Version française
Home     About     Download     Resources     Contact us    
Browse thread
Re: [Caml-list] Lambda-Term (f x) (x f) translated to Ocaml?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: yoann padioleau <padator@w...>
Subject: Re: [Caml-list] Lambda-Term (f x) (x f) translated to Ocaml?

> Hello,
> 
> I'm not firm in lambda calculus, what is the lambda-term
> in the subject translated to OCaml?
> 
> Is this possible?

the ocaml interpreter dont want this definition

let g f x = (f x) (x f)

and shout: 
  this expression has type ('a -> 'b) -> 'c -> 'd but is here used with type 'a

I guess that this is not a lambda term that can be typed.
There are many of them. A famous one is the Y combinator.
The _typed_ lambda calculus does not allow all the lambda terms
of the (normal) lambda calculus.

> 
> P.S.: Also welcome is a "Lambda-Calculus for Dummies" recommendation
>       on literature (or web-links). ;-)
> 

I liked very much:
 G.J.Michaelson, An Introduction to Functional Programming Through Lambda Calculus, Addison-Wesley
now available online from
 http://www.macs.hw.ac.uk/~greg/books.html

>