[cc65] -O bug in 2.13.2

From: Johan Kotlinski <kotlinski1gmail.com>
Date: 2012-02-05 04:11:09
The following fails with -O enabled:

#include <assert.h>

void main() {
    unsigned char buf = 0x20;
    unsigned char* ptr = &buf;
    *ptr ^= *ptr;
    assert(*ptr == (0x20 ^ 0x20));  // Fails!
}

Cheers,
Johan
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Sun Feb 5 04:11:44 2012

This archive was generated by hypermail 2.1.8 : 2012-02-05 04:11:48 CET