aboutsummaryrefslogtreecommitdiffstats
path: root/src/Test/VeriFuzz/Circuit.hs
diff options
context:
space:
mode:
authorYann Herklotz <ymherklotz@gmail.com>2019-01-10 15:49:13 +0000
committerYann Herklotz <ymherklotz@gmail.com>2019-01-10 15:49:13 +0000
commitdac34f6ff5c46f11fe6c548b92a02ebf4f10d7e9 (patch)
treee51f51b4e82f3c764bcba88725e20e4fb10284da /src/Test/VeriFuzz/Circuit.hs
parent3f1190cd7fc873449a1fd430386aa4b773d010ac (diff)
downloadverismith-dac34f6ff5c46f11fe6c548b92a02ebf4f10d7e9.tar.gz
verismith-dac34f6ff5c46f11fe6c548b92a02ebf4f10d7e9.zip
Rename files out of the module
Diffstat (limited to 'src/Test/VeriFuzz/Circuit.hs')
-rw-r--r--src/Test/VeriFuzz/Circuit.hs38
1 files changed, 0 insertions, 38 deletions
diff --git a/src/Test/VeriFuzz/Circuit.hs b/src/Test/VeriFuzz/Circuit.hs
deleted file mode 100644
index 7958f6a..0000000
--- a/src/Test/VeriFuzz/Circuit.hs
+++ /dev/null
@@ -1,38 +0,0 @@
-{-|
-Module : VeriFuzz.Circuit
-Description : Definition of the circuit graph.
-Copyright : (c) 2018-2019, Yann Herklotz Grave
-License : BSD-3
-Maintainer : ymherklotz [at] gmail [dot] com
-Stability : experimental
-Portability : POSIX
-
-Definition of the circuit graph.
--}
-
-module VeriFuzz.Circuit where
-
-import Data.Graph.Inductive (Gr, LNode)
-import System.Random
-import Test.QuickCheck
-
--- | The types for all the gates.
-data Gate = And
- | Or
- | Xor
- deriving (Show, Eq, Enum, Bounded, Ord)
-
--- | Newtype for the Circuit which implements a Graph from fgl.
-newtype Circuit = Circuit { getCircuit :: Gr Gate () }
-
-newtype CNode = CNode { getCNode :: LNode Gate }
-
-instance Random Gate where
- randomR (a, b) g =
- case randomR (fromEnum a, fromEnum b) g of
- (x, g') -> (toEnum x, g')
-
- random = randomR (minBound, maxBound)
-
-instance Arbitrary Gate where
- arbitrary = elements [And, Or, Xor]