
I came across this line of code in a GoLang code base today:
func (us UserStore) GetUsers(w http.ResponseWriter, r *http.Request) { // implementation // making use of `us` object/variable}
and my honest reaction was ... humm!
To me, this wasn't new but also something that I haven't paid much attention to either. I had just realized that the variable us is actually not in the argument list.
If we take look at the above snippet, the us variable is being passed separately to the functio...
Published on December 10, 2023 02:43