public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/102026] New: The comment on the instantiation description of __variant::__gen_vtable_impl can be updated
@ 2021-08-23 15:04 hewillk at gmail dot com
  2021-08-23 15:29 ` [Bug libstdc++/102026] " redi at gcc dot gnu.org
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: hewillk at gmail dot com @ 2021-08-23 15:04 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 102026
           Summary: The comment on the instantiation description of
                    __variant::__gen_vtable_impl can be updated
           Product: gcc
           Version: 12.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libstdc++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: hewillk at gmail dot com
  Target Milestone: ---

This is not a bug, this is just something that can be improved.

Since the template parameter of __gen_vtable_impl no longer has _Variant_tuple,
 it will be more friendly to those who love to read the source code if the
comment of
https://github.com/gcc-mirror/gcc/blob/master/libstdc%2B%2B-v3/include/std/variant#L875-L901
is updated. ;-)

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

* [Bug libstdc++/102026] The comment on the instantiation description of __variant::__gen_vtable_impl can be updated
  2021-08-23 15:04 [Bug libstdc++/102026] New: The comment on the instantiation description of __variant::__gen_vtable_impl can be updated hewillk at gmail dot com
@ 2021-08-23 15:29 ` redi at gcc dot gnu.org
  2021-08-23 15:45 ` hewillk at gmail dot com
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: redi at gcc dot gnu.org @ 2021-08-23 15:29 UTC (permalink / raw)
  To: gcc-bugs

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

Jonathan Wakely <redi at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2021-08-23
     Ever confirmed|0                           |1
           Keywords|                            |documentation

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

* [Bug libstdc++/102026] The comment on the instantiation description of __variant::__gen_vtable_impl can be updated
  2021-08-23 15:04 [Bug libstdc++/102026] New: The comment on the instantiation description of __variant::__gen_vtable_impl can be updated hewillk at gmail dot com
  2021-08-23 15:29 ` [Bug libstdc++/102026] " redi at gcc dot gnu.org
@ 2021-08-23 15:45 ` hewillk at gmail dot com
  2021-08-23 16:04 ` redi at gcc dot gnu.org
  2021-08-29 16:40 ` hewillk at gmail dot com
  3 siblings, 0 replies; 5+ messages in thread
From: hewillk at gmail dot com @ 2021-08-23 15:45 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #1 from 康桓瑋 <hewillk at gmail dot com> ---
Another thing that seems noteworthy is in variant#L402:

     void _M_reset()
      {
        if (!_M_valid()) [[unlikely]]
          return;

We use C++20 attributes in the C++17 feature library, so I don’t know whether
we should use the underlined [[__unlikely__]] like we do in variant #L1310 or
it doesn’t matter.

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

* [Bug libstdc++/102026] The comment on the instantiation description of __variant::__gen_vtable_impl can be updated
  2021-08-23 15:04 [Bug libstdc++/102026] New: The comment on the instantiation description of __variant::__gen_vtable_impl can be updated hewillk at gmail dot com
  2021-08-23 15:29 ` [Bug libstdc++/102026] " redi at gcc dot gnu.org
  2021-08-23 15:45 ` hewillk at gmail dot com
@ 2021-08-23 16:04 ` redi at gcc dot gnu.org
  2021-08-29 16:40 ` hewillk at gmail dot com
  3 siblings, 0 replies; 5+ messages in thread
From: redi at gcc dot gnu.org @ 2021-08-23 16:04 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> ---
Yes, it should be [[__unlikely__]], thanks.

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

* [Bug libstdc++/102026] The comment on the instantiation description of __variant::__gen_vtable_impl can be updated
  2021-08-23 15:04 [Bug libstdc++/102026] New: The comment on the instantiation description of __variant::__gen_vtable_impl can be updated hewillk at gmail dot com
                   ` (2 preceding siblings ...)
  2021-08-23 16:04 ` redi at gcc dot gnu.org
@ 2021-08-29 16:40 ` hewillk at gmail dot com
  3 siblings, 0 replies; 5+ messages in thread
From: hewillk at gmail dot com @ 2021-08-29 16:40 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from 康桓瑋 <hewillk at gmail dot com> ---
It seems that all lambdas used in <variant> can remove the mutable keyword
since there are no members that need to be "mutable" inside the lambda.

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

end of thread, other threads:[~2021-08-29 16:40 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-23 15:04 [Bug libstdc++/102026] New: The comment on the instantiation description of __variant::__gen_vtable_impl can be updated hewillk at gmail dot com
2021-08-23 15:29 ` [Bug libstdc++/102026] " redi at gcc dot gnu.org
2021-08-23 15:45 ` hewillk at gmail dot com
2021-08-23 16:04 ` redi at gcc dot gnu.org
2021-08-29 16:40 ` hewillk at gmail dot com

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).