+2004-01-20 Erik Petrich <epetrich@ivorytower.norman.ok.us>
+
+ * src/hc08/ralloc.c (rematStr): fixed bug #879282
+ * src/SDCCast.c (decorateType): fixed bug #880197
+
2004-01-20 Michael Hope <michaelh@juju.net.nz>
* sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
/* make sure the type is complete and sane */
checkTypeSanity(LETYPE(tree), "(cast)");
+ /* If code memory is read only, then pointers to code memory */
+ /* implicitly point to constants -- make this explicit */
+ {
+ sym_link *t = LTYPE(tree);
+ while (t && t->next)
+ {
+ if (IS_CODEPTR(t) && port->mem.code_ro)
+ {
+ if (IS_SPEC(t->next))
+ SPEC_CONST (t->next) = 1;
+ else
+ DCL_PTR_CONST (t->next) = 1;
+ }
+ t = t->next;
+ }
+ }
+
#if 0
/* if the right is a literal replace the tree */
if (IS_LITERAL (RETYPE (tree))) {
while (1)
{
-
/* if plus or minus print the right hand side */
if (ic->op == '+' || ic->op == '-')
{
/* we reached the end */
if (ic->op == ADDRESS_OF)
sprintf (s, "%s", OP_SYMBOL (IC_LEFT (ic))->rname);
- else if (ic->op == '=');
+ else if (ic->op == '=')
sprintf (s, "0x%04x", (int) operandLitValue (IC_RIGHT (ic)) );
break;
}