00:00:00 --- log: started forth/02.11.06 01:01:42 --- quit: XeF4 ("pois") 02:27:46 --- quit: Soap` (Read error: 104 (Connection reset by peer)) 02:36:23 --- join: Xuz (aemerson@bgp01132867bgs.ypeast01.mi.comcast.net) joined #forth 02:51:16 Hi. 02:51:54 Hiya 05:29:56 --- quit: Xuz ("Zzzzzzzzzzzzzzzzzzzzzzzzzzzzz-POP!") 05:41:28 --- quit: skylan (Read error: 104 (Connection reset by peer)) 05:42:31 --- join: skylan (sjh@207.164.213.149) joined #forth 05:45:39 --- join: XeF4 (xef4@lowfidelity.org) joined #forth 06:09:14 --- join: Herkamire (~jason@wsip68-15-54-54.ri.ri.cox.net) joined #forth 06:16:51 --- join: Herkamir1 (~jason@wsip68-15-54-54.ri.ri.cox.net) joined #forth 06:34:01 --- quit: Herkamire (Read error: 110 (Connection timed out)) 07:00:48 --- join: Herkamire (~jason@wsip68-15-54-54.ri.ri.cox.net) joined #forth 07:17:22 --- quit: Herkamir1 (Read error: 110 (Connection timed out)) 07:18:04 --- quit: skylan ("blah") 07:44:39 hmm 07:44:43 * ianni launches is4th 08:07:31 --- join: tathi (~josh@wsip68-15-54-54.ri.ri.cox.net) joined #forth 08:18:04 Hello all. 08:18:42 hey Robert 08:21:02 hey 08:21:12 Thanks for the NEXT help. 08:21:23 who me? 08:21:31 Nah, tathi. 08:21:34 ah 08:21:39 But I can hug you too, if you want. 08:21:45 so, I'm gonna build something to model an elevator system in forth 08:21:51 Robert: ok :) 08:22:00 so how can I store something more than numbers in arrays? 08:22:14 should i use a struct-like thing or something? 08:22:27 ive never really done any memory management 08:22:47 You could...just calculate the address as sizeof(structure)*index + base. 08:23:52 right, just like C! 08:23:55 what NEXT help? 08:24:10 create struct-array my-struct size * allot 08:24:10 so orientation-wise, how do i have a point of reference? what does HERE mean? 08:24:39 tathi: Wasn't it you who mailed Jeff Fox and asked about SWAP in machineforth. 08:24:48 Ooops. Just notices. NEXT should be SWAP. 08:24:52 noticed 08:25:38 Well, homework time. 08:29:14 enjoy 08:29:22 ianni: HERE gives you a memory address. that address points at the memory that you can fill using , (comma) or ALLOT 08:29:35 (or c,) 08:31:29 You can also use an existing structures implementation. 08:35:56 aaaaaaaaa no 08:36:28 learn to mannage memory addresses 08:40:19 I think it's pretty interesting that Jeff Fox and Chuck Moore pretty much Never use SWAP. 08:40:54 I'll have to look at my code and see how much I do 08:41:42 I should do the same, and see if I can avoid it. 08:46:36 Ifigured HERE would do that 08:46:46 the implementation behind it will find me some free space, right? 08:49:01 HERE will just return the dictionary pointer. 08:49:11 ALLOT allocates space for you on the dictionary. 08:50:04 "on the dictionary 08:50:06 "? 08:51:50 Ehm. 08:51:55 Do you know what a dictionary is? 08:52:29 It's like a stack, but you never pop anything from it, you only "push" data to the top of it. 08:52:46 That's where everything is stored. 08:52:58 Compiled code, space for variables and so on,. 08:53:52 you can drop off the dictionary 08:53:54 with forget 08:54:04 which is like pop to /dev/null 08:54:14 Robert: not really, that's why im asking all these basic questions 08:54:33 this makes sense 08:54:43 forth's 'heap' so to spea 08:54:44 Well... that's however not what you usually do. At least I don't :) 08:54:44 kk 09:17:51 ALLOT allocates memory on the _HEAP_ 09:18:14 this doen't generally have anything to do with the dictionary 09:18:29 Herkamire: Oh, I see. 09:19:15 the heap is a big wad of memmory that the forth system uses, and that you can use yourself. 09:21:04 everything below HERE is used. 09:23:18 great 09:24:09 now - where is some code I can look at to see someone using sctructures 09:27:43 Sorry. 09:27:46 I was confusing terms. 09:27:51 * Robert hides. 09:28:18 * ianni isnt confused quite yet 09:28:19 Get taught by me - say goodbye to your future. 09:34:07 lol 09:40:18 I dont see i44or using it aynwhere.. hmm 09:40:31 o no h does 09:40:32 cool 09:41:37 Using what? 09:44:22 struct 09:44:24 s 09:44:43 Oh, yes. 09:52:02 --- join: proteusguy (~username@65.191.88.177) joined #forth 09:55:11 Hi proteusguy. 09:55:52 I'm just wondering, how hard would it be to construct a system that can run program code from RAM? That's the only thing I miss with the microcontrollers. 09:56:16 And writing a virtual machine seems a bit..well..slow. Even though that is what I am doing now. 09:58:36 * Robert just notices Z80s and such are very cheap ;) 09:58:49 Hey Robert - I dunno. Actualy I wasn't aware of any such restriction in the AtMel or that it even knew its cost mem was RAM or ROM. 10:01:40 Do you have any idea how external SRAM is connected? 10:03:17 Its been a while since I looked at the AtMel. Does it have address lines going out like a cpu? 10:06:41 Robert - sorry I gotta run to lunch. TTYL. 10:10:40 Bye. 10:12:20 ianni: don't use structs. Do it yourself 10:13:15 ianni: use: , c, allot 10:13:34 Herkamire: yeah, I need to understand how those work before I use them anyway 10:13:34 ianni: use ! and @ and calculate memory addresses 10:13:49 proteusguy: With a special control bit set, it can do that. 10:14:14 Herkamire: ALLOT is like malloc ? 10:14:20 what's c, ? 10:14:49 allot is sorta like malloc. 10:15:15 You usually can't just free() the memory, though. 10:15:29 I wouldn't expect to 10:24:15 so if i am creating an elevator system, and I want to associate things with each 'floor' or whatever 10:24:31 i would maybe want a master array of elevator variables and... 10:24:48 I have no idea what you are trying to accomplish 10:25:09 well, say I jsut want to pretend im writing an elevator system (per onetom's idea) 10:25:26 so ill create 10 "floors" and pretend people are getting in and outrandomly or something 10:25:44 so i need to know the state of the actual elevator... hrm 10:26:08 my instinct as an OO developer would be to have instance variables for each floor 10:26:24 and maybe some global indicator of status 10:26:31 hrmm 10:27:28 I want to use structs :) 10:27:39 but i definitely shouldn't 10:28:32 a fixed length array should work fine 10:53:37 --- join: I440r (~mark4@sdn-ap-012tnnashP0397.dialsprint.net) joined #forth 10:59:00 re I440r 11:00:01 hi 11:05:41 I wonder if my library would have any forth books 11:05:56 im gonna go find out 11:09:05 Hi I440r. 11:09:41 I440r: How should I do with all the constants connected to e.g. the syscall in IsForth? 11:10:07 Should they be defined in linux.f? 11:30:18 --- quit: I440r (Read error: 60 (Operation timed out)) 11:34:58 --- join: gilbertbsd (~gilbertbs@67.97.122.63) joined #forth 11:35:39 hullo 11:36:30 Hi gilbertbsd. 11:37:16 hey have you ever read RAndall Hyde's asm tutorial? 11:40:37 No. 11:40:47 I read asm sources instead ;) 11:42:47 do you now? 11:45:09 Sometimes. 12:23:52 --- join: I440r (mark4@sdn-ap-032tnnashP0269.dialsprint.net) joined #forth 12:24:07 http://www.chipcenter.com/eexpert/dashby/dashby041_tyn_puzzle.jpg;$sessionid$LYY2EGIAACFAUQSNDISCFEQ 12:24:09 someone explain that to me 12:41:39 --- quit: gilbertbsd (Read error: 110 (Connection timed out)) 12:41:51 I440r: look at the grid :) 12:42:27 * ianni 's seen that one before 12:45:57 ianni i was. i dont get it :) 12:46:23 damn that's well done :) 12:50:13 the line from the top right to the left corner on the two figures is not straight. on the top one in is bowed down. on the bottom one in is bent the other way. 12:53:38 Yep - red object has a slope of 3/8 whereas green is 2/5. Good eye. 12:58:29 aha 13:06:45 hehe 13:06:52 I remember I was boggled by it too 13:06:58 so I helf up a piece of paper - lo and behold :) 13:07:00 held 13:27:06 :) 13:27:14 im so pissed 13:27:17 I found forth books at my library 13:27:22 lots better than anything i found on the web 13:27:30 but i couldnt check them out, they wouldnt give me a library card 13:27:37 because my current address I wrote down doesnt match my ID 13:27:41 Mother fuckers. 13:27:44 :P 13:28:03 its cool, with forth i can pick all the old books and they wont be out of date :) 13:29:32 --- join: skylan (sjh@Rockcliffe71.tbaytel.net) joined #forth 13:56:19 20:13 < Robert> I440r: How should I do with all the constants connected to e.g. 13:56:20 the syscall in IsForth? 13:56:20 20:13 < Robert> Should they be defined in linux.f? 13:56:30 I440r: Hi again.. 13:56:53 erm 13:57:07 you lost me 13:57:29 Yup. 13:57:40 I saw you were disconnected right after that 13:58:09 my machine crashed, i didnt see your question at all then heh 13:58:18 and i dont understand what you mean now 13:58:24 what about ? 13:58:38 \ive defined a file.f with some useful file handling words 13:58:55 Hmmm 13:59:00 Didn't sere that 13:59:03 mechecks 13:59:21 Not in my version :-/ 13:59:45 no, its going to be in the NEXT release heh 14:01:50 Bah. 14:01:53 Hurry! :P 14:02:32 I'm actually using IsForth to do some simulation of microcontroller applications I'm working with. 14:02:49 cool :) 14:02:57 Noticed the development of it became _extremley_ fast. /me hugs Chuck and I440r :P 14:03:13 btw, you're into the 8051 series of mcs, right? 14:04:26 yes 14:05:07 Neat.. how's the instruction set? 14:05:49 * Robert is planning to get some of them. 14:05:53 easy :) 14:05:59 They're not expensive at all. 14:06:10 Yay. 14:06:10 its a nice uc 14:06:25 Cool. 14:06:44 Hrm 14:06:51 Do you know any instruction reference? 14:07:56 lol you can get them online 14:08:12 google for 8051 opcodes 14:08:42 Okie..I'm checking atmel's ones 14:09:14 the siemens references are good 14:10:15 OK, thanks 14:29:17 --- quit: Herkamire ("home again home again") 14:31:12 --- quit: tathi ("leaving") 15:23:50 --- join: bugslayer (guest@62.77.213.177) joined #forth 15:23:56 i440r what is your ip? 15:24:05 somebody dns i440r for me? 15:25:53 erm 15:26:02 158.253.233.15 15:27:57 hrm 15:47:36 --- join: tathi (~josh@ip68-9-58-207.ri.ri.cox.net) joined #forth 16:21:36 --- join: tcn (tcn@tc1-login11.megatrondata.com) joined #forth 16:22:03 :) 16:23:09 --- quit: bugslayer ("bye") 16:23:14 hey 16:27:40 so what do you think of those elections eh ? :) 16:28:19 cool 16:28:51 well.. i heard you got a democrat governor 16:28:54 :) 16:29:02 but we got a republican! 16:29:25 we almost voted down the income tax 16:29:25 yea 16:29:42 got rid of bilingual education 16:29:42 whats important is that we now have the house AND the senate :))))) 16:29:51 yeah 16:30:45 Too bad there's no fundamental difference in republican or democratic views. The only real difference is, well, frivolous. Icing. 16:31:02 Rhetoric, is the only real difference. 16:31:38 --- quit: XeF4 ("pois") 16:31:52 BBL 16:33:06 bullshit 16:33:15 abasolute BULLShit 16:38:55 yeah, come visit massachusetts to see what Democrat rule is like 16:39:53 there's a difference.. it's like the US vs. the USSR 16:40:38 --- quit: tathi ("leaving") 16:47:04 I am SO glad our democrat got elected 16:49:35 check out the results of the vote on www.vote.com 16:50:03 22,838 to 841 :))) 16:50:03 i've seen enough results 16:50:32 22,841? 16:50:59 its vote.com - they as a question and keep track of the answers. they will mail the right ppl with their results too 16:51:15 the vote is "is it good for the country that the gop now has both the house and the senate" 17:03:40 Fuck... 2am, school tomorrow and I can't sleep. 17:04:03 And if I finally DO manage to sleep, I won't wake up. 17:04:15 Best of all - first class tomorrow is a biology test. 17:04:44 Which means, if I sleep too long, I'll miss it. If I don't go to bed, I'll be a zombie by then. 17:04:49 * Robert sighs. 17:07:53 it's only biology 17:09:31 Yes, I know. 17:25:44 --- join: proteus_ (~username@65.191.88.177) joined #forth 17:35:28 --- quit: tcn () 17:39:37 --- quit: proteusguy (Read error: 110 (Connection timed out)) 18:07:30 Heh. So from what I hear, this election wasn't as big of a scam as the last presidential election... 18:07:54 That's good, I guess. At least Americans can pretend they're living in a democracy... 18:08:02 Good for them. 18:10:08 At least the American system keeps those pinko green party wackos out of power. 18:11:21 Actually, I could care less. The choice between republican and democratic parties is a joke. It's a choice between baboons and orangutans. The corporations write the US's laws anyways... 18:22:16 --- quit: proteus_ (Read error: 104 (Connection reset by peer)) 20:33:24 --- join: bugslayer (guest@62.77.213.177) joined #forth 20:33:39 i could say that there is one party, the demopublican party, but i wont ;) 20:34:08 yeah fractal, you seem to be in a little bit of a trolling mood 20:34:49 Meh, not particularly, I'm just honest. 20:34:58 hah 20:35:39 so how goes it fractal? 20:35:40 I'm just tired of americans believing they're living in "the land of the free". 20:35:43 doing much forth coding these days? 20:35:44 Heh. Not bad. You? 20:35:52 so so 20:35:52 Ya, a little here and there. 20:35:57 doing some forth coding here and there 20:36:03 Heh. Cool. 20:36:07 but sometimes it really takes some effort to get off my ass and code 20:36:18 Ya, no doubt. 20:37:14 i've got a "code a mud in forth" project 20:37:23 but the main obstacle is the database in the first place 20:37:33 Ah yes, I think I've talked to you about that before. 20:37:50 i don't really know how i should go about making the database, and what to put in the database and crap 20:37:58 do i put code in the database? 20:38:00 Hm... Yeah, that could be tough, especially since forth is poor at dynamic memory allocation. 20:38:16 well the dynamic memory allocation isn't that hard 20:38:35 my problem with the database isn't purely an implementation problem 20:38:44 but of how the hell it should be utilized 20:38:48 Hm, ok, then why don't you have something like: 20:39:06 name:password:item1,item2,item3:gold 20:39:09 Or something. 20:39:19 1 line per user. 20:39:25 i'm planning this super complex object system, which is paralysing me from making a little crappy thing :P 20:39:43 Heh. 20:39:47 coding to throw away isn't in my bloodstream yet 20:39:57 er, blood 20:40:14 Well, there's always using external DBs. 20:40:32 nah :P 20:40:42 You could write up some quick SQL query code... 20:40:53 so um, i suppose i save the DB as a file 20:41:02 and then load only the stuff i need? 20:41:12 or maybe i could have the dtabase as a forth file 20:41:23 and all the words in the file would be the dtata 20:41:28 As a forth code file? That's probably a bad idea. 20:41:41 : player1 password object1 object2 ; 20:41:55 hheh 20:41:59 What if a player sets their password to ";"? 20:42:05 Could crash the server. 20:42:09 well the password would be a string silly :P 20:42:33 : player1 passwordstring ; 20:42:54 Well, what if they're password was " " ; "? 20:43:25 Or, what if you wanted an item called swap? 20:43:35 There's just too many things that could go wrong. 20:43:38 no, the string is terminated by 0 20:43:39 no 20:44:01 you are blowing it out of "proportion" 20:44:42 the object1 and ojbect2 don'thave to reflect the name of the object 20:44:45 it could just be a number 20:44:52 and there would be a list of object 20:44:52 s 20:45:17 Ok, possibly. 20:45:47 But consider this: The forth dictionary is stored in a linear, append-only heap. 20:45:49 well it probably isn't a good idea to have everything as words, probably slow down the compiler or something.. 20:45:52 yeah 20:46:07 unless i seriously hacked the dictionary and dictionary words ;) 20:46:23 Yeah, well speed isn't really the problem, but what if somebody gains an item? 20:46:38 You'll have to reload the entire dictionary. 20:46:49 yeah, inconvenient :P 20:46:57 Yeah... 20:47:06 well.. 20:47:21 instead of words there could be a data strcuture of fixed size 20:47:36 with like 30 spaces for items 20:47:39 or whatever 20:47:48 Ok, fair enough, though it doesn't scale well... 20:47:51 a 100 spaces 20:48:04 well there could be a limit to the number of items the player is allowed 20:48:20 player tries to pick up 101th item and it says "fool! you cannot carry more than 100 items!" 20:48:35 i wonder if there's a limit like that on other muds 20:48:57 True, so you plan on having all users logged on at the moment in memory? 20:49:11 Or all users in the DB? 20:51:23 eh? don't understand your question 20:52:10 Well, nevermind. 20:52:42 oh 20:52:49 same thing? :P 20:53:30 Don't worry about it. :) 20:53:31 if they're logged in, then they'll be in memory, but they'll be stored in the DB, and the parts of the db not being immediately utilized will be offline 20:53:43 er, will be on hd 20:53:45 Ok... 20:54:10 That's what I thought. 20:54:44 Well, good luck. 21:01:51 fractal, what's your email? 21:02:22 msg it to me if you want to keep it hiudden from clog 21:04:57 What? 21:05:05 Oh, I see. 21:06:09 sent 21:06:28 should explain it in a little more detail for ya 21:09:51 Cool. 21:10:20 i still welcome any input 21:13:38 fractal: the generate room description seems a little tricky.. how do i knoww when an object is in the same room ? 21:20:20 ls 21:20:23 doh 21:23:41 Well, you're going to have to have both "descriptions" of the objects, and "instances" of objects... 21:23:51 And the "instances 21:24:11 " of objects will most likely contain a number referring to which "description" it's associated with. 21:24:40 yeah 21:24:54 hm 21:26:02 why should the description be somewhere else? 21:26:15 and not part of the object dtatastructure? 21:28:04 Well, you don't want to duplicate the description for every instance of the object. 21:28:32 Like, there's no point in storing "A long sword" 50 times. 21:29:02 Also, if you want to change the damage a long sword does, you'll only have to change it in one spot. 21:29:46 there'll be one "A long sword" 21:29:57 and a pointer to that with every person who has that item 21:30:27 that's the way i was thinking of it as 21:30:34 Yes, that's what I'm saying. 21:31:08 Also, most MUDs also have individual properties to objects, like this particular long sword is 20% damage, and is blessed. 21:31:15 so the player has a pointer to the object dtat strcuture and the datastructure contains the description as well as all attributes.. 21:31:18 But that's certainly not essential. 21:31:32 well that can be passed to the datastructure or something, dunno 21:31:46 but not part of it.. 21:31:53 Um. You don't pass things to the data structure. 21:32:10 heh, i know, but i could have affectors or something 21:32:37 "Affectors"? 21:33:06 well the affect of blessed can be realized without putting it in the datastrcuture 21:33:14 the datastructure is an object 21:33:28 vaguely anyways 21:37:00 ummm 21:37:46 there should be a way to still have blessed and stuff like that 21:38:04 maybe 2 datastructures 21:38:11 eww ;) 21:41:37 And you want to do this in forth? 21:45:51 yes, are you anti-forth or something? do you think it's hard to do stuff in forth? you should check isforth, it's inspiring and the whole thing was coded reallly fast. it has sockets, and more, and will soon be a serious forth development platform.. 21:46:19 it inspires me because it's simple and close to the metal yet achieves a lot already 21:46:24 and the socket code is nice 21:46:29 which he hasn't released yet 21:47:10 No, I'm not anti-forth at all. Actually, I have my own forth comiler: http://www.hcsw.org/frugal/ 21:47:33 However, I do recoginize the strengths and weaknesses of a language. 21:48:57 And yes, isforth is OK, but, of course, not portable. 21:49:43 actually, i'm hard pressed to think of any weaknesses except for poor support, lack of excellent forth books (starting forth is out of print), and lack of good examples of forth code and good role models for forth coding methodology 21:50:19 i have seen lists of the cons that forth has, but most of those are perceived or not directly inherent with the language but dependant on the programmer 21:50:40 Well, lack of typing is a big limitation. 21:50:53 Lack of standardization. 21:51:00 isforth is portable, not the kernel, but that can be coded for the next platform easily 21:51:07 ew, you're an ans-forth lover 21:51:14 "standardization" "portability" 21:51:15 Easily? Heh. Uh huh. 21:51:28 uh huh 21:51:38 i440r coded the isforth kernel in 1-2 months 21:51:56 and he took longer cause of the learning curve 21:52:07 and some stuff he had to hack around 21:52:11 I gave him a shell on my oBSD machine, asked him to port isforth, and he couldn't do it. This is another x86 unix too. 21:52:33 he wouldn't do it 21:52:36 not couldn't 21:52:42 No, he couldn't. 21:52:50 Gave up after a few days. 21:53:03 Supposedly, it shouldn't even need to be rewritten. 21:53:49 Yes, i440r has some strong opinions on portability, many of which make little sense. 21:53:55 the syscalls stuff need to be changed and the freebsd.1 needs to be done 21:54:06 who cares about i440r's opinion on portability? 21:54:09 this is forth 21:54:18 chuck moore's opinions are where it's at :P 21:55:30 Yes, well forth is an interesting, flexible, and powerful language, but it simply doesn't take into account decades of compiler research. 21:56:06 lol 21:56:41 For instance, lack of typing. 21:58:38 It's an outdated language. 21:58:51 But can still be useful in many areas. 21:58:53 a skilled assembly coder can easily produce better code than any compiler. a skilled forth coder like chuck moore is essentially using forth like a macro assembler, with well chosen macros with which he can build a program. he unlocks the potential of the program through his approach to problem solving and finds the best possible problem with the least "hooks" 21:59:34 it might not take into account decades of compiler research, but that's because that shit is completely irrelevant 22:00:13 Well, yes, in theory. Unfortunatley, there are different levels of the "best" solution. This is something forth programmers generally have a difficult time of seeing. 22:00:28 it is my view that since forth is a DIRECT and SPECIFIC outgrowth of chuck's philosophy, it is stupid for forth to be used by those who don't closely follow or agree with chuck's philosophy 22:01:26 fractal: that is an unsubstantiated statement, how do you know that chuck moore doesn't see the levels.. hmm? :) 22:01:57 Well, chuck is definitley not the only contributer to the forth language. 22:01:59 actually, the one disadvantage of forth is probably: there's only one forth coder ;) 22:02:03 Nor the only forth programmer. 22:02:26 Oh, so what you're saying is that only chuck's code is forth code? 22:02:56 well i really don't care about most of the forth coders out there, most of them are just mucking it up and/or coding in ANS Forth 22:03:05 and ANS Forth != forth :) 22:03:21 do you read clf? 22:03:23 i don't 22:03:37 Perhaps not, but an ANS forth implementation is just as much forth as, say, isforth. 22:03:39 i don't understand what you mean when you say "lack of typing" ?? 22:03:55 bugslayer : It doesn't have a typing system. 22:04:32 what's a typing system? why does it need one? why does it need string handling code? or OOP code? or floating point code? 22:04:35 Just so we're clear, C has a (very primitive) weak typing system. 22:04:42 Like int, char, etc. 22:04:47 oh 22:04:48 typing 22:05:04 i was tyhinkging like, the act of typing letters on the keyboard 22:05:21 Strong typing is invaluable in avoiding a wide number of common programming errors. 22:05:25 Heh. No. 22:06:06 For instance, in a modern language, it should be impossible to dereference a NULL pointer, or overflow a buffe.r 22:06:13 fractal. strong typing and OOP etc dont simplify a problem 22:06:28 it just re-factors the problem :) 22:06:28 Actually, it's really a shame that C and it's derivatives are still in common use. 22:06:50 you still have all the same problems, you just dont SEE them the same :) 22:06:54 isforth follows the forth spirit much more closely than ans forth does. ans forth ihas a vocabulary that is far too big and to ocomplex in the pursuit for solving fake problems 22:07:19 and isforth is closer to the metal 22:07:24 bugslayer : isforth's core has more words defined than the ANS standard specifies. 22:08:06 And i440r, I agree with OOP. I don't think that it creates a signifigant advantage in managing complexity. 22:08:12 isforth is homebuilt to solve i440r's own problems 22:08:35 Strong typing is different though. Unfortunatley, most people only have experience with "C-style typing". 22:09:32 bugslayer isforths vocabulary is fat for forth 22:09:57 but when i can metacompile ill be able to VASTLY simplify the targets vocabs 22:10:01 bugslayer : Ok, granted, isforth is taylored to i440rs own needs, but don't make claims that isforth is "leaner" than ANS forth. 22:10:32 fractal isforth IS leaner than ans 22:10:35 or... will be 22:10:35 I440r : Let me know how that goes. Sounds interesting. 22:10:36 ans forths have vocabs of 300 or more.. 22:10:54 thers alot in isforths kernel that can eventually be factored out to extensions 22:11:02 and will therefore be OPTIONAL!!! 22:11:29 fractal. i can sort of explain some of my plans :) 22:11:57 i have a few hundred words in isforth, i think 70 or 80 is a LEAN forth :) 22:11:58 There's nothing preventing an ANS forth system from not including many words in the core set. The only specification is that when interpreting an "ANS compatible" forth program, all words in the core set must be loaded. 22:12:03 so isforth is a little fat :) 22:13:40 fractal: the forth philosophy is to get rid of as many layers as possible.. just have the leanest, thinnest possible layer, and when a problem is solved, it is the "right solution" by virtue of solving the problem in the smallest way and by introducing the fewest layers 22:14:17 isforth is intended to be more paletable to teh linux c community 22:14:19 in essentially being the least complex solution 22:14:24 Yes, I understand that subset of the forth philosophy. 22:14:31 as a means of suckering them into the forth community :) 22:14:51 subset? naw, there's the forth philosophy and there's derivatives 22:15:07 and bastard childs ;) 22:15:12 er.. children 22:15:15 I believe the more signifigant part of the forth philosophy is factoring definitions. 22:15:28 Managing complexity by pieces. 22:15:32 "Divide and conquer" 22:15:52 yep, simplifying 22:15:53 Which is, essentially, the cornerstone of structured programming. 22:16:26 However, this brings up another one of forth's DISadvantages. 22:16:42 It doesn't handle namespaces very well. 22:16:52 namespaces? 22:17:23 Yes. I hate to compare an elegant language like C to forth, but here goes. :) 22:17:30 Er, other way around. 22:17:36 Elegant language like forth to C 22:17:43 i think that the question of whether or not that forth has advantages depends on your perception, it depends on what your philosophy is, and your approach/perspective to problems 22:17:44 lol 22:18:01 er 22:18:04 disadvantages 22:18:06 But, C provides local variable namespaces in functions, where forth doesn't. 22:18:34 Since forth doesn't use local variables (usually), this is largely irrelevant. 22:18:34 local variables are not needed by forth 22:18:44 the forth philosophy is to use UNNAMED parameters 22:18:46 nameless 22:18:47 However, forth ought to have better local word namespaces. 22:18:48 anonymous 22:18:57 it shouldnt have any 22:19:11 whethere or not dforth has disavantages is affected by how you approach the solving of a problem, and your philosophy. if you approach the problem properly, you don't need all these features like typing, oops, etc 22:19:20 you should read Thinking Forth 22:19:36 there's words and there's the stack, which lets you implicitly pass data 22:19:47 Well, you really ought to be able to define words inside of words. 22:19:57 there's absolutely no need for local variables 22:20:01 eh?? 22:20:17 Yes, there's no need for local variables, but there IS a need for local namespaces. 22:20:26 why should you define words inside of words? 22:20:42 remember, illegal words are those bigger than 2 lines 22:21:24 For instance, often you have a particular part of a problem that you always have to solve, but you always solve differently. 22:21:40 You should be able to name this piece of your problem locally to your problem only. 22:21:42 lots of small words.. it's a different paradigm, some people try to apply the "functions" paradigm to forth words 22:21:48 fractal why is there a need for local namespaces 22:21:55 forth are not functions 22:21:55 im still not sure what a local namespace is 22:21:56 er 22:22:02 WORDS are not FUNCTIONS 22:22:23 words are all operators 22:22:38 like in c the + / * etc are all operators not functions 22:22:45 everything in forth is an operator 22:22:46 Well, ok. A namespace is a particular set of names that can only be referenced from it's associated code. 22:22:59 hidden words 22:23:11 Yes, sort of. 22:23:15 but thats a bad reason for using headerless/hidden words 22:23:20 thats information hiding. 22:23:28 forths way is to do information SHARING 22:23:31 That's information *abstraction*. 22:23:32 fractal: bad programmers can stay away from forth 22:23:43 Even in forth, you use a degree of abstraction. 22:23:50 in fact, 90% of coders out there probably suck, and they shouldn't be coding :P 22:24:15 Factoring of code is a method of abstraction. 22:24:29 bugslayer : Only because they were taught on C and C-like languages. :) 22:25:19 you are concerned about protecting the programmer. that's what this typing and namespaces crap is all about 22:25:27 well guess what? fuck the programmer 22:26:43 my perspective is that the user's time is much more important, and i have experienced, too many times, a bloated os and a bloated program running far slower than it should and wasting my time 22:26:58 multiply that wasted time by millions of users 22:27:14 and you have a mass theft of the economy 22:27:47 fortunately for us, we have a language called forth that enables the programmer to be much more considerate of the user, AND enables the programmer to code pretty fast 22:27:54 Yes, but that wasted time is a small fraction of the wasted time, lost data, and lost productivity of poor quality software. 22:27:57 bugslayre thats also my philosophy 22:28:09 most coders are so full of themselves they FORGET the end-user 22:28:44 what the fuck point is there in writing code that is useless to the end user. its the person who uses the software thats important, not the person who coded it 22:28:51 fractal: woah! the quality of the software is PURELY dependant on the programmer. it is NOT dependant on the language and especially isn't dependant on TYPING and NAMESPACES 22:28:59 For instance, when your windows "illegal operations". These are errors that could easily be prevented. 22:29:21 typing and namespaces are to protect the weak programmers.. 22:29:58 bugslayer : Ok, answer me this: Why do forth programmers use ( arg1 arg2 c-arg3 -- addr1 ) etc? 22:30:04 forth programmers can and do put in error checking and easily make sure the whole system DOESN:T crash even if some code is buggy 22:30:10 That is an unenforced method of typing. 22:30:18 the forth programmers that use those are gay ;) 22:30:26 Is that right? 22:30:36 What do you think about that, i440r? 22:30:46 no, i'm joking a bit 22:30:58 it's a good question 22:30:58 forth shouldnt TEST anything it can get away with not testing 22:31:08 why does chuck moore not use stack arguments? 22:31:08 : foo blah blah blah if blah blah ; 22:31:15 : bar blah balh blah then blah blah ; 22:31:37 stack arguments are considered poor programming methodology 22:31:51 What?! 22:32:03 yes 22:32:03 Are you listening to yourself? 22:32:07 :) 22:32:36 stack arguments are considered poor programming methodology, seriously. 22:32:42 When you do "1 2 +", you are passing 2 stack arguments to the word "+". 22:32:44 by a handful of people 22:32:51 er 22:32:51 er 22:32:51 er 22:32:51 er 22:32:53 i'm tired 22:33:01 s/arguments/comments 22:33:15 been fucking up a lot if you haven't noticed heh 22:33:21 making those errors 22:33:31 So, let me get this straight... 22:33:38 its them drugs ure doing :) 22:33:59 You're saying that documenting the stack effects of a word is bad programming practise? 22:34:29 Brodie introduced this notation in chapter 3 (I think) by the way. 22:35:19 didn't he say something about it being considered poor programming style tho? especially in Thinking Forth??? i can't remember, so i might be wrong 22:35:29 how would it be 22:35:53 No, I don't think he did. I think he advocates using them extensively. 22:36:42 have you read Thinking Forth? 22:36:52 Yes, I read it a long time ago. 22:37:05 I read Starting Forth again recently though. 22:37:21 my local library lost its copy :( 22:37:21 Excellent book for learning forth. 22:37:50 Except, he doesn't introduce immediacy soon enough, IMO. 22:38:00 heh 22:38:48 well, i think that immediacy might be overabused by lots of forth coders 22:38:50 not sue tho 22:38:52 sure 22:39:05 emphasis on "might be" 22:39:15 immediacy isnt one of the things peopl;e abuse realy 22:39:23 it only has application in creating words 22:39:29 Immediacy is one of the cornerstone of forth, I think. 22:39:50 that and does> :) 22:39:54 does> is THE key stone 22:40:58 Yes, does> is a key stone if it is the chosen method of creating creating words. 22:41:15 immediacy is fine for creating compiler words, but for creating structures, uh uh ;) 22:41:26 classes, structures, oop 22:41:33 nevermind, i'm trolling a little 22:43:11 actually, does> is not efficient 22:43:11 No, not necessarily. Immediacy has other uses. 22:43:16 i tend to use ;uses 22:43:35 : constant create , does> @ ; is less efficient than 22:43:43 For instance, calculating literals at compile-time, rather than runtime. 22:43:49 : constant create , (;uses) doconstant ; 22:44:35 : myword [ 3 64 * ] literal ; 22:44:37 [ ' foo >body ] @ 22:44:45 erm 22:44:48 Is more efficient than : myword 3 64 * ; 22:44:57 [ ' foo >body literal ] @ 22:44:57 lol 22:45:00 And more explicit than : myword 196 ; 22:45:15 yes, [ ] is very handy for that sort of thing 22:45:27 i would do that as 3 64 * constant myword 22:45:27 heh 22:45:27 or better yet 22:45:45 3 64 * const myword 22:45:45 a const compiles as a literal in isforth 22:46:05 but what if myword has other words in it? 22:46:14 So? 22:46:16 : myword [ ascii * ] blah blah blah ; 22:46:21 : myword [ 3 64 * ] literal blah blah ; 22:46:31 fractal: i was talking to i440r 22:46:36 Oh. 22:47:02 No, there's still no problem. You're essentially trading memory for CPU time. 22:47:29 It takes 2 cells for a compiled literal, but only 1 to reference a constant. 22:47:49 Which is actually not a bad idea. I may just use that in frugal. 22:47:57 For const. 22:48:57 my var and const definitions are yours any time you want them :)P 22:49:24 i440r: why did you keep variable and constant? throw them out 22:49:40 backwards compatibility is lame 22:49:41 Well, the internals are probably too different to just copy and paste the definitions, but I like your idea for const. 22:49:43 : const create , immediate does> @ ?comp# ; 22:49:57 Yes, that won't work in mine. 22:50:06 erm let me get the definition for ?comp# 22:50:17 No, I don't use does> at all. 22:50:52 : ?comp# state @ not ?exit compile (lit) , ; 22:51:51 how would you recode const for frugal ? 22:52:02 So, I440r, what's your opinion on documenting stack effects. 22:52:08 Well, let me think for a minute. 22:52:16 i read Thinking Forth in early 2002 22:52:26 very important 22:52:37 but i dont document the return stack effects 22:52:45 that just clutters the stack comments 22:53:18 if u look at isforths source thers only a few uncommented words 22:53:43 i think comments in general are very important 22:53:55 : const create immediate compile-#, compile-, compile-exit ; 22:54:00 Or something. 22:54:23 Yes, agreed. 22:54:32 It's essential to have some sort of typing system. 22:55:19 heh 22:55:47 i440r was talking about regular comments i believe 22:55:49 not about stack comments 22:56:07 : type ( a1 n1 --- ) for count emit nxt ; 22:56:12 Well, if you look at the isforth code, you'll see almost every word is so commented. 22:56:15 erm needs a drop 22:56:37 stack comments are just as important as regular comments i believe 22:56:39 Hm... I use a do in type, what's for/nxt? 22:56:40 aren't all his words stack commented? 22:56:44 : type ( a1 n1 --- ) for count emit nxt drop ; 22:57:09 Yes, the stack comments provide an abstracted programmer interface to the word. 22:57:13 for next, the looping mechanism endorsed by chuck 22:57:27 for is a >r 22:57:29 And how does it differ from do/loop ? 22:57:48 nxt decrements top of return stack till 0 then exits the loop 22:57:52 you pass only 1 number 22:58:08 i wont call any word except NEXT next 22:58:09 easier to implement in hardware apparently 22:58:16 next has special meaning in forth 22:58:19 Oh, I see. So it's fundamentally no different than do/loop. 22:58:23 i440r: that's cause you are non-standard 22:58:25 nxt is my name for what others call next 22:58:32 where the standard is chuck! :P 22:58:36 i conform to the isforth standard:P 22:58:57 and chuck doesnt :) 22:59:24 chuck and jeff fox and other forth coders are anti- stack comments 22:59:46 they must've figured out a way to not need stack comments eh? 22:59:58 the forth is strong in 'em! 23:00:11 where forth = force 23:00:40 Show me where they say why they're anti stack-comments. 23:03:08 weird, google isn't showing any docs ith "stack comments" on ultratech 23:03:48 if i didn't read the stuff on stack comments, for sure i read them in a leo brodie book 23:04:00 er, if i didn't read them on ultratech 23:04:07 I see. 23:06:16 no, it just means that "stack comments" wasn't said, it was said differently 23:07:14 if i remember correctly, the "why" was because they see it as a crutch, that properly factored words don't need it because a glannce tells you want it does 23:07:42 i herd a reay cool joke the other day... dunno how OLD it is tho 23:07:45 aha 23:07:52 they called it "stack diagram" 23:07:55 there are TEN types of people in the word. 23:08:02 So people who draw stack diagrams or pictures of things on the stack should immediately realize that they are doing something wrong. Even the little parameter pictures that are so popular. You know if you are defining a word and then you put in a comment showing what the stack effects are 23:08:02 and it indicates F and x and y 23:08:06 those who understand binary and those who dont 23:08:54 F ( x - y ) 23:08:54 I used to appreciate this back in the days when I let my stacks get too complicated, but no more. We don't need this kind of information. It should be obvious from the source code or be documented somewhere else. 23:08:57 I440r : lol 23:09:03 i440r: heh 23:09:14 :) 23:09:59 bugslayer : And there is no convincing rational to accompany that? 23:10:14 fractal: for the most part, chuck moore probably passes only 1 parameter to a word, and at most 2 parameters 23:10:31 as a complete newbie, it seems to me that i agree with bugslayer 23:10:52 despite my appreciation for I440r's stack comments 23:11:27 with proper factorization, the words are small and understandable and you don't have have very many items on the stack at all.. 23:11:29 Well, the fact is that it doesn't matter how many arguments you pass on the stack. It's a handy mechanism for remembering what you mean by those arguments. 23:11:35 not agree really, no real basis to agree on yet, but i heard somewhere that 2 or 3 word words were best 23:11:45 bugslayer is falling into the "self commenting code" trap 23:11:49 and it makes sense, in a weird sort of way ........ 23:11:49 NO such thing 23:11:50 just look at the code. if the word is a 1 liner 23:12:03 I440r : I think that is one of the few things we agree upon. :) 23:12:04 i440r: maybe not at the low level 23:12:07 true that 23:12:18 fractal i agree with alot of what you say 23:12:28 bugslayer at ANY level 23:12:33 I440r : Yes, likewise. 23:12:33 its language independant 23:12:37 i440r: i think that if forth is properly abstracted, and the high level words were used, it would read like english! 23:12:38 thers NO such thing 23:12:53 fractal you just havent figured out that "im always right" yet :) 23:12:54 heh 23:13:06 often wrong you mean 23:13:16 bugslayer : The stack comments ARE a method of abstraction though, and often describe a word's function more quickly than the code itself. 23:13:18 bugslayre yes. but that doesnt negate the need for comments 23:13:19 I440r : Heh. 23:13:39 sure, but it negates stack comments 23:13:46 no 23:14:16 comments play the role of stack comments except you jdon't have any lame parameter/stack picture/diagram 23:14:22 http://www.ultratechnology.com/moore4th.htm 23:14:24 part of why my code is as good as it is (even if i do say so myself) is because i take the time to think about the comments and stack comments 23:14:25 bugslayer : You say you've read Starting Forth? Didn't you find the stack comments helpful there? 23:15:09 Looking at my copy, I see he introduced them in chapter 1. 23:15:10 fractal: nope, found them confusing at first, didn't pay attention to them when i read the book 23:15:21 i was a newbie when i first read the book 23:15:53 bugslayer exactly 23:16:05 they weren't really that helpful to my learning the words anyways, i just learned "oh, i need to pass this number and crap" to the word 23:16:08 1: always write code so that a newbie can read it 23:16:13 2: always comment it for the newbie 23:16:24 uhhh 23:16:30 but when you comment dont make the comments intrusive 23:16:37 i.e. dont make them get in the way of teh expert 23:16:41 code code code 23:16:45 comment comment comment 23:16:46 code code code 23:16:47 comment comment comment 23:16:48 code code code 23:16:48 comment comment comment 23:16:52 is FUCKED UP 23:17:06 it fragments the code and makes it difficult to parse 23:17:10 code code code comment 23:17:11 the code WILL NEVER BE READABLE BY A NEWBIE UNTIL the code gets OUT of the LOW LEVEL!!!! GRRR!!!! 23:17:12 code code code comment 23:17:12 code code code comment 23:17:12 code code code comment 23:17:14 is much better 23:17:16 bugslayer : Exactly. The stack comments illustrate what you should have on the stack when you call the word (should it be an address or 2 integers or what?) and what data you should expect in return. 23:17:35 bugslayre dood LOW level is EASIER to read 23:17:37 not harder 23:18:15 fractal: i said the stack commetns were confusing, i did not figure out stack comments until some time after i had returned the book to the librar 23:18:33 i440r: not when the code reads like english 23:19:04 bugslayer : I defy you to give me one piece of *useful* code in any language that reads like english. 23:19:07 bullshit 23:19:27 what he said heh 23:19:27 my ansi code for my mud reads like this: blue on green 23:19:44 i've seen speuler's code, some fragments are very english like 23:20:09 his tui code goes like: blah on blah is nice 23:20:15 blah on blah is not nice 23:20:18 etc 23:20:40 it takes care to design english-like highlevel forth code 23:20:41 Some fragments perhaps. A lot of stuff looks like english. The fact is, english is inconsitent, inefficient and NOT something you would want a computer language to look like. 23:20:54 (Even if it was possible) 23:20:54 heh 23:22:02 German is marginally better, but natural languages are meant for human communication, not for instructing machines. 23:22:14 read http://www.ultratechnology.com/1xforth.htm read his reasoning for why stack comments are no good 23:22:22 OK. 23:22:29 scroll down to "stack parameters" 23:23:49 gotta go 23:23:53 --- quit: bugslayer ("bbiab") 23:23:55 I can't agree with him there. 23:24:08 i gotta go too 23:24:10 zzz 23:24:12 OK. Bye., 23:24:14 nite nite 23:24:18 Night 23:24:19 --- quit: I440r ("Reality Strikes Again!") 23:24:55 Hm... Everyone ducked out there... 23:26:34 I personally think it is foolhardy to throw out the most consistent method of internal documentation available to forth on the promise of "self documenting code". 23:32:51 --- join: proteusguy (~username@65.191.88.177) joined #forth 23:48:25 --- join: thin (thin@h68-146-166-145.cg.shawcable.net) joined #forth 23:48:44 back 23:48:51 <-- bugslayer 23:51:20 fractal: i recommend reading www.ultratechnology.com/essence.htm and the sequel structs.htm 23:51:26 it's interesting 23:51:28 um 23:51:57 i don't have a problem with comments at all 23:52:39 stack comments on the other hand, while they are very nice, i think that perhaps they can be done without, especially if all the words are really short and only 1 or 2 parameters are passed 23:52:54 _especially_ if only 1 parameter is passed :) 23:58:05 i think it's important to think of words as totally different than functions.. i've been slightly brainwashed by functions so i kind of know what its like, but words are not functions. they are stringable operators, and each operator is very very simple, and only takes 1 or 2 parameters.. and operators are built of other simple operators.. everything is kept really simple and a powerful program is achieved from simple components 23:59:59 --- log: ended forth/02.11.06