[cairo] inline functions
behdad at behdad.org
Wed Apr 18 14:52:53 PDT 2007
On Tue, 2007-04-17 at 03:32 -0400, XinGang Li wrote:
> 2007/4/17, Behdad Esfahbod <behdad at behdad.org>:
> On Mon, 2007-04-16 at 22:35 -0400, XinGang Li wrote:
> > since 1.4.4, the __inline specifier of all the inline
> > replaced with inline. But for the msvc compiler we need
> to using
> > the __inline specifier for the c functions.
> > This is a good way to fix this problem:
> > Add below code to pixman.h:
> > #if defined(_MSC_VER)
> > #define WARN_UNUSED_RESULT
> > #define inline __inline
> > #endif
> Thanks. I asked Pavlov and he thought inline should
> work... Anyway, in
> that case I need to put it back in cairoint.h too I guess.
> BTW, what is this __forceinline thing with MS
> compilers? There is this
> piece in fbmmx.c:
> #ifdef _MSC_VER
> #undef inline
> #define inline __forceinline
> Should I leave it intact?
> "Those who would give up Essential Liberty to purchase a
> Temporary Safety, deserve neither Liberty nor Safety."
> -- Benjamin Franklin, 1759
> I'm not sure it's a good thing to use __forceinline.
> But may be should put it back to pixman.h.
> BWT: For the MS compilers, we also need to define WARN_UNUSED_RESULT.
All should be fixed now.
> Li XinGang
> EMail: slinavlee at gmail.com
> Blog: avlee.cnblogs.com
> cairo mailing list
> cairo at cairographics.org
"Those who would give up Essential Liberty to purchase a little
Temporary Safety, deserve neither Liberty nor Safety."
-- Benjamin Franklin, 1759
More information about the cairo