Skip to content

Commit 003feeb

Browse files
committed
Deprecate the public constants in SQLParserUtils
1 parent e4978c2 commit 003feeb

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

UPGRADE.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,10 @@ Some of the constants were renamed in the process:
2323
* `DATETIMETZ` -> `DATETIMETZ_MUTABLE`
2424
* `TIME` -> `TIME_MUTABLE`
2525

26+
## Deprecated `SQLParserUtils` constants
27+
28+
The constants in `Doctrine\DBAL\SQLParserUtils` have been deprecated and will be made private in 3.0.
29+
2630
# Upgrade to 2.9
2731

2832
## Deprecated `Statement::fetchColumn()` with an invalid index
@@ -92,7 +96,7 @@ This method now throws SPL ``UnexpectedValueException`` instead of accidentally
9296

9397
## Doctrine\DBAL\Connection::TRANSACTION_* constants deprecated
9498

95-
``Doctrine\DBAL\Connection::TRANSACTION_*`` were moved into ``Doctrine\DBAL\TransactionIsolationLevel`` class without the ``TRANSACTION_`` prefix.
99+
``Doctrine\DBAL\Connection::TRANSACTION_*`` were moved into ``Doctrine\DBAL\TransactionIsolationLevel`` class without the ``TRANSACTION_`` prefix.
96100

97101
## DEPRECATION: direct usage of the PDO APIs in the DBAL API
98102

lib/Doctrine/DBAL/SQLParserUtils.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,12 @@ class SQLParserUtils
3030
*/
3131
public const POSITIONAL_TOKEN = '\?';
3232
public const NAMED_TOKEN = '(?<!:):[a-zA-Z_][a-zA-Z0-9_]*';
33-
/**#@-*/
34-
3533
// Quote characters within string literals can be preceded by a backslash.
3634
public const ESCAPED_SINGLE_QUOTED_TEXT = "(?:'(?:\\\\\\\\)+'|'(?:[^'\\\\]|\\\\'?|'')*')";
3735
public const ESCAPED_DOUBLE_QUOTED_TEXT = '(?:"(?:\\\\\\\\)+"|"(?:[^"\\\\]|\\\\"?)*")';
3836
public const ESCAPED_BACKTICK_QUOTED_TEXT = '(?:`(?:\\\\\\\\)+`|`(?:[^`\\\\]|\\\\`?)*`)';
37+
/**#@-*/
38+
3939
private const ESCAPED_BRACKET_QUOTED_TEXT = '(?<!\b(?i:ARRAY))\[(?:[^\]])*\]';
4040

4141
/**

0 commit comments

Comments
 (0)