Hi:
first of all, yes , you are right about the reverse order thing:
and then, they are not equal:
will output:
strncmp:
int(5)
int(5)
int(0)
int(0)
thanks
2011/7/29 Ángel González :
> Laruence wrote:
>>
>> Hi:
>>
>> strn(case)cmp dosen't support a negative length as its thi
Laruence wrote:
Hi:
strn(case)cmp dosen't support a negative length as its third
paramter, while substr dose.
here is the rfc: https://wiki.php.net/rfc/strncmpnegativelen
any question? plz worte me back.
thanks
What do you exactly mean by "in the reverse order" in
if the abs of
Hi:
As Derick and Pierre said(in IRC), I change the patch base from
PHP 5.3 to PHP5.4,
and avoid changing ZEND_API declaration.
RFC updated
new patch :
http://www.laruence.com/php-dev/php-5.4-trunk-strncmp-supproting-negative-len.patch
thanks
2011/7/28 Pierre Joye :
> the signat
the signature is not the same anymore, some extension may not build
anymore (depending on the compiler used and its flag).
Cheers,
On Thu, Jul 28, 2011 at 1:32 PM, Laruence wrote:
> Hi:
>
> why?
>
> I think this change would not cause any other side-effects.
>
> and if you are worry about INT_MA
Hi:
why?
I think this change would not cause any other side-effects.
and if you are worry about INT_MAX, I think it's ok to declare with
long(in fact, I already did so).
thanks
2011/7/28 Derick Rethans :
> On Thu, 28 Jul 2011, Laruence wrote:
>
>> Hi:
>>
>> strn(case)cmp dosen't support a
On Thu, 28 Jul 2011, Laruence wrote:
> Hi:
>
> strn(case)cmp dosen't support a negative length as its third
> paramter, while substr dose.
>
> I wrote a patch to make strn(case)cmp supporting negative length,
> make following script works as expect:
>
> if (strncmp("prefix_num", "n