Re: [PATCH 0/4] BUG_RETURN_VAL macros

2012-05-15 Thread Peter Hutterer
On Tue, May 15, 2012 at 08:06:48PM +0200, Mark Kettenis wrote: > > From: Peter Hutterer > > Date: Tue, 15 May 2012 20:26:37 +1000 > > > > I got annoyed having to write constructs like > > > > BUG_WARN(foo); > > if (foo) > > return FALSE; > > > > and similar. glib has useful macros like g_re

Re: [PATCH 0/4] BUG_RETURN_VAL macros

2012-05-15 Thread Chase Douglas
On 05/15/2012 11:06 AM, Mark Kettenis wrote: >> From: Peter Hutterer >> Date: Tue, 15 May 2012 20:26:37 +1000 >> >> I got annoyed having to write constructs like >> >> BUG_WARN(foo); >> if (foo) >> return FALSE; >> >> and similar. glib has useful macros like g_return_if_fail and similar, these

Re: [PATCH 0/4] BUG_RETURN_VAL macros

2012-05-15 Thread Mark Kettenis
> From: Peter Hutterer > Date: Tue, 15 May 2012 20:26:37 +1000 > > I got annoyed having to write constructs like > > BUG_WARN(foo); > if (foo) > return FALSE; > > and similar. glib has useful macros like g_return_if_fail and similar, these > are macros that essentially do the same job. They

Re: [PATCH 0/4] BUG_RETURN_VAL macros

2012-05-15 Thread Chase Douglas
On 05/15/2012 03:26 AM, Peter Hutterer wrote: > > I got annoyed having to write constructs like > > BUG_WARN(foo); > if (foo) > return FALSE; > > and similar. glib has useful macros like g_return_if_fail and similar, these > are macros that essentially do the same job. They shout into the lo

[PATCH 0/4] BUG_RETURN_VAL macros

2012-05-15 Thread Peter Hutterer
I got annoyed having to write constructs like BUG_WARN(foo); if (foo) return FALSE; and similar. glib has useful macros like g_return_if_fail and similar, these are macros that essentially do the same job. They shout into the log, but otherwise continue as normal. http://developer.gnome.org