From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (71-38-131-64.ptld.qwest.net [71.38.131.64]) by hurricane.the-brannons.com (Postfix) with ESMTPSA id 9A21E7895D for ; Sat, 26 Sep 2015 08:32:52 -0700 (PDT) From: Chris Brannon To: Edbrowse-dev@lists.the-brannons.com References: <20150826111122.eklhad@comcast.net> Date: Sat, 26 Sep 2015 08:36:06 -0700 In-Reply-To: <20150826111122.eklhad@comcast.net> (Karl Dahlke's message of "Sat, 26 Sep 2015 11:11:22 -0400") Message-ID: <87twqhjiqh.fsf@mushroom.localdomain> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Edbrowse-dev] Microsoft C X-BeenThere: edbrowse-dev@lists.the-brannons.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Edbrowse Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Sep 2015 15:32:53 -0000 Karl Dahlke writes: > gcc allows us to define variables anywhere in a block, but Studio C does not. > In the interest of a possible windows port, I request all developers > keep variable definitions at the top of each function or block, > as per K&R. It's not gcc. This was introduced with the C99 standard. I wonder if Visual Studio can be told that code is C99? If not, oh well. On the other hand, gcc allows mixed declarations and code regardless of the standard. If you build with -Wall -pedantic and aren't compiling C99 or C++, it'll complain about mixed declarations and code, but it will happily compile it. -- Chris