website icon indicating copy to clipboard operation
website copied to clipboard

tour: struct literals in same def/print order

Open crisman opened this issue 1 year ago • 1 comments

The current code on "tour/moretypes/5" ("Struct Literals") seems to be designed to confuse a reader into thinking that contents of 'v1' and 'p' are importantly the same. The contents of both variable's structs have the same int values and then when printed they are (what seems like purposefully, but with no explanation) printed next to each other.

Set the values in 'p' to be different and print the values in the same order they are defined in.

crisman avatar Mar 04 '23 21:03 crisman

This PR (HEAD: 836bd29d44bdf4e84d43128f0e7d11797f3b4e86) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/c/website/+/473475 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off) See the Wiki page for more info

gopherbot avatar Mar 04 '23 21:03 gopherbot