From a27f2bb84d3df800184fdf5442bd2f42de75b03b Mon Sep 17 00:00:00 2001 From: Michael Mc Donnell Date: Sat, 14 Jun 2025 02:08:07 -0400 Subject: [PATCH] Fix Rust-analyzer errors and warnings in `blurmac` (#37439) I got 22 errors and 63 warnings when I opened the Servo project in Visual Studio Code with the Rust-analyzer extension on Linux. The `blurmac` package, which is vendored in the source tree, only needs to be be compiled on macOS. With this change I get zero errors and 2 unrelated warnings. Testing: I don't have a mac and cannot test it there. I only tested it building on Linux. I also did not test test the Bluetooth feature. I think the change is pretty straightforward and unlikely to cause a major regression. Signed-off-by: Michael Mc Donnell --- third_party/blurmac/src/lib.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/third_party/blurmac/src/lib.rs b/third_party/blurmac/src/lib.rs index 0385c6af860..e828eef74e0 100644 --- a/third_party/blurmac/src/lib.rs +++ b/third_party/blurmac/src/lib.rs @@ -4,6 +4,7 @@ // . // This file may not be copied, modified, or distributed except // according to those terms. +#![cfg(target_os = "macos")] #[macro_use] extern crate log;