Skip to content

Reflection::getModifierNames() with readonly modifier #8943

Closed
@adoy

Description

@adoy

Description

The following code:

<?php

var_dump(Reflection::getModifierNames(ReflectionProperty::IS_READONLY));

Resulted in this output:

array(0) {
}

But I expected this output instead:

array(1) {
  [0]=>
  string(8) "readonly"
}

PHP Version

PHP 8.1

Operating System

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions