[comp.lang.c] Interactive LPI-C problem

fredg@marob.masa.com (Fred Goldrich) (10/01/90)

	I recently obtained my first supposedly ANSI-compatible C
complier, LPI-C from Interactive Systems Corp. and Language Processors,
Inc.  In my first few moments of playing around with it, I think I
have found a serious problem -- it seems to come up with the wrong
value for argc!

$cat test.c
main(argc,argv)
int argc;
char *argv[];
{
printf("Hello world! -- %d\n",argc);
}
$cc test.c
$a.out
Hello world! -- 1
$a.out xxx
Hello world! -- 2
$lpicc test.c
$a.out
Hello world! -- 0
$a.out xxx
Hello world! -- 0

	Am I misunderstanding something about ANSI C?
(Please, flame gently!)  Or is there indeed a problem here?

	Thanks to all.
-- 
	Fred Goldrich
	{att,philabs,rutgers,cmcl2,hombre}!phri!marob!fredg
	(formerly dasys1!maestro)