c/10406: Suggestion for variable attribute "default"

Wolfgang Bangerth bangerth@ices.utexas.edu
Mon Apr 14 22:26:00 GMT 2003


The following reply was made to PR c/10406; it has been noted by GNATS.

From: Wolfgang Bangerth <bangerth@ices.utexas.edu>
To: "Benjamin K." <bkausbk@web.de>
Cc: bangerth@dealii.org, <gcc-bugs@gcc.gnu.org>, <gcc-gnats@gcc.gnu.org>
Subject: Re: c/10406: Suggestion for variable attribute "default"
Date: Mon, 14 Apr 2003 17:24:28 -0500 (CDT)

 > It is at least same unimportant as some other attributes like
 > transparent_union, unused, deprecated or weak.
 
 Attribute unused is used in cases where in C++ you can write
   void f(int /*p*/) {
     ...; /* doesn't use p, but did in the past; we don't want to change 
             the prototype, though */
   }
 which you can't do in C.
 
 Deprecated was deemed useful enough to be included into the Java standard.
 
 Attribute weak changes the semantics of a function w.r.t. the linker.
 
 That being said, it might well be that some of the attributes are useless. 
 That should not tempt us into creating more uselessness, though.
 
 IMHO, your proposal is absolutely useless, since
 - one can get the same effect with a minimal change
 - it would have a ridiculously far-reaching impact since it would 
   essentially introduce overloading assignment operators in C.
 
 Wolfgang (certain to speak for the wider GCC community here)
 
 -------------------------------------------------------------------------
 Wolfgang Bangerth              email:            bangerth@ices.utexas.edu
                                www: http://www.ices.utexas.edu/~bangerth/
 
 



More information about the Gcc-prs mailing list