Are extension functions given lower priority than ...
# announcements
f
Are extension functions given lower priority than class/object functions when resolving what function is being called? I'm getting this and I'm not sure that's normal/expected : https://gist.github.com/FredDeschenes/83cee779fcc3fb1bb63c8fabfed28806
c
Yup, member functions are preferred to extensions. That's documented here: https://kotlinlang.org/docs/reference/extensions.html#extensions-are-resolved-statically
>> If a class has a member function, and an extension function is defined which has the same receiver type, the same name and is applicable to given arguments, the member always wins.
f
ah I missed that part, thanks!
😉 1