mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-16 14:58:05 +08:00
* gcore-shaders: add crate, move `color` and `blending` from gcore * gcore-shaders: move `AsU32` * gcore-shaders: move `ChoiceType`, switch `Cow` for `&str`, adjust node macro * gcore-shaders: move `registry::types` * gcore-shaders: move `context::Ctx` * raster-nodes: make it `no_std` with `std` feature * gcore-shaders: fix doctest
10 lines
222 B
Rust
10 lines
222 B
Rust
pub trait Ctx: Clone + Send {}
|
|
|
|
impl<T: Ctx> Ctx for Option<T> {}
|
|
impl<T: Ctx + Sync> Ctx for &T {}
|
|
impl Ctx for () {}
|
|
|
|
pub trait ArcCtx: Send + Sync {}
|
|
#[cfg(feature = "std")]
|
|
impl<T: ArcCtx> Ctx for std::sync::Arc<T> {}
|