[Git][ghc/ghc][wip/jeltsch/obtaining-os-handles] Get rid of the duplication of the caveats documentation
Wolfgang Jeltsch pushed to branch wip/jeltsch/obtaining-os-handles at Glasgow Haskell Compiler / GHC Commits: 0319831e by Wolfgang Jeltsch at 2025-12-13T20:50:37+02:00 Get rid of the duplication of the caveats documentation - - - - - 1 changed file: - libraries/ghc-internal/src/GHC/Internal/System/IO/OS.hs Changes: ===================================== libraries/ghc-internal/src/GHC/Internal/System/IO/OS.hs ===================================== @@ -316,27 +316,8 @@ withWindowsHandleWritingBiasedRaw -- ** Caveats {-$with-ref-caveats - #with-ref-caveats#There are the following caveats regarding the above - operations: - - * Flushing of buffers can fail if the given handle is readable but not - seekable. - - * If one of these operations is performed as part of an action executed by - 'System.IO.Unsafe.unsafePerformIO', - 'System.IO.Unsafe.unsafeInterleaveIO', or one of their “dupable” - variants and the user-provided action receives an asychnchronous - exception and does not catch it, then the following happens: - - - Before the overall computation is suspended, the blocking of handle - operations is removed. - - - When the computation is later resumed due to another evaluation - attempt, the blocking of handle operations is reinstantiated, the - Haskell-managed buffers are flushed again, and the user-provided - action is run from the beginning. - - Repeating the previously executed part of the user-provided action - cannot be avoided apparently. See the @[async]@ note in the source code - of "GHC.Internal.IO.Handle.Internals" for further explanation. + #with-ref-caveats#This subsection is just a dummy, whose purpose is to serve + as the target of the hyperlinks above. The real documentation of the caveats + is in the /Caveats/ subsection in the @base@ module @System.IO.OS@, which + re-exports the above operations. -} View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/0319831e3f9a15c42dd58b7d81fd8d04... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/0319831e3f9a15c42dd58b7d81fd8d04... You're receiving this email because of your account on gitlab.haskell.org.
participants (1)
-
Wolfgang Jeltsch (@jeltsch)