JavaScript is disabled, refresh for a better experience. ambee/giterated

ambee/giterated

Git repository hosting, collaboration, and discovery for the Fediverse.

So. Much. Work.

Amber - ⁨2⁩ years ago

parent: tbd commit: ⁨b05f964

⁨giterated-plugins/giterated-plugin/src/callback/mod.rs⁩ - ⁨417⁩ bytes
Raw
1 mod operation;
2 pub use operation::*;
3 mod value;
4 pub use value::*;
5 mod setting;
6 pub use setting::*;
7
8 /// A container for a callback pointer, used to provide an internal callback function or
9 /// state to a plugin when performing a callback.
10 #[derive(Clone, Copy)]
11 #[repr(C)]
12 pub struct CallbackPtr(*const ());
13
14 impl CallbackPtr {
15 pub unsafe fn from_raw(callback: *const ()) -> Self {
16 Self(callback)
17 }
18 }
19