public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/101224] New: Problem with interaction of modules and std::unique_ptr
@ 2021-06-26 14:36 p.cross13 at yahoo dot com
  2024-03-08 16:03 ` [Bug c++/101224] " ppalka at gcc dot gnu.org
  0 siblings, 1 reply; 2+ messages in thread
From: p.cross13 at yahoo dot com @ 2021-06-26 14:36 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 101224
           Summary: Problem with interaction of modules and
                    std::unique_ptr
           Product: gcc
           Version: 11.1.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: p.cross13 at yahoo dot com
  Target Milestone: ---

Created attachment 51063
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=51063&action=edit
main program file with two module files included in comments, plus compiler
output and compiler version in comments

Code that compiles without modules, and uses std::unique_ptr, has a problem
when parts of the code are moved to modules

$ /d/gcc11/bin/g++ -std=c++20 -fmodules-ts  FmtMain.cpp
In file included from d:\gcc11\include\c++\11.1.0\memory:76,
                 from FmtMain.cpp:1:
d:\gcc11\include\c++\11.1.0\bits\unique_ptr.h: In instantiation of 'void
std::default_delete<_Tp>::operator()(_Tp*) const [with _Tp = Fmt1@Fmt1]':
d:\gcc11\include\c++\11.1.0\bits\unique_ptr.h:361:17:   required from
'std::unique_ptr<_Tp, _Dp>::~unique_ptr() [with _Tp = Fmt1@Fmt1; _Dp =
std::default_delete<Fmt1@Fmt1>]'
FmtMain.cpp:24:24:   required from here
d:\gcc11\include\c++\11.1.0\bits\unique_ptr.h:85:9: error: array subscript is
not an integer
   85 |         delete __ptr;
      |         ^~~~~~~~~~~~

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

* [Bug c++/101224] Problem with interaction of modules and std::unique_ptr
  2021-06-26 14:36 [Bug c++/101224] New: Problem with interaction of modules and std::unique_ptr p.cross13 at yahoo dot com
@ 2024-03-08 16:03 ` ppalka at gcc dot gnu.org
  0 siblings, 0 replies; 2+ messages in thread
From: ppalka at gcc dot gnu.org @ 2024-03-08 16:03 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
                 CC|                            |ppalka at gcc dot gnu.org
         Resolution|---                         |DUPLICATE

--- Comment #1 from Patrick Palka <ppalka at gcc dot gnu.org> ---
Fixed for GCC 14 by the PR103499 fix.

*** This bug has been marked as a duplicate of bug 103499 ***

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

end of thread, other threads:[~2024-03-08 16:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-26 14:36 [Bug c++/101224] New: Problem with interaction of modules and std::unique_ptr p.cross13 at yahoo dot com
2024-03-08 16:03 ` [Bug c++/101224] " 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).