00:00:00 --- log: started forth/06.03.03 00:01:30 i saw the message before, when i forgot an else e.g. but i dont see why it appears here 00:04:06 * chris2 sees PoppaVic running in the room and banging his head to the wall? 00:04:21 hmm? 00:04:43 actually, yeah - but my wallbanging is parsing ;-) 00:05:19 the only mention of that message in the manual is where someone tries to use the stack across a colon definition 00:05:24 i dont see that here 00:06:19 prolly need to trace the idea 00:06:36 and i dont know how to use interpret/compile 00:06:47 as I said, you need to learn it 00:07:06 it should be possible without gforth extensions, though? 00:07:11 If you want to write silliness, you need to know the rules. 00:07:49 well, I'm sure there are variant words that will use an embedded string and lookup from THAT, rather than parse - and it STILL sounds stupid. 00:08:22 i would use evaluate, but that would be very lame 00:10:03 gah :) : [test] name postpone SLiteral postpone . ; immediate works 00:30:00 hmm, That's still useless. 00:31:34 --- quit: PoppaVic ("Pulls the pin...") 00:32:57 --- join: PoppaVic (n=pete@0-2pool198-53.nas30.chicago4.il.us.da.qwest.net) joined #forth 00:33:22 how so? 00:36:45 yay, it works now 00:36:51 thx a lot :) 00:37:06 what's the final code and use? 00:37:17 --- nick: Raystm2 -> nanstm 00:37:46 : a $ b ; : b ." B" ; a 00:37:51 : $ name postpone SLiteral postpone ($) ; immediate 00:38:02 * PoppaVic sighs 00:38:07 : ($) name-too-short? find-name dup 0= if abort" undefined task" else name?int execute then ; 00:38:24 OK. Have fun 00:38:47 why dont you like it? 00:38:53 chris2, I just came in. What are you trying to do? 00:39:06 It all seemed listed backwards, and it still means dick 00:39:09 Quartus: calling words that may not have been defined yet 00:39:22 PoppaVic: yeah, order is reversed. sorry. 00:39:31 chris2: this is why we have deferred-words and such 00:39:51 yes yes. but you need to define them as deferred, right? 00:40:10 deferred or some variation ON that them, of course 00:40:17 them/theme 00:40:30 : foo c" someword" find if execute else drop then ; 00:41:01 Q: nice and clean 00:41:17 i dont like the c"" ;) 00:41:37 You don't need to. There is likely a variant of FIND in whatever system you use that uses counted strings. 00:41:49 S", usually 00:41:49 I believe gforth calls it sfind, for instance. 00:42:00 i want it to call like $ 00:42:44 Gforth? 00:42:48 yeah 00:42:56 --- join: sproingie (n=chuck@64-121-2-59.c3-0.sfrn-ubr8.sfrn.ca.cable.rcn.com) joined #forth 00:43:02 yes. but ans prefered if possible 00:43:42 You'd need a counted string for ANS, to do it cleanly. 00:43:59 If it's CORE you're depending on, at any rate. 00:44:21 hmm 00:44:39 or, words to compile words, etc 00:45:01 or compile strings, actually 00:45:07 For gforth: 00:45:18 : call sfind if execute else drop then ; 00:45:28 : $ parse-word postpone sliteral postpone call ; immediate 00:45:36 yay 00:45:37 good call, Q 00:45:52 That'll work on an ANS system if you build sfind and parse-word underneath it. 00:46:45 Note that $ must be used inside a definition. 00:46:53 yes, it always will be 00:47:23 What do you want this for? 00:47:43 Damn, Q.. I spent almost an hour asking, and never realized he WANTED a call-out 00:47:59 ..it was LOOKING like some freaky "macro" 00:48:28 Quartus: trying to build a "make" like system 00:48:42 Ah. 00:49:04 "14:28 i'm defining a word to call a word that may not yet have been defined" 00:49:16 Yes, that's what you wanted, but I wanted to know why. 00:49:55 so i'd have tasks, like task: foo $ bar $ quux dostuff ;task 00:50:06 and the fun is that every task only will be called once 00:50:28 so there could be circular dependencies 00:50:39 and i obviously dont want to predeclare the task names 00:50:48 I recommend you keep it simple. If you're going to rely on Forth's dictionary to hold your names, you should rely on Forth's other facilities as well. 00:50:54 right 00:52:27 i cant imagine an easier way? 00:53:14 I can, and - I just figured out how to get my old code from that machine to here ;-) 00:53:27 * PoppaVic chuckles with evil, perverse glee 00:53:46 It might work for you. I just had a look at your earlier attempt with all the error-checking and "undefined task" stuff; I suggest you rely on Forth's own mechanisms for error reporting, and not try to disguise the fact that you're using the dictionary for lookup. 00:54:02 Q is right 00:54:08 Plus it was sunk pretty deeply into gforth-specific stuff. 00:54:20 There is no point having a nice, extensible system - and then breaking it 00:54:22 okay 00:54:41 I'm recommending the simplest approach, is all. 00:54:48 yeah, it was just when i check for the name anyway, i'd easier abort than throw an confusing message... 00:55:18 chris2: for fun, now - try your approach on "creating a macro" - with a name, but NOT running it until later, as called. 00:55:45 ..which is a lot like Make does 00:55:50 i dont understand? 00:56:10 Something along the lines of : foo s" someword" evaluate ; works too. 00:56:17 so, 00:56:20 define CFLAGS - right, like that 00:56:21 Quartus: yeah, but that's icky 00:56:25 Why? 00:56:40 doesn't matter if it's "icky" - write a WORD that can make it tidier 00:56:48 well ;) 00:57:03 You're searching the dictionary either way. 00:57:09 Q told you HOW, now you create the "what" 00:57:20 : $ parse-word postpone sliteral postpone evaluate ; immediate 00:57:22 fine :) 00:57:25 Right. 00:57:31 And ANS. 00:57:37 No messing about with counted strings. 00:57:51 ok ok ;) 00:58:08 You've got a possible problem in that you'll need to adjust the search-order if you want to avoid finding every word in Forth. 00:59:20 use a voc or three? maybe even a word that ONLY searches a private wordlist. 00:59:28 yeah 00:59:52 In which case you're either going to have to temporarily modify the search order, or use search-wordlist. 01:00:09 right 01:00:38 damn.. I was gonna' reload today - instad, I can transfer those missing files ;-) 01:01:12 i want to have full forth inside the task definitions 01:01:33 as long as FFI is no issue, go for it ;-) 01:02:36 chris2, I understand. But if $ is meant to find names only defined within the script, or whatever you're calling it, then you'll have to limit it. Otherwise $ words would succeed even before 'words' was defined in your context, if you follow me. 01:03:02 yeah 01:03:17 but if words was redefined after? 01:03:33 that'd be a "hertz donut" 01:03:34 Then the new one would be found. 01:03:46 yeah 01:03:56 so why do i need something special? 01:04:00 chris2: I think I see - wait a sec 01:04:18 ...Yer actually thinking that DEFINING is orderless, aren't you? 01:04:18 It's your system, chris2. I'm pointing out potential pitfalls. If they don't matter to you, then all the better. 01:04:46 the user will see when he defines a task that will overwrite a forth word 01:04:57 PoppaVic: yes 01:05:02 ahh 01:05:18 Why not then create a db? 01:05:39 entries exist, or are created, or CAN be overwritten? 01:05:57 can be overwritten 01:05:59 yes 01:06:08 that's pass1. Pass2 is the actual expansion/executes 01:06:18 yes 01:06:28 been there, done (and doing) that. 01:06:31 what is a "db"? 01:06:35 database 01:07:04 and what would that look like? 01:07:14 doesn't matter if it's a REAL db, a textfile, blockfile or macros. 01:07:36 what WOULD matter is the pass1 and pass2 tools 01:08:06 Well, I can't follow that. Good luck anyway chris2. 01:08:24 well, i need taskname + dependencies -> stuff to execute 01:10:27 Yes, that's what I've been beating in C all winter. 01:10:39 and, why you got that invite 01:44:07 --- quit: I440r (Read error: 104 (Connection reset by peer)) 01:46:51 --- join: JasonWoof (n=jason@pdpc/supporter/student/Herkamire) joined #forth 01:46:51 --- mode: ChanServ set +o JasonWoof 01:54:55 --- quit: sproingie ("Konversation terminated!") 02:24:42 --- join: tathi (n=josh@pdpc/supporter/bronze/tathi) joined #forth 03:46:09 --- join: virl (n=virl@62.178.85.149) joined #forth 03:50:33 --- quit: PoppaVic ("Pulls the pin...") 03:53:18 --- join: reuben (n=ben@leb-cr1-220-16.peak.org) joined #forth 03:58:23 --- join: OrngeTide (i=orange@rm-f.net) joined #forth 05:16:24 --- quit: chris2 ("Leaving") 07:23:55 --- quit: uiuiuiu (Remote closed the connection) 07:23:59 --- join: uiuiuiu (i=ian@dslb-084-056-232-055.pools.arcor-ip.net) joined #forth 07:45:57 --- join: snoopy_1711 (i=snoopy_1@dslb-084-058-147-101.pools.arcor-ip.net) joined #forth 07:54:21 --- quit: Snoopy42 (Read error: 145 (Connection timed out)) 07:54:38 --- nick: snoopy_1711 -> Snoopy42 09:16:02 --- quit: virl ("Verlassend") 09:44:33 --- quit: neceve ("Bye people, I'm leaving") 09:48:39 --- quit: Cheery ("Leaving") 10:05:49 --- nick: nanstm -> Raystm2 11:42:19 --- quit: Robert ("leaving") 11:49:47 --- join: sproingie (n=chuck@64-121-2-59.c3-0.sfrn-ubr8.sfrn.ca.cable.rcn.com) joined #forth 14:32:41 --- join: amca (n=plump@as-bri-1-104.ozonline.com.au) joined #forth 15:51:01 --- quit: amca ("d34d") 15:52:13 --- quit: sproingie ("Konversation terminated!") 17:29:33 --- join: rsyncx (n=bob@CPE000c41aac435-CM00111ae4f4cc.cpe.net.cable.rogers.com) joined #forth 17:30:34 --- quit: rsyncx (Client Quit) 17:40:54 --- join: rsyncx (n=bob@CPE000c41aac435-CM00111ae4f4cc.cpe.net.cable.rogers.com) joined #forth 17:54:58 --- quit: rsyncx ("Leaving") 17:57:07 --- join: rsyncx (n=bob@CPE000c41aac435-CM00111ae4f4cc.cpe.net.cable.rogers.com) joined #forth 18:01:52 --- quit: JasonWoof ("off to bed") 19:13:32 --- join: Cheery (i=Henri@a81-197-45-47.elisa-laajakaista.fi) joined #forth 21:00:27 --- join: virl (n=virl@chello062178085149.1.12.vie.surfer.at) joined #forth 21:51:10 --- join: PoppaVic (n=pete@0-1pool64-227.nas22.chicago4.il.us.da.qwest.net) joined #forth 22:25:49 --- quit: Cheery (Read error: 104 (Connection reset by peer)) 22:25:52 --- join: Cheery_ (i=Henri@a81-197-45-47.elisa-laajakaista.fi) joined #forth 22:33:12 --- quit: rsyncx ("Leaving") 22:39:12 --- join: neceve (n=Clau@unaffiliated/neceve) joined #forth 23:26:24 --- quit: neceve ("Bye people, I'm leaving") 23:40:56 hmm 23:49:47 hi 23:50:20 howdy 23:59:59 --- log: ended forth/06.03.03