From 86fc50c5092fbccf6072dcf7bbdfafb8915f02c8 Mon Sep 17 00:00:00 2001 From: Yong He Date: Wed, 8 Mar 2023 21:52:34 -0800 Subject: Add support for `[PrimalSubstitute]` and `[PrimalSubstituteOf]`. (#2691) * Add support for `[PrimalSubstitute]` and `[PrimalSubstituteOf]`. * Fix * Fix. * Cleanup. --------- Co-authored-by: Yong He --- source/slang/slang-ast-expr.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'source/slang/slang-ast-expr.h') diff --git a/source/slang/slang-ast-expr.h b/source/slang/slang-ast-expr.h index ba0b4ce7a..301dded49 100644 --- a/source/slang/slang-ast-expr.h +++ b/source/slang/slang-ast-expr.h @@ -452,10 +452,14 @@ class HigherOrderInvokeExpr : public Expr List newParameterNames; }; +class PrimalSubstituteExpr : public HigherOrderInvokeExpr +{ + SLANG_AST_CLASS(PrimalSubstituteExpr) +}; + class DifferentiateExpr : public HigherOrderInvokeExpr { SLANG_ABSTRACT_AST_CLASS(DifferentiateExpr) - }; /// An expression of the form `__fwd_diff(fn)` to access the /// forward-mode derivative version of the function `fn` -- cgit v1.2.3