[Bug c++/53499] Incorrect partial ordering result with member vs non-member

2018-01-12 Thread ed at catmur dot co.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53499 --- Comment #3 from Ed Catmur --- I believe this also causes gcc to reject (as ambiguous) the example in [temp.func.order]/3: struct A { }; template struct B { template int operator*(R&); // #1 }; template int operator*(T&, R&);

[Bug c++/81420] When a reference is bound to a member in the base of a temporary, lifetime of the temporary is not extended

2018-01-07 Thread ed at catmur dot co.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81420 --- Comment #1 from Ed Catmur --- icc 18 also has this bug. MSVC 19 2017 (with /permissive-) miscompiles by copying the bound subobject to a separate complete object before binding, so the reference does not dangle but the derived and base class

[Bug c++/78753] non-ambiguous overload resolution with function template partial ordering rules

2017-07-24 Thread ed at catmur dot co.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78753 Ed Catmur changed: What|Removed |Added CC||ed at catmur dot co.uk --- Comment #1 from

[Bug sanitizer/81021] stack-use-after-scope false positive error with exceptions

2017-07-13 Thread ed at catmur dot co.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81021 --- Comment #29 from Ed Catmur --- Created attachment 41750 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=41750=edit stack-use-after-scope-read.cpp Another testcase, no library required. Slight difference here is that the offending op is

[Bug c++/80805] New: ICE in sufficiently complex code with -g (dump_aggr_type)

