Xref: utzoo comp.unix.wizards:9117 comp.lang.c:10567
Path: utzoo!attcan!uunet!husc6!psuvax1!vu-vlsi!swatsun!schwartz
From: schwartz@swatsun.uucp (Scott Schwartz)
Newsgroups: comp.unix.wizards,comp.lang.c
Subject: Alloca() and friends
Summary: Gnu-cc alternatives
Message-ID: <1874@thebes.UUCP>
Date: 6 Jun 88 01:29:43 GMT
References: <16018@brl-adm.ARPA> <8017@brl-smoke.ARPA>
Reply-To: schwartz@thebes.UUCP (Scott Schwartz)
Organization: Swarthmore College, Swarthmore PA
Lines: 18

In article <8017@brl-smoke.ARPA> gwyn@brl.arpa (Doug Gwyn (VLD/VMB) ) writes:
>For a limited class of applications, alloca() can be useful.
>However, I don't use it myself.  My applications all use a more
>disciplined approach to memory allocation.

One nice C extension that gcc provides is variable sized automatic
arrays. I.e.
	foo(s)
	int s;
	{
		int a[s];
	}

I think this obviates the need for alloca() in most (all?) cases.
Too late to get it in ansi, I suppose.

-- 
Scott Schwartz,  schwartz@swarthmore.edu,  psuvax1!vu-vlsi!swatsun!schwartz