summaryrefslogtreecommitdiff
path: root/vendor/beef/src/wide.rs
diff options
context:
space:
mode:
authormo khan <mo@mokhan.ca>2025-07-15 16:37:08 -0600
committermo khan <mo@mokhan.ca>2025-07-17 16:30:22 -0600
commit45df4d0d9b577fecee798d672695fe24ff57fb1b (patch)
tree1b99bf645035b58e0d6db08c7a83521f41f7a75b /vendor/beef/src/wide.rs
parentf94f79608393d4ab127db63cc41668445ef6b243 (diff)
feat: migrate from Cedar to SpiceDB authorization system
This is a major architectural change that replaces the Cedar policy-based authorization system with SpiceDB's relation-based authorization. Key changes: - Migrate from Rust to Go implementation - Replace Cedar policies with SpiceDB schema and relationships - Switch from envoy `ext_authz` with Cedar to SpiceDB permission checks - Update build system and dependencies for Go ecosystem - Maintain Envoy integration for external authorization This change enables more flexible permission modeling through SpiceDB's Google Zanzibar inspired relation-based system, supporting complex hierarchical permissions that were difficult to express in Cedar. Breaking change: Existing Cedar policies and Rust-based configuration will no longer work and need to be migrated to SpiceDB schema.
Diffstat (limited to 'vendor/beef/src/wide.rs')
-rw-r--r--vendor/beef/src/wide.rs42
1 files changed, 0 insertions, 42 deletions
diff --git a/vendor/beef/src/wide.rs b/vendor/beef/src/wide.rs
deleted file mode 100644
index 466e594c..00000000
--- a/vendor/beef/src/wide.rs
+++ /dev/null
@@ -1,42 +0,0 @@
-use crate::traits::Capacity;
-use core::num::NonZeroUsize;
-
-/// Compact three word `Cow` that puts the ownership tag in capacity.
-/// This is a type alias, for documentation see [`beef::generic::Cow`](./generic/struct.Cow.html).
-pub type Cow<'a, T> = crate::generic::Cow<'a, T, Wide>;
-
-pub(crate) mod internal {
- #[derive(Clone, Copy, PartialEq, Eq)]
- pub struct Wide;
-}
-use internal::Wide;
-
-impl Capacity for Wide {
- type Field = Option<NonZeroUsize>;
- type NonZero = NonZeroUsize;
-
- #[inline]
- fn len(fat: usize) -> usize {
- fat
- }
-
- #[inline]
- fn empty(len: usize) -> (usize, Self::Field) {
- (len, None)
- }
-
- #[inline]
- fn store(len: usize, capacity: usize) -> (usize, Self::Field) {
- (len, NonZeroUsize::new(capacity))
- }
-
- #[inline]
- fn unpack(fat: usize, capacity: NonZeroUsize) -> (usize, usize) {
- (fat, capacity.get())
- }
-
- #[inline]
- fn maybe(_: usize, capacity: Option<NonZeroUsize>) -> Option<NonZeroUsize> {
- capacity
- }
-}