mirror of
https://github.com/gfx-rs/wgpu.git
synced 2024-11-22 14:55:05 +00:00
Check if source
is empty when constructing hal::DebugSource
(0.18 backport) (#4693)
Co-authored-by: Teodor Tanasoaia <28601907+teoxoy@users.noreply.github.com>
This commit is contained in:
parent
957e2849dd
commit
ca96cb428c
@ -1317,7 +1317,8 @@ impl<A: HalApi> Device<A> {
|
||||
.contains(wgt::DownlevelFlags::CUBE_ARRAY_TEXTURES),
|
||||
);
|
||||
|
||||
let debug_source = if self.instance_flags.contains(wgt::InstanceFlags::DEBUG) {
|
||||
let debug_source =
|
||||
if self.instance_flags.contains(wgt::InstanceFlags::DEBUG) && !source.is_empty() {
|
||||
Some(hal::DebugSource {
|
||||
file_name: Cow::Owned(
|
||||
desc.label
|
||||
|
Loading…
Reference in New Issue
Block a user