Skip to content

Commit

Permalink
FMT & Autofix
Browse files Browse the repository at this point in the history
  • Loading branch information
CI committed May 17, 2022
1 parent 2f0427b commit b792092
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion mady_macro_core/src/annotator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use std::str::FromStr;
use crate::error::ParseError;
use crate::gen::Chain;

use crate::utils::{null, ops_to_string, Marker};
use crate::utils::{ops_to_string, Marker};

use proc_macro2::TokenStream;
use syn::parse_quote;
Expand Down
2 changes: 1 addition & 1 deletion mady_macro_core/src/folder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ use crate::gen::Chain;
use crate::generator::gen_backward;
use crate::utils::{grad_method, ops_to_string};

use crate::parser::{Parser, Recorder, Register, VarType};
use crate::parser::{Parser, Recorder, Register};

#[derive(Default)]
pub struct Folder;
Expand Down
2 changes: 1 addition & 1 deletion mady_macro_core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ mod tests {
fn gen() {
let ts = parse_quote! {
fn a(a:usize,b:usize) -> usize {
a.mul(b)
a.mul(b)
}
};

Expand Down
4 changes: 2 additions & 2 deletions mady_macro_core/src/utils.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::graph::{Edge, Graph, Node};
use crate::graph::Node;
use crate::parser::{Id, ParseGraph, Var, VarType};
use proc_macro2::{Ident, TokenStream};
use quote::{format_ident, quote};
Expand Down Expand Up @@ -77,7 +77,7 @@ impl Marker {
T: ToString,
{
let ty = method_node.to_type_ident();
let tys = arg_nodes.into_iter().map(|x| x.to_type_ident());
let tys = arg_nodes.iter().map(|x| x.to_type_ident());
let ty_trait = format_ident!("Grad{}", to_upper_camel_case(method_name.to_string()));

Self {
Expand Down

0 comments on commit b792092

Please sign in to comment.