macros: Consistently put ruma_common import path last

This commit is contained in:
Jonas Platte 2022-03-15 12:22:02 +01:00
parent 0faa00ca95
commit 8805b8f2e3
No known key found for this signature in database
GPG Key ID: BBA95679259D342F

View File

@ -159,7 +159,7 @@ pub fn expand_event_content(
// We only generate redacted content structs for state and message-like events // We only generate redacted content structs for state and message-like events
let redacted_event_content = needs_redacted(&content_attr, event_kind) let redacted_event_content = needs_redacted(&content_attr, event_kind)
.then(|| { .then(|| {
generate_redacted_event_content(ident, fields, event_type, ruma_common, event_kind) generate_redacted_event_content(ident, fields, event_type, event_kind, ruma_common)
}) })
.transpose()?; .transpose()?;
@ -185,8 +185,8 @@ fn generate_redacted_event_content(
ident: &Ident, ident: &Ident,
fields: &syn::Fields, fields: &syn::Fields,
event_type: &LitStr, event_type: &LitStr,
ruma_common: &TokenStream,
event_kind: Option<EventKind>, event_kind: Option<EventKind>,
ruma_common: &TokenStream,
) -> Result<TokenStream, syn::Error> { ) -> Result<TokenStream, syn::Error> {
let serde = quote! { #ruma_common::exports::serde }; let serde = quote! { #ruma_common::exports::serde };
let serde_json = quote! { #ruma_common::exports::serde_json }; let serde_json = quote! { #ruma_common::exports::serde_json };