From 8e86121b6ce0f2995050ebe112306ded6bc87ca2 Mon Sep 17 00:00:00 2001 From: Yong He Date: Wed, 8 May 2024 20:52:36 -0700 Subject: Support `[__ref]` attribute to make `this` pass by reference. (#4139) Fixes #4110. --- source/slang/core.meta.slang | 3 +++ 1 file changed, 3 insertions(+) (limited to 'source/slang/core.meta.slang') diff --git a/source/slang/core.meta.slang b/source/slang/core.meta.slang index 22822196c..bde943972 100644 --- a/source/slang/core.meta.slang +++ b/source/slang/core.meta.slang @@ -2561,6 +2561,9 @@ attribute_syntax [nonmutating] : NonmutatingAttribute; __attributeTarget(FunctionDeclBase) attribute_syntax [constref] : ConstRefAttribute; +__attributeTarget(FunctionDeclBase) +attribute_syntax [__ref] : RefAttribute; + /// Indicates that a function computes its result as a function of its arguments without loading/storing any memory or other state. /// /// This is equivalent to the LLVM `readnone` function attribute. -- cgit v1.2.3