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

[BUG] Interfaces Break In Child Projects #2334

Closed
Fenikkusu opened this issue Jan 1, 2022 · 0 comments · Fixed by #2335
Closed

[BUG] Interfaces Break In Child Projects #2334

Fenikkusu opened this issue Jan 1, 2022 · 0 comments · Fixed by #2335

Comments

@Fenikkusu
Copy link
Contributor

When zephir compiles the code, if the root namespace node of an interfaces matches the namespace of the extension you are compiling, zephir will incorrectly associate the interface with the current project, resulting in the error to the effect of 'twistersfury_phalcon_queue_job_jobinterface_ce' undeclared (first use in this function). In this example, I'm developing a project called under the namespace TwistersFury\ChatBot, using another extension I've built that uses the namespace TwistersFury\Phalcon\Queue. When zephir compiles, it sees the interface as part of the current extension. This results in the code snippet zend_class_implements(twistersfury_chatbot_cli_job_packet_ce, 1, twistersfury_phalcon_queue_job_jobinterface_ce); when it should be zend_class_implements(twistersfury_chatbot_cli_job_packet_ce, 1, zephir_get_internal_ce(SL("twistersfury\\phalcon\\queue\\job\\jobinterface")));.

Note: I'm not positive, but this may be what is causing the issue in Issue #2277, but that doesn't look like an interface.

@Fenikkusu Fenikkusu mentioned this issue Jan 1, 2022
3 tasks
@Jeckerson Jeckerson linked a pull request Jan 1, 2022 that will close this issue
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant