Re: [perl #43022] Change of behavior between 5.6.0 and 5.8.0
by Jesse Vincent other posts by this author
May 22 2007 10:39AM messages near this date
Re: [perl #43022] Change of behavior between 5.6.0 and 5.8.0
|
[perl #43020] unsafe \0 for libc open() not sanitised
>
> I haven't looked into this at all, and the test case I am providing is
> very bad, in the sense that I have not tried to trim it down. I wrote
> the attached code around ten years ago, and was surprised to discover
> that it no longer works.
>
> This may be a documented changed; I don't know. As I said, I have not
> investigated this.
>
> The output from the enclosed "demo.pl" file should be:
>
> IX + IX = 18
> XI * IV = 44
> II ** X = 1024
> M - I = 999
> Powers of II:
> 1
> 2
> 4
> 8
> 16
> 32
> 64
> 128
>
> With 5.6.0, that is indeed the output. With 5.8.0, the output is
> erroneous:
>
> IX + IX = 0
> XI * IV = 0
> II ** X = 1
> M - I = 0
> Powers of II:
>
FWIW, if I replace the CPAN Roman package with your code, it works
just fine on 5.8.8. Alternatively, if I rename Roman to "Romana" or
some other not-clobbering package, it works just fine.
If I leave it as written and let it use the CPAN version of Roman.pm,
it fails as you describe.
-jesse
Thread:
Mark-Jason Dominus
David Nicol
Jesse Vincent
|