develooper Front page | perl.perl5.porters | Postings from September 2011

Storable

From:
Sascha Ott
Date:
September 11, 2011 15:06
Subject:
Storable
Message ID:
CA92D0A5.955D%s.ott@warwick.ac.uk

Dear Perl5-porters,

I am using the Storable module to serialise data structures and need their
representation to be identical when the data structures are identical.
However, I am finding that when a different user runs the same code the
representation varies (I made sure the data structures created and
computations done are the same) - example output attached.

It looks like it may be related to the bug that is reported on the Storable
site as:

"Setting $Storable::canonical may not yield frozen strings that compare
equal due to possible stringification of numbers. When the string version of
a scalar exists, it is the form stored; therefore, if you happen to use your
numbers as strings between two freezing operations on the same data
structures, you will get different results."

Is my attached output the sort of result this bug can cause? Do you have
more information on this bug? Could it result in the same computation done
by a different user yielding a different outcome? What does "string version
of a scalar exists" mean - existing in memory?

Any advice appreciated,
Sascha

---------------------------------
Sascha Ott, PhD
Associate Professor
Warwick Systems Biology Centre
Coventry House, Room 327
University of Warwick
CV4 7AL Coventry
United Kingdom

Tel.: +44-(0)24-761-50258
E-mail: s.ott@warwick.ac.uk
http://www2.warwick.ac.uk/fac/sci/systemsbiology/staff/ott/





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