netbeans icon indicating copy to clipboard operation
netbeans copied to clipboard

[PHP] No IDE hint for promoted properties with @mixin

Open terax6669 opened this issue 3 years ago • 0 comments

Apache NetBeans version

Apache NetBeans 15

What happened

NetBeans fails to provide hints for promoted properties in a child property when introduced via @mixin. image

How to reproduce

<?php

/**
 * @property-read Data $data
 */
class IdeHelperDataContainer
{
}

/**
 * @mixin IdeHelperDataContainer
 */
class DataContainer
{
}

class Data
{
	public function __construct(
		public readonly array $foo,
	) {

	}
}

$container = new DataContainer();
$data = new Data([]);

$container->data; // works
$container->data->foo; // no ide hint!
$data->foo; // works

Did this work correctly in an earlier version?

No / Don't know

Operating System

Windows 11 Pro 22000.978

JDK

OpenJDK 19.0.0 (from Chocolatey)

Apache NetBeans packaging

Apache NetBeans provided installer

Anything else

Only when using @mixin.

Are you willing to submit a pull request?

No

Code of Conduct

Yes

terax6669 avatar Sep 25 '22 14:09 terax6669