nodety 0.1.1

Easy to use library for node editor types, generics, inference and validation
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use nodety::{TypeExpr, demo_type::DemoType, scope::ScopePointer, type_expr::ScopePortal};
use proptest::prelude::*;

proptest! {
    #[test]
    #[ignore]
    fn test_normalization_is_equal_to_before(expr in any::<TypeExpr<DemoType>>()) {
        let scoped: TypeExpr<DemoType, ScopePortal<DemoType>> = expr.into();
        let scope = ScopePointer::new_root();
        let normalized = scoped.normalize(&scope);

        prop_assert!(scoped.supertype_of(&normalized, &scope, &scope).is_supertype());
        prop_assert!(normalized.supertype_of(&scoped, &scope, &scope).is_supertype());
    }
}