On quinta-feira, 25 de julho de 2013 09:17:36, André Somers wrote:
> static inline bool qFuzzyComparePossibleNulls(double p1, double p2)
> {
>      if (qFuzzyIsNull(p1)) {
>          return qFuzzyIsNull(p2);
>      } else if (qFuzzyIsNull(p2)) {
>          return false;
>      } else {
>          return qFuzzyCompare(p1, p2);
>      }
> }

if ((qFuzzyIsNull(p1) && qFuzzyIsNull(p2)) || qFuzzyCompare(p1, p2))

If p1 is zero, qFuzzyCompare(p1, p2) will return false unless p2 is also zero.

But, no, I think we need something like what Jan-Arve is suggesting.

--
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center

Attachment: signature.asc
Description: This is a digitally signed message part.

_______________________________________________
Development mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/development

Reply via email to