Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.forth > #26105
| From | anton@mips.complang.tuwien.ac.at (Anton Ertl) |
|---|---|
| Newsgroups | comp.lang.forth |
| Subject | Re: Y combinator |
| Date | 2013-10-03 13:09 +0000 |
| Organization | Institut fuer Computersprachen, Technische Universitaet Wien |
| Message-ID | <2013Oct3.150934@mips.complang.tuwien.ac.at> (permalink) |
| References | <a4aljf$2q2$1@news.tuwien.ac.at> <85eh82hjlr.fsf@junk.nocrew.org> |
Lars Brinkhoff <lars.spam@nocrew.org> writes:
[Anton Ertl in 2002:-)]
>> Defining Y in ANS Forth (no RECURSIVE) is left as an exercise to the
>> reader:-)
>
>I read, I exercised, I posted.
>
>: y ( xt1 -- xt2 ) here tuck 2>r 1 cells allot
> :noname r> postpone literal postpone @ r> compile, postpone ;
> dup rot ! ;
Nice.
Now Curry's definition of Y is
Y = lambda f.(lambda x.f (x x))(lambda x.f (x x))
I am wondering what capabilities of Forth we have to remove until we
have to go to these lengths.
- anton
--
M. Anton Ertl http://www.complang.tuwien.ac.at/anton/home.html
comp.lang.forth FAQs: http://www.complang.tuwien.ac.at/forth/faq/toc.html
New standard: http://www.forth200x.org/forth200x.html
EuroForth 2013: http://www.euroforth.org/ef13/
Back to comp.lang.forth | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Y combinator Lars Brinkhoff <lars.spam@nocrew.org> - 2013-10-03 09:57 +0200
Re: Y combinator anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-10-03 13:09 +0000
Re: Y combinator Lars Brinkhoff <lars.spam@nocrew.org> - 2013-10-07 15:06 +0200
csiph-web