tag | 2d651272616139f5702b7643a22492044ae2964b | |
---|---|---|
tagger | The Android Open Source Project <initial-contribution@android.com> | Wed Jun 09 15:38:40 2021 -0700 |
object | c5df0d2700d63454a2e73d21775b68759bffa9cc |
Android S Beta 2 (SPB2.210513.007)
commit | c5df0d2700d63454a2e73d21775b68759bffa9cc | [log] [tgz] |
---|---|---|
author | Luke Huang <huangluke@google.com> | Wed May 12 15:47:10 2021 +0800 |
committer | Luke Huang <huangluke@google.com> | Wed May 12 08:06:56 2021 +0000 |
tree | 374e6263abc26a82e70c06ffcb32122ace1036af | |
parent | 8cd413ec55368b94f8aafefa2d834fc6c0a810e8 [diff] |
Make libtinyvec available to DnsResolver Test: TH Bug 155855709 Change-Id: If9adf0f784b57c414f81b483882fe61ece0be217
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