From cd003b878c4ed843d79692079b0acc8f74d6ce3d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Stefan=20B=C3=BCrk?= <stefan@buerk.tech>
Date: Wed, 24 Jan 2024 23:42:26 +0100
Subject: [PATCH] [!!!][TASK] Remove `ExpressionBuilder::QUOTE_*` constants
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

The `ExpressionBUilder::QUOTE_*` class constants are
unused already with TYPO3 v12 and `Doctrine DBAL 3.x`
and do not serve any purpose anymore.

This change removes them now to keep the house clean.

Resolves: #102919
Related: #102875
Releases: main
Change-Id: Idc991625c8ce4799452f098bff675c744d4cb37d
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/82639
Tested-by: Stefan Bürk <stefan@buerk.tech>
Reviewed-by: Oliver Bartsch <bo@cedev.de>
Reviewed-by: Oliver Klee <typo3-coding@oliverklee.de>
Reviewed-by: Stefan Bürk <stefan@buerk.tech>
Tested-by: Oliver Bartsch <bo@cedev.de>
Tested-by: core-ci <typo3@b13.com>
Tested-by: Oliver Klee <typo3-coding@oliverklee.de>
---
 .../Database/Query/Expression/ExpressionBuilder.php    |  4 ----
 .../13.0/Breaking-102875-ExpressionBuilderChanges.rst  | 10 +++++++++-
 2 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/typo3/sysext/core/Classes/Database/Query/Expression/ExpressionBuilder.php b/typo3/sysext/core/Classes/Database/Query/Expression/ExpressionBuilder.php
index eb5fcb04ba86..a7046d47d147 100644
--- a/typo3/sysext/core/Classes/Database/Query/Expression/ExpressionBuilder.php
+++ b/typo3/sysext/core/Classes/Database/Query/Expression/ExpressionBuilder.php
@@ -38,10 +38,6 @@ use Doctrine\DBAL\Query\Expression\ExpressionBuilder as DoctrineExpressionBuilde
  */
 class ExpressionBuilder extends DoctrineExpressionBuilder
 {
-    final public const QUOTE_NOTHING = 0;
-    final public const QUOTE_IDENTIFIER = 1;
-    final public const QUOTE_PARAMETER = 2;
-
     public function __construct(protected readonly DoctrineConnection $connection)
     {
         // parent::__construct() skipped by intention, otherwise the private property
diff --git a/typo3/sysext/core/Documentation/Changelog/13.0/Breaking-102875-ExpressionBuilderChanges.rst b/typo3/sysext/core/Documentation/Changelog/13.0/Breaking-102875-ExpressionBuilderChanges.rst
index c7bfc612ca17..3b55af206380 100644
--- a/typo3/sysext/core/Documentation/Changelog/13.0/Breaking-102875-ExpressionBuilderChanges.rst
+++ b/typo3/sysext/core/Documentation/Changelog/13.0/Breaking-102875-ExpressionBuilderChanges.rst
@@ -11,11 +11,19 @@ See :issue:`102875`
 Description
 ===========
 
-Signature changes:
+Signature changes for following methods
+---------------------------------------
 
 *  :php:`ExpressionBuilder::literal(string $value)`: Value must be a string now.
 *  :php:`ExpressionBuilder::trim(): Only `TrimMode` enum for `$position` argument.
 
+Following class constants have been removed
+-------------------------------------------
+
+*   :php:`QUOTE_NOTHING`: Not used since already TYPO3 v12 and Doctrine DBAL 3.x.
+*   :php:`QUOTE_IDENTIFIER`: Not used since already TYPO3 v12 and Doctrine DBAL 3.x.
+*   :php:`QUOTE_PARAMETER`: Not used since already TYPO3 v12 and Doctrine DBAL 3.x.
+
 Impact
 ======
 
-- 
GitLab