What is Expressiveness in a Computer Language
Marshall
marshall.spight at gmail.com
Mon Jun 26 22:20:01 EDT 2006
George Neuner wrote:
>
> I can know that my conversion of floating point to integer is going to
> produce a value within a certain range ... but, in general, the
> compiler can't determine what that range will be. All it knows is
> that a floating point value is being truncated and the stupid
> programmer wants to stick the result into some type too narrow to
> represent the range of possible values.
>
> Like I said to Ben, I haven't seen any _practical_ static type system
> that can deal with things like this. Writing a generic function is
> impossible under the circumstances, and writing a separate function
> for each narrow type is ridiculous and a maintenance nightmare even if
> they can share the bulk of the code.
This is the partial function question again, in a different guise.
Marshall
More information about the Python-list
mailing list