Skip to content

Commit e9f62c6

Browse files
author
Rachel Goldfinger
committed
regenerate staleness tests
1 parent 9247790 commit e9f62c6

File tree

7 files changed

+168
-160
lines changed

7 files changed

+168
-160
lines changed

php/ext/google/protobuf/php-upb.c

Lines changed: 37 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1388,7 +1388,7 @@ const upb_MiniTable google__protobuf__GeneratedCodeInfo__Annotation_msg_init = {
13881388
const upb_MiniTable* google__protobuf__GeneratedCodeInfo__Annotation_msg_init_ptr = &google__protobuf__GeneratedCodeInfo__Annotation_msg_init;
13891389
const upb_MiniTableEnum google__protobuf__Edition_enum_init = {
13901390
64,
1391-
9,
1391+
10,
13921392
{
13931393
0x7,
13941394
0x0,
@@ -1397,6 +1397,7 @@ const upb_MiniTableEnum google__protobuf__Edition_enum_init = {
13971397
0x3e7,
13981398
0x3e8,
13991399
0x3e9,
1400+
0x270f,
14001401
0x1869d,
14011402
0x1869e,
14021403
0x1869f,
@@ -1655,7 +1656,7 @@ const upb_MiniTableFile google_protobuf_descriptor_proto_upb_file_layout = {
16551656

16561657

16571658

1658-
static const char descriptor[13195] = {
1659+
static const char descriptor[13218] = {
16591660
'\n', ' ', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o',
16601661
't', 'o', 'b', 'u', 'f', '/', 'd', 'e', 's', 'c', 'r', 'i',
16611662
'p', 't', 'o', 'r', '.', 'p', 'r', 'o', 't', 'o', '\022', '\017',
@@ -2712,7 +2713,7 @@ static const char descriptor[13195] = {
27122713
'n', 't', 'i', 'c', '\"', '(', '\n', '\010', 'S', 'e', 'm', 'a',
27132714
'n', 't', 'i', 'c', '\022', '\010', '\n', '\004', 'N', 'O', 'N', 'E',
27142715
'\020', '\000', '\022', '\007', '\n', '\003', 'S', 'E', 'T', '\020', '\001', '\022',
2715-
'\t', '\n', '\005', 'A', 'L', 'I', 'A', 'S', '\020', '\002', '*', '\247',
2716+
'\t', '\n', '\005', 'A', 'L', 'I', 'A', 'S', '\020', '\002', '*', '\276',
27162717
'\002', '\n', '\007', 'E', 'd', 'i', 't', 'i', 'o', 'n', '\022', '\023',
27172718
'\n', '\017', 'E', 'D', 'I', 'T', 'I', 'O', 'N', '_', 'U', 'N',
27182719
'K', 'N', 'O', 'W', 'N', '\020', '\000', '\022', '\023', '\n', '\016', 'E',
@@ -2724,38 +2725,40 @@ static const char descriptor[13195] = {
27242725
'\n', '\014', 'E', 'D', 'I', 'T', 'I', 'O', 'N', '_', '2', '0',
27252726
'2', '3', '\020', '\350', '\007', '\022', '\021', '\n', '\014', 'E', 'D', 'I',
27262727
'T', 'I', 'O', 'N', '_', '2', '0', '2', '4', '\020', '\351', '\007',
2728+
'\022', '\025', '\n', '\020', 'E', 'D', 'I', 'T', 'I', 'O', 'N', '_',
2729+
'U', 'N', 'S', 'T', 'A', 'B', 'L', 'E', '\020', '\217', 'N', '\022',
2730+
'\027', '\n', '\023', 'E', 'D', 'I', 'T', 'I', 'O', 'N', '_', '1',
2731+
'_', 'T', 'E', 'S', 'T', '_', 'O', 'N', 'L', 'Y', '\020', '\001',
27272732
'\022', '\027', '\n', '\023', 'E', 'D', 'I', 'T', 'I', 'O', 'N', '_',
2728-
'1', '_', 'T', 'E', 'S', 'T', '_', 'O', 'N', 'L', 'Y', '\020',
2729-
'\001', '\022', '\027', '\n', '\023', 'E', 'D', 'I', 'T', 'I', 'O', 'N',
2730-
'_', '2', '_', 'T', 'E', 'S', 'T', '_', 'O', 'N', 'L', 'Y',
2731-
'\020', '\002', '\022', '\035', '\n', '\027', 'E', 'D', 'I', 'T', 'I', 'O',
2732-
'N', '_', '9', '9', '9', '9', '7', '_', 'T', 'E', 'S', 'T',
2733-
'_', 'O', 'N', 'L', 'Y', '\020', '\235', '\215', '\006', '\022', '\035', '\n',
2734-
'\027', 'E', 'D', 'I', 'T', 'I', 'O', 'N', '_', '9', '9', '9',
2735-
'9', '8', '_', 'T', 'E', 'S', 'T', '_', 'O', 'N', 'L', 'Y',
2736-
'\020', '\236', '\215', '\006', '\022', '\035', '\n', '\027', 'E', 'D', 'I', 'T',
2737-
'I', 'O', 'N', '_', '9', '9', '9', '9', '9', '_', 'T', 'E',
2738-
'S', 'T', '_', 'O', 'N', 'L', 'Y', '\020', '\237', '\215', '\006', '\022',
2739-
'\023', '\n', '\013', 'E', 'D', 'I', 'T', 'I', 'O', 'N', '_', 'M',
2740-
'A', 'X', '\020', '\377', '\377', '\377', '\377', '\007', '*', 'U', '\n', '\020',
2741-
'S', 'y', 'm', 'b', 'o', 'l', 'V', 'i', 's', 'i', 'b', 'i',
2742-
'l', 'i', 't', 'y', '\022', '\024', '\n', '\020', 'V', 'I', 'S', 'I',
2743-
'B', 'I', 'L', 'I', 'T', 'Y', '_', 'U', 'N', 'S', 'E', 'T',
2744-
'\020', '\000', '\022', '\024', '\n', '\020', 'V', 'I', 'S', 'I', 'B', 'I',
2745-
'L', 'I', 'T', 'Y', '_', 'L', 'O', 'C', 'A', 'L', '\020', '\001',
2746-
'\022', '\025', '\n', '\021', 'V', 'I', 'S', 'I', 'B', 'I', 'L', 'I',
2747-
'T', 'Y', '_', 'E', 'X', 'P', 'O', 'R', 'T', '\020', '\002', 'B',
2748-
'~', '\n', '\023', 'c', 'o', 'm', '.', 'g', 'o', 'o', 'g', 'l',
2749-
'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 'B', '\020',
2750-
'D', 'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 'P', 'r',
2751-
'o', 't', 'o', 's', 'H', '\001', 'Z', '-', 'g', 'o', 'o', 'g',
2752-
'l', 'e', '.', 'g', 'o', 'l', 'a', 'n', 'g', '.', 'o', 'r',
2753-
'g', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 't',
2754-
'y', 'p', 'e', 's', '/', 'd', 'e', 's', 'c', 'r', 'i', 'p',
2755-
't', 'o', 'r', 'p', 'b', '\370', '\001', '\001', '\242', '\002', '\003', 'G',
2756-
'P', 'B', '\252', '\002', '\032', 'G', 'o', 'o', 'g', 'l', 'e', '.',
2757-
'P', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'R', 'e', 'f',
2758-
'l', 'e', 'c', 't', 'i', 'o', 'n',
2733+
'2', '_', 'T', 'E', 'S', 'T', '_', 'O', 'N', 'L', 'Y', '\020',
2734+
'\002', '\022', '\035', '\n', '\027', 'E', 'D', 'I', 'T', 'I', 'O', 'N',
2735+
'_', '9', '9', '9', '9', '7', '_', 'T', 'E', 'S', 'T', '_',
2736+
'O', 'N', 'L', 'Y', '\020', '\235', '\215', '\006', '\022', '\035', '\n', '\027',
2737+
'E', 'D', 'I', 'T', 'I', 'O', 'N', '_', '9', '9', '9', '9',
2738+
'8', '_', 'T', 'E', 'S', 'T', '_', 'O', 'N', 'L', 'Y', '\020',
2739+
'\236', '\215', '\006', '\022', '\035', '\n', '\027', 'E', 'D', 'I', 'T', 'I',
2740+
'O', 'N', '_', '9', '9', '9', '9', '9', '_', 'T', 'E', 'S',
2741+
'T', '_', 'O', 'N', 'L', 'Y', '\020', '\237', '\215', '\006', '\022', '\023',
2742+
'\n', '\013', 'E', 'D', 'I', 'T', 'I', 'O', 'N', '_', 'M', 'A',
2743+
'X', '\020', '\377', '\377', '\377', '\377', '\007', '*', 'U', '\n', '\020', 'S',
2744+
'y', 'm', 'b', 'o', 'l', 'V', 'i', 's', 'i', 'b', 'i', 'l',
2745+
'i', 't', 'y', '\022', '\024', '\n', '\020', 'V', 'I', 'S', 'I', 'B',
2746+
'I', 'L', 'I', 'T', 'Y', '_', 'U', 'N', 'S', 'E', 'T', '\020',
2747+
'\000', '\022', '\024', '\n', '\020', 'V', 'I', 'S', 'I', 'B', 'I', 'L',
2748+
'I', 'T', 'Y', '_', 'L', 'O', 'C', 'A', 'L', '\020', '\001', '\022',
2749+
'\025', '\n', '\021', 'V', 'I', 'S', 'I', 'B', 'I', 'L', 'I', 'T',
2750+
'Y', '_', 'E', 'X', 'P', 'O', 'R', 'T', '\020', '\002', 'B', '~',
2751+
'\n', '\023', 'c', 'o', 'm', '.', 'g', 'o', 'o', 'g', 'l', 'e',
2752+
'.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 'B', '\020', 'D',
2753+
'e', 's', 'c', 'r', 'i', 'p', 't', 'o', 'r', 'P', 'r', 'o',
2754+
't', 'o', 's', 'H', '\001', 'Z', '-', 'g', 'o', 'o', 'g', 'l',
2755+
'e', '.', 'g', 'o', 'l', 'a', 'n', 'g', '.', 'o', 'r', 'g',
2756+
'/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 't', 'y',
2757+
'p', 'e', 's', '/', 'd', 'e', 's', 'c', 'r', 'i', 'p', 't',
2758+
'o', 'r', 'p', 'b', '\370', '\001', '\001', '\242', '\002', '\003', 'G', 'P',
2759+
'B', '\252', '\002', '\032', 'G', 'o', 'o', 'g', 'l', 'e', '.', 'P',
2760+
'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'R', 'e', 'f', 'l',
2761+
'e', 'c', 't', 'i', 'o', 'n',
27592762
};
27602763

27612764
static _upb_DefPool_Init *deps[1] = {

php/ext/google/protobuf/php-upb.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6234,6 +6234,7 @@ typedef enum {
62346234
google_protobuf_EDITION_PROTO3 = 999,
62356235
google_protobuf_EDITION_2023 = 1000,
62366236
google_protobuf_EDITION_2024 = 1001,
6237+
google_protobuf_EDITION_UNSTABLE = 9999,
62376238
google_protobuf_EDITION_99997_TEST_ONLY = 99997,
62386239
google_protobuf_EDITION_99998_TEST_ONLY = 99998,
62396240
google_protobuf_EDITION_99999_TEST_ONLY = 99999,

php/ext/google/protobuf/wkt.inc

Lines changed: 124 additions & 124 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ static void google_protobuf_empty_proto_AddDescriptor();
1212
static void google_protobuf_field_mask_proto_AddDescriptor();
1313
static void google_protobuf_source_context_proto_AddDescriptor();
1414
static void google_protobuf_struct_proto_AddDescriptor();
15-
static void google_protobuf_type_proto_AddDescriptor();
1615
static void google_protobuf_timestamp_proto_AddDescriptor();
16+
static void google_protobuf_type_proto_AddDescriptor();
1717
static void google_protobuf_wrappers_proto_AddDescriptor();
1818
/* google/protobuf/any.proto */
1919

@@ -1610,6 +1610,127 @@ static void google_protobuf_NullValue_ModuleInit() {
16101610
strlen("NULL_VALUE"), 0);
16111611
}
16121612

1613+
/* google/protobuf/timestamp.proto */
1614+
1615+
zend_class_entry* GPBMetadata_Google_Protobuf_Timestamp_ce;
1616+
1617+
const char google_protobuf_timestamp_proto_descriptor [239] = {
1618+
'\n', '\037', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 't', 'i', 'm', 'e', 's', 't', 'a',
1619+
'm', 'p', '.', 'p', 'r', 'o', 't', 'o', '\022', '\017', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f',
1620+
'\"', '+', '\n', '\t', 'T', 'i', 'm', 'e', 's', 't', 'a', 'm', 'p', '\022', '\017', '\n', '\007', 's', 'e', 'c', 'o', 'n', 'd', 's', '\030',
1621+
'\001', ' ', '\001', '(', '\003', '\022', '\r', '\n', '\005', 'n', 'a', 'n', 'o', 's', '\030', '\002', ' ', '\001', '(', '\005', 'B', '\205', '\001', '\n', '\023',
1622+
'c', 'o', 'm', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 'B', '\016', 'T', 'i', 'm', 'e',
1623+
's', 't', 'a', 'm', 'p', 'P', 'r', 'o', 't', 'o', 'P', '\001', 'Z', '2', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'g', 'o', 'l', 'a',
1624+
'n', 'g', '.', 'o', 'r', 'g', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 't', 'y', 'p', 'e', 's', '/', 'k', 'n', 'o',
1625+
'w', 'n', '/', 't', 'i', 'm', 'e', 's', 't', 'a', 'm', 'p', 'p', 'b', '\370', '\001', '\001', '\242', '\002', '\003', 'G', 'P', 'B', '\252', '\002',
1626+
'\036', 'G', 'o', 'o', 'g', 'l', 'e', '.', 'P', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'W', 'e', 'l', 'l', 'K', 'n', 'o', 'w',
1627+
'n', 'T', 'y', 'p', 'e', 's', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3',
1628+
};
1629+
1630+
static void google_protobuf_timestamp_proto_AddDescriptor() {
1631+
if (DescriptorPool_HasFile("google/protobuf/timestamp.proto")) return;
1632+
DescriptorPool_AddDescriptor("google/protobuf/timestamp.proto", google_protobuf_timestamp_proto_descriptor,
1633+
sizeof(google_protobuf_timestamp_proto_descriptor));
1634+
}
1635+
1636+
static PHP_METHOD(GPBMetadata_Google_Protobuf_Timestamp, initOnce) {
1637+
google_protobuf_timestamp_proto_AddDescriptor();
1638+
}
1639+
1640+
static zend_function_entry GPBMetadata_Google_Protobuf_Timestamp_methods[] = {
1641+
PHP_ME(GPBMetadata_Google_Protobuf_Timestamp, initOnce, arginfo_void, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC)
1642+
ZEND_FE_END
1643+
};
1644+
1645+
static void GPBMetadata_Google_Protobuf_Timestamp_ModuleInit() {
1646+
zend_class_entry tmp_ce;
1647+
1648+
INIT_CLASS_ENTRY(tmp_ce, "GPBMetadata\\Google\\Protobuf\\Timestamp",
1649+
GPBMetadata_Google_Protobuf_Timestamp_methods);
1650+
1651+
GPBMetadata_Google_Protobuf_Timestamp_ce = zend_register_internal_class(&tmp_ce);
1652+
}
1653+
1654+
/* google_protobuf_Timestamp */
1655+
1656+
zend_class_entry* google_protobuf_Timestamp_ce;
1657+
1658+
static PHP_METHOD(google_protobuf_Timestamp, __construct) {
1659+
google_protobuf_timestamp_proto_AddDescriptor();
1660+
zim_Message___construct(INTERNAL_FUNCTION_PARAM_PASSTHRU);
1661+
}
1662+
1663+
static PHP_METHOD(google_protobuf_Timestamp, getSeconds) {
1664+
Message* intern = (Message*)Z_OBJ_P(getThis());
1665+
const upb_FieldDef *f = upb_MessageDef_FindFieldByName(
1666+
intern->desc->msgdef, "seconds");
1667+
zval ret;
1668+
Message_get(intern, f, &ret);
1669+
RETURN_COPY_VALUE(&ret);
1670+
}
1671+
1672+
static PHP_METHOD(google_protobuf_Timestamp, setSeconds) {
1673+
Message* intern = (Message*)Z_OBJ_P(getThis());
1674+
const upb_FieldDef *f = upb_MessageDef_FindFieldByName(
1675+
intern->desc->msgdef, "seconds");
1676+
zval *val;
1677+
if (zend_parse_parameters(ZEND_NUM_ARGS(), "z", &val)
1678+
== FAILURE) {
1679+
return;
1680+
}
1681+
Message_set(intern, f, val);
1682+
RETURN_COPY(getThis());
1683+
}
1684+
1685+
static PHP_METHOD(google_protobuf_Timestamp, getNanos) {
1686+
Message* intern = (Message*)Z_OBJ_P(getThis());
1687+
const upb_FieldDef *f = upb_MessageDef_FindFieldByName(
1688+
intern->desc->msgdef, "nanos");
1689+
zval ret;
1690+
Message_get(intern, f, &ret);
1691+
RETURN_COPY_VALUE(&ret);
1692+
}
1693+
1694+
static PHP_METHOD(google_protobuf_Timestamp, setNanos) {
1695+
Message* intern = (Message*)Z_OBJ_P(getThis());
1696+
const upb_FieldDef *f = upb_MessageDef_FindFieldByName(
1697+
intern->desc->msgdef, "nanos");
1698+
zval *val;
1699+
if (zend_parse_parameters(ZEND_NUM_ARGS(), "z", &val)
1700+
== FAILURE) {
1701+
return;
1702+
}
1703+
Message_set(intern, f, val);
1704+
RETURN_COPY(getThis());
1705+
}
1706+
1707+
ZEND_BEGIN_ARG_INFO_EX(arginfo_timestamp_fromdatetime, 0, 0, 1)
1708+
ZEND_ARG_INFO(0, datetime)
1709+
ZEND_END_ARG_INFO()
1710+
1711+
static zend_function_entry google_protobuf_Timestamp_phpmethods[] = {
1712+
PHP_ME(google_protobuf_Timestamp, __construct, arginfo_construct, ZEND_ACC_PUBLIC)
1713+
PHP_ME(google_protobuf_Timestamp, getSeconds, arginfo_void, ZEND_ACC_PUBLIC)
1714+
PHP_ME(google_protobuf_Timestamp, setSeconds, arginfo_setter, ZEND_ACC_PUBLIC)
1715+
PHP_ME(google_protobuf_Timestamp, getNanos, arginfo_void, ZEND_ACC_PUBLIC)
1716+
PHP_ME(google_protobuf_Timestamp, setNanos, arginfo_setter, ZEND_ACC_PUBLIC)
1717+
PHP_ME(google_protobuf_Timestamp, fromDateTime, arginfo_timestamp_fromdatetime, ZEND_ACC_PUBLIC)
1718+
PHP_ME(google_protobuf_Timestamp, toDateTime, arginfo_void, ZEND_ACC_PUBLIC)
1719+
ZEND_FE_END
1720+
};
1721+
1722+
static void google_protobuf_Timestamp_ModuleInit() {
1723+
zend_class_entry tmp_ce;
1724+
1725+
INIT_CLASS_ENTRY(tmp_ce, "Google\\Protobuf\\Timestamp",
1726+
google_protobuf_Timestamp_phpmethods);
1727+
1728+
google_protobuf_Timestamp_ce = zend_register_internal_class(&tmp_ce);
1729+
google_protobuf_Timestamp_ce->ce_flags |= ZEND_ACC_FINAL;
1730+
google_protobuf_Timestamp_ce->create_object = Message_create;
1731+
zend_do_inheritance(google_protobuf_Timestamp_ce, message_ce);
1732+
}
1733+
16131734
/* google/protobuf/type.proto */
16141735

16151736
zend_class_entry* GPBMetadata_Google_Protobuf_Type_ce;
@@ -2773,127 +2894,6 @@ static void google_protobuf_Syntax_ModuleInit() {
27732894
strlen("SYNTAX_EDITIONS"), 2);
27742895
}
27752896

2776-
/* google/protobuf/timestamp.proto */
2777-
2778-
zend_class_entry* GPBMetadata_Google_Protobuf_Timestamp_ce;
2779-
2780-
const char google_protobuf_timestamp_proto_descriptor [239] = {
2781-
'\n', '\037', 'g', 'o', 'o', 'g', 'l', 'e', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 't', 'i', 'm', 'e', 's', 't', 'a',
2782-
'm', 'p', '.', 'p', 'r', 'o', 't', 'o', '\022', '\017', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f',
2783-
'\"', '+', '\n', '\t', 'T', 'i', 'm', 'e', 's', 't', 'a', 'm', 'p', '\022', '\017', '\n', '\007', 's', 'e', 'c', 'o', 'n', 'd', 's', '\030',
2784-
'\001', ' ', '\001', '(', '\003', '\022', '\r', '\n', '\005', 'n', 'a', 'n', 'o', 's', '\030', '\002', ' ', '\001', '(', '\005', 'B', '\205', '\001', '\n', '\023',
2785-
'c', 'o', 'm', '.', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', 'B', '\016', 'T', 'i', 'm', 'e',
2786-
's', 't', 'a', 'm', 'p', 'P', 'r', 'o', 't', 'o', 'P', '\001', 'Z', '2', 'g', 'o', 'o', 'g', 'l', 'e', '.', 'g', 'o', 'l', 'a',
2787-
'n', 'g', '.', 'o', 'r', 'g', '/', 'p', 'r', 'o', 't', 'o', 'b', 'u', 'f', '/', 't', 'y', 'p', 'e', 's', '/', 'k', 'n', 'o',
2788-
'w', 'n', '/', 't', 'i', 'm', 'e', 's', 't', 'a', 'm', 'p', 'p', 'b', '\370', '\001', '\001', '\242', '\002', '\003', 'G', 'P', 'B', '\252', '\002',
2789-
'\036', 'G', 'o', 'o', 'g', 'l', 'e', '.', 'P', 'r', 'o', 't', 'o', 'b', 'u', 'f', '.', 'W', 'e', 'l', 'l', 'K', 'n', 'o', 'w',
2790-
'n', 'T', 'y', 'p', 'e', 's', 'b', '\006', 'p', 'r', 'o', 't', 'o', '3',
2791-
};
2792-
2793-
static void google_protobuf_timestamp_proto_AddDescriptor() {
2794-
if (DescriptorPool_HasFile("google/protobuf/timestamp.proto")) return;
2795-
DescriptorPool_AddDescriptor("google/protobuf/timestamp.proto", google_protobuf_timestamp_proto_descriptor,
2796-
sizeof(google_protobuf_timestamp_proto_descriptor));
2797-
}
2798-
2799-
static PHP_METHOD(GPBMetadata_Google_Protobuf_Timestamp, initOnce) {
2800-
google_protobuf_timestamp_proto_AddDescriptor();
2801-
}
2802-
2803-
static zend_function_entry GPBMetadata_Google_Protobuf_Timestamp_methods[] = {
2804-
PHP_ME(GPBMetadata_Google_Protobuf_Timestamp, initOnce, arginfo_void, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC)
2805-
ZEND_FE_END
2806-
};
2807-
2808-
static void GPBMetadata_Google_Protobuf_Timestamp_ModuleInit() {
2809-
zend_class_entry tmp_ce;
2810-
2811-
INIT_CLASS_ENTRY(tmp_ce, "GPBMetadata\\Google\\Protobuf\\Timestamp",
2812-
GPBMetadata_Google_Protobuf_Timestamp_methods);
2813-
2814-
GPBMetadata_Google_Protobuf_Timestamp_ce = zend_register_internal_class(&tmp_ce);
2815-
}
2816-
2817-
/* google_protobuf_Timestamp */
2818-
2819-
zend_class_entry* google_protobuf_Timestamp_ce;
2820-
2821-
static PHP_METHOD(google_protobuf_Timestamp, __construct) {
2822-
google_protobuf_timestamp_proto_AddDescriptor();
2823-
zim_Message___construct(INTERNAL_FUNCTION_PARAM_PASSTHRU);
2824-
}
2825-
2826-
static PHP_METHOD(google_protobuf_Timestamp, getSeconds) {
2827-
Message* intern = (Message*)Z_OBJ_P(getThis());
2828-
const upb_FieldDef *f = upb_MessageDef_FindFieldByName(
2829-
intern->desc->msgdef, "seconds");
2830-
zval ret;
2831-
Message_get(intern, f, &ret);
2832-
RETURN_COPY_VALUE(&ret);
2833-
}
2834-
2835-
static PHP_METHOD(google_protobuf_Timestamp, setSeconds) {
2836-
Message* intern = (Message*)Z_OBJ_P(getThis());
2837-
const upb_FieldDef *f = upb_MessageDef_FindFieldByName(
2838-
intern->desc->msgdef, "seconds");
2839-
zval *val;
2840-
if (zend_parse_parameters(ZEND_NUM_ARGS(), "z", &val)
2841-
== FAILURE) {
2842-
return;
2843-
}
2844-
Message_set(intern, f, val);
2845-
RETURN_COPY(getThis());
2846-
}
2847-
2848-
static PHP_METHOD(google_protobuf_Timestamp, getNanos) {
2849-
Message* intern = (Message*)Z_OBJ_P(getThis());
2850-
const upb_FieldDef *f = upb_MessageDef_FindFieldByName(
2851-
intern->desc->msgdef, "nanos");
2852-
zval ret;
2853-
Message_get(intern, f, &ret);
2854-
RETURN_COPY_VALUE(&ret);
2855-
}
2856-
2857-
static PHP_METHOD(google_protobuf_Timestamp, setNanos) {
2858-
Message* intern = (Message*)Z_OBJ_P(getThis());
2859-
const upb_FieldDef *f = upb_MessageDef_FindFieldByName(
2860-
intern->desc->msgdef, "nanos");
2861-
zval *val;
2862-
if (zend_parse_parameters(ZEND_NUM_ARGS(), "z", &val)
2863-
== FAILURE) {
2864-
return;
2865-
}
2866-
Message_set(intern, f, val);
2867-
RETURN_COPY(getThis());
2868-
}
2869-
2870-
ZEND_BEGIN_ARG_INFO_EX(arginfo_timestamp_fromdatetime, 0, 0, 1)
2871-
ZEND_ARG_INFO(0, datetime)
2872-
ZEND_END_ARG_INFO()
2873-
2874-
static zend_function_entry google_protobuf_Timestamp_phpmethods[] = {
2875-
PHP_ME(google_protobuf_Timestamp, __construct, arginfo_construct, ZEND_ACC_PUBLIC)
2876-
PHP_ME(google_protobuf_Timestamp, getSeconds, arginfo_void, ZEND_ACC_PUBLIC)
2877-
PHP_ME(google_protobuf_Timestamp, setSeconds, arginfo_setter, ZEND_ACC_PUBLIC)
2878-
PHP_ME(google_protobuf_Timestamp, getNanos, arginfo_void, ZEND_ACC_PUBLIC)
2879-
PHP_ME(google_protobuf_Timestamp, setNanos, arginfo_setter, ZEND_ACC_PUBLIC)
2880-
PHP_ME(google_protobuf_Timestamp, fromDateTime, arginfo_timestamp_fromdatetime, ZEND_ACC_PUBLIC)
2881-
PHP_ME(google_protobuf_Timestamp, toDateTime, arginfo_void, ZEND_ACC_PUBLIC)
2882-
ZEND_FE_END
2883-
};
2884-
2885-
static void google_protobuf_Timestamp_ModuleInit() {
2886-
zend_class_entry tmp_ce;
2887-
2888-
INIT_CLASS_ENTRY(tmp_ce, "Google\\Protobuf\\Timestamp",
2889-
google_protobuf_Timestamp_phpmethods);
2890-
2891-
google_protobuf_Timestamp_ce = zend_register_internal_class(&tmp_ce);
2892-
google_protobuf_Timestamp_ce->ce_flags |= ZEND_ACC_FINAL;
2893-
google_protobuf_Timestamp_ce->create_object = Message_create;
2894-
zend_do_inheritance(google_protobuf_Timestamp_ce, message_ce);
2895-
}
2896-
28972897
/* google/protobuf/wrappers.proto */
28982898

28992899
zend_class_entry* GPBMetadata_Google_Protobuf_Wrappers_ce;
@@ -3415,6 +3415,8 @@ static void WellKnownTypes_ModuleInit() {
34153415
google_protobuf_Value_ModuleInit();
34163416
google_protobuf_ListValue_ModuleInit();
34173417
google_protobuf_NullValue_ModuleInit();
3418+
GPBMetadata_Google_Protobuf_Timestamp_ModuleInit();
3419+
google_protobuf_Timestamp_ModuleInit();
34183420
GPBMetadata_Google_Protobuf_Type_ModuleInit();
34193421
google_protobuf_Type_ModuleInit();
34203422
google_protobuf_Field_ModuleInit();
@@ -3424,8 +3426,6 @@ static void WellKnownTypes_ModuleInit() {
34243426
google_protobuf_EnumValue_ModuleInit();
34253427
google_protobuf_Option_ModuleInit();
34263428
google_protobuf_Syntax_ModuleInit();
3427-
GPBMetadata_Google_Protobuf_Timestamp_ModuleInit();
3428-
google_protobuf_Timestamp_ModuleInit();
34293429
GPBMetadata_Google_Protobuf_Wrappers_ModuleInit();
34303430
google_protobuf_DoubleValue_ModuleInit();
34313431
google_protobuf_FloatValue_ModuleInit();

0 commit comments

Comments
 (0)