[00:35:39] We do have a `HOOK:` keyword [00:35:43] s/keywod/keyword [00:35:46] But not really my point. :-p [01:23:14] been working on "not garbage collection" for my lang. [01:24:09] things don't get deleted until all references to them have been removed from the stack. [01:25:22] references only apply to blocks, and all references to a block are linked by a doubly linked list. this means you can push large chunks of data around by reference, but modifying them always copies their data. [01:43:10] * mwgkgk [mwgkgk!uid243904@gateway/web/irccloud.com/x-ozhpeuhthfjtaddj] has joined the channel. [01:50:03] * Sgeo [Sgeo!~Sgeo@ool-18b982ad.dyn.optonline.net] has quit (Read error: Connection reset by peer). [01:52:09] * Sgeo [Sgeo!~Sgeo@ool-18b982ad.dyn.optonline.net] has joined the channel. [01:57:57] * zolk3ri [zolk3ri!~zolk3ri@gateway/tor-sasl/zolk3ri] has joined the channel. [02:12:34] * ptrkriz [ptrkriz!~ptrkriz@81.4.110.225] has quit (Ping timeout: 260 seconds). [04:01:07] * mwgkgk [mwgkgk!uid243904@gateway/web/irccloud.com/x-ozhpeuhthfjtaddj] has quit (Quit: Connection closed for inactivity). [04:37:39] * Sgeo_ [Sgeo_!~Sgeo@ool-18b982ad.dyn.optonline.net] has joined the channel. [04:40:16] * MDude [MDude!~MDude@71.50.47.112] has quit (Ping timeout: 240 seconds). [04:40:36] * Sgeo [Sgeo!~Sgeo@ool-18b982ad.dyn.optonline.net] has quit (Ping timeout: 240 seconds). [05:59:40] imode, i think the standard term for that would be "copy on write" [06:06:03] yup! [06:07:22] sounds like fun - did the same thing recently for my video processing library - before that, it was a manual thing you had to before you modified an image [06:08:31] what is your language anyway? [06:08:44] 's called feather. [06:08:59] it's a scheme-y lisp-y concatenative-y thing with no distinction between compile and runtime. [06:09:47] interpreted or a hybrid thing? [06:10:06] largely interpreted, but I'm working on a compiler. [06:10:18] kinda has to be. 99% of the syntax is derived. [06:10:32] hmm - aiming for jit for that? [06:10:34] there are 8 core primitives. 21 in total if you want the "full power" of the language. [06:10:46] yeah, I'm hoping. [06:10:57] in the worst case a tight dispatch loop won't hurt. [06:11:23] yeah - kinda looking that way in the long term for my stuff [06:11:44] jitting can get complicated unless you have a really tight and minimal core. [06:12:44] in the short time, i try to 'optimise' my looped token streams down to their implied types (int, double etc) and function pointers [06:13:21] it's not like blindingly fast or anything, but it's not too bad either [06:13:40] which language are you implementing in? [06:14:01] currently Python, but my intention is to bootstrap a small C interpreter, which can be used to generate native machine code. [06:14:07] and also an implementation in Go. [06:15:48] let's see if I can snag you a bit of syntax... [06:16:01] cool :) - my language doesn't really lend itself to multiple implementations :) - it's an embeddable c++ library [06:16:15] sounds good - am interested [06:16:33] https://hastebin.com/rucuquluwo.txt [06:16:43] an example of defining if ... then ... else ... end blocks [06:17:00] you can do something similar with while ... do ... end [06:17:20] https://hastebin.com/yayosejifi.txt an example of what assembling a full block looks like in the REPL. [06:18:10] https://hastebin.com/ihasuyedan.txt and here's the definitions required to build conditional blocks, recursion modifiers, and a while loop. [06:18:56] [[[:left: :right:] <- local vars? [06:19:13] nope, stack modifiers. [06:19:29] left takes something on the bottom of the stack and throws it on top. right takes something on the top and throws it on the bottom. [06:19:41] ah - ok [06:19:47] the stack is technically a tape. [06:22:01] i see - my approach is quite different in that i implement my logical branches and loop parsing/execution in the 'host language' rather than try to define a parser which allows the implementation iyswim [06:23:07] yeah, that makes sense. imo it's better to have that stuff be "built-in" or at least baked in at parse time. I'm fiddling with church numerals and shit. [06:23:07] (i think i probably could implement some of those constructs in the language too, but would definitely execute slower) [06:24:01] yeah - think it's mostly about compromise and where you want to put the complexity - in the parser or in the parsed code [06:24:26] my parser is splitting on whitespace. :p [06:24:28] in the latter, it may simplify reimplimentations of another parser [06:24:51] as a consequence, I have no string literals. so if you want that... implement an evaluator. :P [06:24:54] yes :) - that's the great thing about concanetive languages - that's all they need to do:) [06:25:49] heh - i have a 'parse' type of thing which consumes the next token in the input string and puts it on the stack as a string [06:26:13] so basically, a use of that is the simplest: $ "hello world" [06:26:53] your parser must know how to differentiate between quoted string literals, though. [06:27:05] i.e knowing that the space between those two words doesn't count as a token separator. [06:28:12] yes - if i see a " as the first char, i keep scanning/concatanating until the closing " followed by whitespace - also [should] allow nested \" combinations [06:28:34] if the closing quote isn't followed by whitespace, it's an error [06:29:04] huh. I treat that as a separate token. [06:29:10] ...that's a neat corner case. [06:29:49] my first use is from the command line :) - command line parsing is pretty much as i describe it there [06:29:57] neat. a"b"c yields [97 98] c [06:30:24] i would see that as an error :) - unless a token of a"b"c exists :) [06:30:25] that's just from my first pass junk parser. really the language only supports whitespace delimited tokens. [06:31:52] the intent behind feather was initially a fully sandboxed language for users to run code in. [06:33:00] similar goal with mine :) - the base implementation only understands numerics, strings, arrays and stacks :) - it can't even reference files :) [06:33:26] * ephe_meral [ephe_meral!~amnesia@2a02:8109:8880:2004:f098:4989:c1f3:8ee] has joined the channel. [06:34:18] (the exception to that are loading script files, but only from very specific directories) [06:34:34] https://gitlab.com/lilo_booter/rpany [06:35:00] oh hey I've actually seen this. [06:35:04] neat shit. [06:35:46] i think it's pretty :p [06:43:12] * ephe_meral [ephe_meral!~amnesia@2a02:8109:8880:2004:f098:4989:c1f3:8ee] has quit (Ping timeout: 260 seconds). [06:46:57] imode: i actually wrote it to replace a testing tool which i wrote for the day job - it's all about video processing, and it implements a similar language, but in a really embarassing hacky way :) [06:47:27] rpany allowed me to replace it with https://gitlab.com/lilo_booter/vml-batch [06:47:45] siiiick. [06:48:58] there's a ton of stuff that's not mentioned there :) - filters to do most things you need to manipulate video for example (barring 3d stuff, but it's on the way :)) [06:49:57] damn. [07:02:02] (added a little more info the usage summary on that vml-batch link there - indicates where the rpn kicks in for building video graphs) [08:01:13] * zolk3ri [zolk3ri!~zolk3ri@gateway/tor-sasl/zolk3ri] has quit (Remote host closed the connection). [08:32:39] * Sgeo_ [Sgeo_!~Sgeo@ool-18b982ad.dyn.optonline.net] has quit (Read error: Connection reset by peer). [09:35:03] * tme5 [tme5!~tme5@185.214.220.196] has joined the channel. [11:52:54] * imode [imode!~linear@unaffiliated/imode] has quit (Ping timeout: 272 seconds). [13:08:28] * tmew5 [tmew5!~tme5@185.214.220.209] has joined the channel. [13:09:04] * tme5 [tme5!~tme5@185.214.220.196] has quit (Read error: Connection reset by peer). [13:09:23] * tmewett [tmewett!~tme5@185.214.220.197] has joined the channel. [13:12:45] * tmew5 [tmew5!~tme5@185.214.220.209] has quit (Ping timeout: 240 seconds). [14:57:36] * Sgeo [Sgeo!~Sgeo@ool-18b982ad.dyn.optonline.net] has joined the channel. [15:47:15] * MDude [MDude!~MDude@71.50.47.112] has joined the channel. [17:51:05] * tmewett [tmewett!~tme5@185.214.220.197] has quit (Quit: Leaving). [19:00:58] * imode [imode!~linear@unaffiliated/imode] has joined the channel. [21:41:36] * [1]MrMobius [[1]MrMobius!~MrMobius@208.58.206.154] has joined the channel. [21:43:32] * MrMobius [MrMobius!~MrMobius@208.58.206.154] has quit (Ping timeout: 256 seconds). [21:43:33] * [1]MrMobius is now known as MrMobius