-
Notifications
You must be signed in to change notification settings - Fork 419
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use new TruffleRuby::ConcurrentMap backend for Concurrent::Map
- Loading branch information
1 parent
7b7900a
commit 4b0c1b2
Showing
2 changed files
with
21 additions
and
2 deletions.
There are no files selected for viewing
14 changes: 14 additions & 0 deletions
14
lib/concurrent-ruby/concurrent/collection/map/truffleruby_map_backend.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
module Concurrent | ||
|
||
# @!visibility private | ||
module Collection | ||
|
||
# @!visibility private | ||
class TruffleRubyMapBackend < TruffleRuby::ConcurrentMap | ||
def initialize(options = nil) | ||
options ||= {} | ||
super(initial_capacity: options[:initial_capacity], load_factor: options[:load_factor]) | ||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters