Hacked const and volatile modifiers a bit
[fw/sdcc] / src / SDCCval.c
index 56778663cbaaf18ca2c86b04316f501dd83f5e23..b2a9899615e51d6ceba129b227685c6f64fb96fb 100644 (file)
@@ -790,37 +790,37 @@ charVal (char *s)
       switch (*s)
        {
        case 'n':
-         SPEC_CVAL (val->type).v_int = '\n';
+         SPEC_CVAL (val->type).v_uint = '\n';
          break;
        case 't':
-         SPEC_CVAL (val->type).v_int = '\t';
+         SPEC_CVAL (val->type).v_uint = '\t';
          break;
        case 'v':
-         SPEC_CVAL (val->type).v_int = '\v';
+         SPEC_CVAL (val->type).v_uint = '\v';
          break;
        case 'b':
-         SPEC_CVAL (val->type).v_int = '\b';
+         SPEC_CVAL (val->type).v_uint = '\b';
          break;
        case 'r':
-         SPEC_CVAL (val->type).v_int = '\r';
+         SPEC_CVAL (val->type).v_uint = '\r';
          break;
        case 'f':
-         SPEC_CVAL (val->type).v_int = '\f';
+         SPEC_CVAL (val->type).v_uint = '\f';
          break;
        case 'a':
-         SPEC_CVAL (val->type).v_int = '\a';
+         SPEC_CVAL (val->type).v_uint = '\a';
          break;
        case '\\':
-         SPEC_CVAL (val->type).v_int = '\\';
+         SPEC_CVAL (val->type).v_uint = '\\';
          break;
        case '\?':
-         SPEC_CVAL (val->type).v_int = '\?';
+         SPEC_CVAL (val->type).v_uint = '\?';
          break;
        case '\'':
-         SPEC_CVAL (val->type).v_int = '\'';
+         SPEC_CVAL (val->type).v_uint = '\'';
          break;
        case '\"':
-         SPEC_CVAL (val->type).v_int = '\"';
+         SPEC_CVAL (val->type).v_uint = '\"';
          break;
 
        case '0' :
@@ -1546,7 +1546,6 @@ valForArray (ast * arrExpr)
   if (SPEC_SCLS (arrExpr->left->etype) == S_CODE)
     {
       DCL_TYPE (val->type) = CPOINTER;
-      DCL_PTR_CONST (val->type) = port->mem.code_ro;
     }
   else if (SPEC_SCLS (arrExpr->left->etype) == S_XDATA)
     DCL_TYPE (val->type) = FPOINTER;
@@ -1617,7 +1616,6 @@ valForStructElem (ast * structT, ast * elemT)
   if (SPEC_SCLS (structT->etype) == S_CODE)
     {
       DCL_TYPE (val->type) = CPOINTER;
-      DCL_PTR_CONST (val->type) = port->mem.code_ro;
     }
   else if (SPEC_SCLS (structT->etype) == S_XDATA)
     DCL_TYPE (val->type) = FPOINTER;