harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Hindess <mark.hind...@googlemail.com>
Subject Re: Idiomatic Java: return-at-method-end in Harmony
Date Wed, 28 Oct 2009 08:53:19 GMT

In message <c3755b3a0910270918i17a3fb1ft21552999e112b281@mail.gmail.com>,
Alexey Petrenko writes:
> I agree that the code readability is good. No doubt here.
> Unfortunately, rewriting the code which works fine but does not follow
> some our internal vision can easily offend the original authors and
> provoke holy wars.

Would any original authors really be offended or surprised that code
they "donated" to a larger project is refactored to achieve consistent
style across a project?

We are not overrun with current contributors at the moment so I think
making the code readable and thus lowering the barrier to contribution
has to be a good thing for the project.  I think that most original
authors would feel that it is a more worthwhile goal to ensure a
useful future for the code they have donated than to "preserve" it.

> I'm following the same policy while accepting or rejecting the code
> into the project: if the code works fine, do not have visible
> performance or quality issues, but formatted in the way I do not
> like much then I better accept it with minimal modifications to keep
> the author happy. And let him work on the other real problems but
> try to convince me to return back his original code or explain my
> modifications.

I follow a similar policy.  Contributions don't have to be perfect.
They have to be useful in furthering the goals of the project *and*
they have to have a reasonable chance of being maintained - either by
the contributors or by the community.

You seem to imply that original code should be preserved.  I disagree.
It should be developed to serve the projects goals to the utmost extent.
Isn't that why it was donated?  If the original authors feel that the
project goals would be best served by not making particular changes then
we are very open to their input.

> However, I feel ok to rewrite the code I do not like completely if I'm
> making some important modifications :)

I'm not sure this helps because:

a) you will never achieve consistency (okay we probably wont anyway
   but this approach guarantees it),

b) if anyone felt strongly enough to have a "holy war"[0] about style
   then they'll probably be the ones doing the same over the
   definition of "important modificiation".


[0] I'm not sure such contributors exist but perhaps they do and they're
    just waiting for the right moment to speak up. ;-)

View raw message