ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Donald <pe...@apache.org>
Subject Re: [PATCH] Project.java
Date Thu, 13 Jun 2002 00:23:07 GMT
At 04:57 PM 6/12/2002 -0700, you wrote:
> >      public String getProperty(String name) {
> > -        if (name == null) {
> > -          return null;
> > -        }
> > -        String property = (String) properties.get(name);
> > -        return property;
> > +        return (name == null ? null : (String) properties.get(name));
> >      }
>
>Does this have any speed benefits? ie, does it map down to a conditional
>move CMOV opcode on x86 so you avoid a speculation/branch misprediction
>penalty, or is it just a style thing?

Just a style thing.


Cheers,

Peter Donald
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
"Faced with the choice between changing one's mind,
and proving that there is no need to do so - almost
everyone gets busy on the proof."
              - John Kenneth Galbraith
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message