[Bug c++/118469] New: ICE in lexical parser if too many open parentheses

2025-01-14 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118469 Bug ID: 118469 Summary: ICE in lexical parser if too many open parentheses Product: gcc Version: 14.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Compon

[Bug c++/118447] New: Local scope constant is not permitted as function's default argument

2025-01-13 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118447 Bug ID: 118447 Summary: Local scope constant is not permitted as function's default argument Product: gcc Version: 14.2.1 Status: UNCONFIRMED Severity: normal

[Bug c++/118433] New: Local scope deletion of a function is wrongly accepted

2025-01-12 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118433 Bug ID: 118433 Summary: Local scope deletion of a function is wrongly accepted Product: gcc Version: 14.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Co

[Bug analyzer/118300] New: False malloc leak warning from static analyzer

2025-01-05 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118300 Bug ID: 118300 Summary: False malloc leak warning from static analyzer Product: gcc Version: 14.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component:

[Bug c++/117679] Changing active member in a union with overlapping copying not detected in constant expression

2024-11-21 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117679 --- Comment #3 from Fedor Chelnokov --- Here is a better example. It looks valid (unlike above one) because of creating of copy `A( u.a )`: ``` #include struct A { int c[7]; }; struct X { int x; }; struct B : X, A { using A::operator=; }

[Bug c++/117679] New: Changing active member in a union with overlapping copying not detected in constant expression

2024-11-19 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117679 Bug ID: 117679 Summary: Changing active member in a union with overlapping copying not detected in constant expression Product: gcc Version: 14.2.1 Status: UNCONFIRMED

[Bug c++/117651] New: Read of an uninitialized subobject not detected in constant expression

2024-11-18 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117651 Bug ID: 117651 Summary: Read of an uninitialized subobject not detected in constant expression Product: gcc Version: 14.2.1 Status: UNCONFIRMED Severity: norma

[Bug c++/117614] New: Cannot change active member of anonymous union in constant expression

2024-11-15 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117614 Bug ID: 117614 Summary: Cannot change active member of anonymous union in constant expression Product: gcc Version: 14.2.1 Status: UNCONFIRMED Severity: normal

[Bug c++/93607] Deprecated alias templates don't produce warnings

2024-10-23 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93607 Fedor Chelnokov changed: What|Removed |Added CC||fchelnokov at gmail dot com --- Commen

[Bug c++/117106] [12/13/14/15 Regression] ICE when a "deducing this" function with noexcept specification is used before the class is complete

2024-10-22 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117106 --- Comment #3 from Fedor Chelnokov --- (comment #1 corrected) > This crash is reproducible in C++20 mode as well without deducing this: ``` struct A { int x; template void foo() noexcept(noexcept(x)) {} auto bar() -> decltype(fo

[Bug c++/117106] ICE when a "deducing this" function with noexcept specification is used before the class is complete

2024-10-12 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117106 --- Comment #1 from Fedor Chelnokov --- This crash is reproducible in C++20 mode as well without deducing this: ``` struct A { int x; void foo(this auto &&self) noexcept(noexcept(self.x)) {} auto bar() -> decltype(foo()) {} }; ``` In

[Bug c++/116798] New: requires expression can have an explicit object parameter

2024-09-21 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116798 Bug ID: 116798 Summary: requires expression can have an explicit object parameter Product: gcc Version: 14.2.1 Status: UNCONFIRMED Severity: normal P

[Bug c++/103833] Overloaded static member function cannot be resolved unlike overloaded global function

2024-09-08 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103833 --- Comment #2 from Fedor Chelnokov --- Same issue in Clang has been fixed: https://github.com/llvm/llvm-project/issues/52883 Another observation is that `(&(A::m))(0)` was always supported by Clang and MSVC. Demo: https://gcc.godbolt.org/z/q16

[Bug c++/111690] Redefinition of operator == not detected with friend <=>

2024-08-20 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111690 --- Comment #1 from Fedor Chelnokov --- This program should be rejected as well due to ambiguity of equality comparison operator: ``` #include struct A { friend auto operator <=>(const A &, const A &) = default; friend auto operator <=

[Bug c++/116428] New: Redeclaration of explicitly defaulted comparison operator makes it undefined

2024-08-20 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116428 Bug ID: 116428 Summary: Redeclaration of explicitly defaulted comparison operator makes it undefined Product: gcc Version: 14.2.1 Status: UNCONFIRMED Severity:

