Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Data-Compare CPAN distribution.

Report information
The Basics
Id: 3867
Status: resolved
Worked: 1 hour (60 min)
Priority: 0/
Queue: Data-Compare

People
Owner: dcantrell [...] cpan.org
Requestors: david [...] cantrell.org.uk
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.02
Fixed in: (no value)



Subject: Failures with Scalar::Properties objects, also dodgy /o on regex
There is a /o on a pattern match in the module which I believe may cause incorrect operation as the pattern contains an interpolated variable which may vary from one invocation to the next. Additionally, when making comparisons to Scalar::Properties objects, comparisons break. This may also affect any other classes which overload the numify and/or stringify operations. I have a combined patch for both, but am loathe to submit it without discussing exactly how S::P objects should be compared to ordinary scalars. The documentation for my patch says: Note that Scalar::Properties objects are a special case. If you compare a scalar and a Scalar::Properties, then they will be considered the same if the two values are the same, regardless of the presence of properties. If you compare two Scalar::Properties objects, then they will only be considered the same if the values and the properties­ match. This also applies to Scalar::Properties objects embedded deep down in nested data structures.