miketmoore / golang-pointers

Playing with pointers (and structs), for learning!

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Playing with Pointers in Go

I was struggling to understand pointers in a Go program that was passing primitive values to and from various struct instances. I realized, while I thought I understood how pointers worked from very basic tutorials and examples, that I probably didn't!

Note

After some comments from @davecheney, I now know I need to understand slices better. I updated the repo per his comments.

Run Tests

go test

Run Code Coverage

go test -coverprofile=coverage.out && go tool cover -func=coverage.out

About

Playing with pointers (and structs), for learning!


Languages

Language:Go 100.0%