Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.forth > #1008
| From | David Kuehling <dvdkhlng@gmx.de> |
|---|---|
| Newsgroups | comp.lang.forth |
| Subject | Re: Implementation of execute-parsing-file |
| Date | 2011-04-05 11:58 +0200 |
| Message-ID | <87oc4lj9yz.fsf@mosquito.pool> (permalink) |
| References | <ineol4$9je$1@dont-email.me> |
>>>>> "Gerry" == Gerry Jackson <gerry@jackson9000.fsnet.co.uk> writes: > There have previously been discussions on the issue of using ANS Forth > words such as WORD, SOURCE, >IN etc on a text file that is not a Forth > source file e.g. see > https://groups.google.com/group/comp.lang.forth/browse_frm/thread/2debffde7a48617f/fb21c08ade99ef93?hl=en&lnk=gst&q=file-source#fb21c08ade99ef93 > https://groups.google.com/group/comp.lang.forth/browse_frm/thread/93aac6e9ce493606/7cf533cf0afb8c90?hl=en&lnk=gst&q=file-source#7cf533cf0afb8c90 > GForth has a word EXECUTE-PARSING-FILE that can be used to parse and > process a non-Forth text file but, AFAIK, there isn't an ANS Forth > implementation. Anton Ertl implemented a related word called > EXECUTE-PARSING in ANS Forth, see > https://groups.google.com/group/comp.lang.forth/browse_frm/thread/1434bda49fa6d48c/b70e1d9320747fbc?hl=en&lnk=gst&q=%22prepended+to+the+string%22#b70e1d9320747fbc > Having a need for an ANS Forth EXECUTE-PARSING-FILE I used the method > in EXECUTE-PARSING to implement it and integrated the two to get: I didn't take the time to analyze your implementation in detail, but I think it fails at REFILL, which would advance by a single line in EXECUTE-PARSING-FILE but which will skip to the end of the file with your implementation. An easy way to test that is to do POSTPONE \ with your implementation which would skip more than just a single line. (I was looking at this example that removes comments starting on '#' from a file: http://mosquito.dyndns.tv/freesvn/trunk/scriptometer/remove_comments.fs) cheers, David -- GnuPG public key: http://user.cs.tu-berlin.de/~dvdkhlng/dk.gpg Fingerprint: B17A DC95 D293 657B 4205 D016 7DEF 5323 C174 7D40
Back to comp.lang.forth | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Implementation of execute-parsing-file Gerry Jackson <gerry@jackson9000.fsnet.co.uk> - 2011-04-05 10:50 +0100
Re: Implementation of execute-parsing-file David Kuehling <dvdkhlng@gmx.de> - 2011-04-05 11:58 +0200
Re: Implementation of execute-parsing-file Gerry Jackson <gerry@jackson9000.fsnet.co.uk> - 2011-04-05 12:26 +0100
Re: Implementation of execute-parsing-file Josh Grams <josh@qualdan.com> - 2011-04-05 22:35 +0000
Re: Implementation of execute-parsing-file BruceMcF <agila61@netscape.net> - 2011-04-05 18:31 -0700
Re: Implementation of execute-parsing-file Gerry Jackson <gerry@jackson9000.fsnet.co.uk> - 2011-04-06 10:15 +0100
Re: Implementation of execute-parsing-file BruceMcF <agila61@netscape.net> - 2011-04-06 09:04 -0700
Re: Implementation of execute-parsing-file Josh Grams <josh@qualdan.com> - 2011-04-07 10:19 +0000
Re: Implementation of execute-parsing-file BruceMcF <agila61@netscape.net> - 2011-04-07 07:54 -0700
Re: Implementation of execute-parsing-file anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2011-04-07 16:32 +0000
Re: Implementation of execute-parsing-file BruceMcF <agila61@netscape.net> - 2011-04-08 18:22 -0700
Re: Implementation of execute-parsing-file anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2011-04-09 13:10 +0000
Re: Implementation of execute-parsing-file BruceMcF <agila61@netscape.net> - 2011-04-09 12:43 -0700
Re: Implementation of execute-parsing-file anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2011-04-10 13:22 +0000
Re: Implementation of execute-parsing-file BruceMcF <agila61@netscape.net> - 2011-04-10 09:44 -0700
Re: Implementation of execute-parsing-file anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2011-04-11 14:22 +0000
Re: Implementation of execute-parsing-file BruceMcF <agila61@netscape.net> - 2011-04-11 08:37 -0700
Re: Implementation of execute-parsing-file BruceMcF <agila61@netscape.net> - 2011-04-11 09:05 -0700
Re: Implementation of execute-parsing-file anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2011-04-13 16:50 +0000
Re: Implementation of execute-parsing-file BruceMcF <agila61@netscape.net> - 2011-04-13 12:37 -0700
Re: Implementation of execute-parsing-file Andrew Haley <andrew29@littlepinkcloud.invalid> - 2011-04-10 02:55 -0500
Re: Implementation of execute-parsing-file anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2011-04-10 13:11 +0000
Re: Implementation of execute-parsing-file Andrew Haley <andrew29@littlepinkcloud.invalid> - 2011-04-10 09:27 -0500
Re: Implementation of execute-parsing-file anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2011-04-11 14:11 +0000
Re: Implementation of execute-parsing-file Doug Hoffman <glidedog@gmail.com> - 2011-04-07 11:46 -0400
Re: Implementation of execute-parsing-file BruceMcF <agila61@netscape.net> - 2011-04-08 18:24 -0700
Re: Implementation of execute-parsing-file Doug Hoffman <glidedog@gmail.com> - 2011-04-09 02:53 -0400
Re: Implementation of execute-parsing-file BruceMcF <agila61@netscape.net> - 2011-04-09 13:01 -0700
Re: Implementation of execute-parsing-file BruceMcF <agila61@netscape.net> - 2011-04-06 09:14 -0700
Re: Implementation of execute-parsing-file Gerry Jackson <gerry@jackson9000.fsnet.co.uk> - 2011-04-06 10:15 +0100
csiph-web