Show More
@@ -1,5 +1,6 b'' | |||||
1 | # This file is automatically @generated by Cargo. |
|
1 | # This file is automatically @generated by Cargo. | |
2 | # It is not intended for manual editing. |
|
2 | # It is not intended for manual editing. | |
|
3 | ||||
3 | [[package]] |
|
4 | [[package]] | |
4 | name = "adler" |
|
5 | name = "adler" | |
5 | version = "0.2.3" |
|
6 | version = "0.2.3" | |
@@ -511,11 +512,12 b' checksum = "0ee1c47aaa256ecabcaea351eae4' | |||||
511 |
|
512 | |||
512 | [[package]] |
|
513 | [[package]] | |
513 | name = "memmap2" |
|
514 | name = "memmap2" | |
514 |
version = "0. |
|
515 | version = "0.4.0" | |
515 | source = "registry+https://github.com/rust-lang/crates.io-index" |
|
516 | source = "registry+https://github.com/rust-lang/crates.io-index" | |
516 | checksum = "00b6c2ebff6180198788f5db08d7ce3bc1d0b617176678831a7510825973e357" |
|
517 | checksum = "de5d3112c080d58ce560081baeaab7e1e864ca21795ddbf533d5b1842bb1ecf8" | |
517 | dependencies = [ |
|
518 | dependencies = [ | |
518 | "libc", |
|
519 | "libc", | |
|
520 | "stable_deref_trait", | |||
519 | ] |
|
521 | ] | |
520 |
|
522 | |||
521 | [[package]] |
|
523 | [[package]] |
@@ -29,7 +29,7 b' tempfile = "3.1.0"' | |||||
29 | crossbeam-channel = "0.4" |
|
29 | crossbeam-channel = "0.4" | |
30 | micro-timer = "0.3.0" |
|
30 | micro-timer = "0.3.0" | |
31 | log = "0.4.8" |
|
31 | log = "0.4.8" | |
32 | memmap2 = "0.3.1" |
|
32 | memmap2 = {version = "0.4", features = ["stable_deref_trait"]} | |
33 | zstd = "0.5.3" |
|
33 | zstd = "0.5.3" | |
34 | format-bytes = "0.2.2" |
|
34 | format-bytes = "0.2.2" | |
35 |
|
35 |
@@ -290,7 +290,7 b' impl Repo {' | |||||
290 | .mmap_open(docket.data_filename()) |
|
290 | .mmap_open(docket.data_filename()) | |
291 | .io_not_found_as_none()? |
|
291 | .io_not_found_as_none()? | |
292 | { |
|
292 | { | |
293 |
OwningDirstateMap::new_empty( |
|
293 | OwningDirstateMap::new_empty(data_mmap) | |
294 | } else { |
|
294 | } else { | |
295 | OwningDirstateMap::new_empty(Vec::new()) |
|
295 | OwningDirstateMap::new_empty(Vec::new()) | |
296 | }; |
|
296 | }; | |
@@ -407,16 +407,3 b' impl<T, E> LazyCell<T, E> {' | |||||
407 | Ok(RefMut::map(borrowed, |option| option.as_mut().unwrap())) |
|
407 | Ok(RefMut::map(borrowed, |option| option.as_mut().unwrap())) | |
408 | } |
|
408 | } | |
409 | } |
|
409 | } | |
410 |
|
||||
411 | // TODO: remove this when https://github.com/RazrFalcon/memmap2-rs/pull/22 is on crates.io |
|
|||
412 | struct MmapWrapper(memmap2::Mmap); |
|
|||
413 |
|
||||
414 | impl std::ops::Deref for MmapWrapper { |
|
|||
415 | type Target = [u8]; |
|
|||
416 |
|
||||
417 | fn deref(&self) -> &[u8] { |
|
|||
418 | self.0.deref() |
|
|||
419 | } |
|
|||
420 | } |
|
|||
421 |
|
||||
422 | unsafe impl stable_deref_trait::StableDeref for MmapWrapper {} |
|
General Comments 0
You need to be logged in to leave comments.
Login now