Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions cargo-typify/tests/outputs/attr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions cargo-typify/tests/outputs/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions cargo-typify/tests/outputs/custom_btree_map.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions cargo-typify/tests/outputs/derive.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions cargo-typify/tests/outputs/multi_derive.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions cargo-typify/tests/outputs/no-builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify-impl/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -906,8 +906,8 @@ impl TypeSpace {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
8 changes: 4 additions & 4 deletions typify-impl/src/type_entry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1429,11 +1429,11 @@ impl TypeEntry {
value.parse()
}
}
impl ::std::convert::TryFrom<String> for #type_name {
impl ::std::convert::TryFrom<::std::string::String> for #type_name {
type Error = <#inner_type_name as
::std::str::FromStr>::Err;

fn try_from(value: String) ->
fn try_from(value: ::std::string::String) ->
::std::result::Result<Self, Self::Error>
{
value.parse()
Expand Down Expand Up @@ -1514,7 +1514,7 @@ impl TypeEntry {
].into_iter().collect()),
..::std::default::Default::default()
};
schema.subschemas().not = Some(
schema.subschemas().not = ::std::option::Option::Some(
::std::boxed::Box::new(not.into())
);
schema.into()
Expand Down Expand Up @@ -1836,7 +1836,7 @@ impl TypeEntry {
let item = inner_ty.type_ident(type_space, type_mod);
// TODO we'll want this to be a Set of some kind, but we need
// to get the derives right first.
quote! { Vec<#item> }
quote! { ::std::vec::Vec<#item> }
}

TypeEntryDetails::Tuple(items) => {
Expand Down
4 changes: 2 additions & 2 deletions typify-impl/tests/generator.out
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ mod types {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify-impl/tests/github.out
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify-impl/tests/vega.out
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
16 changes: 8 additions & 8 deletions typify/tests/schemas/arrays-and-tuples.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand All @@ -39,20 +39,20 @@ pub mod error {
#[doc = r" </details>"]
#[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)]
#[serde(transparent)]
pub struct ArraySansItems(pub Vec<::serde_json::Value>);
pub struct ArraySansItems(pub ::std::vec::Vec<::serde_json::Value>);
impl ::std::ops::Deref for ArraySansItems {
type Target = Vec<::serde_json::Value>;
fn deref(&self) -> &Vec<::serde_json::Value> {
type Target = ::std::vec::Vec<::serde_json::Value>;
fn deref(&self) -> &::std::vec::Vec<::serde_json::Value> {
&self.0
}
}
impl ::std::convert::From<ArraySansItems> for Vec<::serde_json::Value> {
impl ::std::convert::From<ArraySansItems> for ::std::vec::Vec<::serde_json::Value> {
fn from(value: ArraySansItems) -> Self {
value.0
}
}
impl ::std::convert::From<Vec<::serde_json::Value>> for ArraySansItems {
fn from(value: Vec<::serde_json::Value>) -> Self {
impl ::std::convert::From<::std::vec::Vec<::serde_json::Value>> for ArraySansItems {
fn from(value: ::std::vec::Vec<::serde_json::Value>) -> Self {
Self(value)
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/deny-list.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/extraneous-enum.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/id-or-name.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/maps.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/maps_custom.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
12 changes: 6 additions & 6 deletions typify/tests/schemas/merged-schemas.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down Expand Up @@ -534,9 +534,9 @@ impl ::std::convert::TryFrom<&str> for MergeNumberBounds {
value.parse()
}
}
impl ::std::convert::TryFrom<String> for MergeNumberBounds {
impl ::std::convert::TryFrom<::std::string::String> for MergeNumberBounds {
type Error = <f64 as ::std::str::FromStr>::Err;
fn try_from(value: String) -> ::std::result::Result<Self, Self::Error> {
fn try_from(value: ::std::string::String) -> ::std::result::Result<Self, Self::Error> {
value.parse()
}
}
Expand Down Expand Up @@ -675,9 +675,9 @@ impl ::std::convert::TryFrom<&str> for NarrowNumber {
value.parse()
}
}
impl ::std::convert::TryFrom<String> for NarrowNumber {
impl ::std::convert::TryFrom<::std::string::String> for NarrowNumber {
type Error = <::std::num::NonZeroU64 as ::std::str::FromStr>::Err;
fn try_from(value: String) -> ::std::result::Result<Self, Self::Error> {
fn try_from(value: ::std::string::String) -> ::std::result::Result<Self, Self::Error> {
value.parse()
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/more_types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/multiple-instance-types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
8 changes: 4 additions & 4 deletions typify/tests/schemas/noisy-types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down Expand Up @@ -114,9 +114,9 @@ impl ::std::convert::TryFrom<&str> for IntegerBs {
value.parse()
}
}
impl ::std::convert::TryFrom<String> for IntegerBs {
impl ::std::convert::TryFrom<::std::string::String> for IntegerBs {
type Error = <u64 as ::std::str::FromStr>::Err;
fn try_from(value: String) -> ::std::result::Result<Self, Self::Error> {
fn try_from(value: ::std::string::String) -> ::std::result::Result<Self, Self::Error> {
value.parse()
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/property-pattern.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/reflexive.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/rust-collisions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/simple-types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/string-enum-with-default.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
4 changes: 2 additions & 2 deletions typify/tests/schemas/type-with-modified-generation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ pub mod error {
Self(value.into())
}
}
impl From<String> for ConversionError {
fn from(value: String) -> Self {
impl From<::std::string::String> for ConversionError {
fn from(value: ::std::string::String) -> Self {
Self(value.into())
}
}
Expand Down
Loading