Recursive #includes

Doug Gwyn gwyn at smoke.BRL.MIL
Tue Feb 28 02:31:00 AEST 1989


In article <573 at marob.MASA.COM> samperi at marob.masa.com (Dominick Samperi) writes:
>By the way, I couldn't find any comments about recursive includes in
>K&R, so I guess this means they are permitted?

K&R 1st Edition, Appendix A, Section 12.2:
	A compiler control line of the form
		#include "filename"
	causes the replacement of the line by the entire contents
	of the file "filename".  ...
	#include's may be nested.

That doesn't seem ambiguous to me.  "causes" should be read as
a requirement on the implementation.  "may" gives the programmer
specific license (in case there was any question).



More information about the Comp.lang.c mailing list