public function getFunction($name)
    {
        $name = $this->getShortcut($name);

        // Check if we have looked this alias up before
        if ($function = $this->getLookup($name)) {
            return $function;
        }

        // Get the class / method we are trying to call
        $parts = $this->getAliasParts($name);

        if ($parts === false) {
            return false;
        }

        list($class, $method) = $parts;
        $class = strtolower($class);

        // Does that alias exist
        if (array_key_exists($class, $this->aliases)) {

            $class    = $this->aliases[$class];
            $function = new TwigFunction($name, $class.'::'.$method);

            $this->setLookup($name, $function);

            return $function;
        }

        return false;
    }