Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package gcc7 for openSUSE:Factory checked in 
at 2021-02-11 12:44:47
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/gcc7 (Old)
 and      /work/SRC/openSUSE:Factory/.gcc7.new.28504 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "gcc7"

Thu Feb 11 12:44:47 2021 rev:33 rq:869117 version:7.5.0+r278197

Changes:
--------
--- /work/SRC/openSUSE:Factory/gcc7/cross-aarch64-gcc7.changes  2021-01-10 
19:38:25.341446535 +0100
+++ /work/SRC/openSUSE:Factory/.gcc7.new.28504/cross-aarch64-gcc7.changes       
2021-02-11 12:45:06.613289951 +0100
@@ -1,0 +2,11 @@
+Wed Feb  3 09:31:02 UTC 2021 - Richard Biener <rguent...@suse.com>
+
+- Remove include-fixed/pthread.h
+- Change GCC exception licenses to SPDX format
+
+-------------------------------------------------------------------
+Sun Jan 31 16:41:10 UTC 2021 - Dirk M??ller <dmuel...@suse.com>
+
+- add gcc7-pr81942.patch [bsc#1181618] 
+
+-------------------------------------------------------------------
cross-arm-gcc7.changes: same change
cross-arm-none-gcc7-bootstrap.changes: same change
cross-arm-none-gcc7.changes: same change
cross-avr-gcc7-bootstrap.changes: same change
cross-avr-gcc7.changes: same change
cross-epiphany-gcc7-bootstrap.changes: same change
cross-epiphany-gcc7.changes: same change
cross-hppa-gcc7.changes: same change
cross-i386-gcc7.changes: same change
cross-m68k-gcc7.changes: same change
cross-mips-gcc7.changes: same change
cross-nvptx-gcc7.changes: same change
cross-ppc64-gcc7.changes: same change
cross-ppc64le-gcc7.changes: same change
cross-rx-gcc7-bootstrap.changes: same change
cross-rx-gcc7.changes: same change
cross-s390x-gcc7.changes: same change
cross-sparc-gcc7.changes: same change
cross-sparc64-gcc7.changes: same change
cross-x86_64-gcc7.changes: same change
gcc7-testresults.changes: same change
gcc7.changes: same change

New:
----
  gcc7-pr81942.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ cross-aarch64-gcc7.spec ++++++
--- /var/tmp/diff_new_pack.reu5b0/_old  2021-02-11 12:45:18.257306904 +0100
+++ /var/tmp/diff_new_pack.reu5b0/_new  2021-02-11 12:45:18.261306909 +0100
@@ -137,6 +137,7 @@
 Patch29:        gcc7-pr97535.patch
 Patch30:        gcc7-pr88522.patch
 Patch31:        gcc7-testsuite-fixes.patch
+Patch32:        gcc7-pr81942.patch
 # A set of patches from the RH srpm
 Patch51:        gcc41-ppc32-retaddr.patch
 # Some patches taken from Debian
@@ -300,6 +301,7 @@
 %patch29
 %patch30 -p1
 %patch31 -p1
+%patch32 -p1
 %patch51
 %patch60
 %patch61

cross-arm-gcc7.spec: same change
cross-arm-none-gcc7-bootstrap.spec: same change
cross-arm-none-gcc7.spec: same change
cross-avr-gcc7-bootstrap.spec: same change
cross-avr-gcc7.spec: same change
cross-epiphany-gcc7-bootstrap.spec: same change
cross-epiphany-gcc7.spec: same change
cross-hppa-gcc7.spec: same change
cross-i386-gcc7.spec: same change
cross-m68k-gcc7.spec: same change
cross-mips-gcc7.spec: same change
cross-nvptx-gcc7.spec: same change
cross-ppc64-gcc7.spec: same change
cross-ppc64le-gcc7.spec: same change
cross-rx-gcc7-bootstrap.spec: same change
cross-rx-gcc7.spec: same change
cross-s390x-gcc7.spec: same change
cross-sparc-gcc7.spec: same change
cross-sparc64-gcc7.spec: same change
cross-x86_64-gcc7.spec: same change
gcc7-testresults.spec: same change
++++++ gcc7.spec ++++++
--- /var/tmp/diff_new_pack.reu5b0/_old  2021-02-11 12:45:18.957307923 +0100
+++ /var/tmp/diff_new_pack.reu5b0/_new  2021-02-11 12:45:18.965307935 +0100
@@ -316,6 +316,7 @@
 Patch29:        gcc7-pr97535.patch
 Patch30:        gcc7-pr88522.patch
 Patch31:        gcc7-testsuite-fixes.patch
+Patch32:        gcc7-pr81942.patch
 # A set of patches from the RH srpm
 Patch51:        gcc41-ppc32-retaddr.patch
 # Some patches taken from Debian
@@ -473,7 +474,7 @@
 
 %package -n libstdc++%{libstdcxx_sover}-devel%{libdevel_suffix}
 Summary:        Include Files and Libraries mandatory for Development
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          Development/Languages/C and C++
 Requires:       glibc-devel
 Requires:       libstdc++%{libstdcxx_sover} >= %{version}-%{release}
@@ -486,7 +487,7 @@
 library. It is needed for compiling C++ code.
 %package -n libstdc++%{libstdcxx_sover}-devel%{libdevel_suffix}-32bit
 Summary:        Include Files and Libraries mandatory for Development
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          Development/Languages/C and C++
 Requires:       glibc-devel-32bit
 Requires:       libstdc++%{libstdcxx_sover}-32bit >= %{version}-%{release}
@@ -499,7 +500,7 @@
 library. It is needed for compiling C++ code.
 %package -n libstdc++%{libstdcxx_sover}-devel%{libdevel_suffix}-64bit
 Summary:        Include Files and Libraries mandatory for Development
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          Development/Languages/C and C++
 Requires:       glibc-devel-64bit
 Requires:       libstdc++%{libstdcxx_sover}-64bit >= %{version}-%{release}
@@ -514,7 +515,7 @@
 
 %package -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}
 Summary:        C compiler runtime library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Base
 Provides:       libgcc_s%{libgcc_s} = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -529,7 +530,7 @@
 %postun -n libgcc_s%{libgcc_s}%{libgcc_s_suffix} -p /sbin/ldconfig
 %package -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}-32bit
 Summary:        C compiler runtime library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Base
 Provides:       libgcc_s%{libgcc_s}-32bit = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -544,7 +545,7 @@
 %postun -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}-32bit -p /sbin/ldconfig
 %package -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}-64bit
 Summary:        C compiler runtime library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Base
 Provides:       libgcc_s%{libgcc_s}-64bit = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -560,7 +561,7 @@
 
 %package -n libgomp%{libgomp_sover}%{libgomp_suffix}
 Summary:        The GNU compiler collection OpenMP runtime library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Base
 Provides:       libgomp%{libgomp_sover} = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -579,7 +580,7 @@
 %postun -n libgomp%{libgomp_sover}%{libgomp_suffix} -p /sbin/ldconfig
 %package -n libgomp%{libgomp_sover}%{libgomp_suffix}-32bit
 Summary:        The GNU compiler collection OpenMP runtime library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Base
 Provides:       libgomp%{libgomp_sover}-32bit = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -598,7 +599,7 @@
 %postun -n libgomp%{libgomp_sover}%{libgomp_suffix}-32bit -p /sbin/ldconfig
 %package -n libgomp%{libgomp_sover}%{libgomp_suffix}-64bit
 Summary:        The GNU compiler collection OpenMP runtime library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Base
 Provides:       libgomp%{libgomp_sover}-64bit = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -618,7 +619,7 @@
 
 %package -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}
 Summary:        The standard C++ shared library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Libraries
 Suggests:       libstdc++%{libstdcxx_sover}-locale
 Provides:       libstdc++%{libstdcxx_sover} = %{version}-%{release}
