From owner-freebsd-current Sat Mar 8 10:48:42 2003 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E377337B401 for ; Sat, 8 Mar 2003 10:48:40 -0800 (PST) Received: from ns1.xcllnt.net (209-128-86-226.BAYAREA.NET [209.128.86.226]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2EE6543F3F for ; Sat, 8 Mar 2003 10:48:40 -0800 (PST) (envelope-from marcel@xcllnt.net) Received: from dhcp01.pn.xcllnt.net (dhcp01.pn.xcllnt.net [192.168.4.201]) by ns1.xcllnt.net (8.12.8/8.12.8) with ESMTP id h28ImbSd030111; Sat, 8 Mar 2003 10:48:37 -0800 (PST) (envelope-from marcel@piii.pn.xcllnt.net) Received: from dhcp01.pn.xcllnt.net (localhost [127.0.0.1]) by dhcp01.pn.xcllnt.net (8.12.7/8.12.7) with ESMTP id h28Imb79000675; Sat, 8 Mar 2003 10:48:37 -0800 (PST) (envelope-from marcel@dhcp01.pn.xcllnt.net) Received: (from marcel@localhost) by dhcp01.pn.xcllnt.net (8.12.7/8.12.7/Submit) id h28ImY91000674; Sat, 8 Mar 2003 10:48:34 -0800 (PST) (envelope-from marcel) Date: Sat, 8 Mar 2003 10:48:34 -0800 From: Marcel Moolenaar To: Garrett Wollman Cc: Craig Rodrigues , freebsd-current@FreeBSD.ORG Subject: Re: #warning must be protected by #if __GNUC__ in headers? Message-ID: <20030308184834.GC543@dhcp01.pn.xcllnt.net> References: <20030308161943.GA54921@attbi.com> <200303081728.h28HSDWM039984@khavrinen.lcs.mit.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200303081728.h28HSDWM039984@khavrinen.lcs.mit.edu> User-Agent: Mutt/1.5.3i Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sat, Mar 08, 2003 at 12:28:13PM -0500, Garrett Wollman wrote: > > `#if __GNUC__' wouldn't help matters; every preprocessor has to read > and interpret every preprocessor directive (so that `#else' and > `#endif' can be recognized). I don't think preprocessors should interpret directives when they are dead (ie part of an #if block or #else block that is not to be compiled). They should merely scan the block for #else, #endif and the likes to keep track of nesting, but should otherwise ignore anything it sees. For how does it matter if a directive is valid or invalid when you're not acting upon it anyway? One can even claim that emitting an error or warning *is* reaction upon the directive. -- Marcel Moolenaar USPA: A-39004 marcel@xcllnt.net To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message