mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-08 09:38:26 +03:00
@@ -170,6 +170,7 @@ pub fn intersects(&self, other: $BitFlags) -> bool {
|
||||
}
|
||||
|
||||
/// Returns `true` all of the flags in `other` are contained within `self`.
|
||||
#[inline]
|
||||
pub fn contains(&self, other: $BitFlags) -> bool {
|
||||
(self & other) == other
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user