develooper Front page | perl.perl5.porters | Postings from January 2012

[perl #108986] Math::BigInt overloads '..'

Thread Previous
From:
perlbug-followup
Date:
January 24, 2012 15:15
Subject:
[perl #108986] Math::BigInt overloads '..'
Message ID:
rt-3.6.HEAD-14510-1327446920-554.108986-75-0@perl.org
# New Ticket Created by  (Andreas J. Koenig) 
# Please include the string:  [perl #108986]
# in the subject line of all future correspondence about this issue. 
# <URL: https://rt.perl.org:443/rt3/Ticket/Display.html?id=108986 >


Current Math::BigInt has this:

     62 '>>='   =>      sub { $_[0]->brsft($_[1]); },
     63 
     64 # not supported by Perl yet
     65 '..'    =>      \&_pointpoint,
     66 
     67 '<=>'   =>      sub { my $rc = $_[2] ?

Line 65 is (should be?) broken since .. isn't overloadable and since
v5.15.6-560-g9d51dce this triggers a warning. Or not. I have seen it
warn and I have seen perls after v5.15.6-560-g9d51dce not warn.

Can somebody shed light on this?

% /home/sand/src/perl/repoperls/installed-perls/perl/v5.15.7-73-gda60b1c/9980/bin/perl -Moverload -MMath::BigInt -we '' 

% /home/sand/src/perl/repoperls/installed-perls/perl/v5.15.7-56-g5e909f4/a2da/bin/perl -Moverload -MMath::BigInt -we '' 

% /home/sand/src/perl/repoperls/installed-perls/perl/v5.15.6-561-ge2a7839/127e/bin/perl -Moverload -MMath::BigInt -we '' 
overload arg '..' is invalid at /home/src/perl/repoperls/installed-perls/perl/v5.15.6-561-ge2a7839/127e/lib/5.15.6/overload.pm line 34.


Thanks,
-- 
andreas


Summary of my perl5 (revision 5 version 15 subversion 6) configuration:
  Commit id: e2a78392aa527d2b816d2b7f838b62bd5477f12a
  Platform:
    osname=linux, osvers=2.6.32-5-amd64, archname=x86_64-linux-ld
    uname='linux k83 2.6.32-5-amd64 #1 smp thu nov 3 03:41:26 utc 2011 x86_64 gnulinux '
    config_args='-Dprefix=/home/src/perl/repoperls/installed-perls/perl/v5.15.6-561-ge2a7839/127e -Dmyhostname=k83 -Dinstallusrbinperl=n -Uversiononly -Dusedevel -des -Ui_db -Uuseithreads -Duselongdouble -DDEBUGGING=-g'
    hint=recommended, useposix=true, d_sigaction=define
    useithreads=undef, usemultiplicity=undef
    useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef
    use64bitint=define, use64bitall=define, uselongdouble=define
    usemymalloc=n, bincompat5005=undef
  Compiler:
    cc='cc', ccflags ='-fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64',
    optimize='-O2 -g',
    cppflags='-fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include'
    ccversion='', gccversion='4.4.5', gccosandvers=''
    intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678
    d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
    ivtype='long', ivsize=8, nvtype='long double', nvsize=16, Off_t='off_t', lseeksize=8
    alignbytes=16, prototype=define
  Linker and Libraries:
    ld='cc', ldflags =' -fstack-protector -L/usr/local/lib'
    libpth=/usr/local/lib /lib/../lib /usr/lib/../lib /lib /usr/lib /lib64 /usr/lib64
    libs=-lnsl -ldb -ldl -lm -lcrypt -lutil -lc
    perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc
    libc=/lib/libc-2.11.2.so, so=so, useshrplib=false, libperl=libperl.a
    gnulibc_version='2.11.2'
  Dynamic Linking:
    dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E'
    cccdlflags='-fPIC', lddlflags='-shared -O2 -g -L/usr/local/lib -fstack-protector'


Characteristics of this binary (from libperl): 
  Compile-time options: HAS_TIMES PERLIO_LAYERS PERL_DONT_CREATE_GVSV
                        PERL_MALLOC_WRAP PERL_PRESERVE_IVUV PERL_USE_DEVEL
                        USE_64_BIT_ALL USE_64_BIT_INT USE_LARGE_FILES
                        USE_LOCALE USE_LOCALE_COLLATE USE_LOCALE_CTYPE
                        USE_LOCALE_NUMERIC USE_LONG_DOUBLE USE_PERLIO
                        USE_PERL_ATOF
  Built under linux
  Compiled at Jan 22 2012 12:20:36
  @INC:
    /home/src/perl/repoperls/installed-perls/perl/v5.15.6-561-ge2a7839/127e/lib/site_perl/5.15.6/x86_64-linux-ld
    /home/src/perl/repoperls/installed-perls/perl/v5.15.6-561-ge2a7839/127e/lib/site_perl/5.15.6
    /home/src/perl/repoperls/installed-perls/perl/v5.15.6-561-ge2a7839/127e/lib/5.15.6/x86_64-linux-ld
    /home/src/perl/repoperls/installed-perls/perl/v5.15.6-561-ge2a7839/127e/lib/5.15.6
    .


Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About