This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [DOC Patch] symbol rename pragmas
- From: David Wohlferd <dw at LimeGreenSocks dot com>
- To: Rainer Orth <ro at CeBiTec dot Uni-Bielefeld dot DE>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, Gerald Pfeifer <gerald at pfeifer dot com>, Joseph Myers <joseph at codesourcery dot com>
- Date: Fri, 16 May 2014 18:23:50 -0700
- Subject: Re: [DOC Patch] symbol rename pragmas
- Authentication-results: sourceware.org; auth=none
- References: <5371412C dot 1010600 at LimeGreenSocks dot com> <yddegzy1asg dot fsf at CeBiTec dot Uni-Bielefeld dot DE> <5371FEE6 dot 8010702 at LimeGreenSocks dot com> <yddwqdp3o6d dot fsf at lokon dot CeBiTec dot Uni-Bielefeld dot DE> <53729E8F dot 3020507 at LimeGreenSocks dot com>
This patch is in response to Rainer Orth's comment (below).
I have a release on file with the FSF, but don't have SVN write access.
Problem description:
The (already committed) patch at the top of this thread removed a
reference to Solaris. It has been requested that this be restored to
show the origins of the directive and clarify "when to use it (or not)."
ChangeLog:
2014-05-16 David Wohlferd <dw@LimeGreenSocks.com>
* doc/extend.texi (Symbol-Renaming Pragmas): Restore (slightly
modified) reference to Solaris.
dw
keep documenting the heritage so it's clear why it
exists and when to use it (or not).
Just restoring the first sentence you deleted describing the heritage
should be enough to do so.
Speaking for myself, I didn't see the old text as favoring one course
of action over another. How would you feel about:
GCC supports a @code{#pragma} directive that changes the name used in
assembly for a given declaration. While this pragma is supported on all
platforms, it is intended primarily to provide compatibility with the
Solaris system headers. This effect can also be achieved using the asm
labels extension (@pxref{Asm Labels}).
To me, this subtly discourages using the pragma other than for
Solaris, maintains the heritage, and immediately provides a viable
alternative for other platforms.
Index: extend.texi
===================================================================
--- extend.texi (revision 210542)
+++ extend.texi (working copy)
@@ -16895,8 +16895,10 @@
@subsection Symbol-Renaming Pragmas
GCC supports a @code{#pragma} directive that changes the name used in
-assembly for a given declaration. This effect can also be achieved
-using the asm labels extension (@pxref{Asm Labels}).
+assembly for a given declaration. While this pragma is supported on all
+platforms, it is intended primarily to provide compatibility with the
+Solaris system headers. This effect can also be achieved using the asm
+labels extension (@pxref{Asm Labels}).
@table @code
@item redefine_extname @var{oldname} @var{newname}