←2019-09-09 2019-09-10 2019-09-11→ ↑2019 ↑all
00:26:58 -!- Sgeo_ has quit (Read error: Connection reset by peer).
00:27:21 -!- Sgeo_ has joined.
00:55:33 -!- Lykaina has joined.
00:59:00 <Lykaina> b_jonas: i don't know any other way
01:04:17 -!- ARCUN has joined.
01:05:49 <ARCUN> By definition, a bully automaton is just an extension of a cellular automata
01:06:12 <ARCUN> So would ALPACA still be viable to implement a bully automaton?
01:07:09 <Lykaina> 20:29:07 <b_jonas> Lykania: again, do not define global variables in a header file that you #include into multiple source files. especially not non-constant globals.
01:08:16 <Lykaina> any idea where else i should declare global variables?
01:08:32 <Lykaina> and define
01:09:14 <Lykaina> and what's the difference (in C) between declaring and defining?
01:10:56 <fizzie> A /definition/ of an identifier is a declaration for that identifier that: for an object, causes storage to be reserved for that object; --
01:11:29 <fizzie> Typically you'll have a declaration that's not a definition (such as `extern int x;`) in a .h file, and a corresponding definition (`int x = 123;`) in exactly one .c file.
01:11:54 <Lykaina> why shouldn't they go in headers?
01:12:22 <Lykaina> oh
01:12:29 <fizzie> Because if you have it in a header file, chances are that header file is going to be included in more than one translation unit, and then you end up with more than one definition for the same object, which is generally illegal.
01:12:33 <fizzie> (With some subtlety.)
01:12:49 <Lykaina> b_jonas wasn't beclear enough
01:13:00 <fizzie> http://ix.io/1Mys (from the C99 rationale) explains it better than I could.
01:13:58 <fizzie> ...well, "better" is subjective. But definitely in more detail.
01:14:35 <fizzie> In particular, it goes into the detail of what the standard model is, and what happens in practice on many implementations.
01:15:43 <ARCUN> C looks so simple from the outside, yet it's actually quite complex
01:16:46 -!- pikhq has joined.
01:17:09 <ARCUN> Its subjective, but C++ just looks more natural to learn for me
01:17:36 <ARCUN> Which is weird, since my first language was C#
01:17:38 <fizzie> I guess it has at least the benefit of nobody accidentally thinking it's simple.
01:18:30 -!- pikhq_ has quit (Ping timeout: 258 seconds).
01:21:38 -!- ARCUN has quit (Remote host closed the connection).
01:22:56 -!- ARCUN has joined.
01:23:17 <Lykaina> fizzie: can you look at the echidna repo and find the problem b_jonas is complaining about?
01:23:42 <Lykaina> i mean, it's location
01:23:43 <ARCUN> So, again, is ALPACA viable for the implementation of bully automaton?
01:25:01 <fizzie> Lykaina: I assume they might've been talking about globals.h, and/or argnums.h.
01:28:30 <fizzie> A declaration of the form of `unsigned long progindex;` is what's called a /tentative definition/, which (if a translation unit has no actual definition) is treated as if there was a definition like `unsigned long progindex = 0;` in the translation unit. So if globals.h is included in, say, cmds.c and main.c, both will have a definition for it, which is not strictly conforming C.
01:29:33 <fizzie> Assuming they end up in the same program, anyway.
01:31:24 <fizzie> ("If an identifier declared with external linkage is used in an expression (other than [unrelated exception]), somewhere in the entire program there shall be exactly one external definition for the identifier; otherwise, there shall be no more than one.")
01:34:03 <fizzie> Many implementations are in practice more relaxed than that and allow multiple definitions esp. as long as they don't have an initializer, but that's just a common extension and not guaranteed by the standard.
01:36:51 <fizzie> A strictly conforming program could, for example, have a globals.h with `extern unsigned long progindex;`, and then either in a dedicated globals.c, or in some other one .c file where it makes sense, include an `unsigned long progindex;` to provide the "exactly one" definition required for it.
01:37:34 <fizzie> (A lot of people would prefer to avoid global state entirely, but that's more of a design question than a correctness question.)
01:38:09 <Lykaina> look now
01:38:30 <Lykaina> i just pushed what i think is a fix
01:39:17 <fizzie> I don't have any complaints about that one, at least on a quick glance.
01:39:31 <Lykaina> so it's better?
01:39:45 <fizzie> Yes, assuming I've interpreted b_jonas's criticism right.
01:39:52 <fizzie> Except that it's exceedingly strange to put header guards *outside* the header files.
01:40:38 <Lykaina> oops
01:40:44 <Lykaina> i'll fix that
01:41:28 <fizzie> Also, it's safe to include standard headers like <stdio.h> multiple times. It doesn't hurt to guard against that, but you don't need to unless you want to.
01:41:58 <fizzie> ("Standard headers may be included in any order; each may be included more than once in a given scope, with no effect different from being included only once, except [a niche thing].")
01:44:37 <Lykaina> pushed
01:47:00 <fizzie> Well, I mean... normally you'd have #ifndef H_DEFINES #define H_DEFINES as the first two lines of defines.h itself, and an #endif as the last line. That way all the different places where it's included won't need to (a) remember to wrap the #include in a #infdef-#define-#endif sequence, and (b) coordinate what the name used for the header guard is.
01:48:15 <Lykaina> oh
01:49:21 <fizzie> Of course from the compiler's perspective there's no difference whether those are inside the .h file or around the #include statement, it just treats the whole thing as a sequence of lines. It's just a convenience thing.
01:49:27 <Lykaina> do i need to have the license in every file or just in the LICENSE file?
01:50:49 <kmc> #pragma once
01:50:49 <kmc> !
01:51:11 <fizzie> I'm not qualified to give legal advice, and I've seen both done.
01:51:11 <Lykaina> what's that?
01:51:19 <fizzie> It's another nonstandard extension.
01:52:12 <Lykaina> kmc: what are you asking me to change?
01:52:55 <kmc> no
01:52:58 <kmc> i was just saying
01:53:06 <kmc> that you can use #pragma once instead of include guards
01:53:16 <kmc> if all the compilers you want to use support it
01:53:22 -!- MDude has quit (Ping timeout: 245 seconds).
01:53:22 <kmc> it's faster and less error-prone
01:53:37 <fizzie> I wouldn't. But it's true, you definitely can.
01:53:48 <kmc> faster because, as soon as a header has been seen to have #pragma once, the compiler will not even bother reading it again
01:54:06 <kmc> although I think these days compilers also detect include guards and treat them similarly
01:58:43 -!- ARCUN has quit (Ping timeout: 260 seconds).
01:58:46 <j4cbo> aiui what kmc said
01:59:14 <j4cbo> the main advantage of #pragma once is not having to pick an include guard format
01:59:45 <kmc> I have actually had issues with include guard name collisions once or twice
02:03:01 <fizzie> Regarding the performance question, https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58770
02:05:12 <fizzie> As for the correctness question, I understand a number of implementations have had issues determining what exactly is the same file, given symlinks and all that.
02:07:23 <fizzie> Although you can very reasonably say that you've got bigger problems if, in a single build operation, the same header file is reached via two unrelated paths.
02:08:14 <kmc> it probably happens
02:10:00 <Lykaina> pushed
02:10:15 <Lykaina> fizzie's advice
02:14:02 -!- imode has quit (Ping timeout: 246 seconds).
02:16:52 <fizzie> Should probably have a look at what this language is all about in the first place. Does it have anything to do with the spiky mammals or is that just a name?
02:17:02 <Lykaina> name
02:19:22 <fizzie> Aw. They're pretty cute.
02:19:33 <Lykaina> fizzie: http://sif.lesidhetree.com/sara/echidna/echidna_v0_02a2.pdf
02:22:07 <esowiki> [[NotBrainFuck]] N https://esolangs.org/w/index.php?oldid=66054 * Spleeshmicannon * (+1325) Created page with "'''NotBrainFuck''' (or not brainfuck) is an extension of brainfuck by Jack Benson ([[User:Spleeshmicannon|Spleeshmicannon]]). It adds 8 new symbols to make it easier for begin..."
02:26:44 -!- xkapastel has quit (Quit: Connection closed for inactivity).
02:34:30 <Lykaina> fizzie: Echidna was originally designed to be run on an Arduino, but memory requirements eventually made this unfeasable, with the Arduino version being shelved.
02:35:26 <Lykaina> I then modified the PC version to use far more memory.
02:36:57 <Lykaina> eventually, i figured out how to load the file into ram and run the program from there
02:37:50 <Lykaina> there are 20 Ops, from G - Z
02:39:24 <Lykaina> the interpreter has problems with the if/while loops on while mode that i am unsure how to debug
02:42:31 <Lykaina> at the moment, i feel it's lacking in ops, and i think i can be willing to have ops 0-9 and A-F if needed (i wanted to not use those)
02:44:15 <Lykaina> any questions?
02:48:03 <fizzie> Not at this point, because I have to sleep instead. But I like the L operation, it kind of reminds me of INTERCAL's "select" operator.
02:48:42 <Lykaina> Finally! Someone who likes L!
02:57:08 <Lykaina> kmc: even though it doesn't have "pragma", how do you feel about Echidna?
02:57:41 <Lykaina> (not sure if you are still active)
02:58:52 <kmc> i don't know anything about echidna
02:59:21 <Hooloovo0> wait what does arg1<=1 do in L?
02:59:25 <Lykaina> read whan i told fuzzie
02:59:44 <Hooloovo0> http://sif.lesidhetree.com/sara/echidna/echidna_v0_02a2.pdf took me a while to find it
02:59:56 <Hooloovo0> might want to put that on the esolang wiki or the github
03:00:31 <Hooloovo0> (was just in scrollback but /me never reads that far
03:01:39 <Hooloovo0> oh <<=
03:40:13 -!- imode has joined.
04:06:56 -!- tromp has joined.
04:11:18 -!- tromp has quit (Ping timeout: 246 seconds).
04:14:20 -!- ais523 has joined.
04:15:03 <ais523> <Lykaina> do i need to have the license in every file or just in the LICENSE file? ← I don't know whether or not it's legally necessary to put the license in every file, but a) it doesn't hurt and b) there are a lot of good practical reasons to do it that way
04:15:27 <ais523> if you're using a license written professionally, it'll normally have an appendix giving approved wording to place in every file (which is shorter than the license itself)
04:37:17 -!- ais523 has quit (Quit: quit).
05:15:09 -!- MDude has joined.
05:54:54 -!- tromp has joined.
05:59:38 -!- tromp has quit (Ping timeout: 276 seconds).
06:31:56 -!- tromp has joined.
07:43:15 -!- Frater_EST has joined.
08:00:47 -!- cpressey has joined.
08:08:50 -!- imode has quit (Ping timeout: 240 seconds).
08:15:31 -!- Phantom_Hoover has joined.
08:40:52 -!- grumble has quit (Ping timeout: 622 seconds).
08:42:05 -!- wob_jonas has joined.
08:43:16 <wob_jonas> Lykiana: https://esolangs.org/logs/2019-09-07.html#lrh
08:43:31 <wob_jonas> about global variables
08:44:08 <shachaf> `5 w
08:44:14 <HackEso> 1/1:mother//A mother is a person who practices mothology. \ dc//dc is short for "dump core". (try it out yourself: dc -e '[') \ wat//ኢትዮጵያ ውስጥ የሚሰራ የምግብ አይነት ሲሆን፣ የሚሰራውም ከጤፍ ነው። \ atwp//According to Wikipedia, ATWP means "Air Transport White Paper". \ mussel//Mussels are boily's natural enemies. Fortunately he runs faster than them.
08:44:34 <wob_jonas> Lykaina: ^
08:44:47 <myname> i agree on wat
08:45:15 <wob_jonas> iirc globals.h was included to two C source files
08:48:09 <shachaf> I should figure out a way to make global variables work across .so reloads.
08:52:08 -!- Lord_of_Life has quit (Ping timeout: 245 seconds).
08:53:21 <wob_jonas> ais523: whether there's a separate long license and you only include a short text and reference to it, or whether there's a short license that you include in full, also seems to be a matter of taste between licenses.
08:54:52 -!- Lord_of_Life has joined.
08:54:58 -!- tromp has quit (Remote host closed the connection).
08:55:51 <wob_jonas> The X11 license, most BSD-like licenses, and the boost license are short enough, and at least the FAQ https://www.boost.org/users/license.html considers this an advantage. I personally don't like the boost license though because it doesn't mention a time limit or geograhpical area (eg. "worldwide perpetual").
08:58:17 <wob_jonas> Whereas the apache license, which is pretty similar to the boost license, is too long to embed into every source file, so for that, they use just a short version with reference in source files.
08:59:07 <wob_jonas> In effect, the short licenses don't tend to work, because many project derive parts from code with various other licenses, so they have to include a separate notice anyway to tell which part comes with what license.
08:59:38 <myname> the wtfpl works
09:00:37 <wob_jonas> This is especially typical for big amalgam projects like ffmpeg and mplayer, each of which embed like a hundred codecs and a large part of each other (it's a miracle that they haven't yet blown up exponentially by recursively embedding each other).
09:02:58 <wob_jonas> Similarly the creative commons licenses are also too long to embed.
09:06:02 <cpressey> The MIT license requires that you include it, so all the projects that have only a one-line statement to the effect of "License: MIT" aren't actually under the MIT license.
09:06:20 <cpressey> And y'know what? This matters almost not at all
09:08:49 <wob_jonas> cpressey: sure, even the short disclaimers are always at least a few lines long, except for the ones that are equivalent to the WTFPL, such as the sqlite non-license.
09:10:09 <cpressey> I like the irony though.
09:10:11 <wob_jonas> The short form reference to the apache license is 15 lines long
09:12:49 <shachaf> cpresseyllo
09:12:58 <shachaf> What's the Prompt thing you were talking about the other day?
09:13:50 <wob_jonas> But that's still shorter than the 24 long line boost license
09:14:15 <cpressey> shachaf: https://hackage.haskell.org/package/MonadPrompt-1.0.0.5/docs/Control-Monad-Prompt.html
09:14:31 <cpressey> cpressey: It's not related to delimited continuations
09:14:43 * cpressey frowns
09:15:05 <cpressey> shachaf: It's not related to delimited continuations
09:15:47 <cpressey> Perhaps I should say, it's not *obviously* related to delimited continuations
09:18:00 <shachaf> Oh, that thing.
09:19:34 <shachaf> It's "just" the free monad, right?
09:19:42 <shachaf> Or the free monad of Coyoneda of f.
09:20:35 <cpressey> shachaf: <int-e> cpressey: yeah the connection to free monads uses a fairly odd functor: http://paste.debian.net/1099707/
09:21:58 <cpressey> (maybe you can make more sense of that than I can)
09:25:21 <shachaf> Yes, that functor is sometimes called Coyoneda.
09:25:30 <shachaf> It's the free functor on a type constructor, if that means something to you.
09:25:44 <cpressey> Not really, sorry
09:26:33 <shachaf> OK. It's not that useful a statement anyway.
09:27:05 <shachaf> If my computer wasn't presently so slow I could type a better explanation. One moment.
09:27:08 <wob_jonas> scary
09:27:28 * Lykaina wakes
09:27:31 <Lykaina> brb
09:28:39 <shachaf> Hmm, I'll just try anyway.
09:29:32 -!- tromp has joined.
09:29:50 <wob_jonas> Lykania: I haven't yet looked at how you're now reading the source code into memory and how you use it, or changing the data memory to 16-bit, so I can't comment on that yet
09:30:42 <Lykaina> i am doing the global variable thing now
09:30:51 <shachaf> cpressey: I don't remember how much Haskell you know.
09:31:24 <shachaf> The type is this: data Coyoneda f a = forall x. Coyoneda (f x) (x -> a)
09:31:43 <Lykaina> and using the kind of header guards that go on top and bottom of every header file
09:36:07 <shachaf> It's about fmap fusion, or something.
09:36:27 <shachaf> It turns (fmap f . fmap g . fmap h) into fmap (f . g . h)
09:36:58 <Lykaina> back
09:39:07 <Lykaina> i meant that, at the moment, Echidna uses the global variable suggestion and the kind of header guards that gow on top an bottom of each header file.
09:49:22 <Lykaina> README.md pushed
09:57:30 <esowiki> [[Echidna]] https://esolangs.org/w/index.php?diff=66055&oldid=66042 * Lykaina * (+434) Updating the info to match the Github README.
10:10:04 <Lykaina> README.md pushed again
10:10:47 <cpressey> shachaf: I don't really know Haskell, in the sense that I've never built up good intuitions about anything in its type system.
10:12:12 <cpressey> I still don't really know what a monad is.
10:12:28 <wob_jonas> `? monad
10:12:30 <HackEso> Monads are just monoids in the category of endofunctors.
10:12:30 <wob_jonas> `? burrito
10:12:31 <HackEso> Burritos are like Monads, according to Joe. See https://byorgey.wordpress.com/2009/01/12/abstraction-intuition-and-the-monad-tutorial-fallacy/
10:12:43 <Taneb> `quote burrito
10:12:44 <HackEso> 875) <ais523> btw, I finally discovered what a burrito was, recently <ais523> they're kind of nice to eat <ais523> but don't really resemble monads \ 908) <elliott> well what is time <elliott> imo: an illusion [...] <Taneb> elliott, I think it's more like a burrito <Taneb> If you have too much of time you get ill <Taneb> But damn it felt good <Taneb> You only get out what you put in, unless your time was made by someone else, which isn't as fun <ais
10:12:47 <wob_jonas> yeah, wisdom doesn't know either
10:14:26 <cpressey> I read an article explaining how they're monoids in the category of endofunctors, and *while reading* that article, I could see it. But it doesn't stick.
10:15:21 <wob_jonas> cpressey: that said, apparently to program haskell, you don't have to know what monads are in full generality. you just have to understand the dozen common monads and the dozen common monad transformers and how they combine.
10:17:20 <cpressey> You don't *have* to use monads at all when writing in Haskell, except to do I/O, which you can save til the end and treat as a magical invokation.
10:17:55 <Taneb> You don't even really need to know that IO is a monad
10:18:43 <Taneb> cpressey: have you tried reading You Could Have Invented Monads?
10:19:40 <cpressey> Taneb: Once, a long time ago. It doesn't stick.
10:19:44 <myname> i read cakes, custard and category theory
10:19:48 <wob_jonas> cpressey: "save til the end" in what sense? you may want to use interactive IO
10:19:58 <Taneb> myname: recent editions changed the name to How To Bake Pi
10:20:13 <Taneb> In case you're recommending people go out and buy a copy
10:20:14 <esowiki> [[NotBrainFuck]] M https://esolangs.org/w/index.php?diff=66056&oldid=66054 * A * (-110) Here you go
10:20:28 <myname> okay
10:20:34 <wob_jonas> and of course some programs are easier to write if you do use the ST monad, to be able to prove that a function is pure even if it uses certain impure internals
10:20:43 <wob_jonas> (as in mutable arrays)
10:20:48 <Taneb> (I have a copy of Cakes, Custard and Category Theory but I haven't read it yet)
10:20:58 <cpressey> wob_jonas: You don't *have* to use interactive IO to write, say, a compiler
10:21:11 <myname> it's not that deep a read
10:21:36 <wob_jonas> cpressey: sure you do, at least if it's a compiler for a language where files can include other files and you don't know which files in advance
10:21:40 <Taneb> Yes but I keep wanting to follow along with the exercises and that means going to the shop and buying ingredients
10:22:06 <wob_jonas> that includes not only preprocessor includes, but indirect linker dependencies
10:23:09 <cpressey> wob_jonas: So your argument is that you have to understand a dozen common monad transformers in order to program in Haskell because the compilers you write in Haskell are necessarily ones with #include statements
10:23:32 <wob_jonas> cpressey: and if you have a compiler where you aren't sure that it can't be very slow (or infinitely slow) for some input files, then it may be better to write error/warning messages early, before you finish compiling everything
10:24:06 <wob_jonas> cpressey: no, that's not my argument. my argument is that you don't always write compilers, so it's worth to understand at least how to use IO interactively;
10:24:34 -!- grumble has joined.
10:24:40 <wob_jonas> and that I want to use mutable arrays for efficiently, for which it's worth to understand ST to be able to use them inside pure functions in a way that the compiler can prove safe.
10:25:13 <wob_jonas> you probably aren't required to use the other monads or monad transformers directly.
10:25:14 <cpressey> wob_jonas: Right, well as I said, I *don't* understand them. It doesn't stick. Should I stop programming in Haskell?
10:25:24 <wob_jonas> obviously you'll use lists, but not specifically their monad instance.
10:25:54 <wob_jonas> cpressey: no, because if you stop then you'll probably never understand them, unless you program something very similar to haskell instead
10:26:21 <cpressey> wob_jonas: It's been 10 years. I don't have any reason to assume I'll ever understand them.
10:26:45 <Taneb> Do you need to understand them to use them?
10:27:21 <wob_jonas> cpressey: how about the special case of IO where you glue a >>= onto every IO primitive (except the ones that terminate the program), but don't use >>= with a composed value on the left?
10:27:42 <cpressey> More like 12 years: I wrote this in 2007: https://github.com/catseye/Hev/blob/master/src/Hev.hs
10:27:58 <cpressey> Oh, apparently I started it in 2005, so: 14 years.
10:28:45 <cpressey> Doesn't use a single monad, except in the driver code that reads cmdline arguments and the input file and outputs the result.
10:30:14 <wob_jonas> cpressey: have you written code in non-haskell languages that does interactive IO in an event-driven continuation-passings style where you write explicit continuations to run when an event fires, instead of language support for threads with blocking IO?
10:31:21 <wob_jonas> because as far as I understand, if you do that style consistently so that you do it for every IO operation, even for ones that don't block or the ones that only count as IO in haskell (i.e. accessing mutable state), you get IO monad with >>= only on the right of primitives
10:31:44 <wob_jonas> at least that's how I understand IO, but it could be wrong, or it could be just one of the many food metaphors for IO
10:32:04 <shachaf> cpressey: I think Haskell people typically say "monoid in the category of endofunctors" as a joke to try to make things complicated?
10:32:25 <shachaf> It's not very complicated but also not very helpful.
10:32:27 <wob_jonas> maybe someone who understands haskell a bit more can tell me whether that's a reasonable way to think of it
10:32:39 <shachaf> Anyway this is irrelevant for Coyoneda, which is a pretty simple type.
10:32:44 <wob_jonas> shachaf: yes, I think that's intended as a joke
10:32:48 <wob_jonas> lol
10:33:00 <wob_jonas> "pretty simple type"
10:33:08 <shachaf> wob_jonas: Yes, that's pretty reasonable.
10:33:29 <shachaf> I once wrote this: https://stackoverflow.com/a/13538351
10:35:59 <wob_jonas> shachaf: oh wow, that mentions that IO mechanism that I've only seen in that one crazy esolang
10:36:22 <Taneb> wob_jonas: is that crazy esolang called Haskell?
10:37:09 <wob_jonas> https://esolangs.org/wiki/Lazy_K
10:37:22 <wob_jonas> Taneb: no, Haskell has a different IO mechanism
10:37:43 <wob_jonas> which that writeup also mentions
10:37:52 <wob_jonas> (what a surprise)
10:39:15 <wob_jonas> shachaf: ok, but that doesn't seem to explain how you can write IO as an abstraction of ContIO. is there an explanation for that somewhere?
10:39:39 <Taneb> wob_jonas: Lazy K has the same IO mechanism as Real Fast Nora's Hair Salon 3: Shear Disaster Download
10:40:31 <wob_jonas> Taneb: ok, then it's two crazy esolangs
10:40:34 -!- arseniiv has joined.
10:40:40 <wob_jonas> fair enough
10:40:46 <Taneb> And it's fairly similar to Binary Lambda Calculus
10:40:58 <Taneb> (which uses strings of bits, I believe, rather than characters or codepoints)
10:41:55 <wob_jonas> ok, I think if I saw that esolang, it didn't stick in my head
10:42:16 <wob_jonas> or in my hair or whatever
10:42:41 <Taneb> Yeah, it has a hard to remember name
10:43:31 <Taneb> And it's not particularly original
10:47:12 <cpressey> wob_jonas: explicit continuations on event handlers sounds like Javascript with Promises.
10:47:55 <esowiki> [[Vafix]] N https://esolangs.org/w/index.php?oldid=66057 * A * (+205) New unimplemented thought experiment
10:52:24 <Taneb> In a programming lanugage strictly following the actor model, how is input (e.g. command line input, key presses) handled?
10:52:59 <Taneb> Some sort of special actor?
10:53:01 <wob_jonas> I don't know what the actor model is
10:53:21 <wob_jonas> but sure, if it's foo-oriented then keypresses are probably a kind of foo
10:53:25 <Taneb> https://en.wikipedia.org/wiki/Actor_model
10:53:50 <shachaf> wob_jonas: What do you mean?
10:54:37 <wob_jonas> Taneb: is that like holywood actors who must look as beautiful as a fashion model all the time?
10:55:00 <Taneb> wob_jonas: I think it's more like models who gain popularity and want more money sometimes start acting too
10:55:01 <cpressey> Taneb: I can put it this way: if I were designing an actor language, I'd make the source of keystrokes an actor
10:55:29 <cpressey> That said, in Erlang, iirc,it's not like that, you just call io:readln() like everyone else
11:04:06 <cpressey> I can see having to look at all I/O like you're writing Promises in Javascript (I guess) but it escapes me why anyone would want to model *non*-I/O things like that.
11:05:52 <cpressey> Not too long ago, I saw a unification algorithm written in Haskell, built with a state monad.
11:05:55 <cpressey> whyyyyyyyyyyyy
11:06:06 <wob_jonas> cpressey: that's actually two steps. firstly they model not just interactive blocking IO, but every IO, even the ones that can't block, as the same sort of IO action;
11:06:15 <wob_jonas> then they model access to mutable state the same way
11:06:44 <wob_jonas> and inter-thread synchronization as well
11:07:35 <wob_jonas> but I think the reason is always that they want the language to be pure functional
11:08:01 <wob_jonas> with every function being deterministic and side-effectless
11:08:35 <cpressey> A language that's pure functional, where every library has an interface that mocks an effectful language. Again I ask: whyyyyyyy
11:09:14 <wob_jonas> it would just be a different language without. if you don't like it, use ocaml or rust or something.
11:09:28 <wob_jonas> and that applies to me, I don't use haskell for anything anymore
11:09:40 <wob_jonas> (well, except some lambdabot one-liners or something)
11:10:20 <cpressey> I do like it, though, because it's essentially the only popular language that actually is purely functional.
11:10:57 <wob_jonas> but if you do want a purely functional language, then you need to have those abstractions over everything that isn't purely functional
11:10:59 <shachaf> If users of the only popular language that's purely functional write their algorithms in terms of state mutation, maybe that means those algorithms are best expressed as state mutation.
11:11:44 <wob_jonas> shachaf: at least if you care about real-world efficiency
11:12:21 <wob_jonas> or interaction with anything outside the program
11:15:28 -!- Phantom_Hoover has quit (Ping timeout: 245 seconds).
11:29:30 <cpressey> Well, I don't, so, until a better language comes along, I'll just learn to live with the alienation, I suppose.
11:34:28 <wob_jonas> you could just use a language that isn't pure functional, but use the pure functional subset for much of your code
11:35:20 <cpressey> I do that sometimes with Scheme.
11:35:50 <wob_jonas> do you do it with ocaml?
11:36:11 <cpressey> I don't write OCaml.
11:39:58 <cpressey> Well, at least I understand continuations. I think.
11:40:05 * cpressey goes for a walk
11:40:15 <wob_jonas> whoa, more schema incompatibility
11:40:25 <wob_jonas> only forwards, not backwards
11:40:34 <wob_jonas> or wait
11:40:44 <wob_jonas> which one is backwards compatibility and which one is forward compatibility?
11:40:52 <wob_jonas> I think it's only backwards, not forwards
11:43:08 -!- Frater_EST has quit (Ping timeout: 246 seconds).
11:50:29 <wob_jonas> hmm no
12:13:05 <esowiki> [[Vafix]] M https://esolangs.org/w/index.php?diff=66058&oldid=66057 * A * (+659)
12:16:24 <cpressey> On a positive note, a nonstandard formulation of function composition that I came up with for an experimental concatenative language I'm working on, does appear to be associative and have an identity. So I'll be able to keep working on that.
12:17:31 <wob_jonas> cpressey: that sounds scary
12:19:07 <wob_jonas> but then, I guess, any monoid operation can be thought of as function composition of the bound products with elements of the monoid
12:19:28 <wob_jonas> also known as "every group is a permutation group"
12:20:21 <esowiki> [[Vafix]] M https://esolangs.org/w/index.php?diff=66059&oldid=66058 * A * (+1103)
12:28:28 <esowiki> [[Vafix]] M https://esolangs.org/w/index.php?diff=66060&oldid=66059 * A * (+1031) /* Execution scheme */ More of the execution
12:28:46 -!- Frater_EST has joined.
12:34:15 <esowiki> [[Vafix]] M https://esolangs.org/w/index.php?diff=66061&oldid=66060 * A * (+585) Complete odd process
12:36:55 -!- grumble has changed nick to \emph{grumble}.
12:37:57 -!- FraterEST has joined.
12:38:23 -!- Frater_EST has quit (Ping timeout: 268 seconds).
12:40:25 <esowiki> [[Vafix]] M https://esolangs.org/w/index.php?diff=66062&oldid=66061 * A * (+564)
12:57:10 <cpressey> I found the unification algorithm I mentioned above, if anyone is interested: https://github.com/parsonsmatt/unification/blob/master/Unification.pdf
13:16:50 -!- atslash has joined.
13:16:54 <esowiki> [[Vafix]] M https://esolangs.org/w/index.php?diff=66063&oldid=66062 * A * (+370) /* Vafix in comparision with a normal infix */
13:32:01 <Lykaina> gtg wake
13:33:20 -!- Lykaina has quit (Quit: leaving).
13:52:54 -!- sprocklem has quit (Ping timeout: 258 seconds).
14:07:08 -!- wob_jonas has quit (Ping timeout: 276 seconds).
14:16:19 -!- Lykaina has joined.
14:26:11 <esowiki> [[Encapsulation]] https://esolangs.org/w/index.php?diff=66064&oldid=66039 * A * (+100) /* Computational class */
14:26:23 -!- rain2 has joined.
14:28:13 -!- rain1 has quit (Ping timeout: 244 seconds).
14:35:27 -!- sebbu has quit (Ping timeout: 244 seconds).
14:36:25 -!- sebbu has joined.
14:51:42 <Lykaina> hi
14:52:18 <Lykaina> just seet up email filters for the annoying github alerts i actually want
14:56:14 <esowiki> [[Vafix]] M https://esolangs.org/w/index.php?diff=66065&oldid=66063 * A * (+32) /* Vafix in comparision with a normal infix */
14:58:29 <esowiki> [[Vafix]] M https://esolangs.org/w/index.php?diff=66066&oldid=66065 * A * (+358) /* Parentheses and rules */
14:58:41 <esowiki> [[Pxem]] https://esolangs.org/w/index.php?diff=66067&oldid=65944 * YamTokTpaFa * (+96) /* Examples */
15:00:09 <esowiki> [[Vafix]] M https://esolangs.org/w/index.php?diff=66068&oldid=66066 * A * (+165)
15:06:56 -!- Lord_of_Life has quit (Ping timeout: 276 seconds).
15:12:07 -!- Lord_of_Life has joined.
15:12:37 -!- cpressey has quit (Quit: A la prochaine.).
15:21:13 <esowiki> [[Talk:Pxem]] https://esolangs.org/w/index.php?diff=66069&oldid=61433 * YamTokTpaFa * (+535) /* About unclear conditional looping instructions. */ new section
15:29:03 -!- FraterEST has left.
15:46:07 -!- tromp has quit (Remote host closed the connection).
15:46:42 -!- tromp has joined.
15:48:19 -!- craigo has quit (Ping timeout: 268 seconds).
15:53:30 -!- andrewg12 has joined.
15:53:37 <andrewg12> h
16:00:09 <Lykaina> hi andrewg12
16:00:58 <andrewg12> sup
16:02:50 <Lykaina> so used to using linux with it's multiple desktops that when i use windows it gets harder
16:03:26 <Lykaina> keep doing ctrl-alt-left
16:03:47 <Lykaina> which is something different in windows
16:04:12 <andrewg12> i dunno
16:04:15 <andrewg12> i prefer windows
16:04:37 <Lykaina> i prefer linux
16:06:05 <andrewg12> o
16:11:49 <int-e> sigh: https://devtalk.nvidia.com/default/topic/1052743/linux/what-is-nv_queue-and-why-is-it-the-top-process-on-my-system-/ (solution: don't look at top)
16:36:43 -!- FreeFull has joined.
16:48:00 <int-e> Another bad idea: watching open network connections while firefox is open with nothing but a blank page. Wtf are you doing, Firefox?
16:50:27 <int-e> This may be too much to expect, but why can't we make a browser that, when starting up on a blank page, makes zero network connections?
16:51:05 <int-e> zzo38: don't answer that. It's a rhetorical question.
16:53:32 <esowiki> [[Arch]] https://esolangs.org/w/index.php?diff=66070&oldid=64661 * Areallycoolusername * (+0) /* Pop */
16:53:43 <esowiki> [[Arch]] https://esolangs.org/w/index.php?diff=66071&oldid=66070 * Areallycoolusername * (+0) /* Point */
16:53:57 <esowiki> [[Arch]] https://esolangs.org/w/index.php?diff=66072&oldid=66071 * Areallycoolusername * (+0) /* Cells & Split */
16:54:52 <esowiki> [[Arch]] https://esolangs.org/w/index.php?diff=66073&oldid=66072 * Areallycoolusername * (-1) /* Properties */
16:58:50 <esowiki> [[///]] https://esolangs.org/w/index.php?diff=66074&oldid=65775 * CarlosLuna * (+1469) Adding the "Unary to binary conversion" example.
17:06:07 -!- Phantom_Hoover has joined.
17:21:17 <fizzie> int-e: I had a somewhat similar feeling as the nv_queue for kidle_inject.
17:29:37 <andrewg12> hello
17:29:45 <APic> Hi
17:30:55 <andrewg12> what about the language or
17:32:28 <APic> The Languages.
17:37:08 <int-e> meh: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=842292
17:37:42 <int-e> anyway... the most suspicious looking connection was the captive portal detection
17:39:50 <int-e> From here I get detectportal.firefox.com = CNAME detectportal.prod.mozaws.net = CNAME detectportal.firefox.com-v2.edgesuite.net = CNAME a1089.dscd.akamai.net = 46.125.232.9 or 46.125.232.24; these resolve back to 046125232009.public.t-mobile.at and 046125232024.public.t-mobile.at respectively.
17:40:44 <int-e> Which is not the kind of host name I wanted to see my browser connect to unasked.
17:41:18 -!- imode has joined.
17:52:02 -!- imode has quit (Ping timeout: 240 seconds).
17:54:25 <int-e> And wtf is push.services.mozilla.com good for, aside from giving Mozilla information on how long people keep their browsers open?
17:55:03 <andrewg12> nothing
17:55:07 <int-e> (It can be disabled. But this is the kind of thing I want to be opt-in, not opt-out. At which point it's clear that software developers shouldn't bother with it in the first place.)
18:00:26 -!- Sgeo__ has joined.
18:03:59 -!- Sgeo_ has quit (Ping timeout: 268 seconds).
18:16:52 <int-e> ow, libnss is big... I guess I don't want to rebuild that myself just to see what's inside those https connections :/
18:16:59 -!- imode has joined.
18:38:30 <esowiki> [[Special:Log/newusers]] create * Visual-mov * New user account
18:44:22 -!- andrewg12 has quit (Remote host closed the connection).
18:46:17 <fizzie> int-e: Is that the thing the Web Push API on Firefox uses?
18:47:37 <int-e> fizzie: Shouldn't that be up to the particular website?
18:48:12 <fizzie> I don't know, that's why I asked.
18:48:13 <int-e> fizzie: I'd think this is a particular push service just for firefox itself, for bs like studies.
18:48:28 <fizzie> I see.
18:48:43 <int-e> But it's a guess; I have not done any research on it.
18:48:43 <fizzie> Presumably also for pushing updates to their tracking blacklists and that sort of stuff.
18:49:04 <fizzie> https://wiki.mozilla.org/CloudServices is "delightedly whimsical".
18:49:41 <int-e> "Tracking Protection" ... I almost laughed.
18:50:22 <shachaf> int-e: What do you think of this Coyoneda type?
18:50:34 <shachaf> Other than "a fairly odd functor".
18:51:08 <int-e> shachaf: nothing
18:51:36 <shachaf> That makes sense.
18:52:01 <shachaf> I think it's a neat trick that comes up in multiple contexts, not just this Prompt monad.
18:52:43 <int-e> I tend to think of that stuff very concretely, in terms of continuations.
18:53:51 <shachaf> (Obviously it's not a useful trick because it's just Haskell nonsense.)
18:54:16 <shachaf> (Or maybe it is useful? I'm skeptical.)
18:54:49 <int-e> I also wrote "Codensity transformation" the other day but when I did it, I did a CPS transformation with several continuations.
18:57:38 <shachaf> Well, the Codensity transformation is the same as the CPS transformation.
18:57:51 <int-e> I wasn't even conscious of the fact that (a -> r, b -> r) is isomorphic to Either a b -> r (ignoring bottoms)
18:58:07 <int-e> shachaf: Yeah but the latter term makes sense!
18:59:03 <int-e> It's meaningful, it can be decomposed into subconcepts. "Codensity" is just nonsense.
19:01:28 <int-e> Unfortunately the nonsense has taken over the Haskell community. :P
19:08:05 -!- Lykaina has quit (Quit: leaving).
19:10:11 -!- Phantom_Hoover has quit (Read error: Connection reset by peer).
19:22:28 -!- b_jonas has joined.
19:24:48 <b_jonas> Lykania: I recommend https://virtuawin.sourceforge.io/ , a software that lets you use virtual desktops in windows and set up your favourite keyboard shortcuts
19:27:34 <b_jonas> int-e: re browser and connections, https://twitter.com/jonathansampson/status/1166005813548396549 , also try the debian version, it does 20% less connections because debian patched it so that the favicons for the search websites in the search bar menu are installed with the browser rather than downloaded
19:30:19 -!- Phantom_Hoover has joined.
19:33:25 <int-e> fizzie: you were right, this is connected to the service worker push api.
19:33:59 <int-e> b_jonas: I'm using the debian version already.
19:35:12 <int-e> Oh well. Service workers are another thing that has no right of existing in the first place.
19:36:07 <int-e> I guess you could set up your own personal push service and use that to alleviate the tracking concerns.
19:38:59 -!- ArthurStrong has joined.
19:39:49 <b_jonas> int-e: ok, then imagine that backwards. be glad you're not using the vanilla version, because that does 20% more connections.
19:44:17 <b_jonas> the tweet I linked to measures the windows version
19:50:47 <int-e> b_jonas: reading your thread. "[...] is a feature that allows Mozilla to change the default value of a preference for a targeted set of users [...]" is so ominous.
19:52:42 <b_jonas> int-e: it's not my thread
19:54:22 <int-e> ah. okay, then the thread you linked to (the Firefox subthread in particular.)
19:57:02 <int-e> b_jonas: the funny thing about the quote is that its' from Mozilla themselves
19:57:18 <int-e> Or maybe it's worrying rather than funny. Let's call it interesting.
19:57:51 <b_jonas> int-e: that means sometimes they say things about what their browser is doing. what a weird concept for software
20:00:04 <int-e> Ah. "Normandy manages recipes of changes to make to Firefox, including temporary studies, user surveys and controlled rollout of new features."
20:00:20 <int-e> Clearly another thing to disable.
20:00:37 <int-e> I miss Iceweasel.
20:00:56 <int-e> (But maintaining the thing must've been a lot of work.)
20:00:58 <esowiki> [[Echidna]] https://esolangs.org/w/index.php?diff=66075&oldid=66055 * Lykaina * (-90) Updating documentation.
20:01:01 <b_jonas> int-e: debian's firefox is iceweasel. it's the same thing, they just decided it's safe to use the firefox brand name
20:01:11 <b_jonas> and they do disable some firefox features
20:01:23 <int-e> Not enough, apparently.
20:01:35 <b_jonas> yes, admittedly they do have a hard time keeping up with all the stuff that mozilla adds to firefox
20:01:50 <b_jonas> it's not a sw that anyone enjoys to package
20:02:09 <b_jonas> even making it compile is basically impossible
20:04:42 -!- Lykaina has joined.
20:05:27 <int-e> Also, how many IDs does Firefox have for a single profile...
20:05:35 <Lykaina> patched the If/While bug!
20:05:47 <b_jonas> Lykaina: nice
20:06:01 <b_jonas> Lykania: I recommend https://virtuawin.sourceforge.io/ , a software that lets you use virtual desktops in windows and set up your favourite keyboard shortcuts
20:06:18 <Lykaina> thanks
20:08:15 <int-e> Normandy has one. The push service has one. The activity stream of the default new tab page as one. Telemetry has its own id as well, it seems (and why is that even set when Debian disabled the telemetry feature?!).
20:08:22 <int-e> I don't like what I see.
20:08:33 <Lykaina> i rewarded myself by upping the version to 0.03a0
20:13:06 <Lykaina> brb
20:20:54 <int-e> b_jonas: the thing is, the *right* way to disable all these things is to rip out the code in question, which is a maintenance nightmare, and will upset users who have different ideas about usefulness.
20:21:19 <int-e> (For example I'd rip out the Gollum feature ("pocket"), but I imagine some people find it useful.)
20:22:23 <int-e> (This association is a bit unfair because the pocket in question was really Frodo's.)
20:22:26 <b_jonas> int-e: like I said, the original codebase is already almost impossible to build. it may be harder to build than glibc, which is impressive. if they manage to successfully rip out the right pieces, it may become slightly less hard to build, so it may be less of a maintenance nightmare than you think.
20:23:04 <b_jonas> int-e: isn't the pocket at the mozilla servers (frodo) and you the user of pocket are on your computer (gollum)?
20:23:12 <b_jonas> but you want the thing in frodo's pocket?
20:23:18 <b_jonas> well not you int-e, but the people who ise it
20:23:56 <Lykaina> back
20:25:00 <b_jonas> int-e: hmm, how about Han Solo then? https://scifi.stackexchange.com/q/145117/
20:25:17 <int-e> wrong franchise, never cared much about it
20:32:02 -!- imode has quit (Ping timeout: 240 seconds).
20:36:00 <b_jonas> yeah, Gollum is better
20:37:44 <Lykaina> i need to know: what is my language missing?
20:39:42 <Lykaina> it's something opvious, i'm just blanking out on it
20:40:34 <b_jonas> Lykaina: nothing, I think it has all the operations you need. although I haven't checked the modified implementation yet.
20:42:27 <b_jonas> really, it has arithmetic, flow control, interactive IO, and now array access too, that's enough for anything reasonable
20:42:48 <b_jonas> the array access part is important, you can't really do without
20:43:19 <b_jonas> if the interpreter works correctly, then it's a fine general purpose language
20:43:43 <b_jonas> a low-level one that you want to compile to and use a generous library of useful functions, but still
20:46:22 <Lykaina> how do i implement functions?
20:46:45 <b_jonas> Lykaina: do you mean in the interpreter with the existing semantics?
20:47:13 <Lykaina> i mean in the language
20:47:22 <b_jonas> doesn't it already have functions?
20:47:33 <Lykaina> oh, right
20:47:40 <Lykaina> i mean external
20:47:53 <Lykaina> libraries
20:49:10 <b_jonas> do you mean like calling other functions written in echidna? just concatenate the source codes, plus modify the addresses they use in the data space so they don't clash with each other
20:50:27 <Lykaina> thinking the difference between c and standard library
20:50:43 <Lykaina> extensibility
20:51:29 <b_jonas> sure, but echidna already has built-ins for input and output. you can just build functions over that.
20:52:12 <Lykaina> what about time?
20:53:14 -!- Lord_of_Life has quit (Ping timeout: 240 seconds).
20:53:59 -!- Lord_of_Life has joined.
20:58:18 <Lykaina> how neeeded is the current 'G'?
20:59:53 <Lykaina> it's currently printf("%u",mem[addr])
21:00:25 -!- crash_n_burn has joined.
21:13:03 <b_jonas> I think that's convenient for debugging
21:13:21 <Lykaina> good point
21:13:29 <b_jonas> though to make it even more convenient, you could make it output a space first if the previous output operation was also this numeral thing
21:13:42 <b_jonas> that's magic, but probably acceptible magic
21:13:46 <b_jonas> as long as it's documented
21:14:42 -!- FreeFull has quit (Ping timeout: 246 seconds).
21:15:19 <Lykaina> would ':' be good for time?
21:16:12 <Lykaina> cause it's in the middle of every digital clock
21:16:42 -!- FreeFull has joined.
21:17:47 <Lykaina> and i'm thinking about changing M to be more like L
21:17:53 <b_jonas> Lykaina: dunno, if you want a lot of fancy io stuff like that, you could add some dispatch builtin where one argument decides what operation to do, or builtin functions that have the same interface as echidna functions so you call them with N or something, but are not implemented in echidna?
21:20:32 <Lykaina> that could work
21:22:20 <Lykaina> an m that operated like l would require a lot of arguments
21:23:20 <Lykaina> 30
21:23:34 <Lykaina> it can be done
21:23:55 <Lykaina> better than that weird logic code
21:24:39 <Lykaina> well, 6 5-char arguments
21:30:43 -!- imode has joined.
21:38:09 -!- FreeFull has quit.
21:49:37 -!- b_jonas has quit (Remote host closed the connection).
21:52:39 -!- crash_n_burn has quit (Quit: Lost terminal).
22:22:07 -!- craigo has joined.
22:22:08 -!- MDude has quit (Ping timeout: 245 seconds).
22:22:39 <Lykaina> implemented the new M
22:25:33 <Lykaina> c = a AND b : M @c @a @b =0000 =0000 =0000 =FFFF
22:30:16 <imode> so I have a language named SPL, which for control flow has the following primitives: [?;]. `[` is `while(1){`, `?` is `if(pop(&stack)==0){break;}`, `;` is `break;`, and `]` is `}`. this means you can write pretty clean control structures like `if`, `while` loops, etc.
22:31:24 <imode> I've been wondering what kind of reduction you can make to eliminate `?` and `;`.
22:33:14 <imode> https://hastebin.com/eqogofoqef some sample programs. if there was a clean way to integrate the conditional check into the `[` instruction, that'd be neat.
22:33:31 <imode> the latter one is an iterative factorial algorithm.
22:35:36 <imode> it's a stack based language, and all operations reference the top of the stack. similar to Mouse and stuff.
22:36:48 <imode> an `if` statement can be built using the following form: `<condition> [? <body> ;]`. you can build if/else if/else chains via passing boolean flags around on the stack.
22:37:35 <imode> `.` is `drop`, `:` is `pick`, `\` is `roll`, `~` is negate, `=` is equality... etc.
22:37:36 <HackEso> ​/srv/hackeso-code/multibot_cmds/lib/limits: line 5: exec: .`: not found
22:38:18 <imode> a `while` statement can be built as a similar form. trying to condense this into just `[` and `]` while preserving the same "structure" is what I'm struggling with.
22:42:11 -!- imode has quit (Remote host closed the connection).
22:42:56 -!- imode has joined.
22:43:48 <imode> the ability to break arbitrarily is also incredibly useful.
22:49:07 -!- xkapastel has joined.
23:02:49 -!- Phantom_Hoover has quit (Ping timeout: 244 seconds).
23:08:42 <esowiki> [[///]] M https://esolangs.org/w/index.php?diff=66076&oldid=66074 * A * (+32) /* Examples */ Not in this wiki
23:08:58 <arseniiv> imode: why should you eliminate both `?` and `;`?
23:10:16 <imode> bringing it more in line with something like brainfuck.
23:10:34 <imode> just to see if it's possible, mainly.
23:10:52 <arseniiv> anyway [;?] are a find too, at least for me!
23:12:03 <imode> yeah? I dunno. there's always this niggling doubt in the back of my mind in the form of "you can make the instruction set smaller".
23:12:26 <arseniiv> hm, could one set `]` to be the current `?]` ?
23:13:10 <imode> interesting.
23:13:38 <imode> you could eliminate `;` by doing `,?`
23:13:44 <imode> `[? ... ,?]`
23:13:45 <HackEso> ​/srv/hackeso-code/multibot_cmds/lib/limits: line 5: exec: [?: not found
23:14:09 <arseniiv> ah, break seems inexpressible
23:14:22 <imode> the `,` instruction pushes a zero to the stack. all other numerals like 1, 2, 3 ... A, B, C ... F shifts hexadecimal digits into the top of the stack.
23:14:31 <imode> here, lemme bring up the interpreter.
23:14:51 <imode> https://repl.it/repls/UnknownGenerousLifecycle
23:15:05 <arseniiv> ; as <zero>? is pretty obvious, I agree :D
23:15:16 <imode> hehehe.
23:16:00 <imode> see instinctively, I wanna make `[` into `while(pop(&stack)){`
23:16:36 <imode> but that's weird. your conditional check now has to be duplicated _prior_ to the loop, and _after_ the loop body.
23:17:36 <arseniiv> hmm
23:17:42 <imode> if statement is now `<condition> [ <body> ,]`
23:18:10 <imode> but `while` is now `<condition> [ <body> <condition> ]`
23:19:21 <imode> hm.
23:20:58 <arseniiv> is there a sense to make this a post-condition loop do … while(cond)?
23:21:42 <arseniiv> hm now `if` would be a pain instead
23:21:44 <imode> could you still express a precondition loop with a postcondition loop?
23:21:46 <imode> yeah..
23:22:38 <arseniiv> why while is so universal hm. I never thought about that, ever
23:27:57 <imode> I used to tutor CS concepts, and I used to blow my students' minds when I tell them that they can form every single control flow construct from `while`s.
23:28:25 -!- atslash has quit (Quit: This computer has gone to sleep).
23:31:33 <imode> 'while' is universal in the same way that 'jmp' and 'jnz'/'jz' instructions are universal.
23:42:18 <imode> interesting, `[?;]` can be used to construct something like `begin <first> <condition> while <second> repeat
23:42:24 <imode> https://en.wikipedia.org/wiki/Control_flow#Loop_with_test_in_the_middle
23:44:05 <imode> [ <first> <condition> ? <second> ] would be the equivalent code.
23:44:05 <j-bot> imode: |spelling error
23:44:06 <j-bot> imode: | <first> <condition> ? <second> ] would be the equivalent code.
23:44:06 <j-bot> imode: | ^
23:44:13 <imode> whoops, sorry. forget what triggers bots.
23:55:17 <arseniiv> <imode> https://en.wikipedia.org/wiki/Control_flow#Loop_with_test_in_the_middle => very interesting, thanks!
23:55:33 <imode> https://repl.it/repls/AjarFirmSystemresource an example of just using `while` and `break`.
23:55:38 <imode> np!
23:55:54 <arseniiv> a while ago I did thought about named loops and breaks/continues but for some reason not of that loop type
23:56:08 <arseniiv> that entire page will be useful to me, I think
23:56:34 <arseniiv> [ ]
23:56:35 <j-bot> arseniiv: ]
23:56:41 <arseniiv> haha it works
23:56:45 <imode> hah.
23:56:51 <arseniiv> [ [ ] ]
23:56:51 <j-bot> arseniiv: [ ] ]
23:57:31 <Lykaina> [+-]
23:57:44 * arseniiv pretends he knows what he’s doing
23:57:59 <arseniiv> Lykaina: I think there should be at least one space after [
23:58:02 * Lykaina has no clue either
23:58:10 <arseniiv> [ ] [ ]
23:58:11 <j-bot> arseniiv: ] [ ]
23:58:19 <imode> huh, looking at brainfuck algorithms.
23:58:19 <arseniiv> okay I’ll go sleep
23:58:24 <imode> it looks like I'm right.
23:58:52 <imode> 'while (<condition>) { <body> }' results in you requiring to evalute the condition _again_ at the end of the loop if you just use [ and ].
23:59:12 <imode> independent rediscovery!
23:59:19 <arseniiv> ah
23:59:57 <imode> to send you off, here's a recursive factorial function: ,2{:,0=[:?..,1,;][?:,1-,2!*;]},10,2!
←2019-09-09 2019-09-10 2019-09-11→ ↑2019 ↑all