Fallout-build / Fallout-build/Fallout

Adopt MoreLINQ; remove duplicated collection extensions

Open
#355 1 comment 0 reactions 0 assignees View on GitHub
breaking-change enhancement target/vCurrent
Dominant language
C#
Stars
154
Forks
19
Avg merge
1d 22h
Merged PRs (30d)
15

Description

**Tier 2 — Consolidate.** `src/Fallout.Utilities/Collections/` (~900 LOC, 23 files) contains many LINQ-like helpers that duplicate [**MoreLINQ**](https://www.nuget.org/packages/morelinq): `Enumerable.Distinct.cs` (DistinctBy), `Enumerable.Random.cs` (Random/Shuffle), `Enumerable.TakeUntil.cs`, `Enumerable.ForEach.cs`.

### Action
Add MoreLINQ; delete the duplicated helpers and redirect call sites.

### Keep (genuinely Fallout-specific — do NOT delete)
- `Enumerable.TopologicalSort.cs` (cycle-detecting sort used for target ordering)
- `LookupTable.cs` (mutable `ILookup` — no BCL/MoreLINQ equivalent)
- `Enumerable.SingleOrDefaultOrError.cs` / `Enumerable.ToDictionary.cs` (custom diagnostic messages)

### ⚠️ Breaking change
These are public extension methods. Removal breaks consumers → `breaking-change`, `experimental`, batched to yearly major, CHANGELOG migration note. Where feasible, keep `[Obsolete]` forwarders.

### Acceptance
- [ ] MoreLINQ added to `Directory.Packages.props`
- [ ] Duplicated `Distinct`/`Random`/`TakeUntil`/`ForEach` helpers removed or obsoleted
- [ ] Fallout-specific helpers retained
- [ ] CHANGELOG entry + migration note

_From dependency-consolidation audit, 2026-06-02._

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.