mirror of
https://github.com/gfx-rs/wgpu.git
synced 2024-11-21 22:33:49 +00:00
remove ResourceInfo.label()
This commit is contained in:
parent
c4e067b394
commit
8106028f23
@ -506,10 +506,7 @@ impl<A: HalApi> CommandBuffer<A> {
|
||||
}
|
||||
|
||||
pub(crate) fn extract_baked_commands(&mut self) -> BakedCommands<A> {
|
||||
log::trace!(
|
||||
"Extracting BakedCommands from CommandBuffer {:?}",
|
||||
self.info.label()
|
||||
);
|
||||
log::trace!("Extracting BakedCommands from {}", self.error_ident());
|
||||
let data = self.data.lock().take().unwrap();
|
||||
BakedCommands {
|
||||
encoder: data.encoder.raw,
|
||||
|
@ -151,7 +151,7 @@ pub(crate) enum DeferredDestroy<A: HalApi> {
|
||||
impl<A: HalApi> std::fmt::Debug for Device<A> {
|
||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||
f.debug_struct("Device")
|
||||
.field("adapter", &self.adapter.info.label())
|
||||
.field("label", &self.info.label)
|
||||
.field("limits", &self.limits)
|
||||
.field("features", &self.features)
|
||||
.field("downlevel", &self.downlevel)
|
||||
|
@ -103,21 +103,6 @@ impl<T: Resource> ResourceInfo<T> {
|
||||
}
|
||||
}
|
||||
|
||||
pub(crate) fn label(&self) -> &dyn Debug
|
||||
where
|
||||
Id<T::Marker>: Debug,
|
||||
{
|
||||
if !self.label.is_empty() {
|
||||
return &self.label;
|
||||
}
|
||||
|
||||
if let Some(id) = &self.id {
|
||||
return id;
|
||||
}
|
||||
|
||||
&""
|
||||
}
|
||||
|
||||
pub(crate) fn id(&self) -> Id<T::Marker> {
|
||||
self.id.unwrap()
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user