@@ -635,7 +636,7 @@
 %postun -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix} -p /sbin/ldconfig
 %package -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-32bit
 Summary:        The standard C++ shared library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Libraries
 Suggests:       libstdc++%{libstdcxx_sover}-locale
 Provides:       libstdc++%{libstdcxx_sover}-32bit = %{version}-%{release}
@@ -652,7 +653,7 @@
 %postun -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-32bit -p 
/sbin/ldconfig
 %package -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-64bit
 Summary:        The standard C++ shared library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Libraries
 Suggests:       libstdc++%{libstdcxx_sover}-locale
 Provides:       libstdc++%{libstdcxx_sover}-64bit = %{version}-%{release}
@@ -670,7 +671,7 @@
 
 %package -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-locale
 Summary:        Standard C++ Library Locales
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Libraries
 Provides:       libstdc++%{libstdcxx_sover}-locale = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -734,7 +735,7 @@
 
 %package -n libobjc%{libobjc_sover}%{libobjc_suffix}
 Summary:        Library for the GNU Objective C Compiler
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          Development/Libraries/Other
 Provides:       libobjc%{libobjc_sover} = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -749,7 +750,7 @@
 %postun -n libobjc%{libobjc_sover}%{libobjc_suffix} -p /sbin/ldconfig
 %package -n libobjc%{libobjc_sover}%{libobjc_suffix}-32bit
 Summary:        Library for the GNU Objective C Compiler
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          Development/Libraries/Other
 Provides:       libobjc%{libobjc_sover}-32bit = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -764,7 +765,7 @@
 %postun -n libobjc%{libobjc_sover}%{libobjc_suffix}-32bit -p /sbin/ldconfig
 %package -n libobjc%{libobjc_sover}%{libobjc_suffix}-64bit
 Summary:        Library for the GNU Objective C Compiler
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          Development/Libraries/Other
 Provides:       libobjc%{libobjc_sover}-64bit = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -862,7 +863,7 @@
 
 %package -n libada7
 Summary:        GNU Ada Runtime Libraries
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Libraries
 Provides:       libgnarl-7 = %{version}-%{release}
 Conflicts:      %selfconflict libgnarl-7
@@ -882,7 +883,7 @@
 %postun -n libada7 -p /sbin/ldconfig
 %package -n libada7-32bit
 Summary:        GNU Ada Runtime Libraries
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Libraries
 Provides:       libgnarl-7-32bit = %{version}-%{release}
 Conflicts:      %selfconflict libgnarl-7-32bit
@@ -902,7 +903,7 @@
 %postun -n libada7-32bit -p /sbin/ldconfig
 %package -n libada7-64bit
 Summary:        GNU Ada Runtime Libraries
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          System/Libraries
 Provides:       libgnarl-7-64bit = %{version}-%{release}
 Conflicts:      %selfconflict libgnarl-7-64bit
@@ -963,7 +964,7 @@
 
 %package -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}
 Summary:        The GNU Fortran Compiler Runtime Library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          Development/Languages/Fortran
 %ifarch %quadmath_arch
 Requires:       libquadmath%{libquadmath_sover} >= %{version}-%{release}
@@ -982,7 +983,7 @@
 %postun -n libgfortran%{libgfortran_sover}%{libgfortran_suffix} -p 
/sbin/ldconfig
 %package -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}-32bit
 Summary:        The GNU Fortran Compiler Runtime Library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          Development/Languages/Fortran
 %ifarch %quadmath_arch
 Requires:       libquadmath%{libquadmath_sover}-32bit >= %{version}-%{release}
@@ -1001,7 +1002,7 @@
 %postun -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}-32bit -p 
/sbin/ldconfig
 %package -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}-64bit
 Summary:        The GNU Fortran Compiler Runtime Library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          Development/Languages/Fortran
 %ifarch %quadmath_arch
 Requires:       libquadmath%{libquadmath_sover}-64bit >= %{version}-%{release}
