I would say that if some committer uses asserts in MINA, I will respect that. I tried to use asserts in Java in the past, and I found it almost useless and confusing, so I just dropped it.
It's quite strange because I was a C-assert freak back in the 90ies... In any case, asserts does not replace a decent piece of code :) On Tue, Dec 1, 2009 at 4:31 PM, Alan D. Cabrera <[email protected]>wrote: > > On Dec 1, 2009, at 2:46 AM, Eero Nevalainen wrote: > > Emmanuel Lecharny wrote: >> >>> The test is just a safety belt. It does not harm... We should >>>>> probably refactor this code to be a bit moe accurate though ... >>>>> >>>> >>>> assert? >>>> >>> >>> Yuck :/ >>> >>> So C-ished.. >>> >>> better have better code ! >>> >> >> Wait... what? >> >> I thought the whole point of assertions is to provide these "no harm >> safety belt checks", with the side effect that they can be disabled if >> there are concerns of efficiency. >> > > I personally like asserts for that reason and for the way it declares the > original developer's assumptions. It's quite helpful when a new developer > starts reading the code base. Finally, it does make code testing more > productive in an open source environment where there are many cooks in the > kitchen. > > > > Regards, > Alan > > -- Regards, Cordialement, Emmanuel Lécharny www.iktek.com
