diff --git a/functionMap.php b/functionMap.php index eabe428..327aa5e 100644 --- a/functionMap.php +++ b/functionMap.php @@ -155,7 +155,7 @@ 'the_date' => ['($display is true ? void : string)'], 'the_modified_date' => ['($display is true ? void : string)'], 'the_title' => ['($display is true ? void : string|void)'], - 'trailingslashit' => ['non-falsy-string'], + 'trailingslashit' => ['non-falsy-string', '@phpstan-pure' => ''], 'urldecode_deep' => ['T', '@phpstan-template' => 'T', 'value' => 'T'], 'urlencode_deep' => ['T', '@phpstan-template' => 'T', 'value' => 'T'], 'validate_file' => ["(\$file is '' ? 0 : (\$allowed_files is empty ? 0|1|2 : 0|1|2|3))"], diff --git a/tests/data/pure/trailingslashit.php b/tests/data/pure/trailingslashit.php new file mode 100644 index 0000000..93e7cd4 --- /dev/null +++ b/tests/data/pure/trailingslashit.php @@ -0,0 +1,18 @@ +