Zephir\ClassMethod::areReturnTypesDoubleCompatible PHP Method

areReturnTypesDoubleCompatible() public method

Checks whether at least one return type hint is double compatible
public areReturnTypesDoubleCompatible ( string $type = null ) : boolean
$type string
return boolean
    public function areReturnTypesDoubleCompatible($type = null)
    {
        if (count($this->returnTypes)) {
            foreach ($this->returnTypes as $returnType => $definition) {
                switch ($returnType) {
                    case 'double':
                        return true;
                }
            }
        }
        return false;
    }