(no subject)

  • it's because the "*" were deleted by markdown, try this:

    PS. i have 3.3.0, is there 3.3.2 anywhere to download.

    thanks,
    -- hugh.


    unsigned char data[100];
    unsigned char* datapos;

    #define ENT_DAT(_p) (((unsigned int)((unsigned char*)(_p) + 3)))

    void setFoo()
    {
    // this line goes wrong. the address generated should be
    // datapos -5 + 3 but you get datapos + 0x00FE (not 0xFFFE)
    ENT_DAT(datapos - 5) = 0xffff;
    }

    int main()
    {
    datapos = data + 5;
    setFoo();
    return 0;
    }

    On 29/12/2013 21:15, Philipp Klaus Krause wrote:

    Using sdcc 3.3.2 #8930 I get:

    error 10: 'lvalue' required for 'assignment' operation.

    Which looks good to me.

    Philipp


     
    Last edit: Maarten Brock 2014-01-06