[Bug c++/116335] New: defaulting int spaceship operator produces wrong code

2024-08-11 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116335 Bug ID: 116335 Summary: defaulting int spaceship operator produces wrong code Product: gcc Version: 14.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Com

[Bug c++/116289] [13 regression] Can't apply decltype to comparison operators created by spaceship operator for local classes

2024-08-10 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116289 --- Comment #8 from Fedor Chelnokov --- Thanks for quick fix. A workaround for this issue in GCC 13.3 is to declare spaceship operator as constexpr: ``` int main() { struct A { int x = 0; constexpr auto operator<=>(const A

[Bug c++/116310] New: default equality operator== selects not-const conversion operator

2024-08-09 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116310 Bug ID: 116310 Summary: default equality operator== selects not-const conversion operator Product: gcc Version: 14.1.1 Status: UNCONFIRMED Severity: normal

[Bug c++/116297] New: ICE on using default spaceship comparison operator inside requires

2024-08-08 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116297 Bug ID: 116297 Summary: ICE on using default spaceship comparison operator inside requires Product: gcc Version: 14.1.1 Status: UNCONFIRMED Severity: normal

[Bug c++/116239] New: Different function redeclaration in function scope is wrongly accepted

2024-08-05 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116239 Bug ID: 116239 Summary: Different function redeclaration in function scope is wrongly accepted Product: gcc Version: 14.1.1 Status: UNCONFIRMED Severity: norma

[Bug c++/116227] New: Implicit copy assignment operator is defined in the presence of user copy assignment operator

2024-08-04 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116227 Bug ID: 116227 Summary: Implicit copy assignment operator is defined in the presence of user copy assignment operator Product: gcc Version: 14.1.1 Status: UNCONFIRMED

[Bug c++/116049] friend function with explicit object parameter

2024-07-24 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116049 --- Comment #1 from Fedor Chelnokov --- And this program ``` struct A { friend bool operator == (this const A&, const A&) = default; }; int main() { A{} == A{}; } ``` results in internal compiler error: Segmentation fault 6 |

[Bug c++/116049] New: friend function with explicit object parameter

2024-07-23 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116049 Bug ID: 116049 Summary: friend function with explicit object parameter Product: gcc Version: 14.1.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component:

[Bug c++/116020] Incorrect treatment of (this void) parameter

2024-07-22 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116020 --- Comment #1 from Fedor Chelnokov --- Another problematic problem example is as follows: struct A { static void f(); }; void foo() { A::f(); //ok } void A::f(this void) {} int main() { A::f(); //error in GCC after A::f definiti

[Bug c++/116020] New: Incorrect treatment of (this void) parameter

2024-07-20 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116020 Bug ID: 116020 Summary: Incorrect treatment of (this void) parameter Product: gcc Version: 14.1.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c

[Bug c++/115878] New: C++23: this int argument with value 0 considered as dereferencing a null pointer

2024-07-11 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115878 Bug ID: 115878 Summary: C++23: this int argument with value 0 considered as dereferencing a null pointer Product: gcc Version: 14.1.1 Status: UNCONFIRMED Sever

[Bug c++/115858] New: Incompatibility of coroutines and alloca()

2024-07-10 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115858 Bug ID: 115858 Summary: Incompatibility of coroutines and alloca() Product: gcc Version: 14.1.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++

[Bug c++/115818] New: Infinite recursive in noexcept operator is not detected

2024-07-07 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115818 Bug ID: 115818 Summary: Infinite recursive in noexcept operator is not detected Product: gcc Version: 14.1.1 Status: UNCONFIRMED Severity: normal Pri

[Bug c++/115596] New: Default arguments are erroneously allowed for parameters of a requires expression

2024-06-23 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115596 Bug ID: 115596 Summary: Default arguments are erroneously allowed for parameters of a requires expression Product: gcc Version: 14.1.1 Status: UNCONFIRMED Seve

[Bug c++/115594] New: requires expression permits arrays of voids

2024-06-22 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115594 Bug ID: 115594 Summary: requires expression permits arrays of voids Product: gcc Version: 14.1.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c+

[Bug c++/115504] New: Wrong decltype result for a captured reference inside limbda

2024-06-15 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115504 Bug ID: 115504 Summary: Wrong decltype result for a captured reference inside limbda Product: gcc Version: 14.1.1 Status: UNCONFIRMED Severity: normal

