Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
<?php
class Injectable
{
public function tomalaToda($argument)
{
return "Comete ". $argument;
}
}
class Golosa
{
public function damelaPapi($function)
{
echo $function("Esta");
}
}
$injectable = new Injectable;
$golosa = new Golosa();
$golosa->damelaPapi([$injectable, 'tomalaToda']);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.