← Back to Pull requests

Remove unused internal helpers and fix `TextTerminal` relative moves and `reshape!` #64880

Closed
unknown closed this pull request without merging on Nov 13, 2026 13:50 UTC
View on GitHub
unknown unknown commented on Nov 11, 2026 13:35 UTC
Author

AKA take internal seriously, except where packages use them.

Claude:

---

Removes internal code that nothing calls, in the repo or in registered packages (checked against all of General's source), and fixes the TextTerminal relative-move fallbacks and reshape!, which could never have worked.

  • base: the BrokenInt checked-arithmetic fallbacks (both unions are Union{}, so these methods were never defined), _lookup_cpu and ReshapedArrayIterator.

  • Terminals: the 2-arg TextTerminal cmove_ fallbacks called cmove without the terminal, so they always threw a MethodError, and they clamped downward and rightward moves with max. They now pass the terminal and clamp with min.

  • reshape!(::Array, ::Dims): set a dims field that Array hasn't had since #56236, so it always threw a FieldError. It now sets size.

  • Compiler: nmatches.

  • Random: mt_avail(::MersenneTwister, ::Type).
  • Kept, because packages use them: vector _sub2ind, Profile get_task_ids, ip_matches_func, test_cpu_feature, argument_datatype, Order.ordtype, _require_from_serialized, load_path_setup_code, ReshapedIndex, and the Compiler Timings module. print_callstack, push!(::IntDisjointSet) and uv_ref are kept and now tested.

    Written with Claude Code (Opus 5.5).

    Diff: 164 lines (+123 / -41) across 2 files Reviewer: IanButterworth Review duration: 2894m
    All Vouch review confidence checks passed
    Residual risk 0.16 = Change Risk (0.40) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.40 · 164 lines diff across 2 files
    0.40
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.305
    Shallow Review Depth shallow_review_depth
    0.289
    Ai Authored ai_authored
    0.050
    Real PR Conversation Timeline
    1 comments
    "Review active on #64880"
    general weight: 0.35
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 40% (MEDIUM) · Higher = larger blast radius
    40%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 15.8% · Safe to merge
    15.8%