Implement ProxyNode for node graph

This commit is contained in:
Dennis
2022-08-01 23:44:05 -07:00
committed by Keavon Chambers
parent 066b57f43e
commit a4542b20be
+3 -3
View File
@@ -169,12 +169,12 @@ impl<'n, 'c, CachedNode: Node> CacheNode<'n, 'c, CachedNode> {
pub struct ProxyNode<T: DynamicInput>(T); pub struct ProxyNode<T: DynamicInput>(T);
impl<T: DynamicInput> Node for ProxyNode<T> { impl<T: DynamicInput> Node for ProxyNode<T> {
type Output<'a> = T where Self: 'a; type Output<'a> = &'a T where Self: 'a;
type Input<'a> = &'a () where Self: 'a; type Input<'a> = &'a () where Self: 'a;
fn eval<'a, I: Borrow<Self::Input<'a>>>(&'a self, input: I) -> Self::Output<'a> { fn eval<'a, I: Borrow<Self::Input<'a>>>(&'a self, _input: I) -> Self::Output<'a> {
todo!() &self.0
} }
} }
impl<T: DynamicInput> DynamicInput for ProxyNode<T> { impl<T: DynamicInput> DynamicInput for ProxyNode<T> {