final class ParameterShape
Restricted visibility: declared "@visibility root". Code outside that scope must not name this declaration.

One declared parameter of a function or method.

Properties§

public string $name
public TypeShape $type
public Expr|null $default = null
public bool $variadic = false

Methods§

public function __construct(
    public string $name,
    public TypeShape $type,
    public Expr|null $default = null,
    public bool $variadic = false,
)

Parameters

$namestringThe parameter name without its sigil
$typeTypeShapeThe declared type
$defaultExpr|nullThe default value expression, when the parameter has one
$variadicboolWhether the parameter collects the remaining arguments

Test cases 24§

Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.

Dedicated tests 2
Other tests reaching this symbol 22

Relations§

Instantiated in 1