From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28072 invoked by alias); 7 Jan 2012 19:06:00 -0000 Received: (qmail 28060 invoked by uid 22791); 7 Jan 2012 19:05:59 -0000 X-SWARE-Spam-Status: No, hits=-2.6 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,RCVD_IN_DNSWL_LOW,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mail-iy0-f175.google.com (HELO mail-iy0-f175.google.com) (209.85.210.175) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sat, 07 Jan 2012 19:05:45 +0000 Received: by iakh37 with SMTP id h37so4506666iak.20 for ; Sat, 07 Jan 2012 11:05:44 -0800 (PST) Received: by 10.50.168.2 with SMTP id zs2mr12578587igb.21.1325963144705; Sat, 07 Jan 2012 11:05:44 -0800 (PST) Received: by 10.50.168.2 with SMTP id zs2mr12578514igb.21.1325963143283; Sat, 07 Jan 2012 11:05:43 -0800 (PST) Received: from coign.google.com ([72.14.225.65]) by mx.google.com with ESMTPS id cv10sm4946229igc.0.2012.01.07.11.05.42 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 07 Jan 2012 11:05:42 -0800 (PST) From: Ian Lance Taylor To: Cc: gcc-help@gcc.gnu.org Subject: Re: Keeping blank lines in C++ preproccessor output References: <20120107025653.ZEMRI.117778.root@cdptpa-web06-z02> Date: Sun, 08 Jan 2012 01:02:00 -0000 In-Reply-To: <20120107025653.ZEMRI.117778.root@cdptpa-web06-z02> (galexander2@nc.rr.com's message of "Fri, 6 Jan 2012 21:56:53 -0500") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-IsSubscribed: yes Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org X-SW-Source: 2012-01/txt/msg00042.txt.bz2 writes: > I'm using the C++ preprocessor (g++ -E) to partially preprocess a C++ header file. The preprocessor output documentation (http://gcc.gnu.org/onlinedocs/gcc-4.6.2/cpp/Preprocessor-Output.html#Preprocessor-Output) states: > > Long runs of blank lines are discarded. > > Rather than have long runs of blank lines discarded, I would prefer that runs of two or more blank lines be replaced by single blank line or be left as is. Does anyone know of a way to accomplish either of these? As far as I know there is no way to do this (other than modifying the preprocessor code). It would not be too hard to write a postprocessor which looked at the #line statements and recreated the blank lines. Ian