This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Invalid code in <limits>


Hi,

On Wed, 29 Jan 2003, Mark Mitchell wrote:

> > We alreay do the same thing for static_cast<>, dynamic_casst<>,
> > reinterpret_cast<> and such.  There is no additional inherent complexity.
>
> Well, I did write the code and I have spent a fair amount of time thinking
> about it, and I beg to differ. :-)
>
> You're suggesting treating bulitin functions as keywords, not as functions.
> (That's your analogy with static_cast and sizeof.  Those constructs are
> not parsed as function calls at all.)
>
> If we do that, things will work -- but then we might as well have
> builtin *values* -- rather than builtin *functions*.
>
> That's what I'm suggesting.

Well, functions are obviously more usefull than values, because values are
the subset of constant functions.  We already have builtin functions
taking arguments.  I.e. mapping them to values can't be done.  If you have
to regard them as keywords in the same sense as sizeof() to make it work,
well, then this is the way to go.  I can't think of reasons why those
builtins should be treated as full-flavored functions (with all the
lookup rules, and whatnot) instead of keywords.


Ciao,
Michael.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]