PHPCompiler\Backend\PHP7\PECL::mapToCType PHP Method

mapToCType() protected method

protected mapToCType ( $type )
    protected function mapToCType($type)
    {
        switch ((string) $type) {
            case 'array':
                return 'HashTable*';
            case 'bool':
                return 'zend_bool';
            case 'float':
                return 'double';
            case 'int':
                return 'zend_long';
            case 'string':
                return 'zend_string*';
            case 'mixed':
                return 'zval';
        }
        if ($type->type === Type::TYPE_ARRAY) {
            return 'HashTable*';
        }
        return 'zval';
    }