public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug c++/109679] New: export using for functions does not work as specified @ 2023-04-29 8:37 nico at josuttis dot de 2023-04-29 21:38 ` [Bug c++/109679] " pinskia at gcc dot gnu.org ` (5 more replies) 0 siblings, 6 replies; 7+ messages in thread From: nico at josuttis dot de @ 2023-04-29 8:37 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109679 Bug ID: 109679 Summary: export using for functions does not work as specified Product: gcc Version: 13.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: nico at josuttis dot de Target Milestone: --- Consider the following simple module export scenario to wrap a header file in a module: //***** foo.hpp: #ifndef FOO_HPP #define FOO_HPP inline int foo() { return 42; } #endif // FOO_HPP //***** foomod.cppm: module; #include "foo.hpp" export module FooMod; export using ::foo; //***** testfoo.cpp: import FooMod; int main() { return foo(); } According to the example 2 in "6.6 Program and linkage [basic.link]" and example 2 in "10.2 Export declaration [module.interface]" this should work (function f() in both examples). This is an important feature because it alows programmers to softly migrate header files to modules. ^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/109679] export using for functions does not work as specified 2023-04-29 8:37 [Bug c++/109679] New: export using for functions does not work as specified nico at josuttis dot de @ 2023-04-29 21:38 ` pinskia at gcc dot gnu.org 2023-05-02 14:33 ` redi at gcc dot gnu.org ` (4 subsequent siblings) 5 siblings, 0 replies; 7+ messages in thread From: pinskia at gcc dot gnu.org @ 2023-04-29 21:38 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109679 --- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- modules in GCC is still an experimental feature really. And still being developed. ^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/109679] export using for functions does not work as specified 2023-04-29 8:37 [Bug c++/109679] New: export using for functions does not work as specified nico at josuttis dot de 2023-04-29 21:38 ` [Bug c++/109679] " pinskia at gcc dot gnu.org @ 2023-05-02 14:33 ` redi at gcc dot gnu.org 2023-12-25 13:12 ` admin at hexadigm dot com ` (3 subsequent siblings) 5 siblings, 0 replies; 7+ messages in thread From: redi at gcc dot gnu.org @ 2023-05-02 14:33 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109679 Jonathan Wakely <redi at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Last reconfirmed| |2023-05-02 Status|UNCONFIRMED |NEW Ever confirmed|0 |1 Keywords| |rejects-valid --- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> --- Confirmed. testfoo.cpp: In function 'int main()': testfoo.cpp:5:10: error: 'foo' was not declared in this scope 5 | return foo(); | ^~~ ^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/109679] export using for functions does not work as specified 2023-04-29 8:37 [Bug c++/109679] New: export using for functions does not work as specified nico at josuttis dot de 2023-04-29 21:38 ` [Bug c++/109679] " pinskia at gcc dot gnu.org 2023-05-02 14:33 ` redi at gcc dot gnu.org @ 2023-12-25 13:12 ` admin at hexadigm dot com 2024-01-07 10:52 ` cvs-commit at gcc dot gnu.org ` (2 subsequent siblings) 5 siblings, 0 replies; 7+ messages in thread From: admin at hexadigm dot com @ 2023-12-25 13:12 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109679 Larry Smith <admin at hexadigm dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |admin at hexadigm dot com --- Comment #3 from Larry Smith <admin at hexadigm dot com> --- Likely the same issue I reported here (didn't see yours before posting): https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113129 ^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/109679] export using for functions does not work as specified 2023-04-29 8:37 [Bug c++/109679] New: export using for functions does not work as specified nico at josuttis dot de ` (2 preceding siblings ...) 2023-12-25 13:12 ` admin at hexadigm dot com @ 2024-01-07 10:52 ` cvs-commit at gcc dot gnu.org 2024-01-27 10:21 ` nshead at gcc dot gnu.org 2024-01-27 10:28 ` nshead at gcc dot gnu.org 5 siblings, 0 replies; 7+ messages in thread From: cvs-commit at gcc dot gnu.org @ 2024-01-07 10:52 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109679 --- Comment #4 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Nathaniel Shead <nshead@gcc.gnu.org>: https://gcc.gnu.org/g:63b531e6f8783e8624502d890dc422379de47a9a commit r14-6978-g63b531e6f8783e8624502d890dc422379de47a9a Author: Nathaniel Shead <nathanieloshead@gmail.com> Date: Wed Jan 3 15:29:51 2024 +1100 c++: Export usings referring to global module fragment [PR109679] This patch stops 'add_binding_entity' from ignoring all names in the global module fragment, since they should still be exported if named in an exported using-declaration. PR c++/109679 gcc/cp/ChangeLog: * module.cc (depset::hash::add_binding_entity): Don't skip names in the GMF if they've been exported with a using declaration. gcc/testsuite/ChangeLog: * g++.dg/modules/using-11.h: New test. * g++.dg/modules/using-11_a.C: New test. * g++.dg/modules/using-11_b.C: New test. Signed-off-by: Nathaniel Shead <nathanieloshead@gmail.com> ^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/109679] export using for functions does not work as specified 2023-04-29 8:37 [Bug c++/109679] New: export using for functions does not work as specified nico at josuttis dot de ` (3 preceding siblings ...) 2024-01-07 10:52 ` cvs-commit at gcc dot gnu.org @ 2024-01-27 10:21 ` nshead at gcc dot gnu.org 2024-01-27 10:28 ` nshead at gcc dot gnu.org 5 siblings, 0 replies; 7+ messages in thread From: nshead at gcc dot gnu.org @ 2024-01-27 10:21 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109679 Nathaniel Shead <nshead at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Assignee|unassigned at gcc dot gnu.org |nshead at gcc dot gnu.org Status|NEW |RESOLVED Target Milestone|--- |14.0 CC| |nshead at gcc dot gnu.org --- Comment #5 from Nathaniel Shead <nshead at gcc dot gnu.org> --- Fixed for GCC 14. ^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/109679] export using for functions does not work as specified 2023-04-29 8:37 [Bug c++/109679] New: export using for functions does not work as specified nico at josuttis dot de ` (4 preceding siblings ...) 2024-01-27 10:21 ` nshead at gcc dot gnu.org @ 2024-01-27 10:28 ` nshead at gcc dot gnu.org 5 siblings, 0 replies; 7+ messages in thread From: nshead at gcc dot gnu.org @ 2024-01-27 10:28 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109679 --- Comment #6 from Nathaniel Shead <nshead at gcc dot gnu.org> --- *** Bug 113129 has been marked as a duplicate of this bug. *** ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2024-01-27 10:28 UTC | newest] Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2023-04-29 8:37 [Bug c++/109679] New: export using for functions does not work as specified nico at josuttis dot de 2023-04-29 21:38 ` [Bug c++/109679] " pinskia at gcc dot gnu.org 2023-05-02 14:33 ` redi at gcc dot gnu.org 2023-12-25 13:12 ` admin at hexadigm dot com 2024-01-07 10:52 ` cvs-commit at gcc dot gnu.org 2024-01-27 10:21 ` nshead at gcc dot gnu.org 2024-01-27 10:28 ` nshead 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).