on develop help sign in
Update the doc strings for traceDyn*
commit4e7d1b13bc4019bdd793f59dd9c26d1d6d406d85 authorRyan Trinkle <ryan.trinkle@gmail.com> dateWed 15 Mar 2017, 12:13 (10 years ago) parentd78ba43
1 file changed+5−3
src/Reflex/Dynamic.hs+5−3
src/Reflex/Dynamic.hs+5−3
@@ -185,8 +185,9 @@ distributeListOverDynPure =
185185joinDynThroughMap :: forall t k a. (Reflex t, Ord k) => Dynamic t (Map k (Dynamic t a)) -> Dynamic t (Map k a)
186186joinDynThroughMap = joinDyn . fmap distributeMapOverDynPure
187187
188−-- | Print the value of the 'Dynamic' on each change and prefix it
189−-- with the provided string. This should /only/ be used for debugging.
188+-- | Print the value of the 'Dynamic' when it is first read and on each
189+-- subsequent change that is observed (as traceEvent), prefixed with the
190+-- provided string. This should /only/ be used for debugging.
190191--
191192-- Note: Just like Debug.Trace.trace, the value will only be shown if something
192193-- else in the system is depending on it.
@@ -194,7 +195,8 @@ traceDyn :: (Reflex t, Show a) => String -> Dynamic t a -> Dynamic t a
194195traceDyn s = traceDynWith $ \x -> s <> ": " <> show x
195196
196197-- | Print the result of applying the provided function to the value
197−-- of the 'Dynamic' on each change. This should /only/ be used for
198+-- of the 'Dynamic' when it is first read and on each subsequent change
199+-- that is observed (as traceEvent). This should /only/ be used for
198200-- debugging.
199201--
200202-- Note: Just like Debug.Trace.trace, the value will only be shown if something