diff --git a/phpstan-tests.neon b/phpstan-tests.neon index 60e562e..e574e17 100644 --- a/phpstan-tests.neon +++ b/phpstan-tests.neon @@ -1,5 +1,3 @@ parameters: autoload_files: - tests/phpstan-bootstrap.php - ignoreErrors: - - '#Cannot cast Ramsey\\Uuid\\UuidInterface to string.#' diff --git a/src/UuidInterface.php b/src/UuidInterface.php index 42a3ad7..462fea3 100644 --- a/src/UuidInterface.php +++ b/src/UuidInterface.php @@ -266,9 +266,16 @@ interface UuidInterface extends JsonSerializable, Serializable public function getVersion(); /** - * Converts this UUID into a string representation. + * Returns a string representation of this UUID. * * @return string */ public function toString(); + + /** + * Allows casting this UUID to a string representation. + * + * @return string + */ + public function __toString(); }