{"action":"created","issue":{"url":"https://api.github.com/repos/golang/protobuf/issues/14","labels_url":"https://api.github.com/repos/golang/protobuf/issues/14/labels{/name}","comments_url":"https://api.github.com/repos/golang/protobuf/issues/14/comments","events_url":"https://api.github.com/repos/golang/protobuf/issues/14/events","html_url":"https://github.com/golang/protobuf/issues/14","id":59782259,"number":14,"title":"Generation of repeated structs","user":{"login":"primeMover2011","id":839260,"avatar_url":"https://avatars.githubusercontent.com/u/839260?v=3","gravatar_id":"","url":"https://api.github.com/users/primeMover2011","html_url":"https://github.com/primeMover2011","followers_url":"https://api.github.com/users/primeMover2011/followers","following_url":"https://api.github.com/users/primeMover2011/following{/other_user}","gists_url":"https://api.github.com/users/primeMover2011/gists{/gist_id}","starred_url":"https://api.github.com/users/primeMover2011/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/primeMover2011/subscriptions","organizations_url":"https://api.github.com/users/primeMover2011/orgs","repos_url":"https://api.github.com/users/primeMover2011/repos","events_url":"https://api.github.com/users/primeMover2011/events{/privacy}","received_events_url":"https://api.github.com/users/primeMover2011/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-03-04T10:59:34Z","updated_at":"2015-03-04T23:14:21Z","closed_at":"2015-03-04T23:14:21Z","body":"From  http://golang.org/doc/effective_go.html#slices\r\n\r\n> Slices hold references to an underlying array, \r\n> and if you assign one slice to another, \r\n> both refer to the same array.\r\n\r\nWhen I generate the following proto holding the following messages\r\n\r\n    message AmessageWithAString\r\n    {\r\n\t    required string aString = 1;\r\n    }\r\n\r\n    message RepeatedString \r\n    {\r\n\t    repeated AmessageWithAString PointerToSlice = 1;\r\n    }\r\n\t\r\nthe generator generates \r\n\r\n    type RepeatedString struct {\r\n    \tPointerToSlice   []*AmessageWithAString `protobuf:\"bytes,1,rep\" json:\"PointerToSlice,omitempty\"`\r\n    \tXXX_unrecognized []byte                 `json:\"-\"`\r\n    }\r\n\r\nshouldn't it generate\r\n**PointerToSlice   []AmessageWithAString**\r\ninstead?"},"comment":{"url":"https://api.github.com/repos/golang/protobuf/issues/comments/77271716","html_url":"https://github.com/golang/protobuf/issues/14#issuecomment-77271716","issue_url":"https://api.github.com/repos/golang/protobuf/issues/14","id":77271716,"user":{"login":"dsymonds","id":31506,"avatar_url":"https://avatars.githubusercontent.com/u/31506?v=3","gravatar_id":"","url":"https://api.github.com/users/dsymonds","html_url":"https://github.com/dsymonds","followers_url":"https://api.github.com/users/dsymonds/followers","following_url":"https://api.github.com/users/dsymonds/following{/other_user}","gists_url":"https://api.github.com/users/dsymonds/gists{/gist_id}","starred_url":"https://api.github.com/users/dsymonds/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dsymonds/subscriptions","organizations_url":"https://api.github.com/users/dsymonds/orgs","repos_url":"https://api.github.com/users/dsymonds/repos","events_url":"https://api.github.com/users/dsymonds/events{/privacy}","received_events_url":"https://api.github.com/users/dsymonds/received_events","type":"User","site_admin":false},"created_at":"2015-03-04T23:14:21Z","updated_at":"2015-03-04T23:14:21Z","body":"It's working as intended. You need pointers to messages almost everywhere else."}}