]> git.sur5r.net Git - cc65/blobdiff - src/cc65/symtab.h
Removed (pretty inconsistently used) tab chars from source code base.
[cc65] / src / cc65 / symtab.h
index 18c8ce141115971d91bcde96429f77ec8f277868..154dce55aa5be028bf2d50d9c0545c54e031fdd2 100644 (file)
@@ -1,12 +1,12 @@
 /*****************************************************************************/
 /*                                                                           */
-/*                                symtab.h                                  */
+/*                                 symtab.h                                  */
 /*                                                                           */
-/*             Symbol table management for the cc65 C compiler              */
+/*              Symbol table management for the cc65 C compiler              */
 /*                                                                           */
 /*                                                                           */
 /*                                                                           */
-/* (C) 2000-2009, Ullrich von Bassewitz                                      */
+/* (C) 2000-2013, Ullrich von Bassewitz                                      */
 /*                Roemerstrasse 52                                           */
 /*                D-70794 Filderstadt                                        */
 /* EMail:         uz@cc65.org                                                */
@@ -46,7 +46,7 @@
 
 
 /*****************************************************************************/
-/*                                  Data                                    */
+/*                                   Data                                    */
 /*****************************************************************************/
 
 
 /* Symbol table */
 typedef struct SymTable SymTable;
 struct SymTable {
-    SymTable*                  PrevTab;        /* Pointer to higher level symbol table */
-    SymEntry*                  SymHead;        /* Double linked list of symbols */
-    SymEntry*                  SymTail;        /* Double linked list of symbols */
-    unsigned                   SymCount;       /* Count of symbols in this table */
-    unsigned                   Size;           /* Size of table */
-    SymEntry*                  Tab[1];         /* Actual table, dynamically allocated */
+    SymTable*           PrevTab;        /* Pointer to higher level symbol table */
+    SymEntry*           SymHead;        /* Double linked list of symbols */
+    SymEntry*           SymTail;        /* Double linked list of symbols */
+    unsigned            SymCount;       /* Count of symbols in this table */
+    unsigned            Size;           /* Size of table */
+    SymEntry*           Tab[1];         /* Actual table, dynamically allocated */
 };
 
 /* An empty symbol table */
-extern SymTable                EmptySymTab;
+extern SymTable         EmptySymTab;
 
 /* Forwards */
 struct FuncDesc;
 
 /* Predefined lexical levels */
-#define LEX_LEVEL_GLOBAL       1U
+#define LEX_LEVEL_GLOBAL        1U
 #define LEX_LEVEL_FUNCTION      2U
 
 
 
 /*****************************************************************************/
-/*                       Handling of lexical levels                         */
+/*                        Handling of lexical levels                         */
 /*****************************************************************************/
 
 
@@ -116,7 +116,7 @@ void LeaveStructLevel (void);
 
 
 /*****************************************************************************/
-/*                             Find functions                               */
+/*                              Find functions                               */
 /*****************************************************************************/
 
 
@@ -139,12 +139,12 @@ SymEntry* FindStructField (const Type* TypeArray, const char* Name);
 
 
 /*****************************************************************************/
-/*                      Add stuff to the symbol table                       */
+/*                       Add stuff to the symbol table                       */
 /*****************************************************************************/
 
 
 
-SymEntry* AddStructSym (const char* Name, unsigned Size, SymTable* Tab);
+SymEntry* AddStructSym (const char* Name, unsigned Type, unsigned Size, SymTable* Tab);
 /* Add a struct/union entry and return it */
 
 SymEntry* AddBitField (const char* Name, unsigned Offs, unsigned BitOffs, unsigned Width);
@@ -165,7 +165,7 @@ SymEntry* AddGlobalSym (const char* Name, const Type* T, unsigned Flags);
 
 
 /*****************************************************************************/
-/*                                  Code                                    */
+/*                                   Code                                    */
 /*****************************************************************************/
 
 
@@ -188,6 +188,9 @@ void PrintSymTable (const SymTable* Tab, FILE* F, const char* Header, ...);
 void EmitExternals (void);
 /* Write import/export statements for external symbols */
 
+void EmitDebugInfo (void);
+/* Emit debug infos for the locals of the current scope */
+
 
 
 /* End of symtab.h */