[PHP-DEV] unpack() offset and consumed data measurement

2018-01-28 Thread Chris Wright
Morning all Since PHP 7.1 the unpack() function has a (still undocumented) optional 3rd argument that allows the caller to specify the offset in the input data where parsing should start. While this is a useful feature, it is currently impossible to know how many bytes of the input were consumed f

Re: [PHP-DEV] unpack()

2016-02-25 Thread Rasmus Lerdorf
Trivial things like adding a completely non-controversial optional argument to a function really does not require an RFC. Let's not get hung up on process just for the sake of process here. -Rasmus

Re: [PHP-DEV] unpack()

2016-02-25 Thread Dmitry Stogov
internals@lists.php.net; Hynek Bartoš Subject: Re: [PHP-DEV] unpack() Another note: the return type of the function completely changed (may return `false` now) - also to be checked/documented/tested. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On 25 February 2016 at 06:

Re: [PHP-DEV] unpack()

2016-02-25 Thread Marco Pivetta
nks for checking. > > > > From: Michael Wallner on behalf of Michael > Wallner > Sent: Thursday, February 25, 2016 13:53 > To: Dmitry Stogov > Cc: internals@lists.php.net; Hynek Bartoš > Subject: Re: [PHP-DEV] unpack() > > > I th

Re: [PHP-DEV] unpack()

2016-02-25 Thread Dmitry Stogov
You are right about the error. Thanks for checking. From: Michael Wallner on behalf of Michael Wallner Sent: Thursday, February 25, 2016 13:53 To: Dmitry Stogov Cc: internals@lists.php.net; Hynek Bartoš Subject: Re: [PHP-DEV] unpack() I think the requested

Re: [PHP-DEV] unpack()

2016-02-25 Thread Michael Wallner
> I think the requested feature may be really useful. > > And the implementation is really simple > https://gist.github.com/dstogov/edbb1efcd1e9701e75ab > There seems to be a typo at https://gist.github.com/dstogov/edbb1efcd1e9701e75ab#fi