From: Andrew Pinski Date: Fri, 24 Nov 2023 02:55:30 +0000 (-0800) Subject: Fix contracts-tmpl-spec2.C on targets where plain char is unsigned by default X-Git-Tag: basepoints/gcc-15~4291 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=6e15e4e1abed02443a27a69455f4bfa49457c99e;p=thirdparty%2Fgcc.git Fix contracts-tmpl-spec2.C on targets where plain char is unsigned by default Since contracts-tmpl-spec2.C is just testing contracts, I thought it would be better to just add `-fsigned-char` to the options rather than change the testcase to support both cases. Committed after testing on aarch64-linux-gnu. gcc/testsuite/ChangeLog: PR testsuite/108321 * g++.dg/contracts/contracts-tmpl-spec2.C: Add -fsigned-char to options. Signed-off-by: Andrew Pinski --- diff --git a/gcc/testsuite/g++.dg/contracts/contracts-tmpl-spec2.C b/gcc/testsuite/g++.dg/contracts/contracts-tmpl-spec2.C index 82117671b2d3..fd3a25bd0514 100644 --- a/gcc/testsuite/g++.dg/contracts/contracts-tmpl-spec2.C +++ b/gcc/testsuite/g++.dg/contracts/contracts-tmpl-spec2.C @@ -1,6 +1,6 @@ // basic test to ensure contracts work for class and member specializations // { dg-do run } -// { dg-options "-std=c++2a -fcontracts -fcontract-continuation-mode=on" } +// { dg-options "-std=c++2a -fcontracts -fcontract-continuation-mode=on -fsigned-char" } #include // template specializations can have differing contracts