[Bug c/39456] New: Functions of a file in different named sections
etienne_lorrain at yahoo dot fr
gcc-bugzilla@gcc.gnu.org
Fri Mar 13 14:03:00 GMT 2009
Just that I need to set each functions in a C file into different sections,
with section names I can link in different segments.
That can be done with:
__attribute__ ((section ("sect1_fct1"))) void fct1 (void) {}
__attribute__ ((section ("sect1_fct2"))) void fct2 (void) {}
But cannot unfortunately be done in a macro like:
__attribute__ ((section ("sect1_" __FUNCTION__ ))) void fct1 (void) {}
It would be nice to have some way to do that, like:
__attribute__ ((section_prepend ("sect1_"))) void fct1 (void) {}
so that a bad cut&paste somewhere do not create problems because
a function is in the wrong section (by forgeting to change the
concat'ed string).
--
Summary: Functions of a file in different named sections
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: enhancement
Priority: P3
Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: etienne_lorrain at yahoo dot fr
GCC build triplet: all-all-all
GCC host triplet: all-all-all
GCC target triplet: all-all-all
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39456
More information about the Gcc-bugs
mailing list