{"action":"created","comment":{"url":"https://api.github.com/repos/gonum/matrix/pulls/comments/35597329","id":35597329,"diff_hunk":"@@ -124,12 +124,21 @@ func (m *Dense) Norm(ord float64) float64 {\n func (m *Dense) Add(a, b Matrix) {\n \tar, ac := a.Dims()\n \tbr, bc := b.Dims()\n-\n \tif ar != br || ac != bc {\n \t\tpanic(ErrShape)\n \t}\n \n+\taMat, _ := untranspose(a)\n+\tbMat, _ := untranspose(b)\n \tm.reuseAs(ar, ac)\n+\tvar f func()","path":"mat64/dense_arithmetic.go","position":12,"original_position":12,"commit_id":"7df3548593e62122762c5c87a4d05b60eb472089","original_commit_id":"7df3548593e62122762c5c87a4d05b60eb472089","user":{"login":"kortschak","id":275221,"avatar_url":"https://avatars.githubusercontent.com/u/275221?v=3","gravatar_id":"","url":"https://api.github.com/users/kortschak","html_url":"https://github.com/kortschak","followers_url":"https://api.github.com/users/kortschak/followers","following_url":"https://api.github.com/users/kortschak/following{/other_user}","gists_url":"https://api.github.com/users/kortschak/gists{/gist_id}","starred_url":"https://api.github.com/users/kortschak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kortschak/subscriptions","organizations_url":"https://api.github.com/users/kortschak/orgs","repos_url":"https://api.github.com/users/kortschak/repos","events_url":"https://api.github.com/users/kortschak/events{/privacy}","received_events_url":"https://api.github.com/users/kortschak/received_events","type":"User","site_admin":false},"body":"Much better.\n","created_at":"2015-07-27T22:54:01Z","updated_at":"2015-07-27T22:54:01Z","html_url":"https://github.com/gonum/matrix/pull/157#discussion_r35597329","pull_request_url":"https://api.github.com/repos/gonum/matrix/pulls/157","_links":{"self":{"href":"https://api.github.com/repos/gonum/matrix/pulls/comments/35597329"},"html":{"href":"https://github.com/gonum/matrix/pull/157#discussion_r35597329"},"pull_request":{"href":"https://api.github.com/repos/gonum/matrix/pulls/157"}}},"pull_request":{"url":"https://api.github.com/repos/gonum/matrix/pulls/157","id":40219595,"html_url":"https://github.com/gonum/matrix/pull/157","diff_url":"https://github.com/gonum/matrix/pull/157.diff","patch_url":"https://github.com/gonum/matrix/pull/157.patch","issue_url":"https://api.github.com/repos/gonum/matrix/issues/157","number":157,"state":"open","locked":false,"title":"Fixtestadd","user":{"login":"btracey","id":3680859,"avatar_url":"https://avatars.githubusercontent.com/u/3680859?v=3","gravatar_id":"","url":"https://api.github.com/users/btracey","html_url":"https://github.com/btracey","followers_url":"https://api.github.com/users/btracey/followers","following_url":"https://api.github.com/users/btracey/following{/other_user}","gists_url":"https://api.github.com/users/btracey/gists{/gist_id}","starred_url":"https://api.github.com/users/btracey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/btracey/subscriptions","organizations_url":"https://api.github.com/users/btracey/orgs","repos_url":"https://api.github.com/users/btracey/repos","events_url":"https://api.github.com/users/btracey/events{/privacy}","received_events_url":"https://api.github.com/users/btracey/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-07-17T10:42:17Z","updated_at":"2015-07-27T22:54:01Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1caea69a6684b7759bea2a75ad6fd60b9827b162","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/gonum/matrix/pulls/157/commits","review_comments_url":"https://api.github.com/repos/gonum/matrix/pulls/157/comments","review_comment_url":"https://api.github.com/repos/gonum/matrix/pulls/comments{/number}","comments_url":"https://api.github.com/repos/gonum/matrix/issues/157/comments","statuses_url":"https://api.github.com/repos/gonum/matrix/statuses/7df3548593e62122762c5c87a4d05b60eb472089","head":{"label":"gonum:fixtestadd","ref":"fixtestadd","sha":"7df3548593e62122762c5c87a4d05b60eb472089","user":{"login":"gonum","id":3771091,"avatar_url":"https://avatars.githubusercontent.com/u/3771091?v=3","gravatar_id":"","url":"https://api.github.com/users/gonum","html_url":"https://github.com/gonum","followers_url":"https://api.github.com/users/gonum/followers","following_url":"https://api.github.com/users/gonum/following{/other_user}","gists_url":"https://api.github.com/users/gonum/gists{/gist_id}","starred_url":"https://api.github.com/users/gonum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gonum/subscriptions","organizations_url":"https://api.github.com/users/gonum/orgs","repos_url":"https://api.github.com/users/gonum/repos","events_url":"https://api.github.com/users/gonum/events{/privacy}","received_events_url":"https://api.github.com/users/gonum/received_events","type":"Organization","site_admin":false},"repo":{"id":8569918,"name":"matrix","full_name":"gonum/matrix","owner":{"login":"gonum","id":3771091,"avatar_url":"https://avatars.githubusercontent.com/u/3771091?v=3","gravatar_id":"","url":"https://api.github.com/users/gonum","html_url":"https://github.com/gonum","followers_url":"https://api.github.com/users/gonum/followers","following_url":"https://api.github.com/users/gonum/following{/other_user}","gists_url":"https://api.github.com/users/gonum/gists{/gist_id}","starred_url":"https://api.github.com/users/gonum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gonum/subscriptions","organizations_url":"https://api.github.com/users/gonum/orgs","repos_url":"https://api.github.com/users/gonum/repos","events_url":"https://api.github.com/users/gonum/events{/privacy}","received_events_url":"https://api.github.com/users/gonum/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gonum/matrix","description":"Matrix packages for the Go language.","fork":false,"url":"https://api.github.com/repos/gonum/matrix","forks_url":"https://api.github.com/repos/gonum/matrix/forks","keys_url":"https://api.github.com/repos/gonum/matrix/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gonum/matrix/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gonum/matrix/teams","hooks_url":"https://api.github.com/repos/gonum/matrix/hooks","issue_events_url":"https://api.github.com/repos/gonum/matrix/issues/events{/number}","events_url":"https://api.github.com/repos/gonum/matrix/events","assignees_url":"https://api.github.com/repos/gonum/matrix/assignees{/user}","branches_url":"https://api.github.com/repos/gonum/matrix/branches{/branch}","tags_url":"https://api.github.com/repos/gonum/matrix/tags","blobs_url":"https://api.github.com/repos/gonum/matrix/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gonum/matrix/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gonum/matrix/git/refs{/sha}","trees_url":"https://api.github.com/repos/gonum/matrix/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gonum/matrix/statuses/{sha}","languages_url":"https://api.github.com/repos/gonum/matrix/languages","stargazers_url":"https://api.github.com/repos/gonum/matrix/stargazers","contributors_url":"https://api.github.com/repos/gonum/matrix/contributors","subscribers_url":"https://api.github.com/repos/gonum/matrix/subscribers","subscription_url":"https://api.github.com/repos/gonum/matrix/subscription","commits_url":"https://api.github.com/repos/gonum/matrix/commits{/sha}","git_commits_url":"https://api.github.com/repos/gonum/matrix/git/commits{/sha}","comments_url":"https://api.github.com/repos/gonum/matrix/comments{/number}","issue_comment_url":"https://api.github.com/repos/gonum/matrix/issues/comments{/number}","contents_url":"https://api.github.com/repos/gonum/matrix/contents/{+path}","compare_url":"https://api.github.com/repos/gonum/matrix/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gonum/matrix/merges","archive_url":"https://api.github.com/repos/gonum/matrix/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gonum/matrix/downloads","issues_url":"https://api.github.com/repos/gonum/matrix/issues{/number}","pulls_url":"https://api.github.com/repos/gonum/matrix/pulls{/number}","milestones_url":"https://api.github.com/repos/gonum/matrix/milestones{/number}","notifications_url":"https://api.github.com/repos/gonum/matrix/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gonum/matrix/labels{/name}","releases_url":"https://api.github.com/repos/gonum/matrix/releases{/id}","created_at":"2013-03-05T01:59:12Z","updated_at":"2015-07-03T19:17:43Z","pushed_at":"2015-07-26T15:38:15Z","git_url":"git://github.com/gonum/matrix.git","ssh_url":"git@github.com:gonum/matrix.git","clone_url":"https://github.com/gonum/matrix.git","svn_url":"https://github.com/gonum/matrix","homepage":"","size":2180,"stargazers_count":127,"watchers_count":127,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":20,"mirror_url":null,"open_issues_count":21,"forks":20,"open_issues":21,"watchers":127,"default_branch":"master"}},"base":{"label":"gonum:master","ref":"master","sha":"50ccfc94c575d789a328ecd1d9dd60714572ddf2","user":{"login":"gonum","id":3771091,"avatar_url":"https://avatars.githubusercontent.com/u/3771091?v=3","gravatar_id":"","url":"https://api.github.com/users/gonum","html_url":"https://github.com/gonum","followers_url":"https://api.github.com/users/gonum/followers","following_url":"https://api.github.com/users/gonum/following{/other_user}","gists_url":"https://api.github.com/users/gonum/gists{/gist_id}","starred_url":"https://api.github.com/users/gonum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gonum/subscriptions","organizations_url":"https://api.github.com/users/gonum/orgs","repos_url":"https://api.github.com/users/gonum/repos","events_url":"https://api.github.com/users/gonum/events{/privacy}","received_events_url":"https://api.github.com/users/gonum/received_events","type":"Organization","site_admin":false},"repo":{"id":8569918,"name":"matrix","full_name":"gonum/matrix","owner":{"login":"gonum","id":3771091,"avatar_url":"https://avatars.githubusercontent.com/u/3771091?v=3","gravatar_id":"","url":"https://api.github.com/users/gonum","html_url":"https://github.com/gonum","followers_url":"https://api.github.com/users/gonum/followers","following_url":"https://api.github.com/users/gonum/following{/other_user}","gists_url":"https://api.github.com/users/gonum/gists{/gist_id}","starred_url":"https://api.github.com/users/gonum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gonum/subscriptions","organizations_url":"https://api.github.com/users/gonum/orgs","repos_url":"https://api.github.com/users/gonum/repos","events_url":"https://api.github.com/users/gonum/events{/privacy}","received_events_url":"https://api.github.com/users/gonum/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gonum/matrix","description":"Matrix packages for the Go language.","fork":false,"url":"https://api.github.com/repos/gonum/matrix","forks_url":"https://api.github.com/repos/gonum/matrix/forks","keys_url":"https://api.github.com/repos/gonum/matrix/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gonum/matrix/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gonum/matrix/teams","hooks_url":"https://api.github.com/repos/gonum/matrix/hooks","issue_events_url":"https://api.github.com/repos/gonum/matrix/issues/events{/number}","events_url":"https://api.github.com/repos/gonum/matrix/events","assignees_url":"https://api.github.com/repos/gonum/matrix/assignees{/user}","branches_url":"https://api.github.com/repos/gonum/matrix/branches{/branch}","tags_url":"https://api.github.com/repos/gonum/matrix/tags","blobs_url":"https://api.github.com/repos/gonum/matrix/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gonum/matrix/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gonum/matrix/git/refs{/sha}","trees_url":"https://api.github.com/repos/gonum/matrix/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gonum/matrix/statuses/{sha}","languages_url":"https://api.github.com/repos/gonum/matrix/languages","stargazers_url":"https://api.github.com/repos/gonum/matrix/stargazers","contributors_url":"https://api.github.com/repos/gonum/matrix/contributors","subscribers_url":"https://api.github.com/repos/gonum/matrix/subscribers","subscription_url":"https://api.github.com/repos/gonum/matrix/subscription","commits_url":"https://api.github.com/repos/gonum/matrix/commits{/sha}","git_commits_url":"https://api.github.com/repos/gonum/matrix/git/commits{/sha}","comments_url":"https://api.github.com/repos/gonum/matrix/comments{/number}","issue_comment_url":"https://api.github.com/repos/gonum/matrix/issues/comments{/number}","contents_url":"https://api.github.com/repos/gonum/matrix/contents/{+path}","compare_url":"https://api.github.com/repos/gonum/matrix/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gonum/matrix/merges","archive_url":"https://api.github.com/repos/gonum/matrix/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gonum/matrix/downloads","issues_url":"https://api.github.com/repos/gonum/matrix/issues{/number}","pulls_url":"https://api.github.com/repos/gonum/matrix/pulls{/number}","milestones_url":"https://api.github.com/repos/gonum/matrix/milestones{/number}","notifications_url":"https://api.github.com/repos/gonum/matrix/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gonum/matrix/labels{/name}","releases_url":"https://api.github.com/repos/gonum/matrix/releases{/id}","created_at":"2013-03-05T01:59:12Z","updated_at":"2015-07-03T19:17:43Z","pushed_at":"2015-07-26T15:38:15Z","git_url":"git://github.com/gonum/matrix.git","ssh_url":"git@github.com:gonum/matrix.git","clone_url":"https://github.com/gonum/matrix.git","svn_url":"https://github.com/gonum/matrix","homepage":"","size":2180,"stargazers_count":127,"watchers_count":127,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":20,"mirror_url":null,"open_issues_count":21,"forks":20,"open_issues":21,"watchers":127,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/gonum/matrix/pulls/157"},"html":{"href":"https://github.com/gonum/matrix/pull/157"},"issue":{"href":"https://api.github.com/repos/gonum/matrix/issues/157"},"comments":{"href":"https://api.github.com/repos/gonum/matrix/issues/157/comments"},"review_comments":{"href":"https://api.github.com/repos/gonum/matrix/pulls/157/comments"},"review_comment":{"href":"https://api.github.com/repos/gonum/matrix/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/gonum/matrix/pulls/157/commits"},"statuses":{"href":"https://api.github.com/repos/gonum/matrix/statuses/7df3548593e62122762c5c87a4d05b60eb472089"}}}}