Skip to content

Commit b60ca5b

Browse files
committed
Fix test compilation with Rust 1.62.0
Rust 1.62.0 now tries to build and run examples for non-exported macros, as it has been doing with non-public functions. Ignore the tests, as there is not currently a way to invoke the macros from these examples. See rust-lang/rust#97030.
1 parent f1a1e2d commit b60ca5b

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@
4747
#![recursion_limit = "500"]
4848
#![deny(unused)]
4949
#![allow(unused_macros)]
50+
#![allow(unused_macro_rules)]
5051
#![cfg_attr(not(feature = "default"), allow(unused_imports))]
5152
#![deny(unstable_features)]
5253
#![deny(missing_copy_implementations)]

src/macros.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ macro_rules! feature {
1919
/// The `libc` crate must be in scope with the name `libc`.
2020
///
2121
/// # Example
22-
/// ```
22+
/// ```rust,ignore
2323
/// libc_bitflags!{
2424
/// pub struct ProtFlags: libc::c_int {
2525
/// PROT_NONE;
@@ -39,7 +39,7 @@ macro_rules! feature {
3939
/// various flags have different types, so we cast the broken ones to the right
4040
/// type.
4141
///
42-
/// ```
42+
/// ```rust,ignore
4343
/// libc_bitflags!{
4444
/// pub struct SaFlags: libc::c_ulong {
4545
/// SA_NOCLDSTOP as libc::c_ulong;
@@ -80,7 +80,7 @@ macro_rules! libc_bitflags {
8080
/// The `libc` crate must be in scope with the name `libc`.
8181
///
8282
/// # Example
83-
/// ```
83+
/// ```rust,ignore
8484
/// libc_enum!{
8585
/// pub enum ProtFlags {
8686
/// PROT_NONE,

0 commit comments

Comments
 (0)