try-with-resources and null resource

Tim Peierls tim at peierls.net
Mon Jan 24 16:44:01 PST 2011


On Mon, Jan 24, 2011 at 7:43 PM, Tim Peierls <tim at peierls.net> wrote:

> Burden of proof goes the other way: There's a lot of existing code out
> there that could be rewritten to use try-with-resources, and I'd to have to
> bet that none of it would be better off waiting until the first attempt to
> dereference to throw NPE.
>

I'd *hate to* have to bet. :-)

--tim



More information about the coin-dev mailing list