1. 15
  1.  

    1. 16

      The title of this article is, in my opinion, in poor taste. The article makes almost no mention of it, and I was expecting an article related to its title, and not an explanation of the author’s programming language’s implementation of algebraic effects (or at least a link between the two that was more than a couple of sentences.)

      There also isn’t an explanation as to why it would be computers and not the program (or here, the programming language.) It’s an important and interesting discussion, but it’s used only to bait-and-switch; and in particular, by using a variant of the known sentence that removes all responsibility from the program’s authors.

      1. 4

        For the confused (like myself until a moment ago), this article used to be called “Programs don’t kill people, computers do”.

        1. 2

          The article makes almost no mention of it

          I think you make a fair point here. I’ve been iterating on the post for a while and hadn’t paid attention to the fact the last edit removed any mention. The cliche that side effects might “launch the missiles” is referenced only in the images. There is also no point in an explainer article having slight reference to “in jokes”.

          by using a variant of the known sentence that removes all responsibility from the program’s authors.

          This is an interesting thought. I really only wanted to emphasize that programs only act on input and have no “real” knowledge of the outside world. I’m hadn’t been making commentary on the program authors responsibility. Though as you correctly indicate also an interesting discussion.

          I will think of an alternative title. “Explaining algebraic effects” might be all that’s needed.

          1. 3

            It would be better without the clickbait title. Maybe fewer would read it, but those who do will take it more seriously. There are genuine ethical issues involved in authoring software; let’s not cheapen them.

            1. 1

              The clique that side effects might “launch the missiles”

              I think you mean cliche.

              1. 1

                indeed I do thank you.

          2. 9

            How about “Functions don’t kill people; side effects do”?

            I liked the article (title aside) but wished there were some more details about how effects work.

            You alluded to effects being part of a function’s type signature. It looks as though this is invisible in the source code; the compiler sees an effect being performed and annotates the function with it. If a function calls another that has an effect (without a “handle” clause) the compiler tags it with the effect too, and so on.

            Is it possible to declare a function’s effects explicitly, so the compiler can issue an error if it calls something that has an undeclared effect? Otherwise it sounds like adding an effect to a lower level function “taints” everything above it in the call tree with that effect, which could have unpleasant consequences.

            1. 2

              How effects work is at least a few different things.

              • How the runtime works, I think this is closest to conceptually what they are. And what I was trying to explain here.
              • How they are typed, not what I was explaining here but if so maybe I shouldn’t mention types at all in that case. Note effects can exist in untyped languages.
              • How effects can be handled, a further article I have in draft.

              So it seems like I should try and write about the type system before getting on to handlers.

              Not in EYG there is no possibility to declare any types they are only ever inferred. But in the general case effects end up in a function type signature so if you can annotate a function that annotation should include the effects.

              1. 1

                I agree. I saw EYG has effects described in the docs, but it’s only 2 paragraaphs and I don’t quite get it.

              2. 4

                I enjoyed the article, but the name of the article wasn’t very informative.

                1. 3

                  Renamed to “Algebraic effects are a functional approach to manage side effects”

                  1. 1

                    Thanks, but the old title is still being shown on the front page. Maybe ping @pushcx for help?

                    1. 1

                      It can be changed by users if enough people suggest it.