Skip to content

Commit 7dd1906

Browse files
committed
add copy/clone/compare attributes to some flag sets
1 parent c4dcf6b commit 7dd1906

File tree

4 files changed

+5
-3
lines changed

4 files changed

+5
-3
lines changed

pulse-binding/src/context/subscribe.rs

+1
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ bitflags! {
6060
/// A set of facility masks, to be passed to [`Context::subscribe()`].
6161
///
6262
/// Note that you can convert a [`Facility`] to a mask with [`Facility::to_interest_mask()`].
63+
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
6364
#[repr(transparent)]
6465
pub struct InterestMaskSet: u32 {
6566
/// No facility (null selection; zero).

pulse-binding/src/def.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,7 @@ impl AsRef<capi::pa_spawn_api> for SpawnApi {
299299

300300
bitflags! {
301301
/// Set of sink flags.
302-
#[derive(Debug)]
302+
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
303303
#[repr(transparent)]
304304
pub struct SinkFlagSet: u32 {
305305
/// Flag to pass when no specific options are needed.
@@ -408,7 +408,7 @@ impl SinkState {
408408

409409
bitflags! {
410410
/// Set of source flags.
411-
#[derive(Debug)]
411+
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
412412
#[repr(transparent)]
413413
pub struct SourceFlagSet: u32 {
414414
/// Flag to pass when no specific options are needed.

pulse-binding/src/direction.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ use bitflags::bitflags;
1919

2020
bitflags! {
2121
/// Flag set.
22-
#[derive(Debug)]
22+
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
2323
#[repr(transparent)]
2424
pub struct FlagSet: i32 {
2525
/// Output flag.

pulse-binding/src/stream.rs

+1
Original file line numberDiff line numberDiff line change
@@ -333,6 +333,7 @@ impl State {
333333

334334
bitflags! {
335335
/// Flag set.
336+
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
336337
#[repr(transparent)]
337338
pub struct FlagSet: u32 {
338339
/// Flag to pass when no specific options are needed.

0 commit comments

Comments
 (0)