mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-02-06 02:09:40 +08:00
* g++.dg/ext/oper1.C: New test.
From-SVN: r53657
This commit is contained in:
parent
ecc42c14a7
commit
b3f47c787c
@ -1,3 +1,8 @@
|
||||
2002-05-19 Jason Merrill <jason2redhat.com>
|
||||
|
||||
* g++.dg/ext/oper1.C: New test.
|
||||
|
||||
2002-05-20 David Billinghurst <David.Billinghurst@riotinto.com>
|
||||
2002-05-19 Mark Mitchell <mitchell@doubledemon.codesourcery.com>
|
||||
|
||||
* README.QMTEST: New file.
|
||||
|
19
gcc/testsuite/g++.dg/ext/oper1.C
Normal file
19
gcc/testsuite/g++.dg/ext/oper1.C
Normal file
@ -0,0 +1,19 @@
|
||||
// { dg-do run }
|
||||
|
||||
// Copyright 2002 Free Software Foundation
|
||||
// Contributed by Jason Merrill <jason@redhat.com>
|
||||
|
||||
// Make sure the GNU extension of accepting dropping cv-qualifiers for
|
||||
// the implicit this argument does not kick in when taking the address
|
||||
// of an object, since this extension would change the meaning of a
|
||||
// well-defined program.
|
||||
|
||||
struct A {
|
||||
A* operator&() { return 0; }
|
||||
};
|
||||
|
||||
int main ()
|
||||
{
|
||||
const A a = {};
|
||||
return (&a == 0);
|
||||
}
|
Loading…
Reference in New Issue
Block a user