{"action":"created","comment":{"url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls/comments/29832594","id":29832594,"diff_hunk":"@@ -74,10 +68,7 @@ def value=(value)\n     #\n     #   @return [Fixnum] the current value after incrementation\n     def increment\n-      @mutex.lock\n-      @value += 1\n-    ensure\n-      @mutex.unlock\n+      synchronize { @value += 1 }","path":"lib/concurrent/atomic/atomic_fixnum.rb","position":null,"original_position":61,"commit_id":"6dbbe02dd1d5c54c9c53bdc2ca6574291fa8bc4c","original_commit_id":"69cccd028382da0d4d039763152a322d66aa72ad","user":{"login":"chrisseaton","id":341094,"avatar_url":"https://avatars.githubusercontent.com/u/341094?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisseaton","html_url":"https://github.com/chrisseaton","followers_url":"https://api.github.com/users/chrisseaton/followers","following_url":"https://api.github.com/users/chrisseaton/following{/other_user}","gists_url":"https://api.github.com/users/chrisseaton/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisseaton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisseaton/subscriptions","organizations_url":"https://api.github.com/users/chrisseaton/orgs","repos_url":"https://api.github.com/users/chrisseaton/repos","events_url":"https://api.github.com/users/chrisseaton/events{/privacy}","received_events_url":"https://api.github.com/users/chrisseaton/received_events","type":"User","site_admin":false},"body":"I think the reason it was called `AtomicFixnum` is so that implementations in Java and C can use high performance primitives, which on those platforms do not support overflow.","created_at":"2015-05-07T08:21:57Z","updated_at":"2015-05-07T08:21:57Z","html_url":"https://github.com/ruby-concurrency/concurrent-ruby/pull/287#discussion_r29832594","pull_request_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls/287","_links":{"self":{"href":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls/comments/29832594"},"html":{"href":"https://github.com/ruby-concurrency/concurrent-ruby/pull/287#discussion_r29832594"},"pull_request":{"href":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls/287"}}},"pull_request":{"url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls/287","id":34603175,"html_url":"https://github.com/ruby-concurrency/concurrent-ruby/pull/287","diff_url":"https://github.com/ruby-concurrency/concurrent-ruby/pull/287.diff","patch_url":"https://github.com/ruby-concurrency/concurrent-ruby/pull/287.patch","issue_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/issues/287","number":287,"state":"open","locked":false,"title":"More Synchronization","user":{"login":"jdantonio","id":173910,"avatar_url":"https://avatars.githubusercontent.com/u/173910?v=3","gravatar_id":"","url":"https://api.github.com/users/jdantonio","html_url":"https://github.com/jdantonio","followers_url":"https://api.github.com/users/jdantonio/followers","following_url":"https://api.github.com/users/jdantonio/following{/other_user}","gists_url":"https://api.github.com/users/jdantonio/gists{/gist_id}","starred_url":"https://api.github.com/users/jdantonio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jdantonio/subscriptions","organizations_url":"https://api.github.com/users/jdantonio/orgs","repos_url":"https://api.github.com/users/jdantonio/repos","events_url":"https://api.github.com/users/jdantonio/events{/privacy}","received_events_url":"https://api.github.com/users/jdantonio/received_events","type":"User","site_admin":false},"body":"Updated most classes using `Mutex` to be `Synchronization::Object` subclasses. A few classes have not been updated because they do not align neatly with the implementation of `Synchronization::Object`. Specifically:\r\n\r\n* `ReadWriteLock` uses two mutexes and two condition variables\r\n* `MutexAtomicReference` is a fallback class only used on runtimes without synchronization primitives\r\n* `BufferedChannel` uses two condition variables with a single mutex\r\n* `MVar` uses two condition variables with a single mutex\r\n* `TVar` uses `#lock` and `#unlock` methods which are not available on `Synchronization::Object`","created_at":"2015-05-03T15:55:28Z","updated_at":"2015-05-07T08:21:57Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a514c3e2bde0ad6f87be464b2099ccf1da37d9f0","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls/287/commits","review_comments_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls/287/comments","review_comment_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/issues/287/comments","statuses_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/statuses/6dbbe02dd1d5c54c9c53bdc2ca6574291fa8bc4c","head":{"label":"ruby-concurrency:more-synchronization","ref":"more-synchronization","sha":"6dbbe02dd1d5c54c9c53bdc2ca6574291fa8bc4c","user":{"login":"ruby-concurrency","id":5462766,"avatar_url":"https://avatars.githubusercontent.com/u/5462766?v=3","gravatar_id":"","url":"https://api.github.com/users/ruby-concurrency","html_url":"https://github.com/ruby-concurrency","followers_url":"https://api.github.com/users/ruby-concurrency/followers","following_url":"https://api.github.com/users/ruby-concurrency/following{/other_user}","gists_url":"https://api.github.com/users/ruby-concurrency/gists{/gist_id}","starred_url":"https://api.github.com/users/ruby-concurrency/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ruby-concurrency/subscriptions","organizations_url":"https://api.github.com/users/ruby-concurrency/orgs","repos_url":"https://api.github.com/users/ruby-concurrency/repos","events_url":"https://api.github.com/users/ruby-concurrency/events{/privacy}","received_events_url":"https://api.github.com/users/ruby-concurrency/received_events","type":"Organization","site_admin":false},"repo":{"id":11607598,"name":"concurrent-ruby","full_name":"ruby-concurrency/concurrent-ruby","owner":{"login":"ruby-concurrency","id":5462766,"avatar_url":"https://avatars.githubusercontent.com/u/5462766?v=3","gravatar_id":"","url":"https://api.github.com/users/ruby-concurrency","html_url":"https://github.com/ruby-concurrency","followers_url":"https://api.github.com/users/ruby-concurrency/followers","following_url":"https://api.github.com/users/ruby-concurrency/following{/other_user}","gists_url":"https://api.github.com/users/ruby-concurrency/gists{/gist_id}","starred_url":"https://api.github.com/users/ruby-concurrency/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ruby-concurrency/subscriptions","organizations_url":"https://api.github.com/users/ruby-concurrency/orgs","repos_url":"https://api.github.com/users/ruby-concurrency/repos","events_url":"https://api.github.com/users/ruby-concurrency/events{/privacy}","received_events_url":"https://api.github.com/users/ruby-concurrency/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ruby-concurrency/concurrent-ruby","description":"Modern concurrency tools including agents, futures, promises, thread pools, supervisors, and more. Inspired by Erlang, Clojure, Scala, Go, Java, JavaScript, and classic concurrency patterns.","fork":false,"url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby","forks_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/forks","keys_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/teams","hooks_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/hooks","issue_events_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/issues/events{/number}","events_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/events","assignees_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/assignees{/user}","branches_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/branches{/branch}","tags_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/tags","blobs_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/git/refs{/sha}","trees_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/statuses/{sha}","languages_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/languages","stargazers_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/stargazers","contributors_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/contributors","subscribers_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/subscribers","subscription_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/subscription","commits_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/commits{/sha}","git_commits_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/git/commits{/sha}","comments_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/comments{/number}","issue_comment_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/issues/comments{/number}","contents_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/contents/{+path}","compare_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/merges","archive_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/downloads","issues_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/issues{/number}","pulls_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls{/number}","milestones_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/milestones{/number}","notifications_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/labels{/name}","releases_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/releases{/id}","created_at":"2013-07-23T12:19:51Z","updated_at":"2015-05-07T02:26:26Z","pushed_at":"2015-05-07T02:26:25Z","git_url":"git://github.com/ruby-concurrency/concurrent-ruby.git","ssh_url":"git@github.com:ruby-concurrency/concurrent-ruby.git","clone_url":"https://github.com/ruby-concurrency/concurrent-ruby.git","svn_url":"https://github.com/ruby-concurrency/concurrent-ruby","homepage":"http://www.concurrent-ruby.com","size":17219,"stargazers_count":1357,"watchers_count":1357,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":69,"mirror_url":null,"open_issues_count":25,"forks":69,"open_issues":25,"watchers":1357,"default_branch":"master"}},"base":{"label":"ruby-concurrency:master","ref":"master","sha":"de789ad16e1321eb3eb75a0635d2d08df61a2169","user":{"login":"ruby-concurrency","id":5462766,"avatar_url":"https://avatars.githubusercontent.com/u/5462766?v=3","gravatar_id":"","url":"https://api.github.com/users/ruby-concurrency","html_url":"https://github.com/ruby-concurrency","followers_url":"https://api.github.com/users/ruby-concurrency/followers","following_url":"https://api.github.com/users/ruby-concurrency/following{/other_user}","gists_url":"https://api.github.com/users/ruby-concurrency/gists{/gist_id}","starred_url":"https://api.github.com/users/ruby-concurrency/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ruby-concurrency/subscriptions","organizations_url":"https://api.github.com/users/ruby-concurrency/orgs","repos_url":"https://api.github.com/users/ruby-concurrency/repos","events_url":"https://api.github.com/users/ruby-concurrency/events{/privacy}","received_events_url":"https://api.github.com/users/ruby-concurrency/received_events","type":"Organization","site_admin":false},"repo":{"id":11607598,"name":"concurrent-ruby","full_name":"ruby-concurrency/concurrent-ruby","owner":{"login":"ruby-concurrency","id":5462766,"avatar_url":"https://avatars.githubusercontent.com/u/5462766?v=3","gravatar_id":"","url":"https://api.github.com/users/ruby-concurrency","html_url":"https://github.com/ruby-concurrency","followers_url":"https://api.github.com/users/ruby-concurrency/followers","following_url":"https://api.github.com/users/ruby-concurrency/following{/other_user}","gists_url":"https://api.github.com/users/ruby-concurrency/gists{/gist_id}","starred_url":"https://api.github.com/users/ruby-concurrency/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ruby-concurrency/subscriptions","organizations_url":"https://api.github.com/users/ruby-concurrency/orgs","repos_url":"https://api.github.com/users/ruby-concurrency/repos","events_url":"https://api.github.com/users/ruby-concurrency/events{/privacy}","received_events_url":"https://api.github.com/users/ruby-concurrency/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ruby-concurrency/concurrent-ruby","description":"Modern concurrency tools including agents, futures, promises, thread pools, supervisors, and more. Inspired by Erlang, Clojure, Scala, Go, Java, JavaScript, and classic concurrency patterns.","fork":false,"url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby","forks_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/forks","keys_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/teams","hooks_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/hooks","issue_events_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/issues/events{/number}","events_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/events","assignees_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/assignees{/user}","branches_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/branches{/branch}","tags_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/tags","blobs_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/git/refs{/sha}","trees_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/statuses/{sha}","languages_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/languages","stargazers_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/stargazers","contributors_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/contributors","subscribers_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/subscribers","subscription_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/subscription","commits_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/commits{/sha}","git_commits_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/git/commits{/sha}","comments_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/comments{/number}","issue_comment_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/issues/comments{/number}","contents_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/contents/{+path}","compare_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/merges","archive_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/downloads","issues_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/issues{/number}","pulls_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls{/number}","milestones_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/milestones{/number}","notifications_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/labels{/name}","releases_url":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/releases{/id}","created_at":"2013-07-23T12:19:51Z","updated_at":"2015-05-07T02:26:26Z","pushed_at":"2015-05-07T02:26:25Z","git_url":"git://github.com/ruby-concurrency/concurrent-ruby.git","ssh_url":"git@github.com:ruby-concurrency/concurrent-ruby.git","clone_url":"https://github.com/ruby-concurrency/concurrent-ruby.git","svn_url":"https://github.com/ruby-concurrency/concurrent-ruby","homepage":"http://www.concurrent-ruby.com","size":17219,"stargazers_count":1357,"watchers_count":1357,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":69,"mirror_url":null,"open_issues_count":25,"forks":69,"open_issues":25,"watchers":1357,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls/287"},"html":{"href":"https://github.com/ruby-concurrency/concurrent-ruby/pull/287"},"issue":{"href":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/issues/287"},"comments":{"href":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/issues/287/comments"},"review_comments":{"href":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls/287/comments"},"review_comment":{"href":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/pulls/287/commits"},"statuses":{"href":"https://api.github.com/repos/ruby-concurrency/concurrent-ruby/statuses/6dbbe02dd1d5c54c9c53bdc2ca6574291fa8bc4c"}}}}