Rename TypeMapTrait to TypeMap

Signed-off-by: trivernis <trivernis@protonmail.com>
main
trivernis 3 years ago
parent 3b4b789fe7
commit f2bf355633
Signed by: Trivernis
GPG Key ID: DFFFCC2C7A02DB45

@ -1,6 +1,6 @@
[package]
name = "trait-bound-typemap"
version = "0.2.0"
version = "0.3.0"
edition = "2021"
license = "Apache-2.0"
readme = "README.md"

@ -15,7 +15,7 @@ fat pointer used by trait objects changes which it hasn't in a long time so far.
## Usage
```rust
use trait_bound_typemap::{CloneTypeMap, AnyTypeMap, TypeMapTrait, TypeMapKey};
use trait_bound_typemap::{CloneTypeMap, AnyTypeMap, TypeMap, TypeMapKey};
#[derive(Clone)]
pub struct MyStruct {

@ -14,7 +14,7 @@ macro_rules! impl_typemap {
type Map = $map;
}
impl $crate::TypeMapTrait for $map {
impl $crate::TypeMap for $map {
type Key = $key;
#[inline]

@ -1,5 +1,5 @@
use crate::{
AnyTypeMap, CloneSendSyncTypeMap, CloneTypeMap, PartialEqTypeMap, TypeMapKey, TypeMapTrait,
AnyTypeMap, CloneSendSyncTypeMap, CloneTypeMap, PartialEqTypeMap, TypeMap, TypeMapKey,
};
pub struct TestStructKey;

@ -24,12 +24,12 @@ pub trait TypedKeyMto<T> {
/// A trait to map the key to the map it describes
#[doc(hidden)]
pub trait MapKey {
type Map: TypeMapTrait<Key = Self>;
type Map: TypeMap<Key = Self>;
}
/// A trait implemented by all typemaps that provides
/// all basic typemap functions
pub trait TypeMapTrait {
pub trait TypeMap {
type Key;
/// Creates a new typemap

Loading…
Cancel
Save