commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Phil Steitz <phil.ste...@gmail.com>
Subject Re: Unnecessary casts in Commons-Math
Date Wed, 19 Oct 2005 04:46:10 GMT
Sorry for the late response on this.  I would be -0 to removing
"unnecessary" casts throughtout [math], as we had some issues early on
with type conversions and decided that it was best to err on the side
of making casts explicit in the code.

Phil

On 10/18/05, J.Pietschmann <j3322ptm@yahoo.de> wrote:
> Elliotte Harold wrote:
> > I loaded Commons-Math into Eclipse, which promptly complained about
> > numerous unnecessary casts. For example, this cast to double in
> > LaguerreSolver.solve:
> >
> >         Complex N = new Complex((double)n, 0.0);
> >         Complex N1 = new Complex((double)(n-1), 0.0);
> >
> > If I submitted a patch to remove these unnecessary casts, would it be
> > likely to be accepted or rejected? Personally I find extra code like
> > this to be very ugly, but I know some programmers and projects like
> > these casts. If the commons-math policy is to use these, I'll set my
> > Eclipse project preferences to ignore this. If not I can patch it. What
> > do people prefer?
>
> Dunno. I'll look after this next weekend. There are a few other issues
> pending with the new solvers anyway.
>
> J.Pietschmann
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-dev-help@jakarta.apache.org
>
>

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


Mime
View raw message