[01:47:16] * rprimus [rprimus!~micro@unaffiliated/micro] has quit (Ping timeout: 246 seconds). [01:47:23] * rprimus [rprimus!~micro@unaffiliated/micro] has joined the channel. [03:26:02] * zgrep [zgrep!~zgrep@ircpuzzles/2015/april-fools/sixth/zgrep] has quit (Ping timeout: 260 seconds). [04:25:50] * zgrep [zgrep!~zgrep@ircpuzzles/2015/april-fools/sixth/zgrep] has joined the channel. [05:49:56] * ephe_meral [ephe_meral!~amnesia@ip5f5bf7d1.dynamic.kabel-deutschland.de] has joined the channel. [05:54:11] * proteusguy [proteusguy!~proteusgu@cm-58-10-208-180.revip7.asianet.co.th] has quit (Ping timeout: 240 seconds). [05:56:49] * ephe_meral [ephe_meral!~amnesia@ip5f5bf7d1.dynamic.kabel-deutschland.de] has quit (Ping timeout: 246 seconds). [06:07:31] * proteusguy [proteusguy!~proteusgu@cm-58-10-208-180.revip7.asianet.co.th] has joined the channel. [06:17:31] * Sgeo [Sgeo!~Sgeo@ool-18b982ad.dyn.optonline.net] has quit (Read error: Connection reset by peer). [08:08:24] * ephe_meral [ephe_meral!~amnesia@217.9.41.114] has joined the channel. [08:42:07] * zgrep [zgrep!~zgrep@ircpuzzles/2015/april-fools/sixth/zgrep] has quit (Ping timeout: 240 seconds). [08:43:42] * zgrep [zgrep!~zgrep@ircpuzzles/2015/april-fools/sixth/zgrep] has joined the channel. [08:46:28] * zgrep [zgrep!~zgrep@ircpuzzles/2015/april-fools/sixth/zgrep] has quit (Excess Flood). [08:46:44] * zgrep [zgrep!~zgrep@ircpuzzles/2015/april-fools/sixth/zgrep] has joined the channel. [08:51:17] * zgrep [zgrep!~zgrep@ircpuzzles/2015/april-fools/sixth/zgrep] has quit (Ping timeout: 260 seconds). [08:52:09] * zgrep [zgrep!~zgrep@ircpuzzles/2015/april-fools/sixth/zgrep] has joined the channel. [10:25:23] * ephe_meral [ephe_meral!~amnesia@217.9.41.114] has quit (Ping timeout: 240 seconds). [11:34:06] * ephe_meral [ephe_meral!~amnesia@217.9.41.114] has joined the channel. [13:27:04] * Sgeo [Sgeo!~Sgeo@ool-18b982ad.dyn.optonline.net] has joined the channel. [13:54:11] * nitrix [nitrix!~nitrix@haskell/developer/nitrix] has quit (Read error: Connection reset by peer). [13:59:33] * nitrix [nitrix!~nitrix@haskell/developer/nitrix] has joined the channel. [16:11:05] * ephe_meral [ephe_meral!~amnesia@217.9.41.114] has quit (Ping timeout: 240 seconds). [16:45:52] > In the future it will also run on high-end mobile devices, although there are no plans to scale the language down into deeply embedded devices with little memory or no OS. [16:45:56] progress?:D [17:16:02] <^alex> if we had infinite time and energy, we would absolutely make a bare-metal factor machine [17:26:19] please do [17:27:02] why does "wait-for-process zero? [ . ] [ . ] if" work but "wait-for-process zero? [ . ] when" doesn't? [17:27:43] (there r 2 elements on the stack, but regardless) [17:27:52] I can give u more info but maybe it's enough :/ [17:28:18] if not I can pastebin the code that works, the data stack, etc.. but it's supposed to work! idk why it doesn't [17:28:42] run-process wait-for-process zero? swap '[ _ . ] when [17:28:44] I'm using this right now [17:28:46] because it works [17:28:56] run-process wait-for-process zero? swap [ . ] when [17:28:58] doesn't work [17:32:45] <^alex> '[ _ . ] is equivalent to [ . ] curry, iirc [17:32:48] <^alex> or [ . ] with [17:32:53] <^alex> something like that [17:33:08] <^alex> maybe [17:33:35] <^alex> we also use `with-process-reader` a lot [17:34:03] <^alex> per https://twitter.com/atax1a/status/1160626224818843648 - `"command" utf8 [ "foo" output-stream get [ stream-print ] with-disposal contents ] with-process-stream` [17:34:33] <^alex> writes "foo" into the stdin of "command", reads and prints UTF-8 out of it [17:34:41] <^alex> s/prints/consumes [17:46:59] <^alex> (you might want to use `try-process` and catch the `process-failed`) [17:49:27] * FreeFull [FreeFull!~freefull@defocus/sausage-lover] has joined the channel. [17:50:01] yeah but if I have "t" and "x" on the datastack, why doesnt when work? [17:50:51] run-process wait-for-process zero? swap [ . ] curry when [17:50:53] this does work [17:50:53] odd [17:59:36] <^alex> yeah that makes sense to us [17:59:57] <^alex> '[ _ . ] is a currying [18:00:07] okay but [18:00:26] IN: scratchpad "hash" "echo foo" run-process wait-for-process zero? [ . ] when [18:00:29] "hash" [18:00:32] it works [18:00:39] but not in the code... idk why not [18:00:44] the data stack is the same [18:00:52] t [18:00:53] "hash" [18:01:06] and I know this because I printed it using: wait-for-process zero? . . [18:01:12] it printed t and "hash" [18:01:29] so I wonder why it doesn't work... [18:01:32] <^alex> welll [18:01:34] <^alex> [ "hash" "echo foo" run-process wait-for-process zero? [ . ] when ] infer [18:01:36] <^alex> does not infer [18:01:52] yea [18:01:56] I get that error [18:02:01] :c [18:02:15] right [18:03:10] <^alex> "things that work at the listener but do not infer" are a thing because the listener is a naive compiler [18:03:20] I see [18:03:20] <^alex> doing a word definition invokes the compiler [18:03:28] <^alex> the compiler proper* [18:03:29] okay that makes sense now [18:03:54] so I suppose I should be using curry then [18:04:11] <^alex> curry or fry, they're equivalent [18:04:16] <^alex> (for the most part) [18:05:44] fry is more readable, but on the other than I won't have to include fry, not sure it makes a difference tbh [18:05:56] probably not [18:06:18] hand* [18:25:47] <^alex> the optimizing compiler knows how to turn fry into curry [18:26:16] oh that's good to know [18:26:23] <^alex> one of our few interactions with Slava on Twitter has been to say that reading through the optimizing compiler for Factor was a mind-expanding experience [18:26:50] <^alex> we've seen it turn words full of stack-shuffles, through data flow analysis, into a bunch of straight-line register moves [19:04:03] * FreeFull [FreeFull!~freefull@defocus/sausage-lover] has quit (Ping timeout: 260 seconds). [19:53:16] oh, where do i find the code for the compiler? [20:08:59] <^alex> in the `compiler` vocabulary, mainly [20:10:16] <^alex> we got to know it by walking through the docs for `compile-word` and the associated Compiler Implementation page [20:10:46] <^alex> but we had the benefit of having written a C compiler, in C++, as part of our computer science degree. [21:18:06] ^alex: where's the compiler? is it not here? https://gitweb.factorcode.org/gitweb.cgi?p=factor.git;a=tree;f=core/compiler;hb=HEAD [21:19:33] oh, maybe https://gitweb.factorcode.org/gitweb.cgi?p=factor.git;a=blob;f=basis/compiler/compiler.factor [22:13:57] <^alex> idk about files on disk, we just type `\ compile-word help` at the listener [22:16:56] <^alex> :)