[opensource-dev] Fix for "Attachments displayed in mouselook" bug
Ponzu
lee.ponzu at gmail.com
Sat Oct 9 19:57:49 PDT 2010
Would it be better to just store FALSE in mRenderTypeEnabled[0]?
On Sat, Oct 9, 2010 at 12:19 PM, Argent <secret.argent at gmail.com> wrote:
> I don't normally gripe about stuff like this, but somehow this one
> triggered my twitches from 20 years of supporting PhD programmers.
> Brilliant guys, but sometimes it's SO hard to figure out what they're
> trying to do.
>
> This is a case where the trinary "?:" operator is much more readable
> and understandable.
>
> (type == 0) ? FALSE : mRenderTypeEnabled[type];
>
> But even better:
>
> if(type == 0)
> return FALSE; // explain why here .. eg "in this context we are
> always rendering attached prims on the head when blah blah..."
> else
> return mRenderTypeEnabled[type];
> _______________________________________________
> Policies and (un)subscribe information available here:
> http://wiki.secondlife.com/wiki/OpenSource-Dev
> Please read the policies before posting to keep unmoderated posting
> privileges
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.secondlife.com/pipermail/opensource-dev/attachments/20101009/20a203bf/attachment.htm
More information about the opensource-dev
mailing list