http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52443

--- Comment #4 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-03-01 
10:23:34 UTC ---
Err ...

        /* Allow conversions pointer type to integral type only if
           there is no sign or zero extension involved.
           For targets were the precision of ptrofftype doesn't match that
           of pointers we need to allow arbitrary conversions to ptrofftype. 
*/
        if ((POINTER_TYPE_P (lhs_type)
             && INTEGRAL_TYPE_P (rhs1_type))
            || (POINTER_TYPE_P (rhs1_type)
                && INTEGRAL_TYPE_P (lhs_type)
                && (TYPE_PRECISION (rhs1_type) >= TYPE_PRECISION (lhs_type)
                    || ptrofftype_p (sizetype))))
          return false;

tricky business ;)

Reply via email to