Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Errors when using $this in trait #143

Closed
roberthusak opened this issue Jan 8, 2018 · 0 comments
Closed

Errors when using $this in trait #143

roberthusak opened this issue Jan 8, 2018 · 0 comments
Assignees
Labels
Projects

Comments

@roberthusak
Copy link
Contributor

Test case:

<?php
trait T {
  public function bar() {
    return $this instanceof C;
  }
}
class C {
  use T;
}
echo (new C)->bar();

Expected result: 1
Actual result: NotImplementedException thrown from CodeGenerator.EmitAsObject(TypeSymbol, bool) during compilation.

The same happens in the case of CodeGenerator.EmitConvertToPhpValue.

@roberthusak roberthusak added this to TODO in MediaWiki via automation Jan 8, 2018
MediaWiki automation moved this from TODO to Done Jan 8, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
MediaWiki
  
Done
Development

No branches or pull requests

2 participants