Skip to content

Prevent offsetGet on enums in const expr #58

Closed
@iluuu1994

Description

@iluuu1994

Based on this discussion. We need to prevent Foo::Bar[0] in const expressions because that would allow you to run arbitrary code in a constant expression (through offsetGet). This should probably be mentioned in the RFC.

Here's the tests, maybe that will make more sense:
iluuu1994/php-src@4f4c314

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions