Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.forth > #42863
| From | Paul Rubin <no.email@nospam.invalid> |
|---|---|
| Newsgroups | comp.lang.forth |
| Subject | Re: How to solve this problem in FORTH? |
| Date | 2015-10-26 21:58 -0700 |
| Organization | A noiseless patient Spider |
| Message-ID | <87y4eovrf6.fsf@jester.gateway.sonic.net> (permalink) |
| References | <f195a1a1-8609-4319-9df9-d8cbb2a11fdb@googlegroups.com> <ed5ecb8e-cb01-4acb-9e4c-0a20b12f290b@googlegroups.com> <87fv0yvz6f.fsf@jester.gateway.sonic.net> <c790e466-39c8-44e9-9109-9e2524aacab2@googlegroups.com> |
Raimond Dragomir <raimond.dragomir@gmail.com> writes:
> Why would you need a nested function for such a trivial problem?
Of course it's not needed-- it just allows a little more factoring,
which can be nice depending on your tastes.
> : vadd2
> local{ v1 v2 v3 | vadd }
> { >r v1 @ r@ th @ v2 @ r@ th @ v3 @ r> th ! } vadd !
> 0 vadd @ execute
> 1 vadd @ execute
> 2 vadd @ execute
> ;
That is nice. Note that there was a big discussion a few months ago
about whether the Forth 200x standard's quotations should allow
accessing the parent's locals like that, and I think the result was that
it was considered to potentially complicate implementations too much to
be worthwhile. If you've got a simple implementation you might want to
comment.
Back to comp.lang.forth | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
How to solve this problem in FORTH? lehs <skydda.barnen@gmail.com> - 2015-10-26 00:02 -0700
Re: How to solve this problem in FORTH? Paul Rubin <no.email@nospam.invalid> - 2015-10-26 00:58 -0700
Re: How to solve this problem in FORTH? lehs <skydda.barnen@gmail.com> - 2015-10-26 02:36 -0700
Re: How to solve this problem in FORTH? Paul Rubin <no.email@nospam.invalid> - 2015-10-26 21:56 -0700
Re: How to solve this problem in FORTH? Raimond Dragomir <raimond.dragomir@gmail.com> - 2015-10-26 03:09 -0700
Re: How to solve this problem in FORTH? Raimond Dragomir <raimond.dragomir@gmail.com> - 2015-10-26 03:14 -0700
Re: How to solve this problem in FORTH? lehs <skydda.barnen@gmail.com> - 2015-10-26 04:55 -0700
Re: How to solve this problem in FORTH? Raimond Dragomir <raimond.dragomir@gmail.com> - 2015-10-26 05:11 -0700
Re: How to solve this problem in FORTH? humptydumpty <ouatubi@gmail.com> - 2015-10-26 06:35 -0700
Re: How to solve this problem in FORTH? lehs <skydda.barnen@gmail.com> - 2015-10-26 12:25 -0700
Re: How to solve this problem in FORTH? humptydumpty <ouatubi@gmail.com> - 2015-10-27 00:47 -0700
Re: How to solve this problem in FORTH? lehs <skydda.barnen@gmail.com> - 2015-10-27 08:06 -0700
Re: How to solve this problem in FORTH? humptydumpty <ouatubi@gmail.com> - 2015-10-27 23:43 -0700
Re: How to solve this problem in FORTH? lehs <skydda.barnen@gmail.com> - 2015-10-28 01:30 -0700
Re: How to solve this problem in FORTH? humptydumpty <ouatubi@gmail.com> - 2015-10-28 01:58 -0700
Re: How to solve this problem in FORTH? franck.bensusan@gmail.com - 2015-10-28 02:56 -0700
Re: How to solve this problem in FORTH? lehs <skydda.barnen@gmail.com> - 2015-10-28 03:36 -0700
Re: How to solve this problem in FORTH? Hans Bezemer <the.beez.speaks@gmail.com> - 2015-10-28 15:31 +0100
Re: How to solve this problem in FORTH? Paul Rubin <no.email@nospam.invalid> - 2015-10-26 21:58 -0700
Re: How to solve this problem in FORTH? Raimond Dragomir <raimond.dragomir@gmail.com> - 2015-10-26 23:38 -0700
Re: How to solve this problem in FORTH? anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2015-10-27 09:24 +0000
Re: How to solve this problem in FORTH? Raimond Dragomir <raimond.dragomir@gmail.com> - 2015-10-27 02:54 -0700
Re: How to solve this problem in FORTH? mhx@iae.nl - 2015-10-26 11:31 -0700
Re: How to solve this problem in FORTH? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-10-26 04:54 -0400
Re: How to solve this problem in FORTH? Paul Rubin <no.email@nospam.invalid> - 2015-10-26 02:09 -0700
Re: How to solve this problem in FORTH? Ron Aaron <rambamist@gmail.com> - 2015-10-26 11:16 +0200
Re: How to solve this problem in FORTH? Lars Brinkhoff <lars.spam@nocrew.org> - 2015-10-26 10:49 +0100
Re: How to solve this problem in FORTH? Hans Bezemer <the.beez.speaks@gmail.com> - 2015-10-28 11:22 +0100
Re: How to solve this problem in FORTH? Howerd <howerdo@yahoo.co.uk> - 2015-10-28 04:09 -0700
Re: How to solve this problem in FORTH? hughaguilar96@gmail.com - 2015-10-29 19:52 -0700
Re: How to solve this problem in FORTH? "WJ" <w_a_x_man@yahoo.com> - 2015-10-30 09:00 +0000
Re: How to solve this problem in FORTH? lehs <skydda.barnen@gmail.com> - 2015-10-26 02:44 -0700
csiph-web