modula2: Ensure that module registration constructors are 'extern' [PR108183].
authorIain Sandoe <iain@sandoe.co.uk>
Wed, 21 Dec 2022 09:05:32 +0000 (09:05 +0000)
committerIain Sandoe <iain@sandoe.co.uk>
Sun, 1 Jan 2023 09:29:07 +0000 (09:29 +0000)
commitd423e8dc59045d8f281dcb1a02559cb6f91456bf
tree088b25509669b82ce774366aeeee36662a457631
parent90323d0b4b9f7eeba6c044498346257db82fb024
modula2: Ensure that module registration constructors are 'extern' [PR108183].

The symbols for module registration constructors need to be external
or we get wrong code generated for targets that allow direct access to
local symbol definitions.

Signed-off-by: Iain Sandoe <iain@sandoe.co.uk>
PR modula2/108183

gcc/m2/ChangeLog:

* gm2-compiler/M2GCCDeclare.mod: Module registration constructors are
externs to the builder of m2_link.

Co-Authored-By: Gaius Mulley <gaiusmod2@gmail.com>
gcc/m2/gm2-compiler/M2GCCDeclare.mod