
10 Oct
2007
10 Oct
'07
8:17 a.m.
Dan Piponi wrote:
The reusability of Num varies inversely with how many assumptions you make about it.
A default implementation of pi would only increase usability, not decrease it. If you need a specialized definition of pi in your instance, you would provide it, just as you do now. If pi makes no sense in your instance and you need it to be an error, you would define pi = error "pi in your face", just as you do now. And in the most common case, you would do nothing, instead of redifining pi in the obvious way, as you need to do now. -Yitz