mirror of
https://github.com/gfx-rs/wgpu.git
synced 2024-11-25 00:03:29 +00:00
chore: satisfy clippy::assigning_clones
This commit is contained in:
parent
bfe96d87b2
commit
f1b06f55ce
@ -399,7 +399,7 @@ fn run() -> anyhow::Result<()> {
|
||||
block_ctx_dump_prefix: args.block_ctx_dir.clone().map(std::path::PathBuf::from),
|
||||
};
|
||||
|
||||
params.entry_point = args.entry_point.clone();
|
||||
params.entry_point.clone_from(&args.entry_point);
|
||||
if let Some(ref version) = args.profile {
|
||||
params.glsl.version = version.0;
|
||||
}
|
||||
|
@ -227,8 +227,12 @@ impl super::CommandEncoder {
|
||||
fn set_pipeline_inner(&mut self, inner: &super::PipelineInner) {
|
||||
self.cmd_buffer.commands.push(C::SetProgram(inner.program));
|
||||
|
||||
self.state.first_instance_location = inner.first_instance_location.clone();
|
||||
self.state.push_constant_descs = inner.push_constant_descs.clone();
|
||||
self.state
|
||||
.first_instance_location
|
||||
.clone_from(&inner.first_instance_location);
|
||||
self.state
|
||||
.push_constant_descs
|
||||
.clone_from(&inner.push_constant_descs);
|
||||
|
||||
// rebind textures, if needed
|
||||
let mut dirty_textures = 0u32;
|
||||
|
@ -573,7 +573,7 @@ impl super::Device {
|
||||
.collect();
|
||||
raw_view_formats.push(original_format);
|
||||
|
||||
wgt_view_formats = config.view_formats.clone();
|
||||
wgt_view_formats.clone_from(&config.view_formats);
|
||||
wgt_view_formats.push(config.format);
|
||||
}
|
||||
|
||||
@ -1015,7 +1015,7 @@ impl crate::Device for super::Device {
|
||||
let mut wgt_view_formats = vec![];
|
||||
if !desc.view_formats.is_empty() {
|
||||
raw_flags |= vk::ImageCreateFlags::MUTABLE_FORMAT;
|
||||
wgt_view_formats = desc.view_formats.clone();
|
||||
wgt_view_formats.clone_from(&desc.view_formats);
|
||||
wgt_view_formats.push(desc.format);
|
||||
|
||||
if self.shared.private_caps.image_format_list {
|
||||
|
Loading…
Reference in New Issue
Block a user