mozilla / rkv

A simple, humane, typed key-value storage solution.
https://crates.io/crates/rkv
Apache License 2.0
310 stars 53 forks source link

remove unnecessary use declarations, self:: reference #102

Closed mykmelez closed 5 years ago

mykmelez commented 5 years ago

@rrichardson While reviewing #101, I realized that we can remove the use rkv and use tempfile declarations in examples/, as they're redundant with later declarations that import specific symbols from those crates.

Also, the use self::rkv::{ … } declaration happens to work because of the preceding use rkv declaration, but self:: is intended to reference local modules/items, and rkv is actually an external crate in this case (from the perspective of the example, which demonstrates how an external consumer would use rkv).

So this followup branch removes the use rkv and use tempfile declarations and changes use self::rkv::{ … } to use rkv::{ … }.

Does this seem reasonable?

rrichardson commented 5 years ago

This looks much nicer.