public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libstdc++/103726] --disable-hosted-libstdcxx (freestanding C++) does not provide <coroutine> as what standard requires
Date: Tue, 11 Jan 2022 13:29:39 +0000	[thread overview]
Message-ID: <bug-103726-4-lOZ0c73OEg@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-103726-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #12 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jonathan Wakely <redi@gcc.gnu.org>:

https://gcc.gnu.org/g:265d3e1a4e3d6c71d354f859302f023dc2d33f62

commit r12-6474-g265d3e1a4e3d6c71d354f859302f023dc2d33f62
Author: Jonathan Wakely <jwakely@redhat.com>
Date:   Mon Jan 10 20:48:53 2022 +0000

    libstdc++: Install <coroutine> header for freestanding [PR103726]

    The standard says that <coroutine> should be present for freestanding.
    That was intentionally left out of the initial implementation, but can
    be done without much trouble. The header should be moved to libsupc++ at
    some point in stage 1.

    The standard also says that <coroutine> defines a std::hash
    specialization, which was missing from our implementation. That's a
    problem for freestanding (see LWG 3653) so only do that for hosted.

    We can use concepts to constrain the __coroutine_traits_impl base class
    when compiled with concepts enabled. In a pure C++20 implementation we
    would not need that base class at all and could just use a constrained
    partial specialization of coroutine_traits. But the absence of the
    __coroutine_traits_impl<R, void> base would create an ABI difference
    between the non-standard C++14/C++17 support for coroutines and the same
    code compiled as C++20. If we drop support for <coroutine> pre-C++20 we
    should revisit this.

    libstdc++-v3/ChangeLog:

            PR libstdc++/103726
            * include/Makefile.am: Install <coroutine> for freestanding.
            * include/Makefile.in: Regenerate.
            * include/std/coroutine: Adjust headers and preprocessor
            conditions.
            (__coroutine_traits_impl): Use concepts when available.
            [_GLIBCXX_HOSTED] (hash<coroutine_handle>): Define.

  parent reply	other threads:[~2022-01-11 13:29 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-15  4:23 [Bug libstdc++/103726] New: " unlvsur at live dot com
2021-12-15  8:09 ` [Bug libstdc++/103726] " redi at gcc dot gnu.org
2021-12-15 21:10 ` unlvsur at live dot com
2021-12-15 21:36 ` redi at gcc dot gnu.org
2021-12-15 21:36 ` unlvsur at live dot com
2021-12-15 21:39 ` redi at gcc dot gnu.org
2021-12-15 21:39 ` unlvsur at live dot com
2021-12-15 23:42 ` de34 at live dot cn
2021-12-15 23:46 ` redi at gcc dot gnu.org
2021-12-15 23:54 ` unlvsur at live dot com
2022-01-10 21:14 ` redi at gcc dot gnu.org
2022-01-11  4:13 ` unlvsur at live dot com
2022-01-11 11:26 ` redi at gcc dot gnu.org
2022-01-11 13:29 ` cvs-commit at gcc dot gnu.org [this message]
2022-01-11 13:31 ` redi at gcc dot gnu.org
2022-01-11 17:16 ` unlvsur at live dot com
2022-01-11 17:16 ` unlvsur at live dot com
2022-01-11 17:31 ` redi at gcc dot gnu.org
2022-01-11 17:37 ` unlvsur at live dot com
2022-01-11 17:52 ` redi at gcc dot gnu.org
2022-01-11 18:36 ` cvs-commit at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-103726-4-lOZ0c73OEg@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).