{"action":"created","comment":{"url":"https://api.github.com/repos/sympy/symengine/pulls/comments/36544091","id":36544091,"diff_hunk":"@@ -10,10 +10,9 @@ Integer::Integer(int i)\n \n std::size_t Integer::__hash__() const\n {\n-    std::hash<long long int> hash_fn;\n     // only the least significant bits that fit into \"signed long int\" are\n     // hashed:\n-    return hash_fn(this->i.get_si());\n+    return this->i.get_ui() * mpz_sgn(this->i.get_mpz_t());","path":"symengine/integer.cpp","position":8,"original_position":8,"commit_id":"307b599beff40e1a1e83f0e887a7050a4bf15692","original_commit_id":"307b599beff40e1a1e83f0e887a7050a4bf15692","user":{"login":"isuruf","id":5234427,"avatar_url":"https://avatars.githubusercontent.com/u/5234427?v=3","gravatar_id":"","url":"https://api.github.com/users/isuruf","html_url":"https://github.com/isuruf","followers_url":"https://api.github.com/users/isuruf/followers","following_url":"https://api.github.com/users/isuruf/following{/other_user}","gists_url":"https://api.github.com/users/isuruf/gists{/gist_id}","starred_url":"https://api.github.com/users/isuruf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/isuruf/subscriptions","organizations_url":"https://api.github.com/users/isuruf/orgs","repos_url":"https://api.github.com/users/isuruf/repos","events_url":"https://api.github.com/users/isuruf/events{/privacy}","received_events_url":"https://api.github.com/users/isuruf/received_events","type":"User","site_admin":false},"body":"For ints with small absolute values hashes are the same in all python versions (https://docs.python.org/3/library/stdtypes.html#hashing-of-numeric-types), so that tests like `set((2*x**2*y).args) == set((2, x**2, y))` can be kept as it is.\r\n\r\nI'll look into whether speed is a concern. I'll revert back to 08ecc0b123548e9e39f74f39383b8c89b78e4352, get this merged in and then see what should be done.","created_at":"2015-08-07T17:59:59Z","updated_at":"2015-08-07T17:59:59Z","html_url":"https://github.com/sympy/symengine/pull/564#discussion_r36544091","pull_request_url":"https://api.github.com/repos/sympy/symengine/pulls/564","_links":{"self":{"href":"https://api.github.com/repos/sympy/symengine/pulls/comments/36544091"},"html":{"href":"https://github.com/sympy/symengine/pull/564#discussion_r36544091"},"pull_request":{"href":"https://api.github.com/repos/sympy/symengine/pulls/564"}}},"pull_request":{"url":"https://api.github.com/repos/sympy/symengine/pulls/564","id":40834718,"html_url":"https://github.com/sympy/symengine/pull/564","diff_url":"https://github.com/sympy/symengine/pull/564.diff","patch_url":"https://github.com/sympy/symengine/pull/564.patch","issue_url":"https://api.github.com/repos/sympy/symengine/issues/564","number":564,"state":"open","locked":false,"title":"Python testing for MSVC","user":{"login":"isuruf","id":5234427,"avatar_url":"https://avatars.githubusercontent.com/u/5234427?v=3","gravatar_id":"","url":"https://api.github.com/users/isuruf","html_url":"https://github.com/isuruf","followers_url":"https://api.github.com/users/isuruf/followers","following_url":"https://api.github.com/users/isuruf/following{/other_user}","gists_url":"https://api.github.com/users/isuruf/gists{/gist_id}","starred_url":"https://api.github.com/users/isuruf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/isuruf/subscriptions","organizations_url":"https://api.github.com/users/isuruf/orgs","repos_url":"https://api.github.com/users/isuruf/repos","events_url":"https://api.github.com/users/isuruf/events{/privacy}","received_events_url":"https://api.github.com/users/isuruf/received_events","type":"User","site_admin":false},"body":"Added python testing for MSVC in Release mode.\r\n\r\nIn Debug mode, `python27_d.lib` which is the debug version of python is missing.","created_at":"2015-07-25T10:13:43Z","updated_at":"2015-08-07T17:59:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5a496cc7398caaf2079adddea6a9ece34bc311b8","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/sympy/symengine/pulls/564/commits","review_comments_url":"https://api.github.com/repos/sympy/symengine/pulls/564/comments","review_comment_url":"https://api.github.com/repos/sympy/symengine/pulls/comments{/number}","comments_url":"https://api.github.com/repos/sympy/symengine/issues/564/comments","statuses_url":"https://api.github.com/repos/sympy/symengine/statuses/307b599beff40e1a1e83f0e887a7050a4bf15692","head":{"label":"isuruf:msvc","ref":"msvc","sha":"307b599beff40e1a1e83f0e887a7050a4bf15692","user":{"login":"isuruf","id":5234427,"avatar_url":"https://avatars.githubusercontent.com/u/5234427?v=3","gravatar_id":"","url":"https://api.github.com/users/isuruf","html_url":"https://github.com/isuruf","followers_url":"https://api.github.com/users/isuruf/followers","following_url":"https://api.github.com/users/isuruf/following{/other_user}","gists_url":"https://api.github.com/users/isuruf/gists{/gist_id}","starred_url":"https://api.github.com/users/isuruf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/isuruf/subscriptions","organizations_url":"https://api.github.com/users/isuruf/orgs","repos_url":"https://api.github.com/users/isuruf/repos","events_url":"https://api.github.com/users/isuruf/events{/privacy}","received_events_url":"https://api.github.com/users/isuruf/received_events","type":"User","site_admin":false},"repo":{"id":20401702,"name":"symengine","full_name":"isuruf/symengine","owner":{"login":"isuruf","id":5234427,"avatar_url":"https://avatars.githubusercontent.com/u/5234427?v=3","gravatar_id":"","url":"https://api.github.com/users/isuruf","html_url":"https://github.com/isuruf","followers_url":"https://api.github.com/users/isuruf/followers","following_url":"https://api.github.com/users/isuruf/following{/other_user}","gists_url":"https://api.github.com/users/isuruf/gists{/gist_id}","starred_url":"https://api.github.com/users/isuruf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/isuruf/subscriptions","organizations_url":"https://api.github.com/users/isuruf/orgs","repos_url":"https://api.github.com/users/isuruf/repos","events_url":"https://api.github.com/users/isuruf/events{/privacy}","received_events_url":"https://api.github.com/users/isuruf/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/isuruf/symengine","description":"Fast symbolic manipulation library, written in C++","fork":true,"url":"https://api.github.com/repos/isuruf/symengine","forks_url":"https://api.github.com/repos/isuruf/symengine/forks","keys_url":"https://api.github.com/repos/isuruf/symengine/keys{/key_id}","collaborators_url":"https://api.github.com/repos/isuruf/symengine/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/isuruf/symengine/teams","hooks_url":"https://api.github.com/repos/isuruf/symengine/hooks","issue_events_url":"https://api.github.com/repos/isuruf/symengine/issues/events{/number}","events_url":"https://api.github.com/repos/isuruf/symengine/events","assignees_url":"https://api.github.com/repos/isuruf/symengine/assignees{/user}","branches_url":"https://api.github.com/repos/isuruf/symengine/branches{/branch}","tags_url":"https://api.github.com/repos/isuruf/symengine/tags","blobs_url":"https://api.github.com/repos/isuruf/symengine/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/isuruf/symengine/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/isuruf/symengine/git/refs{/sha}","trees_url":"https://api.github.com/repos/isuruf/symengine/git/trees{/sha}","statuses_url":"https://api.github.com/repos/isuruf/symengine/statuses/{sha}","languages_url":"https://api.github.com/repos/isuruf/symengine/languages","stargazers_url":"https://api.github.com/repos/isuruf/symengine/stargazers","contributors_url":"https://api.github.com/repos/isuruf/symengine/contributors","subscribers_url":"https://api.github.com/repos/isuruf/symengine/subscribers","subscription_url":"https://api.github.com/repos/isuruf/symengine/subscription","commits_url":"https://api.github.com/repos/isuruf/symengine/commits{/sha}","git_commits_url":"https://api.github.com/repos/isuruf/symengine/git/commits{/sha}","comments_url":"https://api.github.com/repos/isuruf/symengine/comments{/number}","issue_comment_url":"https://api.github.com/repos/isuruf/symengine/issues/comments{/number}","contents_url":"https://api.github.com/repos/isuruf/symengine/contents/{+path}","compare_url":"https://api.github.com/repos/isuruf/symengine/compare/{base}...{head}","merges_url":"https://api.github.com/repos/isuruf/symengine/merges","archive_url":"https://api.github.com/repos/isuruf/symengine/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/isuruf/symengine/downloads","issues_url":"https://api.github.com/repos/isuruf/symengine/issues{/number}","pulls_url":"https://api.github.com/repos/isuruf/symengine/pulls{/number}","milestones_url":"https://api.github.com/repos/isuruf/symengine/milestones{/number}","notifications_url":"https://api.github.com/repos/isuruf/symengine/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/isuruf/symengine/labels{/name}","releases_url":"https://api.github.com/repos/isuruf/symengine/releases{/id}","created_at":"2014-06-02T11:28:39Z","updated_at":"2015-05-07T16:27:23Z","pushed_at":"2015-08-07T09:45:09Z","git_url":"git://github.com/isuruf/symengine.git","ssh_url":"git@github.com:isuruf/symengine.git","clone_url":"https://github.com/isuruf/symengine.git","svn_url":"https://github.com/isuruf/symengine","homepage":"http://sympy.org","size":4272,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"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":"sympy:master","ref":"master","sha":"ac1da8668492c3e89fc3abbc0d3972be6bde21aa","user":{"login":"sympy","id":260832,"avatar_url":"https://avatars.githubusercontent.com/u/260832?v=3","gravatar_id":"","url":"https://api.github.com/users/sympy","html_url":"https://github.com/sympy","followers_url":"https://api.github.com/users/sympy/followers","following_url":"https://api.github.com/users/sympy/following{/other_user}","gists_url":"https://api.github.com/users/sympy/gists{/gist_id}","starred_url":"https://api.github.com/users/sympy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sympy/subscriptions","organizations_url":"https://api.github.com/users/sympy/orgs","repos_url":"https://api.github.com/users/sympy/repos","events_url":"https://api.github.com/users/sympy/events{/privacy}","received_events_url":"https://api.github.com/users/sympy/received_events","type":"Organization","site_admin":false},"repo":{"id":42376,"name":"symengine","full_name":"sympy/symengine","owner":{"login":"sympy","id":260832,"avatar_url":"https://avatars.githubusercontent.com/u/260832?v=3","gravatar_id":"","url":"https://api.github.com/users/sympy","html_url":"https://github.com/sympy","followers_url":"https://api.github.com/users/sympy/followers","following_url":"https://api.github.com/users/sympy/following{/other_user}","gists_url":"https://api.github.com/users/sympy/gists{/gist_id}","starred_url":"https://api.github.com/users/sympy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sympy/subscriptions","organizations_url":"https://api.github.com/users/sympy/orgs","repos_url":"https://api.github.com/users/sympy/repos","events_url":"https://api.github.com/users/sympy/events{/privacy}","received_events_url":"https://api.github.com/users/sympy/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/sympy/symengine","description":"SymEngine is a fast symbolic manipulation library, written in C++ (SymEngine was previously called CSymPy)","fork":false,"url":"https://api.github.com/repos/sympy/symengine","forks_url":"https://api.github.com/repos/sympy/symengine/forks","keys_url":"https://api.github.com/repos/sympy/symengine/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sympy/symengine/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sympy/symengine/teams","hooks_url":"https://api.github.com/repos/sympy/symengine/hooks","issue_events_url":"https://api.github.com/repos/sympy/symengine/issues/events{/number}","events_url":"https://api.github.com/repos/sympy/symengine/events","assignees_url":"https://api.github.com/repos/sympy/symengine/assignees{/user}","branches_url":"https://api.github.com/repos/sympy/symengine/branches{/branch}","tags_url":"https://api.github.com/repos/sympy/symengine/tags","blobs_url":"https://api.github.com/repos/sympy/symengine/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sympy/symengine/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sympy/symengine/git/refs{/sha}","trees_url":"https://api.github.com/repos/sympy/symengine/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sympy/symengine/statuses/{sha}","languages_url":"https://api.github.com/repos/sympy/symengine/languages","stargazers_url":"https://api.github.com/repos/sympy/symengine/stargazers","contributors_url":"https://api.github.com/repos/sympy/symengine/contributors","subscribers_url":"https://api.github.com/repos/sympy/symengine/subscribers","subscription_url":"https://api.github.com/repos/sympy/symengine/subscription","commits_url":"https://api.github.com/repos/sympy/symengine/commits{/sha}","git_commits_url":"https://api.github.com/repos/sympy/symengine/git/commits{/sha}","comments_url":"https://api.github.com/repos/sympy/symengine/comments{/number}","issue_comment_url":"https://api.github.com/repos/sympy/symengine/issues/comments{/number}","contents_url":"https://api.github.com/repos/sympy/symengine/contents/{+path}","compare_url":"https://api.github.com/repos/sympy/symengine/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sympy/symengine/merges","archive_url":"https://api.github.com/repos/sympy/symengine/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sympy/symengine/downloads","issues_url":"https://api.github.com/repos/sympy/symengine/issues{/number}","pulls_url":"https://api.github.com/repos/sympy/symengine/pulls{/number}","milestones_url":"https://api.github.com/repos/sympy/symengine/milestones{/number}","notifications_url":"https://api.github.com/repos/sympy/symengine/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sympy/symengine/labels{/name}","releases_url":"https://api.github.com/repos/sympy/symengine/releases{/id}","created_at":"2008-08-13T18:40:14Z","updated_at":"2015-07-22T01:52:50Z","pushed_at":"2015-08-07T17:45:35Z","git_url":"git://github.com/sympy/symengine.git","ssh_url":"git@github.com:sympy/symengine.git","clone_url":"https://github.com/sympy/symengine.git","svn_url":"https://github.com/sympy/symengine","homepage":"http://sympy.org","size":23790,"stargazers_count":71,"watchers_count":71,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":61,"mirror_url":null,"open_issues_count":91,"forks":61,"open_issues":91,"watchers":71,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/sympy/symengine/pulls/564"},"html":{"href":"https://github.com/sympy/symengine/pull/564"},"issue":{"href":"https://api.github.com/repos/sympy/symengine/issues/564"},"comments":{"href":"https://api.github.com/repos/sympy/symengine/issues/564/comments"},"review_comments":{"href":"https://api.github.com/repos/sympy/symengine/pulls/564/comments"},"review_comment":{"href":"https://api.github.com/repos/sympy/symengine/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/sympy/symengine/pulls/564/commits"},"statuses":{"href":"https://api.github.com/repos/sympy/symengine/statuses/307b599beff40e1a1e83f0e887a7050a4bf15692"}}}}