Andrea Vezzosi pushed to branch wip/romes/async-rpc at Glasgow Haskell Compiler / GHC Commits: 460a1d8f by Andrea Vezzosi at 2026-11-15T17:06:36+01:00 fixup! interp: fix runWithPipes on Windows when without -threaded - - - - - 1 changed file: - libraries/ghci/GHCi/Message/Async.hs Changes: ===================================== libraries/ghci/GHCi/Message/Async.hs ===================================== @@ -598,9 +598,8 @@ drainPipe p unmask = catch loop (void . replyToPendings) where Just q -> writeTQueue q (uq,bs) Cancel uq -> cancelRequest am uq - replyToPendings e = do - atomically $ failPendingReplies p e - pipeCloseRead p `catch` \(_ :: IOException) -> pure () + replyToPendings e = finally (pipeCloseRead p `catch` \(_ :: IOException) -> pure ()) -- TODO: log with verbose. + . atomically $ failPendingReplies p e am = pipeAsyncMngr p @@ -669,8 +668,8 @@ fillPipe p unmask = loop `catch` cleanup Nothing where am = pipeAsyncMngr p - cleanup last_write e0 = do - atomically $ do + cleanup last_write e0 = finally (pipeCloseWrite p `catch` \(_ :: IOException) -> pure ()) -- TODO: log with verbose + . atomically $ do -- deactivate here too so we keep track of the exception if end still 'Open'. s <- deactivatePipeEnd (pipeWriteStatus p) (Just e0) case last_write of @@ -680,7 +679,6 @@ fillPipe p unmask = loop `catch` cleanup Nothing where putTMVar var . Left $ if isOpen s then e0 else toException PipeWriteClosedException -- real exception already reported once failPendingWrites p $ toException PipeWriteClosedException - pipeCloseWrite p `catch` \(_ :: IOException) -> pure () failPendingWrites :: Pipe -> SomeException -> STM () failPendingWrites p e = do View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/460a1d8f3947e81193bc2b2c7d2c6d73... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/460a1d8f3947e81193bc2b2c7d2c6d73... You're receiving this email because of your account on gitlab.haskell.org. Manage all notifications: https://gitlab.haskell.org/-/profile/notifications | Help: https://gitlab.haskell.org/help
participants (1)
-
Andrea Vezzosi (@trac-Saizan)