1
0
Fork 0
forked from wry/wry

all: set rust edition to 2024

This commit is contained in:
Julian Orth 2025-02-21 10:44:29 +01:00
parent 02a18f620b
commit 3338909170
515 changed files with 1225 additions and 1187 deletions

View file

@ -3,15 +3,15 @@ use {
async_engine::{AsyncEngine, SpawnedFuture},
io_uring::{IoUring, IoUringError},
pipewire::{
pw_formatter::{format, PwFormatter},
pw_formatter::{PwFormatter, format},
pw_ifs::{
pw_client::{PwClient, PwClientMethods},
pw_client_node::{
PwClientNode, PW_CLIENT_NODE_FACTORY, PW_CLIENT_NODE_INTERFACE,
PW_CLIENT_NODE_VERSION,
PW_CLIENT_NODE_FACTORY, PW_CLIENT_NODE_INTERFACE, PW_CLIENT_NODE_VERSION,
PwClientNode,
},
pw_core::{PwCore, PwCoreMethods, PW_CORE_VERSION},
pw_registry::{PwRegistry, PW_REGISTRY_VERSION},
pw_core::{PW_CORE_VERSION, PwCore, PwCoreMethods},
pw_registry::{PW_REGISTRY_VERSION, PwRegistry},
},
pw_mem::PwMemPool,
pw_object::{PwObject, PwObjectData, PwObjectError, PwOpcode},
@ -36,7 +36,7 @@ use {
rc::{Rc, Weak},
},
thiserror::Error,
uapi::{c, OwnedFd},
uapi::{OwnedFd, c},
};
#[derive(Debug, Error)]

View file

@ -3,40 +3,40 @@
use {
crate::{
async_engine::SpawnedFuture,
format::{pw_formats, Format},
format::{Format, pw_formats},
pipewire::{
pw_con::PwCon,
pw_mem::{PwMemError, PwMemMap, PwMemSlice, PwMemTyped},
pw_object::{PwObject, PwObjectData},
pw_parser::{PwParser, PwParserError},
pw_pod::{
pw_node_activation, spa_chunk, spa_io_buffers, spa_meta_bitmap, spa_meta_busy,
spa_meta_cursor, spa_meta_header, spa_meta_region, PW_CHOICE_Enum, PW_CHOICE_Flags,
PW_OBJECT_Format, PW_OBJECT_ParamBuffers, PW_OBJECT_ParamMeta, PW_TYPE_Long,
PW_CHOICE_Enum, PW_CHOICE_Flags, PW_NODE_ACTIVATION_FINISHED,
PW_NODE_ACTIVATION_NOT_TRIGGERED, PW_NODE_ACTIVATION_TRIGGERED, PW_OBJECT_Format,
PW_OBJECT_ParamBuffers, PW_OBJECT_ParamMeta, PW_PROP_DONT_FIXATE, PW_TYPE_Long,
PwIoType, PwPod, PwPodFraction, PwPodObject, PwPodRectangle, PwPropFlag,
SPA_DATA_DmaBuf, SPA_DATA_MemFd, SPA_DATA_MemPtr, SPA_FORMAT_VIDEO_format,
SPA_DATA_DmaBuf, SPA_DATA_FLAG_READABLE, SPA_DATA_MemFd, SPA_DATA_MemPtr,
SPA_DIRECTION_INPUT, SPA_DIRECTION_OUTPUT, SPA_FORMAT_VIDEO_format,
SPA_FORMAT_VIDEO_framerate, SPA_FORMAT_VIDEO_modifier, SPA_FORMAT_VIDEO_size,
SPA_FORMAT_mediaSubtype, SPA_FORMAT_mediaType, SPA_IO_Buffers, SPA_META_Bitmap,
SPA_META_Busy, SPA_META_Control, SPA_META_Cursor, SPA_META_Header,
SPA_META_VideoCrop, SPA_META_VideoDamage, SPA_NODE_COMMAND_Pause,
SPA_NODE_COMMAND_Start, SPA_NODE_COMMAND_Suspend, SPA_PARAM_BUFFERS_blocks,
SPA_PARAM_BUFFERS_buffers, SPA_PARAM_BUFFERS_dataType, SPA_PARAM_Buffers,
SPA_PARAM_EnumFormat, SPA_PARAM_Format, SPA_PARAM_META_size, SPA_PARAM_META_type,
SPA_PARAM_Meta, SpaDataFlags, SpaDataType, SpaDirection, SpaIoType,
SpaMediaSubtype, SpaMediaType, SpaMetaType, SpaNodeBuffersFlags, SpaNodeCommand,
SpaParamType, SpaVideoFormat, PW_NODE_ACTIVATION_FINISHED,
PW_NODE_ACTIVATION_NOT_TRIGGERED, PW_NODE_ACTIVATION_TRIGGERED,
PW_PROP_DONT_FIXATE, SPA_DATA_FLAG_READABLE, SPA_DIRECTION_INPUT,
SPA_DIRECTION_OUTPUT, SPA_NODE_BUFFERS_FLAG_ALLOC, SPA_PARAM_INFO,
SPA_PARAM_INFO_READ, SPA_PARAM_INFO_SERIAL, SPA_PORT_FLAG,
SPA_PORT_FLAG_CAN_ALLOC_BUFFERS,
SPA_META_VideoCrop, SPA_META_VideoDamage, SPA_NODE_BUFFERS_FLAG_ALLOC,
SPA_NODE_COMMAND_Pause, SPA_NODE_COMMAND_Start, SPA_NODE_COMMAND_Suspend,
SPA_PARAM_BUFFERS_blocks, SPA_PARAM_BUFFERS_buffers, SPA_PARAM_BUFFERS_dataType,
SPA_PARAM_Buffers, SPA_PARAM_EnumFormat, SPA_PARAM_Format, SPA_PARAM_INFO,
SPA_PARAM_INFO_READ, SPA_PARAM_INFO_SERIAL, SPA_PARAM_META_size,
SPA_PARAM_META_type, SPA_PARAM_Meta, SPA_PORT_FLAG,
SPA_PORT_FLAG_CAN_ALLOC_BUFFERS, SpaDataFlags, SpaDataType, SpaDirection,
SpaIoType, SpaMediaSubtype, SpaMediaType, SpaMetaType, SpaNodeBuffersFlags,
SpaNodeCommand, SpaParamType, SpaVideoFormat, pw_node_activation, spa_chunk,
spa_io_buffers, spa_meta_bitmap, spa_meta_busy, spa_meta_cursor, spa_meta_header,
spa_meta_region,
},
},
utils::{
bitfield::Bitfield, buf::TypedBuf, clonecell::CloneCell, copyhashmap::CopyHashMap,
errorfmt::ErrorFmt, option_ext::OptionExt,
},
video::{dmabuf::DmaBuf, Modifier},
video::{Modifier, dmabuf::DmaBuf},
},
std::{
cell::{Cell, RefCell},

View file

@ -59,7 +59,9 @@ impl PwCore {
let name = p2.read_string()?;
let change_mask = p2.read_long()?;
let dict = p2.read_dict_struct()?;
log::info!("info: id={id}, cookie={cookie}, user_name={user_name}, host_name={host_name}, version_name={version_name}, name={name}, change_mask={change_mask}");
log::info!(
"info: id={id}, cookie={cookie}, user_name={user_name}, host_name={host_name}, version_name={version_name}, name={name}, change_mask={change_mask}"
);
log::info!("dict: {:#?}", dict);
Ok(())
}

View file

@ -1,14 +1,14 @@
use {
crate::utils::{
copyhashmap::CopyHashMap,
mmap::{mmap, Mmapped},
mmap::{Mmapped, mmap},
oserror::OsError,
page_size::page_size,
ptr_ext::{MutPtrExt, PtrExt},
},
std::{marker::PhantomData, ops::Range, rc::Rc},
thiserror::Error,
uapi::{c, OwnedFd, Pod},
uapi::{OwnedFd, Pod, c},
};
#[derive(Default)]

View file

@ -9,7 +9,7 @@ use {
fmt::{Debug, Formatter},
sync::atomic::{AtomicI32, AtomicU32},
},
uapi::{c, Pod},
uapi::{Pod, c},
};
macro_rules! ty {