Commit Graph

518 Commits

Author SHA1 Message Date
Ulrik Sverdrup 274fb2d531 Test MSRV with old versions 2024-07-30 21:12:33 +02:00
Ulrik Sverdrup 201d23a485 Set rust-version in Cargo.toml 2024-07-30 21:12:33 +02:00
Ulrik Sverdrup cee33ee1e8 Remove disabled and now-redundant tests 2024-07-30 17:34:36 +02:00
ltdk 3a75e11edc Add as_slice & as_mut_slice methods to IntoIter 2024-03-26 09:06:53 +01:00
Ulrik Sverdrup f243d433ef Remove borsch from msrv builder
Is not supported at msrv anyway (msrv applies to defaults)
2024-03-12 21:49:34 +01:00
Ulrik Sverdrup 5a2edb68b9 Update changelog 2024-03-11 22:54:20 +01:00
Jan Špaček ae6cfd3baf Improve optional support for borsh serialization
- Do not allocate when deserializing ArrayString
- Serialize length as u32, not as u64, to be consistent with
  serialization of [T] and str
- Add tests
2024-03-07 21:11:18 +01:00
Mateusz Kowalczyk 4337b1bdd7 Optional support for borsh serialization 2024-03-07 21:11:18 +01:00
YuhanLiin 7a1722ed0f Update release notes 2024-03-07 21:06:22 +01:00
YuhanLiin 9f45cc26c3 Make as_ptr and as_mut_ptr on ArrayString public 2024-03-07 21:06:22 +01:00
JakkuSakura 1cd7b9d859 feat: put len before xs 2024-03-07 21:05:54 +01:00
Ulrik Sverdrup 27401fbc22 Fix miri error in extend_zst
Miri reported this here:

Undefined Behavior: memory access failed: alloc42975 has size 4, so
pointer at offset 5 is out-of-bounds

specifically for the ptr.write() where ptr is a pointer to ZST.

Somewhat confusing that miri complains about the write, maybe a new
feature.
2024-03-07 20:44:32 +01:00
Ulrik Sverdrup 2c92a59bed 0.7.4 2023-06-17 21:58:14 +02:00
bluss 2cd12ef4be Merge pull request #240 from elichai/zeroize
Optionally implement Zeroize on ArrayVec/ArrayString
2023-06-15 11:03:37 +02:00
Elichai Turkel 71200c01b9 Add Zeroize and benches to the CI matrix 2023-06-14 15:05:11 +03:00
Elichai Turkel bb9279e2a6 Optionally implement Zeroize on ArrayVec/ArrayString 2023-06-13 22:03:50 +03:00
Ulrik Sverdrup 4ab6d63958 0.7.3 2023-06-12 21:39:49 +02:00
bluss 671274484b Merge pull request #236 from kornelski/track_caller
track_caller for capacity overflow panics
2023-05-05 21:24:17 +02:00
Kornel dc33f756d0 track_caller for capacity overflow panics 2023-04-10 22:45:30 +01:00
bluss 0e131fd781 Merge pull request #230 from msrd0/string-borrowmut
Add missing `BorrowMut` implementation for `ArrayString`
2022-11-12 10:04:16 +01:00
bluss 0637cb7997 Merge pull request #226 from clubby789/sb-fixes
Fix stacked borrows violations
2022-11-12 10:03:42 +01:00
clubby789 c9ff579405 Fix stacked borrows violations
Use offsets from a single pointer instead of multiple pointers into an array.
Also removed an integer-pointer cast
2022-11-12 09:46:43 +01:00
bluss a927f7cf03 Merge pull request #215 from RalfJung/miri
update Miri CI config
2022-11-12 09:45:13 +01:00
Dominic 9dd3f3c67b Add missing BorrowMut for ArrayString 2022-11-09 17:08:42 +01:00
Ralf Jung c65c66e855 update Miri CI config 2022-03-08 15:49:57 -05:00
bluss 67ec907a98 0.7.2 2021-10-28 18:53:54 +02:00
bluss a4690c9389 Merge pull request #194 from bhgomes/const-fns
Upgrade length/capacity-related functions to const-fn
2021-10-27 19:56:40 +02:00
bluss 4c8149a875 Merge pull request #200 from niklasf/follow-vec-retain
Follow optimization of std::Vec::retain (rust-lang/rust#88060)
2021-10-27 19:53:35 +02:00
Niklas Fiekas bc21f19e70 Follow optimization of std::Vec::retain (rust-lang/rust#88060) 2021-10-08 10:38:58 +02:00
bluss e209a5076a Merge pull request #197 from c410-f3r/str
Add `zero_filled` constructor
2021-08-14 22:05:43 +02:00
bluss 1e74077b72 Doc/wording edit for zero_filled 2021-08-14 13:37:00 +02:00
Caio e98cb1c81a Typo 2021-08-13 20:06:03 -03:00
Caio f5acafa0b3 Add zero_filled constructor 2021-08-13 20:04:44 -03:00
Brandon H. Gomes 17c5dd051e upgrade len/capacity-related functions to const-fn 2021-08-01 13:54:17 -04:00
Brandon H. Gomes 481f93084e add remaining_capacity to ArrayString 2021-08-01 13:53:21 -04:00
bluss e5b3c9bc6c Merge pull request #189 from clarfonthey/as_mut_str
Add ArrayString::as_mut_str
2021-06-20 23:41:01 +02:00
ltdk c4917813b8 Add ArrayString::as_mut_str 2021-06-20 15:35:54 -04:00
bluss 0c866b32f0 0.7.1 2021-06-05 15:13:37 +02:00
bluss 515a18cc88 Merge pull request #187 from conradludgate/into-inner-take
take and into_inner_unchecked functions
2021-05-31 23:43:55 +02:00
Conrad Ludgate 0fdf39f15d debug-assert 2021-05-30 20:34:17 +01:00
Conrad Ludgate 16c8e4d40d tests + docs 2021-05-29 13:01:14 +01:00
bluss dfceb6d624 Merge pull request #186 from a1phyr/use_truncate_in_clone_from
Use `truncate` in `clone_from`
2021-05-29 09:03:40 +02:00
Conrad Ludgate 6dc46b3a1c update take 2021-05-26 20:08:02 +01:00
Conrad Ludgate 8778483b12 feat: API additions 2021-05-25 21:57:59 +01:00
Benoît du Garreau 6be5ed4bc2 Use truncate in clone_from 2021-05-24 22:09:34 +02:00
bluss 7b290b7aa5 DOC: Mention author @oxalica in changelog for retain opt 2021-03-30 23:31:09 +02:00
bluss bf4ee7e5f9 DOC: Update 0.7.0 changelog with forgotten item #174 2021-03-30 23:17:50 +02:00
bluss 5685049fbe 0.7.0 2021-03-29 22:10:04 +02:00
bluss b0dfc877c1 Merge pull request #183 from bluss/revert-new
Add new_const() for const construction and revert new to old version
2021-03-29 21:57:12 +02:00
bluss b7f3aa9fce FIX: Add new_const() for const construction and revert new to old version
The new() function is significantly faster, it optimizes better at the
moment/in current rust. For this reason, provide a const fn constructor,
but not as the default `new`.
2021-03-29 21:52:39 +02:00