Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:103826 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 56546 invoked from network); 24 Jan 2019 17:24:09 -0000 Received: from unknown (HELO mail-oi1-f170.google.com) (209.85.167.170) by pb1.pair.com with SMTP; 24 Jan 2019 17:24:09 -0000 Received: by mail-oi1-f170.google.com with SMTP id m6so4848248oig.11 for ; Thu, 24 Jan 2019 06:02:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=k4GngcWrU7v0p7LIEcHAxmrOW08tHhECavL8uY/wQqA=; b=qspcF847GepMNYtEWIq7z/bU9NsvEGpWV1uwAckWxAbg4yKC0BxIQ8Jy8tRZwsiP2s FEXWL8nh/u0VjPxSxVuwHEu5edgggutUYNxSH+vAlNKY18//z12V/PT4x1W+gPupwwL+ crNGdCrQcoAWolsfRFtiLWCT2ggDOKfTG6ygo5pgjwmOARB0tX129fzOBF1RlEghvdv7 eeRrkvggAgOG+qb1DpIvyN7VxY19Z/mtv7IvYkI2TGqzvNJTbtFZ+m4xq6rzv4BVuoSc B1pTfleyQqHOBtk5vvne8JxrQ/V/xu343hPrY1guD5eaz+mH74ppW66RnN+L7461QRsK vRug== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=k4GngcWrU7v0p7LIEcHAxmrOW08tHhECavL8uY/wQqA=; b=Sgvirit3PMwvpP/SXQ5O0dFUhtga7iBnykb1LADuHux3YUj3PP50RYv/W1qU7y6w/d NF9HRMV+io+iOuzB74uFZQ6NzOY0H+DnmmNcbphSIj7zLL78pLS339r0Dc7RyDKPAYhx Oe6uVDxeU4v91Off9YFdJj1diWwFfFCL3lXtRriZDgNrOtLEMZ1hsONwRP+XXRzL808X AqbueIHAqhNXBetWSz7QxiB+wIDMdSUPdLAR8JQ4jpp1Cfanphnaa3fxPciCpWT2fpVJ RWG3D43H8Ih27GXAwguh6N/YvFfVbpDeSA7feIitefjBHbJseXOmwdFe/MmpCQw8yhEu 7OdA== X-Gm-Message-State: AJcUukeDLqUcg1GPCoh6ESd66yPtaRKY3rpQWeAACa49h4E5Xty55jUf iiUxg6h+PP0NGhluKa1AokQ8bZkhgK3H7mZeGDw= X-Google-Smtp-Source: ALg8bN4SDbfjyvqbsaVdZNpNFtbXnRO9hoFoJ/l6AwnS7QY9t21GnhbRxsz6mEYkz4nfh3IWi8q9AZAkH/TzyyOa7gw= X-Received: by 2002:aca:5807:: with SMTP id m7mr1223126oib.71.1548338537230; Thu, 24 Jan 2019 06:02:17 -0800 (PST) MIME-Version: 1.0 References: <20190124131514.CD9051000DB@smtp02.mail.de> In-Reply-To: Date: Thu, 24 Jan 2019 15:02:05 +0100 Message-ID: To: Nikita Popov Cc: naitsirch@e.mail.de, PHP internals Content-Type: multipart/alternative; boundary="00000000000080f651058034a888" Subject: Re: [PHP-DEV] [RFC] New custom object serialization mechanism From: nicolas.grekas+php@gmail.com (Nicolas Grekas) --00000000000080f651058034a888 Content-Type: text/plain; charset="UTF-8" Thank you Nikita, the RFC looks solid to me. Using magic methods makes perfect sense to allow a smooth migration path. We could enforce that if one of __serialize() or __unserialize() is > defined, both have to be defined, to avoid running into such cases. That would make sense a lot of sense to me. > Maybe one could use `__normalize()` and `__denormalize()` [...] > I'd like that "serialization" appears in some form in the name > An idea: __pre_serialize / __post_unserialize But __serialize/__unserialize are good to me. Nicolas --00000000000080f651058034a888--