Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery

Re^4: random behaviour of perl hashes

by liz (Monsignor)
on Aug 28, 2006 at 20:57 UTC ( #570047=note: print w/replies, xml ) Need Help??

in reply to Re^3: random behaviour of perl hashes
in thread random behaviour of perl hashes

According to "perlrun":

The default behaviour is to randomise unless the PERL_HASH_SEED is set. If Perl has been compiled with "-DUSE_HASH_SEED_EXPLICIT", the default behaviour is not to randomise unless the PERL_HASH_SEED is set.

perhaps ActiveState Perl is compiled with -DUSE_HASH_SEED_EXPLICIT ?

perl -V
might tell you whether that is the case.


Replies are listed 'Best First'.
Re^5: random behaviour of perl hashes
by swampyankee (Parson) on Aug 28, 2006 at 21:13 UTC

    perl -v returns (among many other data):

    -GF -W3 -MD -Zi
    -DNDEBUG -O1 -DWIN32

    It would seem not, unless -DNO_HASH_SEED has a similar effect.


    Only two things are infinite, the universe and human stupidity, and I'm not sure about the former.

    Albert Einstein

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://570047]
[Cosmic37]: I guess it is searching for the string "$mydt"
[Corion]: Indeed cool, erix ;)
[Cosmic37]: rather than the value of $mydt which is a date time strong such as 2016-01-01 12:30:56
[Corion]: Cosmic37: No, but maybe $mydt doesn't contain what you think it does, or it contains characters that are special in a regular expression? Try if( $line =~ /\Q$mydt\E/) { ... for a literal match
[Cosmic37]: I mean string grrr
[Corion]: Maybe add an else branch in which you print what the values of $line and $mydt are?
[Cosmic37]: ah thank you I will try
[Cosmic37]: you are right $mydt did not contain what I expected... :-D I will now think :-D
[Cosmic37]: crunch...grind... whirr...gnashing metal crunching cogs...

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (9)
As of 2017-06-29 17:02 GMT
Find Nodes?
    Voting Booth?
    How many monitors do you use while coding?

    Results (673 votes). Check out past polls.