@@ -1220,7 +1221,7 @@
 
 %package -n libatomic%{libatomic_sover}%{libatomic_suffix}
 Summary:        The GNU Compiler Atomic Operations Runtime Library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          Development/Languages/C and C++
 Provides:       libatomic%{libatomic_sover} = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -1235,7 +1236,7 @@
 %postun -n libatomic%{libatomic_sover}%{libatomic_suffix} -p /sbin/ldconfig
 %package -n libatomic%{libatomic_sover}%{libatomic_suffix}-32bit
 Summary:        The GNU Compiler Atomic Operations Runtime Library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          Development/Languages/C and C++
 Provides:       libatomic%{libatomic_sover}-32bit = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -1250,7 +1251,7 @@
 %postun -n libatomic%{libatomic_sover}%{libatomic_suffix}-32bit -p 
/sbin/ldconfig
 %package -n libatomic%{libatomic_sover}%{libatomic_suffix}-64bit
 Summary:        The GNU Compiler Atomic Operations Runtime Library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:          Development/Languages/C and C++
 Provides:       libatomic%{libatomic_sover}-64bit = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -1785,6 +1786,7 @@
 %patch29
 %patch30 -p1
 %patch31 -p1
+%patch32 -p1
 %patch51
 %patch60
 %patch61
@@ -2367,6 +2369,7 @@
 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/bits/mathdef.h
 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/sys/ucontext.h
 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/bits/statx.h
+rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/pthread.h
 %if !%{enable_plugins}
 # no plugins
 rm -rf $RPM_BUILD_ROOT%{libsubdir}/plugin

++++++ gcc.spec.in ++++++
--- /var/tmp/diff_new_pack.reu5b0/_old  2021-02-11 12:45:19.201308278 +0100
+++ /var/tmp/diff_new_pack.reu5b0/_new  2021-02-11 12:45:19.205308284 +0100
@@ -322,6 +322,7 @@
 Patch29:       gcc7-pr97535.patch
 Patch30:       gcc7-pr88522.patch
 Patch31:       gcc7-testsuite-fixes.patch
+Patch32:       gcc7-pr81942.patch
 # A set of patches from the RH srpm
 Patch51:       gcc41-ppc32-retaddr.patch
 # Some patches taken from Debian
@@ -462,7 +463,7 @@
 # PACKAGE-BEGIN
 %package -n libstdc++%{libstdcxx_sover}-devel%{libdevel_suffix}@variant@
 Summary:      Include Files and Libraries mandatory for Development
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:        Development/Languages/C and C++
 Requires: libstdc++%{libstdcxx_sover}@variant@ >= %{version}-%{release}
 Requires: glibc-devel@variant@
@@ -479,7 +480,7 @@
 # PACKAGE-BEGIN
 %package -n libgcc_s%{libgcc_s}%{libgcc_s_suffix}@variant@
 Summary:      C compiler runtime library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:        System/Base
 Provides:      libgcc_s%{libgcc_s}@variant@ = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -497,7 +498,7 @@
 # PACKAGE-BEGIN
 %package -n libgomp%{libgomp_sover}%{libgomp_suffix}@variant@
 Summary:      The GNU compiler collection OpenMP runtime library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:        System/Base
 Provides:      libgomp%{libgomp_sover}@variant@ = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -519,7 +520,7 @@
 # PACKAGE-BEGIN
 %package -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}@variant@
 Summary:      The standard C++ shared library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:        System/Libraries
 Suggests:      libstdc++%{libstdcxx_sover}-locale
 Provides:      libstdc++%{libstdcxx_sover}@variant@ = %{version}-%{release}
@@ -538,7 +539,7 @@
 
 %package -n libstdc++%{libstdcxx_sover}%{libstdcxx_suffix}-locale
 Summary:       Standard C++ Library Locales
-License:       GPL-3.0-with-GCC-exception
+License:       GPL-3.0 WITH GCC-exception-3.1
 Group:         System/Libraries
 Provides:      libstdc++%{libstdcxx_sover}-locale = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -581,7 +582,7 @@
 # PACKAGE-BEGIN
 %package -n libobjc%{libobjc_sover}%{libobjc_suffix}@variant@
 Summary:      Library for the GNU Objective C Compiler
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:        Development/Libraries/Other
 Provides:      libobjc%{libobjc_sover}@variant@ = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -639,7 +640,7 @@
 # PACKAGE-BEGIN
 %package -n libada@base_ver@@variant@
 Summary:      GNU Ada Runtime Libraries
