Commit Graph

258 Commits

Author SHA1 Message Date
Joel Wejdenstål febc45dc62
Revert "Only hash keys once, taking advantage of hashbrown raw entry api (#259)"
This reverts commit 3448b6f070.
2023-08-29 13:17:03 +02:00
Joel Wejdenstål 8364d3e48e
fix lint 2023-08-22 02:00:33 +02:00
Arthur Silva 3448b6f070
Only hash keys once, taking advantage of hashbrown raw entry api (#259) 2023-08-22 01:57:35 +02:00
Joel 018f0a1671
assert that the shard count is not 1 (#273)
* assert that the shard count is not 1

* lint
2023-07-11 05:39:27 +02:00
Joel Wejdenstål 6616a8d28c
fmt 2023-07-11 05:30:00 +02:00
Tobias Kahlert 3b418466ed
Entry insert (#226)
* added Entry::insert_entry

* added Entry::insert
2023-07-11 05:29:24 +02:00
Amin Yahyaabadi 079faeb02b
feat: implement Display and AsRef for MappedRef (#261) 2023-07-11 05:24:05 +02:00
Jan dcc97f8ddb
Implement `Serialize` for reference types (#264) 2023-07-11 05:21:26 +02:00
Joel 4c7568cce6
add support for arbitrary (#272) 2023-07-11 05:20:05 +02:00
Joel d36311e634
update deps & toolchain to stable-1.64 (#271) 2023-07-11 04:56:54 +02:00
Joel 7f9522c528
fmt (#251) 2023-01-20 08:08:52 +01:00
Arash Sahebolamri 8a0149d31b
Add `shards_mut()` and `into_shards()` to `DashMap` and `shards()` to `ReadOnlyView` (#237) 2023-01-20 08:04:58 +01:00
Fointard 0b2a2269b2
fix: typo in lib.rs (#229) 2022-10-09 13:57:57 +02:00
Joel Wejdenstål f27dba3062
fmt 2022-08-30 20:09:31 +02:00
Tom Karwowski d1f58eaf48
feat: add ReadOnlyView::par_iter() and ReadOnlyView::into_par_iter() (#223) 2022-08-30 20:08:29 +02:00
Tom Karwowski 9deeb37ccb
feat: memoize default shard amount (#222)
Use once_cell crate to memoize the value.
This doesn't add any new dependencies, as once_cell was already a subdependency. Additionally it was merged into std in nighlty and awaiting stabilization.
2022-08-30 20:05:07 +02:00
Tom Karwowski 030671060f
feat: add try_reserve method (#221) 2022-08-30 20:04:31 +02:00
Wolf Thomsen 459db7ac6f
Fix small typo in lib.rs module docstring (#209) 2022-06-06 14:09:52 +02:00
Joel dd7164dfef
Delete table.rs 2022-06-06 14:07:11 +02:00
Joel 3236196d01
Use a proper lock implementation (#214)
* use a proper but reentrant safe lock impl

* impl downgrade
2022-05-28 13:19:37 +02:00
Joel Wejdenstål c162b21b6c
Revert "Hash keys once (#194)"
This reverts commit 3d315aa7a7.
2022-05-02 17:55:05 +02:00
Joel 8f32487a12
improve locking (#204) 2022-04-29 22:04:14 +02:00
Joel 7a8beaa4dc
Mapped Ref and RefMut (#203)
Co-authored-by: Artem Shein <artem.shein@esrlabs.com>
2022-04-29 21:18:34 +02:00
Joel fcaa55511a
Address major issues (#202) 2022-04-29 21:02:35 +02:00
Joel Wejdenstål 82c2323bc6
Fix lint 2022-04-29 19:12:47 +02:00
Josh Triplett 94b49a2d60
Use `std:🧵:available_parallelism` in place of num_cpus (#199) 2022-04-29 19:11:02 +02:00
Josh Triplett 288e213c78
Fix a couple of clippy "needless_borrow" issues (#200) 2022-04-27 21:04:14 +02:00
Stepan Koltsov 5e794aa789
VacantEntry/OccupiedEntry default type for S (#193) 2022-04-27 14:16:25 +02:00
Stepan Koltsov 3d315aa7a7
Hash keys once (#194) 2022-04-27 14:15:16 +02:00
Leo 23f3d04335
Add check for if a shard_amount is a power of two. (#186)
Signed-off-by: Leo Lu <luyuxuanleo@gmail.com>
2022-03-01 10:26:30 +01:00
Leo 6321c886b4
Add support for setting shard amount. (#185) 2022-02-28 18:28:38 +01:00
xacrimon 1f3709632d
fix rayon 2022-02-06 17:39:23 +01:00
xacrimon 2f488a0664
cleanup 2022-02-06 17:32:47 +01:00
xacrimon f01fc7580b
make explicit 2022-02-06 17:19:45 +01:00
xacrimon 45c7a3ca71
elide 2022-02-06 16:42:35 +01:00
xacrimon fbb6ffb1d7
ref smuggle 2022-02-06 16:37:18 +01:00
xacrimon e530e80da0
lint + fmt 2022-02-06 16:17:38 +01:00
Joe e3de359556
Add DashMap::try_get, DashMap::try_get_mut, DashMap::try_entry 2022-02-06 10:46:08 +00:00
xacrimon 38e7703c75
fix lint 2021-12-12 18:20:55 +01:00
xacrimon 47c01be318
fmt 2021-12-12 18:16:59 +01:00
xacrimon caa4096ec8
fix rayon 2021-12-12 18:16:50 +01:00
xacrimon fd828f37b2
fmt 2021-12-12 18:16:50 +01:00
xacrimon 7da4dd7fbb
use parking_lot 2021-12-12 18:16:50 +01:00
Joel 45058dbeba
Merge pull request #148 from sdragic/master
support Serde and FromIterator for custom hashers
2021-12-12 17:59:36 +01:00
Joel dfa0f96cc6
Merge pull request #164 from BratSinot/remove_if_mut
Add remove_if_mut for Map.
2021-12-12 17:59:09 +01:00
Joel fde71253ee
Merge pull request #160 from mscofield0/master
Add "alter" variation but for immutable borrows
2021-12-12 17:56:04 +01:00
Joel ddc15d5499
Merge pull request #161 from omjadas/fix/lifetimes
Specify explicit lifetimes for key/value
2021-12-12 17:42:45 +01:00
BratSinot 4e93ed7650 Add remove_if_mut for Map. 2021-11-25 17:56:38 +02:00
omjadas 0959b5795f fix: specify explicit lifetimes 2021-10-22 21:43:16 +11:00
Michael Scofield ea509788a1 Added docs 2021-10-09 21:23:12 +02:00