GNU social JP
  • FAQ
  • Login
GNU social JPは日本のGNU socialサーバーです。
Usage/ToS/admin/test/Pleroma FE
  • Public

    • Public
    • Network
    • Groups
    • Featured
    • Popular
    • People

Conversation

Notices

  1. Embed this notice
    Nicolas Martyanoff (galdor@emacs.ch)'s status on Friday, 11-Aug-2023 01:11:37 JST Nicolas Martyanoff Nicolas Martyanoff

    Go 1.21 introducing min and max is good. Go devs finally realized that "c := max(a,b)" is better than:

    c := a
    if b > a {
    c = b
    }

    If we're lucky in a couple years they'll finally understand why so many have been asking for the conditional ternary operator. One can dream.

    In conversation Friday, 11-Aug-2023 01:11:37 JST from emacs.ch permalink
    • Embed this notice
      Louis (louis@emacs.ch)'s status on Friday, 11-Aug-2023 01:11:36 JST Louis Louis
      in reply to

      @galdor The ternary operator is "too brilliant" to understand for mediocre programmers, which is for whom Go was made for:

      "They’re not capable of understanding a brilliant language but we want to use them to build good software." (Rob Pike)

      While Go is a great tool to build good software fast, it doesn't offer opportunities to grow as a programmer.

      In conversation Friday, 11-Aug-2023 01:11:36 JST permalink
      clacke likes this.
    • Embed this notice
      Louis (louis@emacs.ch)'s status on Friday, 11-Aug-2023 01:11:39 JST Louis Louis
      in reply to
      • Pavel Korytov :emacs:

      @sqrtminusone What I mean specifically is that you look at your 100 lines of mostly imperative Go code and think, how can I make that better and more expressive?

      Just to realize that in Go there is rarely such an opportunity, compared to many other languages, that allow you to learn more advanced functional concepts and abstraction patterns over time.

      It took the Go devs 14 years to release a generic min/max function and slice/maps utility functions like Contains. I probably wrote thousands of rudimentary, ugly for loops because those did not exist.

      @galdor

      In conversation Friday, 11-Aug-2023 01:11:39 JST permalink
      clacke likes this.
    • Embed this notice
      Pavel Korytov :emacs: (sqrtminusone@emacs.ch)'s status on Friday, 11-Aug-2023 01:11:42 JST Pavel Korytov :emacs: Pavel Korytov :emacs:
      in reply to
      • Louis

      @louis @galdor What opportunities do you have in mind? Do you mean some abstractions or patterns that are unavailable in Go or...?

      Besides, the road to Perl is paved with good intentions

      In conversation Friday, 11-Aug-2023 01:11:42 JST permalink
    • Embed this notice
      Louis (louis@emacs.ch)'s status on Friday, 11-Aug-2023 01:11:45 JST Louis Louis
      in reply to
      • chsh -s /usr/bin/pwsh $USER

      @a13cui Actually a few months ago, when the Go telemetry shitshow happend, Nim was my choice #1 as a replacement. However, the library ecosystem is dire for serious web backend and database development. That was the reason I abondoned it.

      That was, of course, before I decided to shred my head with Common Lisp 🙂

      In conversation Friday, 11-Aug-2023 01:11:45 JST permalink
      clacke likes this.
    • Embed this notice
      chsh -s /usr/bin/pwsh $USER (a13cui@emacs.ch)'s status on Friday, 11-Aug-2023 01:11:47 JST chsh -s /usr/bin/pwsh $USER chsh -s /usr/bin/pwsh $USER
      in reply to
      • Louis

      @louis if you're willing to go into superior better syntax territory, there's also Nim

      In conversation Friday, 11-Aug-2023 01:11:47 JST permalink
    • Embed this notice
      Louis (louis@emacs.ch)'s status on Friday, 11-Aug-2023 01:11:48 JST Louis Louis
      in reply to
      • chsh -s /usr/bin/pwsh $USER
      • Pavel Korytov :emacs:

      @a13cui There is a middle ground, and in my opinion that is the #V language. It has a version of Go-like syntax that is as easy to comprehend but has all the "missing" features you would miss in Go.

      https://vlang.io/

      I'm not in favour of the V lang, nor do I recommend if for any serious use, but for other reasons.

      @sqrtminusone @galdor

      In conversation Friday, 11-Aug-2023 01:11:48 JST permalink

      Attachments


      1. Invalid filename.
    • Embed this notice
      chsh -s /usr/bin/pwsh $USER (a13cui@emacs.ch)'s status on Friday, 11-Aug-2023 01:11:49 JST chsh -s /usr/bin/pwsh $USER chsh -s /usr/bin/pwsh $USER
      in reply to
      • Louis
      • Pavel Korytov :emacs:

      @louis @sqrtminusone @galdor I'd argue that adding too many new syntax features to "make it more expressive" is also bad and ugly (e.g. Rust or C++)

      In conversation Friday, 11-Aug-2023 01:11:49 JST permalink
    • Embed this notice
      chsh -s /usr/bin/pwsh $USER (a13cui@emacs.ch)'s status on Friday, 11-Aug-2023 01:11:51 JST chsh -s /usr/bin/pwsh $USER chsh -s /usr/bin/pwsh $USER
      in reply to
      • Louis

      @louis ironically, I am using Common Lisp at this very moment for my Tcl LSP :blobcat3c:

      In conversation Friday, 11-Aug-2023 01:11:51 JST permalink
      clacke likes this.

Feeds

  • Activity Streams
  • RSS 2.0
  • Atom
  • Help
  • About
  • FAQ
  • TOS
  • Privacy
  • Source
  • Version
  • Contact

GNU social JP is a social network, courtesy of GNU social JP管理人. It runs on GNU social, version 2.0.2-dev, available under the GNU Affero General Public License.

Creative Commons Attribution 3.0 All GNU social JP content and data are available under the Creative Commons Attribution 3.0 license.