From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23482 invoked by alias); 12 Apr 2011 21:40:07 -0000 Received: (qmail 23457 invoked by uid 22791); 12 Apr 2011 21:40:06 -0000 X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (216.239.44.51) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 12 Apr 2011 21:40:02 +0000 Received: from kpbe14.cbf.corp.google.com (kpbe14.cbf.corp.google.com [172.25.105.78]) by smtp-out.google.com with ESMTP id p3CLe0QW011994; Tue, 12 Apr 2011 14:40:01 -0700 Received: from jade.mtv.corp.google.com (jade.mtv.corp.google.com [172.18.116.94]) by kpbe14.cbf.corp.google.com with ESMTP id p3CLdxO5012669; Tue, 12 Apr 2011 14:39:59 -0700 Received: by jade.mtv.corp.google.com (Postfix, from userid 21482) id 76F58222670; Tue, 12 Apr 2011 14:39:59 -0700 (PDT) To: reply@codereview.appspotmail.com, dnovillo@google.com, gcc-patches@gcc.gnu.org Subject: [pph] Test PPH include at global scope. (issue4399041) Message-Id: <20110412213959.76F58222670@jade.mtv.corp.google.com> Date: Tue, 12 Apr 2011 21:40:00 -0000 From: crowl@google.com (Lawrence Crowl) X-System-Of-Record: true X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org X-SW-Source: 2011-04/txt/msg00941.txt.bz2 Add a test to ensure that PPH files are #included at global scope. Initially, this test is XFAIL, as it's a low priority error. Index: gcc/testsuite/ChangeLog.pph 2011-04-12 Lawrence Crowl * g++.dg/pph/y2smother.cc: New. Index: gcc/testsuite/g++.dg/pph/y2smother.cc =================================================================== *** gcc/testsuite/g++.dg/pph/y2smother.cc (revision 0) --- gcc/testsuite/g++.dg/pph/y2smother.cc (revision 0) *************** *** 0 **** --- 1,4 ---- + namespace smother { + #include "x1struct1.h" + // { dg-error "pph file not included at global scope" "" { xfail *-*-* } } + } -- This patch is available for review at http://codereview.appspot.com/4399041