re PR c++/85067 (ICE with volatile parameter in defaulted copy-constructor)
/cp 2018-03-27 Paolo Carlini <paolo.carlini@oracle.com> PR c++/85067 * method.c (defaulted_late_check): Partially revert r253321 changes, do not early return upon error. /testsuite 2018-03-27 Paolo Carlini <paolo.carlini@oracle.com> PR c++/85067 * g++.dg/cpp0x/defaulted51.C: New. * g++.dg/cpp0x/constexpr-68754.C: Adjust. From-SVN: r258904
This commit is contained in:
parent
153dba6cbb
commit
f7d9ed11b2
5 changed files with 28 additions and 2 deletions
|
@ -1,3 +1,9 @@
|
|||
2018-03-27 Paolo Carlini <paolo.carlini@oracle.com>
|
||||
|
||||
PR c++/85067
|
||||
* method.c (defaulted_late_check): Partially revert r253321 changes,
|
||||
do not early return upon error.
|
||||
|
||||
2018-03-27 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/85077
|
||||
|
|
|
@ -2189,7 +2189,6 @@ defaulted_late_check (tree fn)
|
|||
"expected signature", fn);
|
||||
inform (DECL_SOURCE_LOCATION (fn),
|
||||
"expected signature: %qD", implicit_fn);
|
||||
return;
|
||||
}
|
||||
|
||||
if (DECL_DELETED_FN (implicit_fn))
|
||||
|
|
|
@ -1,3 +1,9 @@
|
|||
2018-03-27 Paolo Carlini <paolo.carlini@oracle.com>
|
||||
|
||||
PR c++/85067
|
||||
* g++.dg/cpp0x/defaulted51.C: New.
|
||||
* g++.dg/cpp0x/constexpr-68754.C: Adjust.
|
||||
|
||||
2018-03-27 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/85077
|
||||
|
|
|
@ -3,5 +3,5 @@
|
|||
|
||||
struct base { };
|
||||
struct derived : base {
|
||||
constexpr derived& operator=(derived const&) = default; // { dg-error "defaulted declaration" "" { target { ! c++14 } } }
|
||||
constexpr derived& operator=(derived const&) = default; // { dg-error "defaulted" "" { target { ! c++14 } } }
|
||||
};
|
||||
|
|
15
gcc/testsuite/g++.dg/cpp0x/defaulted51.C
Normal file
15
gcc/testsuite/g++.dg/cpp0x/defaulted51.C
Normal file
|
@ -0,0 +1,15 @@
|
|||
// PR c++/85067
|
||||
// { dg-do compile { target c++11 } }
|
||||
|
||||
template<int> struct A
|
||||
{
|
||||
A();
|
||||
A(volatile A&) = default; // { dg-error "defaulted" }
|
||||
};
|
||||
|
||||
struct B
|
||||
{
|
||||
A<0> a;
|
||||
};
|
||||
|
||||
B b;
|
Loading…
Add table
Reference in a new issue