# "Multiple Inheritance" for Interfaces

- Thread: https://externals.io/message/6409
- Original archive: https://news-web.php.net/php.internals/6409
- Started by Sebastian Bergmann on 2003-12-13T15:09:33+00:00
- Messages: 1
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #6409 — Sebastian Bergmann — 2003-12-13T15:09:33+00:00

URL: https://externals.io/message/6409#6409

While porting PicoContainer to PHP 5 I noticed that we currently do not
  support syntax to have an interface extend more than one parent
  interface.

  For instance

    interface A {}
    interface B {}
    interface C extends A, B {}

  is possible in Java while PHP 5 currently throws a syntax error, which
  it does not for

    interface A {}
    interface B {}
    interface C implements A, B {}

  I have now two questions:

    - Could we please add the syntax/semantic from Java so that interfaces
      can extend more than one parent interface?

    - Does

        interface C implements A, B {}

      do what I want?

  Greetings,
Sebastian

-- 
Sebastian Bergmann
http://sebastian-bergmann.de/                   http://phpOpenTracker.de/

Das Buch zu PHP 5: http://professionelle-softwareentwicklung-mit-php5.de/
