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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
ml9951/ThreadScope | papers/haskell_symposium_2009/bsort/BSortPar2.hs | bsd-3-clause | -------------------------------------------------------------------------------
main :: IO ()
main
= do nums <- sequence (replicate (2^14) (getStdRandom (randomR (1,255))))
tStart <- getClockTime
performGC
let r = bsort nums
seq r (return ())
tEnd <- getClockTime
... | 500 | main :: IO ()
main
= do nums <- sequence (replicate (2^14) (getStdRandom (randomR (1,255))))
tStart <- getClockTime
performGC
let r = bsort nums
seq r (return ())
tEnd <- getClockTime
putStrLn (show (sum r))
putStrLn ("Time: " ++ show (secDiff tStart tEnd) ++ ... | 416 | main
= do nums <- sequence (replicate (2^14) (getStdRandom (randomR (1,255))))
tStart <- getClockTime
performGC
let r = bsort nums
seq r (return ())
tEnd <- getClockTime
putStrLn (show (sum r))
putStrLn ("Time: " ++ show (secDiff tStart tEnd) ++ " seconds.")
... | 402 | true | true | 0 | 15 | 115 | 154 | 72 | 82 | null | null |
plneappl/HaskellVectorsETC | mld.hs | mit | toBoolV :: (Vector v Z2) => v Z2 -> v Bool
toBoolV = fmap (toEnum . fromEnum) | 77 | toBoolV :: (Vector v Z2) => v Z2 -> v Bool
toBoolV = fmap (toEnum . fromEnum) | 77 | toBoolV = fmap (toEnum . fromEnum) | 34 | false | true | 0 | 8 | 16 | 48 | 22 | 26 | null | null |
haliner/presenter | Main.hs | gpl-3.0 | left :: ActionM ()
left = do
liftIO $ callProcess "xdotool" ["key", "--clearmodifier", "Left"]
redirect "/" | 111 | left :: ActionM ()
left = do
liftIO $ callProcess "xdotool" ["key", "--clearmodifier", "Left"]
redirect "/" | 111 | left = do
liftIO $ callProcess "xdotool" ["key", "--clearmodifier", "Left"]
redirect "/" | 92 | false | true | 0 | 9 | 19 | 43 | 21 | 22 | null | null |
green-haskell/ghc | compiler/stranal/DmdAnal.hs | bsd-3-clause | addLazyFVs :: DmdType -> DmdEnv -> DmdType
addLazyFVs dmd_ty lazy_fvs
= dmd_ty `bothDmdType` mkBothDmdArg lazy_fvs | 116 | addLazyFVs :: DmdType -> DmdEnv -> DmdType
addLazyFVs dmd_ty lazy_fvs
= dmd_ty `bothDmdType` mkBothDmdArg lazy_fvs | 116 | addLazyFVs dmd_ty lazy_fvs
= dmd_ty `bothDmdType` mkBothDmdArg lazy_fvs | 73 | false | true | 0 | 8 | 16 | 41 | 19 | 22 | null | null |
ezyang/hoopl | src/Compiler/Hoopl/Stream.hs | bsd-3-clause | iterS :: Stream s a -> Stream s a
iterS stream = \s -> case stream s of
Nothing -> Nothing
Just (Pair a s') -> Just $ Pair a (s' `thenS` iterS stream) | 196 | iterS :: Stream s a -> Stream s a
iterS stream = \s -> case stream s of
Nothing -> Nothing
Just (Pair a s') -> Just $ Pair a (s' `thenS` iterS stream) | 196 | iterS stream = \s -> case stream s of
Nothing -> Nothing
Just (Pair a s') -> Just $ Pair a (s' `thenS` iterS stream) | 162 | false | true | 0 | 13 | 79 | 88 | 42 | 46 | null | null |
sol/hpack | src/Data/Aeson/Config/FromValue.hs | mit | genericFromValueWith :: (Generic a, GenericDecode (Rep a)) => Options -> Value -> Parser a
genericFromValueWith opts = fmap to . genericDecode opts | 148 | genericFromValueWith :: (Generic a, GenericDecode (Rep a)) => Options -> Value -> Parser a
genericFromValueWith opts = fmap to . genericDecode opts | 148 | genericFromValueWith opts = fmap to . genericDecode opts | 57 | false | true | 0 | 8 | 22 | 59 | 28 | 31 | null | null |
kaoskorobase/mescaline | lib/mescaline/runtests.hs | gpl-3.0 | main :: IO ()
main = defaultMain
$ Data.KDTree.Test.tests
++ Mescaline.Data.PriorityQueue.Test.tests | 117 | main :: IO ()
main = defaultMain
$ Data.KDTree.Test.tests
++ Mescaline.Data.PriorityQueue.Test.tests | 117 | main = defaultMain
$ Data.KDTree.Test.tests
++ Mescaline.Data.PriorityQueue.Test.tests | 103 | false | true | 4 | 7 | 27 | 41 | 20 | 21 | null | null |
leepike/copilot-core | src/Copilot/Core/Locals.hs | bsd-3-clause | --------------------------------------------------------------------------------
locsExpr :: Expr a -> DList Loc
locsExpr e0 = case e0 of
Const _ _ -> empty
Drop _ _ _ -> empty
Local t _ name e1 e2 -> singleton (Loc name t)
`append` locsExpr e1
... | 851 | locsExpr :: Expr a -> DList Loc
locsExpr e0 = case e0 of
Const _ _ -> empty
Drop _ _ _ -> empty
Local t _ name e1 e2 -> singleton (Loc name t)
`append` locsExpr e1
`append` locsExpr e2
Var _ _ ... | 769 | locsExpr e0 = case e0 of
Const _ _ -> empty
Drop _ _ _ -> empty
Local t _ name e1 e2 -> singleton (Loc name t)
`append` locsExpr e1
`append` locsExpr e2
Var _ _ -> empty
ExternVar _ _ ... | 737 | true | true | 0 | 12 | 358 | 237 | 114 | 123 | null | null |
jwiegley/github | samples/Users/ShowUser2.hs | bsd-3-clause | main :: IO ()
main = do
possibleUser <- GH.executeRequest' $ GH.userInfoForR "phadej"
print possibleUser | 112 | main :: IO ()
main = do
possibleUser <- GH.executeRequest' $ GH.userInfoForR "phadej"
print possibleUser | 112 | main = do
possibleUser <- GH.executeRequest' $ GH.userInfoForR "phadej"
print possibleUser | 98 | false | true | 0 | 10 | 22 | 40 | 18 | 22 | null | null |
lukexi/ghc-7.8-arm64 | compiler/codeGen/StgCmmClosure.hs | bsd-3-clause | maybeIsLFCon _ = Nothing | 24 | maybeIsLFCon _ = Nothing | 24 | maybeIsLFCon _ = Nothing | 24 | false | false | 0 | 5 | 3 | 9 | 4 | 5 | null | null |
mstksg/tensor-ops | src/Data/Type/Sing.hs | bsd-3-clause | entailSing2
:: forall a b c. ()
=> (Sing a -> Sing b -> Sing c)
-> ((SingI a, SingI b) :- SingI c)
entailSing2 f = Sub $ withSingI (f (sing :: Sing a) (sing :: Sing b)) Wit | 184 | entailSing2
:: forall a b c. ()
=> (Sing a -> Sing b -> Sing c)
-> ((SingI a, SingI b) :- SingI c)
entailSing2 f = Sub $ withSingI (f (sing :: Sing a) (sing :: Sing b)) Wit | 184 | entailSing2 f = Sub $ withSingI (f (sing :: Sing a) (sing :: Sing b)) Wit | 73 | false | true | 0 | 13 | 51 | 111 | 56 | 55 | null | null |
cchalmers/geometry | src/Geometry/ThreeD/Types.hs | bsd-3-clause | r3SphericalIso :: RealFloat n => Iso' (V3 n) (n, Angle n, Angle n)
r3SphericalIso = iso
(\v@(V3 x y z) -> (norm v, atan2A y x, acosA (z / norm v)))
(\(r,θ,φ) -> V3 (r * cosA θ * sinA φ) (r * sinA θ * sinA φ) (r * cosA φ)) | 227 | r3SphericalIso :: RealFloat n => Iso' (V3 n) (n, Angle n, Angle n)
r3SphericalIso = iso
(\v@(V3 x y z) -> (norm v, atan2A y x, acosA (z / norm v)))
(\(r,θ,φ) -> V3 (r * cosA θ * sinA φ) (r * sinA θ * sinA φ) (r * cosA φ)) | 227 | r3SphericalIso = iso
(\v@(V3 x y z) -> (norm v, atan2A y x, acosA (z / norm v)))
(\(r,θ,φ) -> V3 (r * cosA θ * sinA φ) (r * sinA θ * sinA φ) (r * cosA φ)) | 160 | false | true | 0 | 11 | 57 | 169 | 86 | 83 | null | null |
Hamcha/dvx | Dvx/Utils.hs | mit | joinstr acc depth (x:xs) =
joinstr ((head acc ++ x):(tail acc)) (depth + nesting x) xs
where
nesting c | head c == '{' = 1
| last c == '}' = -1
| otherwise = 0
-- |1 if given True, 0 if given False | 244 | joinstr acc depth (x:xs) =
joinstr ((head acc ++ x):(tail acc)) (depth + nesting x) xs
where
nesting c | head c == '{' = 1
| last c == '}' = -1
| otherwise = 0
-- |1 if given True, 0 if given False | 244 | joinstr acc depth (x:xs) =
joinstr ((head acc ++ x):(tail acc)) (depth + nesting x) xs
where
nesting c | head c == '{' = 1
| last c == '}' = -1
| otherwise = 0
-- |1 if given True, 0 if given False | 244 | false | false | 0 | 10 | 92 | 113 | 53 | 60 | null | null |
rueshyna/gogol | gogol-identity-toolkit/gen/Network/Google/IdentityToolkit/Types/Product.hs | mpl-2.0 | -- | If idToken is STS id token, then this field will be refresh token.
vctrRefreshToken :: Lens' VerifyCustomTokenResponse (Maybe Text)
vctrRefreshToken
= lens _vctrRefreshToken
(\ s a -> s{_vctrRefreshToken = a}) | 222 | vctrRefreshToken :: Lens' VerifyCustomTokenResponse (Maybe Text)
vctrRefreshToken
= lens _vctrRefreshToken
(\ s a -> s{_vctrRefreshToken = a}) | 150 | vctrRefreshToken
= lens _vctrRefreshToken
(\ s a -> s{_vctrRefreshToken = a}) | 85 | true | true | 1 | 9 | 39 | 51 | 25 | 26 | null | null |
chadbrewbaker/shellcheck | ShellCheck/Analytics.hs | gpl-3.0 | prop_checkUnassignedReferences1 = verifyTree checkUnassignedReferences "echo $foo" | 82 | prop_checkUnassignedReferences1 = verifyTree checkUnassignedReferences "echo $foo" | 82 | prop_checkUnassignedReferences1 = verifyTree checkUnassignedReferences "echo $foo" | 82 | false | false | 0 | 5 | 5 | 11 | 5 | 6 | null | null |
spechub/Hets | THF/StaticAnalysisTHF.hs | gpl-2.0 | insertConst :: Constant -> As.Name -> Type -> Annotations
-> State ([Diagnosis], SignTHF, Set.Set SymbolTHF) ()
insertConst c n t a = do
(_, sig, _) <- get
if sigHasTypeSymbol c sig then (appandDiag $ mkDiag Error
"Duplicate definition of a symbol as a type constant. Symbol: " c)
... | 1,246 | insertConst :: Constant -> As.Name -> Type -> Annotations
-> State ([Diagnosis], SignTHF, Set.Set SymbolTHF) ()
insertConst c n t a = do
(_, sig, _) <- get
if sigHasTypeSymbol c sig then (appandDiag $ mkDiag Error
"Duplicate definition of a symbol as a type constant. Symbol: " c)
... | 1,246 | insertConst c n t a = do
(_, sig, _) <- get
if sigHasTypeSymbol c sig then (appandDiag $ mkDiag Error
"Duplicate definition of a symbol as a type constant. Symbol: " c)
else do
isTypeConsistent t
if sigHasConstSymbol c sig then
unless (sigHasSameType c t sig) $ app... | 1,114 | false | true | 0 | 21 | 531 | 314 | 167 | 147 | null | null |
Ongy/monky | Monky/Examples/Combine.hs | lgpl-3.0 | combine :: (PollModule a, PollModule b) => IO a -> IO b -> IO (CombiHandle a b)
combine a b = do
c <- a
d <- b
return $ C c d
-- Module handle a, b. IORef for caching a, b. MVar to implement boolean, containing value doesn't matter
-- |Wrapper type for 'EvtModule's | 272 | combine :: (PollModule a, PollModule b) => IO a -> IO b -> IO (CombiHandle a b)
combine a b = do
c <- a
d <- b
return $ C c d
-- Module handle a, b. IORef for caching a, b. MVar to implement boolean, containing value doesn't matter
-- |Wrapper type for 'EvtModule's | 272 | combine a b = do
c <- a
d <- b
return $ C c d
-- Module handle a, b. IORef for caching a, b. MVar to implement boolean, containing value doesn't matter
-- |Wrapper type for 'EvtModule's | 192 | false | true | 0 | 10 | 62 | 89 | 41 | 48 | null | null |
pyr/apotiki | System/Apotiki/Debian/Control.hs | isc | ctlEntryParser :: P.Parser (String, String)
ctlEntryParser = do
k <- unpack `fmap` P.takeWhile (P.notInClass ":")
P.string $ pack ":"
v <- if (k == "Description") then ctlFlatDescParser else ctlValParser
return (k, strip v) | 231 | ctlEntryParser :: P.Parser (String, String)
ctlEntryParser = do
k <- unpack `fmap` P.takeWhile (P.notInClass ":")
P.string $ pack ":"
v <- if (k == "Description") then ctlFlatDescParser else ctlValParser
return (k, strip v) | 231 | ctlEntryParser = do
k <- unpack `fmap` P.takeWhile (P.notInClass ":")
P.string $ pack ":"
v <- if (k == "Description") then ctlFlatDescParser else ctlValParser
return (k, strip v) | 187 | false | true | 0 | 12 | 40 | 97 | 49 | 48 | null | null |
nomeata/ghc | compiler/codeGen/StgCmmForeign.hs | bsd-3-clause | getFCallArgs :: [StgArg] -> FCode [(CmmExpr, ForeignHint)]
-- (a) Drop void args
-- (b) Add foreign-call shim code
-- It's (b) that makes this differ from getNonVoidArgAmodes
getFCallArgs args
= do { mb_cmms <- mapM get args
; return (catMaybes mb_cmms) }
where
get arg | isVoidRep arg_rep
... | 670 | getFCallArgs :: [StgArg] -> FCode [(CmmExpr, ForeignHint)]
getFCallArgs args
= do { mb_cmms <- mapM get args
; return (catMaybes mb_cmms) }
where
get arg | isVoidRep arg_rep
= return Nothing
| otherwise
= do { cmm <- getArgAmode (NonVoid arg)
; dflag... | 553 | getFCallArgs args
= do { mb_cmms <- mapM get args
; return (catMaybes mb_cmms) }
where
get arg | isVoidRep arg_rep
= return Nothing
| otherwise
= do { cmm <- getArgAmode (NonVoid arg)
; dflags <- getDynFlags
; return (Just (add_shim ... | 494 | true | true | 0 | 12 | 232 | 172 | 86 | 86 | null | null |
ssaavedra/liquidhaskell | src/Language/Haskell/Liquid/Bare/GhcSpec.hs | bsd-3-clause | makeGhcSpec2 invs ialias measures su sp
= return $ sp { invariants = subst su invs
, ialiases = subst su ialias
, measures = subst su
<$> M.elems (Ms.measMap measures)
++ Ms.imeas measures
} | 311 | makeGhcSpec2 invs ialias measures su sp
= return $ sp { invariants = subst su invs
, ialiases = subst su ialias
, measures = subst su
<$> M.elems (Ms.measMap measures)
++ Ms.imeas measures
} | 311 | makeGhcSpec2 invs ialias measures su sp
= return $ sp { invariants = subst su invs
, ialiases = subst su ialias
, measures = subst su
<$> M.elems (Ms.measMap measures)
++ Ms.imeas measures
} | 311 | false | false | 0 | 13 | 155 | 80 | 40 | 40 | null | null |
spencerjanssen/cabal2nix | src/Cabal2Nix/PostProcess.hs | bsd-3-clause | ncursesPatchPhase :: String
ncursesPatchPhase = "patchPhase = \"find . -type f -exec sed -i -e 's|ncursesw/||' {} \\\\;\";" | 123 | ncursesPatchPhase :: String
ncursesPatchPhase = "patchPhase = \"find . -type f -exec sed -i -e 's|ncursesw/||' {} \\\\;\";" | 123 | ncursesPatchPhase = "patchPhase = \"find . -type f -exec sed -i -e 's|ncursesw/||' {} \\\\;\";" | 95 | false | true | 0 | 4 | 17 | 11 | 6 | 5 | null | null |
Concomitant/LambdaHack | Game/LambdaHack/Common/Msg.hs | bsd-3-clause | encodeLine :: [AttrChar] -> ScreenLine
encodeLine l = G.fromList $ map (fromIntegral . fromEnum) l | 98 | encodeLine :: [AttrChar] -> ScreenLine
encodeLine l = G.fromList $ map (fromIntegral . fromEnum) l | 98 | encodeLine l = G.fromList $ map (fromIntegral . fromEnum) l | 59 | false | true | 0 | 8 | 14 | 44 | 21 | 23 | null | null |
ComputationWithBoundedResources/ara-inference | doc/tpdb_trs/Haskell/basic_haskell/rangeSize_2.hs | mit | asAs :: MyBool -> MyBool -> MyBool;
asAs MyFalse x = MyFalse | 64 | asAs :: MyBool -> MyBool -> MyBool
asAs MyFalse x = MyFalse | 63 | asAs MyFalse x = MyFalse | 24 | false | true | 0 | 6 | 15 | 25 | 13 | 12 | null | null |
GaloisInc/sk-dev-platform | libs/genLobster/Main.hs | bsd-3-clause | processPolicy :: Options -> Policy -> IO ()
processPolicy opts x = do
f <- if isDir opts
then do
let dir = path opts
createDirectoryIfMissing True dir
return $ \fn s -> do
writeFile fn s
appendFile fn "\n"
else do
let fn = path opts
writeFile fn ""
return $ ... | 398 | processPolicy :: Options -> Policy -> IO ()
processPolicy opts x = do
f <- if isDir opts
then do
let dir = path opts
createDirectoryIfMissing True dir
return $ \fn s -> do
writeFile fn s
appendFile fn "\n"
else do
let fn = path opts
writeFile fn ""
return $ ... | 398 | processPolicy opts x = do
f <- if isDir opts
then do
let dir = path opts
createDirectoryIfMissing True dir
return $ \fn s -> do
writeFile fn s
appendFile fn "\n"
else do
let fn = path opts
writeFile fn ""
return $ \_ s -> appendFile fn s
mapM_ (processPoli... | 354 | false | true | 0 | 15 | 128 | 157 | 70 | 87 | null | null |
hnfmr/beginning_haskell | DataBuilder.hs | mit | clientToText (Company i n p d) =
"client(com," <> B.decimal i <> B.singleton ',' <> B.fromText (escapeString n) <> B.singleton ','
<> personToText p <> B.singleton ',' <> B.fromText (escapeString d) <> B.singleton ')' | 235 | clientToText (Company i n p d) =
"client(com," <> B.decimal i <> B.singleton ',' <> B.fromText (escapeString n) <> B.singleton ','
<> personToText p <> B.singleton ',' <> B.fromText (escapeString d) <> B.singleton ')' | 235 | clientToText (Company i n p d) =
"client(com," <> B.decimal i <> B.singleton ',' <> B.fromText (escapeString n) <> B.singleton ','
<> personToText p <> B.singleton ',' <> B.fromText (escapeString d) <> B.singleton ')' | 235 | false | false | 4 | 9 | 51 | 106 | 47 | 59 | null | null |
nushio3/unittyped | src/UnitTyped/Type.hs | lgpl-2.1 | u |- d = fmap (\x -> x - d) u | 29 | u |- d = fmap (\x -> x - d) u | 29 | u |- d = fmap (\x -> x - d) u | 29 | false | false | 0 | 8 | 10 | 35 | 16 | 19 | null | null |
sapek/pandoc | src/Text/Pandoc/Readers/LaTeX.hs | gpl-2.0 | inNote :: Inlines -> Inlines
inNote ils =
note $ para $ ils <> str "." | 72 | inNote :: Inlines -> Inlines
inNote ils =
note $ para $ ils <> str "." | 72 | inNote ils =
note $ para $ ils <> str "." | 43 | false | true | 0 | 7 | 17 | 33 | 16 | 17 | null | null |
knotman90/google-interview | haskell/wikibook.hs | gpl-3.0 | mapIO :: (a -> IO b) -> [a] -> IO [b]
mapIO f = sequenceIO . map f | 66 | mapIO :: (a -> IO b) -> [a] -> IO [b]
mapIO f = sequenceIO . map f | 66 | mapIO f = sequenceIO . map f | 28 | false | true | 1 | 9 | 17 | 54 | 25 | 29 | null | null |
beni55/openshake | tests/evan-hang/Shakefile.hs | bsd-3-clause | hs_of :: FilePath -> FilePath
hs_of fn = FilePath.replaceExtension fn "hs" | 74 | hs_of :: FilePath -> FilePath
hs_of fn = FilePath.replaceExtension fn "hs" | 74 | hs_of fn = FilePath.replaceExtension fn "hs" | 44 | false | true | 0 | 7 | 10 | 30 | 13 | 17 | null | null |
PPitson/Deque | test/unit/HUnitTests.hs | bsd-3-clause | -- push back
test37 = TestCase (assertEqual "push back" [1] (toListDEQ $ pushBackDEQ emptyDEQ 1) ) | 99 | test37 = TestCase (assertEqual "push back" [1] (toListDEQ $ pushBackDEQ emptyDEQ 1) ) | 86 | test37 = TestCase (assertEqual "push back" [1] (toListDEQ $ pushBackDEQ emptyDEQ 1) ) | 86 | true | false | 0 | 10 | 16 | 35 | 18 | 17 | null | null |
nevrenato/Hets_Fork | OWL2/Parse.hs | gpl-2.0 | subPropertyKey :: CharParser st ()
subPropertyKey = pkeyword subPropertyOfC | 75 | subPropertyKey :: CharParser st ()
subPropertyKey = pkeyword subPropertyOfC | 75 | subPropertyKey = pkeyword subPropertyOfC | 40 | false | true | 0 | 6 | 8 | 21 | 10 | 11 | null | null |
lueck/htcf | src/HTCF/ConfigParser.hs | gpl-3.0 | -- | Test if one digit numbers are read as ordinals.
singleDigitOrdinalP :: [Config] -> Bool
singleDigitOrdinalP [] = defaultSingleDigitOrdinal | 143 | singleDigitOrdinalP :: [Config] -> Bool
singleDigitOrdinalP [] = defaultSingleDigitOrdinal | 90 | singleDigitOrdinalP [] = defaultSingleDigitOrdinal | 50 | true | true | 0 | 6 | 19 | 24 | 13 | 11 | null | null |
bennofs/cabal2nix | src/Distribution/Nixpkgs/Fetch.hs | bsd-3-clause | fetch :: forall a. (String -> MaybeT IO a) -- ^ This function is passed the output path name as an argument.
-- It should return 'Nothing' if the file doesn't match the expected format.
-- This is required, because we c... | 2,105 | fetch :: forall a. (String -> MaybeT IO a) -- ^ This function is passed the output path name as an argument.
-- It should return 'Nothing' if the file doesn't match the expected format.
-- This is required, because we c... | 1,989 | fetch f = runMaybeT . fetchers where
fetchers :: Source -> MaybeT IO (DerivationSource, a)
fetchers source = msum . (fetchLocal source :) $ map (\fetcher -> fetchWith fetcher source >>= process)
[ (False, "url", [])
, (True, "git", ["--fetch-submodules"])
, (True, "hg", [])
, (True, "svn", [])
,... | 1,494 | true | true | 0 | 13 | 560 | 544 | 289 | 255 | null | null |
narurien/ganeti-ceph | src/Ganeti/DataCollectors/Lv.hs | gpl-2.0 | -- | This function computes the JSON representation of the LV status.
buildJsonReport :: Options -> IO J.JSValue
buildJsonReport opts = do
let inputFile = optInputFile opts
lvInfo <- getLvInfo inputFile
(prim, sec) <- getInstanceList opts
return . J.showJSON $ addInstNameToLv (prim ++ sec) lvInfo
-- | This fun... | 372 | buildJsonReport :: Options -> IO J.JSValue
buildJsonReport opts = do
let inputFile = optInputFile opts
lvInfo <- getLvInfo inputFile
(prim, sec) <- getInstanceList opts
return . J.showJSON $ addInstNameToLv (prim ++ sec) lvInfo
-- | This function computes the DCReport for the logical volumes. | 302 | buildJsonReport opts = do
let inputFile = optInputFile opts
lvInfo <- getLvInfo inputFile
(prim, sec) <- getInstanceList opts
return . J.showJSON $ addInstNameToLv (prim ++ sec) lvInfo
-- | This function computes the DCReport for the logical volumes. | 259 | true | true | 0 | 11 | 64 | 93 | 43 | 50 | null | null |
srank/regexp | Tokenise.hs | gpl-3.0 | tokenise xs = Text f:tokenise g
where (f, g) = getFrontLiteral xs | 67 | tokenise xs = Text f:tokenise g
where (f, g) = getFrontLiteral xs | 67 | tokenise xs = Text f:tokenise g
where (f, g) = getFrontLiteral xs | 67 | false | false | 0 | 6 | 13 | 37 | 17 | 20 | null | null |
alexander-at-github/eta | compiler/ETA/StgSyn/CoreToStg.hs | bsd-3-clause | check_eq_li TopLet TopLet = True | 46 | check_eq_li TopLet TopLet = True | 46 | check_eq_li TopLet TopLet = True | 46 | false | false | 0 | 5 | 18 | 13 | 5 | 8 | null | null |
ZjMNZHgG5jMXw/privacy-option | Language/POL/Syntax.hs | bsd-3-clause | -- (R23)
ifobs o c = If o c | 47 | ifobs o c = If o c | 38 | ifobs o c = If o c | 38 | true | false | 1 | 5 | 28 | 23 | 8 | 15 | null | null |
jberthold/rts-serialisation | testExceptions.hs | bsd-3-clause | -- need a time-wasting function which allocates...
nfib :: Integer -> Integer
nfib 0 = 1 | 88 | nfib :: Integer -> Integer
nfib 0 = 1 | 37 | nfib 0 = 1 | 10 | true | true | 0 | 7 | 15 | 25 | 11 | 14 | null | null |
travitch/dalvik | src/Dalvik/DebugInfo.hs | bsd-3-clause | startLocal :: DebugState -> Word32 -> Int32 -> Int32 -> Int32
-> DebugState
startLocal s r nid tid sid =
s { dbgLocals = Map.alter start r (dbgLocals s)
, dbgSeqNo = n + 1
}
where start (Just (LocalInfo 0 a' 0xFFFFFFFF nid' tid' sid' : ls)) =
Just $ l' : LocalInfo n a' a nid' tid' si... | 497 | startLocal :: DebugState -> Word32 -> Int32 -> Int32 -> Int32
-> DebugState
startLocal s r nid tid sid =
s { dbgLocals = Map.alter start r (dbgLocals s)
, dbgSeqNo = n + 1
}
where start (Just (LocalInfo 0 a' 0xFFFFFFFF nid' tid' sid' : ls)) =
Just $ l' : LocalInfo n a' a nid' tid' si... | 497 | startLocal s r nid tid sid =
s { dbgLocals = Map.alter start r (dbgLocals s)
, dbgSeqNo = n + 1
}
where start (Just (LocalInfo 0 a' 0xFFFFFFFF nid' tid' sid' : ls)) =
Just $ l' : LocalInfo n a' a nid' tid' sid' : ls
start (Just ls) = Just $ l' : ls
start Nothing = Just [l']
... | 410 | false | true | 5 | 10 | 168 | 210 | 105 | 105 | null | null |
frantisekfarka/ghc-dsi | compiler/nativeGen/PPC/Ppr.hs | bsd-3-clause | pprInstr (MULLW reg1 reg2 ri@(RIImm _)) = pprLogic (sLit "mull") reg1 reg2 ri | 77 | pprInstr (MULLW reg1 reg2 ri@(RIImm _)) = pprLogic (sLit "mull") reg1 reg2 ri | 77 | pprInstr (MULLW reg1 reg2 ri@(RIImm _)) = pprLogic (sLit "mull") reg1 reg2 ri | 77 | false | false | 0 | 9 | 12 | 44 | 21 | 23 | null | null |
mitchellwrosen/inline-c | src/Language/C/Inline/Context.hs | mit | funPtrAntiQuoter :: AntiQuoter HaskellIdentifier
funPtrAntiQuoter = AntiQuoter
{ aqParser = cDeclAqParser
, aqMarshaller = \purity cTypes cTy cId -> do
hsTy <- convertType_ "funCtx" purity cTypes cTy
hsExp <- getHsVariable "funCtx" cId
case hsTy of
TH.AppT (TH.ConT n) hsTy' | n == ''FunPtr... | 645 | funPtrAntiQuoter :: AntiQuoter HaskellIdentifier
funPtrAntiQuoter = AntiQuoter
{ aqParser = cDeclAqParser
, aqMarshaller = \purity cTypes cTy cId -> do
hsTy <- convertType_ "funCtx" purity cTypes cTy
hsExp <- getHsVariable "funCtx" cId
case hsTy of
TH.AppT (TH.ConT n) hsTy' | n == ''FunPtr... | 645 | funPtrAntiQuoter = AntiQuoter
{ aqParser = cDeclAqParser
, aqMarshaller = \purity cTypes cTy cId -> do
hsTy <- convertType_ "funCtx" purity cTypes cTy
hsExp <- getHsVariable "funCtx" cId
case hsTy of
TH.AppT (TH.ConT n) hsTy' | n == ''FunPtr -> do
hsExp' <- [| \cont -> do
... | 596 | false | true | 0 | 18 | 208 | 142 | 69 | 73 | null | null |
tomwadeson/adventofcode | 02.hs | mit | smallestSide :: Box -> Int
smallestSide = minimum . sides | 57 | smallestSide :: Box -> Int
smallestSide = minimum . sides | 57 | smallestSide = minimum . sides | 30 | false | true | 0 | 5 | 9 | 19 | 10 | 9 | null | null |
vaporware/carnival | SendMail.hs | mit | sendMail :: Mail -> Handler ()
sendMail m = send =<< liftIO (overrideRecipients m)
where
send = if appSendMail compileTimeAppSettings
then sendViaSendGrid
else sendToLog | 192 | sendMail :: Mail -> Handler ()
sendMail m = send =<< liftIO (overrideRecipients m)
where
send = if appSendMail compileTimeAppSettings
then sendViaSendGrid
else sendToLog | 192 | sendMail m = send =<< liftIO (overrideRecipients m)
where
send = if appSendMail compileTimeAppSettings
then sendViaSendGrid
else sendToLog | 161 | false | true | 0 | 8 | 46 | 55 | 27 | 28 | null | null |
distillation/language-core | Language/Core/Test/TestSyntax.hs | gpl-3.0 | testRebuildBangType = [(LHE.UnBangedTy (LHE.TyVar (LHE.Ident "name"))) ~=? (rebuildBangType (makeBangDataType "name" [])),
(LHE.UnBangedTy (LHE.TyApp (LHE.TyCon (LHE.UnQual (LHE.Ident "name"))) (LHE.TyVar (LHE.Ident "var")))) ~=? (rebuildBangType (makeBangDataType "name" ["var"])),
... | 539 | testRebuildBangType = [(LHE.UnBangedTy (LHE.TyVar (LHE.Ident "name"))) ~=? (rebuildBangType (makeBangDataType "name" [])),
(LHE.UnBangedTy (LHE.TyApp (LHE.TyCon (LHE.UnQual (LHE.Ident "name"))) (LHE.TyVar (LHE.Ident "var")))) ~=? (rebuildBangType (makeBangDataType "name" ["var"])),
... | 539 | testRebuildBangType = [(LHE.UnBangedTy (LHE.TyVar (LHE.Ident "name"))) ~=? (rebuildBangType (makeBangDataType "name" [])),
(LHE.UnBangedTy (LHE.TyApp (LHE.TyCon (LHE.UnQual (LHE.Ident "name"))) (LHE.TyVar (LHE.Ident "var")))) ~=? (rebuildBangType (makeBangDataType "name" ["var"])),
... | 539 | false | false | 0 | 19 | 89 | 246 | 126 | 120 | null | null |
phaazon/OpenGLRaw | src/Graphics/Rendering/OpenGL/Raw/Tokens.hs | bsd-3-clause | gl_OBJECT_TYPE_ARB :: GLenum
gl_OBJECT_TYPE_ARB = 0x8B4E | 56 | gl_OBJECT_TYPE_ARB :: GLenum
gl_OBJECT_TYPE_ARB = 0x8B4E | 56 | gl_OBJECT_TYPE_ARB = 0x8B4E | 27 | false | true | 0 | 4 | 5 | 11 | 6 | 5 | null | null |
spechub/Hets | TPTP/Parser.hs | gpl-2.0 | -- <atomic_word> ::= <lower_word> | <single_quoted>
-- %----<single_quoted> tokens do not include their outer quotes, therefore the
-- %----<lower_word> <atomic_word> cat and the <single_quoted> <atomic_word> 'cat'
-- %----are the same. Quotes must be removed from a <single_quoted> <atomic_word>
-- %----if doi... | 931 | atomic_word :: CharParser st Token
atomic_word = parserTrace "atomic_word" (
pToken lower_word
<|> do
s <- single_quoted
let sNoQuotes = removeQuotes $ tokStr s
case runParser lower_word () "" sNoQuotes of
Right _ -> return $ s { tokStr = sNoQuotes }
Left _ -> return s
<?> "atomic_word"
... | 442 | atomic_word = parserTrace "atomic_word" (
pToken lower_word
<|> do
s <- single_quoted
let sNoQuotes = removeQuotes $ tokStr s
case runParser lower_word () "" sNoQuotes of
Right _ -> return $ s { tokStr = sNoQuotes }
Left _ -> return s
<?> "atomic_word"
)
where
removeQuotes :: Strin... | 407 | true | true | 2 | 16 | 183 | 139 | 70 | 69 | null | null |
wuerges/vlsi_verification | test/TestBase.hs | bsd-3-clause | fileNames = concat [complete f | f <- files] | 44 | fileNames = concat [complete f | f <- files] | 44 | fileNames = concat [complete f | f <- files] | 44 | false | false | 1 | 8 | 8 | 27 | 11 | 16 | null | null |
markus-git/co-feldspar | src/Feldspar/Software/Optimize.hs | bsd-3-clause | -- | projection with a stronger constraint to allow using it in
-- bidirectional patterns.
prjBi :: (sub :<: sup) => sup sig -> Maybe (sub sig)
prjBi = prj | 157 | prjBi :: (sub :<: sup) => sup sig -> Maybe (sub sig)
prjBi = prj | 64 | prjBi = prj | 11 | true | true | 0 | 9 | 31 | 40 | 21 | 19 | null | null |
GaloisInc/halvm-ghc | compiler/basicTypes/BasicTypes.hs | bsd-3-clause | tupleParens :: TupleSort -> SDoc -> SDoc
tupleParens BoxedTuple p = parens p | 81 | tupleParens :: TupleSort -> SDoc -> SDoc
tupleParens BoxedTuple p = parens p | 81 | tupleParens BoxedTuple p = parens p | 40 | false | true | 0 | 6 | 17 | 32 | 14 | 18 | null | null |
Wolfchase/Sniffer | dist/build/autogen/Paths_sniffer.hs | gpl-3.0 | getBinDir, getLibDir, getDataDir, getLibexecDir, getSysconfDir :: IO FilePath
getBinDir = catchIO (getEnv "sniffer_bindir") (\_ -> return bindir) | 145 | getBinDir, getLibDir, getDataDir, getLibexecDir, getSysconfDir :: IO FilePath
getBinDir = catchIO (getEnv "sniffer_bindir") (\_ -> return bindir) | 145 | getBinDir = catchIO (getEnv "sniffer_bindir") (\_ -> return bindir) | 67 | false | true | 0 | 8 | 16 | 44 | 26 | 18 | null | null |
ideas-edu/ideas | src/Ideas/Common/Strategy/Configuration.hs | apache-2.0 | repeatDecl :: Decl Unary -- fix me: overlap with combinators
repeatDecl = "repeat1" .=. Unary repeat1 | 102 | repeatDecl :: Decl Unary
repeatDecl = "repeat1" .=. Unary repeat1 | 65 | repeatDecl = "repeat1" .=. Unary repeat1 | 40 | true | true | 0 | 6 | 16 | 22 | 11 | 11 | null | null |
plcplc/encapsulated-resources | src/System/EncapsulatedResources.hs | gpl-3.0 | -- ^ Wildcard matching
-- | Initialize the mechanics for interacting with resources in this process
-- resource.
runResourceM :: ResourcesPosixSettings -> String -> ResourceM a -> IO ()
runResourceM settings name act = do
rootDir <- maybe
(getProgName >>= mkdtemp)
(pure)
(rpsRootDir settings)
rootChan ... | 594 | runResourceM :: ResourcesPosixSettings -> String -> ResourceM a -> IO ()
runResourceM settings name act = do
rootDir <- maybe
(getProgName >>= mkdtemp)
(pure)
(rpsRootDir settings)
rootChan <- atomically $ newTChan
tId <- myThreadId
rootRes <- atomically $ newRes name rootDir rootChan tId (return ()... | 480 | runResourceM settings name act = do
rootDir <- maybe
(getProgName >>= mkdtemp)
(pure)
(rpsRootDir settings)
rootChan <- atomically $ newTChan
tId <- myThreadId
rootRes <- atomically $ newRes name rootDir rootChan tId (return ())
catch (evalStateT act rootRes >> return ())
(\DestroyResourceExce... | 407 | true | true | 0 | 13 | 113 | 162 | 77 | 85 | null | null |
phischu/fragnix | tests/packages/scotty/System.FilePath.Posix.hs | bsd-3-clause | -- | Delete the drive, if it exists.
--
-- > dropDrive x == snd (splitDrive x)
dropDrive :: FilePath -> FilePath
dropDrive = snd . splitDrive | 141 | dropDrive :: FilePath -> FilePath
dropDrive = snd . splitDrive | 62 | dropDrive = snd . splitDrive | 28 | true | true | 0 | 5 | 26 | 22 | 13 | 9 | null | null |
sopvop/snap-core | test/Snap/Core/Tests.hs | bsd-3-clause | go :: Snap a -> IO (Request,Response)
go m = do
zomgRq <- mkZomgRq
runSnap m dummy timeoutModifier zomgRq
where
dummy !x = return $! (show x `using` rdeepseq) `seq` ()
timeoutModifier !f = return $! f 0 `seq` ()
------------------------------------------------------------------------------ | 310 | go :: Snap a -> IO (Request,Response)
go m = do
zomgRq <- mkZomgRq
runSnap m dummy timeoutModifier zomgRq
where
dummy !x = return $! (show x `using` rdeepseq) `seq` ()
timeoutModifier !f = return $! f 0 `seq` ()
------------------------------------------------------------------------------ | 310 | go m = do
zomgRq <- mkZomgRq
runSnap m dummy timeoutModifier zomgRq
where
dummy !x = return $! (show x `using` rdeepseq) `seq` ()
timeoutModifier !f = return $! f 0 `seq` ()
------------------------------------------------------------------------------ | 272 | false | true | 0 | 9 | 60 | 114 | 56 | 58 | null | null |
AndreasPK/stack | src/Data/Maybe/Extra.hs | bsd-3-clause | -- | @'forMaybeA' '==' 'flip' 'mapMaybeA'@
forMaybeA :: Applicative f => [a] -> (a -> f (Maybe b)) -> f [b]
forMaybeA = flip mapMaybeA | 134 | forMaybeA :: Applicative f => [a] -> (a -> f (Maybe b)) -> f [b]
forMaybeA = flip mapMaybeA | 91 | forMaybeA = flip mapMaybeA | 26 | true | true | 0 | 13 | 24 | 61 | 29 | 32 | null | null |
pgj/bead | src/Bead/Persistence/SQL/TestData.hs | bsd-3-clause | reg = UserRegistration "username" "email" "name" "token" time | 61 | reg = UserRegistration "username" "email" "name" "token" time | 61 | reg = UserRegistration "username" "email" "name" "token" time | 61 | false | false | 1 | 5 | 7 | 20 | 8 | 12 | null | null |
vincenthz/hs-cryptohash | Tests/KAT.hs | bsd-3-clause | sha512Hash = HashFct { fctHash = SHA512.hash, fctInc = hashinc SHA512.init SHA512.update SHA512.finalize } | 106 | sha512Hash = HashFct { fctHash = SHA512.hash, fctInc = hashinc SHA512.init SHA512.update SHA512.finalize } | 106 | sha512Hash = HashFct { fctHash = SHA512.hash, fctInc = hashinc SHA512.init SHA512.update SHA512.finalize } | 106 | false | false | 1 | 9 | 13 | 42 | 20 | 22 | null | null |
spechub/Hets | HasCASL/Morphism.hs | gpl-2.0 | -- | only rename the kinds in a type
mapKindsOfType :: IdMap -> TypeMap -> IdMap -> Type -> Type
mapKindsOfType jm tm im = foldType mapTypeRec
{ foldTypeAbs = \ _ -> TypeAbs . mapTypeArg jm tm im
, foldKindedType = \ _ t -> KindedType t . Set.map (mapKindI jm) } | 270 | mapKindsOfType :: IdMap -> TypeMap -> IdMap -> Type -> Type
mapKindsOfType jm tm im = foldType mapTypeRec
{ foldTypeAbs = \ _ -> TypeAbs . mapTypeArg jm tm im
, foldKindedType = \ _ t -> KindedType t . Set.map (mapKindI jm) } | 233 | mapKindsOfType jm tm im = foldType mapTypeRec
{ foldTypeAbs = \ _ -> TypeAbs . mapTypeArg jm tm im
, foldKindedType = \ _ t -> KindedType t . Set.map (mapKindI jm) } | 173 | true | true | 0 | 12 | 60 | 97 | 49 | 48 | null | null |
mrakgr/futhark | src/Futhark/Pass/ExtractKernels.hs | bsd-3-clause | isSegmentedOp :: KernelNest
-> [Int]
-> SubExp
-> Out.Lambda
-> [(SubExp, VName)]
-> (Pattern
-> Pattern
-> SubExp
-> SubExp
-> [(SubExp, VName)]
-> Binder Out.... | 3,283 | isSegmentedOp :: KernelNest
-> [Int]
-> SubExp
-> Out.Lambda
-> [(SubExp, VName)]
-> (Pattern
-> Pattern
-> SubExp
-> SubExp
-> [(SubExp, VName)]
-> Binder Out.... | 3,283 | isSegmentedOp nest perm segment_size lam scan_inps m = runMaybeT $ do
-- We must verify that array inputs to the operation are inputs to
-- the outermost loop nesting or free in the loop nest, and that
-- none of the names bound by the loop nest are used in the lambda.
-- Furthermore, the neutral elements must ... | 2,904 | false | true | 0 | 27 | 1,153 | 814 | 389 | 425 | null | null |
tjakway/ghcjvm | compiler/types/Coercion.hs | bsd-3-clause | seqCo (AppCo co1 co2) = seqCo co1 `seq` seqCo co2 | 59 | seqCo (AppCo co1 co2) = seqCo co1 `seq` seqCo co2 | 59 | seqCo (AppCo co1 co2) = seqCo co1 `seq` seqCo co2 | 59 | false | false | 0 | 6 | 19 | 30 | 14 | 16 | null | null |
githubkleon/ConvenientHDL | src/Language/Cynide/PrettyPrint.hs | bsd-3-clause | -- -----------------------------------------------------------------------------
-- Miscellaneous
ppParamAssigns :: [ParamAssign] -> Doc
ppParamAssigns paramAssigns
= commasep (map ppParamAssign paramAssigns) | 211 | ppParamAssigns :: [ParamAssign] -> Doc
ppParamAssigns paramAssigns
= commasep (map ppParamAssign paramAssigns) | 112 | ppParamAssigns paramAssigns
= commasep (map ppParamAssign paramAssigns) | 73 | true | true | 0 | 7 | 18 | 40 | 19 | 21 | null | null |
axch/dysvunctional-language | haskell-fol/FOL/Language/Expression.hs | agpl-3.0 | fringe (AnnVectorSh ss) = concatMap fringe ss | 46 | fringe (AnnVectorSh ss) = concatMap fringe ss | 46 | fringe (AnnVectorSh ss) = concatMap fringe ss | 46 | false | false | 0 | 6 | 7 | 21 | 9 | 12 | null | null |
yihuang/cabal-install | Main.hs | bsd-3-clause | unpackAction :: UnpackFlags -> [String] -> GlobalFlags -> IO ()
unpackAction unpackFlags extraArgs globalFlags = do
let verbosity = fromFlag (unpackVerbosity unpackFlags)
targets <- readUserTargets verbosity extraArgs
config <- loadConfig verbosity (globalConfigFile globalFlags) mempty
let globalFlags' = savedG... | 487 | unpackAction :: UnpackFlags -> [String] -> GlobalFlags -> IO ()
unpackAction unpackFlags extraArgs globalFlags = do
let verbosity = fromFlag (unpackVerbosity unpackFlags)
targets <- readUserTargets verbosity extraArgs
config <- loadConfig verbosity (globalConfigFile globalFlags) mempty
let globalFlags' = savedG... | 487 | unpackAction unpackFlags extraArgs globalFlags = do
let verbosity = fromFlag (unpackVerbosity unpackFlags)
targets <- readUserTargets verbosity extraArgs
config <- loadConfig verbosity (globalConfigFile globalFlags) mempty
let globalFlags' = savedGlobalFlags config `mappend` globalFlags
unpack verbosity
... | 423 | false | true | 0 | 12 | 94 | 132 | 62 | 70 | null | null |
seckcoder/vector | Data/Vector/Fusion/Bundle/Monadic.hs | bsd-3-clause | foldl f = foldlM (\a b -> return (f a b)) | 41 | foldl f = foldlM (\a b -> return (f a b)) | 41 | foldl f = foldlM (\a b -> return (f a b)) | 41 | false | false | 1 | 10 | 10 | 37 | 16 | 21 | null | null |
distrap/ivory-tower-canopen | src/CANOpen/Tower/NMT.hs | bsd-3-clause | nmtCmd Stop = 0x02 | 18 | nmtCmd Stop = 0x02 | 18 | nmtCmd Stop = 0x02 | 18 | false | false | 0 | 5 | 3 | 9 | 4 | 5 | null | null |
nickng/gong | GoTypes.hs | apache-2.0 | unfoldTop :: Eqn -> M Eqn
unfoldTop (EqnSys bnd) = do
(r,body) <- unbind bnd
let vars = unrec r
let newbody = L.foldr (\(x,Embed rhs) body -> subst x rhs body) body vars
bla <- unfoldType newbody
return $ EqnSys (bind (rec vars) bla)
---- Fencing predicate for types ----
-- G ; ~y ; ~z |-t T
--... | 568 | unfoldTop :: Eqn -> M Eqn
unfoldTop (EqnSys bnd) = do
(r,body) <- unbind bnd
let vars = unrec r
let newbody = L.foldr (\(x,Embed rhs) body -> subst x rhs body) body vars
bla <- unfoldType newbody
return $ EqnSys (bind (rec vars) bla)
---- Fencing predicate for types ----
-- G ; ~y ; ~z |-t T
--... | 568 | unfoldTop (EqnSys bnd) = do
(r,body) <- unbind bnd
let vars = unrec r
let newbody = L.foldr (\(x,Embed rhs) body -> subst x rhs body) body vars
bla <- unfoldType newbody
return $ EqnSys (bind (rec vars) bla)
---- Fencing predicate for types ----
-- G ; ~y ; ~z |-t T
-- G records previously enco... | 542 | false | true | 0 | 14 | 128 | 139 | 69 | 70 | null | null |
jbddc/vf-verifier | src/VCGenerator.hs | gpl-3.0 | replaceExp idents s expr (Addition e1 e2) = Addition (replaceExp idents s expr e1) (replaceExp idents s expr e2) | 112 | replaceExp idents s expr (Addition e1 e2) = Addition (replaceExp idents s expr e1) (replaceExp idents s expr e2) | 112 | replaceExp idents s expr (Addition e1 e2) = Addition (replaceExp idents s expr e1) (replaceExp idents s expr e2) | 112 | false | false | 0 | 7 | 18 | 52 | 25 | 27 | null | null |
rkday/github-dashboard | github-dashboard.hs | mit | ain =
do
cfg <- load [Required "./githubissues.cfg"]
lst <- require cfg "repoNames"
user <- require cfg "repoOwner"
oauthToken <- Data.Configurator.lookup cfg "oauthToken"
let oauth = fmap GithubOAuth oauthToken
ctd <- newIORef $ CrossThreadData (Right []) (Right []) (Right []) (... | 1,113 | main =
do
cfg <- load [Required "./githubissues.cfg"]
lst <- require cfg "repoNames"
user <- require cfg "repoOwner"
oauthToken <- Data.Configurator.lookup cfg "oauthToken"
let oauth = fmap GithubOAuth oauthToken
ctd <- newIORef $ CrossThreadData (Right []) (Right []) (Right []) ... | 1,113 | main =
do
cfg <- load [Required "./githubissues.cfg"]
lst <- require cfg "repoNames"
user <- require cfg "repoOwner"
oauthToken <- Data.Configurator.lookup cfg "oauthToken"
let oauth = fmap GithubOAuth oauthToken
ctd <- newIORef $ CrossThreadData (Right []) (Right []) (Right []) ... | 1,113 | false | false | 0 | 16 | 400 | 358 | 157 | 201 | null | null |
nimia/bottle | codeedit/Editor/CodeEdit/ExpressionEdit.hs | gpl-3.0 | expressionEventMap
:: MonadF m
=> Ancestry.ExpressionAncestry m
-> DataOps.ExpressionPtr m
-> HoleResultPicker m
-> CTransaction ViewTag m (EventHandlers (Transaction ViewTag m))
expressionEventMap ancestry exprPtr holePicker = do
(addArgDoc, addArgHandler) <-
transaction $ NextArg.makeAddArgHandler anc... | 1,351 | expressionEventMap
:: MonadF m
=> Ancestry.ExpressionAncestry m
-> DataOps.ExpressionPtr m
-> HoleResultPicker m
-> CTransaction ViewTag m (EventHandlers (Transaction ViewTag m))
expressionEventMap ancestry exprPtr holePicker = do
(addArgDoc, addArgHandler) <-
transaction $ NextArg.makeAddArgHandler anc... | 1,351 | expressionEventMap ancestry exprPtr holePicker = do
(addArgDoc, addArgHandler) <-
transaction $ NextArg.makeAddArgHandler ancestry exprPtr
return . mconcat $
[ moveUnlessOnHole .
Widget.actionEventMapMovesCursor
Config.giveAsArgumentKeys "Give as argument" .
WidgetIds.diveIn $ DataOps.give... | 1,162 | false | true | 3 | 14 | 269 | 355 | 171 | 184 | null | null |
peterokagey/haskellOEIS | src/Helpers/GridPolytopes.hs | apache-2.0 | -- Hexagons with side length k, all nonnegative coordinates, and touching the coordinate planes
normalized :: Polygon -> Integer -> [VertexSet]
normalized polygon k = nub $ map (\[v,u] -> makeShape polygon v u) $ adjacentSides polygon k | 236 | normalized :: Polygon -> Integer -> [VertexSet]
normalized polygon k = nub $ map (\[v,u] -> makeShape polygon v u) $ adjacentSides polygon k | 140 | normalized polygon k = nub $ map (\[v,u] -> makeShape polygon v u) $ adjacentSides polygon k | 92 | true | true | 2 | 9 | 37 | 71 | 35 | 36 | null | null |
codecurve/FieldML-Haskell-01 | src/FieldML/Utility01.hs | bsd-2-clause | cardinality (Labels (StringLabels a)) = size a | 46 | cardinality (Labels (StringLabels a)) = size a | 46 | cardinality (Labels (StringLabels a)) = size a | 46 | false | false | 0 | 8 | 6 | 25 | 11 | 14 | null | null |
TypeDB/keyvalue | Database/KeyValue/LogOperations.hs | gpl-3.0 | addNewRecord :: FilePath -> IO (Handle, Handle)
addNewRecord dir = do
(hintFile, hintHandle) <- openNewBinaryFile dir hintExt
recordHandle <- openBinaryFile (replaceExtension hintFile recordExt) ReadWriteMode
hSetBuffering hintHandle NoBuffering
hSetBuffering recordHandle NoBuffering
return (hintHandle, recor... | 435 | addNewRecord :: FilePath -> IO (Handle, Handle)
addNewRecord dir = do
(hintFile, hintHandle) <- openNewBinaryFile dir hintExt
recordHandle <- openBinaryFile (replaceExtension hintFile recordExt) ReadWriteMode
hSetBuffering hintHandle NoBuffering
hSetBuffering recordHandle NoBuffering
return (hintHandle, recor... | 435 | addNewRecord dir = do
(hintFile, hintHandle) <- openNewBinaryFile dir hintExt
recordHandle <- openBinaryFile (replaceExtension hintFile recordExt) ReadWriteMode
hSetBuffering hintHandle NoBuffering
hSetBuffering recordHandle NoBuffering
return (hintHandle, recordHandle)
-- | Get all the keys from the hint fi... | 387 | false | true | 0 | 10 | 65 | 95 | 46 | 49 | null | null |
Oblosys/webviews | src/lib/BlazeHtml.hs | mit | html !!! attrs = foldl (!) html attrs | 37 | html !!! attrs = foldl (!) html attrs | 37 | html !!! attrs = foldl (!) html attrs | 37 | false | false | 3 | 5 | 7 | 23 | 10 | 13 | null | null |
ulricha/dsh | src/Database/DSH/SL/Opt/Properties/BottomUp.hs | bsd-3-clause | -- FIXME this is (almost) identical to its X100 counterpart -> merge
inferWorker :: NodeMap (SLOp r e) -> SLOp r e -> AlgNode -> NodeMap BottomUpProps -> BottomUpProps
inferWorker d op node pm =
case op of
TerOp vl c1 c2 c3 ->
let c1Props = lookupUnsafe pm "no children properties" c1
... | 1,021 | inferWorker :: NodeMap (SLOp r e) -> SLOp r e -> AlgNode -> NodeMap BottomUpProps -> BottomUpProps
inferWorker d op node pm =
case op of
TerOp vl c1 c2 c3 ->
let c1Props = lookupUnsafe pm "no children properties" c1
c2Props = lookupUnsafe pm "no children properties" c2
... | 952 | inferWorker d op node pm =
case op of
TerOp vl c1 c2 c3 ->
let c1Props = lookupUnsafe pm "no children properties" c1
c2Props = lookupUnsafe pm "no children properties" c2
c3Props = lookupUnsafe pm "no children properties" c3
in checkError d node [c1Props,... | 853 | true | true | 0 | 12 | 301 | 300 | 141 | 159 | null | null |
brendanhay/gogol | gogol-dfareporting/gen/Network/Google/Resource/DFAReporting/RemarketingLists/Patch.hs | mpl-2.0 | -- | OAuth access token.
rlpAccessToken :: Lens' RemarketingListsPatch (Maybe Text)
rlpAccessToken
= lens _rlpAccessToken
(\ s a -> s{_rlpAccessToken = a}) | 163 | rlpAccessToken :: Lens' RemarketingListsPatch (Maybe Text)
rlpAccessToken
= lens _rlpAccessToken
(\ s a -> s{_rlpAccessToken = a}) | 138 | rlpAccessToken
= lens _rlpAccessToken
(\ s a -> s{_rlpAccessToken = a}) | 79 | true | true | 1 | 9 | 29 | 51 | 25 | 26 | null | null |
jhickner/haskell-modbus | test/Data/ModbusSpec.hs | bsd-3-clause | singleEncodeResult :: [ByteString]
singleEncodeResult = pack <$> [ [1,0,1,0,1]
, [2,0,1,0,1]
, [3,0,1,0,1]
, [4,0,1,0,1]
, [5,0,1,0,1]
, [6,0,1,0,1]
... | 492 | singleEncodeResult :: [ByteString]
singleEncodeResult = pack <$> [ [1,0,1,0,1]
, [2,0,1,0,1]
, [3,0,1,0,1]
, [4,0,1,0,1]
, [5,0,1,0,1]
, [6,0,1,0,1]
... | 492 | singleEncodeResult = pack <$> [ [1,0,1,0,1]
, [2,0,1,0,1]
, [3,0,1,0,1]
, [4,0,1,0,1]
, [5,0,1,0,1]
, [6,0,1,0,1]
, [8,0,1,0,1]
... | 457 | false | true | 0 | 8 | 295 | 217 | 139 | 78 | null | null |
rueshyna/gogol | gogol-dfareporting/gen/Network/Google/DFAReporting/Types/Product.hs | mpl-2.0 | -- | Whether Flash assets associated with the creative need to be
-- automatically converted to HTML5. This flag is enabled by default and
-- users can choose to disable it if they don\'t want the system to
-- generate and use HTML5 asset for this creative. Applicable to the
-- following creative type: FLASH_INPAGE. Ap... | 547 | creConvertFlashToHTML5 :: Lens' Creative (Maybe Bool)
creConvertFlashToHTML5
= lens _creConvertFlashToHTML5
(\ s a -> s{_creConvertFlashToHTML5 = a}) | 157 | creConvertFlashToHTML5
= lens _creConvertFlashToHTML5
(\ s a -> s{_creConvertFlashToHTML5 = a}) | 103 | true | true | 0 | 8 | 91 | 54 | 30 | 24 | null | null |
bos/text | tests/Tests/Properties/Basics.hs | bsd-2-clause | s_cons_s x = (x:) `eqP` (unpackS . S.unstream . S.cons x) | 68 | s_cons_s x = (x:) `eqP` (unpackS . S.unstream . S.cons x) | 68 | s_cons_s x = (x:) `eqP` (unpackS . S.unstream . S.cons x) | 68 | false | false | 0 | 9 | 21 | 37 | 20 | 17 | null | null |
zhiyuanshi/fcore | frontend/simplify/SimplifyImpl.hs | bsd-2-clause | infer i j (FI.Data _ _ e) = infer i j e | 47 | infer i j (FI.Data _ _ e) = infer i j e | 47 | infer i j (FI.Data _ _ e) = infer i j e | 47 | false | false | 0 | 8 | 19 | 32 | 15 | 17 | null | null |
spechub/Hets | CommonLogic/ClTests.hs | gpl-2.0 | ct :: TERM
ct = Name_term (Token "Cat" nullRange) | 49 | ct :: TERM
ct = Name_term (Token "Cat" nullRange) | 49 | ct = Name_term (Token "Cat" nullRange) | 38 | false | true | 0 | 7 | 8 | 22 | 11 | 11 | null | null |
mightymoose/liquidhaskell | benchmarks/text-0.11.2.3/Data/Text/Encoding/Fusion/Common.hs | bsd-3-clause | restreamUtf32BE :: Stream Char -> Stream Word8
restreamUtf32BE (Stream next0 s0 len) = Stream next (RS0 s0) (len * 2)
where
next (RS0 s) = case next0 s of
Done -> Done
Skip s' -> Skip (RS0 s')
Yield x s' -> Yield c1 (RS3 s' c2 c3 c4)
where
n = ord x
... | 643 | restreamUtf32BE :: Stream Char -> Stream Word8
restreamUtf32BE (Stream next0 s0 len) = Stream next (RS0 s0) (len * 2)
where
next (RS0 s) = case next0 s of
Done -> Done
Skip s' -> Skip (RS0 s')
Yield x s' -> Yield c1 (RS3 s' c2 c3 c4)
where
n = ord x
... | 643 | restreamUtf32BE (Stream next0 s0 len) = Stream next (RS0 s0) (len * 2)
where
next (RS0 s) = case next0 s of
Done -> Done
Skip s' -> Skip (RS0 s')
Yield x s' -> Yield c1 (RS3 s' c2 c3 c4)
where
n = ord x
c1 = fromIntegral $ shiftR n 24
... | 596 | false | true | 3 | 12 | 251 | 283 | 138 | 145 | null | null |
janschulz/pandoc | src/Text/Pandoc/Readers/OPML.hs | gpl-2.0 | readOPML :: ReaderOptions -> String -> Either PandocError Pandoc
readOPML _ inp = setTitle (opmlDocTitle st')
. setAuthors (opmlDocAuthors st')
. setDate (opmlDocDate st')
. doc . mconcat <$> bs
where (bs, st') = flip runState def . runExceptT $ (mapM parseBlo... | 421 | readOPML :: ReaderOptions -> String -> Either PandocError Pandoc
readOPML _ inp = setTitle (opmlDocTitle st')
. setAuthors (opmlDocAuthors st')
. setDate (opmlDocDate st')
. doc . mconcat <$> bs
where (bs, st') = flip runState def . runExceptT $ (mapM parseBlo... | 421 | readOPML _ inp = setTitle (opmlDocTitle st')
. setAuthors (opmlDocAuthors st')
. setDate (opmlDocDate st')
. doc . mconcat <$> bs
where (bs, st') = flip runState def . runExceptT $ (mapM parseBlock $ normalizeTree $ parseXML inp)
-- normalize input, consolida... | 356 | false | true | 0 | 12 | 116 | 121 | 59 | 62 | null | null |
rodrigo-machado/verigraph | src/library/XML/XMLUtilities.hs | gpl-3.0 | textAtTag :: ArrowXml cat => String -> cat (Data.Tree.NTree.TypeDefs.NTree XNode) String
textAtTag tag = atTag tag >>> text | 123 | textAtTag :: ArrowXml cat => String -> cat (Data.Tree.NTree.TypeDefs.NTree XNode) String
textAtTag tag = atTag tag >>> text | 123 | textAtTag tag = atTag tag >>> text | 34 | false | true | 0 | 10 | 17 | 48 | 24 | 24 | null | null |
josefs/autosar | oldARSim/ARXML.hs | bsd-3-clause | toDest "PARAMETER-SW-COMPONENT-TYPE" = RSEParameterSwComponentType | 66 | toDest "PARAMETER-SW-COMPONENT-TYPE" = RSEParameterSwComponentType | 66 | toDest "PARAMETER-SW-COMPONENT-TYPE" = RSEParameterSwComponentType | 66 | false | false | 0 | 5 | 3 | 9 | 4 | 5 | null | null |
vito/atomo | src/Atomo/Pretty.hs | bsd-3-clause | headlessKeywords'' _ _ _ = empty | 32 | headlessKeywords'' _ _ _ = empty | 32 | headlessKeywords'' _ _ _ = empty | 32 | false | false | 0 | 5 | 5 | 13 | 6 | 7 | null | null |
coursestitch/coursestitch-api | lib/CourseStitch/Models/Queries.hs | apache-2.0 | deleteSessions :: Token -> SqlPersistT IO ()
deleteSessions token = deleteWhere [SessionToken P.==. token] | 106 | deleteSessions :: Token -> SqlPersistT IO ()
deleteSessions token = deleteWhere [SessionToken P.==. token] | 106 | deleteSessions token = deleteWhere [SessionToken P.==. token] | 61 | false | true | 0 | 7 | 13 | 37 | 18 | 19 | null | null |
d0kt0r0/Tidal | test/Sound/Tidal/ParseTest.hs | gpl-3.0 | run :: Microspec ()
run =
describe "Sound.Tidal.Parse" $ do
describe "parseBP_E" $ do
it "can parse strings" $ do
compareP (Arc 0 12)
("a b c" :: Pattern String)
(fastCat ["a", "b", "c"])
it "can parse ints" $ do
compareP (Arc 0 2)
("0 1 2 3 4 5 6 7 8 0 10... | 4,206 | run :: Microspec ()
run =
describe "Sound.Tidal.Parse" $ do
describe "parseBP_E" $ do
it "can parse strings" $ do
compareP (Arc 0 12)
("a b c" :: Pattern String)
(fastCat ["a", "b", "c"])
it "can parse ints" $ do
compareP (Arc 0 2)
("0 1 2 3 4 5 6 7 8 0 10... | 4,206 | run =
describe "Sound.Tidal.Parse" $ do
describe "parseBP_E" $ do
it "can parse strings" $ do
compareP (Arc 0 12)
("a b c" :: Pattern String)
(fastCat ["a", "b", "c"])
it "can parse ints" $ do
compareP (Arc 0 2)
("0 1 2 3 4 5 6 7 8 0 10 20 30 40 50" :: Pat... | 4,186 | false | true | 0 | 21 | 1,574 | 1,365 | 658 | 707 | null | null |
deweyvm/starstats | src/StarStats/DB/Connection.hs | mit | close :: IConnection c => c -> IO ()
close con = do
disconnect con | 70 | close :: IConnection c => c -> IO ()
close con = do
disconnect con | 70 | close con = do
disconnect con | 33 | false | true | 0 | 9 | 18 | 41 | 17 | 24 | null | null |
kaoskorobase/arff | Text/ARFF.hs | bsd-2-clause | putReal _ MissingValue = putMissingValue | 47 | putReal _ MissingValue = putMissingValue | 47 | putReal _ MissingValue = putMissingValue | 47 | false | false | 1 | 5 | 11 | 13 | 5 | 8 | null | null |
SergeyKrivohatskiy/fp_haskell | hw11/Parser/Main.hs | mit | main = fmap (const ()) $ runTestTT $ test
$ label "pure"
[ parserTestOK (pure 4) "qwerty" === (4, "qwerty")
, parserTestOK (pure 'x') "" === ('x', "")
] ++ label "empty"
[ parserTestFail (empty :: Parser Char ()) "qwerty"
, parserTestFail (empty :: Parser Char ()) ""
] ++ label ... | 8,445 | main = fmap (const ()) $ runTestTT $ test
$ label "pure"
[ parserTestOK (pure 4) "qwerty" === (4, "qwerty")
, parserTestOK (pure 'x') "" === ('x', "")
] ++ label "empty"
[ parserTestFail (empty :: Parser Char ()) "qwerty"
, parserTestFail (empty :: Parser Char ()) ""
] ++ label ... | 8,445 | main = fmap (const ()) $ runTestTT $ test
$ label "pure"
[ parserTestOK (pure 4) "qwerty" === (4, "qwerty")
, parserTestOK (pure 'x') "" === ('x', "")
] ++ label "empty"
[ parserTestFail (empty :: Parser Char ()) "qwerty"
, parserTestFail (empty :: Parser Char ()) ""
] ++ label ... | 8,445 | false | false | 2 | 16 | 2,208 | 3,340 | 1,781 | 1,559 | null | null |
TeensyPass/teensy_pass_haskell | Cli.hs | gpl-2.0 | insertParser = InsertOptions
<$> switch (long "echo" <> short 'e')
<*> switch (long "multiline" <> short 'm')
<*> forceParser
<*> passNameParser | 204 | insertParser = InsertOptions
<$> switch (long "echo" <> short 'e')
<*> switch (long "multiline" <> short 'm')
<*> forceParser
<*> passNameParser | 204 | insertParser = InsertOptions
<$> switch (long "echo" <> short 'e')
<*> switch (long "multiline" <> short 'm')
<*> forceParser
<*> passNameParser | 204 | false | false | 0 | 12 | 80 | 54 | 25 | 29 | null | null |
beni55/libmpd-haskell | tests/UtilSpec.hs | mit | prop_parseDate_simple :: YearString -> Bool
prop_parseDate_simple (YS x) = isJust $ parseDate x | 95 | prop_parseDate_simple :: YearString -> Bool
prop_parseDate_simple (YS x) = isJust $ parseDate x | 95 | prop_parseDate_simple (YS x) = isJust $ parseDate x | 51 | false | true | 0 | 7 | 12 | 31 | 15 | 16 | null | null |
agremm/par-sched | src/Parallel/Graph.hs | gpl-2.0 | buildGraph :: [Task a] -> IO (P.Gr (NLabel a) ELabel)
buildGraph ts = do
graphs <- mapM task2Graph ts
let nodes = concat $ map labNodes graphs
let edges = concat $ map labEdges graphs
let graph = insEdges edges $ insNodes nodes empty
-- remove roots and outgoing edges to increase
-- components ... | 707 | buildGraph :: [Task a] -> IO (P.Gr (NLabel a) ELabel)
buildGraph ts = do
graphs <- mapM task2Graph ts
let nodes = concat $ map labNodes graphs
let edges = concat $ map labEdges graphs
let graph = insEdges edges $ insNodes nodes empty
-- remove roots and outgoing edges to increase
-- components ... | 707 | buildGraph ts = do
graphs <- mapM task2Graph ts
let nodes = concat $ map labNodes graphs
let edges = concat $ map labEdges graphs
let graph = insEdges edges $ insNodes nodes empty
-- remove roots and outgoing edges to increase
-- components and thus exploitable parallelism.
-- ... deleting ... | 653 | false | true | 0 | 14 | 177 | 198 | 97 | 101 | null | null |
ulricha/dsh-tpc-h | Queries/TPCH/Standard/Q6.hs | bsd-3-clause | -- | TPC-H Query Q6
q6 :: Day -> Decimal -> Decimal -> Q Decimal
q6 startDate discount quantity =
sum [ l_extendedpriceQ l * l_discountQ l
| l <- lineitems
, l_shipdateQ l >= toQ startDate
, l_shipdateQ l < toQ (C.addDays 365 startDate)
, between (l_discountQ l) lowerDiscount upperDiscount
... | 449 | q6 :: Day -> Decimal -> Decimal -> Q Decimal
q6 startDate discount quantity =
sum [ l_extendedpriceQ l * l_discountQ l
| l <- lineitems
, l_shipdateQ l >= toQ startDate
, l_shipdateQ l < toQ (C.addDays 365 startDate)
, between (l_discountQ l) lowerDiscount upperDiscount
, l_quantityQ l <... | 429 | q6 startDate discount quantity =
sum [ l_extendedpriceQ l * l_discountQ l
| l <- lineitems
, l_shipdateQ l >= toQ startDate
, l_shipdateQ l < toQ (C.addDays 365 startDate)
, between (l_discountQ l) lowerDiscount upperDiscount
, l_quantityQ l < toQ quantity
]
where
lowerDiscou... | 384 | true | true | 2 | 11 | 118 | 164 | 73 | 91 | null | null |
fffej/HS-Poker | LookupPatternMatch.hs | bsd-3-clause | getValueFromProduct 675 = 309 | 29 | getValueFromProduct 675 = 309 | 29 | getValueFromProduct 675 = 309 | 29 | false | false | 0 | 5 | 3 | 9 | 4 | 5 | null | null |
sdiehl/ghc | compiler/basicTypes/Literal.hs | bsd-3-clause | litTag (LitLabel _ _ _) = 6 | 29 | litTag (LitLabel _ _ _) = 6 | 29 | litTag (LitLabel _ _ _) = 6 | 29 | false | false | 0 | 6 | 8 | 20 | 9 | 11 | null | null |
rzil/honours | LeavittPathAlgebras/WeightedLPA.hs | mit | nodify weightedGraph (NormalFormAtom c v (e:es))
| (weightings weightedGraph M.! normalFormEdge e < normalFormEdgeWeighting e) = 0
| otherwise = (convertEdge e) * (nodify weightedGraph (NormalFormAtom c u es))
where u = (if normalFormEdgeIsGhost e then fst else snd) (edges (graph weightedGraph) M.! normalFormEdg... | 324 | nodify weightedGraph (NormalFormAtom c v (e:es))
| (weightings weightedGraph M.! normalFormEdge e < normalFormEdgeWeighting e) = 0
| otherwise = (convertEdge e) * (nodify weightedGraph (NormalFormAtom c u es))
where u = (if normalFormEdgeIsGhost e then fst else snd) (edges (graph weightedGraph) M.! normalFormEdg... | 324 | nodify weightedGraph (NormalFormAtom c v (e:es))
| (weightings weightedGraph M.! normalFormEdge e < normalFormEdgeWeighting e) = 0
| otherwise = (convertEdge e) * (nodify weightedGraph (NormalFormAtom c u es))
where u = (if normalFormEdgeIsGhost e then fst else snd) (edges (graph weightedGraph) M.! normalFormEdg... | 324 | false | false | 2 | 11 | 51 | 147 | 68 | 79 | null | null |
cmc-haskell-2016/reversi | src/GameRecolorCells.hs | bsd-3-clause | -- recalculate of total
changeCNT :: [Cell] -> CountBlackWhite -> CountBlackWhite
changeCNT ((Cell _ (Player p)) : xs) (cntBlack, cntWhite) = case p of
WhiteMove -> (changeCNT xs (cntBlack, cntWhite+1))
BlackMove -> (changeCNT xs (cntBlack+1, cntWhite)) | 262 | changeCNT :: [Cell] -> CountBlackWhite -> CountBlackWhite
changeCNT ((Cell _ (Player p)) : xs) (cntBlack, cntWhite) = case p of
WhiteMove -> (changeCNT xs (cntBlack, cntWhite+1))
BlackMove -> (changeCNT xs (cntBlack+1, cntWhite)) | 238 | changeCNT ((Cell _ (Player p)) : xs) (cntBlack, cntWhite) = case p of
WhiteMove -> (changeCNT xs (cntBlack, cntWhite+1))
BlackMove -> (changeCNT xs (cntBlack+1, cntWhite)) | 180 | true | true | 0 | 11 | 44 | 107 | 58 | 49 | null | null |
Gabriel439/Haskell-Errors-Library | Control/Error/Script.hs | bsd-3-clause | scriptIO :: (MonadIO m) => IO a -> ExceptT Text m a
scriptIO = ExceptT
. liftIO
. liftM (fmapL (Data.Text.pack . show))
. (try :: IO a -> IO (Either SomeException a)) | 193 | scriptIO :: (MonadIO m) => IO a -> ExceptT Text m a
scriptIO = ExceptT
. liftIO
. liftM (fmapL (Data.Text.pack . show))
. (try :: IO a -> IO (Either SomeException a)) | 193 | scriptIO = ExceptT
. liftIO
. liftM (fmapL (Data.Text.pack . show))
. (try :: IO a -> IO (Either SomeException a)) | 141 | false | true | 0 | 12 | 59 | 89 | 45 | 44 | null | null |
forked-upstream-packages-for-ghcjs/ghc | compiler/hsSyn/HsExpr.hs | bsd-3-clause | -- We know the list must have at least one @Match@ in it.
pprMatches :: (OutputableBndr idL, OutputableBndr idR, Outputable body)
=> HsMatchContext idL -> MatchGroup idR body -> SDoc
pprMatches ctxt (MG { mg_alts = matches })
= vcat (map (pprMatch ctxt) (map unLoc matches)) | 290 | pprMatches :: (OutputableBndr idL, OutputableBndr idR, Outputable body)
=> HsMatchContext idL -> MatchGroup idR body -> SDoc
pprMatches ctxt (MG { mg_alts = matches })
= vcat (map (pprMatch ctxt) (map unLoc matches)) | 231 | pprMatches ctxt (MG { mg_alts = matches })
= vcat (map (pprMatch ctxt) (map unLoc matches)) | 95 | true | true | 0 | 9 | 61 | 97 | 47 | 50 | null | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.