Skip to content

Commit

Permalink
cargo: Delete metal-rs patch
Browse files Browse the repository at this point in the history
This is a library crate, meaning that `[patch]`es don't get applied
when users depend on our crate, and falsely end up with a broken
build while our CI said everything was hunky dory (https://github.com/
/issues/224).  We also cannot have a
direct `git` dependency as that prevents us from publishing to
crates.io.  The current workaround to that is to use a custom registry
for both `metal-rs` and `gpu-allocator` until our upstream changes
are merged and released.

What's worse, the harcoded hash that this was pointing to no longer
has a live reference on our fork (maybe due to a force-push), and the
CI is now failing to to fetch that commit by hash while build-testing
`gpu-allocator`.
  • Loading branch information
MarijnS95 committed May 22, 2024
1 parent cbf5299 commit a654a42
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
3 changes: 0 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,3 @@ metal = ["dep:metal"]
public-winapi = ["dep:winapi"]

default = ["d3d12", "vulkan"]

[patch.crates-io]
metal = { git = "https://github.com/Traverse-Research/metal-rs", rev = "a354c33" }
4 changes: 2 additions & 2 deletions src/vulkan/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ pub struct AllocatorCreateDesc {
/// let my_gpu_data: Vec<MyGpuData> = make_vertex_data();
/// ```
///
/// Depending on how the data we're copying will be used, the vulkan device may have a minimum
/// Depending on how the data we're copying will be used, the Vulkan device may have a minimum
/// alignment requirement for that data:
///
/// ```ignore
Expand Down Expand Up @@ -180,7 +180,7 @@ impl Allocation {
///
/// [`Slab`]: presser::Slab
// best to be explicit where the lifetime is coming from since we're doing unsafe things
// and relying on an inferred liftime type in the PhantomData below
// and relying on an inferred lifetime type in the PhantomData below
#[allow(clippy::needless_lifetimes)]
pub fn try_as_mapped_slab<'a>(&'a mut self) -> Option<MappedAllocationSlab<'a>> {
let mapped_ptr = self.mapped_ptr()?.cast().as_ptr();
Expand Down

0 comments on commit a654a42

Please sign in to comment.