zendframework/zf2 — pull request #4534 by gwis (2013-05-23 18:11:33+00:00)
Title: Introduce JsonSerializable polyfill and support in Zend\Json\Encoder

This is an alternative to https://github.com/zendframework/zf2/pull/4507

It introduces a polyfill into `Zend\Stdlib` which can be used by legacy PHP implementations. `Zend\Json\Encoder` then tests for the PHP built-in interface which will work even on PHP implementations where `\JsonSerializable` doesn't exist.