[clean-list] Re: Troubles using a function as parameter to another function

RT Happe rthappe@mathematik.uni-freiburg.de
Sun, 17 Feb 2002 18:28:12 +0100 (CET)


> In any case it looks like it may be a better strategy not to specify the
> type of a function for each function one defines and let the compiler do
> the work for you...
> I tend to specify always the type when I define functions, maybe is just an
> unconscious "porting" from the world of C ("always use prototypes!")

I think type declarations are a useful bit of documentation.  I tend to
document the types of major functions and data even when programming in
latently typed languages such as Scheme.  By the way, I understand that
  * Clean may sometimes approve type assignments it cannot deduce by
    itself;  that's Mycroft's job in Clean's Hindley/Milner/Mycroft type
    system).
  * the programmer may assign a more specific type than Clean would.

rthappe