On Tue, 2006-11-28 at 19:23 +0200, Steffen Macke wrote:
> Hi Lars,
> 
> your addition of lib/attributes.h to lib/arrows.h is causing
> problems because attributes.h is already referencing arrows.h.
> 
> Now MSVC is complaining that
> 
> attributes.h(38) : error C2079: 'arrow' uses undefined struct '_Arrow'
> 
> What is the best way to fix this?

I'm tempted to just say "Get a better compiler", but I know that's not
useful. The below diff, which merely moves the #include of attributes.h
from arrows.h (doesn't seem to be needed there) into arrows.c where it
belongs might do it.  Let me know what happens with it.

-Lars
Index: lib/arrows.c
===================================================================
RCS file: /cvs/gnome/dia/lib/arrows.c,v
retrieving revision 1.43
diff -u -r1.43 arrows.c
--- lib/arrows.c	25 Nov 2006 20:39:07 -0000	1.43
+++ lib/arrows.c	28 Nov 2006 19:01:44 -0000
@@ -35,6 +35,7 @@
 
 #include "arrows.h"
 #include "diarenderer.h"
+#include "attributes.h"
 #include "intl.h"
 
 struct menudesc arrow_types[] =
Index: lib/arrows.h
===================================================================
RCS file: /cvs/gnome/dia/lib/arrows.h,v
retrieving revision 1.34
diff -u -r1.34 arrows.h
--- lib/arrows.h	13 Nov 2006 06:13:54 -0000	1.34
+++ lib/arrows.h	28 Nov 2006 19:01:44 -0000
@@ -23,7 +23,6 @@
 #include "geometry.h"
 #include "color.h"
 #include "dia_xml.h"
-#include "attributes.h"
 #include "widgets.h"
 
 /* NOTE: Add new arrow types at the end, or the enums
@@ -96,6 +95,7 @@
   real length;
   real width;
 };
+
 
 void arrow_draw(DiaRenderer *renderer, ArrowType type,
 		Point *to, Point *from,
_______________________________________________
Dia-list mailing list
[email protected]
http://mail.gnome.org/mailman/listinfo/dia-list
FAQ at http://www.gnome.org/projects/dia/faq.html
Main page at http://www.gnome.org/projects/dia

Reply via email to