Like Go/Rust, why not to have "func" keyword before function declaration

ketmar via Digitalmars-d digitalmars-d at puremagic.com
Tue Jan 20 06:02:24 PST 2015


On Tue, 20 Jan 2015 13:49:47 +0000
MattCoder via Digitalmars-d <digitalmars-d at puremagic.com> wrote:

> On Tuesday, 20 January 2015 at 13:47:11 UTC, ketmar via 
> Digitalmars-d wrote:
> >   void function foo () { ... }
> >   foo();
> >
> > do you see the subtle difference? yes, that tiny whitespace in
> > declaration. i borrowed that habit from some Oberon code 
> > decades ago, and it serves me well since then.
> 
> Hmm, nice one. I think I'll do this too.
be my guest. ;-) i'll be glad if it will help you.

the only bad thing i found with this style is that after some time you
really start noticing the absense of whitespace in declaraions, and it
annoys you. so the first thing you want to do with someone's code is to
ADD THAT WHITESPACES! somehow it becomes most frustrating element of
alien code styling. ;-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: not available
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20150120/5ea01bf9/attachment.sig>


More information about the Digitalmars-d mailing list