diff --git a/src/cc65/codegen.c b/src/cc65/codegen.c index dfc986d09..db5cd9cbb 100644 --- a/src/cc65/codegen.c +++ b/src/cc65/codegen.c @@ -2491,7 +2491,7 @@ void g_add (unsigned flags, unsigned long val) }; if (flags & CF_CONST) { - flags &= ~CF_FORCECHAR; // Handle chars as ints + flags &= ~CF_FORCECHAR; /* Handle chars as ints */ g_push (flags & ~CF_CONST, 0); } oper (flags, val, ops); @@ -2510,7 +2510,7 @@ void g_sub (unsigned flags, unsigned long val) }; if (flags & CF_CONST) { - flags &= ~CF_FORCECHAR; // Handle chars as ints + flags &= ~CF_FORCECHAR; /* Handle chars as ints */ g_push (flags & ~CF_CONST, 0); } oper (flags, val, ops); @@ -2552,7 +2552,7 @@ void g_mul (unsigned flags, unsigned long val) } /* If the right hand side is const, the lhs is not on stack but still - * in the primary register. + * in the primary register. */ if (flags & CF_CONST) { @@ -2603,7 +2603,7 @@ void g_mul (unsigned flags, unsigned long val) /* If we go here, we didn't emit code. Push the lhs on stack and fall * into the normal, non-optimized stuff. */ - flags &= ~CF_FORCECHAR; // Handle chars as ints + flags &= ~CF_FORCECHAR; /* Handle chars as ints */ g_push (flags & ~CF_CONST, 0); } @@ -2633,7 +2633,7 @@ void g_div (unsigned flags, unsigned long val) /* Generate a division */ if (flags & CF_CONST) { /* lhs is not on stack */ - flags &= ~CF_FORCECHAR; // Handle chars as ints + flags &= ~CF_FORCECHAR; /* Handle chars as ints */ g_push (flags & ~CF_CONST, 0); } oper (flags, val, ops); @@ -2661,7 +2661,7 @@ void g_mod (unsigned flags, unsigned long val) /* Do it the hard way... */ if (flags & CF_CONST) { /* lhs is not on stack */ - flags &= ~CF_FORCECHAR; // Handle chars as ints + flags &= ~CF_FORCECHAR; /* Handle chars as ints */ g_push (flags & ~CF_CONST, 0); } oper (flags, val, ops); diff --git a/src/cc65/litpool.c b/src/cc65/litpool.c index 65c896d58..6243e38b5 100644 --- a/src/cc65/litpool.c +++ b/src/cc65/litpool.c @@ -167,7 +167,7 @@ const char* GetLiteral (unsigned Offs) /* Get a pointer to the literal with the given offset in the pool */ { CHECK (Offs < LiteralOffs); - return &LiteralPool[Offs]; + return (const char*) &LiteralPool[Offs]; } diff --git a/src/cc65/preproc.c b/src/cc65/preproc.c index 115d57beb..321b3b175 100644 --- a/src/cc65/preproc.c +++ b/src/cc65/preproc.c @@ -753,7 +753,7 @@ enum { PP_LINE, PP_PRAGMA, PP_UNDEF, - PP_ILLEGAL, + PP_ILLEGAL }; static const struct tok_elt pre_toks[] = {