Fix for #4517 - Detecting class method as built-in function

Accidentally messed up pull request 10. This is a replacement one.

http://dev.kohanaframework.org/issues/4517