Re: Change to lvalue casting in gcc v4.01

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



kenkahn@xxxxxxxxxxxxx wrote:

>>>    char *buffer[1024];
>>>    *((uint32_t)buffer) = 0x1234;
>>>      
>>>
>>I don't believe that has ever been valid.
>>    
>>
>
>*SIGH* I meant to write
>
>      char buffer[1024];
>      *((uint32_t)buffer) = 0x1234;
>
>Is that better (and allowed)?
>  
>
*((uint32_t *)buffer) = 0x1234; IS still allowd. What has been forbidden
is things like:

((uint32_t) *buffer) = 0x1234;



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux