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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Mr-Click/PFQ | user/Haskell/Network/PFq/Default.hs | gpl-2.0 | bloom_src_filter m hs p = let ips = unsafePerformIO (mapM inet_addr hs) in MFunction "bloom_src_filter" m ips p () () () () () | 126 | bloom_src_filter m hs p = let ips = unsafePerformIO (mapM inet_addr hs) in MFunction "bloom_src_filter" m ips p () () () () () | 126 | bloom_src_filter m hs p = let ips = unsafePerformIO (mapM inet_addr hs) in MFunction "bloom_src_filter" m ips p () () () () () | 126 | false | false | 0 | 11 | 22 | 66 | 30 | 36 | null | null |
pasberth/binal1 | Language/Binal/StyleGuidance.hs | mit | isStyleError :: StyleError -> Bool
isStyleError (UnexpectedEOFWhileReading _) = True | 84 | isStyleError :: StyleError -> Bool
isStyleError (UnexpectedEOFWhileReading _) = True | 84 | isStyleError (UnexpectedEOFWhileReading _) = True | 49 | false | true | 0 | 7 | 9 | 24 | 12 | 12 | null | null |
mgsloan/crdt | src/Data/CRDT/Counter.hs | bsd-3-clause | incCount :: PartialOrd a => Inc a :-> a
incCount = lens getter setter
where
getter = unpack . unpack
setter x = Inc `over` join (Max x) | 140 | incCount :: PartialOrd a => Inc a :-> a
incCount = lens getter setter
where
getter = unpack . unpack
setter x = Inc `over` join (Max x) | 140 | incCount = lens getter setter
where
getter = unpack . unpack
setter x = Inc `over` join (Max x) | 100 | false | true | 3 | 8 | 32 | 82 | 34 | 48 | null | null |
viethnguyen/parse-logic | parse-logic.hs | gpl-2.0 | showExpr (AND a b) = (showExpr a) ++ " and " ++ (showExpr b) | 60 | showExpr (AND a b) = (showExpr a) ++ " and " ++ (showExpr b) | 60 | showExpr (AND a b) = (showExpr a) ++ " and " ++ (showExpr b) | 60 | false | false | 0 | 8 | 13 | 37 | 18 | 19 | null | null |
JPMoresmau/BuildWrapper | src/Language/Haskell/BuildWrapper/GHC.hs | bsd-3-clause | -- | get the GHC typechecked AST
getAST :: FilePath -- ^ the source file
-> FilePath -- ^ the base directory
-> String -- ^ the module name
-> [String] -- ^ the GHC options
-> IO (OpResult (Maybe TypecheckedSource))
getAST fp base_dir modul opts=do
(a,n)<-withASTNotes (\_ -> ret... | 474 | getAST :: FilePath -- ^ the source file
-> FilePath -- ^ the base directory
-> String -- ^ the module name
-> [String] -- ^ the GHC options
-> IO (OpResult (Maybe TypecheckedSource))
getAST fp base_dir modul opts=do
(a,n)<-withASTNotes (\_ -> return . tm_typechecked_source) id b... | 441 | getAST fp base_dir modul opts=do
(a,n)<-withASTNotes (\_ -> return . tm_typechecked_source) id base_dir (SingleFile fp modul) opts
return (listToMaybe a,n)
-- | perform an action on the GHC Typechecked module | 225 | true | true | 0 | 13 | 120 | 119 | 63 | 56 | null | null |
olsner/ghc | compiler/prelude/PrelNames.hs | bsd-3-clause | sourceUnpackDataConKey = mkPreludeDataConUnique 59 | 67 | sourceUnpackDataConKey = mkPreludeDataConUnique 59 | 67 | sourceUnpackDataConKey = mkPreludeDataConUnique 59 | 67 | false | false | 0 | 5 | 20 | 9 | 4 | 5 | null | null |
facebookincubator/duckling | Duckling/Rules/KA.hs | bsd-3-clause | langRules (Seal RegexMatch) = [] | 32 | langRules (Seal RegexMatch) = [] | 32 | langRules (Seal RegexMatch) = [] | 32 | false | false | 0 | 6 | 4 | 18 | 8 | 10 | null | null |
portnov/yaledger | YaLedger/Output/ASCII.hs | bsd-3-clause | align w ACenter str
| textLength str >= w = takeText w str
| otherwise =
let m = (w - textLength str) `div` 2
n = w - textLength str - m
pad1 = replicate m ' '
pad2 = replicate n ' '
in pad1 <> str <> pad2 | 241 | align w ACenter str
| textLength str >= w = takeText w str
| otherwise =
let m = (w - textLength str) `div` 2
n = w - textLength str - m
pad1 = replicate m ' '
pad2 = replicate n ' '
in pad1 <> str <> pad2 | 241 | align w ACenter str
| textLength str >= w = takeText w str
| otherwise =
let m = (w - textLength str) `div` 2
n = w - textLength str - m
pad1 = replicate m ' '
pad2 = replicate n ' '
in pad1 <> str <> pad2 | 241 | false | false | 4 | 13 | 86 | 121 | 55 | 66 | null | null |
vipo/TicTacToe | client/Main.hs | bsd-3-clause | move :: (String, String) -> Bool -> Int -> IO Bool
move p@(gameId, playerId) continue _ =
if not continue then return False
else do
board <- getBoard p
moves <- randomMoves
if D.thereIsWinner board then return False
else (postBoard p (appendMove board moves))
>>= (return . not . D.thereIsW... | 326 | move :: (String, String) -> Bool -> Int -> IO Bool
move p@(gameId, playerId) continue _ =
if not continue then return False
else do
board <- getBoard p
moves <- randomMoves
if D.thereIsWinner board then return False
else (postBoard p (appendMove board moves))
>>= (return . not . D.thereIsW... | 326 | move p@(gameId, playerId) continue _ =
if not continue then return False
else do
board <- getBoard p
moves <- randomMoves
if D.thereIsWinner board then return False
else (postBoard p (appendMove board moves))
>>= (return . not . D.thereIsWinner) | 275 | false | true | 0 | 13 | 79 | 131 | 66 | 65 | null | null |
patperry/permutation | lib/Data/Permute/IOBase.hs | bsd-3-clause | getSizeIOPermute :: IOPermute -> IO Int
getSizeIOPermute (IOPermute p) = stToIO $ getSizeSTPermute p | 100 | getSizeIOPermute :: IOPermute -> IO Int
getSizeIOPermute (IOPermute p) = stToIO $ getSizeSTPermute p | 100 | getSizeIOPermute (IOPermute p) = stToIO $ getSizeSTPermute p | 60 | false | true | 0 | 7 | 13 | 34 | 16 | 18 | null | null |
hsyl20/ViperVM | haskus-system/src/lib/Haskus/Arch/Common/Register.hs | bsd-3-clause | -- | Make a terminal register family matching a single register
regFamFromReg :: Reg b rt -> RegFamT b rt
regFamFromReg Reg{..} = RegFam
{ regFamBank = Singleton registerBank
, regFamId = Singleton registerId
, regFamSize = Singleton registerSize
, regFamOffset = Singleton registerOffset
, regFam... | 346 | regFamFromReg :: Reg b rt -> RegFamT b rt
regFamFromReg Reg{..} = RegFam
{ regFamBank = Singleton registerBank
, regFamId = Singleton registerId
, regFamSize = Singleton registerSize
, regFamOffset = Singleton registerOffset
, regFamType = registerType
} | 282 | regFamFromReg Reg{..} = RegFam
{ regFamBank = Singleton registerBank
, regFamId = Singleton registerId
, regFamSize = Singleton registerSize
, regFamOffset = Singleton registerOffset
, regFamType = registerType
} | 240 | true | true | 0 | 7 | 76 | 79 | 42 | 37 | null | null |
rueshyna/gogol | gogol-games/gen/Network/Google/Games/Types/Product.hs | mpl-2.0 | -- | Indicates whether the icon image being returned is a default image, or
-- is game-provided.
queIsDefaultIconURL :: Lens' Quest (Maybe Bool)
queIsDefaultIconURL
= lens _queIsDefaultIconURL
(\ s a -> s{_queIsDefaultIconURL = a}) | 239 | queIsDefaultIconURL :: Lens' Quest (Maybe Bool)
queIsDefaultIconURL
= lens _queIsDefaultIconURL
(\ s a -> s{_queIsDefaultIconURL = a}) | 142 | queIsDefaultIconURL
= lens _queIsDefaultIconURL
(\ s a -> s{_queIsDefaultIconURL = a}) | 94 | true | true | 0 | 9 | 41 | 49 | 26 | 23 | null | null |
sdiehl/ghc | compiler/GHC/CmmToC.hs | bsd-3-clause | -- Note [StgWord alignment]
-- C codegen builds static closures as StgWord C arrays (pprWordArray).
-- Their real C type is 'StgClosure'. Macros like UNTAG_CLOSURE assume
-- pointers to 'StgClosure' are aligned at pointer size boundary:
-- 4 byte boundary on 32 systems
-- and 8 bytes on 64-bit systems
-- see TAG_MASK... | 900 | pprLocalness :: CLabel -> SDoc
pprLocalness lbl | not $ externallyVisibleCLabel lbl = text "static "
| otherwise = empty | 137 | pprLocalness lbl | not $ externallyVisibleCLabel lbl = text "static "
| otherwise = empty | 106 | true | true | 0 | 9 | 163 | 70 | 40 | 30 | null | null |
brendanhay/gogol | gogol-logging/gen/Network/Google/Resource/Logging/Projects/Locations/Buckets/List.hs | mpl-2.0 | -- | Creates a value of 'ProjectsLocationsBucketsList' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'plblParent'
--
-- * 'plblXgafv'
--
-- * 'plblUploadProtocol'
--
-- * 'plblAccessToken'
--
-- * 'plblUploadType'
--
-- * 'plblPageTo... | 799 | projectsLocationsBucketsList
:: Text -- ^ 'plblParent'
-> ProjectsLocationsBucketsList
projectsLocationsBucketsList pPlblParent_ =
ProjectsLocationsBucketsList'
{ _plblParent = pPlblParent_
, _plblXgafv = Nothing
, _plblUploadProtocol = Nothing
, _plblAccessToken = Nothing
, _plblUploadTyp... | 428 | projectsLocationsBucketsList pPlblParent_ =
ProjectsLocationsBucketsList'
{ _plblParent = pPlblParent_
, _plblXgafv = Nothing
, _plblUploadProtocol = Nothing
, _plblAccessToken = Nothing
, _plblUploadType = Nothing
, _plblPageToken = Nothing
, _plblPageSize = Nothing
, _plblCallback = ... | 333 | true | true | 0 | 7 | 152 | 97 | 64 | 33 | null | null |
pparkkin/eta | compiler/ETA/Specialise/Rules.hs | bsd-3-clause | ruleCheckBind :: RuleCheckEnv -> CoreBind -> Bag SDoc
-- The Bag returned has one SDoc for each call site found
ruleCheckBind env (NonRec _ r) = ruleCheck env r | 163 | ruleCheckBind :: RuleCheckEnv -> CoreBind -> Bag SDoc
ruleCheckBind env (NonRec _ r) = ruleCheck env r | 102 | ruleCheckBind env (NonRec _ r) = ruleCheck env r | 48 | true | true | 0 | 7 | 31 | 41 | 20 | 21 | null | null |
input-output-hk/pos-haskell-prototype | chain/src/Pos/Chain/Txp/Toil/Logic.hs | mit | rollbackToil :: GenesisWStakeholders -> [(TxAux, TxUndo)] -> GlobalToilM ()
rollbackToil bootStakeholders txun = do
rollbackTxsStakes bootStakeholders txun
utxoMToGlobalToilM $ mapM_ Utxo.rollbackTxUtxo $ reverse txun
----------------------------------------------------------------------------
-- Local
-------... | 492 | rollbackToil :: GenesisWStakeholders -> [(TxAux, TxUndo)] -> GlobalToilM ()
rollbackToil bootStakeholders txun = do
rollbackTxsStakes bootStakeholders txun
utxoMToGlobalToilM $ mapM_ Utxo.rollbackTxUtxo $ reverse txun
----------------------------------------------------------------------------
-- Local
-------... | 492 | rollbackToil bootStakeholders txun = do
rollbackTxsStakes bootStakeholders txun
utxoMToGlobalToilM $ mapM_ Utxo.rollbackTxUtxo $ reverse txun
----------------------------------------------------------------------------
-- Local
----------------------------------------------------------------------------
-- | ... | 416 | false | true | 0 | 10 | 58 | 70 | 36 | 34 | null | null |
VictorDenisov/ldap-client | src/Ldap/Client/Search.hs | bsd-2-clause | -- | Maximum time (in seconds) allowed for the Search. No limit if the value
-- is @0@ (default: @0@).
time :: Int32 -> Mod Search
time x = Mod (\y -> y { _time = x }) | 167 | time :: Int32 -> Mod Search
time x = Mod (\y -> y { _time = x }) | 64 | time x = Mod (\y -> y { _time = x }) | 36 | true | true | 0 | 9 | 37 | 42 | 23 | 19 | null | null |
dysinger/amazonka | amazonka-codedeploy/gen/Network/AWS/CodeDeploy/Types.hs | mpl-2.0 | -- | 'DeploymentInfo' constructor.
--
-- The fields accessible through corresponding lenses are:
--
-- * 'diApplicationName' @::@ 'Maybe' 'Text'
--
-- * 'diCompleteTime' @::@ 'Maybe' 'UTCTime'
--
-- * 'diCreateTime' @::@ 'Maybe' 'UTCTime'
--
-- * 'diCreator' @::@ 'Maybe' 'DeploymentCreator'
--
-- * 'diDeploymentConfigN... | 1,582 | deploymentInfo :: DeploymentInfo
deploymentInfo = DeploymentInfo
{ _diApplicationName = Nothing
, _diDeploymentGroupName = Nothing
, _diDeploymentConfigName = Nothing
, _diDeploymentId = Nothing
, _diRevision = Nothing
, _diS... | 756 | deploymentInfo = DeploymentInfo
{ _diApplicationName = Nothing
, _diDeploymentGroupName = Nothing
, _diDeploymentConfigName = Nothing
, _diDeploymentId = Nothing
, _diRevision = Nothing
, _diStatus = No... | 723 | true | true | 0 | 7 | 448 | 139 | 97 | 42 | null | null |
SWP-Ubau-SoSe2014-Haskell/SWPSoSe14 | src/RailEditor/TextArea.hs | mit | selectEntries textArea (x:xs) = do
selectEntry textArea x
selectEntries textArea xs | 87 | selectEntries textArea (x:xs) = do
selectEntry textArea x
selectEntries textArea xs | 87 | selectEntries textArea (x:xs) = do
selectEntry textArea x
selectEntries textArea xs | 87 | false | false | 0 | 7 | 14 | 34 | 15 | 19 | null | null |
ghc-android/ghc | compiler/coreSyn/CoreSyn.hs | bsd-3-clause | tickishCounts HpcTick{} = True | 33 | tickishCounts HpcTick{} = True | 33 | tickishCounts HpcTick{} = True | 33 | false | false | 1 | 5 | 6 | 16 | 6 | 10 | null | null |
VyacheslavHashov/servant-auth-token | servant-auth-token-rocksdb/src/Servant/Server/Auth/Token/RocksDB/Schema.hs | bsd-3-clause | listUsersPaged :: MonadResource m => Page -> PageSize -> RocksDBEnv -> m ([WithId UserImplId UserImpl], Word)
listUsersPaged p s db = getPagedList db p s =<< (_modelUsers <$> loadModel db) | 188 | listUsersPaged :: MonadResource m => Page -> PageSize -> RocksDBEnv -> m ([WithId UserImplId UserImpl], Word)
listUsersPaged p s db = getPagedList db p s =<< (_modelUsers <$> loadModel db) | 188 | listUsersPaged p s db = getPagedList db p s =<< (_modelUsers <$> loadModel db) | 78 | false | true | 0 | 12 | 29 | 75 | 37 | 38 | null | null |
raichoo/Idris-dev | src/Idris/AbsSyntaxTree.hs | bsd-3-clause | highestFC (PAppImpl t _) = highestFC t | 38 | highestFC (PAppImpl t _) = highestFC t | 38 | highestFC (PAppImpl t _) = highestFC t | 38 | false | false | 0 | 7 | 6 | 20 | 9 | 11 | null | null |
mwu-tow/accelerate-cuda | Data/Array/Accelerate/CUDA.hs | bsd-3-clause | unsafeFree :: Arrays arrs => arrs -> IO ()
unsafeFree = unsafeFreeWith defaultContext | 85 | unsafeFree :: Arrays arrs => arrs -> IO ()
unsafeFree = unsafeFreeWith defaultContext | 85 | unsafeFree = unsafeFreeWith defaultContext | 42 | false | true | 0 | 8 | 12 | 30 | 14 | 16 | null | null |
ndmitchell/nsis | src/Development/NSIS/Plugins/WinMessages.hs | bsd-3-clause | wm_ICONERASEBKGND = 0x0027 | 40 | wm_ICONERASEBKGND = 0x0027 | 40 | wm_ICONERASEBKGND = 0x0027 | 40 | false | false | 0 | 4 | 16 | 6 | 3 | 3 | null | null |
abakst/liquidhaskell | src/Language/Haskell/Liquid/Transforms/Rec.hs | bsd-3-clause | freshInt
= do s <- get
let n = freshIndex s
put s{freshIndex = n+1}
return n | 99 | freshInt
= do s <- get
let n = freshIndex s
put s{freshIndex = n+1}
return n | 99 | freshInt
= do s <- get
let n = freshIndex s
put s{freshIndex = n+1}
return n | 99 | false | false | 1 | 11 | 39 | 53 | 22 | 31 | null | null |
rayl/gedcom-tools | Main.hs | bsd-3-clause | rANUL = chk "ANUL" | 18 | rANUL = chk "ANUL" | 18 | rANUL = chk "ANUL" | 18 | false | false | 1 | 5 | 3 | 13 | 4 | 9 | null | null |
olsner/ghc | compiler/ghci/ByteCodeGen.hs | bsd-3-clause | bcView (AnnTick _other_tick (_,e)) = Just e | 45 | bcView (AnnTick _other_tick (_,e)) = Just e | 45 | bcView (AnnTick _other_tick (_,e)) = Just e | 45 | false | false | 0 | 8 | 8 | 26 | 13 | 13 | null | null |
sinelaw/lamdu | Lamdu/Sugar/Convert/List.hs | gpl-3.0 | guardHeadTailTags ::
MonadPlus m =>
Anchors.SpecialFunctions t ->
Lens.Getting (First Guid) s Guid ->
s -> s -> m ()
guardHeadTailTags specialFunctions tagLens hd tl = do
guardTag Anchors.sfHeadTag hd
guardTag Anchors.sfTailTag tl
where
guardTag tag x =
guard . (== tag specialFunctions) =<<
... | 349 | guardHeadTailTags ::
MonadPlus m =>
Anchors.SpecialFunctions t ->
Lens.Getting (First Guid) s Guid ->
s -> s -> m ()
guardHeadTailTags specialFunctions tagLens hd tl = do
guardTag Anchors.sfHeadTag hd
guardTag Anchors.sfTailTag tl
where
guardTag tag x =
guard . (== tag specialFunctions) =<<
... | 349 | guardHeadTailTags specialFunctions tagLens hd tl = do
guardTag Anchors.sfHeadTag hd
guardTag Anchors.sfTailTag tl
where
guardTag tag x =
guard . (== tag specialFunctions) =<<
maybeToMPlus (x ^? tagLens) | 224 | false | true | 2 | 12 | 77 | 136 | 60 | 76 | null | null |
snoyberg/ghc | compiler/stgSyn/CoreToStg.hs | bsd-3-clause | stgArity _ LambdaBound = 0 | 33 | stgArity _ LambdaBound = 0 | 33 | stgArity _ LambdaBound = 0 | 33 | false | false | 1 | 5 | 11 | 13 | 5 | 8 | null | null |
harry-clarke/advent_of_code_2016 | src/haskell/puzzle_5/puzzle_5.hs | gpl-3.0 | main :: IO ()
main = do
let a1 = decrypt_1 input
let a2 = decrypt_2 input
--print a1
print a2 | 101 | main :: IO ()
main = do
let a1 = decrypt_1 input
let a2 = decrypt_2 input
--print a1
print a2 | 101 | main = do
let a1 = decrypt_1 input
let a2 = decrypt_2 input
--print a1
print a2 | 87 | false | true | 1 | 7 | 28 | 46 | 22 | 24 | null | null |
mainland/dph | dph-test/framework/DPH/Testsuite/Preproc.hs | bsd-3-clause | subst env (AppT t u) = AppT (subst env t) (subst env u) | 55 | subst env (AppT t u) = AppT (subst env t) (subst env u) | 55 | subst env (AppT t u) = AppT (subst env t) (subst env u) | 55 | false | false | 0 | 7 | 12 | 41 | 19 | 22 | null | null |
julienschmaltz/madl | examples/Examples.hs | mit | -- | Map containing flattened versions of the predefined networks.
networkMapFlattened :: Hash.Map Text FlattenedNetwork
networkMapFlattened = fmap unflatten networkMap_flat where
networkMap_flat :: Hash.Map Text FlatFlattenedNetwork
networkMap_flat = fmap unfoldMacros networkMap
-- | Map containing colored ve... | 354 | networkMapFlattened :: Hash.Map Text FlattenedNetwork
networkMapFlattened = fmap unflatten networkMap_flat where
networkMap_flat :: Hash.Map Text FlatFlattenedNetwork
networkMap_flat = fmap unfoldMacros networkMap
-- | Map containing colored versions of the predefined networks. | 287 | networkMapFlattened = fmap unflatten networkMap_flat where
networkMap_flat :: Hash.Map Text FlatFlattenedNetwork
networkMap_flat = fmap unfoldMacros networkMap
-- | Map containing colored versions of the predefined networks. | 233 | true | true | 0 | 6 | 49 | 48 | 25 | 23 | null | null |
Jem777/deepthought | src/Eval.hs | gpl-3.0 | getTree (EvalState t _) = t | 27 | getTree (EvalState t _) = t | 27 | getTree (EvalState t _) = t | 27 | false | false | 0 | 6 | 5 | 18 | 8 | 10 | null | null |
aisamanra/config-ini | src/Data/Ini/Config.hs | bsd-3-clause | -- | Convert a textual value to the appropriate string type. This will
-- never fail.
--
-- >>> string "foo" :: Either String String
-- Right "foo"
string :: (IsString a) => Text -> Either String a
string = return . fromString . T.unpack | 243 | string :: (IsString a) => Text -> Either String a
string = return . fromString . T.unpack | 89 | string = return . fromString . T.unpack | 39 | true | true | 2 | 8 | 50 | 52 | 26 | 26 | null | null |
ice1000/Kt2Dart | src/LexicalStructure.hs | agpl-3.0 | integerLiteralP :: Parser String
integerLiteralP = do
t <- some $ digitP <|> charP '_'
return [ c | c <- t, c /= '_' ]
-- | 125 | integerLiteralP :: Parser String
integerLiteralP = do
t <- some $ digitP <|> charP '_'
return [ c | c <- t, c /= '_' ]
-- | 125 | integerLiteralP = do
t <- some $ digitP <|> charP '_'
return [ c | c <- t, c /= '_' ]
-- | 92 | false | true | 0 | 10 | 30 | 58 | 28 | 30 | null | null |
enolive/exercism | haskell/grade-school/test/Tests.hs | mit | main :: IO ()
main = hspecWith defaultConfig {configFastFail = True} specs | 74 | main :: IO ()
main = hspecWith defaultConfig {configFastFail = True} specs | 74 | main = hspecWith defaultConfig {configFastFail = True} specs | 60 | false | true | 0 | 7 | 11 | 35 | 16 | 19 | null | null |
RobinKrom/BtcExchanges | src/Data/BtcExchanges.hs | bsd-3-clause | counter BTCAUD = AUD | 20 | counter BTCAUD = AUD | 20 | counter BTCAUD = AUD | 20 | false | false | 0 | 5 | 3 | 9 | 4 | 5 | null | null |
DavidAlphaFox/ghc | libraries/Cabal/Cabal/Distribution/Simple/GHC.hs | bsd-3-clause | checkPackageDbStack :: PackageDBStack -> IO ()
checkPackageDbStack (GlobalPackageDB:rest)
| GlobalPackageDB `notElem` rest = return () | 136 | checkPackageDbStack :: PackageDBStack -> IO ()
checkPackageDbStack (GlobalPackageDB:rest)
| GlobalPackageDB `notElem` rest = return () | 136 | checkPackageDbStack (GlobalPackageDB:rest)
| GlobalPackageDB `notElem` rest = return () | 89 | false | true | 0 | 8 | 16 | 47 | 23 | 24 | null | null |
brendanhay/gogol | gogol-apps-reseller/gen/Network/Google/Resource/Reseller/Subscriptions/ChangePlan.hs | mpl-2.0 | -- | OAuth access token.
scpAccessToken :: Lens' SubscriptionsChangePlan (Maybe Text)
scpAccessToken
= lens _scpAccessToken
(\ s a -> s{_scpAccessToken = a}) | 165 | scpAccessToken :: Lens' SubscriptionsChangePlan (Maybe Text)
scpAccessToken
= lens _scpAccessToken
(\ s a -> s{_scpAccessToken = a}) | 140 | scpAccessToken
= lens _scpAccessToken
(\ s a -> s{_scpAccessToken = a}) | 79 | true | true | 0 | 9 | 29 | 48 | 25 | 23 | null | null |
forste/haReFork | tools/property/syntax/HasPropStruct.hs | bsd-3-clause | propHas e pp = proprec $ PropHas e pp | 37 | propHas e pp = proprec $ PropHas e pp | 37 | propHas e pp = proprec $ PropHas e pp | 37 | false | false | 0 | 6 | 8 | 20 | 9 | 11 | null | null |
a143753/AOJ | 0382.hs | apache-2.0 | [[n,c],d] =
let s = sum d
a = s `div` (n+1)
b = s `mod` (n+1)
in
if b /= 0
then (a + 1)
else a | 122 | [[n,c],d] =
let s = sum d
a = s `div` (n+1)
b = s `mod` (n+1)
in
if b /= 0
then (a + 1)
else a | 122 | [[n,c],d] =
let s = sum d
a = s `div` (n+1)
b = s `mod` (n+1)
in
if b /= 0
then (a + 1)
else a | 122 | false | false | 0 | 11 | 55 | 88 | 50 | 38 | null | null |
typelead/epm | epm/Distribution/Client/Setup.hs | bsd-3-clause | usageFlags :: String -> String -> String
usageFlags name pname =
"Usage: " ++ pname ++ " " ++ name ++ " [FLAGS]\n" | 116 | usageFlags :: String -> String -> String
usageFlags name pname =
"Usage: " ++ pname ++ " " ++ name ++ " [FLAGS]\n" | 116 | usageFlags name pname =
"Usage: " ++ pname ++ " " ++ name ++ " [FLAGS]\n" | 75 | false | true | 0 | 8 | 24 | 40 | 20 | 20 | null | null |
itayd/hh | src/hh.hs | bsd-3-clause | mkVersion :: String
mkVersion = showVersion version | 51 | mkVersion :: String
mkVersion = showVersion version | 51 | mkVersion = showVersion version | 31 | false | true | 0 | 5 | 6 | 14 | 7 | 7 | null | null |
jsl/RunnyBabbot | src/RunnyBabbot/Spoonerize.hs | mit | vowels = "AEIOUaeiou" | 25 | vowels = "AEIOUaeiou" | 25 | vowels = "AEIOUaeiou" | 25 | false | false | 1 | 5 | 6 | 10 | 3 | 7 | null | null |
jacekszymanski/wxHaskell | wxcore/src/haskell/Graphics/UI/WXCore/WxcDefs.hs | lgpl-2.1 | wxSTC_CHARSET_GREEK :: Int
wxSTC_CHARSET_GREEK = 161 | 52 | wxSTC_CHARSET_GREEK :: Int
wxSTC_CHARSET_GREEK = 161 | 52 | wxSTC_CHARSET_GREEK = 161 | 25 | false | true | 0 | 4 | 5 | 11 | 6 | 5 | null | null |
jvictor0/OnlineRandomForest | src/CART.hs | mit | dirichlet_param dim = replicate dim 0.01 | 40 | dirichlet_param dim = replicate dim 0.01 | 40 | dirichlet_param dim = replicate dim 0.01 | 40 | false | false | 0 | 5 | 5 | 14 | 6 | 8 | null | null |
selectel/stringlike | src/Data/String/Like.hs | mit | -- | Transform any 'ToString' type to lazy 'LazyByteString'
lbs :: ToString a => a -> LazyByteString
lbs = string | 113 | lbs :: ToString a => a -> LazyByteString
lbs = string | 53 | lbs = string | 12 | true | true | 0 | 8 | 19 | 30 | 13 | 17 | null | null |
oldmanmike/ghc | compiler/prelude/TysWiredIn.hs | bsd-3-clause | -- See Note [Wiring in RuntimeRep]
vecCountDataConNames :: [Name]
vecCountDataConNames = zipWith3Lazy mk_special_dc_name
[ fsLit "Vec2", fsLit "Vec4", fsLit "Vec8"
, fsLit "Vec16", fsLit "Vec32", fsLit "Vec64" ]
vecCountDataConKeys
... | 348 | vecCountDataConNames :: [Name]
vecCountDataConNames = zipWith3Lazy mk_special_dc_name
[ fsLit "Vec2", fsLit "Vec4", fsLit "Vec8"
, fsLit "Vec16", fsLit "Vec32", fsLit "Vec64" ]
vecCountDataConKeys
vecCountDataCons | 313 | vecCountDataConNames = zipWith3Lazy mk_special_dc_name
[ fsLit "Vec2", fsLit "Vec4", fsLit "Vec8"
, fsLit "Vec16", fsLit "Vec32", fsLit "Vec64" ]
vecCountDataConKeys
vecCountDataCons | 282 | true | true | 0 | 7 | 129 | 70 | 32 | 38 | null | null |
drhodes/jade2hdl | app/Main.hs | bsd-3-clause | hdl = strOption $ mconcat [ long "hdl"
, metavar "[vhdl|verilog]"
, help "HDL language, vhdl or verilog"
] | 184 | hdl = strOption $ mconcat [ long "hdl"
, metavar "[vhdl|verilog]"
, help "HDL language, vhdl or verilog"
] | 184 | hdl = strOption $ mconcat [ long "hdl"
, metavar "[vhdl|verilog]"
, help "HDL language, vhdl or verilog"
] | 184 | false | false | 0 | 8 | 96 | 31 | 15 | 16 | null | null |
maximilianhuber/innovation | lib/Game/MetaGame/Types/Core.hs | bsd-3-clause | getUnrestricted (ULogE _ t _) = t | 33 | getUnrestricted (ULogE _ t _) = t | 33 | getUnrestricted (ULogE _ t _) = t | 33 | false | false | 0 | 6 | 6 | 20 | 9 | 11 | null | null |
brendanhay/gogol | gogol-jobs/gen/Network/Google/Resource/Jobs/Projects/Companies/Get.hs | mpl-2.0 | -- | OAuth access token.
pcgAccessToken :: Lens' ProjectsCompaniesGet (Maybe Text)
pcgAccessToken
= lens _pcgAccessToken
(\ s a -> s{_pcgAccessToken = a}) | 162 | pcgAccessToken :: Lens' ProjectsCompaniesGet (Maybe Text)
pcgAccessToken
= lens _pcgAccessToken
(\ s a -> s{_pcgAccessToken = a}) | 137 | pcgAccessToken
= lens _pcgAccessToken
(\ s a -> s{_pcgAccessToken = a}) | 79 | true | true | 0 | 9 | 29 | 48 | 25 | 23 | null | null |
ahmadsalim/p3-tool | p3-tool/FPromela/Lexer.hs | gpl-3.0 | semiSep :: Parser st a -> Parser st [a]
semiSep = Tok.semiSep lexer | 67 | semiSep :: Parser st a -> Parser st [a]
semiSep = Tok.semiSep lexer | 67 | semiSep = Tok.semiSep lexer | 27 | false | true | 0 | 8 | 12 | 39 | 17 | 22 | null | null |
ryzhyk/cocoon | cocoon/Parse.hs | apache-2.0 | dot = T.dot lexer | 24 | dot = T.dot lexer | 24 | dot = T.dot lexer | 24 | false | false | 1 | 5 | 10 | 15 | 5 | 10 | null | null |
mettekou/ghc | compiler/coreSyn/CoreSyn.hs | bsd-3-clause | -- | @True@ if the unfolding is a constructor application, the application
-- of a CONLIKE function or 'OtherCon'
isConLikeUnfolding :: Unfolding -> Bool
isConLikeUnfolding (OtherCon _) = True | 220 | isConLikeUnfolding :: Unfolding -> Bool
isConLikeUnfolding (OtherCon _) = True | 106 | isConLikeUnfolding (OtherCon _) = True | 66 | true | true | 0 | 9 | 56 | 32 | 15 | 17 | null | null |
brendanhay/gogol | gogol-cloudsearch/gen/Network/Google/CloudSearch/Types/Product.hs | mpl-2.0 | -- | Token to retrieve the next page of results, or empty if there are no
-- more results in the list.
ldsrNextPageToken :: Lens' ListDataSourceResponse (Maybe Text)
ldsrNextPageToken
= lens _ldsrNextPageToken
(\ s a -> s{_ldsrNextPageToken = a}) | 254 | ldsrNextPageToken :: Lens' ListDataSourceResponse (Maybe Text)
ldsrNextPageToken
= lens _ldsrNextPageToken
(\ s a -> s{_ldsrNextPageToken = a}) | 151 | ldsrNextPageToken
= lens _ldsrNextPageToken
(\ s a -> s{_ldsrNextPageToken = a}) | 88 | true | true | 1 | 9 | 46 | 52 | 26 | 26 | null | null |
zeniuseducation/poly-euler | Alfa/haskell/tutorial/two.hs | epl-1.0 | numcol :: Int -> [Int]
numcol n
| n < 10 = [n]
| otherwise = numcol (div n 10) ++ [rem n 10] | 96 | numcol :: Int -> [Int]
numcol n
| n < 10 = [n]
| otherwise = numcol (div n 10) ++ [rem n 10] | 96 | numcol n
| n < 10 = [n]
| otherwise = numcol (div n 10) ++ [rem n 10] | 73 | false | true | 1 | 8 | 27 | 70 | 33 | 37 | null | null |
lynnard/cocos2d-hs | src/Graphics/UI/Cocos2d/Widget.hs | bsd-3-clause | widget_enableDpadNavigation :: (WidgetPtr arg'1) => arg'1 -> HoppyP.Bool -> HoppyP.IO ()
widget_enableDpadNavigation arg'1 arg'2 =
HoppyFHR.withCppPtr (toWidget arg'1) $ \arg'1' ->
let arg'2' = if arg'2 then 1 else 0 in
(widget_enableDpadNavigation' arg'1' arg'2') | 270 | widget_enableDpadNavigation :: (WidgetPtr arg'1) => arg'1 -> HoppyP.Bool -> HoppyP.IO ()
widget_enableDpadNavigation arg'1 arg'2 =
HoppyFHR.withCppPtr (toWidget arg'1) $ \arg'1' ->
let arg'2' = if arg'2 then 1 else 0 in
(widget_enableDpadNavigation' arg'1' arg'2') | 270 | widget_enableDpadNavigation arg'1 arg'2 =
HoppyFHR.withCppPtr (toWidget arg'1) $ \arg'1' ->
let arg'2' = if arg'2 then 1 else 0 in
(widget_enableDpadNavigation' arg'1' arg'2') | 181 | false | true | 0 | 11 | 39 | 89 | 45 | 44 | null | null |
olorin/amazonka | amazonka-kms/gen/Network/AWS/KMS/DescribeKey.hs | mpl-2.0 | -- | A unique identifier for the customer master key. This value can be a
-- globally unique identifier, a fully specified ARN to either an alias or
-- a key, or an alias name prefixed by \"alias\/\".
--
-- - Key ARN Example -
-- arn:aws:kms:us-east-1:123456789012:key\/12345678-1234-1234-1234-123456789012
-- - ... | 612 | dKeyId :: Lens' DescribeKey Text
dKeyId = lens _dKeyId (\ s a -> s{_dKeyId = a}) | 80 | dKeyId = lens _dKeyId (\ s a -> s{_dKeyId = a}) | 47 | true | true | 0 | 9 | 107 | 50 | 32 | 18 | null | null |
mcmaniac/ghc | compiler/main/DynFlags.hs | bsd-3-clause | nop :: TurnOnFlag -> DynP ()
nop _ = return () | 46 | nop :: TurnOnFlag -> DynP ()
nop _ = return () | 46 | nop _ = return () | 17 | false | true | 0 | 7 | 10 | 28 | 13 | 15 | null | null |
idzardh/dotfiles | xmonad.hs | gpl-3.0 | prompt = 20 | 19 | prompt = 20 | 19 | prompt = 20 | 19 | false | false | 0 | 4 | 10 | 6 | 3 | 3 | null | null |
kim/amazonka | amazonka-ec2/gen/Network/AWS/EC2/Types.hs | mpl-2.0 | -- | Any tags assigned to the network ACL.
naTags :: Lens' NetworkAcl [Tag]
naTags = lens _naTags (\s a -> s { _naTags = a }) . _List | 133 | naTags :: Lens' NetworkAcl [Tag]
naTags = lens _naTags (\s a -> s { _naTags = a }) . _List | 90 | naTags = lens _naTags (\s a -> s { _naTags = a }) . _List | 57 | true | true | 0 | 9 | 28 | 54 | 27 | 27 | null | null |
kranich/haste-compiler | src/Haste/Environment.hs | bsd-3-clause | hostWordSize = finiteBitSize (undefined :: CIntPtr) | 51 | hostWordSize = finiteBitSize (undefined :: CIntPtr) | 51 | hostWordSize = finiteBitSize (undefined :: CIntPtr) | 51 | false | false | 0 | 6 | 5 | 15 | 8 | 7 | null | null |
TomMD/ghc | compiler/main/DriverPipeline.hs | bsd-3-clause | writeInterfaceOnlyMode :: DynFlags -> Bool
writeInterfaceOnlyMode dflags =
gopt Opt_WriteInterface dflags &&
HscNothing == hscTarget dflags | 141 | writeInterfaceOnlyMode :: DynFlags -> Bool
writeInterfaceOnlyMode dflags =
gopt Opt_WriteInterface dflags &&
HscNothing == hscTarget dflags | 141 | writeInterfaceOnlyMode dflags =
gopt Opt_WriteInterface dflags &&
HscNothing == hscTarget dflags | 98 | false | true | 0 | 7 | 17 | 34 | 16 | 18 | null | null |
ion1/rcon-haskell | Network/Rcon/Parse.hs | isc | execCommandQ :: Word32 -> Parser QueryPacket
execCommandQ id_ = ExecCommandQ id_ <$> (byteString0 <* emptyByteString0) | 118 | execCommandQ :: Word32 -> Parser QueryPacket
execCommandQ id_ = ExecCommandQ id_ <$> (byteString0 <* emptyByteString0) | 118 | execCommandQ id_ = ExecCommandQ id_ <$> (byteString0 <* emptyByteString0) | 73 | false | true | 0 | 8 | 14 | 40 | 18 | 22 | null | null |
beni55/markdown | test/main.hs | bsd-3-clause | main :: IO ()
main = do
examples <- getExamples
gruber <- getGruber
hspec $ do
describe "block" blockSpecs
describe "inline" inlineSpecs
describe "paragraphs" $ do
it "simple"
$ check "<p>Hello World!</p>" "Hello World!"
it "multiline"
$ check "<p>Hello\nWorld!<... | 6,152 | main :: IO ()
main = do
examples <- getExamples
gruber <- getGruber
hspec $ do
describe "block" blockSpecs
describe "inline" inlineSpecs
describe "paragraphs" $ do
it "simple"
$ check "<p>Hello World!</p>" "Hello World!"
it "multiline"
$ check "<p>Hello\nWorld!<... | 6,152 | main = do
examples <- getExamples
gruber <- getGruber
hspec $ do
describe "block" blockSpecs
describe "inline" inlineSpecs
describe "paragraphs" $ do
it "simple"
$ check "<p>Hello World!</p>" "Hello World!"
it "multiline"
$ check "<p>Hello\nWorld!</p>" "Hello\nW... | 6,138 | false | true | 1 | 21 | 2,056 | 1,040 | 428 | 612 | null | null |
gencer/bond | compiler/src/Language/Bond/Codegen/TypeMapping.hs | mit | javaType BT_MetaName = pure "java.lang.String" | 46 | javaType BT_MetaName = pure "java.lang.String" | 46 | javaType BT_MetaName = pure "java.lang.String" | 46 | false | false | 0 | 5 | 4 | 12 | 5 | 7 | null | null |
abakst/liquidhaskell | benchmarks/vector-0.10.0.1/Data/Vector/Unboxed.hs | bsd-3-clause | drop = G.drop | 13 | drop = G.drop | 13 | drop = G.drop | 13 | false | false | 1 | 6 | 2 | 12 | 4 | 8 | null | null |
konn/BottleStory | Application.hs | bsd-2-clause | -- This function allocates resources (such as a database connection pool),
-- performs initialization and creates a WAI application. This is also the
-- place to put your migrate statements to have automatic database
-- migrations handled by Yesod.
withBottleStory :: AppConfig DefaultEnv -> Logger -> (Application -> IO... | 783 | withBottleStory :: AppConfig DefaultEnv -> Logger -> (Application -> IO ()) -> IO ()
withBottleStory conf logger f = do
#ifdef PRODUCTION
s <- static Settings.staticDir
#else
s <- staticDevel Settings.staticDir
#endif
dbconf <- withYamlEnvironment "config/mongoDB.yml" (appEnv conf)
$ either erro... | 534 | withBottleStory conf logger f = do
#ifdef PRODUCTION
s <- static Settings.staticDir
#else
s <- staticDevel Settings.staticDir
#endif
dbconf <- withYamlEnvironment "config/mongoDB.yml" (appEnv conf)
$ either error return . Database.Persist.Base.loadConfig
Database.Persist.Base.withPool (dbcon... | 449 | true | true | 0 | 15 | 150 | 163 | 81 | 82 | null | null |
pgj/bead | src/Bead/View/TemplateAndComponentNames.hs | bsd-3-clause | coursesForm = CoursesForm "courses" | 35 | coursesForm = CoursesForm "courses" | 35 | coursesForm = CoursesForm "courses" | 35 | false | false | 0 | 5 | 3 | 9 | 4 | 5 | null | null |
kim/amazonka | amazonka-cloudformation/gen/Network/AWS/CloudFormation/SignalResource.hs | mpl-2.0 | -- | 'SignalResourceResponse' constructor.
signalResourceResponse :: SignalResourceResponse
signalResourceResponse = SignalResourceResponse | 139 | signalResourceResponse :: SignalResourceResponse
signalResourceResponse = SignalResourceResponse | 96 | signalResourceResponse = SignalResourceResponse | 47 | true | true | 0 | 4 | 9 | 12 | 7 | 5 | null | null |
bjpop/blip | blipinterpreter/src/Blip/Interpreter/StandardObjectID.hs | bsd-3-clause | dictTypeID :: ObjectID
dictTypeID = toObjectID DictTypeID | 57 | dictTypeID :: ObjectID
dictTypeID = toObjectID DictTypeID | 57 | dictTypeID = toObjectID DictTypeID | 34 | false | true | 0 | 6 | 6 | 21 | 8 | 13 | null | null |
flipstone/orville | orville-postgresql/src/Database/Orville/PostgreSQL/Internal/Expr/Expr.hs | mit | rawExprToSql :: RawExpr -> String
rawExprToSql = go ""
where
go rest (RawExprString s) = s ++ rest
go rest (RawExprAppend r1 r2) = go (go rest r2) r1
go rest (RawExprConcat exprs) = foldr (flip go) rest exprs
#if MIN_VERSION_base(4,11,0) | 252 | rawExprToSql :: RawExpr -> String
rawExprToSql = go ""
where
go rest (RawExprString s) = s ++ rest
go rest (RawExprAppend r1 r2) = go (go rest r2) r1
go rest (RawExprConcat exprs) = foldr (flip go) rest exprs
#if MIN_VERSION_base(4,11,0) | 252 | rawExprToSql = go ""
where
go rest (RawExprString s) = s ++ rest
go rest (RawExprAppend r1 r2) = go (go rest r2) r1
go rest (RawExprConcat exprs) = foldr (flip go) rest exprs
#if MIN_VERSION_base(4,11,0) | 218 | false | true | 0 | 7 | 55 | 114 | 51 | 63 | null | null |
apyrgio/ganeti | src/Ganeti/HTools/Cluster.hs | bsd-2-clause | nodeEvacInstance opts nl il mode inst@(Instance.Instance
{Instance.diskTemplate = dt@DTSharedFile})
gdx avail_nodes =
failOnSecondaryChange mode dt >>
evacOneNodeOnly opts nl il inst gdx avail_nodes | 289 | nodeEvacInstance opts nl il mode inst@(Instance.Instance
{Instance.diskTemplate = dt@DTSharedFile})
gdx avail_nodes =
failOnSecondaryChange mode dt >>
evacOneNodeOnly opts nl il inst gdx avail_nodes | 289 | nodeEvacInstance opts nl il mode inst@(Instance.Instance
{Instance.diskTemplate = dt@DTSharedFile})
gdx avail_nodes =
failOnSecondaryChange mode dt >>
evacOneNodeOnly opts nl il inst gdx avail_nodes | 289 | false | false | 0 | 11 | 113 | 67 | 33 | 34 | null | null |
jasonzoladz/persistent | persistent/Database/Persist/Sql/Util.hs | mit | entityColumnNames :: EntityDef -> SqlBackend -> [Sql]
entityColumnNames ent conn =
(if hasCompositeKey ent
then [] else [connEscapeName conn $ fieldDB (entityId ent)])
<> map (connEscapeName conn . fieldDB) (entityFields ent) | 238 | entityColumnNames :: EntityDef -> SqlBackend -> [Sql]
entityColumnNames ent conn =
(if hasCompositeKey ent
then [] else [connEscapeName conn $ fieldDB (entityId ent)])
<> map (connEscapeName conn . fieldDB) (entityFields ent) | 238 | entityColumnNames ent conn =
(if hasCompositeKey ent
then [] else [connEscapeName conn $ fieldDB (entityId ent)])
<> map (connEscapeName conn . fieldDB) (entityFields ent) | 184 | false | true | 2 | 11 | 43 | 89 | 44 | 45 | null | null |
forste/haReFork | tools/property/parse2/Parser/PropPlogic.hs | bsd-3-clause | pred' args p = ((,) args # pred p) `mplus` pred'' args p
where
pred'' args p =
do HsVar x <- return (last args)
(,) (init args) . predComp [(hsPVar x,Nothing)] # prop p | 190 | pred' args p = ((,) args # pred p) `mplus` pred'' args p
where
pred'' args p =
do HsVar x <- return (last args)
(,) (init args) . predComp [(hsPVar x,Nothing)] # prop p | 190 | pred' args p = ((,) args # pred p) `mplus` pred'' args p
where
pred'' args p =
do HsVar x <- return (last args)
(,) (init args) . predComp [(hsPVar x,Nothing)] # prop p | 190 | false | false | 2 | 13 | 56 | 120 | 53 | 67 | null | null |
mdsteele/fallback | src/Fallback/State/Simple.hs | gpl-3.0 | allEquipmentSlots :: [ItemSlot]
allEquipmentSlots = concatMap slots [minBound .. maxBound] where
slots n = [CharWeaponSlot n, CharArmorSlot n, CharAccessorySlot n]
------------------------------------------------------------------------------- | 246 | allEquipmentSlots :: [ItemSlot]
allEquipmentSlots = concatMap slots [minBound .. maxBound] where
slots n = [CharWeaponSlot n, CharArmorSlot n, CharAccessorySlot n]
------------------------------------------------------------------------------- | 246 | allEquipmentSlots = concatMap slots [minBound .. maxBound] where
slots n = [CharWeaponSlot n, CharArmorSlot n, CharAccessorySlot n]
------------------------------------------------------------------------------- | 214 | false | true | 0 | 6 | 23 | 53 | 29 | 24 | null | null |
madebyjeffrey/HSProcessing | src/main.hs | bsd-2-clause | {-}
showMonitor :: GLFW.Monitor -> IO String
showMonitor m = do
(x, y) <- GLFW.getMonitorPhysicalSize m
pure $ show x <> " x " <> show y
main :: IO ()
main = do
r <- GLFW.init
when r $ do
monitors <- GLFW.getMonitors
putStrLn =<< (liftM unlines $ case monitors of
Nothing ... | 572 | errorCallback :: GLFW.ErrorCallback
errorCallback err description = hPutStrLn stderr (show err <> description) | 110 | errorCallback err description = hPutStrLn stderr (show err <> description) | 74 | true | true | 0 | 8 | 155 | 35 | 18 | 17 | null | null |
pawel-n/data-fix1 | src/Data/Fix1.hs | mit | ana1 :: HFunctor f => (g a -> f g a) -> g a -> Fix1 f a
ana1 f = Fix1 . hmap (ana1 f) . f | 89 | ana1 :: HFunctor f => (g a -> f g a) -> g a -> Fix1 f a
ana1 f = Fix1 . hmap (ana1 f) . f | 89 | ana1 f = Fix1 . hmap (ana1 f) . f | 33 | false | true | 0 | 9 | 27 | 69 | 32 | 37 | null | null |
bch29/streaming-png | src/Codec/Picture/Png/Streaming/Juicy.hs | lgpl-3.0 | bp8 :: (Monad m) => BytePacker m Word8 r
bp8 input =
do bs :> res <- Q.toStrict input
return (bytestringToVector bs :> res) | 130 | bp8 :: (Monad m) => BytePacker m Word8 r
bp8 input =
do bs :> res <- Q.toStrict input
return (bytestringToVector bs :> res) | 130 | bp8 input =
do bs :> res <- Q.toStrict input
return (bytestringToVector bs :> res) | 89 | false | true | 0 | 10 | 30 | 62 | 29 | 33 | null | null |
fimad/scalpel | scalpel-core/src/Text/HTML/Scalpel/Internal/Select.hs | apache-2.0 | selectNodes [_] (_, [], _) _ acc = acc | 38 | selectNodes [_] (_, [], _) _ acc = acc | 38 | selectNodes [_] (_, [], _) _ acc = acc | 38 | false | false | 2 | 6 | 8 | 32 | 15 | 17 | null | null |
RAFIRAF/HASKELL | baby.hs | mit | listaBMI = [(80.0,1.8),(50,1.7),(95,1.9)] | 41 | listaBMI = [(80.0,1.8),(50,1.7),(95,1.9)] | 41 | listaBMI = [(80.0,1.8),(50,1.7),(95,1.9)] | 41 | false | false | 1 | 6 | 2 | 36 | 21 | 15 | null | null |
brendanhay/gogol | gogol-logging/gen/Network/Google/Resource/Logging/Folders/Locations/Buckets/Views/List.hs | mpl-2.0 | -- | Required. The bucket whose views are to be listed:
-- \"projects\/[PROJECT_ID]\/locations\/[LOCATION_ID]\/buckets\/[BUCKET_ID]\"
flbvlParent :: Lens' FoldersLocationsBucketsViewsList Text
flbvlParent
= lens _flbvlParent (\ s a -> s{_flbvlParent = a}) | 257 | flbvlParent :: Lens' FoldersLocationsBucketsViewsList Text
flbvlParent
= lens _flbvlParent (\ s a -> s{_flbvlParent = a}) | 123 | flbvlParent
= lens _flbvlParent (\ s a -> s{_flbvlParent = a}) | 64 | true | true | 0 | 9 | 30 | 43 | 23 | 20 | null | null |
giorgidze/HCodecs | src/Codec/Midi.hs | bsd-3-clause | buildMessage msg | isMetaMessage msg = buildMetaMessage msg | 59 | buildMessage msg | isMetaMessage msg = buildMetaMessage msg | 59 | buildMessage msg | isMetaMessage msg = buildMetaMessage msg | 59 | false | false | 0 | 8 | 7 | 21 | 8 | 13 | null | null |
TomMD/ghc | compiler/prelude/THNames.hs | bsd-3-clause | inlineDataConName = thCon (fsLit "Inline") inlineDataConKey | 65 | inlineDataConName = thCon (fsLit "Inline") inlineDataConKey | 65 | inlineDataConName = thCon (fsLit "Inline") inlineDataConKey | 65 | false | false | 0 | 7 | 11 | 17 | 8 | 9 | null | null |
prowdsponsor/country-codes | src/Data/CountryCodes/ISO31661.hs | bsd-3-clause | toText KG = "KG" | 16 | toText KG = "KG" | 16 | toText KG = "KG" | 16 | false | false | 0 | 4 | 3 | 10 | 4 | 6 | null | null |
sjfloat/dnngraph | NN/Backend/Torch/Codegen.hs | bsd-3-clause | insert (Seq exps') = insertContainer "seq" sequential' exps'
where
sequential' = torchExp (TorchModule "nn" "Sequential" []) | 134 | insert (Seq exps') = insertContainer "seq" sequential' exps'
where
sequential' = torchExp (TorchModule "nn" "Sequential" []) | 134 | insert (Seq exps') = insertContainer "seq" sequential' exps'
where
sequential' = torchExp (TorchModule "nn" "Sequential" []) | 134 | false | false | 1 | 7 | 25 | 51 | 21 | 30 | null | null |
polarina/sdl2 | Graphics/UI/SDL/Video.hs | bsd-3-clause | createTextureFromSurface :: MonadIO m => Renderer -> Ptr Surface -> m Texture
createTextureFromSurface v1 v2 = liftIO $ createTextureFromSurface' v1 v2 | 151 | createTextureFromSurface :: MonadIO m => Renderer -> Ptr Surface -> m Texture
createTextureFromSurface v1 v2 = liftIO $ createTextureFromSurface' v1 v2 | 151 | createTextureFromSurface v1 v2 = liftIO $ createTextureFromSurface' v1 v2 | 73 | false | true | 0 | 8 | 20 | 46 | 21 | 25 | null | null |
jwiegley/ghc-release | compiler/llvmGen/Llvm/Types.hs | gpl-3.0 | -- | Test if a 'LlvmVar' is global.
isGlobal :: LlvmVar -> Bool
isGlobal (LMGlobalVar _ _ _ _ _ _) = True | 105 | isGlobal :: LlvmVar -> Bool
isGlobal (LMGlobalVar _ _ _ _ _ _) = True | 69 | isGlobal (LMGlobalVar _ _ _ _ _ _) = True | 41 | true | true | 0 | 9 | 22 | 41 | 19 | 22 | null | null |
kelnage/tamarin-prover | lib/theory/src/Theory/Constraint/Solver/Contradictions.hs | gpl-3.0 | nonInjectiveFactInstances :: ProofContext -> System -> [(NodeId, NodeId, NodeId)]
nonInjectiveFactInstances ctxt se = do
Edge c@(i, _) (k, _) <- S.toList $ L.get sEdges se
let kFaPrem = nodeConcFact c se
kTag = factTag kFaPrem
kTerm = firstTerm kFaPrem
... | 1,207 | nonInjectiveFactInstances :: ProofContext -> System -> [(NodeId, NodeId, NodeId)]
nonInjectiveFactInstances ctxt se = do
Edge c@(i, _) (k, _) <- S.toList $ L.get sEdges se
let kFaPrem = nodeConcFact c se
kTag = factTag kFaPrem
kTerm = firstTerm kFaPrem
... | 1,207 | nonInjectiveFactInstances ctxt se = do
Edge c@(i, _) (k, _) <- S.toList $ L.get sEdges se
let kFaPrem = nodeConcFact c se
kTag = factTag kFaPrem
kTerm = firstTerm kFaPrem
conflictingFact fa = factTag fa == kTag && firstTerm fa == kTerm
guard (kT... | 1,125 | false | true | 1 | 15 | 387 | 340 | 172 | 168 | null | null |
kawu/partage | src/NLP/Partage/AStar.hs | bsd-2-clause | parsedTrees
:: forall n t. (Ord n, Ord t)
=> Hype n t -- ^ Final state of the earley parser
-> S.Set n -- ^ The start symbol set
-> Int -- ^ Length of the input sentence
-> [T.Tree n (Maybe (Tok t))]
parsedTrees hype start n
= concatMap (`fromPassive` hype)
$ finalFrom star... | 328 | parsedTrees
:: forall n t. (Ord n, Ord t)
=> Hype n t -- ^ Final state of the earley parser
-> S.Set n -- ^ The start symbol set
-> Int -- ^ Length of the input sentence
-> [T.Tree n (Maybe (Tok t))]
parsedTrees hype start n
= concatMap (`fromPassive` hype)
$ finalFrom star... | 328 | parsedTrees hype start n
= concatMap (`fromPassive` hype)
$ finalFrom start n hype | 90 | false | true | 0 | 15 | 103 | 106 | 56 | 50 | null | null |
DanielWaterworth/Idris-dev | src/Idris/REPLParser.hs | bsd-3-clause | pColour :: P.IdrisParser (Maybe Color)
pColour = doColour colours
where doColour [] = fail "Unknown colour"
doColour ((s, c):cs) = (try (P.symbol s) >> return c) <|> doColour cs | 191 | pColour :: P.IdrisParser (Maybe Color)
pColour = doColour colours
where doColour [] = fail "Unknown colour"
doColour ((s, c):cs) = (try (P.symbol s) >> return c) <|> doColour cs | 191 | pColour = doColour colours
where doColour [] = fail "Unknown colour"
doColour ((s, c):cs) = (try (P.symbol s) >> return c) <|> doColour cs | 152 | false | true | 3 | 11 | 42 | 100 | 44 | 56 | null | null |
dmvianna/haskellbook | src/Ch26-Scotty-3.hs | unlicense | param' :: Parsable a => Text -> MaybeT ActionM a
param' k = MaybeT $
rescue (Just <$> param k)
(const (return Nothing)) | 141 | param' :: Parsable a => Text -> MaybeT ActionM a
param' k = MaybeT $
rescue (Just <$> param k)
(const (return Nothing)) | 141 | param' k = MaybeT $
rescue (Just <$> param k)
(const (return Nothing)) | 92 | false | true | 0 | 10 | 44 | 61 | 29 | 32 | null | null |
wehu/hw | src/AST.hs | apache-2.0 | prExp (ECon (CCon n es) _) = PP.parens $ PP.text n PP.<+> prExpList es | 70 | prExp (ECon (CCon n es) _) = PP.parens $ PP.text n PP.<+> prExpList es | 70 | prExp (ECon (CCon n es) _) = PP.parens $ PP.text n PP.<+> prExpList es | 70 | false | false | 0 | 9 | 13 | 45 | 21 | 24 | null | null |
rueshyna/gogol | gogol-compute/gen/Network/Google/Resource/Compute/BackendServices/AggregatedList.hs | mpl-2.0 | -- | The maximum number of results per page that should be returned. If the
-- number of available results is larger than maxResults, Compute Engine
-- returns a nextPageToken that can be used to get the next page of results
-- in subsequent list requests.
bsalMaxResults :: Lens' BackendServicesAggregatedList Word32
bs... | 413 | bsalMaxResults :: Lens' BackendServicesAggregatedList Word32
bsalMaxResults
= lens _bsalMaxResults
(\ s a -> s{_bsalMaxResults = a})
. _Coerce | 156 | bsalMaxResults
= lens _bsalMaxResults
(\ s a -> s{_bsalMaxResults = a})
. _Coerce | 95 | true | true | 0 | 10 | 77 | 49 | 27 | 22 | null | null |
ihc/futhark | src/Futhark/Optimise/MemoryBlockMerging/Coalescing/SafetyCondition5.hs | isc | coerce :: (ExplicitMemorish flore, ExplicitMemorish tlore) =>
FindM flore a -> FindM tlore a
coerce = FindM . unFindM | 127 | coerce :: (ExplicitMemorish flore, ExplicitMemorish tlore) =>
FindM flore a -> FindM tlore a
coerce = FindM . unFindM | 127 | coerce = FindM . unFindM | 24 | false | true | 0 | 8 | 28 | 50 | 23 | 27 | null | null |
TomMD/cryptol | src/Cryptol/Prims/Eval.hs | bsd-3-clause | fromThenToV :: Value
fromThenToV =
tlamN $ \ first ->
tlamN $ \ next ->
tlamN $ \ lst ->
tlamN $ \ bits ->
tlamN $ \ len ->
case (first, next, lst, len, bits) of
(Nat first', Nat next', Nat lst', Nat len', Nat bits') ->
let nums = enumFromThenTo first' next' lst'
in VSeq Fal... | 681 | fromThenToV :: Value
fromThenToV =
tlamN $ \ first ->
tlamN $ \ next ->
tlamN $ \ lst ->
tlamN $ \ bits ->
tlamN $ \ len ->
case (first, next, lst, len, bits) of
(Nat first', Nat next', Nat lst', Nat len', Nat bits') ->
let nums = enumFromThenTo first' next' lst'
in VSeq Fal... | 681 | fromThenToV =
tlamN $ \ first ->
tlamN $ \ next ->
tlamN $ \ lst ->
tlamN $ \ bits ->
tlamN $ \ len ->
case (first, next, lst, len, bits) of
(Nat first', Nat next', Nat lst', Nat len', Nat bits') ->
let nums = enumFromThenTo first' next' lst'
in VSeq False (genericTake len' ... | 660 | false | true | 10 | 18 | 163 | 189 | 96 | 93 | null | null |
mrgaaron/dcpu-16 | src/haskell/Assembler.hs | bsd-2-clause | isLabel _ = False | 27 | isLabel _ = False | 27 | isLabel _ = False | 27 | false | false | 0 | 5 | 13 | 9 | 4 | 5 | null | null |
green-haskell/ghc | compiler/cmm/CmmCommonBlockElim.hs | bsd-3-clause | eqMaybeWith _ Nothing Nothing = True | 36 | eqMaybeWith _ Nothing Nothing = True | 36 | eqMaybeWith _ Nothing Nothing = True | 36 | false | false | 1 | 5 | 5 | 13 | 5 | 8 | null | null |
arquitecturas-concurrentes/stm-samples-haskell | 1_broken_accounts/src/Main.hs | mit | {- Workers -}
workers :: Int -> IORef Account -> [IO ()]
workers n account = replicate n (depositWorker account) ++
replicate n (withdrawWorker account) | 174 | workers :: Int -> IORef Account -> [IO ()]
workers n account = replicate n (depositWorker account) ++
replicate n (withdrawWorker account) | 159 | workers n account = replicate n (depositWorker account) ++
replicate n (withdrawWorker account) | 116 | true | true | 0 | 9 | 46 | 62 | 30 | 32 | null | null |
AlephAlpha/Samau | OldSamau/Eval.hs | gpl-2.0 | smDrop s = s | 28 | smDrop s = s | 28 | smDrop s = s | 28 | false | false | 0 | 5 | 19 | 9 | 4 | 5 | null | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.