develooper Front page | perl.perl5.porters | Postings from March 2000

[ID 20000324.059] stumbled on a bug?

Cere Davis
March 24, 2000 15:38
[ID 20000324.059] stumbled on a bug?
Message ID:

This is a bug report for perl from,
generated with the help of perlbug 1.26 running under perl 5.00503.

[Please enter your report here]

I don't know if this is a bug or....

but I've got this really crude piece of Perl code that simply converts
a Month string into a month number.  It looks like so:

  if($month eq "Mar"){$month=03;} if($month eq "Jan"){$month=01;}
  if($month eq "Feb"){$month=02;} if($month eq "Apr"){$month=04;}
  if($month eq "May"){$month=05;} if($month eq "Jun"){$month=06;}
  if($month eq "Nov"){$month=11;} if($month eq "Dec"){$month=12;}
  if($month eq "Jul"){$month=07;} if($month eq "Aug"){$month="08";}
  if($month eq "Sep"){$month="09";} if($month eq "Oct"){$month=10;}
  print " $month\n";

if I take the quotes out of the 09 or 08 months I get a compile time
error that says:

Illegal octal digit at ./ line 13, at end of line
Execution of ./ aborted due to compilation errors.

(Ignore the line numbers in the error.)  I know that the errors are easy coming from the unquoted 08 and 09 months.

What's up with this weirdness?

[Please do not change anything below this line]

Site configuration information for perl 5.00503:

Configured by cere at Mon Sep 20 14:17:11 PDT 1999.

Summary of my perl5 (5.0 patchlevel 5 subversion 3) configuration:
    osname=dec_osf, osvers=4.0, archname=alpha-dec_osf
    uname='osf1 v4.0 878 alpha '
    hint=previous, useposix=true, d_sigaction=define
    usethreads=undef useperlio=undef d_sfio=undef
    cc='cc', optimize='-O4', gccversion=
    cppflags='-std -ieee -D_INTRINSICS -I/usr/local/include -DLANGUAGE_C'
    ccflags ='-std -fprm d -ieee -D_INTRINSICS -I/usr/local/include -DLANGUAGE_C'
    stdchar='unsigned char', d_stdstdio=define, usevfork=false
    intsize=4, longsize=8, ptrsize=8, doublesize=8
    d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=8
    alignbytes=8, usemymalloc=y, prototype=define
  Linker and Libraries:
    ld='ld', ldflags =' -L/usr/local/lib'
    libpth=/usr/local/lib /usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /var/shlib
    libs=-lnsl -ldbm -ldb -lm
    libc=/usr/shlib/, so=so, useshrplib=true,
  Dynamic Linking:
    dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='  -Wl,-rpath,/uns/mind/usr/local/perl5/lib/5.00503/alpha-dec_osf/CORE'
    cccdlflags=' ', lddlflags='-shared -expect_unresolved "*" -O4 -msym -s -L/usr/local/lib'

Locally applied patches:

@INC for perl 5.00503:

Environment for perl 5.00503:
    LANG (unset)
    LANGUAGE (unset)
    LOGDIR (unset)
    PERL_BADLANG (unset)
    SHELL=/bin/ksh Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About