[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Bison 1.875 aborts (nsyms != ntokens + nvars) on attached input file
From: |
Joe Zbiciak |
Subject: |
Bison 1.875 aborts (nsyms != ntokens + nvars) on attached input file |
Date: |
Fri, 23 Apr 2004 10:51:54 -0500 |
User-agent: |
Mutt/1.4.2i |
Hello,
Bison 1.875 under Solaris 2.8 aborts on the attached input file.
Bison 1.25 and 1.35 seem to handle the file just file. Bison aborts
in reader(). Here's info from GDB:
(gdb) run bison_bug.y
Starting program: /foo/solaris2.8/bin/bison bison_bug.y
Program received signal SIGABRT, Aborted.
0xff31fbe8 in _libc_kill () from /usr/lib/libc.so.1
(gdb) bt
#0 0xff31fbe8 in _libc_kill () from /usr/lib/libc.so.1
#1 0xff2b598c in abort () from /usr/lib/libc.so.1
#2 0x00022bb4 in reader () at reader.c:542
#3 0x000164f4 in main (argc=337920, argv=0x53000) at main.c:80
(gdb) fr 2
#2 0x00022bb4 in reader () at reader.c:542
542 abort ();
(gdb) list
537 nritems += 3;
538 grammar = p;
539 }
540
541 if (! (nsyms <= SYMBOL_NUMBER_MAXIMUM && nsyms == ntokens + nvars))
542 abort ();
543
544 xfclose (finput);
545
546 /* Assign the symbols their symbol numbers. Write #defines for the
(gdb) print nsyms
$1 = 80
(gdb) print ntokens
$2 = 35
(gdb) print nvars
$3 = 44
(gdb)
Notice that ntokens + nvars adds up to one less than nsyms.
The attached bug example is a stripped down version of an actual grammar
file I'm using in one of my projects. Some of the type and variable
names have been changed.
Regards,
--Joe
--
|| Joseph Zbiciak, MGTS | "23. No matter how tempted I am with the ||
|| address@hidden | prospect of unlimited power, I will not ||
|| #include <std_disc.h> | consume any energy field bigger than my ||
|| Texas Instruments | head." -- Evil Overlord top 100 list ||
bison_bug.y
Description: Text document
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Bison 1.875 aborts (nsyms != ntokens + nvars) on attached input file,
Joe Zbiciak <=