summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2019-10-17 11:33:54 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2019-10-17 11:51:20 -0700
commit052215a138ab6a4091d59ba95565e2d0cef5f35f (patch)
treeded0bd70692d317c4309961a4bbf9246e6561b82 /tests
parent15c1b913cf0831cba7c1e57d656134e4a630dee2 (diff)
downloadbison-052215a138ab6a4091d59ba95565e2d0cef5f35f.tar.gz
bison: check for int overflow when scanning
* src/scan-gram.l: Include errno.h, for errno. (scan_integer, handle_syncline): Check for integer overflow. * tests/input.at (too-large.y): Adjust to match new diagnostics.
Diffstat (limited to 'tests')
-rw-r--r--tests/input.at2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/input.at b/tests/input.at
index f696f0cf..fe03f2e1 100644
--- a/tests/input.at
+++ b/tests/input.at
@@ -1523,7 +1523,9 @@ start: TOO_LARGE_DEC TOO_LARGE_HEX
AT_BISON_CHECK([too-large.y], [1], [],
[[too-large.y:9.22-42: error: integer out of range: '999999999999999999999'
+too-large.y:9.22-42: error: user token number of TOO_LARGE_DEC too large
too-large.y:10.24-44: error: integer out of range: '0xFFFFFFFFFFFFFFFFFFF'
+too-large.y:10.24-44: error: user token number of TOO_LARGE_HEX too large
]])
AT_BISON_OPTION_POPDEFS