00:00:00 --- log: started forth/14.08.09 00:08:13 --- part: xyh left #forth 00:15:45 --- join: xyh (~user@222.58.71.50) joined #forth 02:02:06 --- quit: kumul (Ping timeout: 255 seconds) 02:02:28 --- part: xyh left #forth 03:30:27 --- quit: DGASAU (Ping timeout: 246 seconds) 03:32:36 --- join: DGASAU (~user@p50993595.dip0.t-ipconnect.de) joined #forth 05:39:44 --- nick: karswell` -> karswell 06:20:40 --- join: Zarutian (~zarutian@194-144-84-110.du.xdsl.is) joined #forth 06:21:12 --- nick: Vuokko_ -> Vuokko 07:00:18 --- quit: Zarutian (Quit: Zarutian) 07:20:26 --- join: Zarutian (~zarutian@194-144-84-110.du.xdsl.is) joined #forth 08:04:53 --- join: true-grue (~grue@95-26-14-33.broadband.corbina.ru) joined #forth 08:29:44 --- join: elaforest (~elaforest@unaffiliated/elaforest) joined #forth 09:00:26 --- quit: elaforest (Ping timeout: 250 seconds) 09:12:15 --- join: xyh (~user@222.58.71.50) joined #forth 09:28:55 --- join: bbloom (~bbloom@162.244.139.179) joined #forth 09:53:01 --- part: xyh left #forth 09:53:32 --- join: xyh (~user@222.58.71.50) joined #forth 09:57:48 --- join: Desmaad (~MrPyke@CPEbc140136a7f3-CMbc140136a7f0.cpe.net.cable.rogers.com) joined #forth 10:05:12 --- join: elaforest (~elaforest@unaffiliated/elaforest) joined #forth 10:07:49 --- quit: bjorkintosh (Remote host closed the connection) 10:09:24 --- quit: bbloom (Quit: Computer has gone to sleep.) 10:09:55 Hello. 10:10:06 hello 10:11:50 hello 10:11:54 ji 10:11:55 hi 10:13:59 I have one little question regarding word definitions. 10:14:15 ? 10:14:18 --- join: bjorkintosh (~bjork@ip68-13-229-200.ok.ok.cox.net) joined #forth 10:14:40 Desmaad: you do not have to ask to ask :) 10:15:42 Anyway, why do so many word definitions have the word DUP after the effect definition? 10:16:15 I know it means to duplicate the top value of the stack. 10:16:21 to act on a copy of the top of the stack 10:16:23 But why bother? 10:16:46 what if you wanted to re-use that value later? 10:17:12 : even. ( n -- ) dup 2 mod if ." odd" else ." even" then . ; 10:17:44 it is needed twice 10:17:48 Point. 10:18:08 Desmaad: Because when a function be executed, it takes away a value, from the top of the stack 10:18:17 Okay. 10:18:21 ... 10:18:26 and it's the obverse of words that end with DROP. 10:18:46 Which removes the top value from the stack. 10:18:56 yep 10:19:05 and other reason might be to balance control flow so stack comment is accurate in every execution path 10:19:12 to clean up any leftover values, if any. 10:21:07 indeed some loop migth look like var @ 10 0 do dup i + . loop drop 10:21:43 Desmaad: and different functions takes away different numbers of values, from the top of the stack :) 10:22:17 tangentstorm: how is your projects now ? 10:22:29 tangentstorm: I am trying to design a OS for x86_64 :: http://wiki.osdev.org/User:Xyh and http://wiki.osdev.org/Alta_Lang 10:27:51 very slowly... doing client work. 10:30:54 --- quit: Zarutian (Quit: Zarutian) 11:09:45 --- join: Zarutian (~zarutian@194-144-84-110.du.xdsl.is) joined #forth 11:22:00 --- join: bbloom (~bbloom@162.244.139.179) joined #forth 11:36:25 --- quit: Desmaad (Remote host closed the connection) 11:38:59 --- join: kumul (~mool@adsl-72-50-87-81.prtc.net) joined #forth 12:13:24 --- join: impomatic (~chatzilla@167.156.125.91.dyn.plus.net) joined #forth 12:51:33 --- quit: elaforest (Ping timeout: 240 seconds) 14:21:39 --- quit: bbloom (Quit: Computer has gone to sleep.) 14:31:38 --- part: xyh left #forth 15:00:09 --- join: xyh (~user@222.58.71.50) joined #forth 15:21:15 --- quit: kumul (Ping timeout: 250 seconds) 16:02:00 --- quit: true-grue (Read error: Connection reset by peer) 16:36:36 --- join: bbloom (~bbloom@c-67-183-87-90.hsd1.wa.comcast.net) joined #forth 17:09:28 --- quit: bbloom (Quit: Computer has gone to sleep.) 17:17:10 --- join: bbloom_ (~bbloom@c-67-183-87-90.hsd1.wa.comcast.net) joined #forth 17:22:27 --- join: kumul (~mool@adsl-72-50-87-81.prtc.net) joined #forth 17:24:19 --- join: kumool (~mool@adsl-72-50-87-51.prtc.net) joined #forth 17:27:38 --- quit: kumul (Ping timeout: 244 seconds) 17:41:23 --- quit: bbloom_ (Quit: Computer has gone to sleep.) 17:49:25 --- join: bbloom (~bbloom@c-67-183-87-90.hsd1.wa.comcast.net) joined #forth 17:55:55 --- join: saml_ (~saml@pool-71-190-5-241.nycmny.east.verizon.net) joined #forth 18:02:20 --- quit: bbloom (Quit: Computer has gone to sleep.) 18:50:48 --- part: xyh left #forth 18:51:51 --- quit: Zarutian (Quit: Zarutian) 19:55:39 --- join: xyh (~user@222.58.71.50) joined #forth 20:26:04 --- part: xyh left #forth 21:03:28 --- quit: saml_ (Ping timeout: 255 seconds) 23:38:57 --- quit: impomatic_ (Quit: impomatic_) 23:42:44 --- quit: impomatic (Ping timeout: 250 seconds) 23:48:00 --- join: impomatic (~chatzilla@167.156.125.91.dyn.plus.net) joined #forth 23:59:59 --- log: ended forth/14.08.09