Hash bug in 2.95.2

Cambell Prince cambell@btw.co.nz
Tue Sep 26 17:58:00 GMT 2000


Hi,

2.95.2 appears to have trouble with the following code:

void Options::dispatch(char* m) {
  Token tokens[] = {
    "-c", 1, &Options::onC,
    "-l", 1, &Options::onL,
    "-h", 1, &Options::onH,
    "-?", 1, &Options::onH,
    "-p", 1, &Options::onP,
  };
  ...

It works when there is only one entry in the array, but not more.

cambell@apu:/net/src/mds/drivers/taitdrv$ g++ -v --save-temps -c -g -I../../
opt
ions.cpp
Reading specs from /usr/lib/gcc-lib/i386-linux/2.95.2/specs
gcc version 2.95.2 20000220 (Debian GNU/Linux)

/usr/lib/gcc-lib/i386-linux/2.95.2/cpp -lang-c++ -v -I../../ -D__GNUC__=2 -D
__G
NUG__=2 -D__GNUC_MINOR__=95 -D__cplusplus -D__ELF__ -Dunix -D__i386__ -Dlinu
x -D
__ELF__ -D__unix__ -D__i386__ -D__linux__ -D__unix -D__linux -Asystem(posix)
 -D_
_EXCEPTIONS -g -Acpu(i386) -Amachine(i386) -Di386 -D__i386 -D__i386__
options.cp
p options.ii
GNU CPP version 2.95.2 20000220 (Debian GNU/Linux) (i386 Linux/ELF)
#include "..." search starts here:
#include <...> search starts here:
 ../..
 /usr/lib/gcc-lib/i386-linux/2.95.2/../../../../include/g++-3
 /usr/local/include
 /usr/lib/gcc-lib/i386-linux/2.95.2/include
 /usr/include
End of search list.
The following default directories have been omitted from the search path:
 /usr/lib/gcc-lib/i386-linux/2.95.2/../../../../i386-linux/include
End of omitted list.
 /usr/lib/gcc-lib/i386-linux/2.95.2/cc1plus options.ii -quiet -dumpbase
options.
cc -g -version -o options.s
GNU C++ version 2.95.2 20000220 (Debian GNU/Linux) (i386-linux) compiled by
GNU
C version 2.95.2 20000220 (Debian GNU/Linux).
options.cpp: In method `void Options::init(int, char **)':
options.cpp:34: warning: choosing `CountString::operator char *()' over
`CountSt
ring::operator const char *() const'
options.cpp:34: warning:   for conversion from `CountString' to `const char
*'
options.cpp:34: warning:   because conversion sequence for the argument is
bette
r
options.cpp: In method `void Options::dispatch(char *)':
options.cpp:49: Internal compiler error in `const_hash', at varasm.c:2372
Please submit a full bug report.
See <URL: http://www.gnu.org/software/gcc/bugs.html > for instructions.
cambell@apu:/net/src/mds/drivers/taitdrv$

---
Cambell Prince cambell@btw.co.nz
BTW Navigation Systems Ltd
14-22 Connett Rd West, Bell Block, New Plymouth
New Zealand

Ph  +64 6 759 5040
Fax +64 6 759 5049

GPS - Mobile Data - Real Time Information Systems - Embedded Systems
---

-------------- next part --------------
A non-text attachment was scrubbed...
Name: options.ii.gz
Type: application/x-gzip
Size: 7572 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-bugs/attachments/20000926/ec0ea9e7/attachment.bin>


More information about the Gcc-bugs mailing list