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 modula2/108183] wrong code generated in the modula2 scaffold mechanism Date: Wed, 04 Jan 2023 14:55:01 +0000 [thread overview] Message-ID: <bug-108183-4-o7Cvxh8clJ@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-108183-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108183 --- Comment #21 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Iain D Sandoe <iains@gcc.gnu.org>: https://gcc.gnu.org/g:ec6d1fc09faea4a6be4df74babb73dca6b50ff0c commit r13-4996-gec6d1fc09faea4a6be4df74babb73dca6b50ff0c Author: Iain Sandoe <iain@sandoe.co.uk> Date: Fri Dec 30 19:46:13 2022 +0000 modula-2: Fix registration of modules via constructors [PR108183]. This reworks the mechanism used for module registration to use init- time constructors. The order of registration is not important, the actual initialization dependency tree will be computed early in the execution (all that matters is that we have registered before that). This fixes a potential issue in which the external name known to the m2 system is of the form _M2_XXXXXX_ctor() but the C++ code was producing a static variable instance with the same name. Signed-off-by: Iain Sandoe <iain@sandoe.co.uk> PR modula2/108183 gcc/m2/ChangeLog: * gm2-libs-ch/UnixArgs.cc (_M2_UnixArgs_ctor): Rework to use an extern "C" function with 'constructor' attribute. * gm2-libs-ch/dtoa.cc (_M2_dtoa_ctor): Likewise. * gm2-libs-ch/ldtoa.cc (_M2_ldtoa_ctor): Likewise. libgm2/ChangeLog: * libm2cor/KeyBoardLEDs.cc (_M2_KeyBoardLEDs_ctor): Rework to use an extern "C" function with 'constructor' attribute. * libm2iso/ErrnoCategory.cc (_M2_ErrnoCategory_ctor): Likewise. * libm2iso/RTco.cc (_M2_RTco_ctor): Likewise. * libm2pim/Selective.cc (_M2_Selective_ctor): Likewise. * libm2pim/SysExceptions.cc (_M2_SysExceptions_ctor): Likewise. * libm2pim/UnixArgs.cc (_M2_UnixArgs_ctor): Likewise. * libm2pim/cgetopt.cc (_M2_cgetopt_ctor): Likewise. * libm2pim/dtoa.cc (_M2_dtoa_ctor): Likewise. * libm2pim/errno.cc (_M2_errno_ctor): Likewise. * libm2pim/ldtoa.cc (_M2_ldtoa_ctor): Likewise. * libm2pim/sckt.cc (_M2_sckt_ctor): Likewise. * libm2pim/termios.cc (_M2_termios_ctor): Likewise. * libm2pim/wrapc.c: Add a new line to the file end.
next prev parent reply other threads:[~2023-01-04 14:55 UTC|newest] Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-12-19 23:45 [Bug modula2/108183] New: " iains at gcc dot gnu.org 2022-12-19 23:46 ` [Bug modula2/108183] " iains at gcc dot gnu.org 2022-12-19 23:57 ` iains at gcc dot gnu.org 2022-12-20 8:20 ` gaius at gcc dot gnu.org 2022-12-20 8:38 ` gaius at gcc dot gnu.org 2022-12-20 9:36 ` iains at gcc dot gnu.org 2022-12-20 10:00 ` iains at gcc dot gnu.org 2022-12-20 12:34 ` iains at gcc dot gnu.org 2022-12-20 12:37 ` iains at gcc dot gnu.org 2022-12-20 12:45 ` rguenth at gcc dot gnu.org 2022-12-20 20:21 ` iains at gcc dot gnu.org 2022-12-20 20:42 ` iains at gcc dot gnu.org 2022-12-20 21:24 ` gaius at gcc dot gnu.org 2022-12-21 15:35 ` iains at gcc dot gnu.org 2022-12-21 15:39 ` iains at gcc dot gnu.org 2022-12-24 17:19 ` iains at gcc dot gnu.org 2022-12-28 16:07 ` gaius at gcc dot gnu.org 2022-12-31 12:54 ` iains at gcc dot gnu.org 2022-12-31 12:57 ` iains at gcc dot gnu.org 2023-01-01 9:29 ` cvs-commit at gcc dot gnu.org 2023-01-02 11:21 ` iains at gcc dot gnu.org 2023-01-02 12:20 ` iains at gcc dot gnu.org 2023-01-04 14:55 ` cvs-commit at gcc dot gnu.org [this message] 2023-01-04 16:22 ` iains 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-108183-4-o7Cvxh8clJ@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: linkBe 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).