open-gpui-macros 0.1.0

Macros used by Open GPUI.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
#[test]
fn test_derive_context() {
    use open_gpui::{App, Window};
    use open_gpui_macros::{AppContext, VisualContext};

    #[derive(AppContext, VisualContext)]
    struct _MyCustomContext<'a, 'b> {
        #[app]
        app: &'a mut App,
        #[window]
        window: &'b mut Window,
    }
}