pp_negate

2005-07-29 Thread Piotr Fusik
I see three problems with this function:

1. [#36674] -undef results in -0.0 rather than the expected 0.
This is probably easy to fix, but I don't know if undef is the only value for 
which (!SvIOKp(sv)  !SvNOKp(sv)  !SvPOKp(sv)).

2. [#36675] Strings starting with '-' or '+' are treaded as strings, even when 
they represent numbers. Now I doubt this should be changed, but at least it 
should be clearly documented in perlop and probably perltrap. (imagine someone 
extracts numbers with a regular expression or split, and expects -100 to be 
treated the same way as 100)

3. There is some special treating of UTF-8 strings: they can be prefixed with 
'-' even when they don't start with an identifier first character.
I was unable to provoke this behavior in practice, who knows how to do that?


Re: pp_negate

2005-07-29 Thread Michael G Schwern
On Fri, Jul 29, 2005 at 08:36:10AM +0200, Piotr Fusik wrote:
 2. [#36675] Strings starting with '-' or '+' are treaded as strings, even 
 when they represent numbers. Now I doubt this should be changed, but at least 
 it should be clearly documented in perlop and probably perltrap. (imagine 
 someone extracts numbers with a regular expression or split, and expects 
 -100 to be treated the same way as 100)

I guess the upshot of this is:

$ perl -wle '$f = -100;  print -$f'
+100
$ perl -wle '$f = -100;  print -$f'
100


-- 
Michael G Schwern [EMAIL PROTECTED] http://www.pobox.com/~schwern
Just call me 'Moron Sugar'.
http://www.somethingpositive.net/sp05182002.shtml


Re: Smoke [5.9.3] 25237 FAIL(F) linux 2.6.12-4-686 [debian] (i686/1 cpu)

2005-07-29 Thread Dominic Dunlop

On 2005–07–28, at 20:09, [EMAIL PROTECTED] wrote:

Automated smoke report for 5.9.3 patch 25237
kirk: Intel(R) Celeron(R) CPU 2.00GHz (GenuineIntel 1994MHz)  
(i686/1 cpu)

onlinux - 2.6.12-4-686 [debian]
...
../t/op/sprintf.t...FAILED 147


This is due to change #25235 -- see http://www.mail-archive.com/ 
perl5-porters@perl.org/msg89982.html. Please run t/op/sprintf.t by  
hand and send the output line from the offending test. Thanks.

--
Dominic Dunlop



Re: [PATCH] Fix English error in overload.pm

2005-07-29 Thread Rafael Garcia-Suarez
Andy Lester wrote:
 In Simon's Advanced Perl Programming, 2e there's a quote from
 overload.pm that warrants a [sic].  This fixed that.

Thanks applied, with a nit :

+It is possible to hook into this process via Coverload::constant()
+and Coverload::remove_constant() functions.

I added a the before Coverload::constant(). I suppose that's
more correct. But who am I to give grammar lessons ? :)

-- 
* What system had proved more effective?
* Indirect suggestion implicating selfinterest.
-- Ulysses


Smoke [5.9.3] 25241 FAIL(F) MSWin32 WinXP/.Net SP1 (x86/1 cpu)

2005-07-29 Thread Steve Hay
Automated smoke report for 5.9.3 patch 25241
TANGAROA.uk.radan.com:  Intel(R) Pentium(R) 4 CPU 2.00GHz(~1992 MHz) (x86/1 cpu)
onMSWin32 - WinXP/.Net SP1
using cl version 12.00.8804
smoketime 10 hours 45 minutes (average 20 minutes 11 seconds)

Summary: FAIL(F)

O = OK  F = Failure(s), extended report at the bottom
X = Failure(s) under TEST but not under harness
? = still running or test results not (yet) available
Build failures during:   - = unknown or N/A
c = Configure, m = make, M = make (after miniperl), t = make test-prep

   25241 Configuration (common) -DINST_TOP=$(INST_DRV)\Smoke\doesntexist
--- -
F F 
F F -Dusemymalloc
F F -Duselargefiles
F F -Duselargefiles -Dusemymalloc
F F -Duseithreads -Uuseimpsys
F F -Duseithreads -Uuseimpsys -Dusemymalloc
F F -Duseithreads -Uuseimpsys -Duselargefiles
F F -Duseithreads -Uuseimpsys -Duselargefiles -Dusemymalloc
F F -Accflags='-DPERL_COPY_ON_WRITE'
F F -Accflags='-DPERL_COPY_ON_WRITE' -Dusemymalloc
F F -Accflags='-DPERL_COPY_ON_WRITE' -Duselargefiles
F F -Accflags='-DPERL_COPY_ON_WRITE' -Duselargefiles -Dusemymalloc
F F -Accflags='-DPERL_COPY_ON_WRITE' -Duseithreads -Uuseimpsys
F F -Accflags='-DPERL_COPY_ON_WRITE' -Duseithreads -Uuseimpsys 
-Dusemymalloc
F F -Accflags='-DPERL_COPY_ON_WRITE' -Duseithreads -Uuseimpsys 
-Duselargefiles
F F -Accflags='-DPERL_COPY_ON_WRITE' -Duseithreads -Uuseimpsys 
-Duselargefiles -Dusemymalloc
| +- -DDEBUGGING
+--- no debugging


Failures: (common-args) -DINST_TOP=$(INST_DRV)\Smoke\doesntexist
[default] 
[default] -DDEBUGGING
[default] -Dusemymalloc
[default] -DDEBUGGING -Dusemymalloc
[default] -Duselargefiles
[default] -DDEBUGGING -Duselargefiles
[default] -Duselargefiles -Dusemymalloc
[default] -DDEBUGGING -Duselargefiles -Dusemymalloc
[default] -Duseithreads -Uuseimpsys
[default] -DDEBUGGING -Duseithreads -Uuseimpsys
[default] -Duseithreads -Uuseimpsys -Dusemymalloc
[default] -DDEBUGGING -Duseithreads -Uuseimpsys -Dusemymalloc
[default] -Duseithreads -Uuseimpsys -Duselargefiles
[default] -DDEBUGGING -Duseithreads -Uuseimpsys -Duselargefiles
[default] -Duseithreads -Uuseimpsys -Duselargefiles -Dusemymalloc
[default] -DDEBUGGING -Duseithreads -Uuseimpsys -Duselargefiles -Dusemymalloc
[default] -Accflags='-DPERL_COPY_ON_WRITE'
[default] -DDEBUGGING -Accflags='-DPERL_COPY_ON_WRITE'
[default] -Accflags='-DPERL_COPY_ON_WRITE' -Dusemymalloc
[default] -DDEBUGGING -Accflags='-DPERL_COPY_ON_WRITE' -Dusemymalloc
[default] -Accflags='-DPERL_COPY_ON_WRITE' -Duselargefiles
[default] -DDEBUGGING -Accflags='-DPERL_COPY_ON_WRITE' -Duselargefiles
[default] -Accflags='-DPERL_COPY_ON_WRITE' -Duselargefiles -Dusemymalloc
[default] -DDEBUGGING -Accflags='-DPERL_COPY_ON_WRITE' -Duselargefiles 
-Dusemymalloc
[default] -Accflags='-DPERL_COPY_ON_WRITE' -Duseithreads -Uuseimpsys
[default] -DDEBUGGING -Accflags='-DPERL_COPY_ON_WRITE' -Duseithreads -Uuseimpsys
[default] -DDEBUGGING -Accflags='-DPERL_COPY_ON_WRITE' -Duseithreads 
-Uuseimpsys -Dusemymalloc
[default] -Accflags='-DPERL_COPY_ON_WRITE' -Duseithreads -Uuseimpsys 
-Duselargefiles
[default] -DDEBUGGING -Accflags='-DPERL_COPY_ON_WRITE' -Duseithreads 
-Uuseimpsys -Duselargefiles
[default] -Accflags='-DPERL_COPY_ON_WRITE' -Duseithreads -Uuseimpsys 
-Duselargefiles -Dusemymalloc
[default] -DDEBUGGING -Accflags='-DPERL_COPY_ON_WRITE' -Duseithreads 
-Uuseimpsys -Duselargefiles -Dusemymalloc
op/sprintf.tFAILED 147

[default] -Accflags='-DPERL_COPY_ON_WRITE' -Duseithreads -Uuseimpsys 
-Dusemymalloc
op/sprintf.tFAILED 147
Inconsistent test results (between TEST and harness):
../ext/threads/t/thread.t...FAILED test 25

Compiler messages(MSWin32):
LINK : warning LNK4089: all references to SHELL32.dll discarded by /OPT:REF
FastCalc.xs(397) : warning C4244: 'function' : conversion from 'double ' to 
'long ', possible loss of data
FastCalc.xs(399) : warning C4244: '+=' : conversion from 'double ' to 'unsigned 
int ', possible loss of data

-- 
Report by Test::Smoke v1.19_71 build 876 running on perl 5.8.7
(Reporter v0.022 / Smoker v0.025)




Radan Computational Ltd.

The information contained in this message and any files transmitted with it are 
confidential and intended for the addressee(s) only.  If you have received this 
message in error or there are any problems, please notify the sender 
immediately.  The unauthorized use, disclosure, copying or alteration of this 
message is strictly forbidden.  Note that any views or opinions presented in 
this email are solely those of the author and do not necessarily represent 
those of Radan Computational Ltd.  The recipient(s) of this message should 
check it and any attached files for viruses: Radan 

Re: [PATCH] More embed.fnc goodness

2005-07-29 Thread Rafael Garcia-Suarez
Andy Lester wrote:
 
 * embed.fnc: Adding many NN and NULLOK flags.  I'm down to 280 or so
 pointer parameters to clean up.  In at least one case, I fixed one that
 was wrong (force_list).
 
 * doio.c: Consting
 
 * op.c: Fixed some indents.  Hoisted a check for non-null outside of an
 if-then chain, to improve readability.  Added a couple of consts.
 
 * pp_ctl.c: Consting.
 
 * regcomp.c: Consting.
 
 * regexec.c: Consting.
 
 * sv.c: Fixed indenting.
 
 * util.c: Consting.

Thanks, applied as change 25243.


Re: [ANNOUNCE] Test::Simple/More/Builder 0.60_01

2005-07-29 Thread Peter

Michael G Schwern wrote:


* Added the long delayed BAIL_OUT to Test::More.



So, the way I would go about using this would be something like this?

my $obj=new SomeObj();
isa($obj, SomeObj) or BAIL_OUT(It wasn't my object :();

--Peter


Re: [PATCH] Re: [perl #36676] -0.0 printed as 0 on Windows

2005-07-29 Thread Abe Timmerman
Op een mooie zomerdag (Thursday 28 July 2005 12:31),schreef  Dominic Dunlop:
 On 2005–07–28, at 11:07, H.Merijn Brand wrote:
  %.0f  -0.1-0  C library bug: no minus on VMS,
  HP-UX
 
  Which isn't true anymore anyway. I've just tried on SuSE 9.2, SuSE
  9.3,
  AIX 4.3.3, AIX 5.2.0, HP-UX 11i, and HP-UX 11.00, and all print
  -0 on
  the example below. Only HP-UX 10.20 still prints 0

 OK. Can somebody say what the situation is on (particular versions
 of) VMS? -- copied to John E Malmberg in the hope of help.

$This is perl, v5.8.6 built for VMS_AXP
$ uname -a
OpenVMS SPE180 0 V8.2 AlphaServer_DS20_500_MHz Alpha
$ perl -we printf qq/%0.f\n/, -0.1
0

This is perl, v5.8.6 built for VMS_VAX
TIMMERMAN:FAFNER$ uname -a
OpenVMS FAFNER 0 V7.2 VAX_7000-720 VAX
$ perl -we printf qq/%0.f\n/, -0.1
0

HTH +
Good luck,

Abe
-- 
Traditionally, we accept US or UK spelling everywhere. Life's too short
to ask British English speakers to learn American, or vice versa.
 -- Hugo van der Sanden on p5p @ 2002-05-27


Re: pp_negate

2005-07-29 Thread Tels
-BEGIN PGP SIGNED MESSAGE-

Moin,

Michael G Schwern [EMAIL PROTECTED] wrote:

On Fri, Jul 29, 2005 at 08:36:10AM +0200, Piotr Fusik wrote:
 2. [#36675] Strings starting with '-' or '+' are treaded as strings, 
even when they represent numbers. Now I doubt this should be changed, 
but at least it should be clearly documented in perlop and probably 
perltrap. (imagine someone extracts numbers with a regular expression or 
split, and expects -100 to be treated the same way as 100)

I guess the upshot of this is:

$ perl -wle '$f = -100;  print -$f'
+100
$ perl -wle '$f = -100;  print -$f'
100

The first one looks wrong to me:

 # perl -wle '$f = -fo;  print -$f'
 +fo
 # perl -wle '$f = -NaN;  print -$f'
 +NaN

Ugh. You learn to find some dusted, obscure Perl corner every day...

Best wishes,

Tels

- -- 
Michael G Schwern [EMAIL PROTECTED] http://www.pobox.com/~schwern
Just call me 'Moron Sugar'.
http://www.somethingpositive.net/sp05182002.shtml


- -- 
 Signed on Fri Jul 29 12:44:42 2005 with key 0x93B84C15.
 Visit my photo gallery at http://bloodgate.com/photos/
 PGP key on http://bloodgate.com/tels.asc or per email.

 Ich bin mit der Gesamtsituation unzufrieden!

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.2.4 (GNU/Linux)

iQEVAwUBQuoJHXcLPEOTuEwVAQEZ0gf+MXC+1uRx17o9qQV3vHB/OK/MfCLxuKLf
sBXMvHvc5GDHGzDhM296rdCX82fY0i8eOJgQo0YKfFTAjZLZOkUxEOc2fHdyr3Kh
ZZ3Zxt/GMkcR/fpTzlUemPk2PZELUE3Pb+pUieTvDzmS0hGrqvelyDwurUSTL9fK
obCsedolBvjur85tjeS4MWWOQ+xbgWWBF/TOupYVIasue7jjMXxKX+yaYjcIxzlA
llFUWqH2M21iz6IFi0adL9gWekgVgG54n+r2+Us1NXvZVpypHixSN/0SmoC+5ACL
M0ZnC71HQsnVZUEQOwrktUQxy1oWUYUW2nFxlrHW0pKvjGChHvo/Wg==
=WUUr
-END PGP SIGNATURE-


Re: Smoke [5.9.3] 25237 FAIL(F) linux 2.6.12-4-686 [debian] (i686/1 cpu)

2005-07-29 Thread H.Merijn Brand
On Fri, 29 Jul 2005 09:20:59 +0200, Dominic Dunlop [EMAIL PROTECTED]
wrote:

 On 2005–07–28, at 20:09, [EMAIL PROTECTED] wrote:
  Automated smoke report for 5.9.3 patch 25237
  kirk: Intel(R) Celeron(R) CPU 2.00GHz (GenuineIntel 1994MHz)  
  (i686/1 cpu)
  onlinux - 2.6.12-4-686 [debian]
  ...
  ../t/op/sprintf.t...FAILED 147
 
 This is due to change #25235 -- see http://www.mail-archive.com/ 
 perl5-porters@perl.org/msg89982.html. Please run t/op/sprintf.t by  
 hand and send the output line from the offending test. Thanks.

But they are only failing on -DPERL_DEBUG_COW, which makes it harder to trace

-- 
H.Merijn BrandAmsterdam Perl Mongers (http://amsterdam.pm.org/)
using Perl 5.6.2, 5.8.0, 5.8.5,  5.9.2  on HP-UX 10.20, 11.00  11.11,
 AIX 4.3  5.2, SuSE 9.2  9.3, and Cygwin. http://www.cmve.net/~merijn
Smoking perl: http://www.test-smoke.org,perl QA: http://qa.perl.org
 reports  to: [EMAIL PROTECTED],perl-qa@perl.org


Re: Re: pp_negate

2005-07-29 Thread Piotr Fusik
The first one looks wrong to me:

 # perl -wle \'$f = -fo;  print -$f\'
 +fo
 # perl -wle \'$f = -NaN;  print -$f\'
 +NaN

Ugh. You learn to find some dusted, obscure Perl corner every day...

This behavior is clearly documented in perlop:

if the string starts with a plus or minus, a string starting with the opposite 
sign is returned

I'm more interested in the problems 1 and 3.


Smoke [5.9.3] 25241 FAIL(XF) bsd/os 4.1 (i386/1 cpu)

2005-07-29 Thread kane
Automated smoke report for 5.9.3 patch 25241
fixit.xs4all.nl: Pentium II (i386/1 cpu)
onbsd/os - 4.1
using cc version egcs-2.91.66 19990314 (egcs-1.1.2 release)
smoketime 3 hours 55 minutes (average 1 hour 57 minutes)

Summary: FAIL(XF)

O = OK  F = Failure(s), extended report at the bottom
X = Failure(s) under TEST but not under harness
? = still running or test results not (yet) available
Build failures during:   - = unknown or N/A
c = Configure, m = make, M = make (after miniperl), t = make test-prep

   25241 Configuration (common) none
--- -
F F - - -Duse64bitint
O X - - 
| | | +- PERLIO = perlio -DDEBUGGING
| | +--- PERLIO = stdio  -DDEBUGGING
| +- PERLIO = perlio
+--- PERLIO = stdio


Failures: (common-args) none
[stdio/perlio] -Duse64bitint
../t/op/int.t...FAILED 11

[perlio] 
Inconsistent test results (between TEST and harness):
../lib/Net/hostent.tFAILED at test 4

-- 
Report by Test::Smoke v1.19_67 build 842 running on perl 5.00503
(Reporter v0.019 / Smoker v0.023)



Re: [PATCH] Re: [perl #36676] -0.0 printed as 0 on Windows

2005-07-29 Thread Dominic Dunlop


On 2005–07–29, at 12:30, Abe Timmerman wrote:


$This is perl, v5.8.6 built for VMS_AXP
$ uname -a
OpenVMS SPE180 0 V8.2 AlphaServer_DS20_500_MHz Alpha
$ perl -we printf qq/%0.f\n/, -0.1
0

This is perl, v5.8.6 built for VMS_VAX
TIMMERMAN:FAFNER$ uname -a
OpenVMS FAFNER 0 V7.2 VAX_7000-720 VAX
$ perl -we printf qq/%0.f\n/, -0.1
0

HTH +


Indeed it does. Thanks. AFAICT from HP's site, OpenVMS V8.2 is  
current, while V7.2 dates from 1999. Am I correct? If I am, t/op/ 
sprintf.t can stay in its post-patch 25235 state, which expects all  
versions to fail this particular test.

--
Dominic Dunlop



Re: [PATCH] Re: [perl #36676] -0.0 printed as 0 on Windows

2005-07-29 Thread John E. Malmberg

Abe Timmerman wrote:

Op een mooie zomerdag (Thursday 28 July 2005 12:31),schreef  Dominic Dunlop:


On 2005–07–28, at 11:07, H.Merijn Brand wrote:


%.0f  -0.1-0  C library bug: no minus on VMS,
HP-UX


Which isn't true anymore anyway. I've just tried on SuSE 9.2, SuSE
9.3,
AIX 4.3.3, AIX 5.2.0, HP-UX 11i, and HP-UX 11.00, and all print
-0 on
the example below. Only HP-UX 10.20 still prints 0


OK. Can somebody say what the situation is on (particular versions
of) VMS? -- copied to John E Malmberg in the hope of help.



$This is perl, v5.8.6 built for VMS_AXP
$ uname -a
OpenVMS SPE180 0 V8.2 AlphaServer_DS20_500_MHz Alpha
$ perl -we printf qq/%0.f\n/, -0.1
0

This is perl, v5.8.6 built for VMS_VAX
TIMMERMAN:FAFNER$ uname -a
OpenVMS FAFNER 0 V7.2 VAX_7000-720 VAX
$ perl -we printf qq/%0.f\n/, -0.1
0


I will pass this on to the experts in this area.  It may be a case of 
setting the proper build options.


Some bug-fixes that visibly change behavior are not enabled by default 
so that they do not break existing programs that depend on the incorrect 
behavior.


-John
[EMAIL PROTECTED]
Personal Opinion Only


Re: Smoke [5.9.3] 25237 FAIL(F) linux 2.6.12-4-686 [debian] (i686/1 cpu)

2005-07-29 Thread Dominic Dunlop

On 2005–07–29, at 12:48, H.Merijn Brand wrote:

But they are only failing on -DPERL_DEBUG_COW, which makes it  
harder to trace


Thanks for pointing that out. Fails for me too (on darwin 7.6.0) if I  
-DPERL_DEBUG_COW:


[EMAIL PROTECTED]:perl-current-debugCOW$ ./miniperl -Ilib t/op/sprintf.t
1..254
...
not ok 147 %.0g -0.0 -0 0 # No minus
...

Investigating.
--
Dominic Dunlop



[PATCH] Re: Smoke [5.9.3] 25237 FAIL(F) linux 2.6.12-4-686 [debian] (i686/1 cpu)

2005-07-29 Thread Dominic Dunlop

On 2005–07–29, at 16:49, Dominic Dunlop wrote:


On 2005–07–29, at 12:48, H.Merijn Brand wrote:


But they are only failing on -DPERL_DEBUG_COW, which makes it  
harder to trace



Thanks for pointing that out. Fails for me too (on darwin 7.6.0) if  
I -DPERL_DEBUG_COW:


[EMAIL PROTECTED]:perl-current-debugCOW$ ./miniperl -Ilib t/op/sprintf.t
1..254
...
not ok 147 %.0g -0.0 -0 0 # No minus
...

Investigating.


Right. Patch attached. The PERL_DEBUG_COW definition for the SvNVX  
was turning a negative zero into a positive zero. Since I don't have  
access to a copy of the IEE 754 FP standard, the closest I can find  
to a definitive definition of expected arithmetic results involving  
positive and negative zeros is table 2.5 in http://docs.hp.com/en/ 
B3906-90005/ch02s02.html. The patch makes the macro do the right  
thing to preserve a zero's sign.


All tests pass for me with  make minitest.
--
Dominic Dunlop



cow-patch
Description: Binary data


Smoke [5.9.3] 25241 FAIL(F) openbsd 3.7 (i386/1 cpu)

2005-07-29 Thread steve
Automated smoke report for 5.9.3 patch 25241
mccoy.peters.homeunix.org: Intel Pentium III (GenuineIntel 686-class, 512KB 
L2 cache) (548 MHz) (i386/1 cpu)
onopenbsd - 3.7
using cc version 3.3.5 (propolice)
smoketime 8 hours 39 minutes (average 1 hour 4 minutes)

Summary: FAIL(F)

O = OK  F = Failure(s), extended report at the bottom
X = Failure(s) under TEST but not under harness
? = still running or test results not (yet) available
Build failures during:   - = unknown or N/A
c = Configure, m = make, M = make (after miniperl), t = make test-prep

   25241 Configuration (common) none
--- -
F F F F 
F F F F -Duse64bitint
F F F F -Duseithreads
F F F F -Duseithreads -Duse64bitint
| | | +- PERLIO = perlio -DDEBUGGING
| | +--- PERLIO = stdio  -DDEBUGGING
| +- PERLIO = perlio
+--- PERLIO = stdio


Failures: (common-args) none
[stdio/perlio] 
[stdio/perlio] -DDEBUGGING
[stdio/perlio] -Duse64bitint
[stdio/perlio] -DDEBUGGING -Duse64bitint
[stdio/perlio] -Duseithreads
[stdio/perlio] -DDEBUGGING -Duseithreads
[stdio/perlio] -Duseithreads -Duse64bitint
[stdio/perlio] -DDEBUGGING -Duseithreads -Duse64bitint
../t/op/sprintf.t...FAILED 147

Compiler messages(gcc):
/tmp//ccF12267.o(.text+0x3e): In function `main':
/tmp//ccdy8716.o(.text+0x5d): In function `main':
/tmp//ccNq7939.o(.text+0xde): In function `main':
op.c: In function `Perl_newCONSTSUB':
op.c:4609: warning: null argument where non-null required (arg 1)
opmini.c: In function `Perl_newCONSTSUB':
opmini.c:4609: warning: null argument where non-null required (arg 1)
libperl.a(perlio.o)(.text+0x4ed8): In function `PerlIO_vsprintf':
opmini.o(.text+0x316): In function `Perl_allocmy':
libperl.a(toke.o)(.text+0x722c): In function `Perl_yylex':
libperl.a(op.o)(.text+0x316): In function `Perl_allocmy':
lib/auto/DynaLoader/DynaLoader.a(DynaLoader.o)(.text+0x23e): In function 
`XS_DynaLoader_dl_load_file':
util.o(.text+0x1f3): In function `savestr':
str.o(.text+0x5d): In function `str_2ptr':
byterun.c: In function `byterun':
byterun.c:893: warning: comparison is always false due to limited range of data 
type
../libperl.a(perlio.o)(.text+0x4ed8): In function `PerlIO_vsprintf':
../libperl.a(op.o)(.text+0x316): In function `Perl_allocmy':
../libperl.a(toke.o)(.text+0x722c): In function `Perl_yylex':
/tmp//ccW29036.o(.text+0x3e): In function `main':
/tmp//ccM29043.o(.text+0x5d): In function `main':
/tmp//ccV12905.o(.text+0xde): In function `main':
libperl.a(perlio.o)(.text+0x4f98): In function `PerlIO_vsprintf':
libperl.a(toke.o)(.text+0x7f30): In function `Perl_yylex':
lib/auto/DynaLoader/DynaLoader.a(DynaLoader.o)(.text+0x326): In function 
`XS_DynaLoader_dl_load_file':
util.o(.text+0x2c3): In function `savestr':
str.o(.text+0x81): In function `str_2ptr':
../libperl.a(perlio.o)(.text+0x4f98): In function `PerlIO_vsprintf':
../libperl.a(toke.o)(.text+0x7f30): In function `Perl_yylex':
/tmp//ccrW5547.o(.text+0x3e): In function `main':
/tmp//ccH11065.o(.text+0x5d): In function `main':
/tmp//ccy19030.o(.text+0xde): In function `main':
libperl.a(perlio.o)(.text+0x52f4): In function `PerlIO_vsprintf':
libperl.a(toke.o)(.text+0x7330): In function `Perl_yylex':
../libperl.a(perlio.o)(.text+0x52f4): In function `PerlIO_vsprintf':
../libperl.a(toke.o)(.text+0x7330): In function `Perl_yylex':
/tmp//ccg29112.o(.text+0x3e): In function `main':
/tmp//ccG15241.o(.text+0x5d): In function `main':
/tmp//ccd31971.o(.text+0xde): In function `main':
libperl.a(perlio.o)(.text+0x53b4): In function `PerlIO_vsprintf':
libperl.a(toke.o)(.text+0x8030): In function `Perl_yylex':
lib/auto/DynaLoader/DynaLoader.a(DynaLoader.o)(.text+0x32a): In function 
`XS_DynaLoader_dl_load_file':
../libperl.a(perlio.o)(.text+0x53b4): In function `PerlIO_vsprintf':
../libperl.a(toke.o)(.text+0x8030): In function `Perl_yylex':
/tmp//ccS14776.o(.text+0x3e): In function `main':
/tmp//ccb24554.o(.text+0x5d): In function `main':
/tmp//cccz2454.o(.text+0xde): In function `main':
libperl.a(perlio.o)(.text+0x127): In function `PerlIO_debug':
opmini.o(.text+0x39d): In function `Perl_allocmy':
libperl.a(toke.o)(.text+0x8060): In function `Perl_yylex':
libperl.a(op.o)(.text+0x39d): In function `Perl_allocmy':
lib/auto/DynaLoader/DynaLoader.a(DynaLoader.o)(.text+0x302): In function 
`XS_DynaLoader_dl_load_file':
DProf.xs:140: warning: `unused' attribute ignored
../libperl.a(perlio.o)(.text+0x127): In function `PerlIO_debug':
../libperl.a(op.o)(.text+0x39d): In function `Perl_allocmy':
../libperl.a(toke.o)(.text+0x8060): In function `Perl_yylex':
/tmp//ccr17706.o(.text+0x3e): In function `main':
/tmp//ccG23252.o(.text+0x5d): In function `main':
/tmp//ccU10135.o(.text+0xde): In function `main':
libperl.a(toke.o)(.text+0x8ed0): In function `Perl_yylex':
lib/auto/DynaLoader/DynaLoader.a(DynaLoader.o)(.text+0x4f6): In function 
`XS_DynaLoader_dl_load_file':

Status of patches to blead 25210 for VMS bug?

2005-07-29 Thread John E. Malmberg
What is the status of the patches that I submitted based on [EMAIL PROTECTED] 
to correctly fix the CONST QUALIFIER warning issue?


-John
[EMAIL PROTECTED]
Personal Opinion Only


[patch] [EMAIL PROTECTED] on OpenVMS/vms.c - fopen bug.

2005-07-29 Thread John E. Malmberg
The existing code in the fopen() call aways fails with an invalid 
argument, so the if clause following it has never been run since this 
version of the code was in place.


Fixing this bug may expose other side effects as it is assuming that the 
first 4 bytes of an executable are not printable.  I have not checked

if that is true for the ELF executables found on I64.

EAGLE gdiff -u vms/vms.c_bug2 vms/vms.c
--- vms/vms.c_bug2  Fri Jul 29 10:15:32 2005
+++ vms/vms.c   Fri Jul 29 10:14:03 2005
@@ -5300,7 +5300,7 @@
   *s = '\0';

   /* check that it's really not DCL with no file extension */
-  fp = fopen(resspec,r,ctx=bin,shr=get);
+  fp = fopen(resspec,r,ctx=bin,shr=get);
   if (fp) {
 char b[4] = {0,0,0,0};
 read(fileno(fp),b,4);

-John
[EMAIL PROTECTED]
Personal Opinion Only


Smoke [5.9.3] 25244 FAIL(F) linux 2.6.12-5-686 [debian] (i686/1 cpu)

2005-07-29 Thread steve
Automated smoke report for 5.9.3 patch 25244
kirk: Intel(R) Celeron(R) CPU 2.00GHz (GenuineIntel 1994MHz) (i686/1 cpu)
onlinux - 2.6.12-5-686 [debian]
using cc version 4.0.2 20050720 (prerelease) (Debian 4.0.1-2ubuntu3)
smoketime 2 hours 41 minutes (average 20 minutes 9 seconds)

Summary: FAIL(F)

O = OK  F = Failure(s), extended report at the bottom
X = Failure(s) under TEST but not under harness
? = still running or test results not (yet) available
Build failures during:   - = unknown or N/A
c = Configure, m = make, M = make (after miniperl), t = make test-prep

   25244 Configuration (common) none
--- -
O O 
O O -Duseithreads
F F -DPERL_DEBUG_COW
F F -DPERL_DEBUG_COW -Duseithreads
| +- -DDEBUGGING
+--- no debugging


Failures:
[default] -DPERL_DEBUG_COW
[default] -DDEBUGGING -DPERL_DEBUG_COW
[default] -DPERL_DEBUG_COW -Duseithreads
[default] -DDEBUGGING -DPERL_DEBUG_COW -Duseithreads
../t/op/sprintf.t...FAILED 147

-- 
Report by Test::Smoke v1.19#716 running on perl 5.8.7
(Reporter v0.016 / Smoker v0.015)



Smoke [5.9.3] 25245 FAIL(F) linux 2.6.12-5-686 [debian] (i686/1 cpu)

2005-07-29 Thread steve
Automated smoke report for 5.9.3 patch 25245
kirk: Intel(R) Celeron(R) CPU 2.00GHz (GenuineIntel 1994MHz) (i686/1 cpu)
onlinux - 2.6.12-5-686 [debian]
using cc version 4.0.2 20050729 (prerelease) (Debian 4.0.1-4ubuntu1)
smoketime 2 hours 40 minutes (average 20 minutes)

Summary: FAIL(F)

O = OK  F = Failure(s), extended report at the bottom
X = Failure(s) under TEST but not under harness
? = still running or test results not (yet) available
Build failures during:   - = unknown or N/A
c = Configure, m = make, M = make (after miniperl), t = make test-prep

   25245 Configuration (common) none
--- -
O O 
O O -Duseithreads
F F -DPERL_DEBUG_COW
F F -DPERL_DEBUG_COW -Duseithreads
| +- -DDEBUGGING
+--- no debugging


Failures:
[default] -DPERL_DEBUG_COW
[default] -DDEBUGGING -DPERL_DEBUG_COW
[default] -DPERL_DEBUG_COW -Duseithreads
[default] -DDEBUGGING -DPERL_DEBUG_COW -Duseithreads
../t/op/sprintf.t...FAILED 147

-- 
Report by Test::Smoke v1.19#716 running on perl 5.8.7
(Reporter v0.016 / Smoker v0.015)



Data corruption - [EMAIL PROTECTED] on VMS.

2005-07-29 Thread John E. Malmberg
In the code path below, the execution of the HEK_FLAGS(hek) causes the 
memory for a different allocated structure to be modified, which then 
causes an access violation when the corrupted value is used as an index.


This is in the module HV, routine S_share_hek_flags().

len has a value if 19 in this case.

Newx(k, STRUCT_OFFSET(struct shared_he,
 shared_he_hek.hek_key[0]) + len + 2, char);
new_entry = (struct shared_he *)k;
entry = (new_entry-shared_he_he);
hek = (new_entry-shared_he_hek);

Copy(str, HEK_KEY(hek), len, char);
HEK_KEY(hek)[len] = 0;
HEK_LEN(hek) = len;
HEK_HASH(hek) = hash;
HEK_FLAGS(hek) = (unsigned char)flags_masked;

HEK_FLAGS(hek) expands to:
   (*((unsigned char *)(hek)-hek_key)+(hek)-hek_len+1))

DBG eval/addr hek-hek_key
10439684
DBG eval 10439684+20
10439704

The address 10439704 was already a part of the structure that 
Perl_hv_iternext_flags() had pointed a variable named iter at.


DBG exam *iter
*HV\Perl_hv_iternext_flags\iter
xhv_name:   1162633044
xhv_eiter:  4998486
xhv_riter:  -256
DBG eval/addr iter-xhv_riter
10439704

It appears to me that one of these structures was not allocated large 
enough for the data that is being put in it.  As the xpvhv_aux structure 
is a fixed size structure, my suspicion is that the problem is the above 
code somewhere since this is where the HEK struct is allocated just 
before *iter got corrupted.


Prior to the corruption, iter-xhv_riter had -1.

The value that was being processed at this time is:

DBG exam/az *str
*HV\S_share_hek_flags\str:  PERL_DESTRUCT_LEVEL = 2

-John
[EMAIL PROTECTED]
Personal Opinion Only



[perl #36689] =, |= and ^= overloads are nbot documented

2005-07-29 Thread via RT
# New Ticket Created by  [EMAIL PROTECTED] 
# Please include the string:  [perl #36689]
# in the subject line of all future correspondence about this issue. 
# URL: https://rt.perl.org/rt3/Ticket/Display.html?id=36689 



This is a bug report for perl from [EMAIL PROTECTED],
generated with the help of perlbug 1.35 running under perl v5.8.4.


-
[Please enter your report here]

In itself this report is purely about the documentation:

Overload operators |=, = and ^= work, but are not documented to exist
in perldoc overload.

I'm reporting this as a bug since not having these caused one of my modules
to fail due to a copy constructor not getting executed at the proper moment.

PS:

  why isn't it enough to have overloads for the ops themselves to get the
  copy constructor on:
$object += $foo;

 Or, in other words, why do I have to do

  use overload
 +  = \plus,
 += = \plus,
 =  = \copy;

instead of:

  use overload
 +  = \plus,
 =  = \copy;

It would seem to me that having both a + overload and a = overload should
be sign enough that you'd want the copy-constructor to get triggered on a 
mutator like:

$object += $foo;

[Please do not change anything below this line]
-
---
Flags:
category=core
severity=low
---
This perlbug was built using Perl v5.8.6 - Fri Dec 24 19:25:13 CET 2004
It is being executed now by  Perl v5.8.4 - Thu Jun  3 13:28:19 CEST 2004.

Site configuration information for perl v5.8.4:

Configured by ton at Thu Jun  3 13:28:19 CEST 2004.

Summary of my perl5 (revision 5 version 8 subversion 4) configuration:
  Platform:
osname=linux, osvers=2.6.5, archname=i686-linux-64int-ld
uname='linux quasar 2.6.5 #8 mon apr 5 05:41:20 cest 2004 i686 gnulinux '
config_args=''
hint=recommended, useposix=true, d_sigaction=define
usethreads=undef use5005threads=undef useithreads=undef 
usemultiplicity=undef
useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
use64bitint=define use64bitall=undef uselongdouble=define
usemymalloc=y, bincompat5005=undef
  Compiler:
cc='cc', ccflags ='-fno-strict-aliasing -I/usr/local/include 
-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64',
optimize='-O2 -fomit-frame-pointer',
cppflags='-fno-strict-aliasing -I/usr/local/include'
ccversion='', gccversion='3.4.0 20031231 (experimental)', gccosandvers=''
intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=12345678
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12
ivtype='long long', ivsize=8, nvtype='long double', nvsize=12, 
Off_t='off_t', lseeksize=8
alignbytes=4, prototype=define
  Linker and Libraries:
ld='cc', ldflags =' -L/usr/local/lib'
libpth=/usr/local/lib /lib /usr/lib
libs=-lnsl -ldb -ldl -lm -lcrypt -lutil -lc
perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc
libc=/lib/libc-2.3.2.so, so=so, useshrplib=false, libperl=libperl.a
gnulibc_version='2.3.2'
  Dynamic Linking:
dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E'
cccdlflags='-fpic', lddlflags='-shared -L/usr/local/lib'

Locally applied patches:


---
@INC for perl v5.8.4:
/usr/lib/perl5/5.8.4/i686-linux-64int-ld
/usr/lib/perl5/5.8.4
/usr/lib/perl5/site_perl/5.8.4/i686-linux-64int-ld
/usr/lib/perl5/site_perl/5.8.4
/usr/lib/perl5/site_perl
.

---
Environment for perl v5.8.4:
HOME=/home/ton
LANG (unset)
LANGUAGE (unset)
LD_LIBRARY_PATH (unset)
LOGDIR (unset)

PATH=/home/ton/bin.Linux:/home/ton/bin:/home/ton/bin.SampleSetup:/usr/local/bin:/usr/local/sbin:/home/oracle/product/9.2/bin:/usr/local/ar/bin:/usr/games/bin:/usr/X11R6/bin:/usr/share/bin:/usr/bin:/usr/sbin:/bin:/sbin:.
PERL_BADLANG (unset)
SHELL=/bin/bash



[perl #36691] string captured into $1, $2,... in pattern match sometimes have utf8 bit on and sometimes off. Even for the same patternmatch arguments

2005-07-29 Thread Andy Maas
# New Ticket Created by  Andy Maas 
# Please include the string:  [perl #36691]
# in the subject line of all future correspondence about this issue. 
# URL: https://rt.perl.org/rt3/Ticket/Display.html?id=36691 


This is a bug report for perl from [EMAIL PROTECTED],

generated with the help of perlbug 1.35 running under perl v5.8.6.

 

 

-

[Please enter your report here]

 

I observed two related problems.

 

1. Strings captured in $1, $2... in pattern match sometimes have its
utf8 flag on and other times off.

   This is true even when pattern match has the same arguments.

   It looks like that behavior depends on certain mode that cause it to
behave one way or the other

 

   I identified one method to trigger it to behave one way

   (setting utf8 flag on on patter match when argument contain 8 bit
data).

   This is by using HTTP::DAV module to access a DAV resource.

 

   I also identified another method to make it behave another way.

   This is by calling Encode::is_utf8($2) before pattern match

 

2. The call to Encode::is_utf8($2) actually reset utf8 flag of $2
which seems to be odd since the

   call is supposedly doing nothing but reading utf8 flag status of its
argument.

 

This is the script I use for testing:

 

 

use Encode;

use HTTP::DAV;

 

my $data = pack(H*, d0cf);

 

print
-\n
;

print Start CASE 1. utf8 bit is not set on \$2\n;

 

$data =~ /^()(.*)/;

print is_utf8=.(utf8::is_utf8($2)?1:0).\n;

 

# no warning here

my $v = $2  abc;

 

 

print
\n\n---
--\n;

print Start CASE 2. using HTTP::DAV module caused utf8 bit is set on
\$2\n;

 

# this triggered warning in later code

my $dav = HTTP::DAV-new;

$dav-credentials(-user = devcenter, -pass = rocks, -url =
http://webdav.silverstream.com/Director/WebDAVService/main;);

$dav-open(http://webdav.silverstream.com/Director/WebDAVService/main;)
;

 

# uncomment the following line to see how the Encode::is_utf8 clear utf8
bit of $2

#Encode::is_utf8($2);

 

$data =~ /^()(.*)/;

print is_utf8=.(utf8::is_utf8($2)?1:0).\n;

 

# warning here

$v = $2  abc;

 

 

 

 

 

[Please do not change anything below this line]

-

---

Flags:

category=core

severity=medium

---

Site configuration information for perl v5.8.6:

 

Configured by marcel at Mon Nov 29 12:06:34 PST 2004.

 

Summary of my perl5 (revision 5 version 8 subversion 6) configuration:

  Platform:

osname=linux, osvers=2.4.20-28.8smp,
archname=i686-linux-thread-multi

uname='linux xenon2 2.4.20-28.8smp #1 smp thu dec 18 12:25:21 est
2003 i686 i686 i386 gnulinux '

config_args='-Dmksymlinks -Dcc=gcc -Dprefix=/tools/x/perl-5.8.6
-Uinstallusrbinperl -Dusethreads -de'

hint=recommended, useposix=true, d_sigaction=define

usethreads=define use5005threads=undef useithreads=define
usemultiplicity=define

useperlio=define d_sfio=undef uselargefiles=define usesocks=undef

use64bitint=undef use64bitall=undef uselongdouble=undef

usemymalloc=n, bincompat5005=undef

  Compiler:

cc='gcc', ccflags ='-D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS
-fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm',

optimize='-O2',

cppflags='-D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS
-fno-strict-aliasing -pipe -I/usr/local/include -I/usr/include/gdbm'

ccversion='', gccversion='3.3.3', gccosandvers=''

intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234

d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12

ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t',
lseeksize=8

alignbytes=4, prototype=define

  Linker and Libraries:

ld='gcc', ldflags =' -L/usr/local/lib'

libpth=/usr/local/lib /lib /usr/lib

libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lpthread -lc

perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc

libc=/lib/libc-2.3.2.so, so=so, useshrplib=false, libperl=libperl.a

gnulibc_version='2.3.2'

  Dynamic Linking:

dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E'

cccdlflags='-fpic', lddlflags='-shared -L/usr/local/lib'

 

Locally applied patches:

 

 

---

@INC for perl v5.8.6:

/tools/x/perl-5.8.6/lib/5.8.6/i686-linux-thread-multi

/tools/x/perl-5.8.6/lib/5.8.6

/tools/x/perl-5.8.6/lib/site_perl/5.8.6/i686-linux-thread-multi

/tools/x/perl-5.8.6/lib/site_perl/5.8.6

/tools/x/perl-5.8.6/lib/site_perl

.

 

---

Environment for perl v5.8.6:

HOME=/u/amaas

LANG=en_US.ISO8859-1

LANGUAGE (unset)

LD_LIBRARY_PATH (unset)

LOGDIR (unset)

 
PATH=/tools/x/bin:/usr/bin::/u/amaas/bin:/usr/local/bin:/bin:/usr/bin:/u