Skip to content

Commit

Permalink
ENH PHP 8.2 support
Browse files Browse the repository at this point in the history
  • Loading branch information
emteknetnz committed Dec 14, 2022
1 parent bf440e4 commit c1cc275
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"composer/installers": "^2.2",
"guzzlehttp/guzzle": "^7.5.0",
"guzzlehttp/psr7": "^2.4.0",
"embed/embed": "^4.4.4",
"embed/embed": "^4.4.7",
"league/csv": "^9.8.0",
"m1/env": "^2.2.0",
"monolog/monolog": "^3.2.0",
Expand Down
2 changes: 1 addition & 1 deletion src/Control/HTTPRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -579,7 +579,7 @@ public function match($pattern, $shiftOnSuccess = false)
$shiftCount = sizeof($patternParts ?? []);
$remaining = count($this->dirParts ?? []) - $i;
for ($j = 1; $j <= $remaining; $j++) {
$arguments["$${j}"] = $this->dirParts[$j + $i - 1];
$arguments['$' . $j] = $this->dirParts[$j + $i - 1];
}
$patternParts = array_merge($patternParts, array_keys($arguments ?? []));
break;
Expand Down
1 change: 1 addition & 0 deletions src/Core/Manifest/ClassManifest.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
*
* To be consistent; In general all array keys are lowercase, and array values are correct-case
*/
#[\AllowDynamicProperties]
class ClassManifest
{
/**
Expand Down
2 changes: 2 additions & 0 deletions src/ORM/Connect/MySQLDatabase.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ class MySQLDatabase extends Database implements TransactionManager
*/
private $transactionManager = null;

private int $transactionNesting = 0;

/**
* Default collation
*
Expand Down
1 change: 0 additions & 1 deletion src/ORM/Connect/MySQLStatement.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,6 @@ public function __construct($statement, $metadata)
public function __destruct()
{
$this->statement->close();
$this->currentRecord = false;
}

/**
Expand Down
1 change: 1 addition & 0 deletions src/View/ViewableData.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
* is provided and automatically escaped by ViewableData. Any class that needs to be available to a view (controllers,
* {@link DataObject}s, page controls) should inherit from this class.
*/
#[\AllowDynamicProperties]
class ViewableData implements IteratorAggregate
{
use Extensible {
Expand Down
7 changes: 7 additions & 0 deletions thirdparty/php-peg/Parser.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,13 @@
* the bracket if a failed match + restore has moved the current position backwards - so we have to check that too.
*/
class ParserRegexp {

public $parser;
public $rx;
public $matches;
public $match_pos;
public $check_pos;

function __construct( $parser, $rx ) {
$this->parser = $parser ;
$this->rx = $rx . 'Sx' ;
Expand Down

0 comments on commit c1cc275

Please sign in to comment.