Search is not available for this dataset
repo_name
string
path
string
license
string
full_code
string
full_size
int64
uncommented_code
string
uncommented_size
int64
function_only_code
string
function_only_size
int64
is_commented
bool
is_signatured
bool
n_ast_errors
int64
ast_max_depth
int64
n_whitespaces
int64
n_ast_nodes
int64
n_ast_terminals
int64
n_ast_nonterminals
int64
loc
int64
cycloplexity
int64
osa1/rho-torrent
src/Rho/Utils.hs
bsd-3-clause
-- | Make a `Word32` from bytes. First argument is most-significant byte. -- -- >>> mkWord32 0x1 0x0 0x0 0x0 -- 16777216 -- -- >>> mkWord32 0x0 0x0 0x0 0x1 -- 1 -- mkWord32 :: Word8 -> Word8 -> Word8 -> Word8 -> Word32 mkWord32 w1 w2 w3 w4 = fromIntegral w1 `shiftL` 24 + fromIntegral w2 `shiftL` 16 + fromIntegr...
356
mkWord32 :: Word8 -> Word8 -> Word8 -> Word8 -> Word32 mkWord32 w1 w2 w3 w4 = fromIntegral w1 `shiftL` 24 + fromIntegral w2 `shiftL` 16 + fromIntegral w3 `shiftL` 8 + fromIntegral w4
192
mkWord32 w1 w2 w3 w4 = fromIntegral w1 `shiftL` 24 + fromIntegral w2 `shiftL` 16 + fromIntegral w3 `shiftL` 8 + fromIntegral w4
137
true
true
6
8
76
89
48
41
null
null
rockdragon/julia-programming
code/haskell/SimpleJSON.hs
mit
isNull v = v == JNull
21
isNull v = v == JNull
21
isNull v = v == JNull
21
false
false
0
5
5
13
6
7
null
null
romanb/amazonka
amazonka-sns/gen/Network/AWS/SNS/DeleteTopic.hs
mpl-2.0
-- | 'DeleteTopic' constructor. -- -- The fields accessible through corresponding lenses are: -- -- * 'dtTopicArn' @::@ 'Text' -- deleteTopic :: Text -- ^ 'dtTopicArn' -> DeleteTopic deleteTopic p1 = DeleteTopic { _dtTopicArn = p1 }
252
deleteTopic :: Text -- ^ 'dtTopicArn' -> DeleteTopic deleteTopic p1 = DeleteTopic { _dtTopicArn = p1 }
122
deleteTopic p1 = DeleteTopic { _dtTopicArn = p1 }
57
true
true
0
6
56
33
21
12
null
null
HS-Carbon/hs-carbon-aggregator
3rd-party/python-pickle/Language/Python/Pickle.hs
apache-2.0
pickleBinInt :: Int -> Pickler () pickleBinInt i | i >= 0 && i < 256 = tell [BININT1 i] | i >= 256 && i < 65536 = tell [BININT2 i] | otherwise = tell [BININT i]
190
pickleBinInt :: Int -> Pickler () pickleBinInt i | i >= 0 && i < 256 = tell [BININT1 i] | i >= 256 && i < 65536 = tell [BININT2 i] | otherwise = tell [BININT i]
190
pickleBinInt i | i >= 0 && i < 256 = tell [BININT1 i] | i >= 256 && i < 65536 = tell [BININT2 i] | otherwise = tell [BININT i]
156
false
true
0
10
67
98
45
53
null
null
bos/text
tests/Tests/Properties/Builder.hs
bsd-2-clause
tb_hexadecimal_integer (a::Integer) = tb_hex a
46
tb_hexadecimal_integer (a::Integer) = tb_hex a
46
tb_hexadecimal_integer (a::Integer) = tb_hex a
46
false
false
0
7
4
19
9
10
null
null
seL4/capDL-tool
Main.hs
bsd-2-clause
processOpts (action:actions) = action (processOpts actions)
59
processOpts (action:actions) = action (processOpts actions)
59
processOpts (action:actions) = action (processOpts actions)
59
false
false
0
7
5
25
12
13
null
null
MedeaMelana/JsonGrammar
Language/JsonGrammar.hs
bsd-3-clause
aeNull :: Iso t (Value :- t) (aeObject, aeArray, _, _, _, aeNull) = $(deriveIsos ''Value)
103
aeNull :: Iso t (Value :- t) (aeObject, aeArray, _, _, _, aeNull) = $(deriveIsos ''Value)
103
(aeObject, aeArray, _, _, _, aeNull) = $(deriveIsos ''Value)
60
false
true
1
9
29
56
28
28
null
null
conal/lambda-ccc
src/LambdaCCC/Unused/Reify.hs
bsd-3-clause
letS = "lettP"
17
letS = "lettP"
17
letS = "lettP"
17
false
false
1
5
5
10
3
7
null
null
uroboros/haskell_design_patterns
chapter6/2_origami.hs
mit
showListF :: (Show a) => ListF a -> String showListF (FixT (Cons_ x r)) = (show x) ++ ", " ++ (showListF r)
110
showListF :: (Show a) => ListF a -> String showListF (FixT (Cons_ x r)) = (show x) ++ ", " ++ (showListF r)
110
showListF (FixT (Cons_ x r)) = (show x) ++ ", " ++ (showListF r)
67
false
true
4
8
25
71
33
38
null
null
urbanslug/ghc
testsuite/tests/codeGen/should_run/cgrun018.hs
bsd-3-clause
xxx = (Tfo (-0.8143#) (-0.5091#) (-0.2788#) (-0.0433#) (-0.4257#) (0.9038#) (-0.5788#) (0.7480#) (0.3246#) (1.5227#) (6.9114#) (-7.0765#))
184
xxx = (Tfo (-0.8143#) (-0.5091#) (-0.2788#) (-0.0433#) (-0.4257#) (0.9038#) (-0.5788#) (0.7480#) (0.3246#) (1.5227#) (6.9114#) (-7.0765#))
184
xxx = (Tfo (-0.8143#) (-0.5091#) (-0.2788#) (-0.0433#) (-0.4257#) (0.9038#) (-0.5788#) (0.7480#) (0.3246#) (1.5227#) (6.9114#) (-7.0765#))
184
false
false
1
8
60
87
48
39
null
null
joelburget/daily-typecheckers
src/Day7.hs
bsd-3-clause
subst2 :: String -> String -> Term2 -> Term2 subst2 from to tm = case tm of BVar2 v | v == from -> BVar2 to | otherwise -> tm FVar2 _ -> tm Abs2 v subTm | v == from -> tm | otherwise -> Abs2 v (subst2 from to subTm) App2 tm1 tm2 -> App2 (subst2 from to tm1) (subst2 from to tm2)
302
subst2 :: String -> String -> Term2 -> Term2 subst2 from to tm = case tm of BVar2 v | v == from -> BVar2 to | otherwise -> tm FVar2 _ -> tm Abs2 v subTm | v == from -> tm | otherwise -> Abs2 v (subst2 from to subTm) App2 tm1 tm2 -> App2 (subst2 from to tm1) (subst2 from to tm2)
302
subst2 from to tm = case tm of BVar2 v | v == from -> BVar2 to | otherwise -> tm FVar2 _ -> tm Abs2 v subTm | v == from -> tm | otherwise -> Abs2 v (subst2 from to subTm) App2 tm1 tm2 -> App2 (subst2 from to tm1) (subst2 from to tm2)
257
false
true
8
9
88
144
66
78
null
null
spacekitteh/smcghc
compiler/codeGen/StgCmmPrim.hs
bsd-3-clause
emitPrimOp dflags [res] SizeofByteArrayOp [arg] = emit $ mkAssign (CmmLocal res) (cmmLoadIndexW dflags arg (fixedHdrSizeW dflags) (bWord dflags))
148
emitPrimOp dflags [res] SizeofByteArrayOp [arg] = emit $ mkAssign (CmmLocal res) (cmmLoadIndexW dflags arg (fixedHdrSizeW dflags) (bWord dflags))
148
emitPrimOp dflags [res] SizeofByteArrayOp [arg] = emit $ mkAssign (CmmLocal res) (cmmLoadIndexW dflags arg (fixedHdrSizeW dflags) (bWord dflags))
148
false
false
2
9
20
66
30
36
null
null
enolan/Idris-dev
src/Idris/Info/Show.hs
bsd-3-clause
showIdrisInstalledPackages :: IO () showIdrisInstalledPackages = do ipkgs <- getIdrisInstalledPackages mapM_ putStrLn ipkgs
127
showIdrisInstalledPackages :: IO () showIdrisInstalledPackages = do ipkgs <- getIdrisInstalledPackages mapM_ putStrLn ipkgs
127
showIdrisInstalledPackages = do ipkgs <- getIdrisInstalledPackages mapM_ putStrLn ipkgs
91
false
true
0
7
16
31
14
17
null
null
ktvoelker/argon
src/Maths/Unsafe.hs
gpl-3.0
iffXY :: (Integral i) => i -> i -> XYDiff t diffXY = wrapXY
60
diffXY :: (Integral i) => i -> i -> XYDiff t diffXY = wrapXY
60
diffXY = wrapXY
15
false
true
0
8
14
31
16
15
null
null
mbakke/ganeti
src/Ganeti/Constants.hs
bsd-2-clause
esScriptSetinfo :: String esScriptSetinfo = esActionSetinfo
59
esScriptSetinfo :: String esScriptSetinfo = esActionSetinfo
59
esScriptSetinfo = esActionSetinfo
33
false
true
0
4
5
11
6
5
null
null
haslab/SecreC
src/Language/SecreC/Parser/PreProcessor.hs
gpl-3.0
coercionMsg :: Doc coercionMsg = PP.text "Controls implicit coercions" $+$ PP.nest 4 ( PP.text "offc" <+> PP.char '=' <+> PP.text "No implicit coercions" $+$ PP.text "defaultsc" <+> PP.char '=' <+> PP.text "Only for default declarations" $+$ PP.text "onc" <+> PP.char '=' <+> PP.text "For regular code (D...
425
coercionMsg :: Doc coercionMsg = PP.text "Controls implicit coercions" $+$ PP.nest 4 ( PP.text "offc" <+> PP.char '=' <+> PP.text "No implicit coercions" $+$ PP.text "defaultsc" <+> PP.char '=' <+> PP.text "Only for default declarations" $+$ PP.text "onc" <+> PP.char '=' <+> PP.text "For regular code (D...
425
coercionMsg = PP.text "Controls implicit coercions" $+$ PP.nest 4 ( PP.text "offc" <+> PP.char '=' <+> PP.text "No implicit coercions" $+$ PP.text "defaultsc" <+> PP.char '=' <+> PP.text "Only for default declarations" $+$ PP.text "onc" <+> PP.char '=' <+> PP.text "For regular code (Default)" $+$ PP...
406
false
true
0
20
84
134
61
73
null
null
blanu/arbre
Arbre/Print.hs
gpl-2.0
printEnvironment Local = ":"
28
printEnvironment Local = ":"
28
printEnvironment Local = ":"
28
false
false
0
5
3
9
4
5
null
null
harendra-kumar/asyncly
src/Streamly/Streams/StreamK/Type.hs
bsd-3-clause
unShare :: IsStream t => t m a -> t m a unShare x = mkStream $ \st yld sng stp -> foldStream st yld sng stp x
113
unShare :: IsStream t => t m a -> t m a unShare x = mkStream $ \st yld sng stp -> foldStream st yld sng stp x
113
unShare x = mkStream $ \st yld sng stp -> foldStream st yld sng stp x
73
false
true
0
8
31
67
30
37
null
null
brendanhay/gogol
gogol-bigquery/gen/Network/Google/BigQuery/Types/Product.hs
mpl-2.0
-- | Arima model fitting metrics. afmArimaFittingMetrics :: Lens' ArimaForecastingMetrics [ArimaFittingMetrics] afmArimaFittingMetrics = lens _afmArimaFittingMetrics (\ s a -> s{_afmArimaFittingMetrics = a}) . _Default . _Coerce
248
afmArimaFittingMetrics :: Lens' ArimaForecastingMetrics [ArimaFittingMetrics] afmArimaFittingMetrics = lens _afmArimaFittingMetrics (\ s a -> s{_afmArimaFittingMetrics = a}) . _Default . _Coerce
214
afmArimaFittingMetrics = lens _afmArimaFittingMetrics (\ s a -> s{_afmArimaFittingMetrics = a}) . _Default . _Coerce
136
true
true
0
11
45
53
28
25
null
null
gleachkr/Carnap
Carnap/src/Carnap/Languages/PureSecondOrder/Syntax.hs
gpl-3.0
incQuant ((SOPQuant (SOPSome s a)) :!$: (LLam f)) = (SOPQuant (SOPSome s (ASucc a))) :!$: (LLam $ \x -> subBoundVar (polyVar s (ASucc a)) x (f $ polyVar s a))
163
incQuant ((SOPQuant (SOPSome s a)) :!$: (LLam f)) = (SOPQuant (SOPSome s (ASucc a))) :!$: (LLam $ \x -> subBoundVar (polyVar s (ASucc a)) x (f $ polyVar s a))
163
incQuant ((SOPQuant (SOPSome s a)) :!$: (LLam f)) = (SOPQuant (SOPSome s (ASucc a))) :!$: (LLam $ \x -> subBoundVar (polyVar s (ASucc a)) x (f $ polyVar s a))
163
false
false
0
13
34
105
53
52
null
null
vdweegen/UvA-Software_Testing
Lab2/Bauke/Exercises.hs
gpl-3.0
pythagoreanTriplets :: [[Integer]] pythagoreanTriplets = generateTriplets 250
77
pythagoreanTriplets :: [[Integer]] pythagoreanTriplets = generateTriplets 250
77
pythagoreanTriplets = generateTriplets 250
42
false
true
0
6
6
20
11
9
null
null
cies/gelatin
gelatin-core/src/Gelatin/Core/Color.hs
bsd-3-clause
paleTurquoise :: (Num a, Fractional a) => V4 a paleTurquoise = V4 (175/255) (238/255) (238/255) 1
97
paleTurquoise :: (Num a, Fractional a) => V4 a paleTurquoise = V4 (175/255) (238/255) (238/255) 1
97
paleTurquoise = V4 (175/255) (238/255) (238/255) 1
50
false
true
0
7
15
59
31
28
null
null
hguenther/smtlib2
Language/SMTLib2/Internals/Type.hs
gpl-3.0
liftType :: List Repr tps -> List Repr idx -> List Repr (Lifted tps idx) liftType Nil idx = Nil
95
liftType :: List Repr tps -> List Repr idx -> List Repr (Lifted tps idx) liftType Nil idx = Nil
95
liftType Nil idx = Nil
22
false
true
0
10
19
52
23
29
null
null
GregorySchwartz/aa-mapper
src/Main.hs
gpl-2.0
opts = info (helper <*> options) ( fullDesc <> progDesc "Return various information about the relationship between\ \ the germline and the clones, most importantly the amino\ \ acid maps (nucleotide sequences only)" <> header "aa-mapper, Gregory W. Schwartz" )
310
opts = info (helper <*> options) ( fullDesc <> progDesc "Return various information about the relationship between\ \ the germline and the clones, most importantly the amino\ \ acid maps (nucleotide sequences only)" <> header "aa-mapper, Gregory W. Schwartz" )
310
opts = info (helper <*> options) ( fullDesc <> progDesc "Return various information about the relationship between\ \ the germline and the clones, most importantly the amino\ \ acid maps (nucleotide sequences only)" <> header "aa-mapper, Gregory W. Schwartz" )
310
false
false
0
9
89
35
17
18
null
null
simonmichael/hledger
hledger-lib/Hledger/Query.hs
gpl-3.0
queryDateSpan' _ = nulldatespan
42
queryDateSpan' _ = nulldatespan
42
queryDateSpan' _ = nulldatespan
42
false
false
0
4
14
10
4
6
null
null
jameshales/voltorb-flip
src/BoardParser.hs
bsd-3-clause
pTile :: Stream s m Char => ParsecT s u m Tile pTile = fmap (tile . digitToInt) $ oneOf "0123"
94
pTile :: Stream s m Char => ParsecT s u m Tile pTile = fmap (tile . digitToInt) $ oneOf "0123"
94
pTile = fmap (tile . digitToInt) $ oneOf "0123"
47
false
true
0
8
20
48
23
25
null
null
vaibhavsagar/duffer.hs
duffer-json/test/Spec.hs
bsd-3-clause
roundTrip :: forall a b. (Coercible a b, FromJSON a, ToJSON a) => a -> b roundTrip = coerce @a . fromJust . decode . encode
123
roundTrip :: forall a b. (Coercible a b, FromJSON a, ToJSON a) => a -> b roundTrip = coerce @a . fromJust . decode . encode
123
roundTrip = coerce @a . fromJust . decode . encode
50
false
true
2
9
25
69
33
36
null
null
erantapaa/hprimecount
app/Main.hs
bsd-2-clause
e501a2 n = length [ p | p <- takeWhile (\p -> p^7 <= n) primes ]
64
e501a2 n = length [ p | p <- takeWhile (\p -> p^7 <= n) primes ]
64
e501a2 n = length [ p | p <- takeWhile (\p -> p^7 <= n) primes ]
64
false
false
1
13
16
48
22
26
null
null
jml/haverer-api
test/Handler/Utilities.hs
apache-2.0
-- | Get the URL relative to the test yesod testUrl :: Text -> YesodExample App ByteString testUrl path = do rootUrl <- testRoot return $ encodeUtf8 $ (rootUrl ++ path) -- Force failure by swearing that black is white, and pigs can fly...
244
testUrl :: Text -> YesodExample App ByteString testUrl path = do rootUrl <- testRoot return $ encodeUtf8 $ (rootUrl ++ path) -- Force failure by swearing that black is white, and pigs can fly...
200
testUrl path = do rootUrl <- testRoot return $ encodeUtf8 $ (rootUrl ++ path) -- Force failure by swearing that black is white, and pigs can fly...
153
true
true
0
9
49
50
25
25
null
null
frantisekfarka/ghc-dsi
libraries/base/Control/Concurrent.hs
bsd-3-clause
withThread :: IO a -> IO a withThread io = do m <- newEmptyMVar _ <- mask_ $ forkIO $ try io >>= putMVar m x <- takeMVar m case x of Right a -> return a Left e -> throwIO (e :: IOException)
206
withThread :: IO a -> IO a withThread io = do m <- newEmptyMVar _ <- mask_ $ forkIO $ try io >>= putMVar m x <- takeMVar m case x of Right a -> return a Left e -> throwIO (e :: IOException)
206
withThread io = do m <- newEmptyMVar _ <- mask_ $ forkIO $ try io >>= putMVar m x <- takeMVar m case x of Right a -> return a Left e -> throwIO (e :: IOException)
179
false
true
0
12
60
108
47
61
null
null
Lythimus/lptv
sites/all/modules/jgm-pandoc-8be6cc2/src/Text/Pandoc/Readers/RST.hs
gpl-2.0
symbol :: GenParser Char ParserState Inline symbol = do result <- oneOf specialChars return $ Str [result] -- parses inline code, between codeStart and codeEnd
165
symbol :: GenParser Char ParserState Inline symbol = do result <- oneOf specialChars return $ Str [result] -- parses inline code, between codeStart and codeEnd
165
symbol = do result <- oneOf specialChars return $ Str [result] -- parses inline code, between codeStart and codeEnd
121
false
true
0
9
30
42
20
22
null
null
EPashkin/gamenumber-gloss
src/View/State.hs
gpl-3.0
doChangePaused :: ViewAction doChangePaused = game . paused %~ not
66
doChangePaused :: ViewAction doChangePaused = game . paused %~ not
66
doChangePaused = game . paused %~ not
37
false
true
0
6
9
19
10
9
null
null
mdsteele/fallback
src/Fallback/Test/FOV.hs
gpl-3.0
losTest :: String -> Test losTest expectedString = let (width, height, arr, isBlocked, expected) = buildArray expectedString eye = uncurry Point $ fromJust $ find (('*' ==) . (arr !)) $ range $ bounds arr visible = Set.fromList $ filter (lineOfSight isBlocked eye) $ map (uncurr...
601
losTest :: String -> Test losTest expectedString = let (width, height, arr, isBlocked, expected) = buildArray expectedString eye = uncurry Point $ fromJust $ find (('*' ==) . (arr !)) $ range $ bounds arr visible = Set.fromList $ filter (lineOfSight isBlocked eye) $ map (uncurr...
601
losTest expectedString = let (width, height, arr, isBlocked, expected) = buildArray expectedString eye = uncurry Point $ fromJust $ find (('*' ==) . (arr !)) $ range $ bounds arr visible = Set.fromList $ filter (lineOfSight isBlocked eye) $ map (uncurry Point) $ range $ bounds ...
575
false
true
2
15
167
209
104
105
null
null
mikeizbicki/Classification
src/Plots.hs
bsd-3-clause
csv2boostErr :: (Num t) => String -> [[String]] -> [(String, t, [Double])] csv2boostErr title xs = trace title $ [ ("", 1, matmap (quantile 0.75) $ doubledata xs) , (title', 2, matmap mean $ doubledata xs) , ("", 1, matmap (quantile 0.25) $ doubledata xs) ] where title' = ...
450
csv2boostErr :: (Num t) => String -> [[String]] -> [(String, t, [Double])] csv2boostErr title xs = trace title $ [ ("", 1, matmap (quantile 0.75) $ doubledata xs) , (title', 2, matmap mean $ doubledata xs) , ("", 1, matmap (quantile 0.25) $ doubledata xs) ] where title' = ...
450
csv2boostErr title xs = trace title $ [ ("", 1, matmap (quantile 0.75) $ doubledata xs) , (title', 2, matmap mean $ doubledata xs) , ("", 1, matmap (quantile 0.25) $ doubledata xs) ] where title' = swapL '\\' ' ' $ last $ words $ ...
375
false
true
0
11
176
180
95
85
null
null
VictorDenisov/keystone
src/Nova.hs
gpl-2.0
computeServer :: Chan NC.Message -> NC.AgentList -> IO () computeServer messageChannel agentList = withSocketsDo $ do addrinfos <- getAddrInfo (Just (defaultHints {addrFlags = [AI_PASSIVE]})) Nothing (Just "13000") let serveraddr = head addrinfos sock <- socket (addrF...
1,229
computeServer :: Chan NC.Message -> NC.AgentList -> IO () computeServer messageChannel agentList = withSocketsDo $ do addrinfos <- getAddrInfo (Just (defaultHints {addrFlags = [AI_PASSIVE]})) Nothing (Just "13000") let serveraddr = head addrinfos sock <- socket (addrF...
1,229
computeServer messageChannel agentList = withSocketsDo $ do addrinfos <- getAddrInfo (Just (defaultHints {addrFlags = [AI_PASSIVE]})) Nothing (Just "13000") let serveraddr = head addrinfos sock <- socket (addrFamily serveraddr) Stream defaultProtocol bindSocket soc...
1,171
false
true
0
24
367
376
176
200
null
null
urbanslug/ghc
testsuite/tests/deSugar/should_compile/ds044.hs
bsd-3-clause
isF _ = False
15
isF _ = False
15
isF _ = False
15
false
false
0
4
5
10
4
6
null
null
pparkkin/eta
compiler/ETA/BasicTypes/Name.hs
bsd-3-clause
isExternalName (Name {n_sort = External _}) = True
53
isExternalName (Name {n_sort = External _}) = True
53
isExternalName (Name {n_sort = External _}) = True
53
false
false
0
10
10
24
12
12
null
null
TomMD/ghc
compiler/simplCore/CoreMonad.hs
bsd-3-clause
thNameToGhcName :: TH.Name -> CoreM (Maybe Name) thNameToGhcName th_name = do hsc_env <- getHscEnv liftIO $ initTcForLookup hsc_env (lookupThName_maybe th_name) #endif
175
thNameToGhcName :: TH.Name -> CoreM (Maybe Name) thNameToGhcName th_name = do hsc_env <- getHscEnv liftIO $ initTcForLookup hsc_env (lookupThName_maybe th_name) #endif
175
thNameToGhcName th_name = do hsc_env <- getHscEnv liftIO $ initTcForLookup hsc_env (lookupThName_maybe th_name) #endif
126
false
true
0
11
28
60
27
33
null
null
fmthoma/ghc
compiler/coreSyn/MkCore.hs
bsd-3-clause
nonExhaustiveGuardsErrorName = err_nm "nonExhaustiveGuardsError" nonExhaustiveGuardsErrorIdKey nON_EXHAUSTIVE_GUARDS_ERROR_ID
159
nonExhaustiveGuardsErrorName = err_nm "nonExhaustiveGuardsError" nonExhaustiveGuardsErrorIdKey nON_EXHAUSTIVE_GUARDS_ERROR_ID
159
nonExhaustiveGuardsErrorName = err_nm "nonExhaustiveGuardsError" nonExhaustiveGuardsErrorIdKey nON_EXHAUSTIVE_GUARDS_ERROR_ID
159
false
false
1
5
39
18
6
12
null
null
dimara/ganeti
src/Ganeti/Metad/WebServer.hs
bsd-2-clause
handleMetadata _ _ "ganeti" "latest" "write" = error405 [POST]
64
handleMetadata _ _ "ganeti" "latest" "write" = error405 [POST]
64
handleMetadata _ _ "ganeti" "latest" "write" = error405 [POST]
64
false
false
0
6
10
23
11
12
null
null
changlinli/nikki
src/Utils.hs
lgpl-3.0
completeEdges [] = []
21
completeEdges [] = []
21
completeEdges [] = []
21
false
false
1
6
3
17
6
11
null
null
michaelficarra/purescript
src/Language/PureScript/Docs/RenderedCode/Render.hs
mit
matchTypeAtom :: Pattern () Type RenderedCode matchTypeAtom = typeLiterals <+> fmap parens matchType where parens x = syntax "(" <> x <> syntax ")"
151
matchTypeAtom :: Pattern () Type RenderedCode matchTypeAtom = typeLiterals <+> fmap parens matchType where parens x = syntax "(" <> x <> syntax ")"
151
matchTypeAtom = typeLiterals <+> fmap parens matchType where parens x = syntax "(" <> x <> syntax ")"
105
false
true
0
7
27
54
25
29
null
null
keqh/Monadius_rewrite
Monadius/Render/VicViper.hs
gpl-2.0
render (x,y) hp age | hp <= 0 = renderBang | otherwise = renderBody where renderBang = preservingMatrix $ do translate2D x y scale pishaMagnitudeX pishaMagnitudeY 0 renderWithShade (Color3 1.0 0 0) (Color3 1.0 0.6 0.4) $ do renderPrimitive LineLoop $ ugo...
1,774
render (x,y) hp age | hp <= 0 = renderBang | otherwise = renderBody where renderBang = preservingMatrix $ do translate2D x y scale pishaMagnitudeX pishaMagnitudeY 0 renderWithShade (Color3 1.0 0 0) (Color3 1.0 0.6 0.4) $ do renderPrimitive LineLoop $ ugo...
1,774
render (x,y) hp age | hp <= 0 = renderBang | otherwise = renderBody where renderBang = preservingMatrix $ do translate2D x y scale pishaMagnitudeX pishaMagnitudeY 0 renderWithShade (Color3 1.0 0 0) (Color3 1.0 0.6 0.4) $ do renderPrimitive LineLoop $ ugo...
1,774
false
false
1
18
444
1,170
672
498
null
null
sleexyz/haskell-fun
FunctorCategories.hs
bsd-3-clause
proofIdentityF :: forall a. a -> a proofIdentityF = mapWith identityFunctor (id :: a -> a) where identityFunctor :: Functor (Wrap (->) a a) (Wrap (->) a a) identityFunctor = id -- | Proof that identity is idempotent
226
proofIdentityF :: forall a. a -> a proofIdentityF = mapWith identityFunctor (id :: a -> a) where identityFunctor :: Functor (Wrap (->) a a) (Wrap (->) a a) identityFunctor = id -- | Proof that identity is idempotent
226
proofIdentityF = mapWith identityFunctor (id :: a -> a) where identityFunctor :: Functor (Wrap (->) a a) (Wrap (->) a a) identityFunctor = id -- | Proof that identity is idempotent
191
false
true
0
9
48
93
45
48
null
null
rodrigo-machado/verigraph
src/library/Base/Valid.hs
gpl-3.0
errorMessages :: ValidationResult -> Maybe String errorMessages IsValid = Nothing
90
errorMessages :: ValidationResult -> Maybe String errorMessages IsValid = Nothing
90
errorMessages IsValid = Nothing
40
false
true
0
6
18
21
10
11
null
null
fnordomat/misc
haskell/editdistviz/EditDistViz.hs
gpl-3.0
yello = rgb 1 1 0
17
yello = rgb 1 1 0
17
yello = rgb 1 1 0
17
false
false
1
5
5
19
6
13
null
null
ladinu/macros
recipes.hs
mit
chickenEnchiladaCasserole = Meal "Chicken Enchilada Rice Casserole" 6 [ (Ingredient "White Rice (Raw)" 2.4 295.8 26.4 (Unit 2 "Cup")), (Ingredient "Chicken Breast (Raw)" 11.2 0 209.5 (Unit 2 "lb")) ./ 2, (Ingredient "Enchilada Sauce" 0 4 0 (Unit 0.25 "Cup")) .* 13, (Ingredient "Refried Beans" 0 16 6...
578
chickenEnchiladaCasserole = Meal "Chicken Enchilada Rice Casserole" 6 [ (Ingredient "White Rice (Raw)" 2.4 295.8 26.4 (Unit 2 "Cup")), (Ingredient "Chicken Breast (Raw)" 11.2 0 209.5 (Unit 2 "lb")) ./ 2, (Ingredient "Enchilada Sauce" 0 4 0 (Unit 0.25 "Cup")) .* 13, (Ingredient "Refried Beans" 0 16 6...
578
chickenEnchiladaCasserole = Meal "Chicken Enchilada Rice Casserole" 6 [ (Ingredient "White Rice (Raw)" 2.4 295.8 26.4 (Unit 2 "Cup")), (Ingredient "Chicken Breast (Raw)" 11.2 0 209.5 (Unit 2 "lb")) ./ 2, (Ingredient "Enchilada Sauce" 0 4 0 (Unit 0.25 "Cup")) .* 13, (Ingredient "Refried Beans" 0 16 6...
578
false
false
0
10
130
234
120
114
null
null
nevrenato/HetsAlloy
Syntax/AS_Library.der.hs
gpl-2.0
getImportNames :: DownloadItems -> [IRI] getImportNames di = case di of ItemMaps im -> map (\ (ItemNameMap i mi) -> fromMaybe i mi) im UniqueItem i -> [i]
158
getImportNames :: DownloadItems -> [IRI] getImportNames di = case di of ItemMaps im -> map (\ (ItemNameMap i mi) -> fromMaybe i mi) im UniqueItem i -> [i]
158
getImportNames di = case di of ItemMaps im -> map (\ (ItemNameMap i mi) -> fromMaybe i mi) im UniqueItem i -> [i]
117
false
true
4
11
31
72
36
36
null
null
siegfriedweber/hgit
src/Git/Repository.hs
bsd-3-clause
getRepository :: MonadRepository (Ptr Repository) getRepository = MonadRepository ask
85
getRepository :: MonadRepository (Ptr Repository) getRepository = MonadRepository ask
85
getRepository = MonadRepository ask
35
false
true
0
7
8
23
11
12
null
null
oldmanmike/ghc
compiler/cmm/CmmLint.hs
bsd-3-clause
lintCmmGraph :: DynFlags -> CmmGraph -> CmmLint () lintCmmGraph dflags g = cmmLocalLiveness dflags g `seq` mapM_ (lintCmmBlock labels) blocks -- cmmLiveness throws an error if there are registers -- live on entry to the graph (i.e. undefined -- variables) where blocks = toBlockList g lab...
361
lintCmmGraph :: DynFlags -> CmmGraph -> CmmLint () lintCmmGraph dflags g = cmmLocalLiveness dflags g `seq` mapM_ (lintCmmBlock labels) blocks -- cmmLiveness throws an error if there are registers -- live on entry to the graph (i.e. undefined -- variables) where blocks = toBlockList g lab...
361
lintCmmGraph dflags g = cmmLocalLiveness dflags g `seq` mapM_ (lintCmmBlock labels) blocks -- cmmLiveness throws an error if there are registers -- live on entry to the graph (i.e. undefined -- variables) where blocks = toBlockList g labels = setFromList (map entryLabel blocks)
310
false
true
2
9
82
96
43
53
null
null
Tener/personal-library-yesod
Handler/Review.hs
bsd-2-clause
postReviewNewR :: AssetId -> Handler RepHtml postReviewNewR aid = do _asset :: Asset <- runDB $ get404 aid uid <- fmap entityKey requireAuth ((result, _), _) <- runFormPost (renderDivs $ reviewForm uid aid) case result of FormSuccess review -> do _revId <- runDB $ insert review ...
397
postReviewNewR :: AssetId -> Handler RepHtml postReviewNewR aid = do _asset :: Asset <- runDB $ get404 aid uid <- fmap entityKey requireAuth ((result, _), _) <- runFormPost (renderDivs $ reviewForm uid aid) case result of FormSuccess review -> do _revId <- runDB $ insert review ...
397
postReviewNewR aid = do _asset :: Asset <- runDB $ get404 aid uid <- fmap entityKey requireAuth ((result, _), _) <- runFormPost (renderDivs $ reviewForm uid aid) case result of FormSuccess review -> do _revId <- runDB $ insert review return () _ -> retur...
352
false
true
0
14
122
146
67
79
null
null
rahulmutt/ghcvm
compiler/Eta/BasicTypes/Literal.hs
bsd-3-clause
-- | Creates a 'Literal' of type @Double#@ mkMachDouble :: Rational -> Literal mkMachDouble = MachDouble
104
mkMachDouble :: Rational -> Literal mkMachDouble = MachDouble
61
mkMachDouble = MachDouble
25
true
true
0
5
15
16
9
7
null
null
statusfailed/machines-io
Main.hs
mit
printer :: (Show a, MonadIO m) => ProcessT m a () printer = repeatedly (await >>= liftIO . print)
97
printer :: (Show a, MonadIO m) => ProcessT m a () printer = repeatedly (await >>= liftIO . print)
97
printer = repeatedly (await >>= liftIO . print)
47
false
true
0
8
18
55
26
29
null
null
ezyang/hoopl
src/Compiler/Hoopl/Shape.hs
bsd-3-clause
entryHalfShape ShapeOC = ShapeO
31
entryHalfShape ShapeOC = ShapeO
31
entryHalfShape ShapeOC = ShapeO
31
false
false
0
5
3
9
4
5
null
null
Chiel92/ants
simulation/Simulator.hs
gpl-2.0
sensedCell p d RightAhead = adjacentCell p (turn IsRight d)
59
sensedCell p d RightAhead = adjacentCell p (turn IsRight d)
59
sensedCell p d RightAhead = adjacentCell p (turn IsRight d)
59
false
false
0
7
9
26
12
14
null
null
Potregon/while
src/Parser/While.hs
gpl-3.0
state states@(82:_) stack input = case headMay input of Just ( PosToken _ (Id _) ) -> shift 1 states stack input Just ( PosToken _ NameSpace) -> shift 2 states stack input Just ( PosToken _ Read ) -> shift 3 states stack input Just ( PosToken _ Output ) -> shift 4 states stack input Just ( PosToken _ Retur...
1,469
state states@(82:_) stack input = case headMay input of Just ( PosToken _ (Id _) ) -> shift 1 states stack input Just ( PosToken _ NameSpace) -> shift 2 states stack input Just ( PosToken _ Read ) -> shift 3 states stack input Just ( PosToken _ Output ) -> shift 4 states stack input Just ( PosToken _ Retur...
1,469
state states@(82:_) stack input = case headMay input of Just ( PosToken _ (Id _) ) -> shift 1 states stack input Just ( PosToken _ NameSpace) -> shift 2 states stack input Just ( PosToken _ Read ) -> shift 3 states stack input Just ( PosToken _ Output ) -> shift 4 states stack input Just ( PosToken _ Retur...
1,469
false
false
1
13
353
604
283
321
null
null
kim/amazonka
amazonka-autoscaling/gen/Network/AWS/AutoScaling/Types.hs
mpl-2.0
-- | 'InstanceMonitoring' constructor. -- -- The fields accessible through corresponding lenses are: -- -- * 'imEnabled' @::@ 'Maybe' 'Bool' -- instanceMonitoring :: InstanceMonitoring instanceMonitoring = InstanceMonitoring { _imEnabled = Nothing }
257
instanceMonitoring :: InstanceMonitoring instanceMonitoring = InstanceMonitoring { _imEnabled = Nothing }
113
instanceMonitoring = InstanceMonitoring { _imEnabled = Nothing }
72
true
true
0
6
39
25
17
8
null
null
crockeo/jalapeno
src/lib/FRP/Jalapeno/Behavior.hs
mit
integralFrom lv lt (BehaviorP a) = BehaviorP $ \t i -> integralTupleFn lv lt t $ a t i
88
integralFrom lv lt (BehaviorP a) = BehaviorP $ \t i -> integralTupleFn lv lt t $ a t i
88
integralFrom lv lt (BehaviorP a) = BehaviorP $ \t i -> integralTupleFn lv lt t $ a t i
88
false
false
0
8
20
49
22
27
null
null
kim/amazonka
amazonka-ec2/gen/Network/AWS/EC2/GetConsoleOutput.hs
mpl-2.0
-- | 'GetConsoleOutputResponse' constructor. -- -- The fields accessible through corresponding lenses are: -- -- * 'gcorInstanceId' @::@ 'Maybe' 'Text' -- -- * 'gcorOutput' @::@ 'Maybe' 'Text' -- -- * 'gcorTimestamp' @::@ 'Maybe' 'UTCTime' -- getConsoleOutputResponse :: GetConsoleOutputResponse getConsoleOutputResponse...
449
getConsoleOutputResponse :: GetConsoleOutputResponse getConsoleOutputResponse = GetConsoleOutputResponse { _gcorInstanceId = Nothing , _gcorTimestamp = Nothing , _gcorOutput = Nothing }
206
getConsoleOutputResponse = GetConsoleOutputResponse { _gcorInstanceId = Nothing , _gcorTimestamp = Nothing , _gcorOutput = Nothing }
153
true
true
0
7
74
45
30
15
null
null
larrytheliquid/Lemmachine
vendor/stdlib/GenerateEverything.hs
mit
fileToMod :: FilePath -> String fileToMod = map slashToDot . dropExtension . makeRelative srcDir where slashToDot c | isPathSeparator c = '.' | otherwise = c
184
fileToMod :: FilePath -> String fileToMod = map slashToDot . dropExtension . makeRelative srcDir where slashToDot c | isPathSeparator c = '.' | otherwise = c
184
fileToMod = map slashToDot . dropExtension . makeRelative srcDir where slashToDot c | isPathSeparator c = '.' | otherwise = c
152
false
true
0
8
52
58
26
32
null
null
nico202/NeMosim
src/api/autogen/Cpp.hs
gpl-2.0
scalarOutput = scalarVal
24
scalarOutput = scalarVal
24
scalarOutput = scalarVal
24
false
false
0
4
2
6
3
3
null
null
docmunch/antemodulum
src/Antemodulum/FilePath.hs
mit
copyFile :: MonadIO m => FilePath -> FilePath -> m () copyFile = liftIO2 Import.copyFile
88
copyFile :: MonadIO m => FilePath -> FilePath -> m () copyFile = liftIO2 Import.copyFile
88
copyFile = liftIO2 Import.copyFile
34
false
true
0
9
14
36
17
19
null
null
nicoan/miniLogo
src/Evaluation.hs
gpl-3.0
evalStatementList (c:cs) localEnv = do evalStatement c localEnv evalStatementList cs localEnv {- La razon por la que evalStatementList devuelve el entorno local es por situaciones como esta: to test localmake "i 0 while (:i < 10) [ fd :i ...
857
evalStatementList (c:cs) localEnv = do evalStatement c localEnv evalStatementList cs localEnv {- La razon por la que evalStatementList devuelve el entorno local es por situaciones como esta: to test localmake "i 0 while (:i < 10) [ fd :i ...
857
evalStatementList (c:cs) localEnv = do evalStatement c localEnv evalStatementList cs localEnv {- La razon por la que evalStatementList devuelve el entorno local es por situaciones como esta: to test localmake "i 0 while (:i < 10) [ fd :i ...
857
false
false
1
8
248
38
18
20
null
null
sgillespie/lambda-calculus
app/Main.hs
mit
version' :: String version' = showVersion P.version
51
version' :: String version' = showVersion P.version
51
version' = showVersion P.version
32
false
true
0
6
6
23
9
14
null
null
vladfi1/game-ai
lib/TwoPlayer.hs
mit
allPlayers :: [Player] allPlayers = allValues
45
allPlayers :: [Player] allPlayers = allValues
45
allPlayers = allValues
22
false
true
0
7
5
21
9
12
null
null
mathhun/stack
src/Stack/Options.hs
bsd-3-clause
-- | Parser for build arguments. buildOptsParser :: Command -> Parser BuildOpts buildOptsParser cmd = fmap addCoverageFlags $ BuildOpts <$> target <*> libProfiling <*> exeProfiling <*> haddock <*> haddockDeps <*> dryRun <*> ghcOpts <*> flags <*> copyBins <...
4,736
buildOptsParser :: Command -> Parser BuildOpts buildOptsParser cmd = fmap addCoverageFlags $ BuildOpts <$> target <*> libProfiling <*> exeProfiling <*> haddock <*> haddockDeps <*> dryRun <*> ghcOpts <*> flags <*> copyBins <*> preFetch <*> buildSubset <*> ...
4,703
buildOptsParser cmd = fmap addCoverageFlags $ BuildOpts <$> target <*> libProfiling <*> exeProfiling <*> haddock <*> haddockDeps <*> dryRun <*> ghcOpts <*> flags <*> copyBins <*> preFetch <*> buildSubset <*> fileWatch' <*> keepGoing <*> forceDirty <*> tests <*...
4,640
true
true
19
28
1,877
703
344
359
null
null
ulyssesp/oscillare
src/Visuals.hs
gpl-3.0
highv = analyze 6 $ highPass ain
32
highv = analyze 6 $ highPass ain
32
highv = analyze 6 $ highPass ain
32
false
false
0
6
6
16
7
9
null
null
siddharthist/m3u-convert
test/Main.hs
mit
-- data M3U = M3U { entries ∷ [M3UEntry] } deriving (Eq) testM3U :: M3U testM3U = M3U { entries = [ M3UEntry { info = Nothing , path = "testpath1" } , M3UEntry { info = Just testEXTINF ...
576
testM3U :: M3U testM3U = M3U { entries = [ M3UEntry { info = Nothing , path = "testpath1" } , M3UEntry { info = Just testEXTINF , path = "testpath2" ...
519
testM3U = M3U { entries = [ M3UEntry { info = Nothing , path = "testpath1" } , M3UEntry { info = Just testEXTINF , path = "testpath2" } ...
504
true
true
0
11
370
84
48
36
null
null
sgillespie/ghc
compiler/codeGen/StgCmmMonad.hs
bsd-3-clause
emitProcWithConvention :: Convention -> Maybe CmmInfoTable -> CLabel -> [CmmFormal] -> CmmAGraphScoped -> FCode () emitProcWithConvention conv mb_info lbl args blocks = emitProcWithStackFrame conv mb_info lbl [] args blocks True
299
emitProcWithConvention :: Convention -> Maybe CmmInfoTable -> CLabel -> [CmmFormal] -> CmmAGraphScoped -> FCode () emitProcWithConvention conv mb_info lbl args blocks = emitProcWithStackFrame conv mb_info lbl [] args blocks True
299
emitProcWithConvention conv mb_info lbl args blocks = emitProcWithStackFrame conv mb_info lbl [] args blocks True
115
false
true
0
12
100
75
35
40
null
null
karamellpelle/MEnv
source/GUI/Widget/LayoutWidget/StaticLayout.hs
bsd-2-clause
xgatherShape :: GUIData -> XGatherLayout a -> GUIShape xgatherShape gd xgather = foldl helper (GUIShape 0.0 (xgatherMinHth xgather)) $ xgatherChildLayouts xgather where helper (GUIShape wth hth) child = case slayoutShape gd child of GUIShape wth' hth' -> GUIShape (wth + wth') (ma...
331
xgatherShape :: GUIData -> XGatherLayout a -> GUIShape xgatherShape gd xgather = foldl helper (GUIShape 0.0 (xgatherMinHth xgather)) $ xgatherChildLayouts xgather where helper (GUIShape wth hth) child = case slayoutShape gd child of GUIShape wth' hth' -> GUIShape (wth + wth') (ma...
331
xgatherShape gd xgather = foldl helper (GUIShape 0.0 (xgatherMinHth xgather)) $ xgatherChildLayouts xgather where helper (GUIShape wth hth) child = case slayoutShape gd child of GUIShape wth' hth' -> GUIShape (wth + wth') (max hth hth')
276
false
true
0
12
83
113
54
59
null
null
frantisekfarka/ghc-dsi
libraries/base/Control/Concurrent.hs
bsd-3-clause
-- | Returns an STM action that can be used to wait until data -- can be written to a file descriptor. The second returned value -- is an IO action that can be used to deregister interest -- in the file descriptor. -- -- /Since: 4.7.0.0/ threadWaitWriteSTM :: Fd -> IO (STM (), IO ()) threadWaitWriteSTM fd #ifdef mingw3...
1,028
threadWaitWriteSTM :: Fd -> IO (STM (), IO ()) threadWaitWriteSTM fd #ifdef mingw32_HOST_OS | threaded = do v <- newTVarIO Nothing mask_ $ void $ forkIO $ do result <- try (waitFd fd 1) atomically (writeTVar v $ Just result) let waitActi...
790
threadWaitWriteSTM fd #ifdef mingw32_HOST_OS | threaded = do v <- newTVarIO Nothing mask_ $ void $ forkIO $ do result <- try (waitFd fd 1) atomically (writeTVar v $ Just result) let waitAction = do result <- readTVar v ...
743
true
true
0
20
420
236
109
127
null
null
castaway/pandoc
src/Text/Pandoc/Readers/Markdown.hs
gpl-2.0
-- definition lists defListMarker :: GenParser Char ParserState () defListMarker = do sps <- nonindentSpaces char ':' <|> char '~' st <- getState let tabStop = stateTabStop st let remaining = tabStop - (length sps + 1) if remaining > 0 then count remaining (char ' ') <|> string "\t" else pzero ...
329
defListMarker :: GenParser Char ParserState () defListMarker = do sps <- nonindentSpaces char ':' <|> char '~' st <- getState let tabStop = stateTabStop st let remaining = tabStop - (length sps + 1) if remaining > 0 then count remaining (char ' ') <|> string "\t" else pzero return ()
308
defListMarker = do sps <- nonindentSpaces char ':' <|> char '~' st <- getState let tabStop = stateTabStop st let remaining = tabStop - (length sps + 1) if remaining > 0 then count remaining (char ' ') <|> string "\t" else pzero return ()
261
true
true
6
8
78
119
59
60
null
null
mapinguari/SC_HS_Proxy
src/Proxy/Query/Unit.hs
mit
isBuilding ZergUltralisk = False
32
isBuilding ZergUltralisk = False
32
isBuilding ZergUltralisk = False
32
false
false
0
5
3
9
4
5
null
null
pparkkin/eta
compiler/ETA/HsSyn/HsDecls.hs
bsd-3-clause
appendGroups :: HsGroup a -> HsGroup a -> HsGroup a appendGroups HsGroup { hs_valds = val_groups1, hs_splcds = spliceds1, hs_tyclds = tyclds1, hs_instds = instds1, hs_derivds = derivds1, hs_fixds = fixds1, hs_defds = defds1, hs_annds = annds1, ...
1,394
appendGroups :: HsGroup a -> HsGroup a -> HsGroup a appendGroups HsGroup { hs_valds = val_groups1, hs_splcds = spliceds1, hs_tyclds = tyclds1, hs_instds = instds1, hs_derivds = derivds1, hs_fixds = fixds1, hs_defds = defds1, hs_annds = annds1, ...
1,394
appendGroups HsGroup { hs_valds = val_groups1, hs_splcds = spliceds1, hs_tyclds = tyclds1, hs_instds = instds1, hs_derivds = derivds1, hs_fixds = fixds1, hs_defds = defds1, hs_annds = annds1, hs_fords = fords1, hs_warnds = warnds1,...
1,342
false
true
0
8
507
329
202
127
null
null
Heather/Idris-dev
src/Idris/Elab/AsPat.hs
bsd-3-clause
-- | Desugar by changing x@y on lhs to let x = y in ... or rhs desugarAs :: PTerm -> PTerm -> (PTerm, PTerm) desugarAs lhs rhs = let (lhs', pats) = runState (collectAs (replaceUnderscore lhs)) [] in (lhs', bindPats pats rhs) where bindPats :: [(Name, FC, PTerm)] -> PTerm -> PTerm bindPats [] rhs...
419
desugarAs :: PTerm -> PTerm -> (PTerm, PTerm) desugarAs lhs rhs = let (lhs', pats) = runState (collectAs (replaceUnderscore lhs)) [] in (lhs', bindPats pats rhs) where bindPats :: [(Name, FC, PTerm)] -> PTerm -> PTerm bindPats [] rhs = rhs bindPats ((n, fc, tm) : ps) rhs = PLet fc n N...
356
desugarAs lhs rhs = let (lhs', pats) = runState (collectAs (replaceUnderscore lhs)) [] in (lhs', bindPats pats rhs) where bindPats :: [(Name, FC, PTerm)] -> PTerm -> PTerm bindPats [] rhs = rhs bindPats ((n, fc, tm) : ps) rhs = PLet fc n NoFC Placeholder tm (bindPats ps rhs)
310
true
true
0
13
109
166
88
78
null
null
brownsys/nettle-openflow
src/Nettle/OpenFlow/MessagesBinary.hs
bsd-3-clause
lenQueueConfig (QueueConfig _ props) = 8 + sum (map lenQueueProp props)
71
lenQueueConfig (QueueConfig _ props) = 8 + sum (map lenQueueProp props)
71
lenQueueConfig (QueueConfig _ props) = 8 + sum (map lenQueueProp props)
71
false
false
0
8
10
33
15
18
null
null
GaloisInc/halvm-ghc
compiler/utils/Outputable.hs
bsd-3-clause
ppWhen False _ = empty
24
ppWhen False _ = empty
24
ppWhen False _ = empty
24
false
false
0
5
6
13
5
8
null
null
Tener/deeplearning-thesis
lib/Agent.hs
bsd-3-clause
evalBoardB :: Color -> BBoard -> Int evalBoardB Black (BBoard brd) = evalBoardI Black brd
89
evalBoardB :: Color -> BBoard -> Int evalBoardB Black (BBoard brd) = evalBoardI Black brd
89
evalBoardB Black (BBoard brd) = evalBoardI Black brd
52
false
true
0
10
14
40
18
22
null
null
brendanhay/gogol
gogol-dfareporting/gen/Network/Google/DFAReporting/Types/Product.hs
mpl-2.0
-- | Popup dimension for a creative. This is a read-only field. Applicable to -- the following creative types: all RICH_MEDIA and all VPAID pwpDimension :: Lens' PopupWindowProperties (Maybe Size) pwpDimension = lens _pwpDimension (\ s a -> s{_pwpDimension = a})
264
pwpDimension :: Lens' PopupWindowProperties (Maybe Size) pwpDimension = lens _pwpDimension (\ s a -> s{_pwpDimension = a})
124
pwpDimension = lens _pwpDimension (\ s a -> s{_pwpDimension = a})
67
true
true
1
9
42
53
26
27
null
null
nikita-volkov/hasql-th
library/Hasql/TH/Extraction/ChildExprList.hs
mit
genericType (GenericType a b c) = typeFunctionName a <> foldMap attrs b <> foldMap typeModifiers c
98
genericType (GenericType a b c) = typeFunctionName a <> foldMap attrs b <> foldMap typeModifiers c
98
genericType (GenericType a b c) = typeFunctionName a <> foldMap attrs b <> foldMap typeModifiers c
98
false
false
0
7
15
41
18
23
null
null
ekmett/wxHaskell
wxcore/src/haskell/Graphics/UI/WXCore/WxcDefs.hs
lgpl-2.1
wxLANGUAGE_XHOSA :: Int wxLANGUAGE_XHOSA = 225
46
wxLANGUAGE_XHOSA :: Int wxLANGUAGE_XHOSA = 225
46
wxLANGUAGE_XHOSA = 225
22
false
true
0
6
5
18
7
11
null
null
jml/language-python
src/Language/Python/Common/LexerUtils.hs
bsd-3-clause
readFloat str = read (readFloatRest str)
40
readFloat str = read (readFloatRest str)
40
readFloat str = read (readFloatRest str)
40
false
false
0
7
5
18
8
10
null
null
Pitometsu/bake
src/General/BigString.hs
bsd-3-clause
limit = 5000
12
limit = 5000
12
limit = 5000
12
false
false
0
4
2
6
3
3
null
null
micknelso/language-c
src/Language/CFamily/C/TravMonad.hs
bsd-3-clause
checkCompatibleTypes :: Type -> Type -> Either TypeMismatch () checkCompatibleTypes _ _ = Right ()
98
checkCompatibleTypes :: Type -> Type -> Either TypeMismatch () checkCompatibleTypes _ _ = Right ()
98
checkCompatibleTypes _ _ = Right ()
35
false
true
0
8
14
36
17
19
null
null
uuhan/Idris-dev
src/Idris/Core/Elaborate.hs
bsd-3-clause
claimFn :: Name -> Name -> Raw -> Elab' aux () claimFn n bn t = processTactic' (ClaimFn n bn t)
95
claimFn :: Name -> Name -> Raw -> Elab' aux () claimFn n bn t = processTactic' (ClaimFn n bn t)
95
claimFn n bn t = processTactic' (ClaimFn n bn t)
48
false
true
0
10
20
54
25
29
null
null
balangs/eTeak
aschem/Render.hs
bsd-3-clause
showComp (Cell pos OrientW (Comp CompBuf inverts _)) = showBuf (schematicScale (moveE 2 pos)) pi >> showInverts bubble pos inverts bufOrientW noOffsets
159
showComp (Cell pos OrientW (Comp CompBuf inverts _)) = showBuf (schematicScale (moveE 2 pos)) pi >> showInverts bubble pos inverts bufOrientW noOffsets
159
showComp (Cell pos OrientW (Comp CompBuf inverts _)) = showBuf (schematicScale (moveE 2 pos)) pi >> showInverts bubble pos inverts bufOrientW noOffsets
159
false
false
0
10
29
65
30
35
null
null
wavewave/hxournal
lib/Application/HXournal/Type/PageArrangement.hs
bsd-2-clause
viewPortBBox :: PageArrangement a :-> ViewPortBBox viewPortBBox = lens getter setter where getter (SingleArrangement _ _ vbbox) = vbbox getter (ContinuousSingleArrangement _ _ _ vbbox) = vbbox setter vbbox (SingleArrangement cdim pdim _) = SingleArrangement cdim pdim vbbox setter vbbox (Continuo...
417
viewPortBBox :: PageArrangement a :-> ViewPortBBox viewPortBBox = lens getter setter where getter (SingleArrangement _ _ vbbox) = vbbox getter (ContinuousSingleArrangement _ _ _ vbbox) = vbbox setter vbbox (SingleArrangement cdim pdim _) = SingleArrangement cdim pdim vbbox setter vbbox (Continuou...
416
viewPortBBox = lens getter setter where getter (SingleArrangement _ _ vbbox) = vbbox getter (ContinuousSingleArrangement _ _ _ vbbox) = vbbox setter vbbox (SingleArrangement cdim pdim _) = SingleArrangement cdim pdim vbbox setter vbbox (ContinuousSingleArrangement cdim ddim pfunc _) = Cont...
365
false
true
1
6
81
132
59
73
null
null
phaazon/OpenGLRaw
RegistryProcessor/src/Main.hs
bsd-3-clause
printFeature :: API -> Version -> ProfileName -> Registry -> IO () printFeature api version profile registry = do let relName = capitalize (unProfileName profile) ++ show (major version) ++ show (minor version) printExtension Nothing [relName] $ fixedReplay api version profile registry
306
printFeature :: API -> Version -> ProfileName -> Registry -> IO () printFeature api version profile registry = do let relName = capitalize (unProfileName profile) ++ show (major version) ++ show (minor version) printExtension Nothing [relName] $ fixedReplay api version profile registry
306
printFeature api version profile registry = do let relName = capitalize (unProfileName profile) ++ show (major version) ++ show (minor version) printExtension Nothing [relName] $ fixedReplay api version profile registry
239
false
true
0
14
61
109
51
58
null
null
zhiyuanshi/fcore
frontend/typecheck/TypeCheck.hs
bsd-2-clause
checkConstruction :: ClassName -> [ClassName] -> Checker () checkConstruction c args = do conn <- getTypeServer unlessIO (JvmTypeQuery.definedConstructor conn c args) $ throwError (L NoLoc (NoSuchConstructor c args)) -- FIXME
243
checkConstruction :: ClassName -> [ClassName] -> Checker () checkConstruction c args = do conn <- getTypeServer unlessIO (JvmTypeQuery.definedConstructor conn c args) $ throwError (L NoLoc (NoSuchConstructor c args)) -- FIXME
243
checkConstruction c args = do conn <- getTypeServer unlessIO (JvmTypeQuery.definedConstructor conn c args) $ throwError (L NoLoc (NoSuchConstructor c args)) -- FIXME
183
false
true
0
12
47
81
39
42
null
null
danielbarter/xcomputer
src/Machine.hs
bsd-3-clause
pAC (x,y,flag,ac,count,pc,ir,addr,mem) = ac
46
pAC (x,y,flag,ac,count,pc,ir,addr,mem) = ac
46
pAC (x,y,flag,ac,count,pc,ir,addr,mem) = ac
46
false
false
0
5
6
37
22
15
null
null
allanderek/ipclib
Language/Hydra/Print.hs
gpl-2.0
printActions :: [ DNAMaction ] -> String printActions assignments = unlines [ "\\action{" , unlines $ map printDNAMaction assignments , "}" ]
178
printActions :: [ DNAMaction ] -> String printActions assignments = unlines [ "\\action{" , unlines $ map printDNAMaction assignments , "}" ]
178
printActions assignments = unlines [ "\\action{" , unlines $ map printDNAMaction assignments , "}" ]
137
false
true
0
8
58
42
22
20
null
null
sdiehl/ghc
compiler/utils/Pretty.hs
bsd-3-clause
mkUnion p q = p `union_` q
30
mkUnion p q = p `union_` q
30
mkUnion p q = p `union_` q
30
false
false
0
5
10
17
9
8
null
null
Jannis/haskell-dsp-experiments
compressor.hs
gpl-3.0
-- |Internal compression stage of a compressor, applied to individual samples. compressValue :: Compressor -> Double -> Double compressValue p x = if x > db2amplitude (threshold p) then (x - db2amplitude (threshold p)) / ratio p + db2amplitude (threshold p) else x
270
compressValue :: Compressor -> Double -> Double compressValue p x = if x > db2amplitude (threshold p) then (x - db2amplitude (threshold p)) / ratio p + db2amplitude (threshold p) else x
191
compressValue p x = if x > db2amplitude (threshold p) then (x - db2amplitude (threshold p)) / ratio p + db2amplitude (threshold p) else x
143
true
true
0
12
48
88
42
46
null
null
bos/wreq
tests/AWS/SQS.hs
bsd-3-clause
createQueue :: String -> String -> Options -> IORef String -> IO () createQueue prefix region baseopts sqsTestState = do let opts = baseopts & param "Action" .~ ["CreateQueue"] & param "QueueName" .~ [T.pack $ prefix ++ queuename] & param "Version" .~ ["2009-02-01"] ...
797
createQueue :: String -> String -> Options -> IORef String -> IO () createQueue prefix region baseopts sqsTestState = do let opts = baseopts & param "Action" .~ ["CreateQueue"] & param "QueueName" .~ [T.pack $ prefix ++ queuename] & param "Version" .~ ["2009-02-01"] ...
797
createQueue prefix region baseopts sqsTestState = do let opts = baseopts & param "Action" .~ ["CreateQueue"] & param "QueueName" .~ [T.pack $ prefix ++ queuename] & param "Version" .~ ["2009-02-01"] & header "Accept" .~ ["application/json"] r <- getWith opts (u...
729
false
true
0
18
254
232
108
124
null
null
fmthoma/ghc
compiler/typecheck/TcEvidence.hs
bsd-3-clause
evTermCoercion (EvCast tm co) = TcCastCo (evTermCoercion tm) co
64
evTermCoercion (EvCast tm co) = TcCastCo (evTermCoercion tm) co
64
evTermCoercion (EvCast tm co) = TcCastCo (evTermCoercion tm) co
64
false
false
0
7
9
29
13
16
null
null
pjones/xmonad-test
vendor/xmonad/src/XMonad/Config.hs
bsd-2-clause
-- | modMask lets you specify which modkey you want to use. The default -- is mod1Mask ("left alt"). You may also consider using mod3Mask -- ("right alt"), which does not conflict with emacs keybindings. The -- "windows key" is usually mod4Mask. -- defaultModMask :: KeyMask defaultModMask = mod1Mask
301
defaultModMask :: KeyMask defaultModMask = mod1Mask
51
defaultModMask = mod1Mask
25
true
true
0
4
49
16
11
5
null
null
arekfu/project_euler
p0101/p0101.hs
mit
op s = let len = length s order = len - 1 coeffs = regress s in poly coeffs
104
op s = let len = length s order = len - 1 coeffs = regress s in poly coeffs
104
op s = let len = length s order = len - 1 coeffs = regress s in poly coeffs
104
false
false
0
9
48
43
20
23
null
null
brendanhay/gogol
gogol-apps-licensing/gen/Network/Google/Resource/Licensing/LicenseAssignments/Update.hs
mpl-2.0
-- | OAuth access token. lauAccessToken :: Lens' LicenseAssignmentsUpdate (Maybe Text) lauAccessToken = lens _lauAccessToken (\ s a -> s{_lauAccessToken = a})
166
lauAccessToken :: Lens' LicenseAssignmentsUpdate (Maybe Text) lauAccessToken = lens _lauAccessToken (\ s a -> s{_lauAccessToken = a})
141
lauAccessToken = lens _lauAccessToken (\ s a -> s{_lauAccessToken = a})
79
true
true
0
9
29
48
25
23
null
null
harrisi/on-being-better
list-expansion/Haskell/cis194/01/01-intro.hs
cc0-1.0
hailstoneSeq :: Integer -> [Integer] hailstoneSeq 1 = [1]
57
hailstoneSeq :: Integer -> [Integer] hailstoneSeq 1 = [1]
57
hailstoneSeq 1 = [1]
20
false
true
0
6
8
24
13
11
null
null
grammarware/slps
topics/semantics/while/sign-detection/Main.hs
bsd-3-clause
testIf = Seq (Assign "x" (Num 5)) (Seq (Assign "y" (Num 10)) (If (Eq (Var "x") (Var "y")) (Assign "z" (Num 1)) (Assign "z" (Num 0))) )
199
testIf = Seq (Assign "x" (Num 5)) (Seq (Assign "y" (Num 10)) (If (Eq (Var "x") (Var "y")) (Assign "z" (Num 1)) (Assign "z" (Num 0))) )
199
testIf = Seq (Assign "x" (Num 5)) (Seq (Assign "y" (Num 10)) (If (Eq (Var "x") (Var "y")) (Assign "z" (Num 1)) (Assign "z" (Num 0))) )
199
false
false
1
13
91
108
52
56
null
null