website/errors/mixin.internalInterface.md
<?php declare(strict_types = 1);
namespace Vendor {
/** @internal */
interface InternalInterface {
public function doFoo(): void;
}
}
namespace App {
/** @mixin \Vendor\InternalInterface */
class MyClass {}
}
The @mixin PHPDoc tag references an interface that is marked as @internal. Internal interfaces are not part of the public API of the package that defines them. Referencing internal types in PHPDoc tags creates a dependency on implementation details that may change without notice in future versions of the package.
Use a public (non-internal) interface or class provided by the package instead:
namespace App {
- /** @mixin \Vendor\InternalInterface */
+ /** @mixin \Vendor\PublicInterface */
class MyClass {}
}
If no public alternative exists, remove the @mixin tag and implement the needed methods directly in the class.