00:00:00 --- log: started forth/02.11.23 02:09:27 --- log: started forth/02.11.23 02:09:27 --- join: clog (nef@bespin.org) joined #forth 02:09:27 --- topic: 'Forth will NEVER be universally accepted. Haha, up yours lamers | IsForth: runs on linux, coded in x86 asm - http://isforth.clss.net | official forth sites: http://www.ultratechnology.com/forth.htm & http://www.colorforth.com' 02:09:27 --- topic: set by futhin on [Mon Nov 18 11:24:57 2002] 02:09:27 --- names: list (clog fridge Fractal XeF4 proteusguy TreyB onetom skylan Robert OrngeTide @ChanServ ianni) 04:37:47 Good morning. 04:58:47 morning 04:59:04 afternoon 05:10:31 Heh. 05:10:42 Right. 06:32:01 --- quit: proteusguy ("Client Exiting") 07:07:47 --- join: ASau (~asau@158.250.48.197) joined #forth 07:08:07 Good evening! 07:10:54 I've made a discovery right now. 07:11:30 Hi :)= 07:11:32 Tell us. 07:12:00 Just one simple thing to eliminate awk. 07:12:20 Technology follows. 07:12:49 1) Reading line: 0 WORD 07:13:53 2) Moving HERE: HERE DUP DUP 2 + DP +! 07:14:12 (Old HERE is stored on stack.) 07:14:56 3) Moving IN: IN @ OVER 1+ IN ! 07:15:30 Now we can separate readed line into field by simple BL WORD. 07:15:34 :) 07:15:47 That's like awk. 07:16:28 What do you think? 07:17:16 Ehm. 07:17:23 I've never used awk. 07:17:32 (C) Aleksey Saushev, 2002. Under DSL, see http://dsl.org for details. :) 07:17:38 Hehe. 07:19:15 "All you need is Forth... Forth is all you need." :))) 07:20:31 I use awk to deal with tables and lists. 07:20:58 "There's nothing you can do that can't be done." ;) 07:21:12 I use awk instead excel&other "spreadshit". 07:21:24 Hehe. 07:21:33 I don't deal with them at all ;) 07:22:38 How would you like 26000000 bytes of records: ? 07:23:09 Huh? 07:23:16 Ya, in _text_ format, line by line. 07:24:40 That's my course paper calculations. 07:25:17 One parameter Schroedinger equation. 07:29:31 By the way. I celebrate birthday tomorrow. 07:30:42 Hmm... 07:31:02 My tech. is much better than awk. 07:31:30 I can use different separators for fields in the same line. 07:32:50 One thing isn't present, regexps. But it also can be done. 07:33:09 Congratulations then :-) 07:33:19 How old are you getting? 07:33:26 I have code for MATCH, substr. search. 07:33:31 Hehe. 07:33:40 21. 07:33:52 String parsing in Forth...not funny without addressing regisers or similar. 07:34:00 Not that old for being in #forth ;) 07:34:23 43 years to be 64 :) 07:34:39 are there other older people in here than i440r? 07:34:56 I thought just about everyone was 15-25 here 07:35:10 Hm. 07:35:30 MrReach, Herkamire, er.. and some others. 07:35:56 TheFox definitly ;) 07:36:01 I haven't seen MrReach in aeons 07:36:05 Not sure how old onetom and the others are. 07:36:09 No :-/ 07:36:20 onetom is 21 or so I thought 07:36:32 I thought he was a bit older. 07:36:37 onetom: Wake up! :) 07:36:38 could be 07:36:42 Approx. 1:1, as I can see. :) 07:36:46 I'm 22+3 weeks 07:37:53 I'm 16+..er..quite a few weeks. 07:42:07 BTW, does Serg_penguin appear on channel? 07:42:50 He's joining 20 times a day. 07:43:04 Average length of 5 minutes ;) 07:43:36 When I get home from school, I usually see 10 new "Hello?"s in his query. 07:43:51 He is hiding from his boss. 07:45:05 Yeah. 07:46:04 He'd chosen wrong parents, that's why he is to earn money instead of university. :( 07:46:28 :-/ 07:50:22 Hmm. Does anyone know what for IEEE proposed so ugly representation of float point numbers. 07:50:38 What the hell it is! 07:52:21 I'm thinking about floating point in my Forth, and Tracy's 1-screen f.p. seems to be much better choice. 07:53:08 I think to modify his technology. 07:53:30 His f.p.: cell-mantissa cell-magnitude 07:53:53 My f.p.: double/triple-mantissa cell-magnitude 07:54:12 Both base 10. 07:55:16 I.e. (mant/10 magn+1) = (mant magn). 07:55:34 Hm. 07:56:05 I need a simple floating-point implementation... 07:56:10 Do you have any sources? 07:56:44 Look at ftp.taygeta.com/pub/Forth/Archive/ibm/ 07:56:58 OK. 07:57:33 There're much old stuff, although _very_interesting_ stuff. 07:58:21 IIRC, zenfloat.arc or .zip 07:58:42 How do I uncompress .arc files? 07:59:11 pkxarc.exe or .com 07:59:28 Any Linux software? 08:00:18 dosemu+pkxarc or dosemu+pkunpak or, maybe, dosemu+unarc. 08:00:40 I don't know about linux soft. 08:01:16 * Robert browses apt. 08:01:23 Although... 08:01:33 I-net is large. 08:02:44 :) 08:02:46 Amen. 08:03:51 About two weeks ago I erased my slack. 08:04:25 I've found that all I need from linux also DOS offers. 08:04:31 --- join: tathi (~josh@ip68-9-58-207.ri.ri.cox.net) joined #forth 08:04:43 DOS uses much less space. 08:05:44 Good evening, tathi! 08:06:10 News of the day. 08:06:29 Awk is to be eliminated by Forth. 08:06:40 Justification. 08:06:45 hi ASau 08:06:55 I'm not a big fan of Awk 08:06:58 but cool ;) 08:07:36 1. Reading line: 0 WORD (or EXPECT, or QUERY, I don't know ANTI) 08:08:10 2. Adjusting HERE: HERE DUP DUP C@ 2+ DP +! 08:08:44 3. Changing IN: IN @ OVER 1+ IN ! 08:09:09 Now BL WORD selects fields of line readed. 08:09:11 ASau: Not for me :) 08:09:31 Aka, $1, $2 etc. after awk. 08:09:42 (C) :) 08:10:28 :) 08:10:42 RE in Forth are needed to eliminate uncoditionally. 08:10:59 I think on this problem. 08:11:34 yeah, I'd like a forth regexp library at some point... 08:11:38 I think 08:13:23 Another choice is patterns a-la SNOBOL4. 08:14:59 not familiar with that 08:15:12 www.snobol4.com 08:15:32 ...IIRC 08:21:12 interesting 08:22:05 Its patterns are stronger than REs. They can mathch more complex things. 08:23:47 In fact, if I limit REs to be without sub-REs, everything is just clear. 08:24:27 Oh! Be back... 08:24:29 --- quit: ASau ("Toffee IRC client for DOS v1.0/b535") 08:29:45 --- join: ASau (~asau@158.250.48.197) joined #forth 08:31:23 --- quit: ASau (Client Quit) 08:33:45 --- join: ASau (~asau@158.250.48.197) joined #forth 08:33:55 Robert: 08:34:19 I've found, where're sources for you. 08:35:12 Go to RuFIG, forth.org.ru, find Members->Filutitch aka Dr.Cactus. 08:35:26 From his site zenmath.rar 08:35:50 Or search RuFIG->Resources for zenmath.rar 08:36:27 I don't remember more precise address. 08:36:53 unrar should be in linux distr. 08:38:08 Or, http://filesearch.ru :) 08:38:33 Yeah, I have unrar. 08:38:49 I'll check, thanks. 08:39:45 That source is almost the same, it is adapted for another system and is more readable. 08:40:08 In zenfloat everything is compressed to fit 1 screen. 08:42:31 Hrm. 08:42:38 ? 08:42:39 I can't find that long. 08:42:43 link* 08:42:55 The font doesn't work either. 08:43:29 Aleksey Filutitch, IIRC, there everything is Latin transliterated. 08:43:29 Ah 08:43:34 I think I'v found it. 08:43:45 Or, Alexei... 08:43:50 It certainly isn't :) 08:44:08 forth.org.ru/~cactus ? 08:45:18 Yes, that one. 08:46:47 --- join: wossname (wossname@HSE-QuebecCity-ppp81227.qc.sympatico.ca) joined #forth 08:47:45 Have you got that file? 08:48:27 forth.org.ru/~cactus/4th/zenmath.rar 08:53:24 Robert, what browser do you use? 08:53:47 Mozilla? 09:03:08 Bye! 09:03:09 --- quit: ASau ("Toffee IRC client for DOS v1.0/b535") 09:35:28 --- join: gameboy (~wer@81.25.34.11) joined #forth 09:35:42 Hi :) 09:36:09 goodhi 10:29:10 --- nick: gameboy -> divgrad 10:31:36 --- part: divgrad left #forth 11:29:22 --- quit: tathi ("leaving") 11:34:46 --- quit: wossname ("lol, bbl, omgwtf") 11:49:48 --- join: tathi (~josh@ip68-9-58-207.ri.ri.cox.net) joined #forth 12:03:56 --- join: neobrat (neobrat@0-1pool79-249.nas6.salt-lake-city1.ut.us.da.qwest.net) joined #forth 12:05:21 yay, _finally_ finished rebuilding SVN :) 12:06:24 gratz 12:15:34 well, to be fair, everything involved has gotten easier to build 12:16:34 and knowing that I shouldn't try to build apache 2 with anything other than the default layout... 12:17:32 hehe ;) 12:18:21 so...what's up? 12:18:43 not much... posted my compiler on a GBA dev site 12:18:47 www.gbadev.org 12:18:58 getting lots of emails about it :) 12:19:32 is that a good thing or a bad thing? :) 12:19:42 well, they are good emails :) 12:19:50 people that want to use it, etc. 12:20:07 lots of people that don't know what FORTH is that are asking about it 12:20:26 excellent 12:20:53 --- join: fridge_ (~fridge@dsl-203-33-161-178.NSW.netspace.net.au) joined #forth 12:21:42 sped up my 3d rendering by about 3x, too -- so im happy :) 12:22:37 --- quit: fridge (Read error: 110 (Connection timed out)) 12:22:45 --- nick: fridge_ -> fridge 12:22:57 sounds good 12:22:58 you time out fast, fridge 12:50:31 =( 13:28:55 --- quit: neobrat () 13:50:00 --- quit: tathi ("leaving") 14:11:03 --- join: TheBlueWizard (TheBlueWiz@ip-216-25-205-162.vienna.va.fcc.net) joined #forth 14:11:09 hiya all 14:11:30 hey 14:13:02 hiya fridge 14:30:43 Hi TheBlueWizard, fridge 14:33:12 hiya Robert 14:33:46 Hmm.. 14:34:33 I should write a Forth for my AVR VM. That way I could code Forth on a cmoputer small enough for my sister's hamster to carry. 14:35:16 AVR? 14:35:49 Yes, an Atmel microcontroller. 14:38:14 hmm...never heard of it 16:42:57 gotta go...bye all 16:46:01 --- part: TheBlueWizard left #forth 17:29:04 --- join: jamc (~user@as3-6-8.asp.s.bonet.se) joined #forth 17:39:23 Hej. 18:05:44 hoi 18:11:52 :) 18:12:00 Hoe gaat het met jou? 18:29:41 no svenskaa 18:31:16 bara french, english 18:32:20 That was no Swedish. 18:32:31 I replied in the language you greeted me in! 18:40:25 hehe 18:40:39 :) 18:42:20 riktig.. 18:42:31 du har rätt 18:42:43 Ik weet dat. >:) 18:44:13 not in the dictionary :) 18:45:14 That's because I reply using the few words od Dutch I know. 18:45:27 If you use a language you don't know, then so do I. 18:47:29 Weltrusten! / God natt! 18:53:09 night :) 20:00:11 --- join: lament (~lament@h24-78-145-92.vc.shawcable.net) joined #forth 20:08:35 --- quit: onetom (Read error: 113 (No route to host)) 20:09:13 --- join: onetom (~tom@novtan.bio.u-szeged.hu) joined #forth 20:16:27 hi 1tom 20:19:54 whee 20:20:05 starting forth is a much better intro than the gforth tutorial 20:20:33 you found a copy? 20:20:49 yeah 20:20:55 online? 20:21:00 was talking to someone on irc 20:21:08 they had a copy that they never read 20:21:12 and offered to give it to me 20:21:19 nah, the real thing 20:21:35 had to go for a bit of a drive to get it, but well worth it 20:25:32 I have both Starting Forth and Thinking Forth. I found TF much more interesting. 20:27:35 thinking forth ward 20:31:21 I'll have to hunt someone down with TF after I've finished with this book 20:36:43 --- quit: jamc ("Don't SANFORIZE me!!") 20:57:14 Hmm, is there a good forth book/advanced tutorial online? 20:58:59 gforth has a manual/tutorial... I won't go so far as to call them good 21:01:22 heh. 21:20:14 What does the word HERE do? 22:13:16 Also, does anyone need a forth mode for nedit? :) 22:14:41 lament: I wouldn't mind one 22:14:57 The one on nedit.org doesn't even seem to work 22:15:05 So I'm making one 22:15:29 Right now it matches comments and word definitions (highlighting the new word's name) 22:15:40 What else should it do? 22:19:37 Oh - ." strings" , of course 22:22:28 What else? 22:30:55 so eg, : foo would make : bold and foo psychedelic purple or so? 22:31:29 * XeF4 wants to see it when it works 22:31:36 s/works/is finished/ 22:36:48 XeF4: yes, 22:36:53 exactly :) 22:37:09 well, it's pretty much finished unless i think of something else to highlight 22:51:37 lament : The word here pushes to current heap pointer onto the stack. 22:51:57 So, here pushes the next address that stuff will be compiled to. 22:53:13 The word , increases here. 22:53:26 here usually is defined as : here h @ ; 22:53:56 So , is: : , h 1 cells +! ; 22:54:33 interesting 22:55:10 , comes in handy especially when compiling arrays. 22:55:19 on ppforth, the actual definitions are : here cp @ ; and : , here dup cell+ cp ! ! ; 22:55:25 is that pretty much the same? 22:55:46 lament : Yes, almost exactly. Some systems use H as the variable, I guess ppforth uses CP 22:56:00 : , here ! cell h +! ; 22:56:15 Fractal: , also moves a word from the stack to the heap 22:56:25 XeF4 : Sorry, you're right. 22:56:30 Fractal: yes, but the definition of , is quite different 22:57:03 lament : Well, xef4 is right, it also !'s a var to the heap before incrementing. Also, +! is just a shorter way of writing that. 22:57:33 interesting 22:57:36 ppforth does have +! 22:58:07 Yes, basically it just means, add this number to this var location. 22:58:24 10 my-var +! 23:00:10 actually : , here cell allot ! ; would be better since having multiple allocation routines is generally bad 23:00:21 if one day you decide to start storing tmp data at just above HERE 23:00:45 As pad does. 23:02:21 Actually, I believe pad to be exceedingly bad programming practice. 23:02:38 Very difficult to write reentrant code with pad. 23:19:27 Is recursion wasteful? Should it be avoided? 23:19:37 not if it's done right 23:20:14 --- join: Sulvey (~not@h24-65-137-230.ed.shawcable.net) joined #forth 23:21:45 Right as in?.. 23:22:09 as in eg, a compiler smart enough to do tail call elimination 23:22:22 so the return stack isn't pushed for every recursion 23:23:46 lament : Unfortunatley, forth compilers aren't smart enough (usually) to do this for you automatically. 23:24:15 However, it is possible to accomplish this by a simple branch rather than a call. 23:24:28 hm, interesting. Wouldn't any recursive call be tail recursion in forth? 23:24:55 lament : No, consider this: : my-func ... my-func ... ; 23:25:12 oops. 23:25:14 When my-func is reached in the definition, the addr of my-func will be compiled in. 23:25:33 And it will be treated as a normal function call. 23:26:13 However, you could do: : my-func [ here ] ... [ branch , , ] ; 23:26:17 Or something. 23:26:49 Probably won't work in most forths, though. Several forths DO define a word: ;recurse which just creates a branch to the beginning of the word. 23:27:06 So... : my-func ... ;recurse ; 23:27:45 Which is tail recursive. 23:27:51 hm 23:28:41 One of the nice things about forth is that it's inherently recursive. All the information necessary to compile a reference to the word is done as soon as create is called. 23:29:46 well, that's nice, : foo ... foo ; still doesn't work on my forth :) 23:30:02 although, in some aspects, : foo ... recurse ; is even prettier 23:30:09 lament : It ought to. See if the word recurse is defined. 23:30:12 because foo does not appear in the dictionary until after ; executes 23:30:13 Oh, cool. 23:30:19 so : foo ... .... recurse ... ; 23:30:25 or : foo ... recurse ; 23:30:31 XeF4 : What!?!? 23:30:49 heh 23:30:50 at least most forths do not add foo to the dictionary until after ; 23:31:01 That's an odd way to do it... 23:31:16 Look at the definition of : in your forth, perhaps. 23:31:29 how so? 23:32:04 Well, it ought to be something like : : create [ 23:32:33 Well, it ought to be something like : : create ] 23:32:34 I mean. 23:33:12 that will fail in most forths 23:33:28 at least every one that keeps data and code in the same memory area 23:33:50 Well, obviously defined exactly like that it won't, but see what I'm saying? 23:33:53 unless ] does some very strange jiggery pokery in addition to just setting state=-1 23:34:05 I see no reason not to link the word into the dictionary when create is called. 23:34:19 XeF4 : What else would it need to do? 23:35:18 Create creates a word that returns a pointer to the value of HERE after Create has finished. 23:35:28 so it would need to change the contents of the Created word 23:36:33 Ah yes, I suppose in a CFA forth, you'd have to set the CFA to point to : 23:36:35 what Forth are you using, Fractal? 23:36:43 XeF4 : frugal 23:36:51 XeF4 : http://www.hcsw.org/frugal/ 23:37:00 * XeF4 remembers Frugal 23:37:17 none of the words besides maybe basic arithmetic work like they do in every other forth 23:37:26 Is there documentation included in the .tgz files for frugal? 23:37:41 Sulvey : Yes, reasonably extensive docs in the docs/ directory. 23:37:47 Thank you. 23:38:03 Including a file that documents the main differences between "conventional" forths and frugal. 23:38:24 XeF4 : Actually, that's not particularly true. 23:38:42 I'm able to port isforth programs to and from frugal while changing almost nothing. 23:39:06 Except isforth's nonstandard >! (maybe !> ?) 23:39:53 And frugal *is* a naturally recursive forth. :) 23:40:00 how so? 23:40:44 Well, as soon as a word is "create"d, it is linked into the dictionary, even though the executable segment may not yet be compiled. 23:41:35 in more conventional forths, a CREATEd word is linked immediately 23:42:14 too, but : is different, so that you can do eg, : + hocus pocus typecheck + ; 23:42:20 Well then why can't you compile a reference to a word inside it's own definition? 23:42:34 you can, you just can't reference it by name 23:42:45 because it is anonymous 23:43:42 XeF4 : Hm. In frugal, the word header is stored before the code. 23:44:01 I was under the impression this was the case in conventional forths too. 23:44:13 in most Forths, the header is stored before the code, but it isn't linked until ; executes 23:50:11 So what exactly does ; do? 23:50:38 links the header created by : with the rest of the dictonary and sets interpret state 23:50:41 All it does in frugal is compile exit 23:50:49 oh, and compile exit 23:51:25 XeF4 : How does it know where the dictinoary entry created with : is located? 23:51:37 Is that stored on the stack? 23:51:53 it is stored in a lastheader variable 23:52:06 : : HEADER 0 ] ; 23:52:29 Oh... That seems needlessly complex. 23:52:39 : ; ?STRUC COMPILE UNNEST !LENGTH COMPILE [ REVEAL ; IMMEDIATE 23:52:45 these from bigforth 23:52:46 What's the rational for not linking it in right away? 23:53:33 so you can redefine words calling older words by the same name and other similar bad practices 23:54:00 Ah, that would make sense. 23:54:22 Yes, that's one thing frugal can't do directly. 23:54:51 You can always defer the word, pass the addr on the stack, etc. 23:55:17 or : plus + ; : + plus ... ; 23:55:31 Yes, that too. 23:55:57 That's one good thing about forth: 1001 ways to do something. 23:56:12 * Sulvey coughs and mentions something about Perl's motto 23:56:17 Heh. 23:56:22 heh 23:56:35 it's probably not a good thing when there're 1001 ways to do ; 23:56:45 That's one good thing about forth: The same amount of ways perl can do something, 1 + 23:57:06 lament : Heh. That may be too. 23:57:24 * Sulvey grins and goes back to lurking 23:59:08 Sulvey : You're in edmonton? 23:59:12 Fractal: actually.. I don't find linking the word immediately an objectional practice 23:59:15 it's just unusual 23:59:36 XeF4 : Yes, I don't really object to linking up after... It's just unusual. :) 23:59:59 --- log: ended forth/02.11.23