[Bug c++/115471] New: Fail to capture (with initializer) constant bit-fields by reference in lambda expression

2024-06-13 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115471 Bug ID: 115471 Summary: Fail to capture (with initializer) constant bit-fields by reference in lambda expression Product: gcc Version: 14.1.1 Status: UNCONFIRMED

[Bug c++/115356] New: not a constant expression can be used as non-type template argument inside requires expression

2024-06-05 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115356 Bug ID: 115356 Summary: not a constant expression can be used as non-type template argument inside requires expression Product: gcc Version: 14.1.1 Status: UNCONFIRMED

[Bug c++/115280] New: Concept can access private alias in a classs

2024-05-29 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115280 Bug ID: 115280 Summary: Concept can access private alias in a classs Product: gcc Version: 14.1.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c

[Bug c++/114654] New: Alias template cannot be found

2024-04-09 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114654 Bug ID: 114654 Summary: Alias template cannot be found Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ A

[Bug c++/114537] bit_cast does not work NSDMI of bitfields

2024-04-05 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114537 --- Comment #5 from Fedor Chelnokov --- Sorry, in above example I had to use `unsigned char` type: ``` #include struct A { unsigned char a : 7; }; static_assert( std::bit_cast(std::bit_cast(A{1})).a == 1 ); ``` This program even after the f

[Bug c++/114537] bit_cast does not work NSDMI of bitfields

2024-04-01 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114537 --- Comment #1 from Fedor Chelnokov --- Probably related: ``` #include struct A { int a: 7; }; static_assert( 1 == std::bit_cast(std::bit_cast(A{1})).a ); ``` It looks valid and accepted by MSVC, but GCC prints: error: '__builtin_bit_cast' ac

[Bug c++/114536] wrong constant evaluation of std::bit_cast for bit fields

2024-03-31 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114536 --- Comment #2 from Fedor Chelnokov --- May be just fail constant evaluation then instead of evaluating it to 0?

[Bug c++/114536] New: wrong constant evaluation of std::bit_cast for bit fields

2024-03-31 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114536 Bug ID: 114536 Summary: wrong constant evaluation of std::bit_cast for bit fields Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal P

[Bug c++/104282] Copy elision when initializing a base-class subobject with aggregate initialization

2024-03-22 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104282 --- Comment #8 from Fedor Chelnokov --- One more inconsistency here: struct A { A() {} A(A&&) = delete; }; struct B : A { }; int main() { // ok in GCC B{ A{} }; // error in GCC B b{ A{} }; } GCC allows temporary creatio

[Bug c++/114225] False positive -Werror=dangling-reference

2024-03-04 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114225 --- Comment #4 from Fedor Chelnokov --- Ok. At the same time we see that some false positives of this warning are fixed in Trunk, e.g. struct A { int i; }; struct Getter { const A * a; const int & value() const { return a->i; } };

[Bug c++/114225] False positive -Werror=dangling-reference

2024-03-04 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114225 --- Comment #2 from Fedor Chelnokov --- Please note that this is a regression in GCC 13. GCC 12 (or other compilers) do not show a warning here: https://godbolt.org/z/Yhfad47xs

[Bug c++/113755] New: Class without a viable destructor wrongly accepted

2024-02-04 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113755 Bug ID: 113755 Summary: Class without a viable destructor wrongly accepted Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Compon

[Bug c++/113713] New: static_assert result depends on optimization settings

2024-02-02 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113713 Bug ID: 113713 Summary: static_assert result depends on optimization settings Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Com

[Bug c++/113529] New: Incorrect result of requires-expression in case of function call ambiguity

2024-01-21 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113529 Bug ID: 113529 Summary: Incorrect result of requires-expression in case of function call ambiguity Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: n

[Bug c++/113523] New: A conversion function template can have a deduced return type

2024-01-20 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113523 Bug ID: 113523 Summary: A conversion function template can have a deduced return type Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal

[Bug libstdc++/113522] New: std::swap cannot be called with explicit template argument std::array

2024-01-20 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113522 Bug ID: 113522 Summary: std::swap cannot be called with explicit template argument std::array Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal

[Bug libstdc++/113327] New: std::sleep_for(std::chrono::hours::max()) returns immediately

2024-01-10 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113327 Bug ID: 113327 Summary: std::sleep_for(std::chrono::hours::max()) returns immediately Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal

