Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
| From | Anonymous Shadow <rocket.penguin@riseup.net> |
|---|---|
| Newsgroups | comp.lang.c |
| Subject | Re: disadvantages of using old parameter syntax? |
| Date | 2015-09-04 20:49 +0800 |
| Organization | Aioe.org NNTP Server |
| Message-ID | <msc40i$d6a$2@speranza.aioe.org> (permalink) |
| References | <msc3ru$d6a$1@speranza.aioe.org> |
On Friday, September 04, 2015 08:46 PM, Anonymous Shadow wrote:
> Are there any important differences I should know about when writing
> code like this:
>
> int
> main(argc, argv)
> int argc;
> char* argv[];
> {
> do_stuff(argc, argv);
> return EXIT_SUCCESS;
> }
>
> as opposed to this:
>
> int
> main(int argc, char *argv[])
> {
> do_stuff(argc, argv);
> return EXIT_SUCCESS;
> }
>
> I know that the first one is used in some old code, like the bsd games,
> but now nobody uses it anymore. If there isn't a big problem with doing
> this, I would like to use it, as it saves a lot of space when dealing
> with multiple arguments with types such as /unsigned short int/, which
> use up a lot of space on an 80-column tty.
>
> --
> Anonymous Shadow
Also, I just remembered: you need to put the function prototypes
somewhere else. However, I think that is not a hassle anyway, because if
I put all my prototypes at the top of a file, it will save me adding a
comment explaining which functions are in it.
--
Anonymous Shadow
Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
disadvantages of using old parameter syntax? Anonymous Shadow <rocket.penguin@riseup.net> - 2015-09-04 20:46 +0800
Re: disadvantages of using old parameter syntax? Anonymous Shadow <rocket.penguin@riseup.net> - 2015-09-04 20:49 +0800
Re: disadvantages of using old parameter syntax? raltbos@xs4all.nl (Richard Bos) - 2015-09-04 16:19 +0000
Re: disadvantages of using old parameter syntax? Eric Sosman <esosman@comcast-dot-net.invalid> - 2015-09-04 10:10 -0400
Re: disadvantages of using old parameter syntax? "Rick C. Hodgin" <rick.c.hodgin@gmail.com> - 2015-09-04 07:23 -0700
Re: disadvantages of using old parameter syntax? mark.bluemel@gmail.com - 2015-09-04 07:45 -0700
Re: disadvantages of using old parameter syntax? David Brown <david.brown@hesbynett.no> - 2015-09-05 14:59 +0200
Re: disadvantages of using old parameter syntax? Malcolm McLean <malcolm.mclean5@btinternet.com> - 2015-09-07 13:26 -0700
Re: disadvantages of using old parameter syntax? David Brown <david.brown@hesbynett.no> - 2015-09-08 08:51 +0200
Re: (Not) discussing C-like toy languages Noob <root@127.0.0.1> - 2015-09-08 13:35 +0200
Re: (Not) discussing C-like toy languages David Brown <david.brown@hesbynett.no> - 2015-09-08 13:59 +0200
Re: (Not) discussing C-like toy languages gazelle@shell.xmission.com (Kenny McCormack) - 2015-09-08 12:35 +0000
Re: (Not) discussing C-like toy languages Noob <root@127.0.0.1> - 2015-09-08 17:55 +0200
Re: (Not) discussing C-like toy languages James Kuyper <jameskuyper@verizon.net> - 2015-09-08 13:11 -0400
Re: (Not) discussing C-like toy languages "Rick C. Hodgin" <rick.c.hodgin@gmail.com> - 2015-09-08 10:19 -0700
Re: (Not) discussing C-like toy languages Noob <root@127.0.0.1> - 2015-09-08 21:31 +0200
Re: (Not) discussing C-like toy languages Richard Heathfield <rjh@cpax.org.uk> - 2015-09-08 20:33 +0100
Re: (Not) discussing C-like toy languages David Brown <david.brown@hesbynett.no> - 2015-09-08 22:56 +0200
Re: (Not) discussing C-like toy languages David Brown <david.brown@hesbynett.no> - 2015-09-08 22:52 +0200
Re: (Not) discussing C-like toy languages Richard Heathfield <rjh@cpax.org.uk> - 2015-09-08 21:59 +0100
Re: (Not) discussing C-like toy languages Gareth Owen <gwowen@gmail.com> - 2015-09-08 21:28 +0100
Re: (Not) discussing C-like toy languages James Kuyper <jameskuyper@verizon.net> - 2015-09-08 10:56 -0400
Re: (Not) discussing C-like toy languages Malcolm McLean <malcolm.mclean5@btinternet.com> - 2015-09-08 08:33 -0700
Re: (Not) discussing C-like toy languages fir <profesor.fir@gmail.com> - 2015-09-08 09:12 -0700
Re: (Not) discussing C-like toy languages "Rick C. Hodgin" <rick.c.hodgin@gmail.com> - 2015-09-08 09:18 -0700
Re: (Not) discussing C-like toy languages fir <profesor.fir@gmail.com> - 2015-09-08 10:15 -0700
Re: (Not) discussing C-like toy languages "Rick C. Hodgin" <rick.c.hodgin@gmail.com> - 2015-09-08 08:38 -0700
Re: (Not) discussing C-like toy languages fir <profesor.fir@gmail.com> - 2015-09-08 08:07 -0700
Re: disadvantages of using old parameter syntax? James Kuyper <jameskuyper@verizon.net> - 2015-09-04 10:48 -0400
Re: disadvantages of using old parameter syntax? Paul N <gw7rib@aol.com> - 2015-09-07 12:48 -0700
csiph-web