set *externs = NULL; /* Varibles that are declared as extern */
/* TODO: this should be configurable (DS803C90 uses more than 6) */
-int maxInterrupts = 6;
+unsigned maxInterrupts = 6;
int allocInfo = 1;
symbol *mainf;
extern char *VersionString;
/* if it is a float then it gets tricky */
/* otherwise it is fairly simple */
if (!IS_FLOAT (val->type)) {
- unsigned long v = floatFromVal (val);
+ unsigned long v = (unsigned long) floatFromVal (val);
v >>= (offset * 8);
switch (size) {
i = 60;
while (i && *s && pplen < plen)
{
- if (*s < ' ' || *s == '\"')
+ if (*s < ' ' || *s == '\"' || *s=='\\')
{
*p = '\0';
if (p != buf)
tfprintf (ofile, "\t!ascii\n", buf);
- tfprintf (ofile, "\t!db !constbyte\n", *s);
+ tfprintf (ofile, "\t!db !constbyte\n", (unsigned char)*s);
p = buf;
}
else
}
else if (size == FPTRSIZE)
{
- tfprintf (oFile, "\t!dws\n", val->name);
+ if (port->use_dw_for_init) {
+ tfprintf (oFile, "\t!dws\n", val->name);
+ } else {
+ printPointerType (oFile, val->name);
+ }
}
else if (size == GPTRSIZE)
{
void
createInterruptVect (FILE * vFile)
{
- int i = 0;
+ unsigned i = 0;
mainf = newSymbol ("main", 0);
mainf->block = 0;
if (!options.c1mode)
{
sprintf (buffer, srcFileName);
- strcat (buffer, ".asm");
+ strcat (buffer, port->assembler.file_ext);
}
else
{