Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!lll-winken!lll-lcc!pyramid!prls!gardner From: gardner@prls.UUCP (Robert Gardner) Newsgroups: comp.lang.c Subject: How are local vars allocated? Message-ID: <7401@prls.UUCP> Date: Fri, 13-Nov-87 16:34:22 EST Article-I.D.: prls.7401 Posted: Fri Nov 13 16:34:22 1987 Date-Received: Sun, 15-Nov-87 11:37:19 EST References: <189@dalcsug.UUCP> Reply-To: gardner@prls.UUCP (Robert Gardner) Organization: Philips Research Labs, Sunnyvale, California Lines: 11 Is there any danger of stack overflow with the following construct: for(;;) { int k; etc. etc. } (assume the loop eventually exits, of course). In other words, is k allocated only once at the beginning of the procedure containing this construct, or is it allocated each time the {} block is entered? Is the answer implementation dependent? Robert Gardner