public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/109111] New: Definition of repeat_view::_Iterator has wrong template-head
@ 2023-03-13 17:57 rs2740 at gmail dot com
  2023-03-13 19:05 ` [Bug libstdc++/109111] " john at drouhard dot dev
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: rs2740 at gmail dot com @ 2023-03-13 17:57 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109111

            Bug ID: 109111
           Summary: Definition of repeat_view::_Iterator has wrong
                    template-head
           Product: gcc
           Version: 13.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libstdc++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: rs2740 at gmail dot com
  Target Milestone: ---

In <ranges>:


  template<copy_constructible _Tp, semiregular _Bound = unreachable_sentinel_t>
    requires (is_object_v<_Tp> && same_as<_Tp, remove_cv_t<_Tp>>
      && (__detail::__is_integer_like<_Bound> || same_as<_Bound,
unreachable_sentinel_t>))
  class repeat_view : /* ... */


  template<copy_constructible _Tp, semiregular _Bound>
    requires __detail::__is_integer_like<_Bound> || same_as<_Bound,
unreachable_sentinel_t>
  class repeat_view<_Tp, _Bound>::_Iterator

The requires-clause should match.

Clang trunk diagnoses this (but not GCC, so there's probably a compiler bug
here too).

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug libstdc++/109111] Definition of repeat_view::_Iterator has wrong template-head
  2023-03-13 17:57 [Bug libstdc++/109111] New: Definition of repeat_view::_Iterator has wrong template-head rs2740 at gmail dot com
@ 2023-03-13 19:05 ` john at drouhard dot dev
  2023-03-13 20:25 ` ppalka at gcc dot gnu.org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: john at drouhard dot dev @ 2023-03-13 19:05 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109111

--- Comment #1 from John Drouhard <john at drouhard dot dev> ---
https://godbolt.org/z/csozden6e

example of gcc not diagnosing mismatched requires clauses (and clang correctly
doing so).

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug libstdc++/109111] Definition of repeat_view::_Iterator has wrong template-head
  2023-03-13 17:57 [Bug libstdc++/109111] New: Definition of repeat_view::_Iterator has wrong template-head rs2740 at gmail dot com
  2023-03-13 19:05 ` [Bug libstdc++/109111] " john at drouhard dot dev
@ 2023-03-13 20:25 ` ppalka at gcc dot gnu.org
  2023-03-14 23:18 ` cvs-commit at gcc dot gnu.org
  2023-03-14 23:26 ` ppalka at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: ppalka at gcc dot gnu.org @ 2023-03-13 20:25 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109111

Patrick Palka <ppalka at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |13.0
           Assignee|unassigned at gcc dot gnu.org      |ppalka at gcc dot gnu.org
                 CC|                            |ppalka at gcc dot gnu.org
           See Also|                            |https://gcc.gnu.org/bugzill
                   |                            |a/show_bug.cgi?id=96830
   Last reconfirmed|                            |2023-03-13
             Status|UNCONFIRMED                 |ASSIGNED
     Ever confirmed|0                           |1

--- Comment #2 from Patrick Palka <ppalka at gcc dot gnu.org> ---
Confirmed, the corresponding compiler bug is PR96830

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug libstdc++/109111] Definition of repeat_view::_Iterator has wrong template-head
  2023-03-13 17:57 [Bug libstdc++/109111] New: Definition of repeat_view::_Iterator has wrong template-head rs2740 at gmail dot com
  2023-03-13 19:05 ` [Bug libstdc++/109111] " john at drouhard dot dev
  2023-03-13 20:25 ` ppalka at gcc dot gnu.org
@ 2023-03-14 23:18 ` cvs-commit at gcc dot gnu.org
  2023-03-14 23:26 ` ppalka at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-03-14 23:18 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109111

--- Comment #3 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Patrick Palka <ppalka@gcc.gnu.org>:

https://gcc.gnu.org/g:578f633ddabd62b41beed635697c95ee2aaa39c0

commit r13-6675-g578f633ddabd62b41beed635697c95ee2aaa39c0
Author: Patrick Palka <ppalka@redhat.com>
Date:   Tue Mar 14 19:06:33 2023 -0400

    libstdc++: Fix template-head of repeat_view::_Iterator [PR109111]

            PR libstdc++/109111

    libstdc++-v3/ChangeLog:

            * include/std/ranges (repeat_view): Remove redundant parentheses
            in requires-clause.
            (repeat_view::_Iterator): Correct the requires-clause.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug libstdc++/109111] Definition of repeat_view::_Iterator has wrong template-head
  2023-03-13 17:57 [Bug libstdc++/109111] New: Definition of repeat_view::_Iterator has wrong template-head rs2740 at gmail dot com
                   ` (2 preceding siblings ...)
  2023-03-14 23:18 ` cvs-commit at gcc dot gnu.org
@ 2023-03-14 23:26 ` ppalka at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: ppalka at gcc dot gnu.org @ 2023-03-14 23:26 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109111

Patrick Palka <ppalka at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|ASSIGNED                    |RESOLVED

--- Comment #4 from Patrick Palka <ppalka at gcc dot gnu.org> ---
Fixed (along with PR96830)

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-03-14 23:26 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-13 17:57 [Bug libstdc++/109111] New: Definition of repeat_view::_Iterator has wrong template-head rs2740 at gmail dot com
2023-03-13 19:05 ` [Bug libstdc++/109111] " john at drouhard dot dev
2023-03-13 20:25 ` ppalka at gcc dot gnu.org
2023-03-14 23:18 ` cvs-commit at gcc dot gnu.org
2023-03-14 23:26 ` ppalka at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).