00:00:00 --- log: started forth/19.05.28 00:29:36 --- join: dddddd (~dddddd@unaffiliated/dddddd) joined #forth 00:48:33 --- join: xek_ (~xek@apn-37-248-138-80.dynamic.gprs.plus.pl) joined #forth 02:02:45 --- quit: ashirase (Ping timeout: 248 seconds) 02:08:57 --- join: ashirase (~ashirase@modemcable098.166-22-96.mc.videotron.ca) joined #forth 03:31:05 --- join: gravicappa (~gravicapp@h37-122-123-170.dyn.bashtel.ru) joined #forth 03:39:18 --- join: mark4 (~mark4@cpe-45-36-112-145.triad.res.rr.com) joined #forth 03:41:39 folks, I would love to know your experience and opinion on the differing semantics for IF: 1. classical, consuming the top of stack; 2. machineforth, testing a flag external to the stack (such as processor flags) 03:42:33 btw I also asked on https://github.com/ForthHub/discussion/issues/82 04:21:20 Both and more depending on application :3 . 05:26:59 --- quit: dave0 (Quit: dave's not here) 05:28:24 muzgo: the 1. approach is easier to implement in hardware and does not involve the usual issues an status register has ISA wise. 05:45:56 --- join: mark4_ (~mark4@cpe-2606-A000-808F-FD00-0-0-0-8.dyn6.twc.com) joined #forth 05:49:52 muzgo: my model is closest to the first approach, though the details differ a little (my system consumes a flag [which must be -1 or 0] on TOS and then calls a function based on the flag, rather than branching on zero [my vm has conditional calls, but not conditional jumps]) 05:51:17 muzgo: I don't have a processor flag for conditionals, so the second option wouldn't work at all on my system 05:55:37 crc you have data types then ? 05:55:50 mark4_: no, it's forth 05:56:11 crc if true is -1 and false is 0 and 1/2/3.... are none of the above that sounds like data types lol 05:56:19 just due to a design decision, true has to be -1 and false 0 05:57:03 not a problem, just have do 0= 0= if .... then 05:58:40 crc: ya using twos complement, yes? 05:58:44 http://forth.works/36fb6e4f28c5e8be49b58a970109dcd9 05:58:44 is the code implementing the conditional primitives 05:59:13 Zarutian: yes 06:00:23 so -1 is all ones cell which means that one can, most times, use AND and OR for both logical and binary operations. 06:01:54 you always could :) 06:02:02 5 if .... then 06:03:12 mark that would likely cause a crash 06:03:18 AND takes the place of & and && 06:03:31 not usually :) 06:03:57 and i would call that a bug, you shuld take -1 as true and everything else as false to be safe 06:04:14 which is actually an inversion of how its usually done 06:04:24 0 is false and everything else is true 06:04:29 http://forth.works/bb20defbe458485c4db7a743a9acb72f 06:04:30 would be roughly the equivalent of my primitives in a standard-ish forth 06:04:31 theres no true/false/crash :) 06:05:23 just do "0= 0=" in front of every one of your IF statements to make them the equiv of other forths 06:05:39 or "0= not" 06:05:46 but the "not" is technically incorrect 06:06:07 it just reads better in english 06:07:13 I'd use n:zero? or n:-zero? if the flag might be invalid 06:07:36 you allow negative zero? 06:07:43 (my standard library only returns flags of -1 or 0, so this isn't an issue in most cases) 06:08:13 -zero? is read as "not zero" 06:08:16 also allowing users to shoot themselves in the foot is what makes forth way more powerful and user friendly than c :P 06:08:19 aha 06:09:27 im currently emerging webkit-gtk, this used to takes HOURS on my other laptop, on this one i think it takes about an hour 06:09:49 if it were coded with x4 it would take 2 seconds to compile :/ 06:09:55 max 06:15:45 proteusguy, you look like you could handle yourself in a bar fight lol 06:16:11 mark4_, hahaha umm... you see me somewhere? 06:16:25 your following the x4 project 06:16:39 your profile has a picture 06:17:46 Ah! Probably my B&W headshot. I was doing a photo shoot (as the photographer) and a friend of mine took a shot of me while I was waiting for the models to reset. haha 06:18:17 im photophobic :P 06:19:19 Actually I took up photography when I was 16 because I hated getting my picture taken all my life and figured the best way not to be in the picture was to be the guy behind the camera. Turned out I was pretty good at it as all the cheerleaders asked me to shoot their yearbook pics. 06:20:01 "in private" ? ;) 06:20:39 my father was an avid photographer when he was younger. now that he has retired he has gotten back into it. he has over 400 cameras now :/ 06:20:49 and over 200 handguns and 200 rifles... omg 06:20:55 some rare ones too 06:23:51 yay webkit-gtk emerge complete... finally 06:24:20 had about 190 packages to upgrade on this system because I have been booted to windows to play games lol 06:26:15 i would really like to know why emrge -uDN world always leaves the most time consuming packages till last? 06:26:26 webkit-gtk and now libreoffice 06:26:53 2 more to go after this, i bete one of them is firefox lol 06:28:54 mark4_: I didnt know you were into gentoo 06:29:49 its been my primary os for 17 years? 06:30:02 i think i picked it up 2000 2001 or something 06:30:09 might even have been before that, i ferget 06:31:42 never had the patience to update it. 06:32:04 usually i start it going right as im going to sleep or when i can keep doing whatever as it updates 06:33:31 oh. i bet the other package is wine-staging lol 06:42:58 mark4_: you switched to gentoo in 2003 06:43:23 aha 06:43:27 how do you know that btw lol 06:44:00 11:34:45 aha well i just switched to gentoo from debian - not abandoning debian yet tho 06:44:06 http://forthworks.com/forth/irc-logs/03.11.09 06:44:07 that was a lie 06:44:12 i totally abandoned debian 06:44:19 lol 06:45:49 the biggest differene was in #debian they kept trying to pronounce "I440r" as 1337 speak and calling me lame for having such a lame nick on irc. 06:46:08 * crc keeps a mirror of clog; it's handy for looking up old chat mentions... 06:46:12 and any time i asked a nub question the answer was "rtfm" from a dozen or so people 06:46:42 in #gentoo it was always helpful answers from a bunch of ppl 06:46:57 "You heard the one about the constipated mathematican?" 06:47:01 ya, clog has his uses 06:47:14 "He had to work it out with a pencil." 06:47:22 ouch 06:48:39 lets just say that he went through a lot of paper 06:54:51 crc: thanks for the answer. I didn't mention your work specifically because I already knew it :) 06:55:31 --- quit: mark4 (Disconnected by services) 06:55:53 --- join: mark4 (~mark4@cpe-45-36-112-145.triad.res.rr.com) joined #forth 06:56:01 --- quit: mark4 (Disconnected by services) 06:56:03 CORDIC: what kinds of programs were favored by using one or the other? 06:56:04 --- nick: mark4_ -> mark4 06:56:26 --- join: mark4_ (~mark4@cpe-45-36-112-145.triad.res.rr.com) joined #forth 06:57:12 Zarutian: that's a good point, thanks. personally I don't care that much, but it is good to know. I am mostly interested in how that impacts the user and the programs written using each type 07:17:03 * tabemann 's been using Debian since 2001 07:18:51 * crc distrusts debian's package manager 07:19:36 emerge --depclean and revdep-rebuild solves all the problems .deb fails at 07:20:56 I use pkgsrc on my remaining Linux server and the ports trees on FreeBSD and OpenBSD 07:34:03 okay, gonna head off to work 07:38:22 --- quit: tabemann (Ping timeout: 252 seconds) 07:48:01 I really like the way control structures work in DSSP https://www.reddit.com/r/Forth/comments/bu0umm/libredssp_a_gpl_licensed_dssp_interpreter/ 08:00:44 pointfree: when I first saw the current conditionals on retroforth, DSSP immediately came to mind 08:02:45 --- quit: proteusguy (Ping timeout: 248 seconds) 08:05:53 --- quit: mark4 (Remote host closed the connection) 08:15:58 muzgo: Also, `( n) DO A` and `RP A` are a lot easier to implement for interpretation state than `( n 0) DO A LOOP` and `BEGIN A UNTIL` 08:15:58 `: rp ' begin dup execute until drop ;` 08:15:58 `: do ' swap 0 ?do dup execute loop drop ;` 08:15:58 `5 do cr` 08:15:58 `rp key? key emit` 08:30:12 --- join: X-Scale` (~ARM@229.219.137.78.rev.vodafone.pt) joined #forth 08:30:49 --- quit: X-Scale (Ping timeout: 246 seconds) 08:31:06 --- nick: X-Scale` -> X-Scale 08:31:32 Or for both compilation and interpretation state support: 08:31:32 `: do ( xt n --) 0 ?do dup execute loop drop ;` 08:31:32 `: rp ( xt --) begin dup execute until drop ;` 08:31:32 `: crs ['] cr 5 do ;` 08:31:32 `crs` 08:31:33 `' cr 5 do` 08:42:10 pointfree: yup, pretty straightforward. I should try writing some stuff using these repetition forms 08:46:15 --- join: dys (~dys@tmo-119-29.customers.d1-online.com) joined #forth 08:59:20 pointfree: wouldn't you need to push/pop the xt to execute? 09:24:27 crc: no in the two cases he mentioned, but in general you would 10:26:18 --- join: PoppaVic (~PoppaVic@unaffiliated/poppavic) joined #forth 11:38:22 --- join: proteusguy (~proteusgu@cm-58-10-208-108.revip7.asianet.co.th) joined #forth 11:38:22 --- mode: ChanServ set +v proteusguy 11:40:49 loops are loopy 11:40:57 recursion is the good stuff 11:41:22 especially in Forth where there's no stack frame crap and tail calls don't need to be "optimised" per se 11:59:19 * crc has no problem with recursion as long as it doesn't impair readablility 12:06:46 a lot of my loops look somewhat like `: (main) do thing rdrop recurse ; : main (main) ;` 12:06:57 Counted loops I use 0; 12:10:40 `[ ... ] times` vs `push ... pop n:dec 0; recurse` 12:13:15 `[... TRUE ] while` for endless loops is also pretty. 12:14:44 I've thought about adding a `forever` combinator: `[ ... ] forever` 12:15:15 --- part: PoppaVic left #forth 12:22:08 --- quit: gravicappa (Ping timeout: 244 seconds) 12:25:31 I was trying to write `times` using recursive words, and now I just have something that's probably the same as normal times 12:25:47 but with a tail call 12:26:14 http://ix.io/1Kji 12:26:55 conceptually the same, not implementation-ally 12:31:53 `repeat 0; #1 - push dup push call pop pop again` 12:32:14 lol. 12:57:16 not using `dip` here for performance reasons. 12:58:33 `as{ 'puducapo i }as` hehe 12:58:52 defined before the assembler is 12:59:31 surprised 12:59:48 the retro standard library is very tight knit though 12:59:51 less surprised 13:00:06 times (nq-) [ swap repeat 0; `33886721 `1 `2053 `1542 again ] call drop ; 13:01:12 with the machine code inlined. I've had a few things fail to work properly doing it this way though, so I'm using the non-packed version for now until I have time to do a deep dive and see why. 13:45:16 --- quit: xek_ (Ping timeout: 258 seconds) 13:56:46 --- quit: Keshl (Read error: Connection reset by peer) 13:57:06 --- join: Keshl (~Purple@207.44.70.214.res-cmts.gld.ptd.net) joined #forth 15:12:46 --- quit: Keshl (Quit: Konversation terminated!) 15:51:39 --- quit: john_cephalopoda (Ping timeout: 250 seconds) 16:07:07 --- join: john_cephalopoda (~john@unaffiliated/john-cephalopoda/x-6407167) joined #forth 16:07:59 --- join: dave0 (~dave0@069.d.003.ncl.iprimus.net.au) joined #forth 16:08:34 hi 16:15:21 --- quit: john_cephalopoda (Ping timeout: 252 seconds) 16:25:11 --- join: Keshl (~Purple@207.44.70.214.res-cmts.gld.ptd.net) joined #forth 16:26:59 --- join: rdrop-exit (~markwilli@112.201.166.63) joined #forth 16:28:49 --- join: john_cephalopoda (~john@unaffiliated/john-cephalopoda/x-6407167) joined #forth 16:30:30 c[_] Good morning Forthwrights 17:08:39 --- quit: nighty (Read error: Connection reset by peer) 17:24:09 --- quit: mark4_ (Quit: Leaving) 17:38:56 --- quit: pareidolia (Quit: ZNC 1.7.1 - https://znc.in) 17:39:46 --- join: pareidolia (~pareidoli@87.213.124.143) joined #forth 17:52:15 --- join: tabemann (~tabemann@rrcs-162-155-170-75.central.biz.rr.com) joined #forth 18:31:33 --- quit: proteusguy (Ping timeout: 248 seconds) 19:02:22 --- join: nighty (~nighty@b157153.ppp.asahi-net.or.jp) joined #forth 19:26:23 --- join: gravicappa (~gravicapp@h37-122-123-170.dyn.bashtel.ru) joined #forth 19:27:20 --- quit: dave0 (Quit: dave's not here) 20:04:30 --- quit: dddddd (Remote host closed the connection) 20:05:54 --- quit: tabemann (Ping timeout: 268 seconds) 20:29:03 --- join: tabemann (~tabemann@2600:1700:7990:24e0:b944:a349:56b9:12fb) joined #forth 21:37:03 --- quit: bb010g (Read error: Connection reset by peer) 21:37:05 --- quit: jimt[m] (Read error: Connection reset by peer) 21:37:14 --- quit: siraben (Read error: Connection reset by peer) 21:37:22 --- quit: alexshpilkin (Remote host closed the connection) 21:39:49 --- quit: john_metcalf (Ping timeout: 248 seconds) 21:47:05 --- join: bb010g (bb010gmatr@gateway/shell/matrix.org/x-umxjzolcysylmcqd) joined #forth 22:12:16 --- join: proteusguy (~proteusgu@cm-58-10-208-108.revip7.asianet.co.th) joined #forth 22:12:16 --- mode: ChanServ set +v proteusguy 22:19:34 --- quit: proteusguy (Remote host closed the connection) 22:27:18 --- join: siraben (sirabenmat@gateway/shell/matrix.org/x-sqgxrnqizdhgypuz) joined #forth 22:27:18 --- join: jimt[m] (jimtmatrix@gateway/shell/matrix.org/x-oibmrjfihseyllbm) joined #forth 22:27:19 --- join: alexshpilkin (alexshpilk@gateway/shell/matrix.org/x-kkqrwtqrjxswerkc) joined #forth 22:39:57 --- join: dave0 (~dave0@069.d.003.ncl.iprimus.net.au) joined #forth 22:40:24 re 22:48:20 --- join: proteusguy (~proteusgu@mx-ll-14.207.209-205.dynamic.3bb.co.th) joined #forth 22:48:20 --- mode: ChanServ set +v proteusguy 23:01:06 --- nick: reepca` -> reepca 23:59:59 --- log: ended forth/19.05.28