2017-05-17 Thread ed at catmur dot co.uk
Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: ed at catmur dot co.uk Target Milestone: --- The following program crashes gcc versions 5.1 to recent trunk (20170517 on godbolt.org) when compiled with -std=c++11 -g (the -g seems

[Bug c++/80605] [7/8 Regression] Bad is_standard_layout result with empty base classes

2017-05-15 Thread ed at catmur dot co.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80605 --- Comment #8 from Ed Catmur --- Looks to have been fixed by r247816.

[Bug c++/80667] [c++1z] ice segfault on partial specialization with non-type template parameter

2017-05-08 Thread ed at catmur dot co.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80667 --- Comment #1 from Ed Catmur --- note: the rationale for using std::integral_constant rather than a T non-type argument is CWG 1315. Clang rejects in -std=c++1z: :22:63: error: ambiguous partial specializations of 'Impl >' Impl> foo()

[Bug c++/80449] New: ICE reporting failed partial class template specialization class template argument deduction

2017-04-18 Thread ed at catmur dot co.uk
Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: ed at catmur dot co.uk Target Milestone: --- The following invalid code ICEs: template struct C; template<> struct C { C(int, int) {} }; auto k =

[Bug c++/79113] New: ICE inheriting a default constructor

2017-01-17 Thread ed at catmur dot co.uk
++ Assignee: unassigned at gcc dot gnu.org Reporter: ed at catmur dot co.uk Target Milestone: --- struct B { B(); }; struct D : B { using B::B; D(char); }; D d; prog.cc:6:3: internal compiler error: Segmentation fault D d; ^ 0xb0569f crash_signal /home/heads/gcc/gcc

[Bug c++/77435] New: Dependent reference non-type template parameter not matched for partial specialization

2016-08-31 Thread ed at catmur dot co.uk
Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: ed at catmur dot co.uk Target Milestone: --- template<int, class T, T> struct S; template struct S<0, T, A> {}; int i; S<0, int*, > r; //

[Bug c++/60027] Problem with braced-init-lists and explicit ctors

2016-05-04 Thread ed at catmur dot co.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60027 Ed Catmur changed: What|Removed |Added CC||ed at catmur dot co.uk --- Comment #1 from

[Bug c++/70536] g++ doesn't emit DW_AT_name for DW_TAG_GNU_formal_parameter_pack

2016-04-04 Thread ed at catmur dot co.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70536 Ed Catmur changed: What|Removed |Added CC||ed at catmur dot co.uk --- Comment #1 from

[Bug c++/70536] New: g++ doesn't emit DW_AT_name for DW_TAG_GNU_formal_parameter_pack

2016-04-04 Thread ed at catmur dot co.uk
Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: ed at catmur dot co.uk Target Milestone: --- Per http://wiki.dwarfstd.org/index.php?title=C%2B%2B0x:_Variadic_templates DW_TAG_GNU_formal_parameter_pack should have a DW_AT_name: 17

[Bug c++/69621] New: extern std::string used as reference template-argument does not have [abi:cxx11] tag applied

2016-02-02 Thread ed at catmur dot co.uk
Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: ed at catmur dot co.uk Target Milestone: --- #include template<std::string&> struct S { static void f(); }; extern std::string s; void g() { S::f

[Bug c++/67033] [c++11] template argument invalid for integral constant expression beginning with address-of expression

2015-07-27 Thread ed at catmur dot co.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67033 --- Comment #1 from Ed Catmur ed at catmur dot co.uk --- Created attachment 36075 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=36075action=edit pr67033.patch This is kinda ugly. The problem is that before C++1z, a non-type template

[Bug c++/67033] New: [c++11] template argument invalid for integral constant expression beginning with address-of expression

2015-07-27 Thread ed at catmur dot co.uk
Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: ed at catmur dot co.uk Target Milestone: --- templatebool B struct S { }; int x; Sx == x s; // error: template argument 1

[Bug c++/66596] Type that is not dependent on the variable template template parameters

2015-06-19 Thread ed at catmur dot co.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66596 --- Comment #1 from Ed Catmur ed at catmur dot co.uk --- Note: error produced is: prog.cc: In instantiation of 'void g() [with T = int]': prog.cc:6:21: required from here prog.cc:5:30: error: 'U::f()' is not a member of 'V' templateclass T

[Bug c++/66476] New: Erroneous initializer_list lifetime extension from temporary initializer_list

2015-06-09 Thread ed at catmur dot co.uk
: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: ed at catmur dot co.uk Target Milestone: --- #include stdio.h #include initializer_list struct S { S(int) { puts(S(int)); } ~S() { puts(~S()); } }; int main() { std

[Bug c++/65775] Late-specified return type bypasses return type checks (qualified, function, array)

2015-04-15 Thread ed at catmur dot co.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65775 --- Comment #1 from Ed Catmur ed at catmur dot co.uk --- Credit to FISOCPP (http://stackoverflow.com/q/29628571/567292) for finding this bug.

[Bug c++/65775] New: Late-specified return type bypasses return type checks (qualified, function, array)

2015-04-15 Thread ed at catmur dot co.uk
Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: ed at catmur dot co.uk If a function declaration has a late-specified return type the usual checks on return types are bypassed: using Qi = int const volatile; Qi q1

[Bug c++/64095] New: [C++14] Ellipsis at end of generic lambda parameter-declaration-clause should be parsed as a parameter pack

2014-11-27 Thread ed at catmur dot co.uk
Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: ed at catmur dot co.uk void f() { [](auto...){}(); } prog.cc: In function 'void f()': prog.cc:1:26: error: no match for call

[Bug c++/60009] New: g++ allows copy-initialization of an array of class type from a non-braced string literal

2014-01-31 Thread ed at catmur dot co.uk
Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: ed at catmur dot co.uk The following code should be rejected, but is accepted by g++ 4.8.1, in both C++03 and C++11 mode: struct s { s(const char

[Bug c++/56239] New: parse error calling operator() on parenthesized value-initialized temporary

2013-02-07 Thread ed at catmur dot co.uk
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56239 Bug #: 56239 Summary: parse error calling operator() on parenthesized value-initialized temporary Classification: Unclassified Product: gcc Version: 4.8.0

[Bug c++/55724] [C++11] Default type of a template value is not working

2012-12-17 Thread ed at catmur dot co.uk
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55724 --- Comment #1 from Ed Catmur ed at catmur dot co.uk 2012-12-17 19:25:39 UTC --- It's not entirely clear in the standard, but my understanding of 14.8.2p5 is that default template argument substitution is contemporaneous to template

[Bug c++/54165] Cast to void should not implicitly call conversion functions

2012-08-03 Thread ed at catmur dot co.uk
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54165 Ed Catmur ed at catmur dot co.uk changed: What|Removed |Added CC||ed at catmur dot co.uk