On Fri, Oct 12, 2012 at 2:41 AM, Olivier Fourdan <ofour...@redhat.com> wrote:
> Peter Hutterer said the following on 10/12/2012 06:37 AM:
>>
>>   [...]
>> +                       *builtin = (flag&  (direct_flag | pointer_flag) ==
>> direct_flag)
>>
>> +                                   ? IS_BUILTIN_TRUE : IS_BUILTIN_FALSE;
>> please expand this to a normal condition - this is too nested to be
>> easily readable.
>
>
> Updated patch attached. Got rid of the 2 additional vars as they did not
> really help with readability.
>
> Cheers,
> Olivier.
>

> +                     if (flag == (1 << INPUT_PROP_DIRECT))
> +                             *builtin = IS_BUILTIN_TRUE;
> +                     else
> +                             *builtin = IS_BUILTIN_FALSE;
> +

Not quite correct, since there could be properties added in the future
whose bits we'd need to set in addition to INPUT_PROP_DIRECT. Third
time's the charm?

Jason

---
When you're rife with devastation / There's a simple explanation:
You're a toymaker's creation / Trapped inside a crystal ball.
And whichever way he tilts it / Know that we must be resilient
We won't let them break our spirits / As we sing our silly song.

------------------------------------------------------------------------------
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev
_______________________________________________
Linuxwacom-devel mailing list
Linuxwacom-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel

Reply via email to