home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / lang / forth / 3669 < prev    next >
Encoding:
Internet Message Format  |  1992-12-25  |  2.7 KB

  1. Path: sparky!uunet!paladin.american.edu!gatech!pitt.edu!pitt!willett!ForthNet
  2. From: ForthNet@willett.pgh.pa.us (ForthNet articles from GEnie)
  3. Newsgroups: comp.lang.forth
  4. Subject: Experimental Ideas
  5. Message-ID: <4179.UUL1.3#5129@willett.pgh.pa.us>
  6. Date: 25 Dec 92 10:08:39 GMT
  7. Organization: EIEI-U
  8. Lines: 59
  9.  
  10. Category 3,  Topic 5
  11. Message 87        Sun Dec 13, 1992
  12. ELLIOTT.C                    at 20:44 EST
  13.  
  14.  -----via CRS Premium Bulletin Board -
  15.  USR Dual Standard 16.8K  (416) 629-7000
  16.  
  17.    To: ALL
  18.  From: MARCEL HENDRIX
  19.  Subj: STOIC?
  20.  
  21.  dw> + At EuroForth '92 Christophe Lavarenne (`FreeForth') proposed to
  22.  dw> + get rid of the Forth interpreter altogether and use a "compile
  23.  dw> + buffer" (my interpretation). The idea, which has also been
  24.  dw> + proposed by Mitch Bradley and John Hayes (among others), is to
  25.  dw> + compile each line typed by the user into a nameless colon
  26.  dw> + definition, execute that code and forget it again.
  27.  
  28.  dw> It is even worse than that.  What if the user uses CREATE DOES>
  29.  dw> in the nameless colon definition?  Better not forget that code!
  30.  
  31.  Ok, in practice this will mean you can do more than the
  32.  interpreter allows, but still not everything. I'd say the code is
  33.  temporary by definition, so what you want with DOES> is clearly
  34.  illegal (in that it can't work :)
  35.  
  36.  dw> If that code also does ALLOT or HERE manipulation, what does
  37.  dw> "forgetting" it mean?
  38.  
  39.  The final result must be the same as typing  5 ALLOT  or  CREATE
  40.  foo 3 , that is, the change is ``permanent''. It has to be.  Of
  41.  course the compiled (temporary) code cannot reside at HERE , if
  42.  that is what you meant. That would interfere with about anything.
  43.  
  44.  dw> Once you do that, are you really doing FORTH anymore, or is it
  45.  dw> something else?  It seems to me that the simplicity of the top
  46.  dw> level comes by avoiding all that hairy stuff.
  47.  
  48.  To do it well, a string stack (not known and not a number  foo :
  49.  1+ ; ) or changed syntax ( S" foo" : 1+ ; ) is needed.  As people
  50.  have mentioned already, it then starts to resemble STOIC (don't
  51.  know it, but looks interesting). The version with the S" may be
  52.  possible with little internal change and very little side
  53.  effects, but it sure gives a different look to the source code.
  54.  
  55.  Marcel Hendrix,
  56.  Dutch Forth Workshop
  57.  
  58.  NET/Mail : FS FORTH Systeme BBS West Germany ++49 7667 556
  59.  ---
  60.   * The GrapeVine/Ferret Face BBS * NLR,ARK * 501-753-8121 DS *
  61.   * PostLink(tm) v1.04  GRAPEVINE (#318) : RelayNet(tm) Hub
  62.  
  63.  
  64. -----
  65. This message came from GEnie via willett.  You *cannot* reply to the author
  66. using e-mail.  Please post a follow-up article, or use any instructions
  67. the author may have included (USMail addresses, telephone #, etc.).
  68. Report problems to: dwp@willett.pgh.pa.us
  69.