Details
-
Improvement
-
Status: Open
-
Minor
-
Resolution: Unresolved
-
0.9.2
-
None
-
None
Description
Currently a set<> type in Thrift equates to a hash where the value of each type is set to 1. The keys are interpreted as strings and therefore lose their ordering. The TestClient for cpp sends:
The TestServer for perl (which I am writing to verify SSL server refactoring) receives:
$thing HASH(0x35da228)=
{ -1 => '1', -2 => '1', 0 => '1', 1 => '1', 2 => '1' }
Note how -1 and -2 are transposed. Further, there are no set manipulations available.
Recommend the use of Set::Scalar as a required perl dependency for proper set operations.
The old behavior could be preserved through a compiler flag for perl ensuring that existing products that rely on the current implementation don't have to change.
Attachments
Issue Links
- relates to
-
THRIFT-1346 Incorrectly generates code for 'set' return type.
- Open
- supercedes
-
THRIFT-3595 Perl Bindings: Set serialization/deserialization differs
- Closed