Use Genfun#addMethod instead of the static version