This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: BUG alloca used as argument to function.


 > From: grahams <grahams@rcp.co.uk>
 > 
 > Hi
 > ALLOCA_BITMAP() which is used by ALLOCA_REG_SET() is implemented as
 > #define ALLOCA_BITMAP ()  bitmap_initialize ((bitmap)alloca (sizeof(..)))
 > alloca () should not be used as an argument to a function. 
 > Graham

	I've seen many people (including myself) make this mistake in
the past.  Perhaps we can have gcc warn about this dubious use of
alloca?

But let's not start a flame war about whether its activated by -Wall,
that is a seperate issue. :-) :-)

		--Kaveh
--
Kaveh R. Ghazi			Engagement Manager / Project Services
ghazi@caip.rutgers.edu		Qwest Internet Solutions

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]