[clean-list] a local function typing question in function composition

Jigang Sun Jigang.Sun at student.paisley.ac.uk
Wed Apr 4 20:27:47 MEST 2007


I want to test the function composition example on page 32-33 of Clean text book Functional Programming in Clean. In order to avoid clashes with o in Clean library, I rename o to oo.

module test
import StdEnv

(oo) infixr 9 ::(b -> c) (a -> b) -> (a -> c)
(oo) g f = h
where 
	h:: a -> c
	h x = g (f x)
	
Start = 3

[test.icl,]: module has changed
Type error [test.icl,7,h]:type variable of type of lifted argument c appears in the specified type
Type error [test.icl,7,h]:type variable of type of lifted argument b appears in the specified type

I do not understand what the message is saying. Could anyone give me a valid one.
Thanks.
Jigang





Legal disclaimer
--------------------------

The information transmitted is the property of the University of Paisley and is intended only for the person or entity 
to which it is addressed and may contain confidential and/or privileged material.  Statements and opinions expressed in this e-mail may not represent those of the company.  Any review, retransmission, dissemination and other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited.
If you received this in error, please contact the sender immediately and delete the material from any computer. 

--------------------------




More information about the clean-list mailing list