diff options
Diffstat (limited to 'vendor/litemap')
-rw-r--r-- | vendor/litemap/.cargo-checksum.json | 2 | ||||
-rw-r--r-- | vendor/litemap/Cargo.lock | 277 | ||||
-rw-r--r-- | vendor/litemap/Cargo.toml | 8 | ||||
-rw-r--r-- | vendor/litemap/benches/bin/litemap_bincode.rs | 2 | ||||
-rw-r--r-- | vendor/litemap/benches/bin/litemap_postcard.rs | 2 | ||||
-rw-r--r-- | vendor/litemap/benches/litemap.rs | 4 | ||||
-rw-r--r-- | vendor/litemap/src/map.rs | 28 | ||||
-rw-r--r-- | vendor/litemap/src/serde.rs | 4 | ||||
-rw-r--r-- | vendor/litemap/src/store/mod.rs | 6 | ||||
-rw-r--r-- | vendor/litemap/src/store/vec_impl.rs | 33 | ||||
-rw-r--r-- | vendor/litemap/src/testing.rs | 4 | ||||
-rw-r--r-- | vendor/litemap/tests/store.rs | 7 |
12 files changed, 159 insertions, 218 deletions
diff --git a/vendor/litemap/.cargo-checksum.json b/vendor/litemap/.cargo-checksum.json index 46a4f357e..a074ae1f6 100644 --- a/vendor/litemap/.cargo-checksum.json +++ b/vendor/litemap/.cargo-checksum.json @@ -1 +1 @@ -{"files":{"Cargo.lock":"33b6362389865144374a4952e3df4580aa90e25ccd6e141da42211158c667a34","Cargo.toml":"f8d7c3287cac0d53910dd611de6d0b1b883f43415bcfdbbd3e9396b75e9989c0","LICENSE":"4ad7541d66a407234e2c84902124cef325c29f3e966353efdb800bedb8b8da21","README.md":"021453bdd013041c191ed05243145d6fcd69d4b2e3c34685d80ee1bb96014495","benches/bin/litemap_bincode.rs":"f68c78c5438173355270560bc7fcc0b1cabc5a9a3001b13e03feb29ba8de60d1","benches/bin/litemap_postcard.rs":"2864ffc0caad3e51e67a1dd2edf23b8e924b3143b683a1101fb5113eccb4efa6","benches/litemap.rs":"dc4ca991b9f0ce618005e0e3133738459c7db580744756a0568da7a0f4f6d1be","benches/testdata/large_litemap.postcard":"7316edaf9b1b618eaa33a22cdc1f02474d53bea4fdd664ad10099235e4de5f0d","examples/language_names_hash_map.rs":"705d1049e64d6080571806f8a06330c6a3b126945bcf3bc341e1c707aad4e8f5","examples/language_names_lite_map.rs":"767246fa90005d2450f60fe1cb92c4431610a44b6e861f6146562595214996d8","src/lib.rs":"cf9c3d91961f85b96680d935f44ec0650c8963ecca4c7c80261840cc2e7b9ce5","src/map.rs":"ff8aece659756a8818be30e28a08d4196de8ed1add81e6782bfd776d158276a2","src/serde.rs":"4308da055ada25f8fd8b1d5a9398a4bfa58936971b638148b45b2d4beb3f0c7d","src/serde_helpers.rs":"72787005972b93e49b9dc17aa47d30699364e6da9dc95aadb820ce58e4bf5c54","src/store/mod.rs":"6a8463f1e93c404f2564b6127dd49e85c9587bb2ec74ae6d0c621447e7642b6e","src/store/slice_impl.rs":"34d46f5e3db0f81f391444b764f2fce7592efe1b758bef3f56a283dc24bf041d","src/store/vec_impl.rs":"c94cf9402fb6710500c0b193a476c705ed10cea9121e8c784bbacc88842539e4","src/testing.rs":"5ecf1642fed31150b29451987a89d0b134d94d62078c7f343fa9754a02f4bd90","tests/rkyv.rs":"b19d91eda9105699a4340340f0a8961de5f02673599dd8eddb43269634777cc4","tests/serde.rs":"0051274f8490c5837d88447bf72fc7266e970fa95c6e4ca540eeba45b7947ce6","tests/store.rs":"6f9506b301d82c9c1bdd737515d476002d06bd89e2f77fd00bc498653a67a629"},"package":"575d8a551c59104b4df91269921e5eab561aa1b77c618dac0414b5d44a4617de"}
\ No newline at end of file +{"files":{"Cargo.lock":"083bdb0f929313e0dbde901d90f3e4de3d8143103efd5ee3842241a8e01eee72","Cargo.toml":"5269701cb5ea061ba73f29271c0e6e2ccbb21b145214ca94ec16982b2532acb7","LICENSE":"4ad7541d66a407234e2c84902124cef325c29f3e966353efdb800bedb8b8da21","README.md":"021453bdd013041c191ed05243145d6fcd69d4b2e3c34685d80ee1bb96014495","benches/bin/litemap_bincode.rs":"76df7e65788467329089488f82bf01bffdc19f18778d42157f17beb1b4fe139c","benches/bin/litemap_postcard.rs":"3c63447b5d3c10109970508189793351753f8fc12887775a1a00817b9f0320ef","benches/litemap.rs":"bf0cde22497f2f397804ac035e18db82a2283374147776273eed858bcd30ae11","benches/testdata/large_litemap.postcard":"7316edaf9b1b618eaa33a22cdc1f02474d53bea4fdd664ad10099235e4de5f0d","examples/language_names_hash_map.rs":"705d1049e64d6080571806f8a06330c6a3b126945bcf3bc341e1c707aad4e8f5","examples/language_names_lite_map.rs":"767246fa90005d2450f60fe1cb92c4431610a44b6e861f6146562595214996d8","src/lib.rs":"cf9c3d91961f85b96680d935f44ec0650c8963ecca4c7c80261840cc2e7b9ce5","src/map.rs":"8bc72cac0960c65da300297f9ab057327a059fbd95ebc01accfcf4dca7f3d665","src/serde.rs":"e8db8afff8bf58f89d0f92a8a71ff6e7e180a26bd7db6d7df34dc657359d1d1f","src/serde_helpers.rs":"72787005972b93e49b9dc17aa47d30699364e6da9dc95aadb820ce58e4bf5c54","src/store/mod.rs":"ba9082debd8952fe98733f5a8d068851708b9486f82327286985cd0257e3dc56","src/store/slice_impl.rs":"34d46f5e3db0f81f391444b764f2fce7592efe1b758bef3f56a283dc24bf041d","src/store/vec_impl.rs":"96024ff999e95615e3584354cfaa446f9a9c5f283620566636f449526f194f36","src/testing.rs":"6e6dcb65920f9d10719b843409e8287f579ec864f9d69a9b33b80578a9fc9e4f","tests/rkyv.rs":"b19d91eda9105699a4340340f0a8961de5f02673599dd8eddb43269634777cc4","tests/serde.rs":"0051274f8490c5837d88447bf72fc7266e970fa95c6e4ca540eeba45b7947ce6","tests/store.rs":"c8b1d7899b68187aa31735f3703b056cab549310fecc3631d8fd3adc17ae714d"},"package":"3a04a5b2b6f54acba899926491d0a6c59d98012938ca2ab5befb281c034e8f94"}
\ No newline at end of file diff --git a/vendor/litemap/Cargo.lock b/vendor/litemap/Cargo.lock index 28af8845a..d674149c9 100644 --- a/vendor/litemap/Cargo.lock +++ b/vendor/litemap/Cargo.lock @@ -14,13 +14,10 @@ dependencies = [ ] [[package]] -name = "atomic-polyfill" -version = "0.1.11" +name = "anes" +version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3ff7eb3f316534d83a8a2c3d1674ace8a5a71198eba31e2e2b597833f699b28" -dependencies = [ - "critical-section", -] +checksum = "4b46cbb362ab8752921c97e041f5e366ee6297bd428a31275b9fcf1e380f7299" [[package]] name = "atty" @@ -55,18 +52,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] -name = "bstr" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3569f383e8f1598449f1a423e72e99569137b47740b1da11ef19af3d5c3223" -dependencies = [ - "lazy_static", - "memchr", - "regex-automata", - "serde", -] - -[[package]] name = "bumpalo" version = "3.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -94,12 +79,6 @@ dependencies = [ ] [[package]] -name = "byteorder" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" - -[[package]] name = "cast" version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -112,14 +91,51 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] +name = "ciborium" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b0c137568cc60b904a7724001b35ce2630fd00d5d84805fbb608ab89509d788f" +dependencies = [ + "ciborium-io", + "ciborium-ll", + "serde", +] + +[[package]] +name = "ciborium-io" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "346de753af073cc87b52b2083a506b38ac176a44cfb05497b622e27be899b369" + +[[package]] +name = "ciborium-ll" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "213030a2b5a4e0c0892b6652260cf6ccac84827b83a85a534e178e3906c4cf1b" +dependencies = [ + "ciborium-io", + "half", +] + +[[package]] name = "clap" -version = "2.34.0" +version = "3.2.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a0610544180c38b88101fecf2dd634b174a62eef6946f84dfc6a7127512b381c" +checksum = "71655c45cb9845d3270c9d6df84ebe72b4dad3c2ba3f7023ad47c144e4e473a5" dependencies = [ "bitflags", + "clap_lex", + "indexmap", "textwrap", - "unicode-width", +] + +[[package]] +name = "clap_lex" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2850f2f5a82cbf437dd5af4d49848fbdfc27c157c3d010345776f952765261c5" +dependencies = [ + "os_str_bytes", ] [[package]] @@ -130,15 +146,16 @@ checksum = "67ba02a97a2bd10f4b59b25c7973101c79642302776489e030cd13cdab09ed15" [[package]] name = "criterion" -version = "0.3.6" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b01d6de93b2b6c65e17c634a26653a29d107b3c98c607c765bf38d041531cd8f" +checksum = "e7c76e09c1aae2bc52b3d2f29e13c6572553b30c4aa1b8a49fd70de6412654cb" dependencies = [ + "anes", "atty", "cast", + "ciborium", "clap", "criterion-plot", - "csv", "itertools", "lazy_static", "num-traits", @@ -147,7 +164,6 @@ dependencies = [ "rayon", "regex", "serde", - "serde_cbor", "serde_derive", "serde_json", "tinytemplate", @@ -156,21 +172,15 @@ dependencies = [ [[package]] name = "criterion-plot" -version = "0.4.5" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2673cc8207403546f45f5fd319a974b1e6983ad1a3ee7e6041650013be041876" +checksum = "6b50826342786a51a89e2da3a28f1c32b06e387201bc2d19791f622c673706b1" dependencies = [ "cast", "itertools", ] [[package]] -name = "critical-section" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6548a0ad5d2549e111e1f6a11a6c2e2d00ce6a3dafe22948d67c2b443f775e52" - -[[package]] name = "crossbeam-channel" version = "0.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -214,32 +224,10 @@ dependencies = [ ] [[package]] -name = "csv" -version = "1.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22813a6dc45b335f9bade10bf7271dc477e81113e89eb251a0bc2a8a81c536e1" -dependencies = [ - "bstr", - "csv-core", - "itoa 0.4.8", - "ryu", - "serde", -] - -[[package]] -name = "csv-core" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b2466559f260f48ad25fe6317b3c8dac77b5bdb5763ac7d9d6103530663bc90" -dependencies = [ - "memchr", -] - -[[package]] name = "either" -version = "1.8.0" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90e5c1c8368803113bf0c9584fc495a58b86dc8a29edbf8fe877d21d9507e797" +checksum = "7fcaabb2fef8c910e7f4c7ce9f67a1283a1715879a7c230ca9d6d1ae31f16d91" [[package]] name = "getrandom" @@ -259,15 +247,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eabb4a44450da02c90444cf74558da904edde8fb4e9035a9a6a4e15445af0bd7" [[package]] -name = "hash32" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0c35f58762feb77d74ebe43bdbc3210f09be9fe6742234d573bacc26ed92b67" -dependencies = [ - "byteorder", -] - -[[package]] name = "hashbrown" version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -277,20 +256,6 @@ dependencies = [ ] [[package]] -name = "heapless" -version = "0.7.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db04bc24a18b9ea980628ecf00e6c0264f3c1426dac36c00cb49b6fbad8b0743" -dependencies = [ - "atomic-polyfill", - "hash32", - "rustc_version", - "serde", - "spin", - "stable_deref_trait", -] - -[[package]] name = "hermit-abi" version = "0.1.19" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -309,6 +274,16 @@ dependencies = [ ] [[package]] +name = "indexmap" +version = "1.9.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1885e79c1fc4b10f0e172c475f458b7f7b93061064d98c3293e98c5ba0c8b399" +dependencies = [ + "autocfg", + "hashbrown", +] + +[[package]] name = "itertools" version = "0.10.5" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -319,21 +294,15 @@ dependencies = [ [[package]] name = "itoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b71991ff56294aa922b450139ee08b3bfc70982c6b2c7562771375cf73542dd4" - -[[package]] -name = "itoa" version = "1.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fad582f4b9e86b6caa621cabeb0963332d92eea04729ab12892c2533951e6440" [[package]] name = "js-sys" -version = "0.3.60" +version = "0.3.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49409df3e3bf0856b916e2ceaca09ee28e6871cf7d9ce97a692cacfdb2a25a47" +checksum = "445dde2150c55e483f3d8416706b97ec8e8237c307e5b7b4b8dd15e6af2a0730" dependencies = [ "wasm-bindgen", ] @@ -352,7 +321,7 @@ checksum = "201de327520df007757c1f0adce6e827fe8562fbc28bfd9c15571c66ca1f5f79" [[package]] name = "litemap" -version = "0.6.1" +version = "0.7.0" dependencies = [ "bincode", "bytecheck", @@ -365,16 +334,6 @@ dependencies = [ ] [[package]] -name = "lock_api" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435011366fe56583b16cf956f9df0095b405b82d76425bc8981c0e22e60ec4df" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] name = "log" version = "0.4.17" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -384,12 +343,6 @@ dependencies = [ ] [[package]] -name = "memchr" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" - -[[package]] name = "memoffset" version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -430,6 +383,12 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0ab1bc2a289d34bd04a330323ac98a1b4bc82c9d9fcb1e66b63caa84da26b575" [[package]] +name = "os_str_bytes" +version = "6.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b7820b9daea5457c9f21c69448905d723fbd21136ccf521748f23fd49e723ee" + +[[package]] name = "plotters" version = "0.3.4" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -464,15 +423,14 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1c2b180dc0bade59f03fd005cb967d3f1e5f69b13922dad0cd6e047cb8af2363" dependencies = [ "cobs", - "heapless", "serde", ] [[package]] name = "proc-macro2" -version = "1.0.50" +version = "1.0.51" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ef7d57beacfaf2d8aee5937dab7b7f28de3cb8b1828479bb5de2a7106f2bae2" +checksum = "5d727cae5b39d21da60fa540906919ad737832fe0b1c165da3a34d6548c849d6" dependencies = [ "unicode-ident", ] @@ -538,12 +496,6 @@ dependencies = [ ] [[package]] -name = "regex-automata" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" - -[[package]] name = "regex-syntax" version = "0.6.28" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -584,15 +536,6 @@ dependencies = [ ] [[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] name = "ryu" version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -620,12 +563,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1c107b6f4780854c8b126e228ea8869f4d7b71260f962fefb57b996b8959ba6b" [[package]] -name = "semver" -version = "1.0.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58bc9567378fc7690d6b2addae4e60ac2eeea07becb2c64b9f218b53865cba2a" - -[[package]] name = "serde" version = "1.0.152" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -635,16 +572,6 @@ dependencies = [ ] [[package]] -name = "serde_cbor" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bef2ebfde456fb76bbcf9f59315333decc4fda0b2b44b420243c11e0f5ec1f5" -dependencies = [ - "half", - "serde", -] - -[[package]] name = "serde_derive" version = "1.0.152" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -657,25 +584,16 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.91" +version = "1.0.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "877c235533714907a8c2464236f5c4b2a17262ef1bd71f38f35ea592c8da6883" +checksum = "cad406b69c91885b5107daf2c29572f6c8cdb3c66826821e286c533490c0bc76" dependencies = [ - "itoa 1.0.5", + "itoa", "ryu", "serde", ] [[package]] -name = "spin" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f6002a767bff9e83f8eeecf883ecb8011875a21ae8da43bffb817a57e78cc09" -dependencies = [ - "lock_api", -] - -[[package]] name = "stable_deref_trait" version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -706,12 +624,9 @@ dependencies = [ [[package]] name = "textwrap" -version = "0.11.0" +version = "0.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d326610f408c7a4eb6f51c37c330e496b08506c9457c9d34287ecc38809fb060" -dependencies = [ - "unicode-width", -] +checksum = "222a222a5bfe1bba4a77b45ec488a741b3cb8872e5e499451fd7d0129c9c7c3d" [[package]] name = "tinytemplate" @@ -730,12 +645,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "84a22b9f218b40614adcb3f4ff08b703773ad44fa9423e4e0d346d5db86e4ebc" [[package]] -name = "unicode-width" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0edd1e5b14653f783770bce4a4dabb4a5108a5370a5f5d8cfe8710c361f6c8b" - -[[package]] name = "unicode-xid" version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -766,9 +675,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.83" +version = "0.2.84" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaf9f5aceeec8be17c128b2e93e031fb8a4d469bb9c4ae2d7dc1888b26887268" +checksum = "31f8dcbc21f30d9b8f2ea926ecb58f6b91192c17e9d33594b3df58b2007ca53b" dependencies = [ "cfg-if", "wasm-bindgen-macro", @@ -776,9 +685,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.83" +version = "0.2.84" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c8ffb332579b0557b52d268b91feab8df3615f265d5270fec2a8c95b17c1142" +checksum = "95ce90fd5bcc06af55a641a86428ee4229e44e07033963a2290a8e241607ccb9" dependencies = [ "bumpalo", "log", @@ -791,9 +700,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.83" +version = "0.2.84" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "052be0f94026e6cbc75cdefc9bae13fd6052cdcaf532fa6c45e7ae33a1e6c810" +checksum = "4c21f77c0bedc37fd5dc21f897894a5ca01e7bb159884559461862ae90c0b4c5" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -801,9 +710,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.83" +version = "0.2.84" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07bc0c051dc5f23e307b13285f9d75df86bfdf816c5721e573dec1f9b8aa193c" +checksum = "2aff81306fcac3c7515ad4e177f521b5c9a15f2b08f4e32d823066102f35a5f6" dependencies = [ "proc-macro2", "quote", @@ -814,15 +723,15 @@ dependencies = [ [[package]] name = "wasm-bindgen-shared" -version = "0.2.83" +version = "0.2.84" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c38c045535d93ec4f0b4defec448e4291638ee608530863b1e2ba115d4fff7f" +checksum = "0046fef7e28c3804e5e38bfa31ea2a0f73905319b677e57ebe37e49358989b5d" [[package]] name = "web-sys" -version = "0.3.60" +version = "0.3.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcda906d8be16e728fd5adc5b729afad4e444e106ab28cd1c7256e54fa61510f" +checksum = "e33b99f4b23ba3eec1a53ac264e35a755f00e966e0065077d6027c0f575b0b97" dependencies = [ "js-sys", "wasm-bindgen", @@ -861,9 +770,9 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "yoke" -version = "0.7.0" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "222180af14a6b54ef2c33493c1eff77ae95a3687a21b243e752624006fb8f26e" +checksum = "1848075a23a28f9773498ee9a0f2cf58fcbad4f8c0ccf84a210ab33c6ae495de" dependencies = [ "serde", "stable_deref_trait", @@ -873,9 +782,9 @@ dependencies = [ [[package]] name = "yoke-derive" -version = "0.7.0" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca800d73d6b7a7ee54f2608205c98b549fca71c9500c1abcb3abdc7708b4a8cb" +checksum = "af46c169923ed7516eef0aa32b56d2651b229f57458ebe46b49ddd6efef5b7a2" dependencies = [ "proc-macro2", "quote", diff --git a/vendor/litemap/Cargo.toml b/vendor/litemap/Cargo.toml index 01ee597a8..a08c685a2 100644 --- a/vendor/litemap/Cargo.toml +++ b/vendor/litemap/Cargo.toml @@ -12,7 +12,7 @@ [package] edition = "2021" name = "litemap" -version = "0.6.1" +version = "0.7.0" authors = ["The ICU4X Project Developers"] include = [ "src/**/*", @@ -35,7 +35,6 @@ keywords = [ ] license = "Unicode-DFS-2016" repository = "https://github.com/unicode-org/icu4x" -resolver = "2" [package.metadata.workspaces] independent = true @@ -76,7 +75,7 @@ optional = true default-features = false [dependencies.yoke] -version = "0.7.0" +version = "0.7.1" features = ["derive"] optional = true @@ -87,11 +86,12 @@ version = "1" version = "0.6" [dev-dependencies.criterion] -version = "0.3.4" +version = "0.4" [dev-dependencies.postcard] version = "1.0.0" features = ["use-std"] +default-features = false [dev-dependencies.rkyv] version = "0.7" diff --git a/vendor/litemap/benches/bin/litemap_bincode.rs b/vendor/litemap/benches/bin/litemap_bincode.rs index 72aa48845..bb17aaba0 100644 --- a/vendor/litemap/benches/bin/litemap_bincode.rs +++ b/vendor/litemap/benches/bin/litemap_bincode.rs @@ -49,7 +49,7 @@ fn generate() { } let buf = bincode::serialize(&map).unwrap(); - println!("{:?}", buf); + println!("{buf:?}"); } #[no_mangle] diff --git a/vendor/litemap/benches/bin/litemap_postcard.rs b/vendor/litemap/benches/bin/litemap_postcard.rs index b3d13d8c8..d7033c21c 100644 --- a/vendor/litemap/benches/bin/litemap_postcard.rs +++ b/vendor/litemap/benches/bin/litemap_postcard.rs @@ -43,7 +43,7 @@ fn generate() { } let buf = postcard::to_stdvec(&map).unwrap(); - println!("{:?}", buf); + println!("{buf:?}"); } #[no_mangle] diff --git a/vendor/litemap/benches/litemap.rs b/vendor/litemap/benches/litemap.rs index 353f03a86..68906037d 100644 --- a/vendor/litemap/benches/litemap.rs +++ b/vendor/litemap/benches/litemap.rs @@ -45,7 +45,7 @@ const POSTCARD: [u8; 176] = [ fn generate() { let map = build_litemap(false); let buf = postcard::to_stdvec(&map).unwrap(); - println!("{:?}", buf); + println!("{buf:?}"); } #[cfg(feature = "generate")] @@ -73,7 +73,7 @@ fn build_litemap(large: bool) -> LiteMap<String, String> { for (key, value) in DATA.into_iter() { if large { for n in 0..8192 { - map.insert(format!("{}{}", key, n), value.to_owned()); + map.insert(format!("{key}{n}"), value.to_owned()); } } else { map.insert(key.to_owned(), value.to_owned()); diff --git a/vendor/litemap/src/map.rs b/vendor/litemap/src/map.rs index 669dc464d..bcd7eb8c9 100644 --- a/vendor/litemap/src/map.rs +++ b/vendor/litemap/src/map.rs @@ -153,9 +153,8 @@ where /// ```rust /// use litemap::LiteMap; /// - /// let mut map = LiteMap::new_vec(); - /// assert!(map.try_append(1, "uno").is_none()); - /// assert!(map.try_append(3, "tres").is_none()); + /// let mut map: LiteMap<i32, &str, Vec<_>> = + /// LiteMap::from_iter([(1, "uno"), (3, "tres")].into_iter()); /// /// assert_eq!(map.first(), Some((&1, &"uno"))); /// ``` @@ -171,9 +170,8 @@ where /// ```rust /// use litemap::LiteMap; /// - /// let mut map = LiteMap::new_vec(); - /// assert!(map.try_append(1, "uno").is_none()); - /// assert!(map.try_append(3, "tres").is_none()); + /// let mut map: LiteMap<i32, &str, Vec<_>> = + /// LiteMap::from_iter([(1, "uno"), (3, "tres")].into_iter()); /// /// assert_eq!(map.last(), Some((&3, &"tres"))); /// ``` @@ -500,22 +498,11 @@ where impl<K, V, S> FromIterator<(K, V)> for LiteMap<K, V, S> where K: Ord, - S: StoreMut<K, V>, + S: StoreFromIterable<K, V>, { fn from_iter<I: IntoIterator<Item = (K, V)>>(iter: I) -> Self { - let iter = iter.into_iter(); - let mut map = match iter.size_hint() { - (_, Some(upper)) => Self::with_capacity(upper), - (lower, None) => Self::with_capacity(lower), - }; - - for (key, value) in iter { - if let Some((key, value)) = map.try_append(key, value) { - map.insert(key, value); - } - } - - map + let values = S::lm_sort_from_iter(iter); + Self::from_sorted_store_unchecked(values) } } @@ -609,7 +596,6 @@ mod test { assert_eq!(expected, actual); } - fn make_13() -> LiteMap<usize, &'static str> { let mut result = LiteMap::new(); result.insert(1, "one"); diff --git a/vendor/litemap/src/serde.rs b/vendor/litemap/src/serde.rs index 7550fb7a9..019f0fdbb 100644 --- a/vendor/litemap/src/serde.rs +++ b/vendor/litemap/src/serde.rs @@ -64,7 +64,7 @@ impl<'de, K, V, R> Visitor<'de> for LiteMapVisitor<K, V, R> where K: Deserialize<'de> + Ord, V: Deserialize<'de>, - R: StoreMut<K, V>, + R: StoreMut<K, V> + StoreFromIterable<K, V>, { type Value = LiteMap<K, V, R>; @@ -127,7 +127,7 @@ impl<'de, K, V, R> Deserialize<'de> for LiteMap<K, V, R> where K: Ord + Deserialize<'de>, V: Deserialize<'de>, - R: StoreMut<K, V>, + R: StoreMut<K, V> + StoreFromIterable<K, V>, { fn deserialize<D>(deserializer: D) -> Result<Self, D::Error> where diff --git a/vendor/litemap/src/store/mod.rs b/vendor/litemap/src/store/mod.rs index 7f4386783..3468ebb97 100644 --- a/vendor/litemap/src/store/mod.rs +++ b/vendor/litemap/src/store/mod.rs @@ -71,6 +71,11 @@ pub trait Store<K: ?Sized, V: ?Sized>: Sized { F: FnMut(&K) -> Ordering; } +pub trait StoreFromIterable<K, V>: Store<K, V> { + /// Create a sorted store from `iter`. + fn lm_sort_from_iter<I: IntoIterator<Item = (K, V)>>(iter: I) -> Self; +} + pub trait StoreMut<K, V>: Store<K, V> { /// Creates a new store with the specified capacity hint. /// @@ -84,6 +89,7 @@ pub trait StoreMut<K, V>: Store<K, V> { /// Gets a key/value pair at the specified index, with a mutable value. fn lm_get_mut(&mut self, index: usize) -> Option<(&K, &mut V)>; + /// Pushes one additional item onto the store. fn lm_push(&mut self, key: K, value: V); diff --git a/vendor/litemap/src/store/vec_impl.rs b/vendor/litemap/src/store/vec_impl.rs index e94e0fb7f..361b926c3 100644 --- a/vendor/litemap/src/store/vec_impl.rs +++ b/vendor/litemap/src/store/vec_impl.rs @@ -98,6 +98,39 @@ impl<K, V> StoreMut<K, V> for Vec<(K, V)> { } } +impl<K: Ord, V> StoreFromIterable<K, V> for Vec<(K, V)> { + fn lm_sort_from_iter<I: IntoIterator<Item = (K, V)>>(iter: I) -> Self { + let iter = iter.into_iter(); + let mut container = match iter.size_hint() { + (_, Some(upper)) => Self::with_capacity(upper), + (lower, None) => Self::with_capacity(lower), + }; + + for (key, value) in iter { + if let Some(last) = container.lm_last() { + if last.0 >= &key { + match container.lm_binary_search_by(|k| k.cmp(&key)) { + #[allow(clippy::unwrap_used)] // Index came from binary_search + Ok(found) => { + let _ = + core::mem::replace(container.lm_get_mut(found).unwrap().1, value); + } + Err(ins) => { + container.insert(ins, (key, value)); + } + } + } else { + container.push((key, value)) + } + } else { + container.push((key, value)) + } + } + + container + } +} + impl<'a, K: 'a, V: 'a> StoreIterable<'a, K, V> for Vec<(K, V)> { type KeyValueIter = core::iter::Map<core::slice::Iter<'a, (K, V)>, MapF<K, V>>; diff --git a/vendor/litemap/src/testing.rs b/vendor/litemap/src/testing.rs index 827c8dd23..2fb8c522a 100644 --- a/vendor/litemap/src/testing.rs +++ b/vendor/litemap/src/testing.rs @@ -98,7 +98,7 @@ where for (k, v) in SORTED_DATA.iter() { #[allow(clippy::single_match)] // for clarity match map.try_append(*k, *v) { - Some(_) => panic!("appending sorted data: {:?} to {:?}", k, map), + Some(_) => panic!("appending sorted data: {k:?} to {map:?}"), None => (), // OK }; } @@ -107,7 +107,7 @@ where #[allow(clippy::single_match)] // for clarity match map.try_append(*k, *v) { Some(_) => (), // OK - None => panic!("cannot append random data: {:?} to{:?}", k, map), + None => panic!("cannot append random data: {k:?} to{map:?}"), }; } assert_eq!(10, map.len()); diff --git a/vendor/litemap/tests/store.rs b/vendor/litemap/tests/store.rs index 0cc8792f8..bd28bee96 100644 --- a/vendor/litemap/tests/store.rs +++ b/vendor/litemap/tests/store.rs @@ -52,6 +52,13 @@ impl<K, V> Store<K, V> for VecWithDefaults<(K, V)> { } } +impl<K: Ord, V> StoreFromIterable<K, V> for VecWithDefaults<(K, V)> { + fn lm_sort_from_iter<I: IntoIterator<Item = (K, V)>>(iter: I) -> Self { + let v: Vec<_> = Vec::lm_sort_from_iter(iter); + Self(v) + } +} + impl<K, V> StoreMut<K, V> for VecWithDefaults<(K, V)> { #[inline] fn lm_with_capacity(capacity: usize) -> Self { |