Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Target Milestone: ---
% cat t.cpp
#include
struct S { int a, b; };
int main ()
{
if (auto [a,b] = S { 0, 1 }; a) { }
else if (std::tie (a, b) = std::tuple (2, 3); a) { }
++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Target Milestone: ---
% cat test.cpp
struct a
{
void f ();
};
struct b: a
{
void f () { a::f (0); }
};
int main ()
{
}
% g++ test.cpp
test.cpp: In member function 'void b::f()':
test.cpp:8:22:
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Target Milestone: ---
GCC refuses to use the explicit constructor for "c" below, while it does use it
for "a" and "b". (It compiles without "explicit"
: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Target Milestone: ---
This may be similar to #93979, but I'm not sure.
% cat test.cpp
#define S(A) sizeof (A)
int main ()
{
int a[10];
return (int) S (a);
}
% g++ -Wold-style-cast test.cpp
t.cpp: In function
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Target Milestone: ---
% cat test.c
#include
#include
#include
/*
static __v4di __builtin_ia32_pand256 (__v4di a, __v4di b)
{
__v4di r;
__asm__ ("vpand %1, %2, %0" : &qu
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Target Milestone: ---
#include
#include
int e;
template std::optional f ()
{
if (auto i = std::string ().find ('a'))
return i;
return { };
}
int main ()
{
size
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Target Milestone: ---
The following code:
template void f (T) = delete;
struct A
{
template A (T v) { f (v); }
};
struct B: A
{
using A::A
Product: gcc
Version: 4.7.2
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: f.heckenb...@fh-soft.de
Created attachment 30014
--> http://gcc.gnu.
: UNCONFIRMED
Severity: normal
Priority: P3
Component: libstdc++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Created attachment 30076
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=30076&action=edit
Test cas
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Created attachment 30237
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=30237&action=edit
Test case
i486-linux-gnu
g++-4.7 (Debian
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Created attachment 30238
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=30238&action=edit
Test case
Got this while triaging #57498. The test program is clearl
Component: libstdc++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Created attachment 30243
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=30243&action=edit
Test case
According to
http://en.cppreference.com/w/cpp/utility/functional/function/~f
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57505
--- Comment #1 from Frank Heckenbach ---
Created attachment 30244
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=30244&action=edit
Test case for enable_shared_from_this
The same applies to std::enable_shared_from_this.
Priority: P3
Component: libstdc++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
As the test below shows, a single invocation of
std::random_device::operator() reads 4k from /dev/urandom, which is
rather wasteful of the entropy collected
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
% cat test.cpp
template struct a
{
int i;
constexpr a (): i (b ()) { }
constexpr int b () { return c (); }
int c () const { throw 42
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
The following program compiles and apparently defaults T as a, altough a (0) is
not a valid expression.
struct a { };
template void f () { }
int main
Priority: P3
Component: inline-asm
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
This was reported as Debian bug #588087 several years ago ...
For error messages concerning inline assembler statements, gcc
counts embedded &qu
river
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
This was reported as Debian bug #593086 several years ago ...
% gcc -MD -MG foo.c
cc1: error: -MG may only be used with -M or -MM
(Contents of source file don't matter.)
According to the manual
`-MD'
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57950
--- Comment #4 from Frank Heckenbach ---
(In reply to Manuel López-Ibáñez from comment #3)
> (In reply to Andreas Schwab from comment #2)
> > GCC uses the line number of the start of the asm statement, so line 8 is
> > correct.
>
> "Correct" as "
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57920
--- Comment #5 from Frank Heckenbach ---
(In reply to Paolo Carlini from comment #1)
> Note that in 4.8.x and mainline for modern x86 and x86_64 targets we don't
> use /dev/urandom at all, we use __x86_rdrand. In general, the idea is that
> more t
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57920
--- Comment #6 from Frank Heckenbach ---
(In reply to Paolo Carlini from comment #3)
> I'm going to attach a patchlet which does the trick (fread -> read) for me.
> Note I'm on purpose disabling the use of __builtin_ia32_rdrand32_step on my
> x86_
: libstdc++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
According to http://www.cplusplus.com/reference/string/string/operator=/,
the std::string move assignment operator should be noexcept.
#include
static_assert (std::is_nothrow_move_assignable
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
I think the following test should not compile, where an a object is implicitly
constructed when calling foo() using its explicit constructor.
struct a
{
explicit a
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=91032
Frank Heckenbach changed:
What|Removed |Added
CC||f.heckenb...@fh-soft.de
--- Comment
NCONFIRMED
Severity: normal
Priority: P3
Component: preprocessor
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Target Milestone: ---
% cat unused.cpp
#pragma GCC diagnostic ignored "-Wunused-macros"
#define YYUSE
#de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80654
Frank Heckenbach changed:
What|Removed |Added
CC||f.heckenb...@fh-soft.de
--- Comment
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80654
--- Comment #6 from Frank Heckenbach ---
Tried to use a self-written (simple) container as a stop-gap, but it also fell
prey to this bug. Daniel Krügler wrote: "std::vector's copy constructor is not
SFINAE-friendly and causes std::is_copy_constru
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80654
--- Comment #8 from Frank Heckenbach ---
(In reply to Ville Voutilainen from comment #7)
> That's not a bug. You need to make the copy constructor of s conditionally
> deleted depending on whether T is copyconstructible.
The copy constructor of
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80654
--- Comment #9 from Frank Heckenbach ---
Found another possible workaround: "Lie" to the compiler (though is it lying
when you're actually telling it the truth? ;) by specializing
std::is_trivially_copy_constructible like this (of course, one nee
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: f.heckenb...@fh-soft.de
Created attachment 28885
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28885
Reproducible test case
Priority: P3
Component: c++
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: f.heckenb...@fh-soft.de
Created attachment 29035
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=29035
Test case
The attached example gives the error:
foo.cpp: In function &
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55798
--- Comment #4 from Frank Heckenbach 2012-12-23
20:12:01 UTC ---
(In reply to comment #3)
> A big note, C and C++ has different rules with respect of nameloop up with
> declarations in the for/if/switch statements.
That's what got me. S
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: f.heckenb...@fh-soft.de
Created attachment 29093
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=29093
Test case
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55893
--- Comment #1 from Frank Heckenbach 2013-01-07
07:21:01 UTC ---
Submitted to early. Here's the description:
The attached test case segfault at runtime:
% g++-4.7 -std=c++11 bug.cpp && ./a.out
Segmentation fault
As far as I can se
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55893
--- Comment #6 from Frank Heckenbach 2013-01-09
04:15:35 UTC ---
(In reply to comment #5)
> Caused by http://gcc.gnu.org/PR49673 I believe. Perhaps instead of testing
> whether TYPE_NEEDS_CONSTRUCTING we need to check if the type has non-
: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: f.heckenb...@fh-soft.de
Created attachment 29268
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=29268
Test case
Compiling the test c
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56100
--- Comment #2 from Frank Heckenbach 2013-01-24
21:25:09 UTC ---
I guess many warnings can only be given correctly during instantiation because
they depend on the actual arguments.
But shadowing is not one of them as the set of identifie
Version: 5.3.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: middle-end
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Target Milestone: ---
Possibly a duplicate of 34515, but that one seems to
iority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Target Milestone: ---
% cat t.cpp
struct a
{
template a (T && v) { }
};
struct b: a
{
using a::a;
};
int main ()
{
b { "foo" };
}
% g++ -Wuseless-cast t.
: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
g++ says "too many initializers" for an array of vectors with initializers, but
only within a struct.
Not sure if it should work (I don't see why not), but it seems inconsistent
that it only fails within a st
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=61122
--- Comment #2 from Frank Heckenbach ---
If it's not allowed, it should also fail at file-scope or function-scope,
shouldn't it?
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Target Milestone: ---
The attached test program tries to construct various structures
consisting of two members of some type a, where
Severity: normal
Priority: P3
Component: testsuite
Assignee: unassigned at gcc dot gnu.org
Reporter: f.heckenb...@fh-soft.de
Target Milestone: ---
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66154
--- Comment #1 from Frank Heckenbach ---
Somehow this got sent before the text was inserted, so here goes:
Also reported on Debian, but I was asked to report it here:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=785249
When I tried to buil
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57951
--- Comment #2 from Frank Heckenbach ---
Another bug that may be related to this one (and certainly depends
on it), originally reported as Debian bug #613551:
Tested with gcc-4.1 (apparently the last version that did allow "-MD -MG"):
When usin
45 matches
Mail list logo