Skip to content

Commit 3afd70f

Browse files
ch1boclaude
andcommitted
Leios N: add field names to Reception
Replace the positional definition of `Reception` with named fields `receivalTimes` and `received`: data Reception a = MkReception { receivalTimes :: !(IntMap Time) , received :: !a } Positional pattern matches continue to work; the fields just make record-style access available where it reads better. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent 319743a commit 3afd70f

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

network-mux/src/Network/Mux/Channel.hs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,9 @@ data Channel m a = Channel {
8989
}
9090

9191
-- | A received value paired with the per-chunk arrival times.
92-
data Reception a = MkReception !(IntMap Time) !a
92+
data Reception a = MkReception { receivalTimes :: !(IntMap Time)
93+
, received :: !a
94+
}
9395
deriving (Foldable, Functor, Traversable)
9496

9597
-- | Given an isomorphism between @a@ and @b@ (in Kleisli category), transform

0 commit comments

Comments
 (0)