Skip to content

A denied read of a private int property that falls back to __get returning a string yields garbage instead of the string #419

Closed

Description

@blacktrs

Summary

A denied read of a private int property that falls back to __get returning a string yields garbage instead of the string.

Repro

<?php
class A {
    private int $x = 1;
    public function __get($n) { return "magic:$n"; }
}
$o = new A;
var_dump($o->x);

Expected (php)

string(7) "magic:x"

Actual (manticore 35461ba2, Darwin arm64)

int(4338782992)

Tracking

Known-bug repro: tests/aot/repro/wrong/denied_property_read_falls_back_to_get_with_other_type.php — bash tests/aot/xfail.sh -k denied_property_read_falls_back_to_get_with_other_type reports XFAIL while this is open and XPASS once it is fixed; then move the repro into tests/aot/cases/ and close this issue.

Activity

  1. added
    bug
    wrong-answer
    on Oct 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugwrong-answer

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions