What is Expressiveness in a Computer Language

Matthias Blume find at my.address.elsewhere
Wed Jun 21 17:05:53 CEST 2006


"Rob Thorpe" <robert.thorpe at antenova.com> writes:

>> >> > No it doesn't. Casting reinterprets a value of one type as a value of
>> >> > another type.
>> >> > There is a difference.  If I cast an unsigned integer 2000000000 to a
>> >> > signed integer in C on the machine I'm using then the result I will get
>> >> > will not make any sense.
>> >>
>> >> Which result are you getting?  What does it mean to "make sense"?
>> >
>> > Well the right one actually, bad example.
>> >
>> > But, if I cast an unsigned int 2500000000 to signed I get -1794967296.
>>
>> So, why do you think this "does not make sense"?
>
> Well, it makes sense in terms of the C spec certainly.
> It does not make sense in that it does not emit an error.

Why not?



More information about the Python-list mailing list