1. 36
  1. 13

    I love the last bullet point under the rationale:

    I found a new hammer(Rust) that I like, and decided to use it on a nail(Go) that I like.

    1. [Comment from banned user removed]

      1. 11

        What would be a “better language than Go” in your opinion?

        1. 4

          A dynamically-typed language would be a better choice IMO. Type-checking is a hindrance in the small-scale coding you do in scripts, and you don’t get the benefit of more efficient machine code since it’s being interpreted anyway.

          1. 2

            I’ve done a lot of dynamic scripting for configuration-y type tasks, and each time I find myself wishing for a statically typed language because it’s too easy to mess something up in a field and quite often it’s a long iteration loop to find your error. Normally the dynamic typing answer is “write more tests”, but (1) that’s always been misguided–why write more tests than you need to considering their expense and (2) doubly so for programs that are just munging configuration.

            1. 2

              tbh I’d prefer something like python + enforced mypy definitions than golang.

              My reasoning differs from @snej, my big problem is that golang, regardless of your opinions about it, is very verbose compared to a language like python or ruby or lua. Honestly, at least from my experience, I think Golang can even be more verbose than a lot of Rust by design. My naïve idea of a goal from having an embedded scripting language in a project is to have a language that is simpler to write in/more succinct than the host language, and Go seems like an ill fit for that.

          2. [Comment from banned user removed]

            1. 13

              Am I the only one who is tired of argument-by-cliche? “Programming in the ‘60s” as well as “billion dollar mistake”. Clearly lots of people are very productive with Go, I think we’re past the point at which we can attribute growth to hype cycle or “Google’s marketing” (no such marketing ever actually existed), etc. At some point we have to admit to ourselves that Go’s success disproves some commonly held beliefs: type systems and other language-level features are not the most important aspects of a programming language’s utility, but rather tooling, ecosystem, approachability, and standardization are more important. I say this as someone who likes ML languages.

              1. [Comment from banned user removed]

                1. 15

                  And I’m tired of people who repeat the same bland criticisms at every opportunity whether or not they’re useful or interesting. Especially when making up a programming language is a lot harder in practice than it appears.

                  1. 2

                    Understandable, but you’re the first to mention popularity in this thread. I said “productive”. And certainly “productivity” is a primary factor of quality if it’s not the whole shebang.

              2. 1

                IMHO most of others.

                1. 1

                  Nothing. ’Tis a perfect language :^)

                  1. 3

                    I see my actually honest question wasn’t understood as such 😅

                2. 3

                  While I also don’t like Go, I still think we need more embedded scripting language implementations in modern languages with expressive type systems rather than in C.

                  Thus my real question is how well is integration with the host? Is there type-safe embedding and projection between the host and the goscript program it’s running?

                  That’s the selling point of (shameless plug) Lua-ML for example.

                3. 0

                  Language: the biggest missing part is goroutine/channel/defer, supports most features, some of them are, probably for the first time, implemented in a script language :), like Pointer/Interface/Struct.

                  Nothing to see here.