| [TASK] Add PHPStan extension to allow assertions (#1594) Suppress warnings for `assert()`s that, according to the DocBlock, can never fail, but in reality could, due to programmer error, since the DocBlock types are not enforced by PHP. This allows us to restore `treatPhpDocTypesAsCertain:true` for stricter static analysis, whilst also using assertions for runtime checks in a development environment, without cluttering up the code with `@phpstan-ignore` comments. The change parallels https://github.com/MyIntervals/emogrifier/pull/1624. It may be possible in future to move the extension to a separate package. | 2 个月前 |