Re: Style convention question
- From: Darin Adler <darin eazel com>
- To: Mark Mielke <mark mark mielke cc>
- Cc: <gtk-devel-list gnome org>, Owen Taylor <otaylor redhat com>
- Subject: Re: Style convention question
- Date: Fri, 09 Mar 2001 10:16:22 -0800
on 3/9/01 9:59 AM, Mark Mielke at mark mark mielke cc wrote:
> This should be in the form:
>
> #ifdef __cplusplus
> # define DECLARE_STRUCT(A) struct A
> #else
> # define DECLARE_STRUCT(A) typedef struct A A
> #endif
>
> DECLARE_STRUCT(A);
> DECLARE_STRUCT(B);
There's no need to do this ifdef. "typedef struct A A;" is allowed in C++
and has the same effect as "struct A;".
-- Darin
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]