[cairo] compiler warnings in cairo_wideint.h/c

Andreas Tobler toa at pop.agri.ch
Tue Oct 12 23:20:37 PDT 2004


Hi all,

being new to cairo and friends. So sorry, for complaining already :)

I use cairo here for libgcj development and compile it under OS-X with a
current gcc-cvs.

Now I struggled over this warnings from cairo_wideint.h/c:

cairo_wideint.h:146: warning: type qualifiers ignored on function return
type

This warning pops up under current released gcc only if you enable the -W
flag. In gcc 4.0.0 it belongs now to the -Wreturn-type which is switched
on when you use -Wall.

So far about the warning when it pops up.

Now the warning itself says, that for example the const in

const cairo_uquorem64_t I _cairo_uint64_divrem (cairo_uint64_t num, cairo_uint64_t
den);

has no effect.

/* Type qualifiers on a function return type are
   normally permitted by the standard but have no
   effect.
*/


I have a patch for this which removes all the consts in cairo_wideint.c/h
but only tested under HAVE_UINT64_T == 1.

If this is a false analysis, please ignore.

Andreas




More information about the cairo mailing list