typedef scope mess

Chris Koenigsberg ckk at g.cs.cmu.edu
Tue Jun 10 09:52:45 AEST 1986


Keywords:not in MY K&R!!

tps at sdchem said the following program should be legal as it was from
"K&R p.206":
	typedef float	distance;

	main()
	{

		auto int	distance;

	/*###8 [cc] unknown size%%%*/
	/*###8 [cc] cannot recover from earlier errors: goodbye!%%%*/
	/*###8 [cc] syntax error%%%*/
	/*###8 [cc] warning: illegal combination of pointer and integer, op =%%%*/
		distance =	1;
		printf( "distance = %d\n", distance );
	}



More information about the Comp.lang.c mailing list