Skip to content

Commit

Permalink
New modifications
Browse files Browse the repository at this point in the history
  • Loading branch information
c410-f3r committed Jun 15, 2019
1 parent 830d32b commit aa1a49c
Show file tree
Hide file tree
Showing 21 changed files with 2,681 additions and 2,385 deletions.
17 changes: 7 additions & 10 deletions .travis.yml
@@ -1,14 +1,11 @@
language: rust
rust:
- 1.20.0
#- 1.36.0
- nightly
- beta
- stable
script: |
cargo build --verbose &&
cargo test --verbose &&
cargo test --verbose --features serde &&
([ $TRAVIS_RUST_VERSION != nightly ] || cargo check --verbose --no-default-features) &&
([ $TRAVIS_RUST_VERSION != nightly ] || cargo test --verbose --features union) &&
([ $TRAVIS_RUST_VERSION != nightly ] || cargo test --verbose --all-features) &&
([ $TRAVIS_RUST_VERSION != nightly ] || cargo bench --verbose bench)
#- stable
script:
- pushd ./scripts
- ./test-stable.sh
- ([ $TRAVIS_RUST_VERSION != nightly ] || ./test-nightly.sh
- popd
27 changes: 13 additions & 14 deletions Cargo.toml
@@ -1,25 +1,24 @@
[package]
name = "smallvec"
version = "0.6.10"
authors = ["Simon Sapin <simon.sapin@exyr.org>"]
license = "MIT/Apache-2.0"
repository = "https://github.com/servo/rust-smallvec"
categories = ["data-structures"]
description = "'Small vector' optimization: store up to a small number of items on the stack"
documentation = "https://doc.servo.org/smallvec/"
edition = "2018"
keywords = ["small", "vec", "vector", "stack", "no_std"]
categories = ["data-structures"]
license = "MIT/Apache-2.0"
name = "smallvec"
readme = "README.md"
documentation = "https://doc.servo.org/smallvec/"
repository = "https://github.com/servo/rust-smallvec"
version = "0.6.10"

[features]
std = []
union = []
default = ["std"]
specialization = []
alloc = []
const_generics = []
default = ["alloc"]
may_dangle = []

[lib]
name = "smallvec"
path = "lib.rs"
specialization = []
std = ["alloc"]
union = []

[dependencies]
serde = { version = "1", optional = true }
Expand Down
6 changes: 5 additions & 1 deletion benches/bench.rs
Expand Up @@ -273,7 +273,11 @@ fn bench_insert_from_slice(b: &mut Bencher) {
#[bench]
fn bench_macro_from_list(b: &mut Bencher) {
b.iter(|| {
let vec: SmallVec<[u64; 16]> = smallvec![
#[cfg(feature = "const_generics")]
let vec: SmallVec<u64, 16>;
#[cfg(not(feature = "const_generics"))]
let vec: SmallVec<[u64; 16]>;
vec = smallvec![
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 20, 24, 32, 36, 0x40, 0x80,
0x100, 0x200, 0x400, 0x800, 0x1000, 0x2000, 0x4000, 0x8000, 0x10000, 0x20000, 0x40000,
0x80000, 0x100000,
Expand Down

0 comments on commit aa1a49c

Please sign in to comment.