Page MenuHomeWickedGov Phorge

ArrayTypeNode.php
No OneTemporary

Size
551 B
Referenced Files
None
Subscribers
None

ArrayTypeNode.php

<?php declare(strict_types = 1);
namespace PHPStan\PhpDocParser\Ast\Type;
use PHPStan\PhpDocParser\Ast\NodeAttributes;
class ArrayTypeNode implements TypeNode
{
use NodeAttributes;
public TypeNode $type;
public function __construct(TypeNode $type)
{
$this->type = $type;
}
public function __toString(): string
{
if (
$this->type instanceof CallableTypeNode
|| $this->type instanceof ConstTypeNode
|| $this->type instanceof NullableTypeNode
) {
return '(' . $this->type . ')[]';
}
return $this->type . '[]';
}
}

File Metadata

Mime Type
text/x-php
Expires
Sun, Nov 22, 20:34 (2 d, 1 m ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
7c/c6/c2112f77e05b9aef75a8ee6420c8
Default Alt Text
ArrayTypeNode.php (551 B)

Event Timeline