This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/81043] New: [concepts] partially specializing on differing constraints gives cryptic error
- From: "hstong at ca dot ibm.com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 09 Jun 2017 22:25:21 +0000
- Subject: [Bug c++/81043] New: [concepts] partially specializing on differing constraints gives cryptic error
- Auto-submitted: auto-generated
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81043
Bug ID: 81043
Summary: [concepts] partially specializing on differing
constraints gives cryptic error
Product: gcc
Version: 8.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: hstong at ca dot ibm.com
Target Milestone: ---
Having more than one partial specialization with, ignoring constraints, the
same arguments results in a cryptic error.
### SOURCE (<stdin>):
template <typename T> concept bool C0 = sizeof(T) <= 4;
template <typename T> concept bool C1 = sizeof(T) > 4;
template <typename T> struct A;
template <C0 T> struct A<T>;
template <C1 T> struct A<T>;
### COMPILER INVOCATION:
g++ -fsyntax-only -x c++ -std=gnu++1z -fconcepts -
### EXPECTED OUTPUT:
(rc=0)
### ACTUAL OUTPUT:
<stdin>:5:24: error: 'A<T>' does not match any declaration
### COMPILER VERSION INFO (g++ -v):
Using built-in specs.
COLLECT_GCC=/opt/wandbox/gcc-head/bin/g++
COLLECT_LTO_WRAPPER=/opt/wandbox/gcc-head/libexec/gcc/x86_64-pc-linux-gnu/8.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../source/configure --prefix=/opt/wandbox/gcc-head
--enable-languages=c,c++ --disable-multilib --without-ppl --without-cloog-ppl
--enable-checking=release --disable-nls --enable-lto
LDFLAGS=-Wl,-rpath,/opt/wandbox/gcc-head/lib,-rpath,/opt/wandbox/gcc-head/lib64,-rpath,/opt/wandbox/gcc-head/lib32
Thread model: posix
gcc version 8.0.0 20170608 (experimental) (GCC)