You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2017/12/14 19:19:00 UTC
[jira] [Commented] (THRIFT-4099) Auto-derive Hash for generated
Rust structs
[ https://issues.apache.org/jira/browse/THRIFT-4099?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16291396#comment-16291396 ]
ASF GitHub Bot commented on THRIFT-4099:
----------------------------------------
Github user przygienda commented on the issue:
https://github.com/apache/thrift/pull/1246
Nah, I'm not AWOL but just completely under water with stuff here and my version here works ;-) ... I agree that we should split the stuff up. I hope to find cycles in new year. Tell me what you want to attack first and we can work together ...
> Auto-derive Hash for generated Rust structs
> -------------------------------------------
>
> Key: THRIFT-4099
> URL: https://issues.apache.org/jira/browse/THRIFT-4099
> Project: Thrift
> Issue Type: Improvement
> Components: Rust - Compiler
> Reporter: Allen George
> Assignee: James E. King, III
> Priority: Minor
> Fix For: 0.11.0
>
>
> Currently Thrift structs are turned into Rust {{struct}} definitions that do not have an auto-derived {{Hash}}. We should auto-derive this trait.
> The following behaviors should be checked:
> # Can still derive {{Hash}} even if the struct contains a {{double}}
> # Can still derive {{Hash}} even if the struct contains {{set<double>}}
> # Can still derive {{Hash}} even if the struct contains {{map<double, double>}}
> Basically, doubles are represented in the auto-generated code by {{OrderedFloat}} instead of {{f64}} since we cannot derive a hash for, or order Rust floats. The resulting code should work even if doubles are contained any where in the structure.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)