Skip to content

fix(stats): remove duplicate big-endian TDigestStub/HllSketchStub defs#3857

Merged
jqnatividad merged 1 commit into
masterfrom
fix-s390x-duplicate-stubs
May 15, 2026
Merged

fix(stats): remove duplicate big-endian TDigestStub/HllSketchStub defs#3857
jqnatividad merged 1 commit into
masterfrom
fix-s390x-duplicate-stubs

Conversation

@jqnatividad
Copy link
Copy Markdown
Collaborator

Summary

  • PR fix(stats): restore big-endian build by giving slot fallbacks an accessible .0 #3850's second commit (addressing roborev review 2085 by moving PartialEq from a derive to an explicit impl on TDigestSlot/HllSlot) accidentally left the old stub struct + impl block alongside the new one. On big-endian targets both TDigestStub and HllSketchStub ended up defined twice — once with #[derive(Default, Clone, PartialEq)] and once with #[derive(Default, Clone)] — producing E0428 (name … is defined multiple times), E0119 (conflicting impls of Default/Clone), E0592 (duplicate definitions), and E0034 (multiple applicable items in scope on update/quantile/is_empty/estimate) and breaking the s390x build.
  • The s390x workflow is workflow_dispatch-triggered only, so the regression slipped past normal CI — see run 25929817626.
  • Fix: delete the redundant #[derive(Default, Clone, PartialEq)] copies and keep the leaner #[derive(Default, Clone)] versions. This matches the post-refactor intent of fix(stats): restore big-endian build by giving slot fallbacks an accessible .0 #3850PartialEq lives on the wrapping TDigestSlot/HllSlot slot types (manual impl PartialEq returning a constant true), not on the inner stubs.

Test plan

  • Standalone rustc --target s390x-unknown-linux-gnu --emit metadata round-trip of the cfg-gated block (same shape-only verification approach used in fix(stats): restore big-endian build by giving slot fallbacks an accessible .0 #3850's commit message). All four symbols — TDigestStub, TDigestSlot, HllSketchStub, HllSlot — appear exactly once in the resulting metadata.
  • cargo test --test tests stats -F all_features (little-endian) — 749 passed, 0 failed.
  • cargo clippy -F all_features — clean.
  • Manual re-run of the s390x workflow on this branch to confirm the build now passes on the native big-endian runner.

🤖 Generated with Claude Code

… defs

PR #3850's second commit (addressing roborev review 2085 by moving
`PartialEq` from a derive to an explicit `impl` on `TDigestSlot`/
`HllSlot`) accidentally left the *old* stub struct + impl alongside
the new one. On big-endian targets both `TDigestStub` and
`HllSketchStub` were therefore defined twice — once with
`#[derive(Default, Clone, PartialEq)]` and once with
`#[derive(Default, Clone)]` — producing E0428, E0119, E0592, and
E0034 errors and breaking the s390x build (run 25929817626).

Delete the redundant `#[derive(Default, Clone, PartialEq)]` copies
and keep the leaner `#[derive(Default, Clone)]` versions, matching
the post-refactor intent of #3850: `PartialEq` lives on the wrapping
`TDigestSlot`/`HllSlot` slot types (manual `impl PartialEq` with
constant `true`), not on the inner stubs.

Verified by a standalone `rustc --target s390x-unknown-linux-gnu
--emit metadata` round-trip of the cfg-gated block (same shape-only
verification approach #3850's commit message describes) and by
running `cargo test --test tests stats -F all_features` (749 passed)
on little-endian.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@codacy-production
Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@jqnatividad jqnatividad merged commit f74168e into master May 15, 2026
17 of 18 checks passed
@jqnatividad jqnatividad deleted the fix-s390x-duplicate-stubs branch May 15, 2026 19:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant