Stop Ignoring Important Returns with PHP 8.5’s `#[\NoDiscard]` Attribute
July 5, 2025 — When writing functions or methods in PHP, we often return values that are crucial for the caller to handle. Usually, those returned values need to be consumed. Check the following example.