Re: Don't cvs update now, if ...
- From: Hans Breuer <hans breuer org>
- To: dia-list gnome org
- Cc: dia-list gnome org
- Subject: Re: Don't cvs update now, if ...
- Date: Mon, 07 Oct 2002 22:00:49 +0200
At 18:50 07.10.02 +0200, Steffen Macke wrote:
Trying to compile, I get a lot
of "redefinition of ..." errors.
Sorry for the incovenience. The M$ compiler docs claim
this construct to be correct (there is no warning at all
for the redefinition and at least for C++ this is standard
conform :)
See :
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclang98/ht
ml/_pluslang_redeclaration_of_typedef_names.asp
Should the lines like
typedef struct _DiaRenderer DiaRenderer;
be replaced by matching #include statements?
this would give the 'circular header dependencies', e.g. object.h
needs to include diarenderer.h and vice versa, which I tried to
avoid. IMO the best solution would be a dia-types.h file only
to define the common typedef's something like
#ifndef DIA_TYPES_H
#define DIA_TYPES_H
typedef struct _Layer Layer;
typedef struct _DiagramData DiagramData;
typedef struct _DiaRenderer DiaRenderer;
#endif
This would allow to pass partly known 'class' pointers without
exposing any details of the concrete class definitions.
What do others think about this ?
Hans
-------- Hans "at" Breuer "dot" Org -----------
Tell me what you need, and I'll tell you how to
get along without it. -- Dilbert
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]