Skip to content

[BUG] Interfaces Break In Child Projects #2334

Closed
@Fenikkusu

Description

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.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions