HH\ImmSet::__toString

Returns the string version of this ImmSet, which is "ImmSet"

Description

public function __toString(): string

Return Values

  • string - The string "ImmSet".

Examples

The string version of an ImmSet is always "ImmSet":

<?hh

namespace Hack\UserDocumentation\API\Examples\ImmSet\__toString;

$is = ImmSet {1, 2, 3};
echo $is."\n";

$is2 = ImmSet {'a', 'b', 'c'};
echo $is2."\n";

$is3 = ImmSet {};
echo $is3."\n";
Output
ImmSet
ImmSet
ImmSet