Skip to content

Commit c8ec928

Browse files
committed
lint: fix clippy
1 parent 0f3138e commit c8ec928

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

float-pigment-css-macro/src/style_syntax.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -894,13 +894,13 @@ impl ToTokens for StyleSyntaxDefinition {
894894
writeln!(&mut style_doc, "| ---- | ---- | ---- |").unwrap();
895895
let table_list_a = supported_properties
896896
.iter()
897-
.filter(|x| !x.name.as_ref().unwrap().starts_with("-"));
897+
.filter(|x| !x.name.as_ref().unwrap().starts_with('-'));
898898
let table_list_b = supported_properties
899899
.iter()
900-
.filter(|x| x.name.as_ref().unwrap().starts_with("-"));
900+
.filter(|x| x.name.as_ref().unwrap().starts_with('-'));
901901
for x in table_list_a.chain(table_list_b) {
902902
let name = x.name.as_ref().unwrap();
903-
let non_standard = name.starts_with("-");
903+
let non_standard = name.starts_with('-');
904904
let name_col = if non_standard {
905905
format!("*`{}`*", name)
906906
} else {

float-pigment-css/src/path.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ use alloc::string::String;
33
pub(crate) fn resolve(base: &str, rel: &str) -> String {
44
let mut slices = vec![];
55
let mut extra_parent_count = 0;
6-
let from_root = base.starts_with("/") || rel.starts_with("/");
6+
let from_root = base.starts_with('/') || rel.starts_with('/');
77
let main = if let Some(rel) = rel.strip_prefix('/') {
88
rel
99
} else {

float-pigment-css/src/sheet/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ impl CompiledStyleSheet {
130130
let m = match media.clone() {
131131
None => parent_media.clone(),
132132
Some(mut m) => {
133-
Rc::make_mut(&mut m).parent = parent_media.clone();
133+
Rc::make_mut(&mut m).parent.clone_from(&parent_media);
134134
Some(m)
135135
}
136136
};

0 commit comments

Comments
 (0)