The attached patch eliminates the failures in
g++.dg/other/darwin-cfstring1.C
and obj-c++.dg/strings/const-cfstring-2.mm by adding -ftrack-macro-expansion=0
to dg-options which partially eliminates the remaining failures in PR
target/54404.
These changes eliminate the failures...
FAIL: g++.dg/other/darwin-cfstring1.C -std=gnu++98 (test for errors, line 21)
FAIL: g++.dg/other/darwin-cfstring1.C -std=gnu++98 (test for errors, line 22)
FAIL: g++.dg/other/darwin-cfstring1.C -std=gnu++98 (test for excess errors)
FAIL: g++.dg/other/darwin-cfstring1.C -std=gnu++11 (test for errors, line 21)
FAIL: g++.dg/other/darwin-cfstring1.C -std=gnu++11 (test for errors, line 22)
FAIL: g++.dg/other/darwin-cfstring1.C -std=gnu++11 (test for excess errors)
FAIL: obj-c++.dg/strings/const-cfstring-2.mm -fnext-runtime (test for
warnings, line 22)
FAIL: obj-c++.dg/strings/const-cfstring-2.mm -fnext-runtime (test for
warnings, line 23)
FAIL: obj-c++.dg/strings/const-cfstring-2.mm -fnext-runtime (test for
warnings, line 25)
FAIL: obj-c++.dg/strings/const-cfstring-2.mm -fnext-runtime (test for
warnings, line 26)
at -m32/-m64 on darwin. Tested on x86_64-apple-darwin12, x86_64-apple-darwin10
and powerpc-apple-darwin9.
Okay for gcc trunk?
Jack
gcc/testsuite/
2012-10-17 Dominique Dhumieres <[email protected]>
Jack Howarth <[email protected]>
PR target/54404
* g++.dg/other/darwin-cfstring1.C: Add -ftrack-macro-expansion=0 to
dg-options.
* obj-c++.dg/strings/const-cfstring-2.mm: Likewise.
Index: gcc/testsuite/g++.dg/other/darwin-cfstring1.C
===================================================================
--- gcc/testsuite/g++.dg/other/darwin-cfstring1.C (revision 192531)
+++ gcc/testsuite/g++.dg/other/darwin-cfstring1.C (working copy)
@@ -4,7 +4,7 @@
/* Developed by Ziemowit Laski <[email protected]>. */
/* { dg-do compile { target *-*-darwin* } } */
-/* { dg-options "-mconstant-cfstrings" } */
+/* { dg-options "-ftrack-macro-expansion=0 -mconstant-cfstrings" } */
#include <CoreFoundation/CFString.h>
Index: gcc/testsuite/obj-c++.dg/strings/const-cfstring-2.mm
===================================================================
--- gcc/testsuite/obj-c++.dg/strings/const-cfstring-2.mm (revision
192531)
+++ gcc/testsuite/obj-c++.dg/strings/const-cfstring-2.mm (working copy)
@@ -6,7 +6,7 @@
/* So far, CFString is darwin-only. */
/* { dg-do compile { target *-*-darwin* } } */
/* { dg-skip-if "NeXT only" { *-*-* } { "-fgnu-runtime" } { "" } } */
-/* { dg-options "-mconstant-cfstrings -Wnonportable-cfstrings" } */
+/* { dg-options "-ftrack-macro-expansion=0 -mconstant-cfstrings
-Wnonportable-cfstrings" } */
#import <Foundation/NSString.h>
#import <CoreFoundation/CFString.h>