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
shayan-najd/QFeldspar
QFeldspar/Magic.hs
gpl-3.0
subs :: Env (SPair NG.Nat TG.Typ) s -> TG.Typ a -> TG.Typ (Subs s a) subs Emp a = a
92
subs :: Env (SPair NG.Nat TG.Typ) s -> TG.Typ a -> TG.Typ (Subs s a) subs Emp a = a
92
subs Emp a = a
23
false
true
4
8
28
66
28
38
null
null
davmre/matrizer
web/Application.hs
gpl-2.0
getAppSettings :: IO AppSettings getAppSettings = loadAppSettings [configSettingsYml] [] useEnv
95
getAppSettings :: IO AppSettings getAppSettings = loadAppSettings [configSettingsYml] [] useEnv
95
getAppSettings = loadAppSettings [configSettingsYml] [] useEnv
62
false
true
1
6
9
29
13
16
null
null
nevrenato/Hets_Fork
Taxonomy/OntoParser.hs
gpl-2.0
ontoDoc :: GenParser Char st [Frag] ontoDoc = do skip fs <- many (frag <?> "Fragment") eof return $ catMaybes fs
120
ontoDoc :: GenParser Char st [Frag] ontoDoc = do skip fs <- many (frag <?> "Fragment") eof return $ catMaybes fs
120
ontoDoc = do skip fs <- many (frag <?> "Fragment") eof return $ catMaybes fs
84
false
true
0
11
28
60
26
34
null
null
danr/hipspec
testsuite/prod/zeno_version/PropT38.hs
gpl-3.0
S x == S y = x == y
19
S x == S y = x == y
19
S x == S y = x == y
19
false
false
1
6
8
29
11
18
null
null
micknelso/language-c
src/Language/CFamily/C/TravMonad.hs
bsd-3-clause
-- | check wheter non-recoverable errors occurred hadHardErrors :: [CError] -> Bool hadHardErrors = (not . null . filter isHardError)
133
hadHardErrors :: [CError] -> Bool hadHardErrors = (not . null . filter isHardError)
83
hadHardErrors = (not . null . filter isHardError)
49
true
true
0
7
19
33
18
15
null
null
spechub/Hets
Comorphisms/CFOL2IsabelleHOL.hs
gpl-2.0
transVar :: Set.Set String -> VAR -> String transVar toks v = let s = showIsaConstT (simpleIdToId v) baseSign renVar t = if Set.member t toks then renVar $ "X_" ++ t else t in renVar s
196
transVar :: Set.Set String -> VAR -> String transVar toks v = let s = showIsaConstT (simpleIdToId v) baseSign renVar t = if Set.member t toks then renVar $ "X_" ++ t else t in renVar s
196
transVar toks v = let s = showIsaConstT (simpleIdToId v) baseSign renVar t = if Set.member t toks then renVar $ "X_" ++ t else t in renVar s
152
false
true
0
11
48
85
41
44
null
null
sdiehl/ghc
compiler/llvmGen/LlvmCodeGen/CodeGen.hs
bsd-3-clause
castVarsW :: Signage -> [(LlvmVar, LlvmType)] -> WriterT LlvmAccum LlvmM [LlvmVar] castVarsW signage vars = do (vars, stmts) <- lift $ castVars signage vars tell $ LlvmAccum stmts mempty return vars -- | Cast a collection of LLVM variables to specific types.
291
castVarsW :: Signage -> [(LlvmVar, LlvmType)] -> WriterT LlvmAccum LlvmM [LlvmVar] castVarsW signage vars = do (vars, stmts) <- lift $ castVars signage vars tell $ LlvmAccum stmts mempty return vars -- | Cast a collection of LLVM variables to specific types.
291
castVarsW signage vars = do (vars, stmts) <- lift $ castVars signage vars tell $ LlvmAccum stmts mempty return vars -- | Cast a collection of LLVM variables to specific types.
188
false
true
0
10
74
89
43
46
null
null
filib/ruby-marshal
src/Data/Ruby/Marshal/Encoding.hs
mit
toEnc "ISO-8859-14" = ISO_8859_14
48
toEnc "ISO-8859-14" = ISO_8859_14
48
toEnc "ISO-8859-14" = ISO_8859_14
48
false
false
0
5
18
9
4
5
null
null
acfoltzer/nbt
src/Data/NBT.hs
bsd-3-clause
getByType StringType = StringTag <$> getString
52
getByType StringType = StringTag <$> getString
52
getByType StringType = StringTag <$> getString
52
false
false
0
5
11
14
6
8
null
null
gibiansky/hlint
data/Default.hs
bsd-3-clause
error = hWaitForInput a 0 ==> hReady a
38
error = hWaitForInput a 0 ==> hReady a
38
error = hWaitForInput a 0 ==> hReady a
38
false
false
1
6
7
21
8
13
null
null
BartAdv/Idris-dev
src/Idris/CaseSplit.hs
bsd-3-clause
-- mapPT tidyVar tm -- where tidyVar (PRef _ _) = Placeholder -- tidyVar t = t elabNewPat :: PTerm -> Idris (Maybe PTerm) elabNewPat t = idrisCatch (do (tm, ty) <- elabVal recinfo ELHS t i <- getIState return (Just (delab i tm))) ...
486
elabNewPat :: PTerm -> Idris (Maybe PTerm) elabNewPat t = idrisCatch (do (tm, ty) <- elabVal recinfo ELHS t i <- getIState return (Just (delab i tm))) (\e -> do i <- getIState logLvl 5 $ "Not a vali...
396
elabNewPat t = idrisCatch (do (tm, ty) <- elabVal recinfo ELHS t i <- getIState return (Just (delab i tm))) (\e -> do i <- getIState logLvl 5 $ "Not a valid split:\n" ++ pshow i e ...
353
true
true
0
13
231
125
60
65
null
null
nickbart1980/pandoc
src/Text/Pandoc/Parsing.hs
gpl-2.0
emailAddress :: Parser [Char] st (String, String) emailAddress = try $ liftA2 toResult mailbox (char '@' *> domain) where toResult mbox dom = let full = fromEntities $ mbox ++ '@':dom in (full, escapeURI $ "mailto:" ++ full) mailbox = intercalate "." `fmap` (emailWord `sepb...
1,108
emailAddress :: Parser [Char] st (String, String) emailAddress = try $ liftA2 toResult mailbox (char '@' *> domain) where toResult mbox dom = let full = fromEntities $ mbox ++ '@':dom in (full, escapeURI $ "mailto:" ++ full) mailbox = intercalate "." `fmap` (emailWord `sepb...
1,108
emailAddress = try $ liftA2 toResult mailbox (char '@' *> domain) where toResult mbox dom = let full = fromEntities $ mbox ++ '@':dom in (full, escapeURI $ "mailto:" ++ full) mailbox = intercalate "." `fmap` (emailWord `sepby1` dot) domain = intercalate "....
1,058
false
true
0
13
355
289
154
135
null
null
Philonous/pontarius-xmpp-e2e
source/Pontarius/E2E/Serialize.hs
apache-2.0
putPubkey :: PubKey -> PutM () putPubkey (PubKey tp' dt) = do putData tp' putData dt
92
putPubkey :: PubKey -> PutM () putPubkey (PubKey tp' dt) = do putData tp' putData dt
92
putPubkey (PubKey tp' dt) = do putData tp' putData dt
61
false
true
0
7
23
43
19
24
null
null
SnipyJulmy/mcs_notes_and_resume
fun-and-log-prog/exercices/s03/s03.hs
lgpl-3.0
-- Ex1.b partitions :: [a] -> [[a]] partitions [] = [[]]
56
partitions :: [a] -> [[a]] partitions [] = [[]]
47
partitions [] = [[]]
20
true
true
0
7
10
39
21
18
null
null
roberth/uu-helium
lib/Prelude.hs
gpl-3.0
foldl' :: (a -> b -> a) -> a -> [b] -> a foldl' _ a [] = a
72
foldl' :: (a -> b -> a) -> a -> [b] -> a foldl' _ a [] = a
72
foldl' _ a [] = a
21
false
true
0
8
32
46
24
22
null
null
konn/pandoc-japanese-filters
japanese-filter.hs
gpl-2.0
inlify :: Pandoc -> [Inline] inlify (Pandoc _ bs0) = concatMap go bs0 where go (Plain is) = is go (Para is) = is go (RawBlock _ _) = [] go (CodeBlock _ _) = [] go (BlockQuote bs) = concatMap go bs go (BulletList bs) = concatMap (concatMap go) bs go (OrderedList _ bs) = concatMap (concatMap...
552
inlify :: Pandoc -> [Inline] inlify (Pandoc _ bs0) = concatMap go bs0 where go (Plain is) = is go (Para is) = is go (RawBlock _ _) = [] go (CodeBlock _ _) = [] go (BlockQuote bs) = concatMap go bs go (BulletList bs) = concatMap (concatMap go) bs go (OrderedList _ bs) = concatMap (concatMap...
552
inlify (Pandoc _ bs0) = concatMap go bs0 where go (Plain is) = is go (Para is) = is go (RawBlock _ _) = [] go (CodeBlock _ _) = [] go (BlockQuote bs) = concatMap go bs go (BulletList bs) = concatMap (concatMap go) bs go (OrderedList _ bs) = concatMap (concatMap go) bs go (DefinitionLis...
523
false
true
0
11
160
303
150
153
null
null
L31R0FF/Perso
haskell/minijeu.hs
gpl-2.0
main = preludejeu
17
main = preludejeu
17
main = preludejeu
17
false
false
1
5
2
10
3
7
null
null
GaloisInc/HaNS
src/Hans/Dns/Packet.hs
bsd-3-clause
labelsToName :: [Label] -> Name labelsToName = F.foldMap toName where toName (Label _ l) = [l] toName (Ptr _ n) = n
124
labelsToName :: [Label] -> Name labelsToName = F.foldMap toName where toName (Label _ l) = [l] toName (Ptr _ n) = n
124
labelsToName = F.foldMap toName where toName (Label _ l) = [l] toName (Ptr _ n) = n
92
false
true
0
7
30
61
31
30
null
null
ssaavedra/liquidhaskell
benchmarks/esop2013-submission/Splay.hs
bsd-3-clause
--LIQUID FIXME: renamed from `showSet'`, must fix parser! {-@ Decrease showSet_go 3 @-} showSet_go :: Show a => String -> Splay a -> String showSet_go _ Leaf = "\n"
165
showSet_go :: Show a => String -> Splay a -> String showSet_go _ Leaf = "\n"
76
showSet_go _ Leaf = "\n"
24
true
true
0
8
29
36
18
18
null
null
arow-oss/arow-sample-webapp
src/App/Db.hs
bsd-3-clause
dbAddCompanyUser :: Text -> Text -> Text -> ReaderT SqlBackend AppM (Maybe (Key CompanyUser)) dbAddCompanyUser email pass name = do hash <- hashPassword pass insertUnique $ CompanyUser email hash name
206
dbAddCompanyUser :: Text -> Text -> Text -> ReaderT SqlBackend AppM (Maybe (Key CompanyUser)) dbAddCompanyUser email pass name = do hash <- hashPassword pass insertUnique $ CompanyUser email hash name
206
dbAddCompanyUser email pass name = do hash <- hashPassword pass insertUnique $ CompanyUser email hash name
110
false
true
0
12
35
77
35
42
null
null
oldmanmike/ghc
compiler/prelude/PrelNames.hs
bsd-3-clause
eqTyConKey = mkPreludeTyConUnique 38
65
eqTyConKey = mkPreludeTyConUnique 38
65
eqTyConKey = mkPreludeTyConUnique 38
65
false
false
0
5
32
9
4
5
null
null
deynekalex/Money-Haskell-Project-
src/Utils.hs
gpl-2.0
deleteByPos :: Int -> Update ItemList () deleteByPos pos = do ItemList ns <- get put (ItemList (take (pos - 1) ns ++ drop (pos + 1) ns))
144
deleteByPos :: Int -> Update ItemList () deleteByPos pos = do ItemList ns <- get put (ItemList (take (pos - 1) ns ++ drop (pos + 1) ns))
144
deleteByPos pos = do ItemList ns <- get put (ItemList (take (pos - 1) ns ++ drop (pos + 1) ns))
103
false
true
0
15
35
83
38
45
null
null
fmapfmapfmap/amazonka
amazonka-opsworks/gen/Network/AWS/OpsWorks/CloneStack.hs
mpl-2.0
-- | The default AWS OpsWorks agent version. You have the following options: -- -- - Auto-update - Set this parameter to 'LATEST'. AWS OpsWorks -- automatically installs new agent versions on the stack\'s instances -- as soon as they are available. -- - Fixed version - Set this parameter to your preferred a...
1,020
cAgentVersion :: Lens' CloneStack (Maybe Text) cAgentVersion = lens _cAgentVersion (\ s a -> s{_cAgentVersion = a})
115
cAgentVersion = lens _cAgentVersion (\ s a -> s{_cAgentVersion = a})
68
true
true
0
9
188
62
41
21
null
null
rueshyna/gogol
gogol-identity-toolkit/gen/Network/Google/IdentityToolkit/Types/Product.hs
mpl-2.0
-- | GCP project number of the requesting delegated app. Currently only -- intended for Firebase V1 migration. irpuarDelegatedProjectNumber :: Lens' IdentitytoolkitRelyingPartyUploadAccountRequest (Maybe Int64) irpuarDelegatedProjectNumber = lens _irpuarDelegatedProjectNumber (\ s a -> s{_irpuarDelegatedProject...
356
irpuarDelegatedProjectNumber :: Lens' IdentitytoolkitRelyingPartyUploadAccountRequest (Maybe Int64) irpuarDelegatedProjectNumber = lens _irpuarDelegatedProjectNumber (\ s a -> s{_irpuarDelegatedProjectNumber = a}) . mapping _Coerce
245
irpuarDelegatedProjectNumber = lens _irpuarDelegatedProjectNumber (\ s a -> s{_irpuarDelegatedProjectNumber = a}) . mapping _Coerce
145
true
true
1
8
51
59
29
30
null
null
DavidAlphaFox/ghc
libraries/Cabal/Cabal/Distribution/Package.hs
bsd-3-clause
thisPackageVersion :: PackageIdentifier -> Dependency thisPackageVersion (PackageIdentifier n v) = Dependency n (thisVersion v)
129
thisPackageVersion :: PackageIdentifier -> Dependency thisPackageVersion (PackageIdentifier n v) = Dependency n (thisVersion v)
129
thisPackageVersion (PackageIdentifier n v) = Dependency n (thisVersion v)
75
false
true
0
7
15
37
18
19
null
null
sinelaw/lamdu
test/Utils.hs
gpl-3.0
showInferred :: ExprIRef.Expression t Infer.IsRestrictedPoly -> String showInferred = show . showRestricted . simplifyDef . canonizeDebug
139
showInferred :: ExprIRef.Expression t Infer.IsRestrictedPoly -> String showInferred = show . showRestricted . simplifyDef . canonizeDebug
139
showInferred = show . showRestricted . simplifyDef . canonizeDebug
68
false
true
0
7
17
36
18
18
null
null
joelburget/haste-compiler
src/Data/JSTarget/Constructors.hs
bsd-3-clause
-- | Create a tail call. tailcall :: AST Exp -> AST Stm tailcall call = Tailcall <$> call
89
tailcall :: AST Exp -> AST Stm tailcall call = Tailcall <$> call
64
tailcall call = Tailcall <$> call
33
true
true
0
7
18
34
15
19
null
null
mcmaniac/ghc
compiler/llvmGen/LlvmCodeGen/CodeGen.hs
bsd-3-clause
genCall env t@(CmmPrim (MO_PopCnt w)) [CmmHinted dst _] args _ = do let width = widthToLlvmInt w dstTy = cmmToLlvmType $ localRegType dst funTy = \n -> LMFunction $ LlvmFunctionDecl n ExternallyVisible CC_Ccc width FixedArgs (tysToParams [width]) Nothing (env1, dstV...
1,022
genCall env t@(CmmPrim (MO_PopCnt w)) [CmmHinted dst _] args _ = do let width = widthToLlvmInt w dstTy = cmmToLlvmType $ localRegType dst funTy = \n -> LMFunction $ LlvmFunctionDecl n ExternallyVisible CC_Ccc width FixedArgs (tysToParams [width]) Nothing (env1, dstV...
1,022
genCall env t@(CmmPrim (MO_PopCnt w)) [CmmHinted dst _] args _ = do let width = widthToLlvmInt w dstTy = cmmToLlvmType $ localRegType dst funTy = \n -> LMFunction $ LlvmFunctionDecl n ExternallyVisible CC_Ccc width FixedArgs (tysToParams [width]) Nothing (env1, dstV...
1,022
false
false
0
15
300
364
195
169
null
null
flyingleafe/parser-gen
src/Grammar.hs
bsd-3-clause
regexLiteral = tokenIf isRegexLiteral where isRegexLiteral (RegexLiteral _) = True isRegexLiteral _ = False
121
regexLiteral = tokenIf isRegexLiteral where isRegexLiteral (RegexLiteral _) = True isRegexLiteral _ = False
121
regexLiteral = tokenIf isRegexLiteral where isRegexLiteral (RegexLiteral _) = True isRegexLiteral _ = False
121
false
false
1
7
27
38
16
22
null
null
ribag/ganeti-experiments
src/Ganeti/Constants.hs
gpl-2.0
drbdBDiskDrain :: String drbdBDiskDrain = "d"
45
drbdBDiskDrain :: String drbdBDiskDrain = "d"
45
drbdBDiskDrain = "d"
20
false
true
0
4
5
11
6
5
null
null
a143753/AOJ
0565.hs
apache-2.0
main = do c <- getContents let i = map read $ lines c :: [Int] o = ans i print o
92
main = do c <- getContents let i = map read $ lines c :: [Int] o = ans i print o
92
main = do c <- getContents let i = map read $ lines c :: [Int] o = ans i print o
92
false
false
1
12
33
56
24
32
null
null
urbanslug/ghc
compiler/prelude/TysWiredIn.hs
bsd-3-clause
pcDataCon :: Name -> [TyVar] -> [Type] -> TyCon -> DataCon pcDataCon = pcDataConWithFixity False
96
pcDataCon :: Name -> [TyVar] -> [Type] -> TyCon -> DataCon pcDataCon = pcDataConWithFixity False
96
pcDataCon = pcDataConWithFixity False
37
false
true
0
10
14
43
20
23
null
null
yav/haskell-lexer
generator/src/Spec/HaskellLexicalSyntax.hs
mit
qvarsym = qual & varsym
23
qvarsym = qual & varsym
23
qvarsym = qual & varsym
23
false
false
1
5
4
13
5
8
null
null
MichielDeCuyper/Algebraic-Effect-Handlers
src/Effect/Error.hs
mit
algError :: TermMonad m f => Error e (m (Either e a)) -> m (Either e a) algError (Throw e) = var (Left e)
105
algError :: TermMonad m f => Error e (m (Either e a)) -> m (Either e a) algError (Throw e) = var (Left e)
105
algError (Throw e) = var (Left e)
33
false
true
0
12
23
76
35
41
null
null
akc/sym
tests/ListStat.hs
bsd-3-clause
comaj w = sum [ n-i | (i,x,y) <- zip3 [1..] w (tail w), x > y ] where n = length w
82
comaj w = sum [ n-i | (i,x,y) <- zip3 [1..] w (tail w), x > y ] where n = length w
82
comaj w = sum [ n-i | (i,x,y) <- zip3 [1..] w (tail w), x > y ] where n = length w
82
false
false
0
11
22
70
36
34
null
null
sordina/purewars
Main.hs
bsd-3-clause
initGL :: IO () initGL = do GL.clearColor $= GL.Color4 0 0 0 0 GL.shadeModel $= GL.Flat GL.depthFunc $= Nothing
117
initGL :: IO () initGL = do GL.clearColor $= GL.Color4 0 0 0 0 GL.shadeModel $= GL.Flat GL.depthFunc $= Nothing
117
initGL = do GL.clearColor $= GL.Color4 0 0 0 0 GL.shadeModel $= GL.Flat GL.depthFunc $= Nothing
101
false
true
1
9
25
60
26
34
null
null
wavewave/hoodle-types
src/Data/Hoodle/Zipper.hs
bsd-2-clause
moveTo :: Int -> SeqZipper a -> Maybe (SeqZipper a) moveTo n orig@(SZ (x,(x1s,x2s))) = let n_x1s = length x1s n_x2s = length x2s res | n < 0 || n > n_x1s + n_x2s = Nothing | n == n_x1s = Just orig | n < n_x1s = let (x1s1, x1s2) = splitAt n x1s el :< r...
642
moveTo :: Int -> SeqZipper a -> Maybe (SeqZipper a) moveTo n orig@(SZ (x,(x1s,x2s))) = let n_x1s = length x1s n_x2s = length x2s res | n < 0 || n > n_x1s + n_x2s = Nothing | n == n_x1s = Just orig | n < n_x1s = let (x1s1, x1s2) = splitAt n x1s el :< rm...
641
moveTo n orig@(SZ (x,(x1s,x2s))) = let n_x1s = length x1s n_x2s = length x2s res | n < 0 || n > n_x1s + n_x2s = Nothing | n == n_x1s = Just orig | n < n_x1s = let (x1s1, x1s2) = splitAt n x1s el :< rm = viewl x1s2 in Just (SZ (e...
589
false
true
35
12
273
290
156
134
null
null
fpco/fpco-cereal
tests/GetTests.hs
bsd-3-clause
mkChunks :: Word -> Chunks mkChunks n = Chunks . take (fromIntegral n) $ cycle [ [x] | x <- [0 .. 255] ]
104
mkChunks :: Word -> Chunks mkChunks n = Chunks . take (fromIntegral n) $ cycle [ [x] | x <- [0 .. 255] ]
104
mkChunks n = Chunks . take (fromIntegral n) $ cycle [ [x] | x <- [0 .. 255] ]
77
false
true
0
10
23
58
30
28
null
null
ml9951/ghc
libraries/pastm/examples/damp-comparing-linked-lists/StraightForwardSTM.hs
bsd-3-clause
addToTail :: ListHandle a -> a -> IO () addToTail (ListHandle {tailList = tailPtrPtr}) x = do tPtr <- atomically ( do null <- newTVar Null tailPtr <- readTVar tailPtrPtr writeTVar tailPtr (Node {val = x, next = null}) writeTVar tailPtrPtr null ...
363
addToTail :: ListHandle a -> a -> IO () addToTail (ListHandle {tailList = tailPtrPtr}) x = do tPtr <- atomically ( do null <- newTVar Null tailPtr <- readTVar tailPtrPtr writeTVar tailPtr (Node {val = x, next = null}) writeTVar tailPtrPtr null ...
363
addToTail (ListHandle {tailList = tailPtrPtr}) x = do tPtr <- atomically ( do null <- newTVar Null tailPtr <- readTVar tailPtrPtr writeTVar tailPtr (Node {val = x, next = null}) writeTVar tailPtrPtr null return() ) return t...
323
false
true
3
16
142
128
58
70
null
null
luigy/stack
src/main/Main.hs
bsd-3-clause
dockerResetCmd :: Bool -> GlobalOpts -> IO () dockerResetCmd keepHome go@GlobalOpts{..} = do (manager,lc) <- liftIO (loadConfigWithOpts go) -- TODO: can we eliminate this lock if it doesn't touch ~/.stack/? withUserFileLock go (configStackRoot $ lcConfig lc) $ \_ -> runStackTGlobal manager (lcConfig l...
448
dockerResetCmd :: Bool -> GlobalOpts -> IO () dockerResetCmd keepHome go@GlobalOpts{..} = do (manager,lc) <- liftIO (loadConfigWithOpts go) -- TODO: can we eliminate this lock if it doesn't touch ~/.stack/? withUserFileLock go (configStackRoot $ lcConfig lc) $ \_ -> runStackTGlobal manager (lcConfig l...
448
dockerResetCmd keepHome go@GlobalOpts{..} = do (manager,lc) <- liftIO (loadConfigWithOpts go) -- TODO: can we eliminate this lock if it doesn't touch ~/.stack/? withUserFileLock go (configStackRoot $ lcConfig lc) $ \_ -> runStackTGlobal manager (lcConfig lc) go $ Docker.preventInContainer $ Do...
402
false
true
0
13
84
125
62
63
null
null
rahulmutt/ghcvm
compiler/Eta/DeSugar/Coverage.hs
bsd-3-clause
addTickLHsExprLetBody :: LHsExpr Id -> TM (LHsExpr Id) addTickLHsExprLetBody e@(L pos e0) = do d <- getDensity case d of TickForBreakPoints | HsLet{} <- e0 -> dont_tick_it | otherwise -> tick_it _other -> addTickLHsExprEvalInner e where tick_it = allocTickBox (ExpBox F...
530
addTickLHsExprLetBody :: LHsExpr Id -> TM (LHsExpr Id) addTickLHsExprLetBody e@(L pos e0) = do d <- getDensity case d of TickForBreakPoints | HsLet{} <- e0 -> dont_tick_it | otherwise -> tick_it _other -> addTickLHsExprEvalInner e where tick_it = allocTickBox (ExpBox F...
530
addTickLHsExprLetBody e@(L pos e0) = do d <- getDensity case d of TickForBreakPoints | HsLet{} <- e0 -> dont_tick_it | otherwise -> tick_it _other -> addTickLHsExprEvalInner e where tick_it = allocTickBox (ExpBox False) False False pos $ addTickHsExpr e0 dont_tick_i...
475
false
true
0
14
129
134
64
70
null
null
niilohlin/neural
neural2.hs
apache-2.0
diomgis t = log((-t)/(t - 1))
29
diomgis t = log((-t)/(t - 1))
29
diomgis t = log((-t)/(t - 1))
29
false
false
0
9
5
31
16
15
null
null
brendanhay/gogol
gogol-accessapproval/gen/Network/Google/Resource/AccessApproval/Folders/UpdateAccessApprovalSettings.hs
mpl-2.0
-- | Creates a value of 'FoldersUpdateAccessApprovalSettings' with the minimum fields required to make a request. -- -- Use one of the following lenses to modify other fields as desired: -- -- * 'fuaasXgafv' -- -- * 'fuaasUploadProtocol' -- -- * 'fuaasUpdateMask' -- -- * 'fuaasAccessToken' -- -- * 'fuaasUploadType' -- ...
915
foldersUpdateAccessApprovalSettings :: AccessApprovalSettings -- ^ 'fuaasPayload' -> Text -- ^ 'fuaasName' -> FoldersUpdateAccessApprovalSettings foldersUpdateAccessApprovalSettings pFuaasPayload_ pFuaasName_ = FoldersUpdateAccessApprovalSettings' { _fuaasXgafv = Nothing , _fuaasUploadProtocol = N...
531
foldersUpdateAccessApprovalSettings pFuaasPayload_ pFuaasName_ = FoldersUpdateAccessApprovalSettings' { _fuaasXgafv = Nothing , _fuaasUploadProtocol = Nothing , _fuaasUpdateMask = Nothing , _fuaasAccessToken = Nothing , _fuaasUploadType = Nothing , _fuaasPayload = pFuaasPayload_ , _fuaasNa...
373
true
true
0
8
162
104
68
36
null
null
ezyang/ghc
compiler/nativeGen/PPC/Ppr.hs
bsd-3-clause
pprInstr (SUBFE reg1 reg2 reg3) = pprLogic (sLit "subfe") reg1 reg2 (RIReg reg3)
80
pprInstr (SUBFE reg1 reg2 reg3) = pprLogic (sLit "subfe") reg1 reg2 (RIReg reg3)
80
pprInstr (SUBFE reg1 reg2 reg3) = pprLogic (sLit "subfe") reg1 reg2 (RIReg reg3)
80
false
false
0
7
12
40
19
21
null
null
creichert/wai
warp/Network/Wai/Handler/Warp/HTTP2/Types.hs
mit
isOpen _ = False
21
isOpen _ = False
21
isOpen _ = False
21
false
false
0
5
8
9
4
5
null
null
cliffano/swaggy-jenkins
clients/haskell-http-client/generated/lib/SwaggyJenkins/ModelLens.hs
mit
-- | 'branchImplWeatherScore' Lens branchImplWeatherScoreL :: Lens_' BranchImpl (Maybe Int) branchImplWeatherScoreL f BranchImpl{..} = (\branchImplWeatherScore -> BranchImpl { branchImplWeatherScore, ..} ) <$> f branchImplWeatherScore
234
branchImplWeatherScoreL :: Lens_' BranchImpl (Maybe Int) branchImplWeatherScoreL f BranchImpl{..} = (\branchImplWeatherScore -> BranchImpl { branchImplWeatherScore, ..} ) <$> f branchImplWeatherScore
199
branchImplWeatherScoreL f BranchImpl{..} = (\branchImplWeatherScore -> BranchImpl { branchImplWeatherScore, ..} ) <$> f branchImplWeatherScore
142
true
true
1
8
23
61
30
31
null
null
ggreif/language-make
src/Language/Makefile/Expansion.hs
bsd-2-clause
expansion ('$':(closing -> Just p):cs) (expansion cs . (p:) -> eater) = dup collapse eater
90
expansion ('$':(closing -> Just p):cs) (expansion cs . (p:) -> eater) = dup collapse eater
90
expansion ('$':(closing -> Just p):cs) (expansion cs . (p:) -> eater) = dup collapse eater
90
false
false
0
11
14
55
28
27
null
null
dag/kibr
src/Data/Lens/Reader.hs
bsd-2-clause
askL :: MonadReader r m => Lens r a -> m a askL = asks . getL
61
askL :: MonadReader r m => Lens r a -> m a askL = asks . getL
61
askL = asks . getL
18
false
true
0
7
16
36
17
19
null
null
romanb/amazonka
amazonka-ec2/gen/Network/AWS/EC2/Types.hs
mpl-2.0
-- | The device index of the network interface attachment on the instance. niaDeviceIndex :: Lens' NetworkInterfaceAttachment (Maybe Int) niaDeviceIndex = lens _niaDeviceIndex (\s a -> s { _niaDeviceIndex = a })
211
niaDeviceIndex :: Lens' NetworkInterfaceAttachment (Maybe Int) niaDeviceIndex = lens _niaDeviceIndex (\s a -> s { _niaDeviceIndex = a })
136
niaDeviceIndex = lens _niaDeviceIndex (\s a -> s { _niaDeviceIndex = a })
73
true
true
1
9
31
51
25
26
null
null
christiaanb/clash
clash/CLasH/VHDL/VHDLTools.hs
bsd-3-clause
----------------------------------------------------------------------------- -- Functions dealing with VHDL types ----------------------------------------------------------------------------- builtin_types :: TypeMap builtin_types = Map.fromList [ (BuiltinType "Bit", Just (std_logicTM, Nothing)), (BuiltinTy...
382
builtin_types :: TypeMap builtin_types = Map.fromList [ (BuiltinType "Bit", Just (std_logicTM, Nothing)), (BuiltinType "Bool", Just (booleanTM, Nothing)) -- TysWiredIn.boolTy ]
189
builtin_types = Map.fromList [ (BuiltinType "Bit", Just (std_logicTM, Nothing)), (BuiltinType "Bool", Just (booleanTM, Nothing)) -- TysWiredIn.boolTy ]
164
true
true
0
9
40
62
36
26
null
null
ambiata/highlighting-kate
Text/Highlighting/Kate/Syntax/Idris.hs
gpl-2.0
regex_0'5bXx'5d'5b0'2d9A'2dFa'2df'5d'2b = compileRegex True "0[Xx][0-9A-Fa-f]+"
79
regex_0'5bXx'5d'5b0'2d9A'2dFa'2df'5d'2b = compileRegex True "0[Xx][0-9A-Fa-f]+"
79
regex_0'5bXx'5d'5b0'2d9A'2dFa'2df'5d'2b = compileRegex True "0[Xx][0-9A-Fa-f]+"
79
false
false
0
5
4
11
5
6
null
null
sdiehl/ghc
compiler/coreSyn/CoreSyn.hs
bsd-3-clause
mkOtherCon :: [AltCon] -> Unfolding mkOtherCon = OtherCon
57
mkOtherCon :: [AltCon] -> Unfolding mkOtherCon = OtherCon
57
mkOtherCon = OtherCon
21
false
true
0
7
7
25
11
14
null
null
uProxy/uproxy-idl-compiler
Parse/Pretty.hs
apache-2.0
typeArguments :: [Type] -> Doc typeArguments ts = char '<' <+> commaSep _type ts <+> char '>'
93
typeArguments :: [Type] -> Doc typeArguments ts = char '<' <+> commaSep _type ts <+> char '>'
93
typeArguments ts = char '<' <+> commaSep _type ts <+> char '>'
62
false
true
0
7
16
40
19
21
null
null
przembot/osm-conduit
test/Spec.hs
bsd-3-clause
testCase01 :: Monad m => Source m Text testCase01 = CL.sourceList [xmlPrefix , "<osm version=\"0.6\" generator=\"lulz generator\">" , "<node id=\"43221\" lat=\"52.153\" lon=\"22.341\" visible=\"true\">" , "<tag k=\"shop\" v=\"alcohol\" />" , "<tag k=\"area\" v=\"safe\" />" , "</nod...
348
testCase01 :: Monad m => Source m Text testCase01 = CL.sourceList [xmlPrefix , "<osm version=\"0.6\" generator=\"lulz generator\">" , "<node id=\"43221\" lat=\"52.153\" lon=\"22.341\" visible=\"true\">" , "<tag k=\"shop\" v=\"alcohol\" />" , "<tag k=\"area\" v=\"safe\" />" , "</nod...
348
testCase01 = CL.sourceList [xmlPrefix , "<osm version=\"0.6\" generator=\"lulz generator\">" , "<node id=\"43221\" lat=\"52.153\" lon=\"22.341\" visible=\"true\">" , "<tag k=\"shop\" v=\"alcohol\" />" , "<tag k=\"area\" v=\"safe\" />" , "</node>" , "</osm>" ]
309
false
true
0
6
87
49
27
22
null
null
Kyle-Ferguson/COP-4020
Assignment 2/Hep.hs
gpl-3.0
hep ("by":"the":"way":xs) = "btw":(hep xs)
42
hep ("by":"the":"way":xs) = "btw":(hep xs)
42
hep ("by":"the":"way":xs) = "btw":(hep xs)
42
false
false
2
8
4
38
17
21
null
null
massysett/penny
penny/lib/Penny/Copper/Formatter.hs
bsd-3-clause
precedeCommentBlocksWithBlankLine :: FileItemP'Star Char () -> FileItemP'Star Char () precedeCommentBlocksWithBlankLine (FileItemP'Star sq) = FileItemP'Star . groupsToFileItems . addWhitespaceBeforeCommentGroups . SeqUtil.groupEithers . fmap splitFileItem $ sq
276
precedeCommentBlocksWithBlankLine :: FileItemP'Star Char () -> FileItemP'Star Char () precedeCommentBlocksWithBlankLine (FileItemP'Star sq) = FileItemP'Star . groupsToFileItems . addWhitespaceBeforeCommentGroups . SeqUtil.groupEithers . fmap splitFileItem $ sq
276
precedeCommentBlocksWithBlankLine (FileItemP'Star sq) = FileItemP'Star . groupsToFileItems . addWhitespaceBeforeCommentGroups . SeqUtil.groupEithers . fmap splitFileItem $ sq
186
false
true
6
9
40
73
31
42
null
null
olsner/ghc
compiler/cmm/SMRep.hs
bsd-3-clause
nonHdrSizeW (ArrayWordsRep words) = words
41
nonHdrSizeW (ArrayWordsRep words) = words
41
nonHdrSizeW (ArrayWordsRep words) = words
41
false
false
0
6
4
16
7
9
null
null
andreagenso/java2scala
src/J2s/Ast/Semantic.hs
apache-2.0
sem_BlockStatement_BlockStatementStatement = BlockStatementStatement
68
sem_BlockStatement_BlockStatementStatement = BlockStatementStatement
68
sem_BlockStatement_BlockStatementStatement = BlockStatementStatement
68
false
false
0
4
2
6
3
3
null
null
mcschroeder/ghc
compiler/main/HscMain.hs
bsd-3-clause
hscCompileCoreExpr :: HscEnv -> SrcSpan -> CoreExpr -> IO ForeignHValue hscCompileCoreExpr hsc_env = lookupHook hscCompileCoreExprHook hscCompileCoreExpr' (hsc_dflags hsc_env) hsc_env
185
hscCompileCoreExpr :: HscEnv -> SrcSpan -> CoreExpr -> IO ForeignHValue hscCompileCoreExpr hsc_env = lookupHook hscCompileCoreExprHook hscCompileCoreExpr' (hsc_dflags hsc_env) hsc_env
185
hscCompileCoreExpr hsc_env = lookupHook hscCompileCoreExprHook hscCompileCoreExpr' (hsc_dflags hsc_env) hsc_env
113
false
true
0
8
20
44
21
23
null
null
NickAger/LearningHaskell
HaskellProgrammingFromFirstPrinciples/Chapter8.hsproj/Chapter8.hs
mit
digitToWord 8 = "eight"
23
digitToWord 8 = "eight"
23
digitToWord 8 = "eight"
23
false
false
1
5
3
13
4
9
null
null
oisdk/Expr
expr-playgrounds/src/Numeric/Expr/Parse.hs
bsd-3-clause
opStyle, funcStyle :: (Monad m, TokenParsing m) => IdentifierStyle m opStyle = IdentifierStyle "operator" ops ops (fromList ["+", "-", "^", "*", "/", "%", "÷", "//"]) ReservedOperator ReservedOperator where ops = oneOf "+-^*/%÷"
256
opStyle, funcStyle :: (Monad m, TokenParsing m) => IdentifierStyle m opStyle = IdentifierStyle "operator" ops ops (fromList ["+", "-", "^", "*", "/", "%", "÷", "//"]) ReservedOperator ReservedOperator where ops = oneOf "+-^*/%÷"
256
opStyle = IdentifierStyle "operator" ops ops (fromList ["+", "-", "^", "*", "/", "%", "÷", "//"]) ReservedOperator ReservedOperator where ops = oneOf "+-^*/%÷"
187
false
true
0
7
59
90
47
43
null
null
jimgiven/smallProjects
miscHaskell/h99/H1120.hs
mit
--Problem 13: Direct Run-Length Encodings internalMyDirectEncode :: (Eq a) => [a] -> EncodeValue a -> [EncodeValue a] internalMyDirectEncode [] ev = [ev]
153
internalMyDirectEncode :: (Eq a) => [a] -> EncodeValue a -> [EncodeValue a] internalMyDirectEncode [] ev = [ev]
111
internalMyDirectEncode [] ev = [ev]
35
true
true
0
9
21
51
27
24
null
null
CompSciCabal/SMRTYPRTY
paip/pete/ch6/Search.hs
unlicense
diff :: Integer -> Integer -> Integer diff a b = abs (a-b)
58
diff :: Integer -> Integer -> Integer diff a b = abs (a-b)
58
diff a b = abs (a-b)
20
false
true
0
8
12
40
18
22
null
null
alexeyzab/cards-with-comrades
backend/src/Application.hs
gpl-3.0
db :: ReaderT SqlBackend (HandlerT App IO) a -> IO a db = handler . runDB
73
db :: ReaderT SqlBackend (HandlerT App IO) a -> IO a db = handler . runDB
73
db = handler . runDB
20
false
true
0
9
15
43
19
24
null
null
serokell/importify
test/test-data/base@basic/30-ListImplicitUsed.hs
mit
foo = sort
10
foo = sort
10
foo = sort
10
false
false
1
5
2
10
3
7
null
null
cernat-catalin/haskellGame
src/GMainLoop/Server.hs
bsd-3-clause
updateWorld :: Server -> IO World updateWorld server@Server{..} = join $ atomically $ do emptyChan <- isEmptyTChan worldChan if not emptyChan then do message <- readTChan worldChan return $ do let world' = execState (processMessage message) world updateWorld server { world = ...
366
updateWorld :: Server -> IO World updateWorld server@Server{..} = join $ atomically $ do emptyChan <- isEmptyTChan worldChan if not emptyChan then do message <- readTChan worldChan return $ do let world' = execState (processMessage message) world updateWorld server { world = ...
366
updateWorld server@Server{..} = join $ atomically $ do emptyChan <- isEmptyTChan worldChan if not emptyChan then do message <- readTChan worldChan return $ do let world' = execState (processMessage message) world updateWorld server { world = world' } else do return ...
332
false
true
15
7
103
102
55
47
null
null
gleachkr/Carnap
Carnap-GHCJS/src/Carnap/GHCJS/Action/TruthTable.hs
gpl-3.0
traverseBPT (MonNode f a) = [Right f] ++ traverseBPT a
54
traverseBPT (MonNode f a) = [Right f] ++ traverseBPT a
54
traverseBPT (MonNode f a) = [Right f] ++ traverseBPT a
54
false
false
0
7
9
30
14
16
null
null
pparkkin/eta
compiler/ETA/Rename/RnBinds.hs
bsd-3-clause
renameSig ctxt sig@(PatSynSig v (flag, qtvs) prov req ty) = do { v' <- lookupSigOccRn ctxt sig v ; let doc = TypeSigCtx $ quotes (ppr v) ; loc <- getSrcSpanM ; let (tv_kvs, mentioned) = extractHsTysRdrTyVars (ty:unLoc prov ++ unLoc req) ; tv_bndrs <- case flag of Implicit...
1,057
renameSig ctxt sig@(PatSynSig v (flag, qtvs) prov req ty) = do { v' <- lookupSigOccRn ctxt sig v ; let doc = TypeSigCtx $ quotes (ppr v) ; loc <- getSrcSpanM ; let (tv_kvs, mentioned) = extractHsTysRdrTyVars (ty:unLoc prov ++ unLoc req) ; tv_bndrs <- case flag of Implicit...
1,057
renameSig ctxt sig@(PatSynSig v (flag, qtvs) prov req ty) = do { v' <- lookupSigOccRn ctxt sig v ; let doc = TypeSigCtx $ quotes (ppr v) ; loc <- getSrcSpanM ; let (tv_kvs, mentioned) = extractHsTysRdrTyVars (ty:unLoc prov ++ unLoc req) ; tv_bndrs <- case flag of Implicit...
1,057
false
false
0
19
371
359
181
178
null
null
rueshyna/gogol
gogol-admin-reports/gen/Network/Google/Reports/Types.hs
mpl-2.0
-- | View audit reports of Google Apps for your domain adminReportsAuditReadOnlyScope :: Proxy '["https://www.googleapis.com/auth/admin.reports.audit.readonly"] adminReportsAuditReadOnlyScope = Proxy
199
adminReportsAuditReadOnlyScope :: Proxy '["https://www.googleapis.com/auth/admin.reports.audit.readonly"] adminReportsAuditReadOnlyScope = Proxy
144
adminReportsAuditReadOnlyScope = Proxy
38
true
true
0
8
17
26
12
14
null
null
paulrzcz/HSvm
Data/SVM.hs
bsd-2-clause
mergeAlgo (EpsilonSvr e cf) p = p { R.svm_type = R.epsilonSvr, R.eps = realToFrac e, R.c = realToFrac cf }
176
mergeAlgo (EpsilonSvr e cf) p = p { R.svm_type = R.epsilonSvr, R.eps = realToFrac e, R.c = realToFrac cf }
176
mergeAlgo (EpsilonSvr e cf) p = p { R.svm_type = R.epsilonSvr, R.eps = realToFrac e, R.c = realToFrac cf }
176
false
false
0
7
89
53
28
25
null
null
alexvong1995/pandoc
src/Text/Pandoc/Parsing.hs
gpl-2.0
-- | Parses material enclosed between start and end parsers. enclosed :: Stream s m Char => ParserT s st m t -- ^ start parser -> ParserT s st m end -- ^ end parser -> ParserT s st m a -- ^ content parser (to be used repeatedly) -> ParserT s st m [a] enclosed start end parser = try $ ...
373
enclosed :: Stream s m Char => ParserT s st m t -- ^ start parser -> ParserT s st m end -- ^ end parser -> ParserT s st m a -- ^ content parser (to be used repeatedly) -> ParserT s st m [a] enclosed start end parser = try $ start >> notFollowedBy space >> many1Till parser end
312
enclosed start end parser = try $ start >> notFollowedBy space >> many1Till parser end
88
true
true
2
11
106
109
52
57
null
null
yiannist/ganeti
src/Ganeti/Constants.hs
bsd-2-clause
ssHypervisorList :: String ssHypervisorList = "hypervisor_list"
63
ssHypervisorList :: String ssHypervisorList = "hypervisor_list"
63
ssHypervisorList = "hypervisor_list"
36
false
true
0
4
5
11
6
5
null
null
Josh211ua/TinyControl
TinyControl/Client.hs
bsd-3-clause
initialState :: P.DataPacket -> UTCTime -> ClientState initialState dp t_delay_start = ClientState { intervals = [] , packetCount = 0 , packetHistory = [] , lastLossEvent = Nothing , lastPacket = dp , lastPacketStamp = (P.seqNum dp, t_delay_start) , nextTimeoutTime = read "0000-00-00 00:00:00" ...
349
initialState :: P.DataPacket -> UTCTime -> ClientState initialState dp t_delay_start = ClientState { intervals = [] , packetCount = 0 , packetHistory = [] , lastLossEvent = Nothing , lastPacket = dp , lastPacketStamp = (P.seqNum dp, t_delay_start) , nextTimeoutTime = read "0000-00-00 00:00:00" ...
349
initialState dp t_delay_start = ClientState { intervals = [] , packetCount = 0 , packetHistory = [] , lastLossEvent = Nothing , lastPacket = dp , lastPacketStamp = (P.seqNum dp, t_delay_start) , nextTimeoutTime = read "0000-00-00 00:00:00" , p = 0 , x_recv = 0 }
294
false
true
0
9
84
100
59
41
null
null
samfoy/adventOfCode
src/Day4.hs
bsd-3-clause
isX a x = concat (replicate a "0") == take a md where md = md5s (Str x)
73
isX a x = concat (replicate a "0") == take a md where md = md5s (Str x)
73
isX a x = concat (replicate a "0") == take a md where md = md5s (Str x)
73
false
false
0
9
19
48
22
26
null
null
dysinger/amazonka
amazonka-elastictranscoder/gen/Network/AWS/ElasticTranscoder/Types.hs
mpl-2.0
-- | The bit rate of the video stream in the output file, in kilobits/second. -- Valid values depend on the values of 'Level' and 'Profile'. If you specify 'auto', -- Elastic Transcoder uses the detected bit rate of the input source. If you -- specify a value other than 'auto', we recommend that you specify a value les...
863
vpBitRate :: Lens' VideoParameters (Maybe Text) vpBitRate = lens _vpBitRate (\s a -> s { _vpBitRate = a })
106
vpBitRate = lens _vpBitRate (\s a -> s { _vpBitRate = a })
58
true
true
0
9
174
57
36
21
null
null
brendanhay/gogol
gogol-youtube/gen/Network/Google/YouTube/Types/Product.hs
mpl-2.0
-- | The ID of the content owner linked to the channel. ccodContentOwner :: Lens' ChannelContentOwnerDetails (Maybe Text) ccodContentOwner = lens _ccodContentOwner (\ s a -> s{_ccodContentOwner = a})
207
ccodContentOwner :: Lens' ChannelContentOwnerDetails (Maybe Text) ccodContentOwner = lens _ccodContentOwner (\ s a -> s{_ccodContentOwner = a})
151
ccodContentOwner = lens _ccodContentOwner (\ s a -> s{_ccodContentOwner = a})
85
true
true
0
9
36
48
25
23
null
null
abbradar/aeson
Data/Aeson/Encode/Builder.hs
bsd-3-clause
-- | Encode a JSON boolean. bool :: Bool -> Builder bool = BP.primBounded (BP.condB id (ascii4 ('t',('r',('u','e')))) (ascii5 ('f',('a',('l',('s','e'))))))
190
bool :: Bool -> Builder bool = BP.primBounded (BP.condB id (ascii4 ('t',('r',('u','e')))) (ascii5 ('f',('a',('l',('s','e'))))))
162
bool = BP.primBounded (BP.condB id (ascii4 ('t',('r',('u','e')))) (ascii5 ('f',('a',('l',('s','e'))))))
138
true
true
0
13
54
87
51
36
null
null
ianoc/jt
src/Jt/QueryParameters.hs
mit
addQp :: QueryParameters -> QueryParameter -> QueryParameters addQp (QueryParameters(existing)) qp@(QueryParameter _ _) = QueryParameters(qp : existing)
152
addQp :: QueryParameters -> QueryParameter -> QueryParameters addQp (QueryParameters(existing)) qp@(QueryParameter _ _) = QueryParameters(qp : existing)
152
addQp (QueryParameters(existing)) qp@(QueryParameter _ _) = QueryParameters(qp : existing)
90
false
true
1
8
15
60
29
31
null
null
jlamothe/passman
app/UI.hs
lgpl-3.0
buildData :: S.StateT Status IO PWData buildData = do d <- run newPWData req $ reqIf (confirm "Would you like to change the password policy?") (do let p = d^.pwPolicy p' <- reqDefault (editPolicy p) p return $ set pwPolicy p' d) (return d)
269
buildData :: S.StateT Status IO PWData buildData = do d <- run newPWData req $ reqIf (confirm "Would you like to change the password policy?") (do let p = d^.pwPolicy p' <- reqDefault (editPolicy p) p return $ set pwPolicy p' d) (return d)
269
buildData = do d <- run newPWData req $ reqIf (confirm "Would you like to change the password policy?") (do let p = d^.pwPolicy p' <- reqDefault (editPolicy p) p return $ set pwPolicy p' d) (return d)
230
false
true
0
15
73
104
48
56
null
null
brendanhay/gogol
gogol-android-publisher/gen/Network/Google/AndroidPublisher/Types/Product.hs
mpl-2.0
-- | A comment from a developer. cDeveloperComment :: Lens' Comment (Maybe DeveloperComment) cDeveloperComment = lens _cDeveloperComment (\ s a -> s{_cDeveloperComment = a})
181
cDeveloperComment :: Lens' Comment (Maybe DeveloperComment) cDeveloperComment = lens _cDeveloperComment (\ s a -> s{_cDeveloperComment = a})
148
cDeveloperComment = lens _cDeveloperComment (\ s a -> s{_cDeveloperComment = a})
88
true
true
0
9
31
48
25
23
null
null
sampou-org/pfad
Code/Code10.hs
bsd-3-clause
preprocess :: Ord a => [a] -> [(a, Set a)] preprocess xs = zip xs (tail (scanr insert empty xs))
104
preprocess :: Ord a => [a] -> [(a, Set a)] preprocess xs = zip xs (tail (scanr insert empty xs))
104
preprocess xs = zip xs (tail (scanr insert empty xs))
56
false
true
0
9
27
61
31
30
null
null
spechub/Hets
CspCASLProver/Utils.hs
gpl-2.0
-- | Function to add the bar types of a sort to an Isabelle theory. addBarType :: IsaTheory -> SORT -> IsaTheory addBarType isaTh sort = let sortBarString = mkSortBarString sort barType = mkSortBarType sort isaTh_sign = fst isaTh isaTh_sen = snd isaTh x = mkFree "x" y = mkFre...
722
addBarType :: IsaTheory -> SORT -> IsaTheory addBarType isaTh sort = let sortBarString = mkSortBarString sort barType = mkSortBarType sort isaTh_sign = fst isaTh isaTh_sen = snd isaTh x = mkFree "x" y = mkFree "y" rhs = termAppl (conDouble (mkPreAlphabetConstructor so...
654
addBarType isaTh sort = let sortBarString = mkSortBarString sort barType = mkSortBarType sort isaTh_sign = fst isaTh isaTh_sen = snd isaTh x = mkFree "x" y = mkFree "y" rhs = termAppl (conDouble (mkPreAlphabetConstructor sort)) y bin_eq = binEq x $ termAppl (c...
609
true
true
0
13
197
219
108
111
null
null
rahulmutt/ghcvm
compiler/Eta/Specialise/Rules.hs
bsd-3-clause
ruleCheck _ (Coercion _) = emptyBag
38
ruleCheck _ (Coercion _) = emptyBag
38
ruleCheck _ (Coercion _) = emptyBag
38
false
false
1
6
8
20
8
12
null
null
FranklinChen/Idris-dev
src/IRTS/CodegenC.hs
bsd-3-clause
irts_c (FArith ATFloat) x = "GETFLOAT(" ++ x ++ ")"
51
irts_c (FArith ATFloat) x = "GETFLOAT(" ++ x ++ ")"
51
irts_c (FArith ATFloat) x = "GETFLOAT(" ++ x ++ ")"
51
false
false
1
6
9
30
12
18
null
null
xarts19/tpbhs
TpbParser.hs
mit
parseResultsPage :: Page -> Either Error [Torrent] parseResultsPage page = liftM catMaybes $ liftM (map decodeRow) columns where columns = liftM (map parseColumns) $ liftM parseRows $ parseTable page
211
parseResultsPage :: Page -> Either Error [Torrent] parseResultsPage page = liftM catMaybes $ liftM (map decodeRow) columns where columns = liftM (map parseColumns) $ liftM parseRows $ parseTable page
211
parseResultsPage page = liftM catMaybes $ liftM (map decodeRow) columns where columns = liftM (map parseColumns) $ liftM parseRows $ parseTable page
160
false
true
1
9
40
82
36
46
null
null
deech/stack
src/Stack/Build.hs
bsd-3-clause
withLoadPackage :: (StackM env m, HasEnvConfig env, MonadBaseUnlift IO m) => EnvOverride -> ((PackageName -> Version -> Map FlagName Bool -> [Text] -> IO Package) -> m a) -> m a withLoadPackage menv inner = do econfig <- view envConfigL withCabalLoader menv $ \cab...
1,418
withLoadPackage :: (StackM env m, HasEnvConfig env, MonadBaseUnlift IO m) => EnvOverride -> ((PackageName -> Version -> Map FlagName Bool -> [Text] -> IO Package) -> m a) -> m a withLoadPackage menv inner = do econfig <- view envConfigL withCabalLoader menv $ \cab...
1,418
withLoadPackage menv inner = do econfig <- view envConfigL withCabalLoader menv $ \cabalLoader -> inner $ \name version flags ghcOptions -> do bs <- cabalLoader $ PackageIdentifier name version -- Intentionally ignore warnings, as it's not really -- appropriate to pr...
1,192
false
true
0
16
376
289
147
142
null
null
fmapfmapfmap/amazonka
core/test/Test/AWS/Data/List.hs
mpl-2.0
absent :: Maybe [Int] absent = Nothing
38
absent :: Maybe [Int] absent = Nothing
38
absent = Nothing
16
false
true
0
6
6
17
9
8
null
null
leshchevds/ganeti
src/Ganeti/Constants.hs
bsd-2-clause
drbdNetCustom :: String drbdNetCustom = "net-custom"
52
drbdNetCustom :: String drbdNetCustom = "net-custom"
52
drbdNetCustom = "net-custom"
28
false
true
0
4
5
11
6
5
null
null
olorin/amazonka
gen/src/Gen/AST/Data.hs
mpl-2.0
waiterData :: HasMetadata a Identity => a -> Map Id (Operation Identity Ref b) -> Id -> Waiter Id -> Either Error WData waiterData m os n w = do o <- note (missingErr k (k, Map.map _opName os)) $ Map.lookup k os wf <- waiterFields m o w c <- Fun' (sma...
938
waiterData :: HasMetadata a Identity => a -> Map Id (Operation Identity Ref b) -> Id -> Waiter Id -> Either Error WData waiterData m os n w = do o <- note (missingErr k (k, Map.map _opName os)) $ Map.lookup k os wf <- waiterFields m o w c <- Fun' (sma...
938
waiterData m os n w = do o <- note (missingErr k (k, Map.map _opName os)) $ Map.lookup k os wf <- waiterFields m o w c <- Fun' (smartCtorId n) (Raw h) <$> pp None (waiterS n wf) <*> pp Indent (waiterD n wf) return $! WData (typeId n) (_opName o) c where missingErr = format ...
763
false
true
0
15
332
320
154
166
null
null
fffej/HS-Poker
LookupPatternMatch.hs
bsd-3-clause
getValueFromProduct 214795 = 4620
33
getValueFromProduct 214795 = 4620
33
getValueFromProduct 214795 = 4620
33
false
false
0
5
3
9
4
5
null
null
AlexanderPankiv/ghc
compiler/coreSyn/PprCore.hs
bsd-3-clause
pprCoreBindingWithSize = pprTopBind sizeAnn
43
pprCoreBindingWithSize = pprTopBind sizeAnn
43
pprCoreBindingWithSize = pprTopBind sizeAnn
43
false
false
0
5
3
9
4
5
null
null
prt2121/haskell-practice
ch6-11-17-25/src/Chapter11.hs
apache-2.0
size _ = Nothing
34
size _ = Nothing
34
size _ = Nothing
34
false
false
0
5
21
9
4
5
null
null
leshchevds/ganeti
src/Ganeti/Constants.hs
bsd-2-clause
diskstatsFile :: String diskstatsFile = "/proc/diskstats"
57
diskstatsFile :: String diskstatsFile = "/proc/diskstats"
57
diskstatsFile = "/proc/diskstats"
33
false
true
0
4
5
11
6
5
null
null
joshcough/Scrabble
test/Scrabble/Move/WordPutTests.hs
mit
quickPut_H :: String -> [Letter] -> Either String WordPut quickPut_H = quickPut horz
84
quickPut_H :: String -> [Letter] -> Either String WordPut quickPut_H = quickPut horz
84
quickPut_H = quickPut horz
26
false
true
0
7
12
30
15
15
null
null
fmapfmapfmap/amazonka
amazonka-ec2/gen/Network/AWS/EC2/Types/Product.hs
mpl-2.0
-- | The allocation ID. niaAllocationId :: Lens' NetworkInterfaceAssociation (Maybe Text) niaAllocationId = lens _niaAllocationId (\ s a -> s{_niaAllocationId = a})
164
niaAllocationId :: Lens' NetworkInterfaceAssociation (Maybe Text) niaAllocationId = lens _niaAllocationId (\ s a -> s{_niaAllocationId = a})
140
niaAllocationId = lens _niaAllocationId (\ s a -> s{_niaAllocationId = a})
74
true
true
0
9
21
46
25
21
null
null
enolan/Idris-dev
src/Idris/Docs.hs
bsd-3-clause
getDocs n w = do i <- getIState docs <- if | Just ci <- lookupCtxtExact n (idris_interfaces i) -> docInterface n ci | Just ri <- lookupCtxtExact n (idris_records i) -> docRecord n ri | Just ti <- lookupCtxtExact n (idris_datatype...
987
getDocs n w = do i <- getIState docs <- if | Just ci <- lookupCtxtExact n (idris_interfaces i) -> docInterface n ci | Just ri <- lookupCtxtExact n (idris_records i) -> docRecord n ri | Just ti <- lookupCtxtExact n (idris_datatype...
987
getDocs n w = do i <- getIState docs <- if | Just ci <- lookupCtxtExact n (idris_interfaces i) -> docInterface n ci | Just ri <- lookupCtxtExact n (idris_records i) -> docRecord n ri | Just ti <- lookupCtxtExact n (idris_datatype...
987
false
false
3
15
452
291
132
159
null
null
brendanhay/gogol
gogol-resourcemanager/gen/Network/Google/Resource/CloudResourceManager/TagKeys/Delete.hs
mpl-2.0
-- | Required. The resource name of a TagKey to be deleted in the format -- \`tagKeys\/123\`. The TagKey cannot be a parent of any existing -- TagValues or it will not be deleted successfully. tkdName :: Lens' TagKeysDelete Text tkdName = lens _tkdName (\ s a -> s{_tkdName = a})
279
tkdName :: Lens' TagKeysDelete Text tkdName = lens _tkdName (\ s a -> s{_tkdName = a})
86
tkdName = lens _tkdName (\ s a -> s{_tkdName = a})
50
true
true
1
9
50
45
24
21
null
null
ml9951/ghc
compiler/typecheck/TcRnTypes.hs
bsd-3-clause
pprCtO RecordUpdOrigin = ptext (sLit "a record update")
61
pprCtO RecordUpdOrigin = ptext (sLit "a record update")
61
pprCtO RecordUpdOrigin = ptext (sLit "a record update")
61
false
false
0
7
13
19
8
11
null
null
kolmodin/cabal
cabal-install/Distribution/Client/Setup.hs
bsd-3-clause
win32SelfUpgradeCommand :: CommandUI Win32SelfUpgradeFlags win32SelfUpgradeCommand = CommandUI { commandName = "win32selfupgrade", commandSynopsis = "Self-upgrade the executable on Windows", commandDescription = Nothing, commandNotes = Nothing, commandUsage = \pname -> "Usage: "...
567
win32SelfUpgradeCommand :: CommandUI Win32SelfUpgradeFlags win32SelfUpgradeCommand = CommandUI { commandName = "win32selfupgrade", commandSynopsis = "Self-upgrade the executable on Windows", commandDescription = Nothing, commandNotes = Nothing, commandUsage = \pname -> "Usage: "...
567
win32SelfUpgradeCommand = CommandUI { commandName = "win32selfupgrade", commandSynopsis = "Self-upgrade the executable on Windows", commandDescription = Nothing, commandNotes = Nothing, commandUsage = \pname -> "Usage: " ++ pname ++ " win32selfupgrade PID PATH\n", commandDefau...
508
false
true
0
13
124
102
61
41
null
null
phischu/fragnix
tests/packages/scotty/System.Posix.ByteString.FilePath.hs
bsd-3-clause
throwErrnoPathIf :: (a -> Bool) -> String -> RawFilePath -> IO a -> IO a throwErrnoPathIf cond loc path f = do res <- f if cond res then throwErrnoPath loc path else return res -- | as 'throwErrnoIf_', but exceptions include the given path when -- appropriate. --
276
throwErrnoPathIf :: (a -> Bool) -> String -> RawFilePath -> IO a -> IO a throwErrnoPathIf cond loc path f = do res <- f if cond res then throwErrnoPath loc path else return res -- | as 'throwErrnoIf_', but exceptions include the given path when -- appropriate. --
276
throwErrnoPathIf cond loc path f = do res <- f if cond res then throwErrnoPath loc path else return res -- | as 'throwErrnoIf_', but exceptions include the given path when -- appropriate. --
203
false
true
0
9
61
87
41
46
null
null