[Bug c++/113303] New: One can assign to const reference in a template partial specialization

2024-01-09 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113303 Bug ID: 113303 Summary: One can assign to const reference in a template partial specialization Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: norma

[Bug c++/113272] Wrong specialization of class template selected

2024-01-09 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113272 --- Comment #2 from Fedor Chelnokov --- Here is simplified program without #include : template struct A {}; template requires requires(){ *p = 0; } struct A {}; int x = 0; struct B : A<&x>, A<(const int *)&x> {}; GCC fails here because o

[Bug c++/113272] New: Wrong specialization of class template selected

2024-01-08 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113272 Bug ID: 113272 Summary: Wrong specialization of class template selected Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component

[Bug c++/113127] New: Unexpected error: '' was not declared 'constexpr'

2023-12-24 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113127 Bug ID: 113127 Summary: Unexpected error: '' was not declared 'constexpr' Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal Priority:

[Bug c++/113113] New: False -Wmismatched-new-delete in case of destroying operator delete

2023-12-22 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113113 Bug ID: 113113 Summary: False -Wmismatched-new-delete in case of destroying operator delete Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal

[Bug c++/112775] New: Class template partial specialization with decltype(n) is wrongly rejected

2023-11-30 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112775 Bug ID: 112775 Summary: Class template partial specialization with decltype(n) is wrongly rejected Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: n

[Bug c++/112744] New: Nested name specifier wrongly produces ambiguity in accessing static field

2023-11-28 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112744 Bug ID: 112744 Summary: Nested name specifier wrongly produces ambiguity in accessing static field Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: n

[Bug c++/112620] New: Changes to the referenced object in exception handler are lost after rethrow

2023-11-19 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112620 Bug ID: 112620 Summary: Changes to the referenced object in exception handler are lost after rethrow Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity:

[Bug c++/112448] New: Constraint expression b rejected

2023-11-08 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112448 Bug ID: 112448 Summary: Constraint expression b rejected Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++

[Bug tree-optimization/112346] [13 Regression] Wrong code produced with -O2

2023-11-02 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112346 --- Comment #4 from Fedor Chelnokov --- According to referenced stackoverflow discussion, the code is reduced from https://github.com/vermaseren/form see https://github.com/vermaseren/form/issues/461

[Bug c/112346] New: Wrong code produced with -O2

2023-11-02 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112346 Bug ID: 112346 Summary: Wrong code produced with -O2 Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assig

[Bug c++/94264] Array-to-pointer conversion not performed on array prvalues

2023-10-08 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94264 Fedor Chelnokov changed: What|Removed |Added CC||fchelnokov at gmail dot com --- Commen

[Bug libstdc++/111685] Segfault while sorting on array element address

2023-10-06 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111685 --- Comment #12 from Fedor Chelnokov --- Related discussion: https://stackoverflow.com/q/77224270/7325599

[Bug libstdc++/111685] Segfault while sorting on array element address

2023-10-04 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111685 --- Comment #10 from Fedor Chelnokov --- It seems that both libc++ and MS STL implement std::sort without a temporary object passed to cmp, because they are fine with compiling the following code in constant expression (where unrelated pointers

[Bug tree-optimization/104165] [12 Regression] -Warray-bounds for unreachable code inlined from std::sort()

2023-09-27 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104165 --- Comment #10 from Fedor Chelnokov --- This issue happens in GCC 13.2 as well: https://godbolt.org/z/TfGx3YccG

[Bug c++/104661] [C++17+] Catching exception by const value when exception-object has lvalue-reference constructor

2023-09-01 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104661 --- Comment #3 from Fedor Chelnokov --- Related discussion: https://stackoverflow.com/a/77021213/7325599

[Bug c++/111132] New: Function redeclaration in local scope breaks constant expression evaluation

2023-08-24 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=32 Bug ID: 32 Summary: Function redeclaration in local scope breaks constant expression evaluation Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity:

[Bug c++/111113] New: Cannot define friend function of a local class in namespace scope

2023-08-23 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=13 Bug ID: 13 Summary: Cannot define friend function of a local class in namespace scope Product: gcc Version: 13.2.1 Status: UNCONFIRMED Severity: normal

[Bug c++/110619] Dangling pointer returned from constexpr function converts in nullptr

