H
Hill Pang
I can find some answer from web, but I can't find their definitions in the C99 standard so far.
Which page is it in?
Thanks in advance.
Which page is it in?
Thanks in advance.
Hill Pang said:I can find some answer from web, but I can't find their definitions in
the C99 standard so far.
Which page is it in?
There a little difference, but in modern context, they are same.
prototype and declaration both are same
prototype and declaration both are same
On 8/7/2012 1:30 PM, Varun Tewari wrote:
By "in modern context," I imagine you mean something like
"always use prototypes, because a compiler that can't handle them
cannot possibly be `modern'." That's good advice: There is almost
never a reason to omit the parameter types, and I'd venture that
even when a reason exists it's probably a weak one.
The Standard
describes non-prototype function declarations as an "obsolecent
feature" of the language, and even if it never gets all the way to
"obsolete" the message is clear: Don't Do That.
Kenneth Brody said:[...]maintaining K&R style code. Yes it's still about. It's only a couple
of years since I modified a K&R program.
Until recently, the code I maintain had to be able to compile on
HP-UX. The C compiler that came with the system would recognize
prototypes, and tell you that you needed to buy their other C compiler
if you needed prototype support.
As I recall, there is now a gcc for HP-UX, eliminating that hurdle.
Pics or it didn't happen.I'd argue that there is much evidence for the existence of a God.
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.