-License:      GPL-3.0-with-GCC-exception
+License:      GPL-3.0 WITH GCC-exception-3.1
 Group:        System/Libraries
 Provides: libgnarl-@base_ver@@variant@ = %{version}-%{release}
 Conflicts: %selfconflict libgnarl-@base_ver@@variant@
@@ -678,7 +679,7 @@
 # PACKAGE-BEGIN
 %package -n libgfortran%{libgfortran_sover}%{libgfortran_suffix}@variant@
 Summary:      The GNU Fortran Compiler Runtime Library
-License:        GPL-3.0-with-GCC-exception
+License:        GPL-3.0 WITH GCC-exception-3.1
 Group:        Development/Languages/Fortran
 %ifarch %quadmath_arch
 Requires: libquadmath%{libquadmath_sover}@variant@ >= %{version}-%{release}
@@ -777,7 +778,7 @@
 # PACKAGE-BEGIN
 %package -n libatomic%{libatomic_sover}%{libatomic_suffix}@variant@
 Summary:      The GNU Compiler Atomic Operations Runtime Library
-License:      GPL-3.0-with-GCC-exception
+License:      GPL-3.0 WITH GCC-exception-3.1
 Group:        Development/Languages/C and C++
 Provides:      libatomic%{libatomic_sover}@variant@ = %{version}-%{release}
 # Only one package may provide this - allows multiple gcc versions
@@ -1095,6 +1096,7 @@
 %patch29
 %patch30 -p1
 %patch31 -p1
+%patch32 -p1
 %patch51
 %patch60
 %patch61
@@ -1682,6 +1684,7 @@
 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/bits/mathdef.h
 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/sys/ucontext.h
 rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/bits/statx.h
+rm -f $RPM_BUILD_ROOT%{libsubdir}/include-fixed/pthread.h
 %if !%{enable_plugins}
 # no plugins
 rm -rf $RPM_BUILD_ROOT%{libsubdir}/plugin

++++++ gcc7-pr81942.patch ++++++
>From d49318d9bc3e63251aada27b322e7756eab19884 Mon Sep 17 00:00:00 2001
From: Paolo Carlini <paolo.carl...@oracle.com>
Date: Tue, 5 Sep 2017 13:33:44 +0000
Subject: [PATCH 1/1] re PR c++/81942 (ICE on empty constexpr constructor with
 C++14)

/cp
2017-09-05  Paolo Carlini  <paolo.carl...@oracle.com>

        PR c++/81942
        * cp-tree.h (LABEL_DECL_CDTOR): Add and document.
        * decl.c (start_preparsed_function): Set LABEL_DECL_CDTOR when
        creating cdtor_label.
        * constexpr.c (returns): Add the case of a constructor/destructor
        returning via a LABEL_DECL_CDTOR label.
        (cxx_eval_constant_expression, case [GOTO_EXPR]): Likewise.

/testsuite
2017-09-05  Paolo Carlini  <paolo.carl...@oracle.com>

        PR c++/81942
        * g++.dg/cpp1y/constexpr-return3.C: New.

From-SVN: r251714
---
 gcc/cp/ChangeLog                               | 10 ++++++++++
 gcc/cp/constexpr.c                             |  8 ++++++--
 gcc/cp/cp-tree.h                               |  6 ++++++
 gcc/cp/decl.c                                  |  5 ++++-
 gcc/testsuite/ChangeLog                        |  5 +++++
 gcc/testsuite/g++.dg/cpp1y/constexpr-return3.C | 11 +++++++++++
 6 files changed, 42 insertions(+), 3 deletions(-)
 create mode 100644 gcc/testsuite/g++.dg/cpp1y/constexpr-return3.C

