mirror of
https://codeberg.org/unspeaker/tengri.git
synced 2025-12-06 03:36:42 +01:00
fix some warns
This commit is contained in:
parent
baa582b9dd
commit
d6dcf137a8
4 changed files with 28 additions and 30 deletions
|
|
@ -1,4 +1,4 @@
|
|||
use crate::*;
|
||||
#[allow(unused)] use crate::*;
|
||||
|
||||
pub struct Group<T>(T);
|
||||
|
||||
|
|
|
|||
|
|
@ -95,4 +95,4 @@ mod layout_padding; pub use self::layout_padding::*;
|
|||
mod layout_pull; pub use self::layout_pull::*;
|
||||
mod layout_push; pub use self::layout_push::*;
|
||||
mod layout_shrink; pub use self::layout_shrink::*;
|
||||
mod layout_stack; pub use self::layout_stack::*;
|
||||
mod layout_stack; //pub use self::layout_stack::*;
|
||||
|
|
|
|||
|
|
@ -15,11 +15,9 @@ mod widget; pub use self::widget::*;
|
|||
pub(crate) use self::Direction::*;
|
||||
pub(crate) use std::fmt::{Debug, Display};
|
||||
pub(crate) use std::marker::PhantomData;
|
||||
pub(crate) use std::ops::{Add, Sub, Mul, Div, Deref};
|
||||
pub(crate) use std::rc::Rc;
|
||||
pub(crate) use std::ops::{Add, Sub, Mul, Div};
|
||||
pub(crate) use std::sync::{Arc, RwLock, atomic::{AtomicUsize, Ordering::Relaxed}};
|
||||
pub(crate) use tengri_core::*;
|
||||
#[cfg(feature = "dsl")] pub(crate) use ::tengri_dsl::*;
|
||||
|
||||
/// Draw target.
|
||||
pub trait Out: Send + Sync + Sized {
|
||||
|
|
|
|||
|
|
@ -9,8 +9,8 @@ pub(crate) struct ExposeMeta;
|
|||
#[derive(Debug, Clone)]
|
||||
pub(crate) struct ExposeImpl(ItemImpl, BTreeMap<ExposeType, BTreeMap<String, Ident>>);
|
||||
|
||||
#[derive(Debug, Clone)]
|
||||
struct ExposeSym(LitStr);
|
||||
//#[derive(Debug, Clone)]
|
||||
//struct ExposeSym(LitStr);
|
||||
|
||||
#[derive(Debug, Clone)]
|
||||
struct ExposeType(Box<Type>);
|
||||
|
|
@ -169,33 +169,33 @@ impl ExposeImpl {
|
|||
}
|
||||
}
|
||||
|
||||
impl From<LitStr> for ExposeSym { fn from (this: LitStr) -> Self { Self(this) } }
|
||||
//impl From<LitStr> for ExposeSym { fn from (this: LitStr) -> Self { Self(this) } }
|
||||
|
||||
impl PartialOrd for ExposeSym {
|
||||
fn partial_cmp (&self, other: &Self) -> Option<Ordering> {
|
||||
let this = &self.0;
|
||||
let that = &other.0;
|
||||
Some(format!("{}", quote! { #this }).cmp(&format!("{}", quote! { #that })))
|
||||
}
|
||||
}
|
||||
//impl PartialOrd for ExposeSym {
|
||||
//fn partial_cmp (&self, other: &Self) -> Option<Ordering> {
|
||||
//let this = &self.0;
|
||||
//let that = &other.0;
|
||||
//Some(format!("{}", quote! { #this }).cmp(&format!("{}", quote! { #that })))
|
||||
//}
|
||||
//}
|
||||
|
||||
impl Ord for ExposeSym {
|
||||
fn cmp (&self, other: &Self) -> Ordering {
|
||||
let this = &self.0;
|
||||
let that = &other.0;
|
||||
format!("{}", quote! { #this }).cmp(&format!("{}", quote! { #that }))
|
||||
}
|
||||
}
|
||||
//impl Ord for ExposeSym {
|
||||
//fn cmp (&self, other: &Self) -> Ordering {
|
||||
//let this = &self.0;
|
||||
//let that = &other.0;
|
||||
//format!("{}", quote! { #this }).cmp(&format!("{}", quote! { #that }))
|
||||
//}
|
||||
//}
|
||||
|
||||
impl PartialEq for ExposeSym {
|
||||
fn eq (&self, other: &Self) -> bool {
|
||||
let this = &self.0;
|
||||
let that = &other.0;
|
||||
format!("{}", quote! { #this }) == format!("{}", quote! { #that })
|
||||
}
|
||||
}
|
||||
//impl PartialEq for ExposeSym {
|
||||
//fn eq (&self, other: &Self) -> bool {
|
||||
//let this = &self.0;
|
||||
//let that = &other.0;
|
||||
//format!("{}", quote! { #this }) == format!("{}", quote! { #that })
|
||||
//}
|
||||
//}
|
||||
|
||||
impl Eq for ExposeSym {}
|
||||
//impl Eq for ExposeSym {}
|
||||
|
||||
impl From<Type> for ExposeType { fn from (this: Type) -> Self { Self(Box::new(this)) } }
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue