What's Coming in Go 1.22 - Daniel Martí - November Gophers 2023

แชร์
ฝัง
  • เผยแพร่เมื่อ 27 ส.ค. 2024
  • A summary of all language, toolchain, standard library, and performance changes coming to Go 1.22, due in Feburary 2024.
    Presented at November Gophers 2023

ความคิดเห็น • 23

  • @NotSexualAtAll
    @NotSexualAtAll 7 หลายเดือนก่อน +2

    Really great talk. Not only in content but in presentation. You're an excellent public speaker and this was awesome.

  • @md2704
    @md2704 8 หลายเดือนก่อน +19

    Great talk! I'm falling more and more in love with the language. Hopefully they add enums soon.

    • @dermuschelschluerfer
      @dermuschelschluerfer 8 หลายเดือนก่อน +2

      you already have const with iota operator for that

    • @angeloceccato
      @angeloceccato 8 หลายเดือนก่อน +3

      Enums like Discrimination Unions are really tasty but I don't think they're coming anytime soon

    • @perc-ai
      @perc-ai 8 หลายเดือนก่อน +1

      Need switch

    • @nixoncode
      @nixoncode 8 หลายเดือนก่อน +1

      don't use go, clearly!

  • @billhammond6209
    @billhammond6209 6 หลายเดือนก่อน

    Great!

  • @Alberto_Cavalcante
    @Alberto_Cavalcante 8 หลายเดือนก่อน +1

    Great presentation. Thanks for sharing!

  • @TorstenBronger
    @TorstenBronger 8 หลายเดือนก่อน +10

    I find func iterators difficult to explain and just syntactic sugar. It is sad that the people in the Go team who have kept Go boring become fewer and fewer.

    • @bebobauomy1265
      @bebobauomy1265 7 หลายเดือนก่อน

      If it could be fun and simple in the Sametime, why not? For really Go is ugly we will not going to lose anything if it is more fun to use.

    • @TorstenBronger
      @TorstenBronger 7 หลายเดือนก่อน +1

      I don’t find func iterators simple.

    • @bebobauomy1265
      @bebobauomy1265 7 หลายเดือนก่อน

      @@TorstenBronger
      Sorry I was taking in general, the language itself still so mush simple compared to other languages, and yes func iterations are not simple, I feel like they are trying to put everything inside a small box, instead of making more keywords, they are just pushing any new feature inside what they have already, but the language sill simple and ugly tho.

    • @angeloceccato
      @angeloceccato 7 หลายเดือนก่อน

      I think the confusion caused by the lack of a standard way of iterating is more problematic. Ultimately, iterators are a well-known feature in any other ecosystem, i think worth the trade-off...

    • @TorstenBronger
      @TorstenBronger 7 หลายเดือนก่อน +1

      @@angeloceccato One of my problems is that I basically know iterators from Python and understood them immediately, whereas the realisation in Go is still magic to me.

  • @nixoncode
    @nixoncode 8 หลายเดือนก่อน +1

    loved the talk

  • @andrewdunbar828
    @andrewdunbar828 8 หลายเดือนก่อน

    I thinked he said "freezed". "Intuhgers" does indeed sound really weird.

  • @wWvwvV
    @wWvwvV 8 หลายเดือนก่อน

    I still don't understand why a nil interface might not be equal to nil. There must be a reason to handle it like that. In Go there are pointers pointing to 0 but also inbuilt data structures also containing pointers like structs like strings, maps, slices. A string cant be nil, but maps and slices can. An interface is a struct. It has a pointer to it's value and a type. If there is no value but a known type, the interface is not nil anymore. The value of the interface is nil. the type is known. This makes the interface not nil. And if you ask the interface for the value it says nil and causes a panic. You have to know that, especially in error handling where 'error' is an interface.

  • @wWvwvV
    @wWvwvV 8 หลายเดือนก่อน

    Coroutines in Go sound beautiful. It has nothing to do with threads. It's a function with internal state that you can call over and over to give results. Like a generator in Python.
    One of the misuses in Go was/still is using channels to give back results. A channel does messenging between threads. Don't use channels in any high performance algorithms. They need two threads.
    What I can also say. Don't use Go maps in an API.
    APIs that only use arrays and slices are much more simple than with maps.

  • @Thoer
    @Thoer 7 หลายเดือนก่อน +2

    `slices.Concat` feels weird. why is it better than `append(slice1, slice2...)`? and if it's not, why have two ways of doing this?

    • @pudgebooster
      @pudgebooster 7 หลายเดือนก่อน

      Backward compatibility. If there is a better way to do something they will add it but will keep the old way

    • @Thoer
      @Thoer 7 หลายเดือนก่อน +2

      @@pudgebooster seems like my own answer is not visible for some reason. `slices.Concat` can take a variable number of slices, `append` will only concatenate 2 slices.

  • @alihammadshah
    @alihammadshah 7 หลายเดือนก่อน

    stop fkn with gopath, fkn hell man go is becoming like node as time passes. gone are the days when you could create a directory in gopath and start writing. go modules should have been made around gopath, this is fkd up, didn't they promise backward compatibility for ever.