public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r12-7188] testsuite: Fix up g++.dg/warn/Wuninitialized-32.C test for ilp32 [PR104373]
@ 2022-02-10 23:28 Jakub Jelinek
  0 siblings, 0 replies; only message in thread
From: Jakub Jelinek @ 2022-02-10 23:28 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:50243f4918c2ed7f1ddbf0e8df97a37aee73ebf2

commit r12-7188-g50243f4918c2ed7f1ddbf0e8df97a37aee73ebf2
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Fri Feb 11 00:27:11 2022 +0100

    testsuite: Fix up g++.dg/warn/Wuninitialized-32.C test for ilp32 [PR104373]
    
    The testcase FAILs whenever size_t is not unsigned long:
    FAIL: g++.dg/warn/Wuninitialized-32.C  -std=c++98 (test for excess errors)
    Excess errors:
    .../gcc/testsuite/g++.dg/warn/Wuninitialized-32.C:4:7: error: 'operator new' takes type 'size_t' ('unsigned int') as first parameter [-fpermissive]
    
    Fixed by using __SIZE_TYPE__ instead of unsigned long.
    
    2022-02-11  Jakub Jelinek  <jakub@redhat.com>
    
            PR tree-optimization/104373
            * g++.dg/warn/Wuninitialized-32.C (operator new[]): Use __SIZE_TYPE__
            as type of the first argument instead of unsigned long.

Diff:
---
 gcc/testsuite/g++.dg/warn/Wuninitialized-32.C | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gcc/testsuite/g++.dg/warn/Wuninitialized-32.C b/gcc/testsuite/g++.dg/warn/Wuninitialized-32.C
index 8b02b5c6adb..144a99e0f93 100644
--- a/gcc/testsuite/g++.dg/warn/Wuninitialized-32.C
+++ b/gcc/testsuite/g++.dg/warn/Wuninitialized-32.C
@@ -1,7 +1,7 @@
 // { dg-do compile }
 // { dg-additional-options "-Wall" }
 
-void* operator new[](unsigned long, void* __p);
+void* operator new[](__SIZE_TYPE__, void* __p);
 
 struct allocator
 {


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-02-10 23:28 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-10 23:28 [gcc r12-7188] testsuite: Fix up g++.dg/warn/Wuninitialized-32.C test for ilp32 [PR104373] Jakub Jelinek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).