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

Add support for interface #16

Open
Trismegiste opened this issue Oct 18, 2014 · 2 comments
Open

Add support for interface #16

Trismegiste opened this issue Oct 18, 2014 · 2 comments

Comments

@Trismegiste
Copy link

I've tried

interface Yopyop {
}

I've got :

PHP Parse error: syntax error, unexpected 'Y' in (program) on line 3

Did I miss something ? 👓

@asmblah
Copy link
Owner

asmblah commented Oct 18, 2014

Hi @Trismegiste,

Thanks for reporting this - unfortunately there's no support for interfaces in Uniter just yet. It's on my roadmap to be implemented at some point soon.

Cheers!

@asmblah
Copy link
Owner

asmblah commented Mar 24, 2015

Hi @Trismegiste,

There is now partial interface support in Uniter - constants defined on the interface are accessible from the interface or from classes that implement it, for example:

<?php

interface Yopyop {
    const a = 4;
}

class Test implements Yopyop {}

print Test::a;

Cheers!

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

No branches or pull requests

2 participants