Go: Pointer or value receiver ?

Should I use a pointer or a value receiver? A single type should either use pointer or value receivers for all its methods. It’s a matter of consistency and safeness.
Read more →

Go design: Function or method ?

Choosing between a function or a method? That look like a simple question.

Go defines a method as a function with a receiver. What does it mean?

How choose carefully between the two? Let’s dive into this deeper than it seems topic.

Read more →

Messing with slices

For a project I’m working on, I have to manipulate a lot of slices. One of those manipulations is a simple function that creates a new slice filled with the same repeated value.

Being still influenced by other languages I worked with previously, I decided to create a function that I could use on any type.

Read more →

Why I love Go

Go is a pragmatic programming language that allows you to write efficient and easy to maintain code. When other languages add more and more features and become more and more complex, Go strips out many common features like classes and polymorphism. This just makes the code simpler and easier to learn. When I started programming in Go several years ago, I was a little puzzled with all those removed features. But the more, I use it and the bigger the program gets, the more Go make sense.
Read more →