trying out the prototype (original) (raw)
Joe Darcy joe.darcy at oracle.com
Tue Aug 24 11:45:53 PDT 2010
- Previous message: trying out the prototype
- Next message: trying out the prototype
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Stephen Colebourne wrote:
On 24 August 2010 12:14, David Holmes <David.Holmes at oracle.com> wrote:
(I guess this forms a case against the try-with-multiple-resources statement in general. The list of semicolon-delimited declarations enclosed by parentheses looks weird, anyway ;-)
I tend to agree the syntax is awkward and far less readable than simply nesting the try-with statements. Overall, I think the semicolon, multi-resource, aspect is more complex than the benefits it gives. Clearer code results from nesting the statements.
I disagree based on my experiences developing tests for the feature.
Compare "testCreateFailure" with "testCreateFailureNested" in
-Joe
- Previous message: trying out the prototype
- Next message: trying out the prototype
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]