This file is indexed.

/usr/share/doc/libghc-quickcheck2-doc/html/Test-QuickCheck-Function.html is in libghc-quickcheck2-doc 2.4.2-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Test.QuickCheck.Function</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Test-QuickCheck-Function.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="src/Test-QuickCheck-Function.html">Source</a></li><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">QuickCheck-2.4.2: Automatic testing of Haskell programs</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Safe Haskell</th><td>Safe-Infered</td></tr></table><p class="caption">Test.QuickCheck.Function</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Generation of random shrinkable, showable functions.
 Not really documented at the moment!
</p><p>Example of use:
</p><pre class="screen"><code class="prompt">&gt;&gt;&gt; </code><strong class="userinput"><code>:{
</code></strong><code class="prompt">&gt;&gt;&gt; </code><strong class="userinput"><code>let prop :: Fun String Integer -&gt; Bool
</code></strong><code class="prompt">&gt;&gt;&gt; </code><strong class="userinput"><code>prop (Fun _ f) = f &quot;monkey&quot; == f &quot;banana&quot; || f &quot;banana&quot; == f &quot;elephant&quot;
</code></strong><code class="prompt">&gt;&gt;&gt; </code><strong class="userinput"><code>:}
</code></strong><code class="prompt">&gt;&gt;&gt; </code><strong class="userinput"><code>quickCheck prop
</code></strong>*** Failed! Falsifiable (after 3 tests and 134 shrinks):     
{&quot;elephant&quot;-&gt;1, &quot;monkey&quot;-&gt;1, _-&gt;0}
</pre><p>To generate random values of type <code><code><a href="Test-QuickCheck-Function.html#t:Fun">Fun</a></code> a b</code>,
 you must have an instance <code><code><a href="Test-QuickCheck-Function.html#t:Function">Function</a></code> a</code>.
 If your type has a <code><a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Text-Show.html#t:Show">Show</a></code> instance, you can use <code><a href="Test-QuickCheck-Function.html#v:functionShow">functionShow</a></code> to write the instance; otherwise,
 use <code><a href="Test-QuickCheck-Function.html#v:functionMap">functionMap</a></code> to give a bijection between your type and a type that is already an instance of <code><a href="Test-QuickCheck-Function.html#t:Function">Function</a></code>.
 See the <code><code><a href="Test-QuickCheck-Function.html#t:Function">Function</a></code> [a]</code> instance for an example of the latter.