Index: gcc-7.5.0+r278197/gcc/cp/constexpr.c
===================================================================
--- gcc-7.5.0+r278197.orig/gcc/cp/constexpr.c
+++ gcc-7.5.0+r278197/gcc/cp/constexpr.c
@@ -3744,7 +3744,9 @@ static bool
 returns (tree *jump_target)
 {
   return *jump_target
-    && TREE_CODE (*jump_target) == RETURN_EXPR;
+    && (TREE_CODE (*jump_target) == RETURN_EXPR
+       || (TREE_CODE (*jump_target) == LABEL_DECL
+           && LABEL_DECL_CDTOR (*jump_target)));
 }
 
 static bool
@@ -4641,7 +4643,9 @@ cxx_eval_constant_expression (const cons
 
     case GOTO_EXPR:
       *jump_target = TREE_OPERAND (t, 0);
-      gcc_assert (breaks (jump_target) || continues (jump_target));
+      gcc_assert (breaks (jump_target) || continues (jump_target)
+                 /* Allow for jumping to a cdtor_label.  */
+                 || returns (jump_target));
       break;
 
     case LOOP_EXPR:
Index: gcc-7.5.0+r278197/gcc/cp/cp-tree.h
===================================================================
--- gcc-7.5.0+r278197.orig/gcc/cp/cp-tree.h
+++ gcc-7.5.0+r278197/gcc/cp/cp-tree.h
@@ -229,6 +229,7 @@ operator == (const cp_expr &lhs, tree rh
       DECL_CONSTRAINT_VAR_P (in a PARM_DECL)
       TEMPLATE_DECL_COMPLEX_ALIAS_P (in TEMPLATE_DECL)
       DECL_INSTANTIATING_NSDMI_P (in a FIELD_DECL)
+      LABEL_DECL_CDTOR (in LABEL_DECL)
    3: DECL_IN_AGGR_P.
    4: DECL_C_BIT_FIELD (in a FIELD_DECL)
       DECL_ANON_UNION_VAR_P (in a VAR_DECL)
@@ -3610,6 +3611,11 @@ more_aggr_init_expr_args_p (const aggr_i
 #define LABEL_DECL_CONTINUE(NODE) \
   DECL_LANG_FLAG_1 (LABEL_DECL_CHECK (NODE))
 
+/* Nonzero if NODE is the target for genericization of 'return' stmts
+   in constructors/destructors of targetm.cxx.cdtor_returns_this targets.  */
+#define LABEL_DECL_CDTOR(NODE) \
+  DECL_LANG_FLAG_2 (LABEL_DECL_CHECK (NODE))
+
 /* True if NODE was declared with auto in its return type, but it has
    started compilation and so the return type might have been changed by
    return type deduction; its declared return type should be found in
Index: gcc-7.5.0+r278197/gcc/cp/decl.c
===================================================================
--- gcc-7.5.0+r278197.orig/gcc/cp/decl.c
+++ gcc-7.5.0+r278197/gcc/cp/decl.c
@@ -15253,7 +15253,10 @@ start_preparsed_function (tree decl1, tr
   if (DECL_DESTRUCTOR_P (decl1)
       || (DECL_CONSTRUCTOR_P (decl1)
          && targetm.cxx.cdtor_returns_this ()))
-    cdtor_label = create_artificial_label (input_location);
+    {
+      cdtor_label = create_artificial_label (input_location);
+      LABEL_DECL_CDTOR (cdtor_label) = true;
+    }
 
   start_fname_decls ();
 
Index: gcc-7.5.0+r278197/gcc/testsuite/g++.dg/cpp1y/constexpr-return3.C
===================================================================
--- /dev/null
+++ gcc-7.5.0+r278197/gcc/testsuite/g++.dg/cpp1y/constexpr-return3.C
@@ -0,0 +1,11 @@
+// PR c++/81942
+// { dg-do compile { target c++14 } }
+
+class A {
+public:
+    constexpr A() {
+      return;
+    }
+};
+
+A mwi;

Reply via email to