소스 검색

more clippy fixes

Evan Almloff 1 년 전
부모
커밋
212022d0c2
2개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 1 1
      packages/autofmt/src/writer.rs
  2. 1 1
      packages/core-macro/src/props/mod.rs

+ 1 - 1
packages/autofmt/src/writer.rs

@@ -197,7 +197,7 @@ impl<'a> Writer<'a> {
             self.out,
             self.out,
             "for {} in {} {{",
             "for {} in {} {{",
             forloop.pat.clone().into_token_stream(),
             forloop.pat.clone().into_token_stream(),
-            prettyplease::unparse_expr(&*forloop.expr)
+            prettyplease::unparse_expr(&forloop.expr)
         )?;
         )?;
 
 
         if forloop.body.is_empty() {
         if forloop.body.is_empty() {

+ 1 - 1
packages/core-macro/src/props/mod.rs

@@ -1086,7 +1086,7 @@ Finally, call `.build()` to create the instance of `{name}`.
         pub fn new(attrs: &[syn::Attribute]) -> Result<TypeBuilderAttr, Error> {
         pub fn new(attrs: &[syn::Attribute]) -> Result<TypeBuilderAttr, Error> {
             let mut result = TypeBuilderAttr::default();
             let mut result = TypeBuilderAttr::default();
             for attr in attrs {
             for attr in attrs {
-                if path_to_single_string(&attr.path()).as_deref() != Some("builder") {
+                if path_to_single_string(attr.path()).as_deref() != Some("builder") {
                     continue;
                     continue;
                 }
                 }