Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:110423 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 56386 invoked from network); 8 Jun 2020 14:45:29 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 8 Jun 2020 14:45:29 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id D3BD11804F2 for ; Mon, 8 Jun 2020 06:28:55 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_PASS, SPF_NONE autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS31103 84.19.160.0/19 X-Spam-Virus: No X-Envelope-From: Received: from mail.toneristzuen.de (mail.toneristzuen.de [84.19.169.162]) by php-smtp4.php.net (Postfix) with ESMTP for ; Mon, 8 Jun 2020 06:28:54 -0700 (PDT) Received: from maniacmansion.fritz.box (ppp-188-174-62-251.dynamic.mnet-online.de [188.174.62.251]) by mail.toneristzuen.de (Postfix) with ESMTPSA id A45CE4B394; Mon, 8 Jun 2020 15:28:48 +0200 (CEST) Message-ID: To: Eddie Kohler , PHP Internals Cc: Sara Golemon Date: Mon, 08 Jun 2020 15:28:43 +0200 In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] New functions `hash_serialize` and `hash_unserialize`? From: johannes@schlueters.de (Johannes =?ISO-8859-1?Q?Schl=FCter?=) On Mon, 2020-06-08 at 09:01 -0400, Eddie Kohler wrote: > I'm writing to gauge interest in two new functions to the PHP `hash` > extension, `hash_serialize` and `hash_unserialize`. These functions > would serialize and unserialize the internals of a HashContext > objectallowing a partially-computed hash to be saved, then restored > and completed in a laterrun. I would suggest to make the HashContext Serializable, then serialize($hash_context); works. Then it also fits when stored in other objects or something ... johannes