matryer/goblueprints

Isn't the implicit change between Chapter1 and Chapter2 confusing?

Closed this issue · 1 comments

func main() {
	var addr = flag.String("addr", ":8080", "The addr of the application.")
	flag.Parse() // parse the flags

Page 18 uses "addr", but 36 The page uses "host".
I find it difficult to understand, but what about?

var host = flag.String("host", ":8080", "The host of the application.")
func main() {
	flag.Parse() // parse the flags

I'm sorry if it has already appeared.

Hey @Rererr thanks for this - It wasn't deliberate but shows that there are often many ways to express the same things.