I disagree with removing the -Interface suffix. Not so much that I think it has to be there, but more along the lines of if it isn't going to be there then the FIG should select a new, perhaps less verbose, naming convention instead.
I feel the suffix gives clarity and informs consumers/implementers that a type hint is dealing with an interface and not a concrete class. Thanks, Jason On Mon, Aug 15, 2016, 3:35 PM Niklas Keller <[email protected]> wrote: > I strongly support this. We took the same decision for async-interop: > https://github.com/async-interop/event-loop/issues/5 > > How do you propose to resolve this common problem? >> namespace Zend\Diactoros; >> use Psr\Http\Message\ServerRequestInterface; >> class ServerRequest implements ServerRequestInterface { ... } > > > If you really want to use the same name, just alias the PSR interface: > > namespace Zend\Diactoros; > > use Psr\Http\Message\ServerRequest as PsrServerRequest; > > class ServerRequest implements PsrServerRequest { ... } > > Requiring the interface to be aliased in each and every file it's used is > a lot worse than having one single alias in an implementation. > > -- > You received this message because you are subscribed to the Google Groups > "PHP Framework Interoperability Group" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/php-fig/7eb5ba06-515a-41c3-bae7-9db47c41b5c4%40googlegroups.com > <https://groups.google.com/d/msgid/php-fig/7eb5ba06-515a-41c3-bae7-9db47c41b5c4%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "PHP Framework Interoperability Group" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/php-fig/CAKjuMEE4goZuEtYZnYXm2%2B6oD7Xkgjjdp%2B06tBipaPLc0bQz3w%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
