https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92032
Charlie changed:
What|Removed |Added
CC||charlie at charliedyson dot net
--- Comment
: libstdc++
Assignee: unassigned at gcc dot gnu.org
Reporter: charlie at charliedyson dot net
Target Milestone: ---
The hash implementation for std::variant appears to be "index +
hash(contained_value)". This leads to collisions when working with numeric
types (e.g. a
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66717
--- Comment #2 from Charlie ---
I think you may be right that it's only the diagnostic that's wrong. The
following compiles fine https://goo.gl/eyuv17
static int foo = 1;
decltype (const_ref_to_int ()) x = foo;
static_assert (std::is_same(
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: charlie at charliedyson dot net
Target Milestone: ---
Applying decltype to a function returning const int & appear
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65354
--- Comment #2 from Charlie ---
Here's a more succinct example (using the "+" trick to convert to a function
pointer):
#include
int main ()
{
auto f = +[] (std::string s)
{
return std::string (std::move (s));
};
std::stri
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: charlie at charliedyson dot net
In the following, the unique_ptr is deleted twice if the lambda is converted to
a function pointer (#if 1) but runs without error if left as a lambda.
Compiled
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: charlie at charliedyson dot net
The following causes a double free on gcc 4.8.2 as shipped with Ubuntu, and
various other versions I tested on Wandbox.
Interestingly enough, explicitly copying
ty: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: charlie at charliedyson dot net
The following causes a segfault on gcc 4.8.1 and earlier versions:
template
struct X
{
template
using First = Head;
using Y = First;
: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: charlie at charliedyson dot net
In particular, the following and similar examples will compile:
class X
{
X() = default; // Should be private
};
int main()
{
X x;
}
Tested