Skip to content

Commit c588b3d

Browse files
committed
rust: cargo fmt
Format all Rust code using current stable Rust, 1.92.
1 parent 724a4ef commit c588b3d

103 files changed

Lines changed: 8500 additions & 6550 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

rust/derive/src/applayerevent.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,9 @@ pub fn derive_app_layer_event(input: TokenStream) -> TokenStream {
5151
// "crate", but if we're being used by a library or plugin user we need to reference the
5252
// Suricata name space as "suricata". Check the CARGO_PKG_NAME environment variable to
5353
// determine what identifier to setup.
54-
let is_suricata = std::env::var("CARGO_PKG_NAME").map(|var| var == "suricata").unwrap_or(false);
54+
let is_suricata = std::env::var("CARGO_PKG_NAME")
55+
.map(|var| var == "suricata")
56+
.unwrap_or(false);
5557
let crate_id = if is_suricata {
5658
syn::Ident::new("crate", proc_macro2::Span::call_site())
5759
} else {

rust/derive/src/stringenum.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,8 @@ where
112112
let fnameu = fname.to_ascii_uppercase();
113113
names_upper.push(fnameu);
114114
}
115-
"" => { // snake_case
115+
"" => {
116+
// snake_case
116117
let fname = transform_name(&v.ident.to_string());
117118
let fnameu = fname.to_ascii_uppercase();
118119
names.push(fname);

0 commit comments

Comments
 (0)