Smartgf for method definition lookup