This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
gcc 2.95: Bug or Feature
- To: gcc-bugs at gcc dot gnu dot org
- Subject: gcc 2.95: Bug or Feature
- From: Albrecht Dress <ad at MPIfR-Bonn dot MPG dot de>
- Date: Fri, 20 Aug 99 15:42:56 MET DST
- Cc: linuxppc-user at lists dot linuxppc dot org
Hi all,
I recently installed gcc 2.95 form the fsirl folder at
devel.linuxppc.org, and i noticed an odd behaviour when compiling the
following piece of code:
#include <string.h>
void hsets_(long hed[128], long *entry, char *string, long strlen)
{
strncpy(string,"#???",4);
}
(Yes, I know, the "long strlen" parameter may cause trouble). Using the
command "gcc -c test.c" works fine, but "gcc -O2 test.c" reports
test.c: In function `hsets_':
test.c:5: called object is not a function
Changing the parameter name removes the error. Is this a bug or a feature?
My machine is an Apple PowerBook G3 (ppc750) running LinuxPPC 1999 (aka R5).
Thanks, Albrecht.
P.S.: as I am not a member of gc/egcs lists, please reply to the address above.
Thanks.
--