Article View: gnu.gcc.bug
Article #1643size_t problem
From: ksakai
Date: Sat, 23 Jan 1993 02:44
Date: Sat, 23 Jan 1993 02:44
39 lines
2019 bytes
2019 bytes
I have made gcc-2.3.3 successfully on RISC news (running newsos 4.1R)
with configured "--target=mips-sony-newsos4.1", then tried to make
libg++-2.3, but next error messages appeared.
----
gcc -g -O -nostdinc++ -I.. -I. -I./../iostream -I./../g++-include -c AllocRing.
cc
In file included from ./std.h:26, from AllocRing.cc:22:
./../g++-include/string.h:28: declaration of `long int strlen (const char *)'
<built-in>:0: conflicts with built-in declaration `unsigned int strlen (const c
har *)'
make[1]: *** [AllocRing.o] Error 1
make: *** [in-src] Error 1
----
On the Omron Luna88k's gcc-2.3.3 (configured "--target=m88k-omron-luna
--with-gnu-ld"), same problem have occurred as this.
----
gcc -g -O -nostdinc++ -I.. -I. -I./../iostream -I./../g++-include -c AllocRing.cc
In file included from ./std.h:26, from AllocRing.cc:22:
./../g++-include/string.h:28: declaration of `long int strlen (const char *)'
<built-in>:0: conflicts with built-in declaration `unsigned int strlen (const char *)'
make[1]: *** [AllocRing.o] Error 1
make: *** [in-src] Error 1
----
In the libg++/g++include/string.h, written as this.
----
// NOTE: If you get a error message from g++ that this declaration
// conflicts with a <built-in> declaration of strlen(), that usually
// indicates that __SIZE_TYPE__ is incorrectly defined by gcc.
// Fix or add SIZE_TYPE in the appropriate file in gcc/config/*.h.
----
So, I think, on both systems, size_t should be defined as "long int".
Kiyotaka Sakai(ksakai@mtl.t.u-tokyo.ac.jp)
Technical Details
Message-ID:
<9301221858.AA18258@vesper.mtl.t.u-tokyo.ac.jp>Path:
arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!cis.ohio-state.edu!mtl.t.u-tokyo.ac.JP!ksakaiShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!cis.ohio-state.edu!mtl.t.u-tokyo.ac.JP!ksakai From: ksakai@mtl.t.u-tokyo.ac.JP Newsgroups: gnu.gcc.bug Subject: size_t problem Date: 22 Jan 1993 21:44:24 -0500 Organization: GNUs Not Usenet Lines: 40 Sender: daemon@cis.ohio-state.edu Approved: bug-gcc@prep.ai.mit.edu Distribution: gnu Message-ID: <9301221858.AA18258@vesper.mtl.t.u-tokyo.ac.jp>