-
-
Notifications
You must be signed in to change notification settings - Fork 294
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
Compile Error: Constant expression contains invalid operations #961
Comments
Transferring to |
So far the only sensible way I've figured to get default's value definition from Summing up: in my opinion we've reached limits of what we can achieve with current proxy generation but I'd like to hear a second thought @doctrine/doctrinecore |
Pinging @Ocramius for his opinion on the matter - TBH ORM should really drop doctrine/common proxies and start using proxy-manager for this. |
Even with proxy-manager, default expressions containing object instantiations aren't really supported yet. That would require moving away from reflection, and instead use something like I completely missed the RFC (https://wiki.php.net/rfc/new_in_initializers): would've raised my concern there. |
BTW, that is one of the largest areas of concern why |
New initializers are accessible as source code via reflection. I specifically asked Nikita to allow this for such use cases. |
See php/php-src#7540 |
Oh, and I submitted support for them at Ocramius/ProxyManager#755 |
Hah, so parsing |
Bug Report
Compile Error: Constant expression contains invalid operations
Summary
Entity with following method
as result getting proxy like this:
This will work:
The text was updated successfully, but these errors were encountered: