#vector #array #stack #no-std

no-std arrayvec

A vector with fixed capacity, backed by an array (it can be stored on the stack too). Implements fixed capacity ArrayVec and ArrayString.

53 releases

0.7.4 Jun 17, 2023
0.7.2 Oct 28, 2021
0.7.1 Jun 5, 2021
0.7.0 Mar 29, 2021
0.3.9 Jul 30, 2015

#10 in Data structures

Download history 716777/week @ 2024-01-01 906655/week @ 2024-01-08 955564/week @ 2024-01-15 984247/week @ 2024-01-22 1040026/week @ 2024-01-29 1040979/week @ 2024-02-05 1053784/week @ 2024-02-12 1015614/week @ 2024-02-19 1088122/week @ 2024-02-26 1066917/week @ 2024-03-04 1095085/week @ 2024-03-11 1129693/week @ 2024-03-18 1102626/week @ 2024-03-25 1166633/week @ 2024-04-01 1092562/week @ 2024-04-08 1088166/week @ 2024-04-15

4,521,405 downloads per month
Used in 10,630 crates (667 directly)

MIT/Apache

71KB
1K SLoC

arrayvec

Crates.io: arrayvec Documentation Build Status

License: Apache OR License: MIT

A vector with fixed capacity.

Please read the API documentation here

License

Dual-licensed to be compatible with the Rust project.

Licensed under the Apache License, Version 2.0 http://www.apache.org/licenses/LICENSE-2.0 or the MIT license http://opensource.org/licenses/MIT, at your option. This file may not be copied, modified, or distributed except according to those terms.


lib.rs:

arrayvec provides the types ArrayVec and ArrayString: array-backed vector and string types, which store their contents inline.

The arrayvec package has the following cargo features:

  • std

    • Optional, enabled by default
    • Use libstd; disable to use no_std instead.
  • serde

    • Optional
    • Enable serialization for ArrayVec and ArrayString using serde 1.x
  • zeroize

    • Optional
    • Implement Zeroize for ArrayVec and ArrayString

Rust Version

This version of arrayvec requires Rust 1.51 or later.

Dependencies

~180KB