{"action":"opened","issue":{"url":"https://api.github.com/repos/dominikh/go-simple/issues/20","repository_url":"https://api.github.com/repos/dominikh/go-simple","labels_url":"https://api.github.com/repos/dominikh/go-simple/issues/20/labels{/name}","comments_url":"https://api.github.com/repos/dominikh/go-simple/issues/20/comments","events_url":"https://api.github.com/repos/dominikh/go-simple/issues/20/events","html_url":"https://github.com/dominikh/go-simple/issues/20","id":168626092,"number":20,"title":"False \"should use copy() instead of a loop\" positive on copy from slice to map","user":{"login":"hectorj","id":2427959,"avatar_url":"https://avatars.githubusercontent.com/u/2427959?v=3","gravatar_id":"","url":"https://api.github.com/users/hectorj","html_url":"https://github.com/hectorj","followers_url":"https://api.github.com/users/hectorj/followers","following_url":"https://api.github.com/users/hectorj/following{/other_user}","gists_url":"https://api.github.com/users/hectorj/gists{/gist_id}","starred_url":"https://api.github.com/users/hectorj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hectorj/subscriptions","organizations_url":"https://api.github.com/users/hectorj/orgs","repos_url":"https://api.github.com/users/hectorj/repos","events_url":"https://api.github.com/users/hectorj/events{/privacy}","received_events_url":"https://api.github.com/users/hectorj/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-08-01T11:36:28Z","updated_at":"2016-08-01T11:36:28Z","closed_at":null,"body":"Hi !\r\nHere is an example of code triggering a false-positive:\r\n\r\n```\r\nmySlice := []string{\"testValue\"}\r\nmyMap := make(map[int]string, len(mySlice))\r\nfor k,v := range mySlice {\r\n        myMap[k] = v\r\n}\r\n```\r\n\r\nUsing a freshly `go get -u`'d version of gosimple, I get the \"should use copy() instead of a loop\" on this.\r\n\r\nBut `copy()` cannot be used with a map."}}
{"actor":{"display_login":"hectorj"}}