Skip to content
Merged
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 packages/const-serialize-macro/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -175,15 +175,15 @@ pub fn derive_parse(input: TokenStream) -> TokenStream {
const_serialize::Layout::Struct(layout) => layout,
_ => panic!("VariantStruct::MEMORY_LAYOUT must be a struct"),
},
std::mem::align_of::<VariantStruct>(),
::std::mem::align_of::<VariantStruct>(),
)
}
}
});
quote! {
unsafe impl #impl_generics const_serialize::SerializeConst for #ty #ty_generics #where_clause {
const MEMORY_LAYOUT: const_serialize::Layout = const_serialize::Layout::Enum(const_serialize::EnumLayout::new(
std::mem::size_of::<Self>(),
::std::mem::size_of::<Self>(),
const_serialize::PrimitiveLayout::new(
#discriminant_size as usize,
),
Expand Down
14 changes: 7 additions & 7 deletions packages/router-macro/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -491,7 +491,7 @@ impl RouteEnum {

quote! {
impl std::fmt::Display for #name {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
#[allow(unused)]
match self {
#(#display_match)*
Expand All @@ -514,14 +514,14 @@ impl RouteEnum {

quote! {
impl<'a> ::core::convert::TryFrom<&'a str> for #name {
type Error = <Self as std::str::FromStr>::Err;
type Error = <Self as ::std::str::FromStr>::Err;

fn try_from(s: &'a str) -> ::std::result::Result<Self, Self::Error> {
s.parse()
}
}

impl std::str::FromStr for #name {
impl ::std::str::FromStr for #name {
type Err = dioxus_router::routable::RouteParseError<#error_name>;

fn from_str(s: &str) -> ::std::result::Result<Self, Self::Err> {
Expand Down Expand Up @@ -646,14 +646,14 @@ impl RouteEnum {
#(#error_variants),*
}

impl std::fmt::Debug for #match_error_name {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
impl ::std::fmt::Debug for #match_error_name {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
write!(f, "{}({})", stringify!(#match_error_name), self)
}
}

impl std::fmt::Display for #match_error_name {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
impl ::std::fmt::Display for #match_error_name {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
match self {
#(#display_match),*
}
Expand Down
8 changes: 4 additions & 4 deletions packages/router-macro/src/route.rs
Original file line number Diff line number Diff line change
Expand Up @@ -180,8 +180,8 @@ impl Route {
let child = field.ident.as_ref().unwrap();
quote! {
Self::#name { #(#dynamic_segments,)* #child } => {
use std::fmt::Display;
use std::fmt::Write;
use ::std::fmt::Display;
use ::std::fmt::Write;
let mut route = String::new();
{
let f = &mut route;
Expand Down Expand Up @@ -334,8 +334,8 @@ impl Route {
}
}

impl<T: std::fmt::Display> std::fmt::Display for NoPartialEq<T> {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
impl<T: ::std::fmt::Display> ::std::fmt::Display for NoPartialEq<T> {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
self.0.fmt(f)
}
}
Expand Down
8 changes: 4 additions & 4 deletions packages/router-macro/src/segment.rs
Original file line number Diff line number Diff line change
Expand Up @@ -314,14 +314,14 @@ pub(crate) fn create_error_type(
#(#error_variants,)*
}

impl std::fmt::Debug for #error_name {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
impl ::std::fmt::Debug for #error_name {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
write!(f, "{}({})", stringify!(#error_name), self)
}
}

impl std::fmt::Display for #error_name {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
impl ::std::fmt::Display for #error_name {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
match self {
Self::ExtraSegments(segments) => {
write!(f, "Found additional trailing segments: {}", segments)?
Expand Down
4 changes: 2 additions & 2 deletions packages/wasm-split/wasm-split-macro/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ pub fn wasm_split(args: TokenStream, input: TokenStream) -> TokenStream {
desugard_async_sig.asyncness = None;
desugard_async_sig.output = match &desugard_async_sig.output {
ReturnType::Default => {
parse_quote! { -> std::pin::Pin<Box<dyn std::future::Future<Output = ()>>> }
parse_quote! { -> ::std::pin::Pin<Box<dyn ::std::future::Future<Output = ()>>> }
}
ReturnType::Type(_, ty) => {
parse_quote! { -> std::pin::Pin<Box<dyn std::future::Future<Output = #ty>>> }
parse_quote! { -> ::std::pin::Pin<Box<dyn ::std::future::Future<Output = #ty>>> }
}
};

Expand Down