Michel Dänzer <[email protected]> writes:

> Is assigning an unsigned value with the MSB set to a signed variable
> well-defined in C?

I have no idea. And I just spent a few hours wading through the N1570
draft of the C standard on a related issue. In particular, this is
worrying:

6.3.1.3

3   Otherwise, the new type is signed and the value cannot be represented
    in it; either the result is implementation-defined or an
    implementation-defined signal is raised.

I don't think the absence of a cast matters.

Surely some better language lawyer can tell us the answer...

-- 
-keith

Attachment: signature.asc
Description: PGP signature

_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to