hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <seb...@gmail.com>
Subject Re: Code formatting and standards
Date Sat, 16 Jan 2010 16:55:08 GMT
On 16/01/2010, Oleg Kalnichevski <olegk@apache.org> wrote:
> Tony Poppleton wrote:
>
> > Hi Sebb,
> >
> > As requested, I have produced a first stab at some coding conventions at
> http://wiki.apache.org/HttpComponents/CodingConventions
> >
> > Please feel free to modify as you see fit.  There is still some work to be
> done, most notably for me adding the Eclipse code formatting (if there is no
> objection then I will add the ones Oleg sent earlier, until the appropriate
> body comes up with the official one)
> >
> > On your point about being consistent in a file being more important than
> across the project, I would disagree.  If these conventions (and the code
> formatter) become the official project standards, then they are exactly
> that, and all files in the project should adhere to them by definition.
> After the single SVN commit to clean up all the code, then both file and
> project consistency will be maintained forevermore.

My point was about applying patches to existing code, which might not
yet have been homogenised.

> >
> > Regards,
> > Tony
> >
> >
>
>  (1) I think it would be worth dividing content of the document into two
> distinct sections: requirements and recommendations. A failure to comply
> with the requirements may lead to the rejection of a patch.

I'd prefer to see the items flagged with MUST and SHOULD; makes it
easier to keep related items together (and easier to change the
priority!) IIRC this is the way RFCs do it.

>  (2) Can we tone down this particular line a little ;-) "Prefer unchecked
> exceptions (like RuntimeException) over checked exceptions". I personally
> would be much more content with something like "checked exceptions should
> represent potentially recoverable exceptions; runtime exceptions should
> represent non-recoverable errors / unexpected errors / programming errors"
> or some such.

+1

>  Oleg
>
> ---------------------------------------------------------------------
>  To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
>  For additional commands, e-mail: dev-help@hc.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org


Mime
View raw message