Skip to content

Commit

Permalink
cpu/arm: allow dead code in cpu/arm mod when building on non-arm
Browse files Browse the repository at this point in the history
Other architectures may not need to do feature checks, and therefore
Feature::available, Feature::mask, etc are never used/read.

This snippet mirrors the similar bit at the top of cpu/intel.

Signed-off-by: Eric Richter <erichte@linux.ibm.com>
  • Loading branch information
erichte-ibm authored and briansmith committed Sep 30, 2023
1 parent c5f7940 commit 549c098
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/cpu/arm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@
// OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
// CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

#![cfg_attr(
not(any(target_arch = "aarch64", target_arch = "arm")),
allow(dead_code)
)]

#[cfg(all(
any(target_os = "android", target_os = "linux"),
any(target_arch = "aarch64", target_arch = "arm")
Expand Down

0 comments on commit 549c098

Please sign in to comment.