[core] Replace id transmute method with explicit functions. (#5509)

Replace the `wgpu_core::id::Id::transmute` method, the `transmute`
private module, and the `Transmute` sealed trait with some associated
functions with obvious names.
This commit is contained in:
Jim Blandy authored and GitHub committed 2024-04-08 21:51:30 -04:00
1 parent 17ef6cac90
commit 03db77cb8c
10 files changed
+54 -49

No files matched your search

+4 -1
View File
@@ -2409,7 +2409,10 @@ impl Global {
(trackers, pending_discard_init_fixups)
};
let cmd_buf = hub.command_buffers.get(encoder_id.transmute()).unwrap();
let cmd_buf = hub
.command_buffers
.get(encoder_id.into_command_buffer_id())
.unwrap();
let mut cmd_buf_data = cmd_buf.data.lock();
let cmd_buf_data = cmd_buf_data.as_mut().unwrap();