How do you think about the flooding of bracket?
Boris Wang
nano.kago at hotmail.com
Fri Jun 16 02:34:37 PDT 2006
"Mike Parker" <aldacron71 at yahoo.com>
??????:e6tjo6$106v$1 at digitaldaemon.com...
> Unknown W. Brackets wrote:
>
> I've adopted a syntax where I only use the colon (:) form on protection
> attributes inside class/struct definitions. Outside, at module scope, I
> use brackets for for protection attributes. Other modifiers, such as
> static, final, abstract, I use inline. Version statements and multi-line
> debug statements all get brackets. extern statements get colons.
>
> It's a coding convention I've come to like. I would really hate to see the
> colon syntax removed because I find it to be much more readable in class
> definitions:
>
> class MyClass
> {
> private
> {
> void myFunc();
> }
> }
>
> With one function it's not so bad, just ugly. But with multiple methods,
> the colon form is much clearer to me. And I really wouldln't like being
> forced to put all of my protection attributes inline.
>
> This is all just a matter of taste. Having optional coding styles is nice,
> I think. I understand where you're coming from, but there are many other
> ways to make code difficult to read. As I see it, this ain't broke so
> don't fix it.
>
First, I post the thread, because neighter i like what, nor don't like what.
Second, please think this problem in more complicated situation.
More information about the Digitalmars-d
mailing list