[ https://issues.apache.org/jira/browse/THRIFT-783?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12872228#action_12872228 ]
Jonathan Ellis commented on THRIFT-783: --------------------------------------- Bug report fail on my part. Sorry about that. The problem is when you have a _list_ (or presumably other collection) of binary, then code like this gets generated: {code} struct SlicePredicate { 1: optional list<binary> column_names, ... {code} {code} if (!this.column_names.equals(that.column_names)) return false; {code} ... because java's List does the Wrong Thing with array elements (calling .equals instead of Arrays.equals). > .equals java method is broken on structs containing binary-type fields > ---------------------------------------------------------------------- > > Key: THRIFT-783 > URL: https://issues.apache.org/jira/browse/THRIFT-783 > Project: Thrift > Issue Type: Bug > Components: Compiler (Java) > Reporter: Jonathan Ellis > Fix For: 0.4 > > > The generated code uses field1.equals(field2) (which is never the case except > for the trivial one of field1==field2) instead of Arrays.equals(field1, > field2). -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.