Article View: comp.sys.amiga.tech
Article #12231Bug: lc1 HANGS with bad input
From: Steve Schoettler
Date: Fri, 14 Apr 1989 19:17
Date: Fri, 14 Apr 1989 19:17
33 lines
1291 bytes
1291 bytes
OK. Here's the simple case:
------------------------
#define y(a) 2*a
myfunc(y)
char *y
{
return(0);
}
----------------------
Note that I forgot the semi-colon after "char *y". If you add the
semi-colon, everything compiles as expected. If you remove the
#define, lc1 warns about a missing semi-colon.
This program as-is, hangs when compiled with "lc1 test", where
test.c is the program above and lc1 is version 5.02. In case
you're wondering, my stack size is 50000.
I admit it's probably bad practice to use variable names that clash
with #define'd functions, but a compiler should never hang, no matter
how stupid the programmer is.
--
Steve Schoettler
shs@uts.amdahl.com
{sun,decwrl,pyramid,ames,uunet}!amdahl!shs
Amdahl Corp., M/S 213, 1250 E. Arques Ave, Sunnyvale, CA 94088
Technical Details
Message-ID:
<19D8W3daRw1010.c0UY@amdahl.uts.amdahl.com>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!utstat!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!bloom-beacon!apple!amdahl!shsShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!utstat!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!bloom-beacon!apple!amdahl!shs From: shs@uts.amdahl.com (Steve Schoettler) Newsgroups: comp.sys.amiga.tech Subject: Bug: lc1 HANGS with bad input Message-ID: <19D8W3daRw1010.c0UY@amdahl.uts.amdahl.com> Date: 14 Apr 89 19:17:38 GMT Reply-To: shs@uts.amdahl.com (Steve Schoettler) Organization: Amdahl Corporation, Sunnyvale CA Lines: 33