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

closure can't use property #1873

Open
zuozhehao opened this issue Jun 20, 2019 · 2 comments · May be fixed by #2203
Open

closure can't use property #1873

zuozhehao opened this issue Jun 20, 2019 · 2 comments · May be fixed by #2203
Labels

Comments

@zuozhehao
Copy link

namespace Example;

class Closure
{
  protected test;

  public function callback()
  {

      return function ()  {

          return this->test;

      };
  }
}
@sergeyklay sergeyklay added the bug label Sep 25, 2019
@sergeyklay
Copy link
Contributor

@dreamsxin Could you please take a look

@dreamsxin
Copy link
Contributor

@sergeyklay We need check that, it in the return expression and call Closure::bindTo to bound object.

Jeckerson added a commit that referenced this issue Apr 8, 2021
@Jeckerson Jeckerson added this to the 0.13.x milestone Apr 13, 2021
@Jeckerson Jeckerson linked a pull request Apr 18, 2021 that will close this issue
3 tasks
@Jeckerson Jeckerson modified the milestones: 0.13.x, 0.14.x Sep 12, 2021
@Jeckerson Jeckerson modified the milestones: 0.14.x, Backlog Oct 3, 2021
@Jeckerson Jeckerson removed this from the Backlog milestone Sep 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants