tag | 0cebc0dc016b7efe92012a44bdff33bc334cd92f | |
---|---|---|
tagger | The Android Open Source Project <initial-contribution@android.com> | Wed Feb 01 16:52:03 2023 -0800 |
object | 54406f30e55af4b60b6812e6fb6910f91a0873cd |
Platform Tools Release 33.0.4 (9550387)
commit | 54406f30e55af4b60b6812e6fb6910f91a0873cd | [log] [tgz] |
---|---|---|
author | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | Wed Feb 01 11:03:03 2023 +0000 |
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | Wed Feb 01 11:03:03 2023 +0000 |
tree | d43d23645a9759d44228504ec1c8c8a680dbf82a | |
parent | 44d340e7da108de66bf9475e7d7c33aa838e2afd [diff] | |
parent | 137c1e2ead287823878973bc767a30b727f143c4 [diff] |
Snap for 9550355 from 137c1e2ead287823878973bc767a30b727f143c4 to sdk-release Change-Id: I460db3113223c4ba6233cc70d20a9c102af67ab3
A 100% safe crate of vec-like types. #![forbid(unsafe_code)]
Main types are as follows:
ArrayVec
is an array-backed vec-like data structure. It panics on overflow.SliceVec
is the same deal, but using a &mut [T]
.TinyVec
(alloc
feature) is an enum that's either an Inline(ArrayVec)
or a Heap(Vec)
. If a TinyVec
is Inline
and would overflow it automatically transitions to Heap
and continues whatever it was doing.To attain this “100% safe code” status there is one compromise: the element type of the vecs must implement Default
.
For more details, please see the docs.rs documentation