Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

enque/dbal v0.10.25 incorrectly claims php 7.4 support #1393

Open
@faldor20

Description

When using enque/dbal v0.10.25 with php 7.4 the follwing error is thrown: Cannot use ::class with dynamic class name
The following code snippet of DbalContext.php shows the use of $connection::class.

 public function getDbalConnection(): Connection
 {
 if (false == $this->connection) {
 $connection = call_user_func($this->connectionFactory);
 if (false == $connection instanceof Connection) {
 throw new \LogicException(sprintf('The factory must return instance of Doctrine\DBAL\Connection. It returns %s', is_object($connection) ? $connection::class : gettype($connection)));
 }
 $this->connection = $connection;
 }
 return $this->connection;
 }

Using ::class on a variable is a php 8.0 feature, not available in php 7.4

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /