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

Improve support of mixed type in objects #2330

Closed
Jeckerson opened this issue Dec 19, 2021 · 1 comment · Fixed by #2331, #2333 or #2337
Closed

Improve support of mixed type in objects #2330

Jeckerson opened this issue Dec 19, 2021 · 1 comment · Fixed by #2331, #2333 or #2337
Assignees

Comments

@Jeckerson
Copy link
Member

Jeckerson commented Dec 19, 2021

public function offsetGet(mixed index) -> mixed
{
    return this->{index};
}

generates error:

[ERROR] Variable type: mixed cannot be used in property-dynamic-access in /srv/phalcon/Mvc/Model/Row.zep on line 43

Also

public function offsetExists(mixed index) -> bool
{
    return isset this->{index};
}

generates error:

[ERROR] [mixed] in /srv/phalcon/Mvc/Model/Row.zep on line 55

@Jeckerson Jeckerson self-assigned this Dec 19, 2021
Jeckerson added a commit that referenced this issue Dec 19, 2021
Jeckerson added a commit that referenced this issue Dec 19, 2021
Jeckerson added a commit that referenced this issue Dec 19, 2021
Jeckerson added a commit that referenced this issue Dec 19, 2021
Jeckerson added a commit that referenced this issue Dec 19, 2021
@Jeckerson Jeckerson linked a pull request Dec 19, 2021 that will close this issue
3 tasks
Jeckerson added a commit that referenced this issue Dec 19, 2021
@Jeckerson
Copy link
Member Author

Cast from mixed to string also doesn't work:

[ERROR] Unknown type: mixed in /srv/phalcon/Support/Collection.zep on line 232

@Jeckerson Jeckerson reopened this Dec 20, 2021
Jeckerson added a commit that referenced this issue Dec 24, 2021
Jeckerson added a commit that referenced this issue Dec 24, 2021
@Jeckerson Jeckerson linked a pull request Dec 24, 2021 that will close this issue
3 tasks
Jeckerson added a commit that referenced this issue Dec 24, 2021
@Jeckerson Jeckerson reopened this Jan 3, 2022
@Jeckerson Jeckerson linked a pull request Jan 3, 2022 that will close this issue
3 tasks
Jeckerson added a commit that referenced this issue Jan 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant