* src/SDCCicode.c (geniCodeParms),
[fw/sdcc] / src / SDCCast.h
index 589141f9cb7e26af80b92ee410bc48c92fc65a17..be782aae94fea11adf39bc1646cbe23f351394e3 100644 (file)
@@ -51,6 +51,7 @@ typedef struct ast
     unsigned initMode:1;
     int level;                 /* level for expr */
     int block;                 /* block number   */
+    int seqPoint;              /* sequence point */
     /* union of values expression can have */
     union
       {
@@ -169,6 +170,16 @@ ast;
                          x == AND_ASSIGN || x == OR_ASSIGN || x == INC_OP || x == DEC_OP)
 #define IS_DEREF_OP(x) (( x->opval.op == '*' && x->right == NULL) || x->opval.op == '.')
 
+typedef enum
+{
+  RESULT_TYPE_NONE = 0,
+  RESULT_CHECK = 0, /* TODO: replace all occurences with the appropriate type and remove me */
+  RESULT_TYPE_BIT,
+  RESULT_TYPE_CHAR,
+  RESULT_TYPE_INT,
+  RESULT_TYPE_OTHER
+} RESULT_TYPE;
+
 /* forward declarations for global variables */
 extern ast *staticAutos;
 extern FILE *codeOutFile;
@@ -191,11 +202,11 @@ ast *createFunction (symbol *, ast *);
 ast *createBlock (symbol *, ast *);
 ast *createLabel (symbol *, ast *);
 ast *createCase (ast *, ast *, ast *);
-ast *createDefault (ast *, ast *);
+ast *createDefault (ast *, ast *, ast *);
 ast *forLoopOptForm (ast *);
 ast *argAst (ast *);
 ast *resolveSymbols (ast *);
-ast *decorateType (ast *);
+ast *decorateType (ast *, RESULT_TYPE);
 ast *createWhile (symbol *, symbol *, symbol *, ast *, ast *);
 ast *createIf (ast *, ast *, ast *);
 ast *createDo (symbol *, symbol *, symbol *, ast *, ast *);
@@ -212,6 +223,7 @@ void addSymToBlock (symbol *, ast *);
 void freeStringSymbol(symbol *);
 DEFSETFUNC(resetParmKey);
 int astErrors(ast *);
+RESULT_TYPE getResultTypeFromType (sym_link *);
 
 // exported variables 
 extern set *operKeyReset;