3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php abstract class AbstractRetriever implements UriRetrieverInterface { /** * Media content type * @var string */ protected $contentType; /** * {@inheritDoc} * @see \JsonSchema\Uri\Retrievers\UriRetrieverInterface::retrieve() */ public abstract function retrieve($uri); /** * {@inheritDoc} * @see \JsonSchema\Uri\Retrievers\UriRetrieverInterface::getContentType() */ public function getContentType() { return $this->contentType; } } interface UriRetrieverInterface { /** * Retrieve a schema from the specified URI * @param string $uri URI that resolves to a JSON schema * @throws \JsonSchema\Exception\ResourceNotFoundException * @return mixed string|null */ public function retrieve($uri); /** * Get media content type * @return string */ public function getContentType(); } ?>
Output for 5.3.9 - 7.1.0
Output for 5.3.0 - 5.3.8
Fatal error: Can't inherit abstract function UriRetrieverInterface::retrieve() (previously declared abstract in AbstractRetriever) in /in/I9uP3 on line 4
Process exited with code 255.
Output for 5.0.0 - 5.2.17
Fatal error: Can't inherit abstract function UriRetrieverInterface::retrieve() (previously declared abstract in AbstractRetriever) in /in/I9uP3 on line 3
Process exited with code 255.
Output for 4.4.2 - 4.4.9
Parse error: syntax error, unexpected T_CLASS in /in/I9uP3 on line 3
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1
Parse error: parse error, unexpected T_CLASS in /in/I9uP3 on line 3
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error in /in/I9uP3 on line 3
Process exited with code 255.