Skip to content
Snippets Groups Projects
Commit 38b9c42b authored by Oliver Klee's avatar Oliver Klee Committed by Stefan Bürk
Browse files

[TASK] Improve type annotations for ExpressionBuilder::literal()

PHPStan will (correctly) unify the previous type
`\PDO::PARAM_*|Connection::PARAM_*|int` to `int` (because
`\PDO::PARAM_*` as well as `Connection::PARAM_*` are all
ints).

So we're using the stricter `Connection::PARAM_*` now, which is a
superset of `\PDO::PARAM_*`.

This allows PHPStan to catch calls to this method with
incorrect values.

Resolves: #98512
Related: #98500
Releases: main, 11.5
Change-Id: I78efb486fe60aea2640435c8c48bd08ae8b3c3cd
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/76167


Tested-by: default avatarcore-ci <typo3@b13.com>
Tested-by: default avatarOliver Klee <typo3-coding@oliverklee.de>
Tested-by: default avatarStefan Bürk <stefan@buerk.tech>
Reviewed-by: default avatarOliver Klee <typo3-coding@oliverklee.de>
Reviewed-by: default avatarStefan Bürk <stefan@buerk.tech>
parent 9baf7a4f
Branches
Tags
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment