Chore: Apply latest nightly clippy lints

This commit is contained in:
Kyle Simpson
2023-01-09 00:43:53 +00:00
parent c60c454cf5
commit 125c803fa7
9 changed files with 21 additions and 31 deletions

View File

@@ -27,10 +27,10 @@ pub enum Error {
impl Display for Error {
fn fmt(&self, f: &mut Formatter<'_>) -> FmtResult {
match self {
Self::Create(c) => f.write_fmt(format_args!("failed to create audio stream: {}", c)),
Self::Create(c) => f.write_fmt(format_args!("failed to create audio stream: {c}")),
Self::CreatePanicked => f.write_str("sync thread panicked while creating stream"),
Self::Streamcatcher(s) =>
f.write_fmt(format_args!("illegal streamcatcher config: {}", s)),
f.write_fmt(format_args!("illegal streamcatcher config: {s}")),
Self::StreamNotAtStart =>
f.write_str("stream cannot have been pre-read/parsed, missing headers"),
}
@@ -87,9 +87,9 @@ pub enum CodecCacheError {
impl Display for CodecCacheError {
fn fmt(&self, f: &mut Formatter<'_>) -> FmtResult {
match self {
Self::Create(c) => f.write_fmt(format_args!("failed to create audio stream: {}", c)),
Self::Parse(p) => f.write_fmt(format_args!("failed to parse audio format: {}", p)),
Self::Opus(o) => f.write_fmt(format_args!("failed to create Opus encoder: {}", o)),
Self::Create(c) => f.write_fmt(format_args!("failed to create audio stream: {c}")),
Self::Parse(p) => f.write_fmt(format_args!("failed to parse audio format: {p}")),
Self::Opus(o) => f.write_fmt(format_args!("failed to create Opus encoder: {o}")),
Self::MetadataEncoding(m) => f.write_fmt(format_args!(
"failed to convert track metadata to JSON: {}",
m
@@ -99,7 +99,7 @@ impl Display for CodecCacheError {
Self::UnknownChannelCount =>
f.write_str("audio stream's channel count could not be determined"),
Self::Streamcatcher(s) =>
f.write_fmt(format_args!("illegal streamcatcher config: {}", s)),
f.write_fmt(format_args!("illegal streamcatcher config: {s}")),
Self::StreamNotAtStart =>
f.write_str("stream cannot have been pre-read/parsed, missing headers"),
}