From 098b777c137d9900378f01bf802fabbceb933e80 Mon Sep 17 00:00:00 2001 From: Ruoyu Zhong Date: Tue, 2 May 2023 01:04:26 +0800 Subject: [PATCH] Fix invalid `macro_export` usage This fixes build failure with Rust 1.69+. According to [^1], "the only valid argument is `#[macro_export(local_inner_macros)]` or no argument (`#[macro_export]`)". The check for invalid `#[macro_export]` arguments was added in rust-lang/rust#107911 and first released in Rust 1.69.0. [^1]: https://github.com/rust-lang/rust/blob/1.69.0/compiler/rustc_lint_defs/src/builtin.rs#L4129 Signed-off-by: Ruoyu Zhong --- src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib.rs b/src/lib.rs index 01bf28f788..8b710ab30d 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -142,7 +142,7 @@ pub async fn load_troy_file(world: &World, file_name: &str) -> Result { } /// Logs but ignores an error -#[macro_export(log_error)] +#[macro_export] #[doc(hidden)] macro_rules! log_error { ($maybe_error:expr, $($args:tt)+) => (