1 | <?php |
||
2 | |||
3 | declare(strict_types=1); |
||
4 | |||
5 | namespace PhpSpellcheck; |
||
6 | |||
7 | if (!\function_exists(t::class)) { |
||
8 | /** |
||
9 | * @param array<mixed> $context |
||
10 | */ |
||
11 | function t(string $string = '', array $context = []): Text |
||
0 ignored issues
–
show
|
|||
12 | { |
||
13 | return new Text($string, $context); |
||
14 | } |
||
15 | } |
||
16 |
Adding explicit visibility (
private
,protected
, orpublic
) is generally recommend to communicate to other developers how, and from where this method is intended to be used.