[Ns-developers] coding style and code reviews update

Gustavo Carneiro gjcarneiro at gmail.com
Tue Dec 8 03:20:45 PST 2009


2009/12/8 Timo Bingmann <tbns at idlebox.net>

> On Tuesday 08 December 2009 07:43:40 Tom Henderson wrote:
> > We've had some on-list and off-list discussion about how the ns-3 code
> > reviews are going, and about the use and possible changes to the coding
> > style guidelines.
>
> While we're at it: I don't know if this issue has been discussed
> previously,
> but I always trip over the (void) argument lists in any function taking no
> parameters. As in
>
> void
> Foo (void)
> {
> }
>
> This is a relic from plain C times, when functions would take any arguments
> without the void.
>
> However, with ns-3 using such very advanced C++ constructs this nostalgia
> strikes me as very odd. Does anyone know another modern C++ community
> requiring this?
>

Even though the examples in the style guide for functions/methods taken no
arguments are written as Foo (void), there is no rule in the style guide
that says you cannot use Foo () instead.  In fact I am more likely to write
Foo () myself, and you'll probably find some such appearances in the NS-3
code today.


>
> Greetings,
> Timo
>



-- 
Gustavo J. A. M. Carneiro
INESC Porto, Telecommunications and Multimedia Unit
"The universe is always one step beyond logic." -- Frank Herbert


More information about the Ns-developers mailing list