{"action":"created","comment":{"url":"https://api.github.com/repos/github/linguist/pulls/comments/113977235","pull_request_review_id":35413164,"id":113977235,"diff_hunk":"@@ -68,6 +68,20 @@ def call(data)\n     # Common heuristics\n     ObjectiveCRegex = /^\\s*(@(interface|class|protocol|property|end|synchronised|selector|implementation)\\b|#import\\s+.+\\.h[\">])/\n \n+\n+    CPPRegexType0 = /^\\s*#.*include.*<(stdint|cstdint|string|vector|map|list|array|bitset|queue|stack|forward_list|unordered_map|unordered_set|(i|o|io)stream).*>/","path":"lib/linguist/heuristics.rb","position":5,"original_position":5,"commit_id":"a351f16af0da8c5066faf631313b4e064af03423","original_commit_id":"a351f16af0da8c5066faf631313b4e064af03423","user":{"login":"rafael-santiago","id":7308777,"avatar_url":"https://avatars3.githubusercontent.com/u/7308777?v=3","gravatar_id":"","url":"https://api.github.com/users/rafael-santiago","html_url":"https://github.com/rafael-santiago","followers_url":"https://api.github.com/users/rafael-santiago/followers","following_url":"https://api.github.com/users/rafael-santiago/following{/other_user}","gists_url":"https://api.github.com/users/rafael-santiago/gists{/gist_id}","starred_url":"https://api.github.com/users/rafael-santiago/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rafael-santiago/subscriptions","organizations_url":"https://api.github.com/users/rafael-santiago/orgs","repos_url":"https://api.github.com/users/rafael-santiago/repos","events_url":"https://api.github.com/users/rafael-santiago/events{/privacy}","received_events_url":"https://api.github.com/users/rafael-santiago/received_events","type":"User","site_admin":false},"body":"Hello, @Alhadis \r\n\r\nSo just confirming:\r\n\r\nDid you mean split the regexes over multiple lines:\r\n\r\n```\r\n%r {\r\n(...)\r\n}x\r\n\r\n```\r\nor suggested capturing groups?\r\n\r\nI think that use capturing groups could obfuscate the code and lead to misunderstandings in the future besides the performance cost.","created_at":"2017-04-28T17:11:15Z","updated_at":"2017-04-28T17:11:15Z","html_url":"https://github.com/github/linguist/pull/3585#discussion_r113977235","pull_request_url":"https://api.github.com/repos/github/linguist/pulls/3585","_links":{"self":{"href":"https://api.github.com/repos/github/linguist/pulls/comments/113977235"},"html":{"href":"https://github.com/github/linguist/pull/3585#discussion_r113977235"},"pull_request":{"href":"https://api.github.com/repos/github/linguist/pulls/3585"}}},"pull_request":{"url":"https://api.github.com/repos/github/linguist/pulls/3585","id":118061417,"html_url":"https://github.com/github/linguist/pull/3585","diff_url":"https://github.com/github/linguist/pull/3585.diff","patch_url":"https://github.com/github/linguist/pull/3585.patch","issue_url":"https://api.github.com/repos/github/linguist/issues/3585","number":3585,"state":"open","locked":false,"title":"Fine-tuning on heuristics related with the issue#3568 (C/C++ header files)","user":{"login":"rafael-santiago","id":7308777,"avatar_url":"https://avatars3.githubusercontent.com/u/7308777?v=3","gravatar_id":"","url":"https://api.github.com/users/rafael-santiago","html_url":"https://github.com/rafael-santiago","followers_url":"https://api.github.com/users/rafael-santiago/followers","following_url":"https://api.github.com/users/rafael-santiago/following{/other_user}","gists_url":"https://api.github.com/users/rafael-santiago/gists{/gist_id}","starred_url":"https://api.github.com/users/rafael-santiago/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rafael-santiago/subscriptions","organizations_url":"https://api.github.com/users/rafael-santiago/orgs","repos_url":"https://api.github.com/users/rafael-santiago/repos","events_url":"https://api.github.com/users/rafael-santiago/events{/privacy}","received_events_url":"https://api.github.com/users/rafael-santiago/received_events","type":"User","site_admin":false},"body":"Hi there,\r\n\r\nI have done some improvements on disambiguation for \".h\" files trying to solve this [issue](https://github.com/github/linguist/issues/3568). \r\n\r\nI also moved one file from \"samples/C++/Field.h\" to \"samples/C/Field.h\", if you analyse this file isolated, it is more like an C source file or at least it is an inconclusive sample.\r\n\r\nI think that cases like the old \"sample/C++/Field.h\" should be solved with a mechanism like a white list but I do not know the ``Linguist`` source code well enough to know if it would be really possible. ","created_at":"2017-04-28T00:59:45Z","updated_at":"2017-04-28T17:11:15Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2d77e83bae8eef2838175df3b6ac14d7541b748e","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/github/linguist/pulls/3585/commits","review_comments_url":"https://api.github.com/repos/github/linguist/pulls/3585/comments","review_comment_url":"https://api.github.com/repos/github/linguist/pulls/comments{/number}","comments_url":"https://api.github.com/repos/github/linguist/issues/3585/comments","statuses_url":"https://api.github.com/repos/github/linguist/statuses/a351f16af0da8c5066faf631313b4e064af03423","head":{"label":"rafael-santiago:master","ref":"master","sha":"a351f16af0da8c5066faf631313b4e064af03423","user":{"login":"rafael-santiago","id":7308777,"avatar_url":"https://avatars3.githubusercontent.com/u/7308777?v=3","gravatar_id":"","url":"https://api.github.com/users/rafael-santiago","html_url":"https://github.com/rafael-santiago","followers_url":"https://api.github.com/users/rafael-santiago/followers","following_url":"https://api.github.com/users/rafael-santiago/following{/other_user}","gists_url":"https://api.github.com/users/rafael-santiago/gists{/gist_id}","starred_url":"https://api.github.com/users/rafael-santiago/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rafael-santiago/subscriptions","organizations_url":"https://api.github.com/users/rafael-santiago/orgs","repos_url":"https://api.github.com/users/rafael-santiago/repos","events_url":"https://api.github.com/users/rafael-santiago/events{/privacy}","received_events_url":"https://api.github.com/users/rafael-santiago/received_events","type":"User","site_admin":false},"repo":{"id":89646145,"name":"linguist","full_name":"rafael-santiago/linguist","owner":{"login":"rafael-santiago","id":7308777,"avatar_url":"https://avatars3.githubusercontent.com/u/7308777?v=3","gravatar_id":"","url":"https://api.github.com/users/rafael-santiago","html_url":"https://github.com/rafael-santiago","followers_url":"https://api.github.com/users/rafael-santiago/followers","following_url":"https://api.github.com/users/rafael-santiago/following{/other_user}","gists_url":"https://api.github.com/users/rafael-santiago/gists{/gist_id}","starred_url":"https://api.github.com/users/rafael-santiago/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rafael-santiago/subscriptions","organizations_url":"https://api.github.com/users/rafael-santiago/orgs","repos_url":"https://api.github.com/users/rafael-santiago/repos","events_url":"https://api.github.com/users/rafael-santiago/events{/privacy}","received_events_url":"https://api.github.com/users/rafael-santiago/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/rafael-santiago/linguist","description":"Language Savant. If your repository's language is being reported incorrectly, send us a pull request!","fork":true,"url":"https://api.github.com/repos/rafael-santiago/linguist","forks_url":"https://api.github.com/repos/rafael-santiago/linguist/forks","keys_url":"https://api.github.com/repos/rafael-santiago/linguist/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rafael-santiago/linguist/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rafael-santiago/linguist/teams","hooks_url":"https://api.github.com/repos/rafael-santiago/linguist/hooks","issue_events_url":"https://api.github.com/repos/rafael-santiago/linguist/issues/events{/number}","events_url":"https://api.github.com/repos/rafael-santiago/linguist/events","assignees_url":"https://api.github.com/repos/rafael-santiago/linguist/assignees{/user}","branches_url":"https://api.github.com/repos/rafael-santiago/linguist/branches{/branch}","tags_url":"https://api.github.com/repos/rafael-santiago/linguist/tags","blobs_url":"https://api.github.com/repos/rafael-santiago/linguist/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rafael-santiago/linguist/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rafael-santiago/linguist/git/refs{/sha}","trees_url":"https://api.github.com/repos/rafael-santiago/linguist/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rafael-santiago/linguist/statuses/{sha}","languages_url":"https://api.github.com/repos/rafael-santiago/linguist/languages","stargazers_url":"https://api.github.com/repos/rafael-santiago/linguist/stargazers","contributors_url":"https://api.github.com/repos/rafael-santiago/linguist/contributors","subscribers_url":"https://api.github.com/repos/rafael-santiago/linguist/subscribers","subscription_url":"https://api.github.com/repos/rafael-santiago/linguist/subscription","commits_url":"https://api.github.com/repos/rafael-santiago/linguist/commits{/sha}","git_commits_url":"https://api.github.com/repos/rafael-santiago/linguist/git/commits{/sha}","comments_url":"https://api.github.com/repos/rafael-santiago/linguist/comments{/number}","issue_comment_url":"https://api.github.com/repos/rafael-santiago/linguist/issues/comments{/number}","contents_url":"https://api.github.com/repos/rafael-santiago/linguist/contents/{+path}","compare_url":"https://api.github.com/repos/rafael-santiago/linguist/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rafael-santiago/linguist/merges","archive_url":"https://api.github.com/repos/rafael-santiago/linguist/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rafael-santiago/linguist/downloads","issues_url":"https://api.github.com/repos/rafael-santiago/linguist/issues{/number}","pulls_url":"https://api.github.com/repos/rafael-santiago/linguist/pulls{/number}","milestones_url":"https://api.github.com/repos/rafael-santiago/linguist/milestones{/number}","notifications_url":"https://api.github.com/repos/rafael-santiago/linguist/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rafael-santiago/linguist/labels{/name}","releases_url":"https://api.github.com/repos/rafael-santiago/linguist/releases{/id}","deployments_url":"https://api.github.com/repos/rafael-santiago/linguist/deployments","created_at":"2017-04-27T22:40:50Z","updated_at":"2017-04-27T22:40:53Z","pushed_at":"2017-04-28T00:44:37Z","git_url":"git://github.com/rafael-santiago/linguist.git","ssh_url":"git@github.com:rafael-santiago/linguist.git","clone_url":"https://github.com/rafael-santiago/linguist.git","svn_url":"https://github.com/rafael-santiago/linguist","homepage":"","size":33353,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"github:master","ref":"master","sha":"c0e242358af6a3ad0ace66e29b480d3f507917cb","user":{"login":"github","id":9919,"avatar_url":"https://avatars2.githubusercontent.com/u/9919?v=3","gravatar_id":"","url":"https://api.github.com/users/github","html_url":"https://github.com/github","followers_url":"https://api.github.com/users/github/followers","following_url":"https://api.github.com/users/github/following{/other_user}","gists_url":"https://api.github.com/users/github/gists{/gist_id}","starred_url":"https://api.github.com/users/github/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/github/subscriptions","organizations_url":"https://api.github.com/users/github/orgs","repos_url":"https://api.github.com/users/github/repos","events_url":"https://api.github.com/users/github/events{/privacy}","received_events_url":"https://api.github.com/users/github/received_events","type":"Organization","site_admin":false},"repo":{"id":1725199,"name":"linguist","full_name":"github/linguist","owner":{"login":"github","id":9919,"avatar_url":"https://avatars2.githubusercontent.com/u/9919?v=3","gravatar_id":"","url":"https://api.github.com/users/github","html_url":"https://github.com/github","followers_url":"https://api.github.com/users/github/followers","following_url":"https://api.github.com/users/github/following{/other_user}","gists_url":"https://api.github.com/users/github/gists{/gist_id}","starred_url":"https://api.github.com/users/github/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/github/subscriptions","organizations_url":"https://api.github.com/users/github/orgs","repos_url":"https://api.github.com/users/github/repos","events_url":"https://api.github.com/users/github/events{/privacy}","received_events_url":"https://api.github.com/users/github/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/github/linguist","description":"Language Savant. If your repository's language is being reported incorrectly, send us a pull request!","fork":false,"url":"https://api.github.com/repos/github/linguist","forks_url":"https://api.github.com/repos/github/linguist/forks","keys_url":"https://api.github.com/repos/github/linguist/keys{/key_id}","collaborators_url":"https://api.github.com/repos/github/linguist/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/github/linguist/teams","hooks_url":"https://api.github.com/repos/github/linguist/hooks","issue_events_url":"https://api.github.com/repos/github/linguist/issues/events{/number}","events_url":"https://api.github.com/repos/github/linguist/events","assignees_url":"https://api.github.com/repos/github/linguist/assignees{/user}","branches_url":"https://api.github.com/repos/github/linguist/branches{/branch}","tags_url":"https://api.github.com/repos/github/linguist/tags","blobs_url":"https://api.github.com/repos/github/linguist/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/github/linguist/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/github/linguist/git/refs{/sha}","trees_url":"https://api.github.com/repos/github/linguist/git/trees{/sha}","statuses_url":"https://api.github.com/repos/github/linguist/statuses/{sha}","languages_url":"https://api.github.com/repos/github/linguist/languages","stargazers_url":"https://api.github.com/repos/github/linguist/stargazers","contributors_url":"https://api.github.com/repos/github/linguist/contributors","subscribers_url":"https://api.github.com/repos/github/linguist/subscribers","subscription_url":"https://api.github.com/repos/github/linguist/subscription","commits_url":"https://api.github.com/repos/github/linguist/commits{/sha}","git_commits_url":"https://api.github.com/repos/github/linguist/git/commits{/sha}","comments_url":"https://api.github.com/repos/github/linguist/comments{/number}","issue_comment_url":"https://api.github.com/repos/github/linguist/issues/comments{/number}","contents_url":"https://api.github.com/repos/github/linguist/contents/{+path}","compare_url":"https://api.github.com/repos/github/linguist/compare/{base}...{head}","merges_url":"https://api.github.com/repos/github/linguist/merges","archive_url":"https://api.github.com/repos/github/linguist/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/github/linguist/downloads","issues_url":"https://api.github.com/repos/github/linguist/issues{/number}","pulls_url":"https://api.github.com/repos/github/linguist/pulls{/number}","milestones_url":"https://api.github.com/repos/github/linguist/milestones{/number}","notifications_url":"https://api.github.com/repos/github/linguist/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/github/linguist/labels{/name}","releases_url":"https://api.github.com/repos/github/linguist/releases{/id}","deployments_url":"https://api.github.com/repos/github/linguist/deployments","created_at":"2011-05-09T22:53:13Z","updated_at":"2017-04-28T11:31:27Z","pushed_at":"2017-04-28T16:11:17Z","git_url":"git://github.com/github/linguist.git","ssh_url":"git@github.com:github/linguist.git","clone_url":"https://github.com/github/linguist.git","svn_url":"https://github.com/github/linguist","homepage":"","size":33343,"stargazers_count":4650,"watchers_count":4650,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":1822,"mirror_url":null,"open_issues_count":94,"forks":1822,"open_issues":94,"watchers":4650,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/github/linguist/pulls/3585"},"html":{"href":"https://github.com/github/linguist/pull/3585"},"issue":{"href":"https://api.github.com/repos/github/linguist/issues/3585"},"comments":{"href":"https://api.github.com/repos/github/linguist/issues/3585/comments"},"review_comments":{"href":"https://api.github.com/repos/github/linguist/pulls/3585/comments"},"review_comment":{"href":"https://api.github.com/repos/github/linguist/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/github/linguist/pulls/3585/commits"},"statuses":{"href":"https://api.github.com/repos/github/linguist/statuses/a351f16af0da8c5066faf631313b4e064af03423"}}}}
{"actor":{"display_login":"rafael-santiago"}}