diff options
author | Paul Yang <TeBoring@users.noreply.github.com> | 2017-03-01 10:39:48 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-03-01 10:39:48 -0800 |
commit | bcbaabe53a8d661f5a473d2a157a4278ad8bf579 (patch) | |
tree | 173e7e07319f10451e2ec290c00cba89a34b647e /php/ext/google/protobuf/array.c | |
parent | 7339fc04c49a055ec0688cd0cb24cf7ea64f7783 (diff) | |
download | protobuf-bcbaabe53a8d661f5a473d2a157a4278ad8bf579.tar.gz protobuf-bcbaabe53a8d661f5a473d2a157a4278ad8bf579.tar.bz2 protobuf-bcbaabe53a8d661f5a473d2a157a4278ad8bf579.zip |
Add mergeFrom method on Message (#2766)
This method merges the contents of the specified message into the
current message. Singular fields that are set in the specified message
overwrite the corresponding fields in the current message. Repeated
fields are appended. Map fields key-value pairs are overritten.
Singular/Oneof sub-messages are recursively merged. All overritten
sub-messages are deep-copied.
Diffstat (limited to 'php/ext/google/protobuf/array.c')
-rw-r--r-- | php/ext/google/protobuf/array.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/php/ext/google/protobuf/array.c b/php/ext/google/protobuf/array.c index e4a88c39..63bb6d0a 100644 --- a/php/ext/google/protobuf/array.c +++ b/php/ext/google/protobuf/array.c @@ -106,6 +106,7 @@ void repeated_field_init(TSRMLS_D) { repeated_field_handlers = PEMALLOC(zend_object_handlers); memcpy(repeated_field_handlers, zend_get_std_object_handlers(), sizeof(zend_object_handlers)); + repeated_field_handlers->write_dimension = repeated_field_write_dimension; repeated_field_handlers->get_gc = repeated_field_get_gc; } |