MCPcopy Create free account
hub / github.com/apache/arrow / CheckMinMaxZeroesSign

Method CheckMinMaxZeroesSign

cpp/src/parquet/statistics_test.cc:1418–1429  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1416
1417 template <typename Stats, typename Values>
1418 void CheckMinMaxZeroesSign(Stats stats, const Values& values) {
1419 stats->Update(values.data(), values.size(), /*null_count=*/0);
1420 ASSERT_TRUE(stats->HasMinMax());
1421
1422 this->CheckEq(stats->min(), positive_zero_);
1423 ASSERT_TRUE(this->signbit(stats->min()));
1424 ASSERT_EQ(stats->EncodeMin(), EncodeValue(negative_zero_));
1425
1426 this->CheckEq(stats->max(), positive_zero_);
1427 ASSERT_FALSE(this->signbit(stats->max()));
1428 ASSERT_EQ(stats->EncodeMax(), EncodeValue(positive_zero_));
1429 }
1430
1431 // ARROW-5562: Ensure that -0.0f and 0.0f values are properly handled like in
1432 // parquet-mr

Callers

nothing calls this directly

Calls 11

CheckEqMethod · 0.95
signbitMethod · 0.95
EncodeValueFunction · 0.85
HasMinMaxMethod · 0.80
EncodeMinMethod · 0.80
EncodeMaxMethod · 0.80
UpdateMethod · 0.45
dataMethod · 0.45
sizeMethod · 0.45
minMethod · 0.45
maxMethod · 0.45

Tested by

no test coverage detected