public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "ppalka at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/114600] [14 Regression] [modules] redefinition errors when using certain std headers in GMF
Date: Fri, 05 Apr 2024 12:55:11 +0000	[thread overview]
Message-ID: <bug-114600-4-gClGClSR9C@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-114600-4@http.gcc.gnu.org/bugzilla/>

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |nshead at gcc dot gnu.org,
                   |                            |ppalka at gcc dot gnu.org
           Keywords|                            |rejects-valid
   Target Milestone|---                         |14.0
             Blocks|                            |103524
            Summary|[modules] redefinition      |[14 Regression] [modules]
                   |errors when using certain   |redefinition errors when
                   |std headers in GMF          |using certain std headers
                   |                            |in GMF
     Ever confirmed|0                           |1
   Last reconfirmed|                            |2024-04-05
             Status|UNCONFIRMED                 |NEW

--- Comment #2 from Patrick Palka <ppalka at gcc dot gnu.org> ---
Confirmed, started with r14-6978.

Mechanical reduction:

$ cat 114600.h
namespace std {
template <typename> struct integral_constant {
  typedef integral_constant type;
};
template <bool> using __enable_if_t = int;
template <typename> auto __and_fn() -> integral_constant<bool>;
template <typename... _Bn> struct __and_ : decltype(__and_fn<_Bn...>) {};
template <typename... _Cond>
using _Require = __enable_if_t<__and_<_Cond...>::value>;
template <typename _Tp> _Require<_Tp> swap();
namespace __swappable_details {
using std::swap;
}
} // namespace std

$ cat 114600_a.C
module;

#include "114600.h"

export module std;

$ cat 114600_b.C
import std;

#include "114600.h"

int main()
{
}

$ g++ -fmodules-ts 114600_*.C
114600.h:3:29: error: template definition of non-template 'typedef struct
std::integral_constant< <template-parameter-1-1> > std::integral_constant<
<template-parameter-1-1> >::type'


Referenced Bugs:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103524
[Bug 103524] [meta-bug] modules issue

  parent reply	other threads:[~2024-04-05 12:55 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-05 10:07 [Bug c++/114600] New: " m.cencora at gmail dot com
2024-04-05 10:07 ` [Bug c++/114600] " m.cencora at gmail dot com
2024-04-05 12:55 ` ppalka at gcc dot gnu.org [this message]
2024-04-05 12:58 ` [Bug c++/114600] [14 Regression] " ppalka at gcc dot gnu.org
2024-04-05 13:10 ` nshead at gcc dot gnu.org
2024-04-05 13:33 ` ppalka at gcc dot gnu.org
2024-04-10 13:24 ` nshead at gcc dot gnu.org
2024-04-10 14:27 ` m.cencora at gmail dot com
2024-04-10 15:41 ` redi at gcc dot gnu.org
2024-04-10 20:55 ` m.cencora at gmail dot com
2024-04-10 21:03 ` m.cencora at gmail dot com
2024-04-15  8:26 ` cvs-commit at gcc dot gnu.org
2024-04-24 13:46 ` ppalka at gcc dot gnu.org
2024-04-24 13:50 ` ppalka 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-114600-4-gClGClSR9C@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).