Skip to content

Instantly share code, notes, and snippets.

View katzchang's full-sized avatar
🤯

Kazunori Otani katzchang

🤯
View GitHub Profile
<?php
class Curry
{
protected $callback, $bind;
protected function __construct($callback, Array $bind)
{
if(!is_callable($callback)) throw new InvalidArgumentException('$callback must be callable');
list($this->callback, $this->bind) = func_get_args();
}
<?php
class Curry
{
protected $callback, $bind;
protected function __construct($callback, Array $bind)
{
if(!is_callable($callback)) throw new InvalidArgumentException('$callback must be callable');
list($this->callback, $this->bind) = func_get_args();
}