mirror of
https://github.com/barrucadu/dejafu.git
synced 2024-12-18 02:51:42 +03:00
Improve haddocks for settings
This commit is contained in:
parent
053ce34682
commit
2037e42d65
@ -105,15 +105,10 @@ module Test.DejaFu
|
||||
|
||||
There are a few knobs to tweak to control the behaviour of dejafu.
|
||||
The defaults should generally be good enough, but if not you have a
|
||||
few tricks available.
|
||||
|
||||
* The 'Way', which controls how schedules are explored.
|
||||
|
||||
* The 'MemType', which controls how reads and writes to @CRef@s (or
|
||||
@IORef@s) behave.
|
||||
|
||||
* The 'Discard' function, which saves memory by throwing away
|
||||
uninteresting results during exploration.
|
||||
few tricks available. The main two are: the 'Way', which controls how
|
||||
schedules are explored; and the 'MemType', which controls how reads
|
||||
and writes to @CRef@s behave; see "Test.DejaFu.Settings" for a
|
||||
complete listing.
|
||||
|
||||
-}
|
||||
|
||||
|
@ -29,9 +29,6 @@ import Test.DejaFu.Types
|
||||
|
||||
-- | SCT configuration record.
|
||||
--
|
||||
-- See 'fromWayAndMemType', 'lway', 'lmemtype', 'ldiscarder',
|
||||
-- 'ldebugShow', and 'ldebugPrint'.
|
||||
--
|
||||
-- @since unreleased
|
||||
data Settings n a = Settings
|
||||
{ _way :: Way
|
||||
|
@ -13,23 +13,21 @@
|
||||
module Test.DejaFu.SCT
|
||||
( -- * Running Concurrent Programs
|
||||
runSCT
|
||||
, runSCTWithSettings
|
||||
, resultsSet
|
||||
, resultsSetWithSettings
|
||||
|
||||
-- ** Strict variants
|
||||
, runSCT'
|
||||
, resultsSet
|
||||
, resultsSet'
|
||||
, runSCTWithSettings'
|
||||
, resultsSetWithSettings'
|
||||
|
||||
-- ** Configuration
|
||||
, runSCTWithSettings
|
||||
, runSCTWithSettings'
|
||||
, resultsSetWithSettings
|
||||
, resultsSetWithSettings'
|
||||
, module Test.DejaFu.Settings
|
||||
|
||||
-- * Deprecated
|
||||
, runSCTDiscard
|
||||
, resultsSetDiscard
|
||||
, runSCTDiscard'
|
||||
, resultsSetDiscard
|
||||
, resultsSetDiscard'
|
||||
, sctBound
|
||||
, sctBoundDiscard
|
||||
|
@ -132,9 +132,32 @@ module Test.DejaFu.Settings
|
||||
, ldiscard
|
||||
|
||||
-- ** Early exit
|
||||
|
||||
-- | Sometimes we don't want to wait for all executions to be
|
||||
-- explored, we just want to stop as soon as a particular result is
|
||||
-- found. An early-exit predicate, which has type @Either Failure a
|
||||
-- -> Bool@, can opt to halt execution when such a result is found.
|
||||
--
|
||||
-- All results found up to, and including, the one which terminates
|
||||
-- the exploration are reported.
|
||||
--
|
||||
-- __Usage in combination with a discard function:__ A discard
|
||||
-- function can be used in combination with early-exit. As usual,
|
||||
-- results or traces will be discarded as appropriate. If a single
|
||||
-- result causes the early-exit function to return @True@ and the
|
||||
-- discard function to return @Just DiscardResultAndTrace@, the
|
||||
-- exploration will end early, but the result will not be included
|
||||
-- in the output.
|
||||
|
||||
, learlyExit
|
||||
|
||||
-- ** Debug output
|
||||
|
||||
-- | You can opt to receive debugging messages by setting debugging
|
||||
-- print and show functions. Enabling debugging doesn't change any
|
||||
-- behaviour, it just causes messages to be printed. These options
|
||||
-- are most likely not useful for anyone not developing dejafu.
|
||||
|
||||
, ldebugShow
|
||||
, ldebugPrint
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user