</p></div></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:Fun" class="def">Fun</a> a b <a href="src/Test-QuickCheck-Function.html#Fun" class="link">Source</a></p><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:Fun" class="def">Fun</a> (a <a href="Test-QuickCheck-Function.html#t::-45--62-">:-&gt;</a> b, b) (a -&gt; b)</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="subs instances"><p id="control.i:Fun" class="caption collapser" onclick="toggleSection('i:Fun')">Instances</p><div id="section.i:Fun" class="show"><table><tr><td class="src">(<a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Text-Show.html#t:Show">Show</a> a, <a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Text-Show.html#t:Show">Show</a> b) =&gt; <a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Text-Show.html#t:Show">Show</a> (<a href="Test-QuickCheck-Function.html#t:Fun">Fun</a> a b)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">(<a href="Test-QuickCheck-Function.html#t:Function">Function</a> a, <a href="Test-QuickCheck-Arbitrary.html#t:CoArbitrary">CoArbitrary</a> a, <a href="Test-QuickCheck-Arbitrary.html#t:Arbitrary">Arbitrary</a> b) =&gt; <a href="Test-QuickCheck-Arbitrary.html#t:Arbitrary">Arbitrary</a> (<a href="Test-QuickCheck-Function.html#t:Fun">Fun</a> a b)</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:apply" class="def">apply</a> ::  <a href="Test-QuickCheck-Function.html#t:Fun">Fun</a> a b -&gt; a -&gt; b<a href="src/Test-QuickCheck-Function.html#apply" class="link">Source</a></p></div><div class="top"><p class="src"><span class="keyword">data</span>  a <a name="t::-45--62-" class="def">:-&gt;</a> c <a href="src/Test-QuickCheck-Function.html#%3A-%3E" class="link">Source</a></p><div class="subs instances"><p id="control.i::-45--62-" class="caption collapser" onclick="toggleSection('i::-45--62-')">Instances</p><div id="section.i::-45--62-" class="show"><table><tr><td class="src"><a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Control-Monad.html#t:Functor">Functor</a> (<a href="Test-QuickCheck-Function.html#t::-45--62-">:-&gt;</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">(<a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Text-Show.html#t:Show">Show</a> a, <a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Text-Show.html#t:Show">Show</a> b) =&gt; <a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Text-Show.html#t:Show">Show</a> (<a href="Test-QuickCheck-Function.html#t::-45--62-">:-&gt;</a> a b)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">(<a href="Test-QuickCheck-Function.html#t:Function">Function</a> a, <a href="Test-QuickCheck-Arbitrary.html#t:CoArbitrary">CoArbitrary</a> a, <a href="Test-QuickCheck-Arbitrary.html#t:Arbitrary">Arbitrary</a> b) =&gt; <a href="Test-QuickCheck-Arbitrary.html#t:Arbitrary">Arbitrary</a> (<a href="Test-QuickCheck-Function.html#t::-45--62-">:-&gt;</a> a b)</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">class</span>  <a name="t:Function" class="def">Function</a> a  <span class="keyword">where</span><a href="src/Test-QuickCheck-Function.html#Function" class="link">Source</a></p><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:function" class="def">function</a> ::  (a -&gt; b) -&gt; a <a href="Test-QuickCheck-Function.html#t::-45--62-">:-&gt;</a> b<a href="src/Test-QuickCheck-Function.html#function" class="link">Source</a></p></div><div class="subs instances"><p id="control.i:Function" class="caption collapser" onclick="toggleSection('i:Function')">Instances</p><div id="section.i:Function" class="show"><table><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> <a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> <a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Data-Char.html#t:Char">Char</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> <a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Data-Int.html#t:Int">Int</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> <a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Prelude.html#t:Integer">Integer</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> <a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Data-Word.html#t:Word8">Word8</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> ()</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> <a href="Test-QuickCheck-Poly.html#t:OrdC">OrdC</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> <a href="Test-QuickCheck-Poly.html#t:OrdB">OrdB</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> <a href="Test-QuickCheck-Poly.html#t:OrdA">OrdA</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> <a href="Test-QuickCheck-Poly.html#t:C">C</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> <a href="Test-QuickCheck-Poly.html#t:B">B</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> <a href="Test-QuickCheck-Poly.html#t:A">A</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> a =&gt; <a href="Test-QuickCheck-Function.html#t:Function">Function</a> [a]</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-QuickCheck-Function.html#t:Function">Function</a> a =&gt; <a href="Test-QuickCheck-Function.html#t:Function">Function</a> (<a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">(<a href="Test-QuickCheck-Function.html#t:Function">Function</a> a, <a href="Test-QuickCheck-Function.html#t:Function">Function</a> b) =&gt; <a href="Test-QuickCheck-Function.html#t:Function">Function</a> (<a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Data-Either.html#t:Either">Either</a> a b)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">(<a href="Test-QuickCheck-Function.html#t:Function">Function</a> a, <a href="Test-QuickCheck-Function.html#t:Function">Function</a> b) =&gt; <a href="Test-QuickCheck-Function.html#t:Function">Function</a> (a, b)</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:functionMap" class="def">functionMap</a> :: <a href="Test-QuickCheck-Function.html#t:Function">Function</a> b =&gt; (a -&gt; b) -&gt; (b -&gt; a) -&gt; (a -&gt; c) -&gt; a <a href="Test-QuickCheck-Function.html#t::-45--62-">:-&gt;</a> c<a href="src/Test-QuickCheck-Function.html#functionMap" class="link">Source</a></p></div><div class="top"><p class="src"><a name="v:functionShow" class="def">functionShow</a> :: (<a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Text-Show.html#t:Show">Show</a> a, <a href="/usr/share/doc/ghc-doc/html/libraries/base-4.5.0.0/Text-Read.html#t:Read">Read</a> a) =&gt; (a -&gt; c) -&gt; a <a href="Test-QuickCheck-Function.html#t::-45--62-">:-&gt;</a> c<a href="src/Test-QuickCheck-Function.html#functionShow" class="link">Source</a></p></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.10.0</p></div></body></html>