You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "candiduslynx (via GitHub)" <gi...@apache.org> on 2023/06/01 16:03:59 UTC

[GitHub] [arrow] candiduslynx commented on a diff in pull request #35872: GH-35871: [Go] Account for struct validity bitmap in `array.ApproxEqual`

candiduslynx commented on code in PR #35872:
URL: https://github.com/apache/arrow/pull/35872#discussion_r1213378184


##########
go/arrow/array/compare.go:
##########
@@ -735,10 +735,14 @@ func arrayApproxEqualFixedSizeList(left, right *FixedSizeList, opt equalOption)
 }
 
 func arrayApproxEqualStruct(left, right *Struct, opt equalOption) bool {
-	for i, lf := range left.fields {
-		rf := right.fields[i]
-		if !arrayApproxEqual(lf, rf, opt) {
-			return false
+	for i := 0; i < left.Len(); i++ {
+		if left.IsNull(i) {
+			continue
+		}

Review Comment:
   we already checked for this in `baseArrayEqual`, see other `approx` implementations



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org