[mercury-users] Why is --infer-all not the deafult?
Maurizio Colucci
seguso.forever at tin.it
Fri Jul 16 05:12:55 AEST 2004
On Wednesday 14 July 2004 17:16, Peter Schachte wrote:
> One factor that may lead to this difference of opinion is the
> abstraction level of the types you are using (or contemplating). If I
> declare an argument to be a list of ints, for example, that gives very
> little insight into what information they carry. If it's declared to
> be a set (represented as a sorted list) of timestamps, that gives much
> more information.
Yes, but what kind of information?
Knowing the type of a variable V only tells you what _can_ be done with V. It
tells you nothing about what is actually done with V --- that is, the meaning
of V.
For example, knowing that L is a list of timestamps tells me nothing about the
meaning of L, that is "the last 10 of times when the user pressed a button".
That's why I think that type checking helps _writing_ code, not reading code.
Maurizio
--------------------------------------------------------------------------
mercury-users mailing list
post: mercury-users at cs.mu.oz.au
administrative address: owner-mercury-users at cs.mu.oz.au
unsubscribe: Address: mercury-users-request at cs.mu.oz.au Message: unsubscribe
subscribe: Address: mercury-users-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------
More information about the users
mailing list