2023-08-07 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110619 --- Comment #8 from Fedor Chelnokov --- Please note that GCC 13 also accepts invalid program (because dangling pointers were converted in nullptr): constexpr auto f(int a) { return &a; } constexpr auto g(int b) { return &b; } static_a

[Bug c++/110642] New: Undefined behavior in same constant expression is found not always

2023-07-12 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110642 Bug ID: 110642 Summary: Undefined behavior in same constant expression is found not always Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity: normal

[Bug c++/110619] Dangling pointer returned from constexpr function converts in nullptr

2023-07-10 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110619 --- Comment #3 from Fedor Chelnokov --- I think according to https://eel.is/c++draft/basic.stc#general-4 the function shall return an "invalid pointer valued". And nullptr is not considered such. And if one modifies the function slightly (see a

[Bug c++/110619] New: Dangling pointer returned from constexpr function converts in nullptr

2023-07-10 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110619 Bug ID: 110619 Summary: Dangling pointer returned from constexpr function converts in nullptr Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity: normal

[Bug c++/110584] New: Constant is not visible in nested lambda

2023-07-07 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110584 Bug ID: 110584 Summary: Constant is not visible in nested lambda Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++

[Bug c++/110570] New: Error reading mutable subobject in constexpr when object lifetime began within the evaluation of E

2023-07-06 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110570 Bug ID: 110570 Summary: Error reading mutable subobject in constexpr when object lifetime began within the evaluation of E Product: gcc Version: 13.1.0 Status: UNCONFIRM

[Bug c++/110513] New: Invalid use of incomplete type std::bool_constant inside requires expression

2023-07-01 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110513 Bug ID: 110513 Summary: Invalid use of incomplete type std::bool_constant inside requires expression Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity:

[Bug c++/110463] [13/14 Regression] Mutable subobject is usable in a constant expression

2023-07-01 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110463 --- Comment #5 from Fedor Chelnokov --- Thanks a lot for a very quick fix!

[Bug c++/110497] New: Wrong error on non-static data member referenced in concept definition

2023-06-30 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110497 Bug ID: 110497 Summary: Wrong error on non-static data member referenced in concept definition Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity: norma

[Bug c++/110463] New: Mutable subobject is usable in a constant expression

2023-06-28 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110463 Bug ID: 110463 Summary: Mutable subobject is usable in a constant expression Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Comp

[Bug c++/110416] New: Error initializing of const union variable with a mutable field

2023-06-26 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110416 Bug ID: 110416 Summary: Error initializing of const union variable with a mutable field Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity: normal

[Bug c++/110191] New: Alias template in function parameter does not match the nested type it refers to

2023-06-09 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110191 Bug ID: 110191 Summary: Alias template in function parameter does not match the nested type it refers to Product: gcc Version: 13.1.0 Status: UNCONFIRMED Sever

[Bug libstdc++/110158] New: Cannot use union with std::string inside in constant expression

2023-06-07 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110158 Bug ID: 110158 Summary: Cannot use union with std::string inside in constant expression Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity: normal

[Bug c++/110114] New: ICE on calling overloaded function in case of incomplete argument type

2023-06-04 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110114 Bug ID: 110114 Summary: ICE on calling overloaded function in case of incomplete argument type Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity: norma

[Bug c++/109833] New: The value of constexpr anonymous union can be changed in runtime

2023-05-12 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109833 Bug ID: 109833 Summary: The value of constexpr anonymous union can be changed in runtime Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity: normal

[Bug c++/109523] New: List-initializing constructor of std::vector is selected erroneously

2023-04-15 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109523 Bug ID: 109523 Summary: List-initializing constructor of std::vector is selected erroneously Product: gcc Version: 12.2.1 Status: UNCONFIRMED Severity: normal

[Bug c++/109159] New: explicit constructor is used in copy-initialization

2023-03-16 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109159 Bug ID: 109159 Summary: explicit constructor is used in copy-initialization Product: gcc Version: 12.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Compo

[Bug c++/108588] __is_constructible returns wrong value for invalid (but non deleted) default constructor

2023-02-08 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108588 --- Comment #1 from Fedor Chelnokov --- According to this StackOverflow answer, the behavior of GCC is incorrect here: https://stackoverflow.com/a/75380301/7325599

[Bug c++/108364] New: Construction from prvalue erroneously uses move-constructor

2023-01-10 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108364 Bug ID: 108364 Summary: Construction from prvalue erroneously uses move-constructor Product: gcc Version: 12.2.1 Status: UNCONFIRMED Severity: normal

