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

Error: Enum case value must be compile-time evaluatable #1671

Open
cawa-93 opened this issue Nov 11, 2024 · 3 comments
Open

Error: Enum case value must be compile-time evaluatable #1671

cawa-93 opened this issue Nov 11, 2024 · 3 comments
Labels

Comments

@cawa-93
Copy link

cawa-93 commented Nov 11, 2024

I'm getting an error when try to parse project on Enum:

use Webspark\Streetmedia\PartnerCabinet\Plugin;

enum FaqSettings: string implements SettingDefinition
{
    case INDEX_PAGE_ID = Plugin::NAMESPACE . '__faq_settings__index_page_id';
}

The Plugin::NAMESPACE is a const so AFAIK it should be compile-time evaluatable ?

@DerManoMann
Copy link
Collaborator

Yep, looks like a bug. Good news is that this seems to work with the 5x-dev branch :) It would be great if you could try that and let me know how that goes.

[v5] is planned to be released in the next few weeks, once PHP 8.4 is officially available.

@cawa-93
Copy link
Author

cawa-93 commented Nov 13, 2024

@DerManoMann How I can try 5x-dev branch ?

@DerManoMann
Copy link
Collaborator

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants