Fix typo in NamedTypePathDef (#9102)

# Objective
Fixes #9091 

## Solution
Rename instances of `Primtive` to `Primitive`

## Migration Guide

Before: 

```rust 
let type_path = NamedTypePathDef::Primtive(ident);
```

After: 
```rust
let type_path = NamedTypePathDef::Primitive(ident);
```
This commit is contained in:
Cptn-Sherman 2023-07-10 10:02:16 -07:00 committed by GitHub
parent c71ae26292
commit aa03130234
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -571,7 +571,7 @@ pub fn impl_type_path(input: TokenStream) -> TokenStream {
generics,
}
}
NamedTypePathDef::Primtive(ref ident) => ReflectTypePath::Primitive(ident),
NamedTypePathDef::Primitive(ref ident) => ReflectTypePath::Primitive(ident),
};
let meta = ReflectMeta::new(type_path, ReflectTraits::default());

View File

@ -73,7 +73,7 @@ pub(crate) enum NamedTypePathDef {
generics: Generics,
custom_path: Option<CustomPathDef>,
},
Primtive(Ident),
Primitive(Ident),
}
impl Parse for NamedTypePathDef {
@ -87,7 +87,7 @@ impl Parse for NamedTypePathDef {
if path.leading_colon.is_none() && custom_path.is_none() {
if path.segments.len() == 1 {
let ident = path.segments.into_iter().next().unwrap().ident;
Ok(NamedTypePathDef::Primtive(ident))
Ok(NamedTypePathDef::Primitive(ident))
} else {
Err(input.error("non-customized paths must start with a double colon (`::`)"))
}