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
Catchouli/robo
src/IRC/QuoteHandler.hs
bsd-3-clause
updateQuoteDB :: Map.Map String String -> Update QuoteDB () updateQuoteDB newValue = put (QuoteDB newValue)
107
updateQuoteDB :: Map.Map String String -> Update QuoteDB () updateQuoteDB newValue = put (QuoteDB newValue)
107
updateQuoteDB newValue = put (QuoteDB newValue)
47
false
true
0
7
14
41
19
22
null
null
vdweegen/UvA-Software_Testing
Lab3/Cas/Exercises.hs
gpl-3.0
cls :: Form -> Form cls = cls' . nnf . arrowfree
49
cls :: Form -> Form cls = cls' . nnf . arrowfree
49
cls = cls' . nnf . arrowfree
29
false
true
2
7
12
32
13
19
null
null
haskell-opengl/OpenGLRaw
src/Graphics/GL/Functions/F05.hs
bsd-3-clause
ptr_glDeleteFencesAPPLE :: FunPtr (GLsizei -> Ptr GLuint -> IO ()) ptr_glDeleteFencesAPPLE = unsafePerformIO $ getCommand "glDeleteFencesAPPLE"
143
ptr_glDeleteFencesAPPLE :: FunPtr (GLsizei -> Ptr GLuint -> IO ()) ptr_glDeleteFencesAPPLE = unsafePerformIO $ getCommand "glDeleteFencesAPPLE"
143
ptr_glDeleteFencesAPPLE = unsafePerformIO $ getCommand "glDeleteFencesAPPLE"
76
false
true
0
10
15
40
19
21
null
null
foreverbell/project-euler-solutions
lib/Common/List.hs
bsd-3-clause
maximumBy' :: (a -> a -> Ordering) -> [a] -> a maximumBy' _ [] = undefined
74
maximumBy' :: (a -> a -> Ordering) -> [a] -> a maximumBy' _ [] = undefined
74
maximumBy' _ [] = undefined
27
false
true
0
8
15
40
21
19
null
null
beni55/haste-compiler
libraries/ghc-7.10/base/include/primop-stricts-710.hs
bsd-3-clause
primOpStrictness RaiseOp = \ _arity -> mkClosedStrictSig [topDmd] botRes
73
primOpStrictness RaiseOp = \ _arity -> mkClosedStrictSig [topDmd] botRes
73
primOpStrictness RaiseOp = \ _arity -> mkClosedStrictSig [topDmd] botRes
73
false
false
0
7
9
22
11
11
null
null
NoxHarmonium/lithium-lang
src/Parser.hs
mit
call :: Parser Expr call = do name <- identifier args <- parens $ commaSep expr return $ Call name args
109
call :: Parser Expr call = do name <- identifier args <- parens $ commaSep expr return $ Call name args
109
call = do name <- identifier args <- parens $ commaSep expr return $ Call name args
89
false
true
0
9
26
47
21
26
null
null
fmapfmapfmap/amazonka
amazonka-glacier/test/Test/AWS/Gen/Glacier.hs
mpl-2.0
testCompleteVaultLockResponse :: CompleteVaultLockResponse -> TestTree testCompleteVaultLockResponse = res "CompleteVaultLockResponse" "fixture/CompleteVaultLockResponse.proto" glacier (Proxy :: Proxy CompleteVaultLock)
235
testCompleteVaultLockResponse :: CompleteVaultLockResponse -> TestTree testCompleteVaultLockResponse = res "CompleteVaultLockResponse" "fixture/CompleteVaultLockResponse.proto" glacier (Proxy :: Proxy CompleteVaultLock)
235
testCompleteVaultLockResponse = res "CompleteVaultLockResponse" "fixture/CompleteVaultLockResponse.proto" glacier (Proxy :: Proxy CompleteVaultLock)
164
false
true
0
6
30
36
17
19
null
null
tjakway/ghcjvm
compiler/cmm/PprC.hs
bsd-3-clause
pprExpr1 :: CmmExpr -> SDoc pprExpr1 (CmmLit lit) = pprLit1 lit
67
pprExpr1 :: CmmExpr -> SDoc pprExpr1 (CmmLit lit) = pprLit1 lit
67
pprExpr1 (CmmLit lit) = pprLit1 lit
39
false
true
0
7
14
27
13
14
null
null
gatlin/psilo
src/Lib/Types/TypeCheck.hs
gpl-3.0
(@~) :: Symbol -> [Type] -> TypeCheck () cls @~ tys = do modify $ \st -> st { constraints = [cls :~ tys] ++ (constraints st) } -- | helper to record a predicate constraint -- | Locally modify a 'TypeEnv', do some work, and then revert it.
260
(@~) :: Symbol -> [Type] -> TypeCheck () cls @~ tys = do modify $ \st -> st { constraints = [cls :~ tys] ++ (constraints st) } -- | helper to record a predicate constraint -- | Locally modify a 'TypeEnv', do some work, and then revert it.
260
cls @~ tys = do modify $ \st -> st { constraints = [cls :~ tys] ++ (constraints st) } -- | helper to record a predicate constraint -- | Locally modify a 'TypeEnv', do some work, and then revert it.
219
false
true
0
14
70
78
41
37
null
null
ssaavedra/liquidhaskell
src/Language/Haskell/Liquid/Desugar710/Coverage.hs
bsd-3-clause
addTickHsCmd (HsCmdApp c e) = liftM2 HsCmdApp (addTickLHsCmd c) (addTickLHsExpr e)
90
addTickHsCmd (HsCmdApp c e) = liftM2 HsCmdApp (addTickLHsCmd c) (addTickLHsExpr e)
90
addTickHsCmd (HsCmdApp c e) = liftM2 HsCmdApp (addTickLHsCmd c) (addTickLHsExpr e)
90
false
false
0
7
18
36
17
19
null
null
olsner/ghc
compiler/typecheck/TcEvidence.hs
bsd-3-clause
mkTcRepReflCo = mkRepReflCo
36
mkTcRepReflCo = mkRepReflCo
36
mkTcRepReflCo = mkRepReflCo
36
false
false
0
4
11
6
3
3
null
null
arnizamani/SeqSolver
Amath/Proofs.hs
gpl-2.0
subgoal _ _ = return Nothing
28
subgoal _ _ = return Nothing
28
subgoal _ _ = return Nothing
28
false
false
1
5
5
15
6
9
null
null
pxqr/algorithm-wm
src/TC.hs
mit
freshVar :: Term a b => Context t a freshVar = var <$> fresh
60
freshVar :: Term a b => Context t a freshVar = var <$> fresh
60
freshVar = var <$> fresh
24
false
true
0
6
13
29
14
15
null
null
hguenther/gtl
lib/Language/GTL/Model.hs
bsd-3-clause
-- | Generate a single expression from all non-guaranteed contracts in a list of contracts by conjunction. gtlContractExpression :: [GTLContract a] -> TypedExpr a gtlContractExpression cons = case mapMaybe (\con -> if gtlContractIsGuaranteed con then Nothing ...
636
gtlContractExpression :: [GTLContract a] -> TypedExpr a gtlContractExpression cons = case mapMaybe (\con -> if gtlContractIsGuaranteed con then Nothing else Just $ gtlContractFormula con) cons of [] -> constant Tru...
529
gtlContractExpression cons = case mapMaybe (\con -> if gtlContractIsGuaranteed con then Nothing else Just $ gtlContractFormula con) cons of [] -> constant True xs -> foldl1 gand xs -- | Represents the start or e...
473
true
true
0
11
198
88
45
43
null
null
AnkalagonBlack/bool-kleisli
src/Data/Bool/Kleisli.hs
bsd-3-clause
andM :: (Functor m, Monad m) => (a -> m Bool) -> (a -> m Bool) -> a -> m Bool andM m1 m2 = allM [m1, m2]
104
andM :: (Functor m, Monad m) => (a -> m Bool) -> (a -> m Bool) -> a -> m Bool andM m1 m2 = allM [m1, m2]
104
andM m1 m2 = allM [m1, m2]
26
false
true
0
10
27
75
38
37
null
null
bvdelft/parac2
src/Language/Java/Paragon/TypeCheck/Monad/TcDeclM.hs
bsd-3-clause
evalLockD :: Lock SourcePos -> TcDeclM PL.TcLock evalLockD (Lock _ n@(Name _ _nt mPre i) ans) = do tm <- case mPre of Nothing -> getTypeMap Just pre -> do let preT = ClassType defaultPos pre [] preTy <- evalSrcClsType PL.bottomM preT tm <- getTypeMap ...
1,418
evalLockD :: Lock SourcePos -> TcDeclM PL.TcLock evalLockD (Lock _ n@(Name _ _nt mPre i) ans) = do tm <- case mPre of Nothing -> getTypeMap Just pre -> do let preT = ClassType defaultPos pre [] preTy <- evalSrcClsType PL.bottomM preT tm <- getTypeMap ...
1,418
evalLockD (Lock _ n@(Name _ _nt mPre i) ans) = do tm <- case mPre of Nothing -> getTypeMap Just pre -> do let preT = ClassType defaultPos pre [] preTy <- evalSrcClsType PL.bottomM preT tm <- getTypeMap case lookupTypeOfT (clsTypeToType preTy)...
1,369
false
true
0
25
549
403
190
213
null
null
agentm/project-m36
src/lib/ProjectM36/IsomorphicSchema.hs
unlicense
applyRelationVariablesSchemaIsomorphs :: SchemaIsomorphs -> RelationVariables -> Either RelationalError RelationVariables applyRelationVariablesSchemaIsomorphs = undefined
236
applyRelationVariablesSchemaIsomorphs :: SchemaIsomorphs -> RelationVariables -> Either RelationalError RelationVariables applyRelationVariablesSchemaIsomorphs = undefined
171
applyRelationVariablesSchemaIsomorphs = undefined
49
false
true
0
7
76
24
12
12
null
null
sordina/Edn
Print.hs
mit
fromValue _ (E.Boolean b) = if b then "true" else "false"
59
fromValue _ (E.Boolean b) = if b then "true" else "false"
59
fromValue _ (E.Boolean b) = if b then "true" else "false"
59
false
false
0
8
12
27
14
13
null
null
JacquesCarette/literate-scientific-software
code/drasil-example/Drasil/GlassBR/Changes.hs
bsd-2-clause
predictWithstandOfCertDegDesc, accAlteredGlassDesc :: Sentence predictWithstandOfCertDegDesc = foldlSent [phrase goal `ofThe'` phrase system, S "is to predict whether the", phrase glaSlab, S "under consideration can", S "withstand an", phrase explosion, S "of a certain degree"]
283
predictWithstandOfCertDegDesc, accAlteredGlassDesc :: Sentence predictWithstandOfCertDegDesc = foldlSent [phrase goal `ofThe'` phrase system, S "is to predict whether the", phrase glaSlab, S "under consideration can", S "withstand an", phrase explosion, S "of a certain degree"]
282
predictWithstandOfCertDegDesc = foldlSent [phrase goal `ofThe'` phrase system, S "is to predict whether the", phrase glaSlab, S "under consideration can", S "withstand an", phrase explosion, S "of a certain degree"]
219
false
true
0
8
38
67
35
32
null
null
sdiehl/ghc
testsuite/tests/concurrent/should_run/T5611a.hs
bsd-3-clause
main :: IO () main = do hSetBuffering stdout LineBuffering tid <- forkIO $ do putStrLn "child: Sleeping" _ <- sleep 1 -- The following lines should not happen after the killThread from the -- parent thread completes. However, they do... -- putStrLn "child: Done ...
630
main :: IO () main = do hSetBuffering stdout LineBuffering tid <- forkIO $ do putStrLn "child: Sleeping" _ <- sleep 1 -- The following lines should not happen after the killThread from the -- parent thread completes. However, they do... -- putStrLn "child: Done ...
630
main = do hSetBuffering stdout LineBuffering tid <- forkIO $ do putStrLn "child: Sleeping" _ <- sleep 1 -- The following lines should not happen after the killThread from the -- parent thread completes. However, they do... -- putStrLn "child: Done sleeping" ...
616
false
true
0
12
182
98
41
57
null
null
mhwombat/exp-uivector-cluster-wains
src/ALife/Creatur/Wain/UIVector/Cluster/Experiment.hs
bsd-3-clause
applyDQEffects :: StateT Experiment IO () applyDQEffects = do aDQ <- fromIntegral . decisionQuality <$> use (subject . W.brain) x <- use (universe . U.uDQDeltaE) let deltaE = x*aDQ PW.adjustEnergy subject deltaE rDQDeltaE "DQ" summary report
249
applyDQEffects :: StateT Experiment IO () applyDQEffects = do aDQ <- fromIntegral . decisionQuality <$> use (subject . W.brain) x <- use (universe . U.uDQDeltaE) let deltaE = x*aDQ PW.adjustEnergy subject deltaE rDQDeltaE "DQ" summary report
249
applyDQEffects = do aDQ <- fromIntegral . decisionQuality <$> use (subject . W.brain) x <- use (universe . U.uDQDeltaE) let deltaE = x*aDQ PW.adjustEnergy subject deltaE rDQDeltaE "DQ" summary report
207
false
true
0
12
43
97
46
51
null
null
batterseapower/dual-calculus
CallByValue/CPS.hs
bsd-3-clause
lookupCoVar a coenv = fromMaybe (return . (CoreVar a `CoreApp`)) $ lookup a coenv
81
lookupCoVar a coenv = fromMaybe (return . (CoreVar a `CoreApp`)) $ lookup a coenv
81
lookupCoVar a coenv = fromMaybe (return . (CoreVar a `CoreApp`)) $ lookup a coenv
81
false
false
0
10
13
39
20
19
null
null
FPtje/GLuaFixer
src/GLua/Lexer.hs
lgpl-2.1
parseKeyword :: Token -> String -> LParser Token parseKeyword tok word = pToken word <**> ((\k -> Identifier . (++) k) <$$> pSome pIdentifierCharacter <<|> const <$> pReturn tok)
206
parseKeyword :: Token -> String -> LParser Token parseKeyword tok word = pToken word <**> ((\k -> Identifier . (++) k) <$$> pSome pIdentifierCharacter <<|> const <$> pReturn tok)
206
parseKeyword tok word = pToken word <**> ((\k -> Identifier . (++) k) <$$> pSome pIdentifierCharacter <<|> const <$> pReturn tok)
157
false
true
0
14
56
77
37
40
null
null
beni55/haste-compiler
libraries/ghc-7.8/base/Data/HashTable.hs
bsd-3-clause
recordLookup :: IO () recordLookup = instrument lkup where lkup hd@HD{ lookups=l } = hd{ lookups=l+1 } -- stats :: IO String -- stats = fmap show $ readIORef hashData -- ---------------------------------------------------------------------------- -- Sample hash functions -- $hash_functions -- -- This implementati...
775
recordLookup :: IO () recordLookup = instrument lkup where lkup hd@HD{ lookups=l } = hd{ lookups=l+1 } -- stats :: IO String -- stats = fmap show $ readIORef hashData -- ---------------------------------------------------------------------------- -- Sample hash functions -- $hash_functions -- -- This implementati...
775
recordLookup = instrument lkup where lkup hd@HD{ lookups=l } = hd{ lookups=l+1 } -- stats :: IO String -- stats = fmap show $ readIORef hashData -- ---------------------------------------------------------------------------- -- Sample hash functions -- $hash_functions -- -- This implementation of hash tables uses...
753
false
true
0
9
130
68
43
25
null
null
randen/cabal
cabal-install/Distribution/Client/Sandbox/PackageEnvironment.hs
bsd-3-clause
-- | Almost the same as 'savedConf `mappend` pkgEnv', but some settings are -- overridden instead of mappend'ed. overrideSandboxSettings :: PackageEnvironment -> PackageEnvironment -> PackageEnvironment overrideSandboxSettings pkgEnv0 pkgEnv = pkgEnv { pkgEnvSavedConfig = mappendedConf ...
1,067
overrideSandboxSettings :: PackageEnvironment -> PackageEnvironment -> PackageEnvironment overrideSandboxSettings pkgEnv0 pkgEnv = pkgEnv { pkgEnvSavedConfig = mappendedConf { savedConfigureFlags = (savedConfigureFlags mappendedConf) { configPackageDBs = configPackage...
954
overrideSandboxSettings pkgEnv0 pkgEnv = pkgEnv { pkgEnvSavedConfig = mappendedConf { savedConfigureFlags = (savedConfigureFlags mappendedConf) { configPackageDBs = configPackageDBs pkgEnvConfigureFlags } , savedInstallFlags = (savedInstallFlags mappendedConf) { insta...
837
true
true
0
11
249
137
76
61
null
null
mrBliss/haddock
haddock-api/src/Haddock/Backends/LaTeX.hs
bsd-2-clause
-- error "foreign declarations are currently not supported by --latex" ------------------------------------------------------------------------------- -- * Type Synonyms ------------------------------------------------------------------------------- -- we skip type patterns for now ppTySyn :: SrcSpan -> DocForDecl...
698
ppTySyn :: SrcSpan -> DocForDecl DocName -> TyClDecl DocName -> Bool -> LaTeX ppTySyn loc doc (SynDecl { tcdLName = L _ name, tcdTyVars = ltyvars , tcdRhs = ltype }) unicode = ppTypeOrFunSig loc [name] (unLoc ltype) doc (full, hdr, char '=') unicode where hdr = hsep (keyword "type" : p...
409
ppTySyn loc doc (SynDecl { tcdLName = L _ name, tcdTyVars = ltyvars , tcdRhs = ltype }) unicode = ppTypeOrFunSig loc [name] (unLoc ltype) doc (full, hdr, char '=') unicode where hdr = hsep (keyword "type" : ppDocBinder name : ppTyVars ltyvars) full = hdr <+> char '=' <+> ppLType un...
331
true
true
1
11
132
163
84
79
null
null
andyarvanitis/Idris-dev
src/IRTS/CodegenC.hs
bsd-3-clause
doOp v (LEq (ATInt ITBig)) [l, r] = v ++ "idris_bigEq(vm, " ++ creg l ++ ", " ++ creg r ++ ")"
94
doOp v (LEq (ATInt ITBig)) [l, r] = v ++ "idris_bigEq(vm, " ++ creg l ++ ", " ++ creg r ++ ")"
94
doOp v (LEq (ATInt ITBig)) [l, r] = v ++ "idris_bigEq(vm, " ++ creg l ++ ", " ++ creg r ++ ")"
94
false
false
0
9
22
57
28
29
null
null
abailly/kontiki
src/Network/Kontiki/Types.hs
bsd-3-clause
term0 :: Term term0 = Term 0
28
term0 :: Term term0 = Term 0
28
term0 = Term 0
14
false
true
0
5
6
14
7
7
null
null
jsavatgy/hatupist
code/timing.hs
gpl-2.0
amountOfIntervals = rDuration `div` iDuration
45
amountOfIntervals = rDuration `div` iDuration
45
amountOfIntervals = rDuration `div` iDuration
45
false
false
0
5
4
12
7
5
null
null
exbb2/BlastItWithPiss
src/GtkBlast/Pasta.hs
gpl-3.0
generatePastaGen Symbol = do E{..} <- ask !postproc <- makePostProc return $ mkFullGen $ \a b c -> fmap (TBPC False False) $ postproc a b c =<< generateSymbolString 5000
191
generatePastaGen Symbol = do E{..} <- ask !postproc <- makePostProc return $ mkFullGen $ \a b c -> fmap (TBPC False False) $ postproc a b c =<< generateSymbolString 5000
191
generatePastaGen Symbol = do E{..} <- ask !postproc <- makePostProc return $ mkFullGen $ \a b c -> fmap (TBPC False False) $ postproc a b c =<< generateSymbolString 5000
191
false
false
0
13
51
79
36
43
null
null
kRITZCREEK/psc-ide
src/PureScript/Ide/Filter.hs
mit
applyFilters :: [Filter] -> [Module] -> [Module] applyFilters = runFilter . fold
80
applyFilters :: [Filter] -> [Module] -> [Module] applyFilters = runFilter . fold
80
applyFilters = runFilter . fold
31
false
true
0
7
11
32
18
14
null
null
bcoppens/HaskellSshClient
src/Ssh/KeyExchange.hs
gpl-3.0
doKex :: [KeyExchangeAlgorithm] -> [HostKeyAlgorithm] -> [CryptionAlgorithm] -> [CryptionAlgorithm] -> [HashMac] -> [HashMac] -> SshConnection ConnectionData doKex clientKEXAlgos clientHostKeys clientCryptos serverCryptos clientHashMacs serverHashMacs = do -- Prepare our KEXInit packet -- Get 16 bytes of rando...
1,267
doKex :: [KeyExchangeAlgorithm] -> [HostKeyAlgorithm] -> [CryptionAlgorithm] -> [CryptionAlgorithm] -> [HashMac] -> [HashMac] -> SshConnection ConnectionData doKex clientKEXAlgos clientHostKeys clientCryptos serverCryptos clientHashMacs serverHashMacs = do -- Prepare our KEXInit packet -- Get 16 bytes of rando...
1,267
doKex clientKEXAlgos clientHostKeys clientCryptos serverCryptos clientHashMacs serverHashMacs = do -- Prepare our KEXInit packet -- Get 16 bytes of randomness for our cookie. -- TODO: use OpenSSL.Random.add for more randomness cookie <- MS.liftIO $ BS.unpack `liftM` randBytes 16 let clientKex = KE...
1,109
false
true
0
12
210
227
116
111
null
null
jozefg/ds-kanren
test/Unify.hs
mit
--------------------------- Conj ------------------------------------- conjid :: TestTree conjid = testProperty "Commutative" . forPred $ \p -> hasSolution p ==> hasSolution (conj success p)
218
conjid :: TestTree conjid = testProperty "Commutative" . forPred $ \p -> hasSolution p ==> hasSolution (conj success p)
147
conjid = testProperty "Commutative" . forPred $ \p -> hasSolution p ==> hasSolution (conj success p)
128
true
true
3
9
49
54
24
30
null
null
spockz/lhs2texhl
src/LiterateHighlighter.hs
mit
----------------------------- main = do args <- cmdArgsRun standard goUTF8 case action args of ListCommands -> putStr newCommands _ -> if agda_mode args then error "Agda mode is currently not...
1,753
main = do args <- cmdArgsRun standard goUTF8 case action args of ListCommands -> putStr newCommands _ -> if agda_mode args then error "Agda mode is currently not supported." ...
1,721
main = do args <- cmdArgsRun standard goUTF8 case action args of ListCommands -> putStr newCommands _ -> if agda_mode args then error "Agda mode is currently not supported." ...
1,721
true
false
5
14
896
376
175
201
null
null
shaurya0/GPWebCrawler
src/GPTracklists.hs
bsd-3-clause
getTracklistFromTags (Just tracklistTags) = Just (sanitizeTracklist $ map fromTagText $ filter isTagText tracklistTags)
119
getTracklistFromTags (Just tracklistTags) = Just (sanitizeTracklist $ map fromTagText $ filter isTagText tracklistTags)
119
getTracklistFromTags (Just tracklistTags) = Just (sanitizeTracklist $ map fromTagText $ filter isTagText tracklistTags)
119
false
false
0
9
12
38
17
21
null
null
oldmanmike/ghc
compiler/basicTypes/IdInfo.hs
bsd-3-clause
pprIdDetails :: IdDetails -> SDoc pprIdDetails VanillaId = empty
64
pprIdDetails :: IdDetails -> SDoc pprIdDetails VanillaId = empty
64
pprIdDetails VanillaId = empty
30
false
true
0
5
8
18
9
9
null
null
ndmitchell/hlint
src/Hint/Extensions.hs
bsd-3-clause
used OverloadedStrings = hasS isString
38
used OverloadedStrings = hasS isString
38
used OverloadedStrings = hasS isString
38
false
false
1
5
4
15
5
10
null
null
tpsinnem/Idris-dev
src/Idris/Core/TT.hs
bsd-3-clause
showCG (MN _ u) | u == txt "underscore" = "_"
45
showCG (MN _ u) | u == txt "underscore" = "_"
45
showCG (MN _ u) | u == txt "underscore" = "_"
45
false
false
0
9
10
30
13
17
null
null
brendanhay/gogol
gogol-youtube/gen/Network/Google/YouTube/Types/Product.hs
mpl-2.0
-- | The video content\'s display aspect ratio, which specifies the aspect -- ratio in which the video should be displayed. vfdvsAspectRatio :: Lens' VideoFileDetailsVideoStream (Maybe Double) vfdvsAspectRatio = lens _vfdvsAspectRatio (\ s a -> s{_vfdvsAspectRatio = a}) . mapping _Coerce
302
vfdvsAspectRatio :: Lens' VideoFileDetailsVideoStream (Maybe Double) vfdvsAspectRatio = lens _vfdvsAspectRatio (\ s a -> s{_vfdvsAspectRatio = a}) . mapping _Coerce
178
vfdvsAspectRatio = lens _vfdvsAspectRatio (\ s a -> s{_vfdvsAspectRatio = a}) . mapping _Coerce
109
true
true
0
10
54
56
29
27
null
null
termite2/debug
Debug/DbgTypes.hs
bsd-3-clause
modelLabelVars :: RModel c a b d -> IO [ModelVar] modelLabelVars ref = getIORef mLabelVars ref
94
modelLabelVars :: RModel c a b d -> IO [ModelVar] modelLabelVars ref = getIORef mLabelVars ref
94
modelLabelVars ref = getIORef mLabelVars ref
44
false
true
0
8
15
42
19
23
null
null
MichaelXavier/HTTPMock
test/Network/HTTPMock/SpecHelper.hs
bsd-2-clause
postReturningBody = requestReturningBody POST
45
postReturningBody = requestReturningBody POST
45
postReturningBody = requestReturningBody POST
45
false
false
0
5
3
9
4
5
null
null
kojiromike/Idris-dev
src/IRTS/JavaScript/LangTransforms.hs
bsd-3-clause
getUsedConstructors :: Map Name LDecl -> Set Name getUsedConstructors x = Set.fromList [ n | LCon _ _ n _ <- universeBi x]
122
getUsedConstructors :: Map Name LDecl -> Set Name getUsedConstructors x = Set.fromList [ n | LCon _ _ n _ <- universeBi x]
122
getUsedConstructors x = Set.fromList [ n | LCon _ _ n _ <- universeBi x]
72
false
true
0
9
22
58
26
32
null
null
SimSaladin/ggtd
src/GGTD/TUI/TaskList.hs
bsd-3-clause
exitEditor :: TaskList -> Handler TaskList exitEditor taskList = return taskList { editor = Nothing }
101
exitEditor :: TaskList -> Handler TaskList exitEditor taskList = return taskList { editor = Nothing }
101
exitEditor taskList = return taskList { editor = Nothing }
58
false
true
0
7
15
32
16
16
null
null
fryguybob/LaTeXGrapher
src/LaTeXGrapher/Diagrams.hs
bsd-3-clause
rtOrientation (Path ((P p,t):_)) = (p,) . startVector $ t where startVector (Trail [] _) = (0,0) startVector (Trail ((Linear v):_) _) = v startVector (Trail ((Cubic a b _):_) _) = b - a e
220
startOrientation (Path ((P p,t):_)) = (p,) . startVector $ t where startVector (Trail [] _) = (0,0) startVector (Trail ((Linear v):_) _) = v startVector (Trail ((Cubic a b _):_) _) = b - a
220
startOrientation (Path ((P p,t):_)) = (p,) . startVector $ t where startVector (Trail [] _) = (0,0) startVector (Trail ((Linear v):_) _) = v startVector (Trail ((Cubic a b _):_) _) = b - a
220
false
false
2
12
68
140
72
68
null
null
spacekitteh/smcghc
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
11
60
103
46
57
null
null
fmapfmapfmap/amazonka
amazonka-ses/gen/Network/AWS/SES/Types/Product.hs
mpl-2.0
-- | The subject of the message: A short summary of the content, which will -- appear in the recipient\'s inbox. mSubject :: Lens' Message Content mSubject = lens _mSubject (\ s a -> s{_mSubject = a})
200
mSubject :: Lens' Message Content mSubject = lens _mSubject (\ s a -> s{_mSubject = a})
87
mSubject = lens _mSubject (\ s a -> s{_mSubject = a})
53
true
true
0
9
36
41
23
18
null
null
tjakway/ghcjvm
compiler/types/Coercion.hs
bsd-3-clause
lcSubstLeft :: LiftingContext -> TCvSubst lcSubstLeft (LC subst lc_env) = liftEnvSubstLeft subst lc_env
103
lcSubstLeft :: LiftingContext -> TCvSubst lcSubstLeft (LC subst lc_env) = liftEnvSubstLeft subst lc_env
103
lcSubstLeft (LC subst lc_env) = liftEnvSubstLeft subst lc_env
61
false
true
0
6
12
35
16
19
null
null
codecurve/FieldML-Haskell-01
src/FieldML/Utility01.hs
bsd-2-clause
domain (Lambda x@(GeneralVariable _ _) _ ) = simplifyFSet $ codomain x
70
domain (Lambda x@(GeneralVariable _ _) _ ) = simplifyFSet $ codomain x
70
domain (Lambda x@(GeneralVariable _ _) _ ) = simplifyFSet $ codomain x
70
false
false
0
9
11
36
17
19
null
null
ucsd-progsys/nanomaly
src/NanoML/Pretty.hs
bsd-3-clause
isValueOrFunVar (Prim1 {}) = True
34
isValueOrFunVar (Prim1 {}) = True
34
isValueOrFunVar (Prim1 {}) = True
34
false
false
0
7
5
16
8
8
null
null
djoyner/zigbee-znet25
src/Network/Protocol/ZigBee/ZNet25/Encoder.hs
bsd-3-clause
-- | Decode a 'B.ByteString' in the 'S.State' monad, reversing the 'encode' -- process. Once a frame delimiter byte is found, the inner frame payload is -- unescaped, the checksum is verified, and finally a 'Frame' is deserialized. -- -- Note that this function may produce zero or more errors or 'Frame's depending -- ...
3,639
decode :: S.MonadState DecoderState m => B.ByteString -> m [Either String Frame] decode bs0 = do ds <- S.get let t = S.runState (unescapeBuffer bs0) $ dsEscapedChar ds go ds { dsEscapedChar = snd t } $ fst t where -- Drop bytes until a frame delimiter is found go ds@(DS Hunting _ _ _) bs | ...
1,871
decode bs0 = do ds <- S.get let t = S.runState (unescapeBuffer bs0) $ dsEscapedChar ds go ds { dsEscapedChar = snd t } $ fst t where -- Drop bytes until a frame delimiter is found go ds@(DS Hunting _ _ _) bs | B.null bs = S.put ds >> return [] | B.head bs == ctrlFram...
1,790
true
true
13
13
1,015
724
354
370
null
null
fpco/stackage-server
src/Handler/Feed.hs
mit
getContent :: SnapshotId -> Snapshot -> Handler Html getContent sid2 snap = do mprev <- snapshotBefore $ snapshotName snap case mprev of Nothing -> return "No previous snapshot found for comparison" Just (sid1, name1) -> do snapDiff <- getSnapshotDiff sid1 sid2 let name2 ...
2,529
getContent :: SnapshotId -> Snapshot -> Handler Html getContent sid2 snap = do mprev <- snapshotBefore $ snapshotName snap case mprev of Nothing -> return "No previous snapshot found for comparison" Just (sid1, name1) -> do snapDiff <- getSnapshotDiff sid1 sid2 let name2 ...
2,529
getContent sid2 snap = do mprev <- snapshotBefore $ snapshotName snap case mprev of Nothing -> return "No previous snapshot found for comparison" Just (sid1, name1) -> do snapDiff <- getSnapshotDiff sid1 sid2 let name2 = snapshotName snap withUrlRenderer ...
2,476
false
true
0
15
1,390
106
50
56
null
null
ThomWright/CIS194
src/HW05.hs
bsd-3-clause
getCriminal :: Map String Integer -> String getCriminal m = fst $ maximumBy (comparing snd) $ Map.toList m
106
getCriminal :: Map String Integer -> String getCriminal m = fst $ maximumBy (comparing snd) $ Map.toList m
106
getCriminal m = fst $ maximumBy (comparing snd) $ Map.toList m
62
false
true
0
9
17
45
21
24
null
null
NorfairKing/the-notes
src/Probability/RandomVariable/Macro.hs
gpl-2.0
-- * Expected value -- | Expected value ev :: Note -> Note ev n = "E" <> sqbrac n
82
ev :: Note -> Note ev n = "E" <> sqbrac n
41
ev n = "E" <> sqbrac n
22
true
true
0
7
20
32
15
17
null
null
ianoc/jt
src/Jt/History/Counters.hs
mit
fetchCounters :: String -> QueryParameters -> HistoryUrl -> IO (Either String (Maybe [Counter])) fetchCounters jobId' queryParameters url = do let (HistoryUrl rawUrl) = url let finalUrl = rawUrl ++ "/ws/v1/history/mapreduce/jobs/" ++ (Utils.toJobId jobId') ++ "/counters" rawFetchCounters queryParameters fin...
325
fetchCounters :: String -> QueryParameters -> HistoryUrl -> IO (Either String (Maybe [Counter])) fetchCounters jobId' queryParameters url = do let (HistoryUrl rawUrl) = url let finalUrl = rawUrl ++ "/ws/v1/history/mapreduce/jobs/" ++ (Utils.toJobId jobId') ++ "/counters" rawFetchCounters queryParameters fin...
325
fetchCounters jobId' queryParameters url = do let (HistoryUrl rawUrl) = url let finalUrl = rawUrl ++ "/ws/v1/history/mapreduce/jobs/" ++ (Utils.toJobId jobId') ++ "/counters" rawFetchCounters queryParameters finalUrl
228
false
true
0
15
49
108
50
58
null
null
shinjiro-itagaki/shinjirecs
shinjirecs-api/src/Class/String.hs
gpl-3.0
deleteMatchedHead cond@(x:xs) txt@(y:ys) = if x == y then deleteMatchedHead xs ys else Nothing
94
deleteMatchedHead cond@(x:xs) txt@(y:ys) = if x == y then deleteMatchedHead xs ys else Nothing
94
deleteMatchedHead cond@(x:xs) txt@(y:ys) = if x == y then deleteMatchedHead xs ys else Nothing
94
false
false
0
8
13
48
26
22
null
null
johnjcamilleri/fst
FST/Info.hs
bsd-3-clause
-- | Is there a built transducer in the state? transducerBuilt :: Info -> Bool transducerBuilt = snd . transducer
113
transducerBuilt :: Info -> Bool transducerBuilt = snd . transducer
66
transducerBuilt = snd . transducer
34
true
true
0
5
19
20
11
9
null
null
DavidAlphaFox/ghc
libraries/xhtml/Text/XHtml/Frameset/Elements.hs
bsd-3-clause
frameset :: Html -> Html frameset = tag "frameset"
73
frameset :: Html -> Html frameset = tag "frameset"
73
frameset = tag "frameset"
37
false
true
0
5
31
18
9
9
null
null
UCSD-PL/RefScript
src/Language/Rsc/Errors.hs
bsd-3-clause
errorOptionalElt l p t t' = mkErr l $ text $ printf "Unmatching optionality values for property '%s' in types '%s' and '%s'." (ppshow p) (ppshow t) (ppshow t')
163
errorOptionalElt l p t t' = mkErr l $ text $ printf "Unmatching optionality values for property '%s' in types '%s' and '%s'." (ppshow p) (ppshow t) (ppshow t')
163
errorOptionalElt l p t t' = mkErr l $ text $ printf "Unmatching optionality values for property '%s' in types '%s' and '%s'." (ppshow p) (ppshow t) (ppshow t')
163
false
false
0
8
32
53
25
28
null
null
bergmark/hakyll
src/Hakyll/Core/Identifier/Pattern.hs
bsd-3-clause
-- An empty match capture' [] _ = Nothing
42
capture' [] _ = Nothing
24
capture' [] _ = Nothing
24
true
false
0
5
9
16
7
9
null
null
dmbarbour/Sirea
src/Sirea/Internal/B0Impl.hs
bsd-3-clause
-- pre-synch for disjoin operation. This must synch everything in x -- with the given (S p ()) signal. synchForDisjoinB0 :: (Monad m) => B0 m (x :&: ((S p () :&: y) :|: z) ) (x :&: ((S p () :&: y) :|: z) ) synchForDisjoinB0 = tshiftB0 disjSynch where disjSynch xuyz = ...
933
synchForDisjoinB0 :: (Monad m) => B0 m (x :&: ((S p () :&: y) :|: z) ) (x :&: ((S p () :&: y) :|: z) ) synchForDisjoinB0 = tshiftB0 disjSynch where disjSynch xuyz = let x = ln_fst xuyz in let u = (ln_snd >>> ln_left >>> ln_fst) xuyz in let y = (l...
829
synchForDisjoinB0 = tshiftB0 disjSynch where disjSynch xuyz = let x = ln_fst xuyz in let u = (ln_snd >>> ln_left >>> ln_fst) xuyz in let y = (ln_snd >>> ln_left >>> ln_snd) xuyz in let z = (ln_snd >>> ln_right) xuyz in -- don't need to synch if statically in left or right ...
680
true
true
0
24
296
278
139
139
null
null
geophf/1HaskellADay
exercises/HAD/Y2017/M01/D16/Exercise.hs
mit
gtfo :: [Int] -> Maybe Int -- gtfo: greather than five-o gtfo = undefined
74
gtfo :: [Int] -> Maybe Int gtfo = undefined
43
gtfo = undefined
16
true
true
0
6
14
22
12
10
null
null
atupal/xmonad-mirror
xmonad.hs
mit
-- Whether focus follows the mouse pointer. myFocusFollowsMouse :: Bool myFocusFollowsMouse = True
98
myFocusFollowsMouse :: Bool myFocusFollowsMouse = True
54
myFocusFollowsMouse = True
26
true
true
0
4
12
12
7
5
null
null
saclark/wyas
src/Wyas/Eval.hs
mit
eval :: LispVal -> ThrowsError LispVal eval val@(Bool _) = return val
83
eval :: LispVal -> ThrowsError LispVal eval val@(Bool _) = return val
83
eval val@(Bool _) = return val
44
false
true
0
8
25
33
16
17
null
null
alphaHeavy/hlint
src/Hint/Extensions.hs
gpl-2.0
extensionsHint :: ModuHint extensionsHint _ x = [rawIdea Error "Unused LANGUAGE pragma" (toSrcLoc sl) (prettyPrint o) (if null new then "" else prettyPrint $ LanguagePragma sl $ map (toNamed . showExt) new) (warnings old new) | not $ used TemplateHaskell x -- if TH is on, can use all other exten...
599
extensionsHint :: ModuHint extensionsHint _ x = [rawIdea Error "Unused LANGUAGE pragma" (toSrcLoc sl) (prettyPrint o) (if null new then "" else prettyPrint $ LanguagePragma sl $ map (toNamed . showExt) new) (warnings old new) | not $ used TemplateHaskell x -- if TH is on, can use all other exten...
599
extensionsHint _ x = [rawIdea Error "Unused LANGUAGE pragma" (toSrcLoc sl) (prettyPrint o) (if null new then "" else prettyPrint $ LanguagePragma sl $ map (toNamed . showExt) new) (warnings old new) | not $ used TemplateHaskell x -- if TH is on, can use all other extensions programmatically ...
572
false
true
1
12
151
214
101
113
null
null
nomeata/ghc
compiler/nativeGen/PPC/CodeGen.hs
bsd-3-clause
ssignReg_FltCode = assignReg_IntCode
37
assignReg_FltCode = assignReg_IntCode
37
assignReg_FltCode = assignReg_IntCode
37
false
false
0
4
3
6
3
3
null
null
ARCCN/hcprobe
src/bench/TestARPGen.hs
bsd-3-clause
pktNum = 1000000
16
pktNum = 1000000
16
pktNum = 1000000
16
false
false
1
5
2
10
3
7
null
null
Zankoku-Okuno/ammonite
Language/Ammonite/Interpreter/Evaluator.hs
gpl-3.0
reduce :: (ReportValue sysval) => Value sysval -> Machine sysval (Value sysval) reduce v = maybe (pure v) (flip reduce' v) =<< popCont where -- Compound Data Contruction reduce' :: (ReportValue sysval) => Cont sysval -> Value sysval -> Machine sysval (Value sysval) reduce' (ListCont vs [], pos) v = redu...
5,239
reduce :: (ReportValue sysval) => Value sysval -> Machine sysval (Value sysval) reduce v = maybe (pure v) (flip reduce' v) =<< popCont where -- Compound Data Contruction reduce' :: (ReportValue sysval) => Cont sysval -> Value sysval -> Machine sysval (Value sysval) reduce' (ListCont vs [], pos) v = redu...
5,239
reduce v = maybe (pure v) (flip reduce' v) =<< popCont where -- Compound Data Contruction reduce' :: (ReportValue sysval) => Cont sysval -> Value sysval -> Machine sysval (Value sysval) reduce' (ListCont vs [], pos) v = reduce $ ListVal (vs |> v) reduce' (ListCont vs (e:es), pos) v = do push...
5,159
false
true
0
18
2,043
2,021
972
1,049
null
null
ihc/futhark
src/Futhark/Optimise/MemoryBlockMerging/Miscellaneous.hs
isc
findM :: Monad m => (a -> m Bool) -> [a] -> m (Maybe a) findM f xs = do xs' <- filterM f xs return $ case xs' of x' : _ -> Just x' _ -> Nothing
155
findM :: Monad m => (a -> m Bool) -> [a] -> m (Maybe a) findM f xs = do xs' <- filterM f xs return $ case xs' of x' : _ -> Just x' _ -> Nothing
155
findM f xs = do xs' <- filterM f xs return $ case xs' of x' : _ -> Just x' _ -> Nothing
99
false
true
0
11
50
95
45
50
null
null
holzensp/ghc
compiler/codeGen/StgCmmPrim.hs
bsd-3-clause
emitPrimOp _ [res] ReadArrayArrayOp_ArrayArray [obj,ix] = doReadPtrArrayOp res obj ix
100
emitPrimOp _ [res] ReadArrayArrayOp_ArrayArray [obj,ix] = doReadPtrArrayOp res obj ix
100
emitPrimOp _ [res] ReadArrayArrayOp_ArrayArray [obj,ix] = doReadPtrArrayOp res obj ix
100
false
false
0
6
24
31
16
15
null
null
rdtaylor/CelestialBodies
Entities.hs
mit
getInitShip :: Ship getInitShip = Ship { ship_position = Position initial_x initial_y , ship_orientation = pi / 2 -- North , ship_velocity = EntityVector 0 0 , ship_lives = 3 }
178
getInitShip :: Ship getInitShip = Ship { ship_position = Position initial_x initial_y , ship_orientation = pi / 2 -- North , ship_velocity = EntityVector 0 0 , ship_lives = 3 }
178
getInitShip = Ship { ship_position = Position initial_x initial_y , ship_orientation = pi / 2 -- North , ship_velocity = EntityVector 0 0 , ship_lives = 3 }
158
false
true
0
7
32
52
30
22
null
null
rpglover64/lens
src/Language/Haskell/TH/Lens.hs
bsd-3-clause
_Interruptible :: Prism' Safety () _Interruptible = prism remitter reviewer where remitter () = Interruptible reviewer Interruptible = Right () reviewer x = Left x #if MIN_VERSION_template_haskell(2,8,0)
226
_Interruptible :: Prism' Safety () _Interruptible = prism remitter reviewer where remitter () = Interruptible reviewer Interruptible = Right () reviewer x = Left x #if MIN_VERSION_template_haskell(2,8,0)
226
_Interruptible = prism remitter reviewer where remitter () = Interruptible reviewer Interruptible = Right () reviewer x = Left x #if MIN_VERSION_template_haskell(2,8,0)
191
false
true
2
7
49
61
29
32
null
null
maxiwoj/HaskellProject
src/Regression.hs
bsd-3-clause
{-| returns distance between the function f(x) = theta_a * x + theta_b and the given point for given x -} cost1el :: Fractional a => (a,a) -> a -> a -> a cost1el (theta_a,theta_b) x_el y_el = (theta_a * x_el + theta_b - y_el) ^ 2
229
cost1el :: Fractional a => (a,a) -> a -> a -> a cost1el (theta_a,theta_b) x_el y_el = (theta_a * x_el + theta_b - y_el) ^ 2
123
cost1el (theta_a,theta_b) x_el y_el = (theta_a * x_el + theta_b - y_el) ^ 2
75
true
true
0
9
46
69
37
32
null
null
samvher/translatethenews
app/TTN/View/Core.hs
mit
navSegment :: TTNTemplate ctx () navSegment = maybe notLoggedInNav loggedInNav =<< getCurrentUser where loggedInNav :: Entity User -> TTNTemplate ctx () loggedInNav _ = ul_ . div_ [id_ "nav-box"] $ do li_ . a_ [href_ listPrefTranslationsPath] $ h "View translations" li_ . a_ [href_ lis...
824
navSegment :: TTNTemplate ctx () navSegment = maybe notLoggedInNav loggedInNav =<< getCurrentUser where loggedInNav :: Entity User -> TTNTemplate ctx () loggedInNav _ = ul_ . div_ [id_ "nav-box"] $ do li_ . a_ [href_ listPrefTranslationsPath] $ h "View translations" li_ . a_ [href_ lis...
824
navSegment = maybe notLoggedInNav loggedInNav =<< getCurrentUser where loggedInNav :: Entity User -> TTNTemplate ctx () loggedInNav _ = ul_ . div_ [id_ "nav-box"] $ do li_ . a_ [href_ listPrefTranslationsPath] $ h "View translations" li_ . a_ [href_ listPrefArticlesPath] $ h "Trans...
791
false
true
4
12
261
266
117
149
null
null
randen/haddock
haddock-api/src/Haddock.hs
bsd-2-clause
haddock :: [String] -> IO () haddock args = haddockWithGhc withGhc args
71
haddock :: [String] -> IO () haddock args = haddockWithGhc withGhc args
71
haddock args = haddockWithGhc withGhc args
42
false
true
0
7
11
31
15
16
null
null
btipling/machine-vm
test/VMTest/Machine/Memory.hs
bsd-3-clause
genRandomRam4K :: Random.StdGen -> (Memory.RAM4K, Random.StdGen) genRandomRam4K g = genRandom8Tuple g genRandomRam512
117
genRandomRam4K :: Random.StdGen -> (Memory.RAM4K, Random.StdGen) genRandomRam4K g = genRandom8Tuple g genRandomRam512
117
genRandomRam4K g = genRandom8Tuple g genRandomRam512
52
false
true
0
7
11
35
18
17
null
null
mstksg/expr-gadt
src/Data/ExprGADT/Types.hs
bsd-3-clause
bB :: Bool -> Expr vs Bool bB = O0 . B
38
bB :: Bool -> Expr vs Bool bB = O0 . B
38
bB = O0 . B
11
false
true
1
7
11
31
13
18
null
null
hdgarrood/aeson-better-errors
src/Data/Aeson/BetterErrors/Internal.hs
mit
withIntegral :: (Functor m, Monad m, Integral a) => (a -> Either err b) -> ParseT err m b withIntegral = with asIntegral
120
withIntegral :: (Functor m, Monad m, Integral a) => (a -> Either err b) -> ParseT err m b withIntegral = with asIntegral
120
withIntegral = with asIntegral
30
false
true
0
9
22
58
29
29
null
null
lukexi/ghc-7.8-arm64
compiler/cmm/PprCmm.hs
bsd-3-clause
pprGraph :: Graph CmmNode e x -> SDoc pprGraph GNil = empty
59
pprGraph :: Graph CmmNode e x -> SDoc pprGraph GNil = empty
59
pprGraph GNil = empty
21
false
true
0
6
11
25
12
13
null
null
kmate/HaRe
old/refactorer/RefacUnfoldAsPatterns.hs
bsd-3-clause
convertPat p = p
16
convertPat p = p
16
convertPat p = p
16
false
false
0
5
3
9
4
5
null
null
sergv/vector
Data/Vector/Fusion/Bundle/Monadic.hs
bsd-3-clause
unsafeFromList sz xs = fromStream (S.fromList xs) sz
52
unsafeFromList sz xs = fromStream (S.fromList xs) sz
52
unsafeFromList sz xs = fromStream (S.fromList xs) sz
52
false
false
1
7
7
30
11
19
null
null
phischu/haxl-neo4j
src/Haxl/Neo4j/Internal.hs
bsd-3-clause
nodeById :: NodeId -> Haxl Node nodeById = dataFetch . NodeById
63
nodeById :: NodeId -> Haxl Node nodeById = dataFetch . NodeById
63
nodeById = dataFetch . NodeById
31
false
true
1
7
10
29
12
17
null
null
HJvT/com
System/Win32/Com/Exception.hs
bsd-3-clause
tYPE_E_OUTOFBOUNDS :: HRESULT tYPE_E_OUTOFBOUNDS = word32ToInt32 (0x80028CA1 ::Word32)
86
tYPE_E_OUTOFBOUNDS :: HRESULT tYPE_E_OUTOFBOUNDS = word32ToInt32 (0x80028CA1 ::Word32)
86
tYPE_E_OUTOFBOUNDS = word32ToInt32 (0x80028CA1 ::Word32)
56
false
true
0
6
7
26
12
14
null
null
ambiata/mafia
src/Mafia/Cabal/Sandbox.hs
bsd-3-clause
sandboxRoot :: Directory sandboxRoot = ".cabal-sandbox"
57
sandboxRoot :: Directory sandboxRoot = ".cabal-sandbox"
57
sandboxRoot = ".cabal-sandbox"
32
false
true
0
4
7
11
6
5
null
null
anirudhhkumarr/ml-lib
src/Parser/CSV.hs
gpl-2.0
toattributeValue::[[String]] -> [AttributeType] -> [[Maybe AttributeValue]] toattributeValue (x:xs) dataType = (zipWith toattrVal dataType x):(toattributeValue xs dataType)
172
toattributeValue::[[String]] -> [AttributeType] -> [[Maybe AttributeValue]] toattributeValue (x:xs) dataType = (zipWith toattrVal dataType x):(toattributeValue xs dataType)
172
toattributeValue (x:xs) dataType = (zipWith toattrVal dataType x):(toattributeValue xs dataType)
96
false
true
0
9
15
71
38
33
null
null
Sword-Smith/hfasto
src/AMD64CodeGenerator.hs
mit
compileExp (BDeclInst rd rs Minus (IntVal imm)) = [AMD64.MOV "rax" rs, AMD64.SUB "rax" (show imm), AMD64.MOV rd "rax"]
221
compileExp (BDeclInst rd rs Minus (IntVal imm)) = [AMD64.MOV "rax" rs, AMD64.SUB "rax" (show imm), AMD64.MOV rd "rax"]
221
compileExp (BDeclInst rd rs Minus (IntVal imm)) = [AMD64.MOV "rax" rs, AMD64.SUB "rax" (show imm), AMD64.MOV rd "rax"]
221
false
false
0
9
120
63
31
32
null
null
bsl/GLFW-b
Graphics/UI/GLFW.hs
bsd-2-clause
-- | If the window is maximized or not. -- See <http://www.glfw.org/docs/3.3/group__window.html#gacccb29947ea4b16860ebef42c2cb9337 glfwGetWindowAttrib> getWindowMaximized :: Window -> IO Bool getWindowMaximized win = fromC `fmap` c'glfwGetWindowAttrib (toC win) c'GLFW_MAXIMIZED
282
getWindowMaximized :: Window -> IO Bool getWindowMaximized win = fromC `fmap` c'glfwGetWindowAttrib (toC win) c'GLFW_MAXIMIZED
130
getWindowMaximized win = fromC `fmap` c'glfwGetWindowAttrib (toC win) c'GLFW_MAXIMIZED
90
true
true
0
8
31
40
21
19
null
null
michalkonecny/polypaver
src/PolyPaver/Input/SPARK.hs
bsd-3-clause
--decodeFnAux _ "pp_exact__sin" [arg1] = sin arg1 --decodeFnAux _ "pp_exact__cos" [arg1] = cos arg1 decodeFnAux original "pp_exact__integral" args = decodeIntegral original args
177
decodeFnAux original "pp_exact__integral" args = decodeIntegral original args
77
decodeFnAux original "pp_exact__integral" args = decodeIntegral original args
77
true
false
0
5
21
20
10
10
null
null
wavewave/SLHAParser
lib/HEP/Parser/SLHAParser.hs
bsd-2-clause
comment :: Parser Comment comment = liftM Comment $ (:) <$> char '#' <*> fmap unpack (takeWhile (not.isEndl)) <* char '\n'
186
comment :: Parser Comment comment = liftM Comment $ (:) <$> char '#' <*> fmap unpack (takeWhile (not.isEndl)) <* char '\n'
185
comment = liftM Comment $ (:) <$> char '#' <*> fmap unpack (takeWhile (not.isEndl)) <* char '\n'
159
false
true
0
11
84
57
28
29
null
null
TomMD/ghc
compiler/prelude/PrelNames.hs
bsd-3-clause
ordClassName = clsQual gHC_CLASSES (fsLit "Ord") ordClassKey
69
ordClassName = clsQual gHC_CLASSES (fsLit "Ord") ordClassKey
69
ordClassName = clsQual gHC_CLASSES (fsLit "Ord") ordClassKey
69
false
false
0
7
15
19
9
10
null
null
shayan-najd/HsParser
U/Pretty.hs
gpl-3.0
-- --------------------------------------------------------------------------- -- @fill@ -- | \"Paragraph fill\" version of 'cat'. fcat :: [Doc] -> Doc fcat = fill False
170
fcat :: [Doc] -> Doc fcat = fill False
38
fcat = fill False
17
true
true
0
6
20
24
14
10
null
null
sgillespie/ghc
testsuite/tests/simplCore/should_compile/simpl003.hs
bsd-3-clause
mapI f (x:xs) = f x `thenI` ( \ fx -> mapI f xs `thenI` ( \ fxs -> returnI (fx:fxs) ))
148
mapI f (x:xs) = f x `thenI` ( \ fx -> mapI f xs `thenI` ( \ fxs -> returnI (fx:fxs) ))
148
mapI f (x:xs) = f x `thenI` ( \ fx -> mapI f xs `thenI` ( \ fxs -> returnI (fx:fxs) ))
148
false
false
0
13
83
64
35
29
null
null
mrehayden1/harmony
Console/Debug.hs
bsd-3-clause
putDebug :: String -> IO () putDebug msg = do en <- readIORef debug when en . putStrLn $ "Debug: " ++ msg
109
putDebug :: String -> IO () putDebug msg = do en <- readIORef debug when en . putStrLn $ "Debug: " ++ msg
109
putDebug msg = do en <- readIORef debug when en . putStrLn $ "Debug: " ++ msg
81
false
true
0
10
26
51
23
28
null
null
dysinger/amazonka
amazonka-opsworks/gen/Network/AWS/OpsWorks/CreateLayer.hs
mpl-2.0
-- | One or more user-defined key/value pairs to be added to the stack attributes. clAttributes :: Lens' CreateLayer (HashMap LayerAttributesKeys Text) clAttributes = lens _clAttributes (\s a -> s { _clAttributes = a }) . _Map
226
clAttributes :: Lens' CreateLayer (HashMap LayerAttributesKeys Text) clAttributes = lens _clAttributes (\s a -> s { _clAttributes = a }) . _Map
143
clAttributes = lens _clAttributes (\s a -> s { _clAttributes = a }) . _Map
74
true
true
0
10
36
52
28
24
null
null
runeksvendsen/rbpcp-handler
test/TstUtil.hs
bsd-3-clause
genServerSettings :: (PC.BtcAmount,PC.BtcAmount) -> Gen PC.ServerSettings genServerSettings (minOpenPrice, maxOpenPrice) = do arbOpenPrice <- choose (fromIntegral minOpenPrice, fromIntegral maxOpenPrice :: Word64) return PC.ServerSettings { PC.serverConfDustLimit = 6000 , PC.serverConfSettle...
469
genServerSettings :: (PC.BtcAmount,PC.BtcAmount) -> Gen PC.ServerSettings genServerSettings (minOpenPrice, maxOpenPrice) = do arbOpenPrice <- choose (fromIntegral minOpenPrice, fromIntegral maxOpenPrice :: Word64) return PC.ServerSettings { PC.serverConfDustLimit = 6000 , PC.serverConfSettle...
469
genServerSettings (minOpenPrice, maxOpenPrice) = do arbOpenPrice <- choose (fromIntegral minOpenPrice, fromIntegral maxOpenPrice :: Word64) return PC.ServerSettings { PC.serverConfDustLimit = 6000 , PC.serverConfSettlePeriod = PC.MkHour 12 , PC.serverConfMinDuration = PC.MkHour 48...
395
false
true
0
11
100
119
62
57
null
null
apyrgio/snf-ganeti
test/hs/Test/Ganeti/Utils.hs
bsd-2-clause
prop_parseUnit :: NonNegative Int -> Property prop_parseUnit (NonNegative n) = conjoin [ parseUnit (show n) ==? (Ok n::Result Int) , parseUnit (show n ++ "m") ==? (Ok n::Result Int) , parseUnit (show n ++ "M") ==? (Ok (truncate n_mb)::Result Int) , parseUnit (show n ++ "g") ==? (Ok (n*1024)::Result Int) , p...
788
prop_parseUnit :: NonNegative Int -> Property prop_parseUnit (NonNegative n) = conjoin [ parseUnit (show n) ==? (Ok n::Result Int) , parseUnit (show n ++ "m") ==? (Ok n::Result Int) , parseUnit (show n ++ "M") ==? (Ok (truncate n_mb)::Result Int) , parseUnit (show n ++ "g") ==? (Ok (n*1024)::Result Int) , p...
788
prop_parseUnit (NonNegative n) = conjoin [ parseUnit (show n) ==? (Ok n::Result Int) , parseUnit (show n ++ "m") ==? (Ok n::Result Int) , parseUnit (show n ++ "M") ==? (Ok (truncate n_mb)::Result Int) , parseUnit (show n ++ "g") ==? (Ok (n*1024)::Result Int) , parseUnit (show n ++ "G") ==? (Ok (truncate n_g...
742
false
true
2
13
174
402
201
201
null
null
gcross/LogicGrowsOnTrees
LogicGrowsOnTrees/benchmarks/tree-versus-list-bind.hs
bsd-2-clause
main :: IO () main = defaultMain [bgroup "list" [bench "unit" $ nf (getWordSum . mconcat . unitBindIt) depth ,bench "int" $ nf (getWordSum . mconcat . intBindIt) depth ] ,bgroup "tree" [bench "unit" $ nf (getWordSum . exploreTree . unitBindIt) depth ,bench "int" $ nf (get...
964
main :: IO () main = defaultMain [bgroup "list" [bench "unit" $ nf (getWordSum . mconcat . unitBindIt) depth ,bench "int" $ nf (getWordSum . mconcat . intBindIt) depth ] ,bgroup "tree" [bench "unit" $ nf (getWordSum . exploreTree . unitBindIt) depth ,bench "int" $ nf (get...
964
main = defaultMain [bgroup "list" [bench "unit" $ nf (getWordSum . mconcat . unitBindIt) depth ,bench "int" $ nf (getWordSum . mconcat . intBindIt) depth ] ,bgroup "tree" [bench "unit" $ nf (getWordSum . exploreTree . unitBindIt) depth ,bench "int" $ nf (getWordSum . expl...
950
false
true
1
14
258
293
144
149
null
null
drmaruyama/Paraiso
examples-old/HelloWorld/Hello.hs
bsd-3-clause
main :: IO () main = do _ <- system "mkdir -p output" T.writeFile "output/OM.txt" $ prettyPrintA1 $ myOM _ <- generateIO mySetup myOM return ()
151
main :: IO () main = do _ <- system "mkdir -p output" T.writeFile "output/OM.txt" $ prettyPrintA1 $ myOM _ <- generateIO mySetup myOM return ()
151
main = do _ <- system "mkdir -p output" T.writeFile "output/OM.txt" $ prettyPrintA1 $ myOM _ <- generateIO mySetup myOM return ()
137
false
true
0
11
33
68
28
40
null
null
raichoo/Idris-dev
src/IRTS/CodegenJavaScript.hs
bsd-3-clause
optimizeConstructors :: [JS] -> ([JS], [JS]) optimizeConstructors js = let (js', cons) = runState (traverse optimizeConstructor' js) M.empty in (map (allocCon . snd) (M.toList cons), js') where allocCon :: (String, JS) -> JS allocCon (name, con) = JSAlloc name (Just con) newConstructor :: Int...
1,778
optimizeConstructors :: [JS] -> ([JS], [JS]) optimizeConstructors js = let (js', cons) = runState (traverse optimizeConstructor' js) M.empty in (map (allocCon . snd) (M.toList cons), js') where allocCon :: (String, JS) -> JS allocCon (name, con) = JSAlloc name (Just con) newConstructor :: Int...
1,778
optimizeConstructors js = let (js', cons) = runState (traverse optimizeConstructor' js) M.empty in (map (allocCon . snd) (M.toList cons), js') where allocCon :: (String, JS) -> JS allocCon (name, con) = JSAlloc name (Just con) newConstructor :: Int -> String newConstructor n = "i$CON$" ++...
1,733
false
true
42
11
611
548
285
263
null
null
petejohanson/arachnid
src/Arachnid/Decisions.hs
mit
end :: (Resource a) => HTTP.Status -> a -> ResourceMonadResult DecisionNode end status = const $ return $ Left status
117
end :: (Resource a) => HTTP.Status -> a -> ResourceMonadResult DecisionNode end status = const $ return $ Left status
117
end status = const $ return $ Left status
41
false
true
0
8
19
47
23
24
null
null
meiersi-11ce/stack
src/Stack/Types/Package.hs
bsd-3-clause
-- | Get the module path. dotCabalModulePath :: DotCabalPath -> Maybe (Path Abs File) dotCabalModulePath (DotCabalModulePath fp) = Just fp
138
dotCabalModulePath :: DotCabalPath -> Maybe (Path Abs File) dotCabalModulePath (DotCabalModulePath fp) = Just fp
112
dotCabalModulePath (DotCabalModulePath fp) = Just fp
52
true
true
0
8
19
39
19
20
null
null