←2025-10-23 2025-10-24 2025-10-25→ ↑2025 ↑all
00:12:38 -!- Lord_of_Life has quit (Remote host closed the connection).
00:13:31 -!- Lord_of_Life has joined.
00:29:26 -!- amby has quit (Quit: so long suckers! i rev up my motorcylce and create a huge cloud of smoke. when the cloud dissipates im lying completely dead on the pavement).
01:23:04 <esolangs> [[Collern]] https://esolangs.org/w/index.php?diff=166596&oldid=166560 * Dmiz * (+162)
01:23:55 <zzo38> I wanted to make a new OID arc to be standardized by ITU or ISO (preferably ITU, although I have been told that is nearly impossible to actually tell them anything), which is combining an existing identification (of one of many kinds, e.g. international telephone numbers, internet domain names, ICAO airport codes, etc) with a timestamp, and in some cases also automatic delegation.
01:24:03 <zzo38> How would you do such a thing like that?
01:36:41 <esolangs> [[Collern]] https://esolangs.org/w/index.php?diff=166597&oldid=166596 * Dmiz * (+69)
03:51:54 <esolangs> [[User talk:Yayimhere]] https://esolangs.org/w/index.php?diff=166598&oldid=166582 * Yayimhere2(school) * (+2) /* Revert */
03:52:42 <esolangs> [[User talk:Yayimhere]] https://esolangs.org/w/index.php?diff=166599&oldid=166598 * Yayimhere2(school) * (+144) /* Sorry? */
03:53:37 <ais523> I'm looking through my mailserver logs, and there are a surprising number of HTTP requests in them – I think it's the AI scraperbots that have found a list of mailservers somewhere, and are just trying to interpret them as web addresses (domain:port) and trying to scrape a page from them
04:13:32 <esolangs> [[UnCompetition]] https://esolangs.org/w/index.php?diff=166600&oldid=166576 * Yayimhere2(school) * (+1082) /* Description */
04:29:53 <b_jonas> ais523: that's not unreasonable, if they send a HTTP request then whatever server is on the other side will often send an error reply that can let you figure out what kind of service it is, and you can send a more useful request the next time
04:30:11 <ais523> b_jonas: there's a couple of domains that are sending the same requests over and over again, though
04:30:34 <b_jonas> yeah, that's less useful probably
04:31:10 <b_jonas> especially if it's on port 25
04:32:29 <korvo> I wonder why they think that the wiki is inactive. We don't really rotate the featured-article box, but that's the only thing that isn't changing on the front page.
04:51:40 <esolangs> [[UnCompetition]] https://esolangs.org/w/index.php?diff=166601&oldid=166600 * Yayimhere2(school) * (+39) /* Computational class */
04:55:51 <zzo38> I have also seen HTTP requests on the SMTP server, on my computer, too.
04:57:47 -!- Yayimhere has joined.
04:58:13 <Yayimhere> hello, people!
04:58:23 <Yayimhere> or what people there may be
05:00:38 <esolangs> [[Utral]] https://esolangs.org/w/index.php?diff=166602&oldid=166547 * Yayimhere2(school) * (+20) /* Info */
05:00:47 <esolangs> [[Utral]] https://esolangs.org/w/index.php?diff=166603&oldid=166602 * Yayimhere2(school) * (+1) /* Info */
05:01:37 -!- slavfox has quit (Quit: ZNC 1.8.2 - https://znc.in).
05:02:14 <korvo> Yayimhere: Welcome back.
05:02:24 <Yayimhere> thanks!
05:02:58 <korvo> I thought about your question on altering the K combinator for a bit. Let's say that K' x y = y; From S, what can we do? Well, note that K' S y = y, so K'S is equivalent to I.
05:03:12 <Yayimhere> true
05:04:07 <korvo> I looked at it for a while, but I wasn't quite able to find B, C, or K; any of those would completely answer the question. I did find O and M and a few other common combinators, though.
05:04:21 <Yayimhere> hmm interesting
05:04:29 <Yayimhere> also
05:04:44 <Yayimhere> we could just shorten the reverse k to RK
05:04:44 <korvo> Well, I didn't try very hard. Maybe you can find them?
05:04:52 <Yayimhere> I can *try*
05:05:16 <Yayimhere> but you are a lot better than me, so I will probably not get much further than you
05:05:24 <Yayimhere> but it is quite interesting
05:05:35 <korvo> I'd avoid reusing letters. R, the robin, is a combinator of BCI already.
05:05:47 -!- slavfox has joined.
05:05:55 <Yayimhere> oh i didnt realize actually
05:06:43 <Yayimhere> also, the reason im asking, is because of the fact that this reverse K, is actually just the church numeral for 0
05:06:56 <korvo> Oh, I'm not better than you, just more well-researched. I bet that if I go get my copy of Smullyan off the shelf, I could find some words about this variant of K. Perhaps he has an exercise where he proves that it's equivalent to K, or where he proves that it's useless. It wouldn't be the first time; earlier in the year, that same book taught me that GI and BCI are equivalent.
05:07:21 <Yayimhere> true
05:08:13 <korvo> Ah! Careful with that. Lambda calculus is done with the assumption that we can build any applicative tree we want; combinatory logic is more restricted. They aren't the same system, even though they have a lot in common because they both have applicative trees.
05:08:47 <Yayimhere> oh they arent? I actually just assumed so, because SKI often is represented as lambda calculus expressions
05:08:53 <Yayimhere> (like in jot for example)
05:10:53 <korvo> My opinion on this is that a combinator is very limited; a combinator builds an applicative tree from its inputs. A closed lambda term, more generally, builds another lambda term from its inputs; a lambda term can have applications and also it can have abstractions.
05:11:29 <Yayimhere> true
05:11:44 <korvo> Well, not everybody agrees with me. See [[closed lambda term]] for what we *do* agree upon.
05:11:53 <Yayimhere> k
05:12:57 <korvo> But yeah, this means that Iota isn't a combinator. Neither is Alpha. They are closed lambda terms, though. Jot isn't a combinator, but a way to encode certain lambda terms.
05:13:11 <Yayimhere> yes
05:14:00 <Yayimhere> also if your wondering what I need this for, I need it to prove υλ TC
05:14:46 <korvo> I have no idea what's going on in that page, sorry.
05:14:55 <Yayimhere> no its fine
05:15:09 <Yayimhere> (ive figured it out anyways lol)
05:15:47 <Yayimhere> it is however still an interesting question
05:19:16 <Yayimhere> anyways
05:19:26 <korvo> Maybe. The standard proof that SKI can encode lambda terms, given at [[combinatory logic]], revolves around matching each of S, I, and K to different possible terms: S gives application, I gives De Bruijn index 0, and K gives constants. K' gives the ability to discard an argument and return I, which isn't the same as holding a constant.
05:19:57 <Yayimhere> im gonna go and make myself go crazy with uncompetition lol
05:20:00 <korvo> I bet that a computer search could quickly settle the question, but if the answer is a big tree filled with lots of S then that won't be enlightening.
05:20:07 <Yayimhere> yees
05:20:14 <Yayimhere> in fact
05:21:06 <korvo> I'm going to play more with Smalltix. I've documented my own calling convention at [[Vixen]]. Treating directories as objects is surprisingly fruitful.
05:21:18 <Yayimhere> cool!
05:22:20 <Yayimhere> also, does anyone know an esolang, where every function, no matter with input or no, will evaluate to a different output
05:24:16 <zzo38> Another use to attack your ally in Pokemon is: if you do not want to attack your opponent(s) for some reason (e.g. Destiny Bond), especially if your ally has Protect.
05:25:17 <esolangs> [[UnCompetition]] https://esolangs.org/w/index.php?diff=166604&oldid=166601 * Yayimhere2(school) * (+182) /* Computational class */
05:25:50 <esolangs> [[UnCompetition]] https://esolangs.org/w/index.php?diff=166605&oldid=166604 * Yayimhere2(school) * (+0) /* Computational class */
05:28:47 <esolangs> [[Underload]] https://esolangs.org/w/index.php?diff=166606&oldid=158524 * Yayimhere2(school) * (+13)
05:29:32 <esolangs> [[Xx]] https://esolangs.org/w/index.php?diff=166607&oldid=166503 * Yayimhere2(school) * (-8)
05:31:05 <esolangs> [[Xx]] https://esolangs.org/w/index.php?diff=166608&oldid=166607 * Yayimhere2(school) * (+13) /* turing completeness proof */
05:33:54 -!- Yayimhere has quit (Quit: Client closed).
05:37:19 -!- Yayimhere has joined.
05:39:34 <korvo> Yayimhere: That's not a language thing; can you see why?
05:39:48 * korvo forcing nuance to develop
05:40:12 <Yayimhere> huh?
05:40:20 <Yayimhere> sorry I got disconnected
05:44:51 <Yayimhere> korvo: what were you saying?
05:47:08 <korvo> Yayimhere: Evaluation of functions isn't a linguistic thing. We just pretend that they're connected.
05:47:34 <Yayimhere> true
05:48:44 <korvo> Like, is there a family of functions where each function evaluates to a different output (on a fixed input)? Yes.
05:49:09 <Yayimhere> but is there one without any input
05:49:15 <korvo> I'd ask what kind of programming *system* you want, not just what kind of *language* you're using to express computations in that system.
05:49:26 <Yayimhere> true
05:49:50 <korvo> Functions always have inputs. When we say that a function doesn't have an input, we mean that its input domain is a set with one element, and we always use that one element as the input.
05:50:16 <Yayimhere> yea thats true
05:50:18 <korvo> data 1 = *; f * = 42 -- f "doesn't have an input"
05:50:21 <Yayimhere> I say true a lot
05:50:23 <Yayimhere> BUT
05:51:51 <Yayimhere> i want a system where routing myself an infinite family of functions where "each function has a sort of "inertia", where they even without input, give an output" where "without input" is, a uniform input
05:52:23 <Yayimhere> that is also Turing complete
05:53:01 <ais523> so the interesting way of interpreting this is "is it possible to design a language so that there's some specific input that you can give to any function, and it causes every possible function to return a different output?"
05:53:16 <Yayimhere> in fact
05:53:27 <ais523> one example of a way you might do that would be to have an input that you can give to a function and it causes the function to print its own source code
05:53:47 <Yayimhere> or in principle, the system this is based off of, a function can return multiple outputs, as it is semi-ambiguous what it should return
05:54:02 <Yayimhere> (or a random one of these outputs)
05:54:05 <ais523> but, this sort of thing is difficult to work into a language because that sort of value can't correctly be manipulated using functions
05:54:13 <Yayimhere> also hello ais523!
05:54:28 <Yayimhere> yea. thats true.
05:54:38 <Yayimhere> so a quine function kinda?
05:54:47 <Yayimhere> or a quine input technically
05:55:00 <ais523> I've had esolang ideas where I wanted to do this sort of thing but was unable to design a coherent language around them (mostly based on object-oriented-like languages where objects were functions that took messages/methodcalls as arguments)
05:55:19 <Yayimhere> interestimng
05:55:22 <Yayimhere> *interesting
05:55:25 <ais523> it's just far too easy to end up with two requiremens that conflict with each other
05:55:50 <Yayimhere> again, this is all based off of an already existing language
05:56:52 <Yayimhere> ais523: requierments for the language/system, or for this input?
05:56:57 <Yayimhere> or for the function(s)
05:57:02 <ais523> for the language design
05:57:10 <Yayimhere> yea ok
06:04:43 <esolangs> [[UnCompetition]] https://esolangs.org/w/index.php?diff=166609&oldid=166605 * Yayimhere2(school) * (+60) /* Computational class */
06:15:27 -!- Yayimhere has quit (Ping timeout: 250 seconds).
06:40:18 -!- Sgeo has quit (Read error: Connection reset by peer).
07:21:17 <APic> Hi
07:37:18 <esolangs> [[User:JIT]] https://esolangs.org/w/index.php?diff=166610&oldid=165415 * JIT * (+41)
07:48:41 -!- Yayimhere has joined.
07:52:49 <esolangs> [[B9]] M https://esolangs.org/w/index.php?diff=166611&oldid=166507 * JIT * (+27)
07:54:06 -!- Yayimhere has quit (Quit: Client closed).
08:03:47 -!- Yayimhere has joined.
08:10:17 -!- Yayimhere has quit (Ping timeout: 250 seconds).
08:11:30 -!- tromp has joined.
09:12:44 <b_jonas> korvo: hold on, in https://logs.esolangs.org/libera-esolangs/2025-08.html#lvw you specifically told me that the Smullyan Mockingbird book does not give a name to KI. doesn't that mean a priori that you won't find the theorem of what you can generate from S and KI (and possibly I, I don't remember how Yayimhere asked exactly) in that book?
09:51:24 -!- Yayimhere has joined.
09:58:27 <strerror> (I is just ꓘS or ꓘꓘ (where ꓘ = KI))
10:04:15 -!- Yayimhere has quit (Ping timeout: 250 seconds).
10:05:11 <tromp> K is True and KI is False
10:05:46 <tromp> True x y = x and False x y = y
10:06:08 -!- Yayimhere has joined.
10:06:26 <Yayimhere> strerror: is this related to the reverse K? I have not been here I got dissconnected
10:08:42 <strerror> Yayimhere: yes. Though I've just picked a name for it, not found anything new about it.
10:08:49 <Yayimhere> yea
10:08:54 <Yayimhere> it does make sense naming wise
10:09:39 <strerror> Hmm it's “Lisu letter kha” — “a language of the Lisu people in Yunnan, China”
10:10:30 <Yayimhere> lol
10:10:48 <Yayimhere> well sorry Lisu people, your letter has now become K
10:10:50 <Yayimhere> lol
10:10:58 <Yayimhere> I say lol way too much
10:11:12 <strerror> tromp: that sounds suggestive of some kind of de Morgan duality? Though maybe only if we also flip S.
10:12:30 <strerror> SK is universal, Sꓘ may or may not be, and I suppose ꓘƧ ought to be for some Ƨ
10:12:52 <Yayimhere> yeaa
10:13:33 <Yayimhere> its would be quite interesting if Sꓘ AND K Ƨ are TC
10:14:34 <esolangs> [[95-98]] https://esolangs.org/w/index.php?diff=166612&oldid=134713 * Yayimhere2(school) * (+6) /* how it works */
10:15:04 <esolangs> [[Talk:95-98]] https://esolangs.org/w/index.php?diff=166613&oldid=156965 * Yayimhere2(school) * (+44) /* About addition arithmetic command */
10:16:03 <tromp> I think S,False is not TC
10:16:36 <Yayimhere> False?
10:16:53 <tromp> False = K I = S K
10:17:05 <Yayimhere> ok
10:25:22 <esolangs> [[2I1IF]] N https://esolangs.org/w/index.php?oldid=166614 * Yayimhere2(school) * (+603) Created page with "{{WIP}} '''2I1IF''' is a family of languages, based off of [[Uncompetition]]. == Concept == For a language to qualify for being a part of 2I1IF, it must be able to be interpreted as "An infinite amount of inputs, and a single universal function", and "An infinit
10:30:43 -!- Yayimhere has quit (Quit: Ping timeout (120 seconds)).
10:35:40 <esolangs> [[2I1IF]] https://esolangs.org/w/index.php?diff=166615&oldid=166614 * Yayimhere2(school) * (+220)
10:35:49 <esolangs> [[2I1IF]] https://esolangs.org/w/index.php?diff=166616&oldid=166615 * Yayimhere2(school) * (-8)
10:43:27 <esolangs> [[2I1IF]] https://esolangs.org/w/index.php?diff=166617&oldid=166616 * Yayimhere2(school) * (+517) /* Concept */
10:53:35 -!- amby has joined.
10:57:36 <esolangs> [[2I1IF]] https://esolangs.org/w/index.php?diff=166618&oldid=166617 * Yayimhere2(school) * (+6) /* Concept */
11:23:50 -!- perlbot has quit (Quit: ZNC 1.9.1+deb2+b3 - https://znc.in).
11:23:50 -!- simcop2387 has quit (Quit: ZNC 1.9.1+deb2+b3 - https://znc.in).
11:38:07 -!- Lord_of_Life has quit (Ping timeout: 246 seconds).
11:38:58 -!- Lord_of_Life has joined.
11:58:38 -!- Riviera has quit (Quit: leaving).
12:21:26 <ais523> I also did some experimentation with S and KI, and mixing them didn't seem like it was giving substantial capabilities over S on its own (e.g. S (KI) a b = (KIb)(ab) = I(ab) = ab, so S (KI) = I; and (KI) S also = I)
12:22:05 <ais523> this isn't a proof that it's S + KI is sub-TC, but it is pretty discouraging and makes it unlikely that adding KI to S would make it Turing-complete
12:23:30 <ais523> S S (KI) a = (Sa)(KIa) = S a I; S a I b = (ab)(Ib) = abb; thus S S (KI) = W and that is giving you a small amount of power that S doesn't have on its own
12:24:25 <ais523> but W (KI) and (KI) W are both also equivalent to I so this doesn't really help much
12:27:38 <ais523> `unidecode ꓘ
12:27:41 <HackEso> ​[U+A4D8 LISU LETTER KHA]
12:31:44 -!- ais523 has quit (Quit: quit).
12:38:38 -!- tromp has quit (Quit: My iMac has gone to sleep. ZZZzzz…).
13:20:29 -!- tromp has joined.
13:24:05 <esolangs> [[2I1IF]] https://esolangs.org/w/index.php?diff=166619&oldid=166618 * Yayimhere2(school) * (+14)
13:31:29 <esolangs> [[User:Yayimhere]] https://esolangs.org/w/index.php?diff=166620&oldid=166528 * Yayimhere2(school) * (+12) /* esolangs */
13:32:05 <esolangs> [[2I1IF]] https://esolangs.org/w/index.php?diff=166621&oldid=166619 * Yayimhere2(school) * (+41)
13:39:32 -!- Sgeo has joined.
13:41:26 <esolangs> [[UnCompetition]] https://esolangs.org/w/index.php?diff=166622&oldid=166609 * Yayimhere2(school) * (+1)
13:44:56 <esolangs> [[UnCompetition]] https://esolangs.org/w/index.php?diff=166623&oldid=166622 * Yayimhere2(school) * (+102) /* Computational class */
14:03:37 <esolangs> [[UnCompetition]] https://esolangs.org/w/index.php?diff=166624&oldid=166623 * Yayimhere2(school) * (+556) first Uncompetition program!
14:04:17 -!- Yayimhere has joined.
14:04:34 <Yayimhere> hello people, ive been on and off for a while, but now ill be more permanently on!
14:06:47 <Yayimhere> I just subjected myself to the worst manual interpretation of a program ive ever done, but im happy I did so
14:15:32 <esolangs> [[Talk:Crypten]] N https://esolangs.org/w/index.php?oldid=166625 * * (+101) Created page with "so @yayimhere what do you think? -~~~~"
14:16:41 -!- vista_user has joined.
14:16:47 -!- vista_user has changed hostmask to ~vista_use@user/DOS-User:11249.
14:17:39 <esolangs> [[Talk:Crypten]] https://esolangs.org/w/index.php?diff=166626&oldid=166625 * Yayimhere2(school) * (+259)
14:17:58 <Yayimhere> hello, vista_user (lol)!!!
14:18:03 <vista_user> yo.
14:18:07 <vista_user> if you think about it interphase g2 stage in mitosis is basically running `chkdsk` on the dna
14:18:17 <vista_user> (or `fsck`)
14:18:27 <Yayimhere> uuuuuuh
14:18:29 <Yayimhere> lol
14:18:31 <Yayimhere> ok
14:18:57 <vista_user> literally check it for errors
14:19:07 <vista_user> basically what both fsck and chkdsk do
14:19:26 <Yayimhere> what is fsck?
14:19:39 <int-e> "file system check"
14:19:56 <Yayimhere> and chkdsk?
14:20:17 <vista_user> check disk
14:20:20 <int-e> "check disk", this one is for dos and windows
14:20:31 <vista_user> literallh same command but batch instead of bash
14:20:52 <int-e> fsck is unixoid
14:21:16 <vista_user> (yes, fsck can be more stuff other than a way to avoid the f word in moderated chatrooms lol)
14:21:30 <Yayimhere> well I cant check for errors lol
14:21:47 <Yayimhere> cuz I dont have much knowledge of bash/batch nor dna
14:21:56 <esolangs> [[Talk:Crypten]] https://esolangs.org/w/index.php?diff=166627&oldid=166626 * Yayimhere2(school) * (+50)
14:22:08 <vista_user> it was a joke on both biology and computing either way
14:22:11 <esolangs> [[Crypten]] M https://esolangs.org/w/index.php?diff=166628&oldid=166583 * * (+255) Notes on similarity to BF
14:22:11 <int-e> vista_user: So what happens if I don't think about it? does that accelerate cell or organism death?
14:22:48 <Yayimhere> lol
14:23:07 <vista_user> int-e: im not sure
14:23:33 <vista_user> im not a scientist (not yet at least) im just some high school student
14:30:01 <korvo> b_jonas: Maybe I missed something, but K' x y = y; K I y = I; so KI isn't K'. I just woke up though, so maybe I'm not fully loaded yet.
14:31:20 <korvo> Oh, hello, K I y z = I z; so KI is a rank-2 combinator. I see. Yeah, not awake yet.
14:32:28 <korvo> That said, you're right about what I said in the past. If that's accurate then you're right that Smullyan won't have the answer. Thanks for recalling that; my memory doesn't actually work right, so I don't recall.
14:33:30 <int-e> vista_user: it was a play on words ("if you think about it...")
14:33:46 <vista_user> oh
14:34:07 <vista_user> (im bad at those...blame austim)
14:34:13 <vista_user> *autins
14:34:18 <vista_user> *austinm
14:34:21 <vista_user> *autism
14:34:28 <Yayimhere> wow
14:34:29 <vista_user> finally
14:34:40 <vista_user> (ffs i cant tyep)
14:34:40 <Yayimhere> tbh ive done that a few times
14:34:56 <Yayimhere> *teyp *ytep ect ect
14:35:01 <vista_user> lol
14:35:13 <Yayimhere> is that mean?
14:35:26 <vista_user> in a discord server im in typo got misspelled as tyop 11 times
14:35:34 <vista_user> 8 of them was me
14:35:43 <Yayimhere> ddamn
14:35:48 <Yayimhere> *dammn
14:35:52 <Yayimhere> *daamn
14:35:56 <Yayimhere> *daaaaaaaaamn
14:35:58 <Yayimhere> lol
14:36:02 <vista_user> lol
14:36:14 <Yayimhere> NO!
14:36:17 <Yayimhere> esolangs!
14:36:19 <Yayimhere> lol
14:36:21 <korvo> And that's what typing class is for. It's not fun but it pays off.
14:36:31 <Yayimhere> yes
14:36:50 <vista_user> but im on a *phone* right now
14:37:05 <Yayimhere> im laying in a very bad position for typing right now
14:37:17 <vista_user> (when inmake the mosy typso is when im on a pjone(
14:37:20 <vista_user> )
14:37:29 <vista_user> ) for teh other oen
14:37:32 <Yayimhere> the (() is crazy
14:37:40 <vista_user> i fixde it
14:37:44 <Yayimhere> great
14:37:58 <Yayimhere> (()) there's a language of that name
14:38:16 <vista_user> is ir an alt name for lisp? /j
14:38:54 <korvo> Eventually your backs won't permit that. I'm at a standing desk with an ergonomic-split keyboard and I take breaks to stretch my hands and arms.
14:39:02 <Yayimhere> why is lisp so popular within esolangin'?
14:39:08 <Yayimhere> korvo: yea I know
14:39:27 <vista_user> idk but theres always teh joke thta lisp = ()(())(()())()()
14:39:33 <Yayimhere> lol
14:39:39 <vista_user> even outsidevesolangign
14:40:10 <vista_user> (yes, i took teh time to acytually match the parens!)
14:40:21 <Yayimhere> great!!!!
14:40:24 <korvo> Why think that Lisp is unpopular? A company called ITA used Lisp (SBCL, I think) to revolutionize how airline booking worked; they were acquired by Google, forcing Google to maintain a Lisp application for decades.
14:40:47 <Yayimhere> wow, I didnt know!
14:41:07 <Yayimhere> I think the reason is in danish programming circles rarely use LISP
14:41:25 <korvo> S-expressions are simple. Eventually, after writing many parsers, you will come to appreciate that a Lisp parser takes less than 100 LOC and can be memorized.
14:41:44 <esolangs> [[Talk:(())]] https://esolangs.org/w/index.php?diff=166629&oldid=130205 * Yayimhere2(school) * (+189)
14:41:58 <vista_user> i never said it was complicated, onlynthat it has A LOT of parens
14:42:43 <korvo> Lisp has as many parens as, say, Python. Whenever Lisp writes (f x y), Python writes f(x, y).
14:43:16 <Yayimhere> its a visual thing, I think
14:43:38 <korvo> It just looks like more parens because they pile up at the beginning as well as the end, as in ((f x y) z). But there's still a pileup in Python; f(x, y)(z) has it in the middle of the expression.
14:43:50 <Yayimhere> yes
14:44:38 <vista_user> i also did say it was a common joke
14:44:54 <vista_user> you could say its a common lisp joke!
14:45:13 <vista_user> (im so funny (no im not))
14:45:22 <Yayimhere> (())
14:45:42 <korvo> You're fine. Y'all're still learning about the different possibilities; it hasn't yet clicked that most languages are bad.
14:45:54 <Yayimhere> lol
14:46:39 <korvo> Like, yes, Lisps are bad. But the popular languages that people use all the time are also bad. So why point and laugh at syntax? I think that it's more about social acceptability than what languages actually represent.
14:46:58 <Yayimhere> yes, it Is, infact
14:47:27 <vista_user> i never said it was bad per se. there are objectively shitty languages thpugh
14:47:33 <korvo> C++ and C are bad too, but you'll see enormous numbers of people defending them and their memory-unsafety purely out of selfishness and machismo. You'll hear piles of untruths: C is low-level, C is efficient, C is safe and you're just a bad programmer, etc.
14:47:42 <int-e> korvo: you can use K' = S (S (K K) I) if you want a more faithful simulation
14:47:43 <vista_user> such as malbolge
14:47:51 <Yayimhere> i was about to say
14:48:05 <Yayimhere> uuuuuh, Uncompetition.
14:48:13 <vista_user> (malbolge is intentionally bad)
14:48:31 <int-e> but K' = K I is "good enough" for many purporses because any reduction that uses K' x y -> y can be simulated through K I x y -> I y -> y
14:49:11 <Yayimhere> vista_user: thats why we usually dont mention esolangs in such discussion
14:49:15 -!- Lord_of_Life has quit (Quit: Laa shay'a waqi'un moutlaq bale kouloun moumkine).
14:49:21 <vista_user> ik
14:49:25 <vista_user> but i had to
14:49:26 <int-e> But you do get different normal forms.
14:49:28 <vista_user> for the lulz
14:49:30 -!- sftp has quit (Ping timeout: 245 seconds).
14:49:35 <korvo> int-e: Ha, that's fair. Thanks.
14:50:17 -!- Lord_of_Life has joined.
14:52:33 -!- Yayimhere has quit (Quit: Client closed).
15:01:21 -!- Yayimhere has joined.
15:02:42 -!- vista_user has quit (Remote host closed the connection).
15:06:37 -!- citrons has quit (Ping timeout: 260 seconds).
15:12:11 -!- citrons has joined.
15:18:42 <esolangs> [[UnCompetition]] https://esolangs.org/w/index.php?diff=166630&oldid=166624 * Yayimhere2(school) * (+32) /* Description */
15:31:54 -!- Yayimhere has quit (Quit: Client closed).
15:37:21 <int-e> korvo: why did I make it so complicated? K' = S K works.
15:38:52 <int-e> In any case, it's a very ad-hoc trick; S M x y -> M y (x y) doesn't fit most binary combinators.
15:39:44 -!- Yayimhere has joined.
15:40:45 -!- simcop2387 has joined.
15:42:25 <Yayimhere> ok, i have an idea, and, I want some help to like "try" it
15:42:27 <korvo> int-e: Sure. What's difficult for me is getting any sort of linear or cancellative behavior out of S. K' is technically cancellative, but in a seemingly-useless way.
15:42:46 -!- perlbot has joined.
15:42:49 <b_jonas> int-e: yes, korvo said KI = SK already. but the question is the opposite, whether you can derive K from S and KI
15:43:04 <b_jonas> or possibly from S and KI and I
15:43:46 <korvo> S
15:44:10 <b_jonas> we already know that all combinators can be derived from S and K and we know the general procedure to do it
15:45:13 <korvo> K'S will give I, at least.
15:46:00 <int-e> No; none of these erase their last argument, but K does. Formally, the right-most leaf of any expression is preserved by reductions in {S,KI,I}, so you can't have M x y -> x
15:48:01 <b_jonas> int-e: hmm, so can you do something where there needs to be a dummy last argument, but you can still translate any program?
15:48:18 <int-e> But maybe you can you have M x y z -> x z? That would be sufficient for simulation...
15:48:35 <int-e> (same thought, I was slow to type it out)
15:48:46 <b_jonas> no, it wouldn't be sufficient because you also need some equivalent of S
15:52:18 <int-e> Well, depends on what you want; it would be sufficient for simulating head reductions which is all you need for checking whether a term reduces to, say, K.
15:52:56 <esolangs> [[EXDotSF]] M https://esolangs.org/w/index.php?diff=166631&oldid=96899 * Rudolph4268 * (+1) Fixed a typo in the description for the "?" command
15:53:49 <korvo> int-e: That convinces me. Yayimhere, does that make sense?
15:54:39 <Yayimhere> does what make sense?
15:55:01 <Yayimhere> Int-es latest message+
15:55:02 <Yayimhere> ?
15:55:04 <korvo> The system {S, K'} we discussed earlier is not complete; in particular it doesn't have K.
15:55:41 <Yayimhere> makes sense lol
15:55:43 <Yayimhere> cool!
15:56:08 <korvo> int-e: Further, we might wonder about the left-most leaves. Is there a deeper reason why K and I yield K' but K' and I do not yield K? It might merely be left-to-right evaluation and the ability to extend the context to the right but not to the left.
16:00:09 -!- perlbot has quit (Quit: ZNC 1.9.1+deb2+b3 - https://znc.in).
16:00:09 -!- simcop2387 has quit (Quit: ZNC 1.9.1+deb2+b3 - https://znc.in).
16:00:23 * korvo thinking KI should be named "kite"
16:00:34 <Yayimhere> lol
16:08:27 -!- Yayimhere has quit (Quit: Client closed).
16:09:36 -!- Yayimhere has joined.
16:17:45 -!- shikhin has quit (Quit: Quittin'.).
16:19:22 -!- shikhin has joined.
16:20:31 -!- shikhin has changed hostmask to ~shikhin@offtopia/offtopian.
16:22:05 <esolangs> [[]] https://esolangs.org/w/index.php?diff=166632&oldid=166447 * C++DSUCKER * (+336)
16:23:04 <esolangs> [[]] https://esolangs.org/w/index.php?diff=166633&oldid=166632 * C++DSUCKER * (+8)
16:24:16 <esolangs> [[]] https://esolangs.org/w/index.php?diff=166634&oldid=166633 * C++DSUCKER * (+0)
16:24:26 -!- simcop2387 has joined.
16:24:30 <esolangs> [[]] https://esolangs.org/w/index.php?diff=166635&oldid=166634 * C++DSUCKER * (+1)
16:26:16 <esolangs> [[]] M https://esolangs.org/w/index.php?diff=166636&oldid=166635 * C++DSUCKER * (+2) /* Example: solve Erds-Straus conjecture */ big header -> small header
16:32:30 -!- perlbot has joined.
17:02:26 -!- perlbot has quit (Quit: ZNC 1.9.1+deb2+b3 - https://znc.in).
17:02:26 -!- simcop2387 has quit (Quit: ZNC 1.9.1+deb2+b3 - https://znc.in).
17:12:14 <esolangs> [[Gilbert Leo Thulani]] N https://esolangs.org/w/index.php?oldid=166637 * Yayimhere2(school) * (+1151) Created page with "Gilbert Leo Thulani, known on the esolang wiki as [[User:Yayimhere]], is an esolanger, and a musician, and makes a lot of art in general. this is some info about her/them/him(...NO!) == Programming specific interests == here's some things I like l
17:13:11 <korvo> Yayimhere: Wrong namespace. Also, please pick one account and stick to it.
17:13:36 <Yayimhere> ?
17:13:54 <Yayimhere> what
17:14:20 <Yayimhere> (also this is not a new account, just some more in depth info on me as a person/creator of esolangs)
17:17:02 <korvo> What you wrote is appropriate for the user namespace but not the main namespace. Pages in [[:category:people]] are usually more subdued; see [[John Horton Conway]], [[Edwin Brady]], [[Gabriella Gonzalez]], or [[Ward Cunningham]] for examples.
17:17:17 <Yayimhere> oooh ok
17:17:19 <Yayimhere> sorryyyyy
17:17:44 <esolangs> [[Gilbert Leo Thulani]] https://esolangs.org/w/index.php?diff=166638&oldid=166637 * Yayimhere2(school) * (-1151) Blanked the page
17:17:45 <esolangs> [[Talk:Crypten]] https://esolangs.org/w/index.php?diff=166639&oldid=166627 * * (+274)
17:17:48 <korvo> While I'm not a deletionist, I do struggle to think of notable work that you've produced. Please recall, from only a few months ago, that we generally expect folks at your age to be *learning* rather than *producing*.
17:19:13 <esolangs> [[User:RaiseAfloppaFan3925]] M https://esolangs.org/w/index.php?diff=166640&oldid=166593 * RaiseAfloppaFan3925 * (-5503) mite kure no kijaku sei ei e
17:20:20 <esolangs> [[Talk:UnCompetition]] N https://esolangs.org/w/index.php?oldid=166641 * * (+170) Created page with "===A question=== Wouldn't <code>~{''x''}</code> force the existence of command ''x'' in the program? -~~~~"
17:21:20 <strerror> The S(KI)I calculus :-)
17:25:42 <strerror> I still feel it's TC because Sxyz shuffles y and z, though it would end up being messy because you can't clean up the trailing subterms
17:25:42 <korvo> Yayimhere: In general, we do have a written policy about this; please read it. https://esolangs.org/wiki/Esolang:Authors
17:27:33 -!- Yayimhere has quit (Ping timeout: 250 seconds).
17:28:44 <strerror> .oO( Of course the real problem isn't anyone's age, just that it's no longer 1993 and the bar is much higher for what makes an interesting language )
17:29:22 <strerror> Maybe the only way now is to invent them by accident, like what just happened
17:30:57 <korvo> Well, that doesn't quite track. Yay's produced quite a bit of garbage by putting a "lol xd random" spin on anything that they hear about. I understand why it happens, and I was once that age too; but I also recognize that I was very pretentious and had no idea what I was talking about, even as I was doing basic programming.
17:31:19 <esolangs> [[WtE,teplw! but actually usable]] https://esolangs.org/w/index.php?diff=166642&oldid=165390 * * (+567)
17:31:36 <korvo> It's not much different from how learning a language does not make one a linguist. (Sorry Whorf, but strong Sapir-Whorf is bogus; learning Lojban does not make one a logician!)
18:11:19 -!- Yayimhere has joined.
18:11:31 <Yayimhere> korvo: i sturggle to infer(?) what you mean by noteable
18:12:44 <korvo> Yayimhere: Like, work which is known on its own for its own merits. Work that people know about before they know its author.
18:13:41 <Yayimhere> korvo: yea no I dont have any, but thats a popularity thing, to some extent
18:14:22 <Yayimhere> and for the learning not producing thing, the only reason I make esolangs is cuz I find it fun to work on. nothing else really
18:14:54 <korvo> Yayimhere: I don't have any notable work either. Don't worry about it. The point is that an author page in the main namespace is helpful because it lists notable works; if somebody discovers an author via one route, then they should be able to discover related work by the same author.
18:15:17 <Yayimhere> korvo: yea, I get it!!!
18:16:15 <Yayimhere> thanks for info:]
18:19:23 <esolangs> [[User:Yayimhere/an esolang for my puter]] https://esolangs.org/w/index.php?diff=166643&oldid=151859 * Yayimhere2(school) * (+114)
18:23:42 -!- Yayimhere has quit (Quit: Client closed).
18:26:29 <esolangs> [[User:Yayimhere/an esolang for my puter]] https://esolangs.org/w/index.php?diff=166644&oldid=166643 * Yayimhere2(school) * (+88) /* thoughts for lang creation */
18:28:48 <esolangs> [[User:Yayimhere/an esolang for my puter]] https://esolangs.org/w/index.php?diff=166645&oldid=166644 * Yayimhere2(school) * (+49) /* thoughts for lang creation */
18:30:15 <esolangs> [[-hacker]] https://esolangs.org/w/index.php?diff=166646&oldid=166169 * Ivava * (+45)
18:39:11 <esolangs> [[User:Yayimhere/Sandbox/]] N https://esolangs.org/w/index.php?oldid=166647 * Yayimhere2(school) * (+57) Created page with "this is me, trying to prove TC!!! seems feasible lol."
18:40:03 <esolangs> [[User:Yayimhere/Sandbox]] https://esolangs.org/w/index.php?diff=166648&oldid=166566 * Yayimhere2(school) * (+38)
18:46:55 <esolangs> [[User:Yayimhere/Sandbox]] https://esolangs.org/w/index.php?diff=166649&oldid=166648 * Yayimhere2(school) * (+4) /* */
18:50:37 <b_jonas> korvo: but isn't "kite" used for some other bird already?
18:56:22 <esolangs> [[User:RaiseAfloppaFan3925/Sandbox]] M https://esolangs.org/w/index.php?diff=166650&oldid=159591 * RaiseAfloppaFan3925 * (+2485) TETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETOTETO
19:03:36 <korvo> b_jonas: It doesn't seem like it. Additionally, Smullyan's character says of their Church encoding, "For t, I take the kestrel K; for f, I take the bird KI." This is in the middle of one of two sections that has multiple uses of KI.
19:05:21 <korvo> The section on arithmetic notes that V(KI) is useful, but focuses on the vireo V.
19:11:34 <esolangs> [[Combinatory logic]] https://esolangs.org/w/index.php?diff=166651&oldid=164969 * Corbin * (+167) /* Table of combinators */ Add two variations on S given by Smullyan.
19:12:00 <korvo> I did find two birds, phoenix and psi bird, in the nearby notes. So I do appreciate being sent back to the book.
19:13:43 -!- perlbot has joined.
19:15:48 -!- simcop2387 has joined.
19:18:52 <Sgeo> Well I have an idea for an esolang, somewhat boring though. Brainfuck with I/O altered to make more sense in a mainframe context.
19:19:31 <esolangs> [[User:Yayimhere/Sandbox/]] https://esolangs.org/w/index.php?diff=166652&oldid=166647 * Yayimhere2(school) * (+589)
19:19:32 <Sgeo> Easiest thing to do would be to have , bring in 80 characters across 80 cells
19:19:55 <Sgeo> And . would.. hmm, not sure if 80 or 133 makes more sense. (Punch vs print)
19:29:36 <APic> Good Night *
19:31:00 -!- ais523 has joined.
19:35:26 <esolangs> [[Combinatory logic]] M https://esolangs.org/w/index.php?diff=166653&oldid=166651 * Corbin * (+0) /* Table of combinators */ Alphabetize Greek letters.
19:40:16 <ais523> <korvo> And that's what typing class is for. It's not fun but it pays off. ← I was technically formally trained in touch-typing, but I invented ending up inventing my own style which is very different from the one that's normally taught
19:40:50 <ais523> I don't keep my hands in a consistent position, I move them based on what I'm subconsciously anticipating that I'll need to type next
19:41:20 <korvo> ais523: I have a pile of quirks from playing too much piano. The worst thing I do is Shift with the same hand that I'm keying rather than alternating.
19:41:22 <ais523> it is extremely fast compared to normal typing styles, but also has a somewhat higher error rate, so it only makes sense in situations where backspace is cheap/free (which wasn't true when typing was invented, but usually is nowadays)
19:42:22 <ais523> hmm, I experimented, and discovered that I was using the left shift key for all my shifting needs
19:42:53 <ais523> there are exceptions, like typing $ or %, so I don't use the left shift key for absolutely everything, just most of it
19:42:56 <int-e> how else would you sprint in video games ;)
19:45:29 <ais523> on the subject of Lisp syntax – I think the primary issue with s-expressions and the parenthesis pileup is that a long row of grouping characters makes it harder for humans to mentally find the start and end of the groups, than if the grouping characters were less clumped up
19:45:57 <ais523> but this isn't really an essential issue because you could change Lisp to use m-expressions instead and nothing would really change (it was originally designed to use m-expressions, IIRC)
19:46:29 * Sgeo wonders how Rhombus is going
19:48:07 <ais523> I guess my main real concern with Lisp is that I prefer non-scripting languages to be statically typed, but if you add static types to Lisp it gets rid of a lot of the theoretical elegance
19:48:10 <korvo> Empirically, the ]]] do pile up in M-expression languages like Wolfram. And the ))) pile up in Python too. Really, the issue is that we use a 1D grammar for trees that aren't 1D.
19:49:11 <ais523> korvo: right, most serious programming languages nowadays have some sort of piping operator in order to resolve the most common case of that, but Lisp and Mathematica are both too old (actually Mathematica probably has one that isn't widely used)
19:49:34 <korvo> ...What *is* the Hausdorff dimension of a B-tree? This seems like something I should have seen before, but I don't know it offhand.
19:50:39 <ais523> in many cases this uses "method notation", piping with ., i.e. (add 1 (mul 2 (add 3 4))) becomes 4.add(3).mul(2).add(1)
19:50:57 <ais523> although, that transform swaps argument order, so ideally you'd also have a version that reverses argument order
19:51:15 <ais523> functional languages also tend to have an operator for that but it usually has a different name; |> seems popular at the moment
19:52:13 <ais523> and of course pointfree programming is naturally full of transformations like that – you rarely get a parenthesis pileup in Haskell, for example
19:53:29 <ais523> (now I just realised that a significant proportion of Rust's non-borrow-related syntactic sugar is designed around avoiding the need to nest a lot of {})
19:54:10 <ais523> in a way this is a rejection of the Lisp philosophy – inventing special-cased syntax to avoid needing to nest the program too much is basically the opposite of what Lisp is about, because it makes introspection difficult
19:55:08 <ais523> hmm, and thinking about it, there's also the Prolog style: add(3, 4, A), mul(2, A, B), add(1, B, C)
19:55:45 <ais523> despite being based on m-expressions, Prolog is almost completely immune to excessive nesting / rightward drift because it doesn't natively support nested predicate invocations, you have to manually sequence them
19:55:59 <ais523> but I'm not sure that the tradeoff that Prolog specifically makes is worth it
19:56:19 <korvo> I'm not exactly sure who started it, but by the 1970s the let-in style from maths seems to have become popular: let x = ... in f(x)
19:56:25 <ais523> (Prolog's syntax is regular enough and introspectable enough to make it possible to write Lisp-style macros in it, but in practice people don't bother)
19:56:51 <korvo> Execline forces this sort of un-nesting because it doesn't support $() inline shell. Instead we write: backtick -E x { ... } f $x
19:57:06 <ais523> korvo: let…in style sort-of naturally falls out of the formalizations of this sort of language, it probably started with someone trying to translate a paper about a language to a concrete implementation
19:57:53 <ais523> because the formalizations want the scope of a variable to be syntactically visible and properly nested, both the start and the end
19:58:36 <korvo> Also because left-to-right is a special reading order. In another buffer, the following execline: importas -iS V backtick -E exe { ${V}/call: $1 exe } $exe --add-fixed --recursive sha256 $2
19:58:40 <ais523> C89's { int a; float b; /* code */ } also achieves that goal (by treating it as sugar for { int a; { float b; /* code */ } }), but it's a less obvious approach from the theory (and C++ and C99 endd up changing it)
19:59:58 <korvo> execlineb and friends all start at the left and pop a fixed number of args, then exec() onto the rest of the args. Kind of like a stack, but usually not pushing, just popping. Substitutions are done by rewriting args; there's no substitution from envp, only from argv.
20:01:08 <ais523> korvo: I was going to say it's kind-of like a queue without enqueuing
20:01:17 <ais523> maybe I've been doing too much tag system programming
20:01:43 <ais523> in most languages that have that general style (e.g. Underload), there is a way to push onto the left-hand side (and this is used to implement loops)
20:01:54 <korvo> ais523: You're on the same page. Execline's author explicitly thinks of argv as something that can be reused and exec() is merely a way to load fresh code onto a single argv under consideration.
20:02:12 <ais523> I expect execline to have one too
20:02:54 <esolangs> [[Special:Log/delete]] delete * Ais523 * deleted "[[Gilbert Leo Thulani]]": blanked by author shortly after creation
20:02:55 <korvo> In Vixen terms, a single method activation only has a single process in memory; every exec() is temporarily activating a new method in the existing environment.
20:03:36 <ais523> korvo: I don't really see the one process versus multiple process thing as being a defining feature of shellscript/execline
20:04:12 <ais523> in a way, shellscript is "better isolated" because you know that commands you run are unlikely to do anything to the rest of the script, whereas an execline command could make arbitrary changes to the trailing arguments
20:05:42 <ais523> but in practice execline is only being used with commands specifically designed for it
20:06:40 <ais523> and "external" commands are called using backtick and the like
20:09:26 <korvo> ais523: Sure. I think that the efficiency is more relevant; by not having to spawn any bashes, I can send multiple messages per second. I still haven't figured out exactly what kind of security model can work on top of this, but it will probably involve having some sort of privileged representation for paths.
20:11:17 <ais523> my reaction to execline is pretty much along the lines of "the execline author's criticisms of sh are valid, but they would be addressed by changing to pretty much any programming language that's statically parsed, and there isn't a clear explanation of why execline uses the particular approach it does"
20:11:43 <ais523> especially because execline isn't actually statically parsed, you have to rely on all the commands to follow the parsing conventions to make it work
20:13:03 <ais523> also, tail-exec is a bizarre way to implement a state machine, most languages have more efficient ways to implement them than that
20:13:52 <korvo> Oh, execline is purpose-built for s6, which is a fork of daemontools. One of the things I'm going to explore is how s6 service directories can be treated as Vixen objects, hopefully.
20:16:37 <ais523> it looks like execline's design was intended to keep the interpreter out of memory, in the belief that that would make things more efficient
20:17:15 <korvo> Still thinking about what you said about loops. Execline just doesn't have a stateful while-loop; not even envp is writable by the looped process. I ended up writing the one while-loop as a recursive call, which is actually pretty neat since it's for recursive parent lookup, but it is kind of a difficult limitation.
20:17:38 <ais523> but actually that just means that every execline command has to redo some of the interpreter steps (such as parsing blocks out of argv)
20:18:31 <ais523> oh, I expected execline loops to work as in Underload, along the lines of "check a condition; if the condition is true, insert the content of a block at the start of the original argv (without removing this command or its arguments); if the condition is false, skip the block"
20:19:19 <ais523> it looks like loopwhilex doesn't quite work like that
20:20:26 <ais523> but the intuition is of an infinitely repeated program part, followed by a goto, i.e. while a {b} c can be thought of as meaning "unless a {goto label} b unless a {goto label} b unless a {goto label} b … label c"
20:20:39 <ais523> and then you can use the language's normal mechanisms for maintaining state
20:21:41 <ais523> (I don't think execline has a forward goto either, but it wouldn't be conceptually hard to add one to the programming model – backwards goto is of course incompatible)
20:21:44 -!- lynndotpy609 has quit (Quit: bye bye).
20:22:59 -!- lynndotpy609 has joined.
20:23:03 <korvo> Yeah. TBH I don't think I'm going to need any state in these little scripts. State would be useful for doing something big and orchestrated, but I might as well just write in Python or another non-shell language for that.
20:23:29 <ais523> right, my other real concern about execline was "why not just use a scripting language that isn't shellscript"
20:23:31 <korvo> I do think that it's an obstacle for saying that we can replace all bash with execline. Execline can't replace 2000 lines of well-factored functions.
20:23:38 <ais523> although I think the answer to that would be "because the executables are big and complicated"
20:24:01 <esolangs> [[Mango]] M https://esolangs.org/w/index.php?diff=166654&oldid=166592 * RaiseAfloppaFan3925 * (-1729) removed stupid thing
20:24:20 <ais523> and so the followup would be "why not write a scripting language that's a proper programming language but is small and simple?"
20:24:41 <ais523> there's probably "market" pressure against doing that (i.e. few people think they need it), but it is something that would be useful
20:25:51 <ais523> I have considered writing my own Perl derivative with substantially fewer features (with the tradeoff being that it runs much faster)
20:26:17 <ais523> and a more consistent / less scary-looking syntax
20:27:40 <korvo> That's the beauty of Smalltix. The methods can be anything with a +x permission bit. Symlinks work fine. The overall idea is to *defragment* the Unix system with a uniform interface.
20:27:44 <ais523> I would probably get rid of the sigils because a) they're the sort of thing that scare people off, b) the way Perl uses them is not really a good match for how programming in Perl actually works, and c) A Pear Tree looks really nice
20:28:42 <ais523> korvo: Smalltix is sort of the opposite of what I want, though – I want a single executable which parses the script, possibly does a very fast compilation step, and then runs it itself
20:30:57 <ais523> I guess I'm looking at the Unix philosophy of having lots of small tools that each do one job well, then saying "why do these each have to be separate executables?"
20:31:14 <esolangs> [[User:RaiseAfloppaFan3925]] M https://esolangs.org/w/index.php?diff=166655&oldid=166640 * RaiseAfloppaFan3925 * (+858) travel back in time and retrieve the first sent message
20:36:26 <korvo> ais523: Sure. That's the batch-processing POV. It makes sense for plenty of workloads. Smalltix is more like a spreadsheet or video game; it's interactive and programmed from the inside.
20:36:58 <ais523> korvo: oh, I see, you want to be able to change a running program (like you can in Smalltalk)
20:37:55 <ais523> oddly enough, what I wanted for my Perl derivative was similar but a bit different – I wanted to be able to see a program's variables at any point in its execution, and edit the program without losing the work it had already done
20:38:26 <ais523> but I wasn't thinking of it as live-editing a program, because I wanted to end up with a reproducible script that could be used to do the same job again in the future
20:38:33 <korvo> Yeah. As a sysadmin, I want my machine to be a holistic system that doesn't have any hidden or opaque parts. In Jakubovich's framing, that means no binaries; in Kell's framing, that means no custom memory allocators. But I'm not being dogmatic; instead I'm imagining a human process which refines a system as it runs to make it object-oriented without discarding any working binary.
20:38:38 <ais523> if you live-edit a program you can end up with a result that couldn't be produced by the final version of the program
20:39:30 <ais523> I guess this is the equivalent of incremental compilation, except for running the program, so I'd call it "incremental execution"
20:39:49 <korvo> As a Perl hacker, do you know the story of atmospheric programming? It seems to no longer be online.
20:39:55 <ais523> I don't
20:40:46 <b_jonas> ais523: but lisp has user-definable macros, so it is about inventing whatever special-cased syntax you want
20:40:53 <korvo> A one-person consultancy had an utterly cracked way of programming. Each client got a fork of the main code, each fork had all variables as globals, and each query was "atmospheric": it pulled globals into the DB queries as needed to satisfy the client's requests.
20:41:04 <ais523> b_jonas: yes, but people normally don't use it for that
20:41:07 <korvo> No version control, IIRC. Lots of security issues.
20:41:27 <b_jonas> plus lisp has first-class functions, which makes it more likely that you can express such things even without macros
20:41:34 <b_jonas> it even has inline lambdas
20:41:48 <ais523> korvo: heh, reminds me a lot of INTERCAL (and CLC-INTERCAL in particluar, which doesn't quite work like that but feels like it's evolving in that direction)
20:43:14 <ais523> although I originally misinterpreted it as the DB being shared between all customers
20:43:19 <korvo> Found it: https://perlhacks.com/2012/03/you-must-hate-version-control-systems/ He's still going! https://www.perl.com/article/my-guilty-perl-obsession/
20:43:26 <b_jonas> on the more esoteric side, Enchain or other languages with similar syntax are technically a way to avoid the pileup of parenthesis, though not a practical way because the cure is worse than the original symptoms
20:43:51 <b_jonas> but it's at least something we should examine, even if to find out that it's not worth
20:44:01 <korvo> "The side you don’t know is that pipelines is what I’ve coined “atmospheric programming”, which is going to take some describing. If you imagine the difference between an object-oriented fully scoped world, and a flat file where everything is a global variable, sming the pendulum all the way further. Not only is everything global, but everything’s structured to be accessed from everywhere."
20:45:52 <b_jonas> wait what? are the sigils really what used to scare people off perl? I don't think that's true.
20:46:54 <b_jonas> "and edit the program without losing the work it had already done" => the hard part is how to combine that with lambda closures. I was thinkign about that recently.
20:47:00 <ais523> b_jonas: I don't think they're the main thing, but they are the main thing that's visible in simple programs
20:47:29 <esolangs> [[Mango]] M https://esolangs.org/w/index.php?diff=166656&oldid=166654 * RaiseAfloppaFan3925 * (+90) Added my implementation (still a stub implementation)
20:47:42 <ais523> I've done enough A Pear Tree programming to realise just how different the programs look if you remove the dollar signs
20:48:18 <ais523> (A Pear Tree still requires you to use $ sigils on variables in cases that would otherwise be ambiguous, but you can omit them in simple cases)
20:49:04 <b_jonas> wait, that's a different A Pear Tree than I was thinking of
20:49:04 <korvo> Doesn't Perl 5 require the sigils to specify how the variable is loaded from storage? Or is it just an affectation inherited from awk?
20:49:18 <ais523> and in simple programs, as long as you do flow control entirely using eval rather than more sensible ways, it polyglots pretty well with Python
20:49:22 <b_jonas> are there two languages with a similar name?
20:49:43 <b_jonas> no, it's the same Pear Tree, it just does multiple apparently unrelated changes to perl
20:49:56 <ais523> korvo: so Perl sigils specify what type the variable has, where there are three types: scalars, arrays, and maps (which Perl calls hashes)
20:50:39 <ais523> but, Perl has both arrays and array references, and an array reference is a type of scalar
20:51:43 <ais523> and array references are generally much more useful than arrays, and also you don't need an existing array to create them (you can just allocate them at will), so a common Perl programming style uses only array references and map references, rather than array-typed and map-typed variables
20:52:15 <ais523> this means that despite multiple sigils existing, $ (scalar) is overwhelmingly the most commonly used one, and the others are, whilst not actually deprecated, mostly unused nowadays
20:52:34 <korvo> Right, I recall code doing lots of $(this)->meth(); sorts of shapes.
20:53:51 <korvo> I haven't ported Smalltalk or Self to Vixen. I just don't like the syntax enough. I think Self makes a lot of sense at a REPL but not as an orchestration language on disk.
20:54:10 <ais523> a Perl object is implemented as a pair of a package (basically the equivalent of a class) and a place to store the object's data
20:54:29 <ais523> and the place to store the data has to be a scalar, in practice it's usually a map reference, and usually an array reference if it isn't a map reference
20:54:47 <ais523> which means that Perl objects are exclusively accessed using $, the other sigils wouldn't work for them
20:54:59 <b_jonas> "and also you don't need an existing array to create them" => that's a great way to make the sort of mistake where your program seem to work well but later dies when an array happens to be empty. I've made such errors without perl, but I think if you try to program perl in the style that you suggest they'll be more likely.
20:55:10 <ais523> (that said, for my "simple incremental execution Perl" I don't think I'd support objects)
20:55:51 <ais523> b_jonas: well this style usually creates arrays with […] and hashes/maps with {…}, those don't die when the array is empty
20:56:01 <b_jonas> ais523: and now we might have to qualify that statement because more recent perl is adding some different kind of OO as well
20:56:30 <korvo> ais523: Curious, yet another fat-pointer language.
20:56:39 <b_jonas> ais523: oh, I was thinking you'd just { push @$x, $y; } inside a loop without initializing $x
20:56:50 <ais523> korvo: that's a good way to think about it, but Perl pointers are stupidly fat even without that
20:58:19 <b_jonas> ais523: or, and this is the way I encountered the bug in non-perl, you { push @{$x{$z}}, $y; } inside a loop, then later try to use @{$x{$z}} which fails if you never pushed with that particular $z
20:58:49 <ais523> b_jonas: now I'm wondering how hard it would be to just simply make that case work
20:59:13 <ais523> it might be as simple as "indexing undef returns undef"?
20:59:23 <korvo> ais523: Oh, I don't mean it to be a bad thing. Or maybe it's a dialect thing; in USA lingo, we would say that a pointer is not "stupidly fat" but "dummy thicc". But to me a fat pointer is just a pair (script, closure) or (behavior, locals) or (class, attributes) or (vtable, struct) or...
20:59:56 <ais523> korvo: I wasn't taking you as implying it was a bad thing
21:00:04 <korvo> And it seems like they're key to so many languages. D, Go, and Rust all rely on fat-pointer strings. Cello calls itself "a fat-pointer library".
21:00:09 <ais523> I was just thinking that it was the obvious approach for Perl because pointers stored so much data there already
21:00:15 <b_jonas> ais523: it's kind of a tradeoff. perl is already making undef semi-silently work as a number or string. you can make it work as a ref to an empty array too, but eventually you'll get more bugs where something is accidentally uninitialized and you don't notice because perl doesn't warn you than how much bugs you have now from where you meant somethign to be an array ref but perl didn't allow it
21:00:56 <ais523> arithmetic on undef gives a warning, right? which in simple programs is IME usually a false positive
21:01:11 <b_jonas> usually yes, but there are some exceptions
21:02:01 <b_jonas> in particular you can { $x += $z; } in a loop, then use $x, and if the addition never ran then you get a false warning
21:02:15 <ais523> I guess there's also the extreme approach of unifying all the types (which is the thing I like about old versions of Perl)
21:02:32 <ais523> it's easy enough to see how an array and a map could be the same type (Lua does that)
21:02:50 <ais523> and it's also easy to see how an array and string could be the same type (a string could be an array of character codes)
21:03:19 <ais523> with this approach, undef would be an empty string, which logically seems reasonable
21:03:57 <ais523> automatic coercions would be very weird, though, you'd get things like "abc"[1][1] == 8
21:04:10 -!- tromp has quit (Quit: My iMac has gone to sleep. ZZZzzz…).
21:04:22 <b_jonas> some of that wouldn't be compatible with existing perl
21:04:32 <ais523> I know, I'm not trying to be compatible, just inspired
21:05:17 <ais523> I think this unify-everything approach would make sense for a golfing language but not so much for practical use
21:06:06 <ais523> undef as "" might make sense practically, but also might be a big mistake (it reminds me a lot of Go's zero values which I think are probably a mistake)
21:06:25 <korvo> Well, there are two fairly popular systems that have "everything is a char" and "everything is an octet" respectively, but I get what you're saying: it's not maintainable to only deal in bytes.
21:06:53 <ais523> that said, the "exists" operation seems wrong, it's needlessly confusing to have both "undefined" and "nonexistent" as possible map values
21:07:21 <ais523> so I think the language should at least get rid of one of those options, and I'm not sure which one makes more sense to remove
21:07:51 <b_jonas> now that I've been writing programs in a dynamical language in a way where I want them to be maintainable for years, I want types *less* unified rather than more, in order to detect mistakes earlier
21:08:01 <b_jonas> even with dynamic typing I lean that way
21:08:02 <ais523> (when I want to implement a set in current Perl, I normally do it – for efficiency reasons – as a map where a nonexistent value means not included, and an undefined value means included – but this is really confusing in the code)
21:08:36 <ais523> b_jonas: so I really like the approach of strings and integers being treated as the same type and changing based on the operator you use
21:09:03 <ais523> I think this is better than the Python/JS approach of tracking what type is used for the value and having the operators act differently according to it
21:09:32 <ais523> but I also think it's probably correct to error if the operator doesn't match the data being stored
21:09:35 <b_jonas> Lua does that, it doesn't distinguish between a key that's not in a table and a key where the associated value is nil. So do Factorio circuit network by the way, no difference between no value or zero value.
21:09:57 <ais523> e.g. I am happy with "123" + "456" = 579, but not "123a" + "456" = 579
21:10:52 <ais523> ooh, perhaps the correct approach is to treat undef, empty array, and empty map as all equivalent, but make them different once you start storing data in them
21:11:18 <b_jonas> ais523: there could be a middle option where you can format a number to a string implicitly (useful to quickly print numbers for debugging) but you need an explicit conversion to parse a string as a number
21:11:36 <ais523> b_jonas: well Perl is often dealing with numbers read from files or pipes
21:11:59 <ais523> I definitely don't want the program to silently change additions into concatenations because I forgot to change one of those from a string to a number
21:12:14 <ais523> and for scripting uses, I don't really want to explicitly cast either
21:12:50 <ais523> but perhaps the approach would be to add, e.g., a way to regex capture as an integer
21:13:10 <b_jonas> yeah, that would make sense
21:13:15 <ais523> thus forcing the parsing step to exist (and even making it statically checkable), but reducing the syntactic overhead
21:14:29 <b_jonas> there's probably a place for everything, I'm just leaning to more explicitness because of what programs I've had to maintain recently.
21:14:41 <b_jonas> they involve a lot of reading and writing text files.
21:14:46 <ais523> the ideal is lightweight explicitness which happens even without you doing anything
21:14:53 <ais523> type inference is a good example of that
21:15:36 <ais523> now I'm wondering whether Perl with type inference is even possible, or whether it encounters heterogenous data too often
21:18:32 <ais523> you would probably need two types of map, a tuplish one where the set of keys were fixed and each key could have a different value type, and one where all the values had the same type but the keys could be arbitrary
21:18:35 <ais523> (and likewise for arrays)
21:31:48 <zzo38> I think that sigils are helpful in some programming languages, for several purposes such as avoiding conflicting with keywords
21:33:32 <korvo> I liked Neighbors' convention for META II: the keywords all start with a sigil! In their case, it was '.' which led to me thinking of the keywords as methods/attributes of some builtin object with an empty name "".
21:34:04 <b_jonas> zzo38: Enchain will use what I think counts as sigils, % and & , to denote that you're defining a function instead of calling it
21:34:19 <b_jonas> they're still sigils if they go *after* the name, right?
21:36:06 <zzo38> I would say it is still sigils whether it is before or after
21:36:49 <b_jonas> ok, then these are sigils because you have to write them immediately after the function name, you can't put whitespace between them because that changes the meaning
21:36:59 <ais523> korvo: in Algol-68, ". before keywords" is the portable convention for how you write keywords
21:37:31 <ais523> which is used to solve the bootstrapping problem of "how can I tell the compiler how I want to write keywords, without knowing what the keyword syntax is"
21:38:06 <ais523> that said I don't think modern Algol-68 implementations actually follow that rule, but maybe they do
21:38:13 <b_jonas> doesn't fortran use dots to write numeric compare operators?
21:38:22 <b_jonas> some dialects at least
21:38:31 <b_jonas> I may be confusing fortran with something else
21:38:39 <ais523> (the other two rules you can use are "keywords in uppercase" and "any sequence of letters that could be a keyword is" – the latter was combined with an underscore sigil to unkeywordise things)
21:39:10 <ais523> I'm also wondering whether the latter invented the use of underscore to replace spaces in variable names
21:39:13 <ais523> or whether that's older
21:39:21 <ais523> b_jonas: .GT. and the like, I think
21:39:25 <b_jonas> "any sequence of letters that could be a keyword is" => how many two-letter keywords are there?
21:39:28 <ais523> but that has dots at the start and end, rather than just the start
21:39:30 <korvo> ais523: TIL! That makes a lot of sense as far as history.
21:39:49 <zzo38> There is "if" and "do" in C are keywords with two letters, as well as many longer keywords
21:39:55 <ais523> b_jonas: I think "if" is a keyword, I'm not sure about "of", I can't immediately think of any others offhand but there probably are some
21:40:16 <ais523> I haven't looked at Algol-68 for a while
21:41:04 <zzo38> In some programming language, does have "of", "in", "to", and "on" also as keywords
21:41:08 <ais523> korvo: https://en.wikipedia.org/wiki/Stropping_(syntax)
21:41:12 <zzo38> (I don't know about ALgol specifically)
21:41:24 -!- strerror_r has joined.
21:41:56 <ais523> huh, this article suggests that the reason that prefix . was used was so that it would work in 6-bit character sets
21:42:12 <ais523> which I didn't know but makes sense
21:42:15 <b_jonas> once you have a large portion of `do if or is no in to of by as on at` as keywords, it starts to get hard to invent good variable names
21:42:29 -!- strerror has quit (Ping timeout: 260 seconds).
21:43:26 <b_jonas> the one I usually ran into is trying to use `if` for an input file handle and `of` (or `log`) for an output file handle
21:45:08 <ais523> b_jonas: I've accidentally used `i8` as a variable name in Rust in the past
21:45:22 <ais523> this is the only time where variable names and type names being in different namespaces has actually been useful
21:45:38 <b_jonas> ais523: oh, the one that really bit me is `j0` as a function name in C.
21:45:52 <ais523> (that said, IMO Rust should have used titlecase names for its primitive types so that variable name / type name clashes couldn't happen in program that used normal capitalisation style)
21:46:09 <b_jonas> ais523: they should have called that 8i though, or else should have made it a normal identifier rather than a keyword
21:46:17 <ais523> NetHack has a clash with the standard library on "yn" I think
21:46:29 <ais523> (and with C++ keywords on "class")
21:47:15 <zzo38> Some of my C programs also use "class" as the name of a variable or a field of a structure, but it is not C++ so it is OK
21:48:35 <ais523> C keywords actually mostly hit the sweet spot of being clear whilst being unlikely to be a variable name
21:48:51 <ais523> especially "struct" and "enum", those are really good keywords
21:49:17 <ais523> some are not so good, like "long"
21:49:38 <ais523> this implies that maybe truncated words are a good choice for keywords
21:53:47 -!- tromp has joined.
21:57:30 <b_jonas> it's not just the casing that's wrong. whether it's called i8 or I8, it should be an ordinary namespaced name in the prelude that you can shadow, not a keyword. theres' no reason why it should be a keyword. they learned the wrong lesson from C or C++ there. same for true and false, those should be ordinary enum constructors.
21:57:41 <ais523> b_jonas: it isn't a keyword
21:57:57 <b_jonas> why isn't it namespaced then?
21:58:06 <b_jonas> is it like a weak keyword?
21:59:05 <ais523> Rust normally uses prelude imports for that sort of thing (i.e. your program has an implicit «use core::option::Option as Option;» as the start) but I'm not sure whether it does that for primitives
22:00:17 <b_jonas> https://doc.rust-lang.org/nightly/std/prelude/index.html should list all the names of the prelude. Option is there; i8 isn't
22:00:43 <b_jonas> so if i8 isn't a (possibly weak) keyword then I don't know what it is
22:00:58 <ais523> it could just be an identifier in the global scope, I guess
22:02:58 <ais523> b_jonas: it definitely isn't a keyword: https://play.rust-lang.org/?version=stable&mode=debug&edition=2024&gist=1a97b4fab7c45582af9a27e3d2d44ff0
22:03:21 -!- tromp has quit (Quit: My iMac has gone to sleep. ZZZzzz…).
22:03:24 <ais523> (the «r#» prefix is how you create an identifier with the same name as a keyword, that isn'ta keyword)
22:07:34 <b_jonas> ais523: I don't think it's in the global scope, firstly because there are only crates there, secondly because you can't call it ::u8
22:08:11 <ais523> maybe it's just a special case that's inconsistent with the rest of the language, then
22:08:12 <b_jonas> it seems as if it's imported into every namespace as if it were in the prelude
22:08:33 <b_jonas> but can be shadowed like anything in the prelude
22:08:35 <zzo38> I think would be better to have sigils indicating stuff that is not keywords, or use other signs or formatting indicating if it is or not keywords, or to not have reserved words even if they are keywords, depending on the use
22:08:44 <b_jonas> because it's imported as if it were a wildcard import
22:10:40 <zzo38> (I think LLVM uses sigils to indicate stuff other than keywords)
22:11:30 <ais523> I like register sigils in asm because they avoid the problem of a variable and register having the same name
22:12:02 <ais523> especially because new registers get introduced over time, e.g. if I had a variable named zmm0, that would have been fine on old assemblers but might break on newer ones
22:12:06 -!- Sgeo_ has joined.
22:14:55 -!- Sgeo has quit (Ping timeout: 240 seconds).
22:18:21 <sorear> the explanation that was current when I was active was "you know what would make a programming language easier to learn? case and gender"
22:20:03 <ais523> sorear: was that intended sincerely or sarcastically? I know that many people find learning word gender to be one of the hardest parts of learning languages that have it, because it's basically just an extra boolean you have to memorise along with every word
22:20:25 <ais523> at least case has simplifying aspects in addition to complicating aspects
22:21:24 <ais523> fwiw I'm not convinced that sigils generally are bad, but I don't think they benefit modern Perl in particular because almost everything is a scalar
22:21:42 <sorear> perl 5 does not have fat pointers. it has fat *variables*. bless attaches metadata to the memory location (SV) like a tie would
22:22:17 <sorear> 100% sincere with maybe a touch of self-deprecation
22:22:21 <ais523> ah, you are right (although programs are in practice nearly always written in such a way that the distinction is not observable)
22:23:05 <ais523> Perl has so much metadata on everything that it is hard to remember where in particular any given datum is stored
22:25:00 <sorear> I did _write_ one...
22:29:45 <esolangs> [[Fat pointer]] N https://esolangs.org/w/index.php?oldid=166657 * Corbin * (+1948) Stub for a recurring concept that isn't properly addressed on WP.
22:32:27 <ais523> korvo: I'd caveat that the extra data in a fat pointer isn't always a pointer, it just needs to contain "type" information generally, but sometimes that's generics rather than a type name expressed as a vtable
22:33:12 <ais523> Rust slices are only accessible via fat pointers that specifies the length they would have if interpreted as an array, for example (which is a numerical generic rather than a vtable)
22:34:14 <korvo> ais523: Sure. I think of those as degenerate cases of the general concept, though; they're just more specialized.
22:34:55 <ais523> hmm, I guess you can view the slice length as a sort of compressed pointer that stores the entire data of its target inside the space that would otherwise be used for the pointer itself
22:35:09 <korvo> The first component is what we call "green" in JIT theory; it's the component that we want to hold constant and "differentiate with respect to", so to speak.
22:35:09 <sorear> how about fortran multidimensional slice descriptors
22:35:11 <ais523> like, we use the number 5 as a compressed version of "a pointer to a vtable for a length-5 array"
22:40:18 <ais523> hmm, is there a standard name for this sort of pointer/reference-like thing where the thing that is being referenced might actually exist in memory, or might just be generated on the spot?
22:43:01 <sorear> laziness?
22:44:05 <ais523> I don't think it's quite the same
22:44:09 <ais523> it is similar though
22:44:32 <ais523> for a lazy pointer/reference, I would expect the target to be generated on first use and then remain in memory, rather than being generated on every use
22:46:20 <sorear> c++, python, and self are all canonically thin-pointer systems where you either have types at compile time, or the referent of a pointer knows its runtime type because it has a vtable/metadata...
22:46:25 <korvo> "proxy", "facade", "becomer" (https://gbracha.blogspot.com/2009/07/miracle-of-become.html)
22:48:13 <sorear> there's a bit of nastiness around c++ multiple inheritance where sometimes an object has to have multiple vtable pointers and seemingly no-op coercions need to offset the object pointer to point at a different vtable pointer, but everything is still thin
22:48:26 <korvo> Isn't Python canonically fat? The `type` allocator produces objects with a `__class__` and `__dict__`; those are the first and second component of the standard fat pointer.
22:48:49 <ais523> korvo: oh right, "proxy" definitely fits (I'm a bit less familar with the other two)
22:49:08 <korvo> I'll concede that perhaps I misread the Self paper. I haven't actually played with a Self implementation.
22:49:23 <sorear> a fat pointer is local and immutable, you can change the type information on one pointer to an object without changing it for others
22:50:12 <sorear> I suppose you could think of a Python object as a fat pointer to a dictionary, but the existence of slots muddles that interpretation
22:50:34 <sorear> i'd rather think of the object as an object itself that simply delegates some behavior to a dictionary
22:50:44 <sorear> the only Self implementation I've used is V8
22:52:56 <ais523> interestingly Rust has an equivalent to Smalltalk become: (called core::mem::replace), although it's much more restrictive because you need a mutable reference to the thing you are replacing
22:53:43 <ais523> it has become increasingly controversial over time because it breaks invariants that would otherwise exist, some of which would be useful for implementing various language features
22:55:25 <ais523> from my point of view, its biggest issue is that it means that the concept of object identity effectively doesn't exist in Rust, because there's no type-system-level way to observe that an object got swapped out and so you can't tell whether you're still using the same object you were previously using if any code you don't control has had a mutable reference to it
22:55:46 <Sgeo_> ...and I wrote a variation (take_mut) to allow what felt like a missing function in the language >.>
22:56:18 <ais523> Sgeo_: is that core::mem::take, or something else?
22:57:47 <Sgeo_> It's more of a core::mem::replace that can wait for the hole to be filled, passing in a closure. It aborts if the closure panics
22:58:26 <Sgeo_> I sort of wanted there to exist a function that turns (T -> T) into one that takes (&mut T)
22:58:57 <ais523> oh, I see, it leaves an uninitialized hole behind?
22:59:08 <ais523> or, well, a copy of the bits but that you aren't allowed to use
22:59:29 <sorear> replace is interesting because it's the only way to move a non-Clone type out of a mutable reference, if you're working with owned values the lack of identity goes much deeper because there's no way to override operator=
23:00:07 <ais523> this is one of the things that makes me think that Rust &mut is incorrectly defined (I am not opposed to the existence of mutable references but I think the specific choices &mut makes for what you can and can't do are wrong)
23:00:15 <Sgeo_> There's an RFC that failed, calling the function replace_with
23:00:36 <ais523> because it has an invariant that it always points to a valid value of the type, even while reborrowed
23:01:08 <Sgeo_> https://github.com/rust-lang/rfcs/pull/1736#issuecomment-1311564676
23:01:29 <Sgeo_> Composition of safe crates that add functions is unsafe
23:01:45 <ais523> I agree that it would make more sense for a reborrowed &mut to not constrain the type of the thing that it's reborrowing (although, as you say, you would need some separate way to maintain panic-safety in that case)
23:02:11 <sorear> well if you reborrow you have a _new_ reference, mutable or not, which upholds the "has a valid value of the type"
23:02:41 <ais523> sorear: but what if you transmute the new reference
23:02:58 <ais523> this is unsafe, but isn't necessarily unsound
23:04:51 <Sgeo_> I wanted to make some sort of unmovable structure based on the compiler preventing self-referencing structures from being moved. I didn't do so and the community invented Pin.
23:05:01 <Sgeo_> I don't... know if my idea would have worked or not
23:05:14 <Sgeo_> I don't fully understand Pin and the async features
23:05:36 <ais523> Sgeo_: you can actually do that in current safe Rust (unmovable self-referencing structures) but there are a lot of restrictions
23:06:01 <ais523> the basic idea is to have a type with a lifetime parameter that controls the lifetimes of the references inside, and the same lifetime is also used for self on the method calls
23:06:53 <ais523> the main problems are that it only works well with shared references (because if you do it with a mutable reference it doesn't reborrow properly) and nothing self-referencing can have a destructor (otherwise it fails drop check)
23:07:57 <ais523> the latter problem seems to be inherent to the idea of self-referencing structures rather than a limitation of the implementation: a structure has to be dropped after everything it references, so if you have a circular reference you can't drop at all
23:08:13 <ais523> (but if there are no destructors Rust works around the problem by simultaneously forgetting the whole structure)
23:08:18 <b_jonas> when you say that replace is the only way to move out from a mutable reference, do you consider mem::swap equivalent to that? because I'm thinking of mem::swap as the more natural way and mem::replace a wrapper around that
23:08:29 <ais523> b_jonas: yes, swap and replace are basically equivalent
23:08:41 <b_jonas> ok good
23:09:10 <ais523> swap is slightly more fundamental in that trying to implement swap in terms of replace needs a temporary, which you might not be able to initialize correctly
23:09:14 <sorear> korvo: skimming everything posted here is unsustainable and I'll have to go back to mostly ignoring, do you want to move the nql stuff somewhere else or just ping?
23:10:14 <b_jonas> as for moving out and leaving a hole that you will fill before you return, thus breaking panic safety, I wonder if you can do that with a Cell
23:10:38 <b_jonas> Sgeo_: ^
23:11:23 <ais523> b_jonas: you can't move out of a cell unless you swap something in
23:11:37 <ais523> in fact, mem::swap is not the fundamental operation, Cell::swap is
23:12:05 <ais523> you can write mem::swap in terms of Cell::swap (and occasionally have to, e.g. when swapping a mutable reference with a cell; that came up for me recently)
23:12:32 <b_jonas> that makes sense, because you might try to access a cell through another reference
23:14:00 <ais523> that said, it is possible that Cell::swap needs a special case for trying to swap a cell with itself, and mem::swap doesn't
23:14:49 <int-e> b_jonas: hmm do you think this reduction in critical path length is meaningful ;-) https://int-e.eu/~bf3/tmp/shapez-mam-critical.png (right: corresponding snippet from https://int-e.eu/~bf3/tree-mam/ )
23:39:17 <int-e> Hmm I think it's a bit over half a second at 10x belt speed. So not huge when the total latency is like 16s.
←2025-10-23 2025-10-24 2025-10-25→ ↑2025 ↑all