[Bug c++/107782] New: constexpr volatile variable is permitted to appear in a constant expression

2022-11-20 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107782 Bug ID: 107782 Summary: constexpr volatile variable is permitted to appear in a constant expression Product: gcc Version: 12.2.1 Status: UNCONFIRMED Severity:

[Bug c++/107744] New: Error in constant evaluation of dynamic_cast

2022-11-17 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107744 Bug ID: 107744 Summary: Error in constant evaluation of dynamic_cast Product: gcc Version: 12.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c

[Bug c++/107509] New: wrong ambiguous overloaded function error if argument class is undefined

2022-11-02 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107509 Bug ID: 107509 Summary: wrong ambiguous overloaded function error if argument class is undefined Product: gcc Version: 12.2.0 Status: UNCONFIRMED Severity: nor

[Bug c++/107124] Reference template parameter refers to a temporary object

2022-10-30 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107124 --- Comment #3 from Fedor Chelnokov --- The latter example is indeed a bug in MSVC: https://developercommunity.visualstudio.com/t/Cannot-find-template-function-with-expli/1672180 And here is the related discussion according the original issue:

[Bug c++/107168] New: Wrong errors for concepts with default lambda not-type argument

2022-10-06 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107168 Bug ID: 107168 Summary: Wrong errors for concepts with default lambda not-type argument Product: gcc Version: 12.2.0 Status: UNCONFIRMED Severity: normal

[Bug c++/101670] Internal compiler error with concepts

2022-10-05 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101670 --- Comment #3 from Fedor Chelnokov --- A shorter example: template concept x = true; void foo(x auto) {} Online demo: https://godbolt.org/z/sT74G8crE

[Bug c++/107124] New: Reference template parameter refers to a temporary object

2022-10-02 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107124 Bug ID: 107124 Summary: Reference template parameter refers to a temporary object Product: gcc Version: 12.2.0 Status: UNCONFIRMED Severity: normal P

[Bug c++/106968] New: ignored noexcept(false) in explicitly-defaulted functions

2022-09-19 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106968 Bug ID: 106968 Summary: ignored noexcept(false) in explicitly-defaulted functions Product: gcc Version: 12.1.0 Status: UNCONFIRMED Severity: normal P

[Bug c++/106599] Wrong copy elision in delegating to copy-constructor

2022-08-22 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106599 --- Comment #4 from Fedor Chelnokov --- And if one deletes copy constructor of A: struct A { constexpr A() = default; constexpr A(const A&) = delete; constexpr A(int) : A(A()) {} }; A a(2); Then Clang rejects the program, b

[Bug libstdc++/106695] New: Regression 11,12: Explicit copy constructor does not work for a parameter passed via std::async

2022-08-20 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106695 Bug ID: 106695 Summary: Regression 11,12: Explicit copy constructor does not work for a parameter passed via std::async Product: gcc Version: 12.1.0 Status: UNCONFIRMED

[Bug c++/106599] New: Wrong copy elision in delegating to copy-constructor

2022-08-12 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106599 Bug ID: 106599 Summary: Wrong copy elision in delegating to copy-constructor Product: gcc Version: 12.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Comp

[Bug tree-optimization/106247] GCC12 warning in Eigen: array subscript is partly outside array bounds

2022-07-10 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106247 Fedor Chelnokov changed: What|Removed |Added CC||fchelnokov at gmail dot com --- Comme

[Bug c++/106247] New: GCC12 warning in Eigen: array subscript is partly outside array bounds

2022-07-10 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106247 Bug ID: 106247 Summary: GCC12 warning in Eigen: array subscript is partly outside array bounds Product: gcc Version: 12.1.0 Status: UNCONFIRMED Severity: norma

[Bug c++/105699] [Concepts] Constrained virtual functions are accepted by GCC

2022-05-24 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105699 --- Comment #2 from Fedor Chelnokov --- Another aspect is that the order of destructors in the class change its behavior: #include template struct X { ~X() requires (N==1); virtual ~X(); }; // X is NOT polymorphic in GCC static_assert( !

[Bug c++/105693] New: Requires-clause constructor is not selected

2022-05-22 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105693 Bug ID: 105693 Summary: Requires-clause constructor is not selected Product: gcc Version: 12.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++

  1   2   3   >