Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
给定一个KFunction如何检查它是否是扩展功能?
KFunction
我知道的唯一方法是检查是否function.extensionReceiverParameter返回null。有没有其他或推荐的方法?
function.extensionReceiverParameter
null
Currently, the only way to check this is to use: function.extensionReceiverParameter.
If it returns null it's not an extension function. If it returns a non-null value that function is a extension function