Re: adding class entry getter for JsonSerializeable

From: Date: Fri, 13 Sep 2013 17:23:27 +0000
Subject: Re: adding class entry getter for JsonSerializeable
References: 1 2 3  Groups: php.internals 
Request: Send a blank email to [email protected] to get a copy of this message
2013/9/8 Johannes Schlüter <[email protected]>

> that only affects code in the same linker run (executable binary or .so)
> as weak the linker to hide symbols. For stuff that should work in other
> extensions one has to mark them as ZEND_API in the engine or PHPAPI in
> core stuff, or a custom EXTENSIONNAME_API (see different
> ext/foo/php_foo.h headers)
>

Thanks pointing it! I marked php_json_serialize_ce to PHP_JSON_API then it
seems it can resolve.

https://github.com/chobie/php-src/commit/80023e80102c6ef6b0248b30ecf68b52d6ef8831


Let me assumed Protobuf extension (not PECL proposed yet) can implement
JsonSerializeable interface internally.
It's very easy to encode protobuf message as json. and, User-land code is
able to implement JsonSerialize.
It should be possible also other extensions, I think it's natural.

This is my first time to suggest feature request. What should I do next?
I have [email protected] account but maybe I don't have wiki karma.

Thanks,


Thread (5 messages)

« previous php.internals (#69121) next »