]> git.sur5r.net Git - cc65/blobdiff - src/cc65/declattr.h
In case of parse errors for structs, don't just set the type of the result to
[cc65] / src / cc65 / declattr.h
index cef08b30f5661e535871702c5dc04c8b4f215c54..d6c8a168b321effb2f818bea224161f9d4e3b941 100644 (file)
@@ -6,10 +6,10 @@
 /*                                                                           */
 /*                                                                           */
 /*                                                                           */
-/* (C) 2000-2002 Ullrich von Bassewitz                                       */
-/*               Wacholderweg 14                                             */
-/*               D-70597 Stuttgart                                           */
-/* EMail:        uz@musoftware.de                                            */
+/* (C) 1998-2009, Ullrich von Bassewitz                                      */
+/*                Roemerstrasse 52                                           */
+/*                D-70794 Filderstadt                                        */
+/* EMail:         uz@cc65.org                                                */
 /*                                                                           */
 /*                                                                           */
 /* This software is provided 'as-is', without any expressed or implied       */
 
 
 
-#include "declare.h"
-
-
-
 /*****************************************************************************/
-/*                                  Data                                    */
+/*                                  Data                                    */
 /*****************************************************************************/
 
 
 
+/* Forward */
+struct Declaration;
+
 /* Supported attribute types */
 typedef enum {
-    atNone     = -1,           /* No attribute */
-    atAlias,                   /* Alias declaration */
-    atUnused,                  /* Variable is unused */
-    atZeroPage,                        /* Zero page symbol */
-
-    atCount                    /* Number of attributes */
-} attrib_t;
+    atNoReturn,                        /* Function does not return */
+    atUnused,                   /* Symbol is unused - don't warn */
+} DeclAttrType;
 
 /* An actual attribute description */
 typedef struct DeclAttr DeclAttr;
 struct DeclAttr {
-    attrib_t                   AttrType;       /* Type of attribute */
-
-    union {
-       struct SymEntry*        Sym;            /* Symbol for alias */
-    } V;
+    DeclAttrType                AttrType;       /* Type of attribute */
 };
 
 
 
 /*****************************************************************************/
-/*                                  Code                                    */
+/*                                  Code                                    */
 /*****************************************************************************/
 
 
 
-void ParseAttribute (const Declaration* D, DeclAttr* A);
+void ParseAttribute (struct Declaration* D);
 /* Parse an additional __attribute__ modifier */