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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
ngzax/urbit | pkg/hs/urbit-king/test/DeriveNounTests.hs | mit | throughNoun :: (ToNoun a, FromNoun b) => a -> Maybe b
throughNoun = fromNoun . toNoun | 85 | throughNoun :: (ToNoun a, FromNoun b) => a -> Maybe b
throughNoun = fromNoun . toNoun | 85 | throughNoun = fromNoun . toNoun | 31 | false | true | 0 | 7 | 15 | 37 | 19 | 18 | null | null |
sdx23/acid-state-dist | src/Data/Acid/Centered/Slave.hs | mit | -- | Open a local State as Slave for a _redundant_ Master. The directory of the local state
-- files can be specified.
enslaveRedStateFrom :: (IsAcidic st, Typeable st) =>
FilePath -- ^ location of the local state files.
-> String -- ^ hostname of the Master
-> PortNumber -- ^ port to connect to
-> st -- ^ initial state
-> IO (AcidState st)
enslaveRedStateFrom = enslaveMayRedStateFrom True | 474 | enslaveRedStateFrom :: (IsAcidic st, Typeable st) =>
FilePath -- ^ location of the local state files.
-> String -- ^ hostname of the Master
-> PortNumber -- ^ port to connect to
-> st -- ^ initial state
-> IO (AcidState st)
enslaveRedStateFrom = enslaveMayRedStateFrom True | 355 | enslaveRedStateFrom = enslaveMayRedStateFrom True | 49 | true | true | 0 | 12 | 150 | 60 | 33 | 27 | null | null |
raimohanska/reactive-bacon | src/Reactive/Bacon/EventStream/IO.hs | bsd-3-clause | fromIO :: IO a -> IO (EventStream a)
fromIO action = fromNonStoppableProcess $ \sink -> void $ forkIO $ action >>= sink . Next >> sink End | 138 | fromIO :: IO a -> IO (EventStream a)
fromIO action = fromNonStoppableProcess $ \sink -> void $ forkIO $ action >>= sink . Next >> sink End | 138 | fromIO action = fromNonStoppableProcess $ \sink -> void $ forkIO $ action >>= sink . Next >> sink End | 101 | false | true | 0 | 11 | 26 | 65 | 31 | 34 | null | null |
tibbe/ghc | compiler/llvmGen/LlvmCodeGen/CodeGen.hs | bsd-3-clause | arg_vars :: [(CmmActual, ForeignHint)]
-> ([LlvmVar], LlvmStatements, [LlvmCmmDecl])
-> LlvmM ([LlvmVar], LlvmStatements, [LlvmCmmDecl])
arg_vars [] (vars, stmts, tops)
= return (vars, stmts, tops) | 218 | arg_vars :: [(CmmActual, ForeignHint)]
-> ([LlvmVar], LlvmStatements, [LlvmCmmDecl])
-> LlvmM ([LlvmVar], LlvmStatements, [LlvmCmmDecl])
arg_vars [] (vars, stmts, tops)
= return (vars, stmts, tops) | 217 | arg_vars [] (vars, stmts, tops)
= return (vars, stmts, tops) | 62 | false | true | 0 | 10 | 43 | 93 | 54 | 39 | null | null |
AkronCodeClub/edX-FP101x-Oct-2014 | jerry_d/functions.hs | mit | mixed = [True, False, True, False] | 34 | mixed = [True, False, True, False] | 34 | mixed = [True, False, True, False] | 34 | false | false | 0 | 5 | 5 | 18 | 11 | 7 | null | null |
mboes/dedukti | Dedukti/Synthesis/ANF.hs | gpl-3.0 | anf :: Ord id => Expr id a -> Expr id a
anf (B (x := t1) (V x' _) _) | x == x' = t1 | 83 | anf :: Ord id => Expr id a -> Expr id a
anf (B (x := t1) (V x' _) _) | x == x' = t1 | 83 | anf (B (x := t1) (V x' _) _) | x == x' = t1 | 43 | false | true | 0 | 8 | 26 | 74 | 34 | 40 | null | null |
ksaveljev/hake-2 | src/Constants.hs | bsd-3-clause | powerArmorShield = 2 :: Int | 27 | powerArmorShield = 2 :: Int | 27 | powerArmorShield = 2 :: Int | 27 | false | false | 0 | 4 | 4 | 9 | 5 | 4 | null | null |
garykl/Horg | Horg/Parse.hs | bsd-3-clause | getDates s =
let closed = filter (T.isPrefixOf $ T.pack "CLOSED:") s
scheduled = filter (T.isPrefixOf $ T.pack "SCHEDULED:") s
deadline = filter (T.isPrefixOf $ T.pack "DEADLINE:") s
in filtern Closed (map extractDate closed)
++ filtern Scheduled (map extractDate scheduled)
++ filtern Deadline (map extractDate deadline)
where
extractDate :: T.Text -> Maybe LocalTime
extractDate = parseDate . unwords . map T.unpack . tail . T.words
filtern :: (LocalTime -> Datetype LocalTime)
-> [Maybe LocalTime]
-> [Datetype LocalTime]
filtern f ll = map f $ justFilter ll | 640 | getDates s =
let closed = filter (T.isPrefixOf $ T.pack "CLOSED:") s
scheduled = filter (T.isPrefixOf $ T.pack "SCHEDULED:") s
deadline = filter (T.isPrefixOf $ T.pack "DEADLINE:") s
in filtern Closed (map extractDate closed)
++ filtern Scheduled (map extractDate scheduled)
++ filtern Deadline (map extractDate deadline)
where
extractDate :: T.Text -> Maybe LocalTime
extractDate = parseDate . unwords . map T.unpack . tail . T.words
filtern :: (LocalTime -> Datetype LocalTime)
-> [Maybe LocalTime]
-> [Datetype LocalTime]
filtern f ll = map f $ justFilter ll | 640 | getDates s =
let closed = filter (T.isPrefixOf $ T.pack "CLOSED:") s
scheduled = filter (T.isPrefixOf $ T.pack "SCHEDULED:") s
deadline = filter (T.isPrefixOf $ T.pack "DEADLINE:") s
in filtern Closed (map extractDate closed)
++ filtern Scheduled (map extractDate scheduled)
++ filtern Deadline (map extractDate deadline)
where
extractDate :: T.Text -> Maybe LocalTime
extractDate = parseDate . unwords . map T.unpack . tail . T.words
filtern :: (LocalTime -> Datetype LocalTime)
-> [Maybe LocalTime]
-> [Datetype LocalTime]
filtern f ll = map f $ justFilter ll | 640 | false | false | 4 | 13 | 164 | 236 | 113 | 123 | null | null |
msakai/icfpc2014 | GHostCPU.hs | bsd-3-clause | getValue _ regs mem (ArgInd r) = readArray regs r >>= readArray mem | 69 | getValue _ regs mem (ArgInd r) = readArray regs r >>= readArray mem | 69 | getValue _ regs mem (ArgInd r) = readArray regs r >>= readArray mem | 69 | false | false | 0 | 7 | 14 | 33 | 15 | 18 | null | null |
benweitzman/PhoBuddies | src/Actions.hs | mit | registerA :: API RegistrationRequest ()
registerA request = do
mHashedPassword <- liftIO . hashPassword $ password request
case mHashedPassword of
Nothing ->
raise unknownFailure
Just hashedPassword -> do
currentTime <- liftIO getCurrentTime
let user = requestToUser request hashedPassword currentTime
mKey <- runDB (DB.insertUnique user)
case mKey of
Nothing ->
raise $ Failure conflict409 "Duplicate email"
Just _ ->
return (created201, ()) | 527 | registerA :: API RegistrationRequest ()
registerA request = do
mHashedPassword <- liftIO . hashPassword $ password request
case mHashedPassword of
Nothing ->
raise unknownFailure
Just hashedPassword -> do
currentTime <- liftIO getCurrentTime
let user = requestToUser request hashedPassword currentTime
mKey <- runDB (DB.insertUnique user)
case mKey of
Nothing ->
raise $ Failure conflict409 "Duplicate email"
Just _ ->
return (created201, ()) | 527 | registerA request = do
mHashedPassword <- liftIO . hashPassword $ password request
case mHashedPassword of
Nothing ->
raise unknownFailure
Just hashedPassword -> do
currentTime <- liftIO getCurrentTime
let user = requestToUser request hashedPassword currentTime
mKey <- runDB (DB.insertUnique user)
case mKey of
Nothing ->
raise $ Failure conflict409 "Duplicate email"
Just _ ->
return (created201, ()) | 487 | false | true | 0 | 17 | 145 | 150 | 68 | 82 | null | null |
nickspinale/htorrent | src/HTorrent/State.hs | mit | newTShan :: STM (TShan a)
newTShan = TShan <$> newTVar [] | 57 | newTShan :: STM (TShan a)
newTShan = TShan <$> newTVar [] | 57 | newTShan = TShan <$> newTVar [] | 31 | false | true | 0 | 7 | 10 | 29 | 14 | 15 | null | null |
mzini/TcT | source/Tct/Method/Bounds/Automata.hs | gpl-3.0 | toRules :: Automaton -> [Rule]
toRules a = [Collapse (invEnum f,l) args q | (f,m1) <- IMap.toList $ fwd a
, (l,m2) <- IMap.toList m1
, (args, qs) <- Map.toList m2
, q <- Set.toList qs] | 313 | toRules :: Automaton -> [Rule]
toRules a = [Collapse (invEnum f,l) args q | (f,m1) <- IMap.toList $ fwd a
, (l,m2) <- IMap.toList m1
, (args, qs) <- Map.toList m2
, q <- Set.toList qs] | 313 | toRules a = [Collapse (invEnum f,l) args q | (f,m1) <- IMap.toList $ fwd a
, (l,m2) <- IMap.toList m1
, (args, qs) <- Map.toList m2
, q <- Set.toList qs] | 282 | false | true | 0 | 9 | 164 | 114 | 59 | 55 | null | null |
urbanslug/ghc | libraries/base/codepages/MakeTable.hs | bsd-3-clause | main :: IO ()
main = do
moduleName:outFile:files <- getArgs
let badFiles = -- These fail with an error like
-- MakeTable: Enum.toEnum{Word8}: tag (33088) is outside of bounds (0,255)
-- I have no idea what's going on, so for now we just
-- skip them.
["CPs/CP932.TXT",
"CPs/CP936.TXT",
"CPs/CP949.TXT",
"CPs/CP950.TXT"]
let files' = filter (`notElem` badFiles) files
sbes <- mapM readMapAndIx files'
putStrLn "Writing output"
withBinaryFile outFile WriteMode $ flip hPutStr
$ unlines $ makeTableFile moduleName files' sbes
where
readMapAndIx f = do
putStrLn ("Reading " ++ f)
m <- readMap f
return (codePageNum f, m)
-- filenames are assumed to be of the form "CP1250.TXT" | 875 | main :: IO ()
main = do
moduleName:outFile:files <- getArgs
let badFiles = -- These fail with an error like
-- MakeTable: Enum.toEnum{Word8}: tag (33088) is outside of bounds (0,255)
-- I have no idea what's going on, so for now we just
-- skip them.
["CPs/CP932.TXT",
"CPs/CP936.TXT",
"CPs/CP949.TXT",
"CPs/CP950.TXT"]
let files' = filter (`notElem` badFiles) files
sbes <- mapM readMapAndIx files'
putStrLn "Writing output"
withBinaryFile outFile WriteMode $ flip hPutStr
$ unlines $ makeTableFile moduleName files' sbes
where
readMapAndIx f = do
putStrLn ("Reading " ++ f)
m <- readMap f
return (codePageNum f, m)
-- filenames are assumed to be of the form "CP1250.TXT" | 875 | main = do
moduleName:outFile:files <- getArgs
let badFiles = -- These fail with an error like
-- MakeTable: Enum.toEnum{Word8}: tag (33088) is outside of bounds (0,255)
-- I have no idea what's going on, so for now we just
-- skip them.
["CPs/CP932.TXT",
"CPs/CP936.TXT",
"CPs/CP949.TXT",
"CPs/CP950.TXT"]
let files' = filter (`notElem` badFiles) files
sbes <- mapM readMapAndIx files'
putStrLn "Writing output"
withBinaryFile outFile WriteMode $ flip hPutStr
$ unlines $ makeTableFile moduleName files' sbes
where
readMapAndIx f = do
putStrLn ("Reading " ++ f)
m <- readMap f
return (codePageNum f, m)
-- filenames are assumed to be of the form "CP1250.TXT" | 861 | false | true | 0 | 11 | 308 | 173 | 85 | 88 | null | null |
Mathnerd314/atomo | src/Atomo/Environment.hs | bsd-3-clause | targets is (Keyword _ _ ps) = do
ts <- mapM (targets' is) ps
return (nub (concat ts)) | 93 | targets is (Keyword _ _ ps) = do
ts <- mapM (targets' is) ps
return (nub (concat ts)) | 93 | targets is (Keyword _ _ ps) = do
ts <- mapM (targets' is) ps
return (nub (concat ts)) | 93 | false | false | 0 | 11 | 25 | 59 | 26 | 33 | null | null |
energyflowanalysis/efa-2.1 | src/EFA/Signal/Signal.hs | bsd-3-clause | indexAdd :: SignalIdx -> Int -> SignalIdx
indexAdd (SignalIdx x) y = SignalIdx $ x P.+ y | 88 | indexAdd :: SignalIdx -> Int -> SignalIdx
indexAdd (SignalIdx x) y = SignalIdx $ x P.+ y | 88 | indexAdd (SignalIdx x) y = SignalIdx $ x P.+ y | 46 | false | true | 4 | 10 | 16 | 48 | 21 | 27 | null | null |
thomasbrus/imperia | src/Language/Imperia/Compiler.hs | mit | compile' :: Store -> Expression -> (Store, [Assembly])
compile' store (Sequencing expressions) =
foldl (\(store, assembly) expression ->
let (store', assembly') = compile' store expression
in (store', assembly ++ assembly')
) (store, []) expressions | 261 | compile' :: Store -> Expression -> (Store, [Assembly])
compile' store (Sequencing expressions) =
foldl (\(store, assembly) expression ->
let (store', assembly') = compile' store expression
in (store', assembly ++ assembly')
) (store, []) expressions | 261 | compile' store (Sequencing expressions) =
foldl (\(store, assembly) expression ->
let (store', assembly') = compile' store expression
in (store', assembly ++ assembly')
) (store, []) expressions | 206 | false | true | 0 | 12 | 45 | 103 | 56 | 47 | null | null |
pavolzetor/openexr-write | src/Graphics/OpenEXR.hs | gpl-3.0 | -- TODO: use some generic version of length
-- TODO: partial function (init)
offsetTable :: Integral a => a -> [a] -> Put
offsetTable offset chunksLengths = mapM_ (\x -> putWord64le (fromIntegral (offset + 8*nChunks + x))) . scanl (+) 0 . init $ chunksLengths
where nChunks = fromIntegral $ length chunksLengths | 319 | offsetTable :: Integral a => a -> [a] -> Put
offsetTable offset chunksLengths = mapM_ (\x -> putWord64le (fromIntegral (offset + 8*nChunks + x))) . scanl (+) 0 . init $ chunksLengths
where nChunks = fromIntegral $ length chunksLengths | 242 | offsetTable offset chunksLengths = mapM_ (\x -> putWord64le (fromIntegral (offset + 8*nChunks + x))) . scanl (+) 0 . init $ chunksLengths
where nChunks = fromIntegral $ length chunksLengths | 197 | true | true | 0 | 17 | 59 | 109 | 55 | 54 | null | null |
ambiata/mismi | mismi-autoscaling/test/Test/Mismi/Autoscaling/Data.hs | bsd-3-clause | tests = $quickCheckAll | 22 | tests = $quickCheckAll | 22 | tests = $quickCheckAll | 22 | false | false | 0 | 5 | 2 | 7 | 3 | 4 | null | null |
conal/hermit | src/HERMIT/Dictionary/Common.hs | bsd-2-clause | -- | List the identifiers bound by a recursive let expression.
letRecIdsT :: (ExtendPath c Crumb, ReadPath c Crumb, AddBindings c, Monad m) => Transform c m CoreExpr [Id]
letRecIdsT = letT recIdsT mempty (\ vs () -> vs) | 219 | letRecIdsT :: (ExtendPath c Crumb, ReadPath c Crumb, AddBindings c, Monad m) => Transform c m CoreExpr [Id]
letRecIdsT = letT recIdsT mempty (\ vs () -> vs) | 156 | letRecIdsT = letT recIdsT mempty (\ vs () -> vs) | 48 | true | true | 0 | 8 | 38 | 74 | 39 | 35 | null | null |
DataStewardshipPortal/ds-form-engine | FormElement/Rendering.hs | apache-2.0 | renderNumberElement :: FormElement -> FormContext -> ElemBehaviour -> JQuery -> IO JQuery
renderNumberElement element context behaviour jq =
let
elemIOJq = select "<span></span>"
>>= appendT "<input type='number' step='0.1'>"
>>= setAttrInside "id" (elementId element)
>>= setAttrInside "name" (elementId element)
>>= setAttrInside "identity" (Element.identity element)
>>= setAttrInside "value" (fromMaybe "" $ show <$> neMaybeValue element)
>>= setMouseEnterHandler (elementFocusHandler element context behaviour)
>>= setKeyupHandler (elementFocusHandler element context behaviour)
>>= setBlurHandler (elementBlurHandler element context behaviour)
>>= setMouseLeaveHandler (elementBlurHandler element context behaviour)
>>= setChangeHandler (elementClickHandler element context behaviour)
>>= appendT " "
>>= case nfiUnit (formItem element) of
NoUnit -> return
SingleUnit u -> appendT u
MultipleUnit units -> renderUnits units
where
renderUnits :: [String] -> JQuery -> IO JQuery
renderUnits units jq1 = foldlM (flip renderUnit) jq1 units
where
renderUnit :: String -> JQuery -> IO JQuery
renderUnit unit jq2 =
appendT "<input type='radio'>" jq2
>>= setAttrInside "value" unit
>>= setAttrInside "name" (nfiUnitId $ nfi element)
>>= setMouseEnterHandler (elementFocusHandler element context behaviour)
>>= setClickHandler (elementFocusHandler element context behaviour)
>>= setMouseLeaveHandler (elementBlurHandler element context behaviour)
>>= case neMaybeUnitValue element of
Nothing -> return
Just selectedOption -> if selectedOption == unit then setAttrInside "checked" "checked" else return
>>= appendT "<label>" >>= setTextInside unit
>>= appendT " "
in renderInput elemIOJq element context behaviour jq | 2,021 | renderNumberElement :: FormElement -> FormContext -> ElemBehaviour -> JQuery -> IO JQuery
renderNumberElement element context behaviour jq =
let
elemIOJq = select "<span></span>"
>>= appendT "<input type='number' step='0.1'>"
>>= setAttrInside "id" (elementId element)
>>= setAttrInside "name" (elementId element)
>>= setAttrInside "identity" (Element.identity element)
>>= setAttrInside "value" (fromMaybe "" $ show <$> neMaybeValue element)
>>= setMouseEnterHandler (elementFocusHandler element context behaviour)
>>= setKeyupHandler (elementFocusHandler element context behaviour)
>>= setBlurHandler (elementBlurHandler element context behaviour)
>>= setMouseLeaveHandler (elementBlurHandler element context behaviour)
>>= setChangeHandler (elementClickHandler element context behaviour)
>>= appendT " "
>>= case nfiUnit (formItem element) of
NoUnit -> return
SingleUnit u -> appendT u
MultipleUnit units -> renderUnits units
where
renderUnits :: [String] -> JQuery -> IO JQuery
renderUnits units jq1 = foldlM (flip renderUnit) jq1 units
where
renderUnit :: String -> JQuery -> IO JQuery
renderUnit unit jq2 =
appendT "<input type='radio'>" jq2
>>= setAttrInside "value" unit
>>= setAttrInside "name" (nfiUnitId $ nfi element)
>>= setMouseEnterHandler (elementFocusHandler element context behaviour)
>>= setClickHandler (elementFocusHandler element context behaviour)
>>= setMouseLeaveHandler (elementBlurHandler element context behaviour)
>>= case neMaybeUnitValue element of
Nothing -> return
Just selectedOption -> if selectedOption == unit then setAttrInside "checked" "checked" else return
>>= appendT "<label>" >>= setTextInside unit
>>= appendT " "
in renderInput elemIOJq element context behaviour jq | 2,021 | renderNumberElement element context behaviour jq =
let
elemIOJq = select "<span></span>"
>>= appendT "<input type='number' step='0.1'>"
>>= setAttrInside "id" (elementId element)
>>= setAttrInside "name" (elementId element)
>>= setAttrInside "identity" (Element.identity element)
>>= setAttrInside "value" (fromMaybe "" $ show <$> neMaybeValue element)
>>= setMouseEnterHandler (elementFocusHandler element context behaviour)
>>= setKeyupHandler (elementFocusHandler element context behaviour)
>>= setBlurHandler (elementBlurHandler element context behaviour)
>>= setMouseLeaveHandler (elementBlurHandler element context behaviour)
>>= setChangeHandler (elementClickHandler element context behaviour)
>>= appendT " "
>>= case nfiUnit (formItem element) of
NoUnit -> return
SingleUnit u -> appendT u
MultipleUnit units -> renderUnits units
where
renderUnits :: [String] -> JQuery -> IO JQuery
renderUnits units jq1 = foldlM (flip renderUnit) jq1 units
where
renderUnit :: String -> JQuery -> IO JQuery
renderUnit unit jq2 =
appendT "<input type='radio'>" jq2
>>= setAttrInside "value" unit
>>= setAttrInside "name" (nfiUnitId $ nfi element)
>>= setMouseEnterHandler (elementFocusHandler element context behaviour)
>>= setClickHandler (elementFocusHandler element context behaviour)
>>= setMouseLeaveHandler (elementBlurHandler element context behaviour)
>>= case neMaybeUnitValue element of
Nothing -> return
Just selectedOption -> if selectedOption == unit then setAttrInside "checked" "checked" else return
>>= appendT "<label>" >>= setTextInside unit
>>= appendT " "
in renderInput elemIOJq element context behaviour jq | 1,931 | false | true | 0 | 24 | 499 | 503 | 236 | 267 | null | null |
haslab/SecreC | src/Text/Derp.hs | gpl-3.0 | compact :: Parser t a -> Parser t a
compact = parserCompact | 59 | compact :: Parser t a -> Parser t a
compact = parserCompact | 59 | compact = parserCompact | 23 | false | true | 0 | 7 | 11 | 31 | 13 | 18 | null | null |
futtetennista/IntroductionToFunctionalProgramming | RWH/src/Ch26/src/BloomFilter/Immutable.hs | mit | elem :: a -> IBloom a -> Bool
x `elem` bfilt =
all test (ihash bfilt x)
where
test hashx =
iarray bfilt ! (hashx `mod` len bfilt) | 143 | elem :: a -> IBloom a -> Bool
x `elem` bfilt =
all test (ihash bfilt x)
where
test hashx =
iarray bfilt ! (hashx `mod` len bfilt) | 143 | x `elem` bfilt =
all test (ihash bfilt x)
where
test hashx =
iarray bfilt ! (hashx `mod` len bfilt) | 113 | false | true | 4 | 8 | 41 | 80 | 35 | 45 | null | null |
DougBurke/swish | tests/GraphTest.hs | lgpl-2.1 | eq2lmap' :: LabelMap (ScopedLabel LabelMem)
eq2lmap' = tstLabelMap 2 [
(s1_1,(1,142577)),(s2_1,(1,142578)),(s3_1,(1,142579)),
(p1_1,(1,142385)),(p2_1,(1,142386)),(p3_1,(1,142387)),
(o1_1,(1,142321)),(o2_1,(1,142322)),(o3_1,(1,142323)),
(l1_1,(1,142129)),(l4_1,(1,1709580)),(l10_1,(1,3766582)),
(b1_1,(2,3880463)),(b2_1,(2,3400925)),
(s1_2,(1,142577)),(s2_2,(1,142578)),(s3_2,(1,142579)),
(p1_2,(1,142385)),(p2_2,(1,142386)),(p3_2,(1,142387)),
(o1_2,(1,142321)),(o2_2,(1,142322)),(o3_2,(1,142323)),
(l1_2,(1,142129)),(l4_2,(1,1709580)),(l10_2,(1,3766582)),
(b1_2,(2,3880463)),(b2_2,(2,3400925))
] | 916 | eq2lmap' :: LabelMap (ScopedLabel LabelMem)
eq2lmap' = tstLabelMap 2 [
(s1_1,(1,142577)),(s2_1,(1,142578)),(s3_1,(1,142579)),
(p1_1,(1,142385)),(p2_1,(1,142386)),(p3_1,(1,142387)),
(o1_1,(1,142321)),(o2_1,(1,142322)),(o3_1,(1,142323)),
(l1_1,(1,142129)),(l4_1,(1,1709580)),(l10_1,(1,3766582)),
(b1_1,(2,3880463)),(b2_1,(2,3400925)),
(s1_2,(1,142577)),(s2_2,(1,142578)),(s3_2,(1,142579)),
(p1_2,(1,142385)),(p2_2,(1,142386)),(p3_2,(1,142387)),
(o1_2,(1,142321)),(o2_2,(1,142322)),(o3_2,(1,142323)),
(l1_2,(1,142129)),(l4_2,(1,1709580)),(l10_2,(1,3766582)),
(b1_2,(2,3880463)),(b2_2,(2,3400925))
] | 916 | eq2lmap' = tstLabelMap 2 [
(s1_1,(1,142577)),(s2_1,(1,142578)),(s3_1,(1,142579)),
(p1_1,(1,142385)),(p2_1,(1,142386)),(p3_1,(1,142387)),
(o1_1,(1,142321)),(o2_1,(1,142322)),(o3_1,(1,142323)),
(l1_1,(1,142129)),(l4_1,(1,1709580)),(l10_1,(1,3766582)),
(b1_1,(2,3880463)),(b2_1,(2,3400925)),
(s1_2,(1,142577)),(s2_2,(1,142578)),(s3_2,(1,142579)),
(p1_2,(1,142385)),(p2_2,(1,142386)),(p3_2,(1,142387)),
(o1_2,(1,142321)),(o2_2,(1,142322)),(o3_2,(1,142323)),
(l1_2,(1,142129)),(l4_2,(1,1709580)),(l10_2,(1,3766582)),
(b1_2,(2,3880463)),(b2_2,(2,3400925))
] | 872 | false | true | 0 | 8 | 341 | 445 | 292 | 153 | null | null |
sdiehl/ghc | libraries/template-haskell/Language/Haskell/TH/PprLib.hs | bsd-3-clause | hang d1 n d2 = do d1' <- d1
d2' <- d2
return (HPJ.hang d1' n d2')
-- punctuate uses the same definition as Text.PrettyPrint | 160 | hang d1 n d2 = do d1' <- d1
d2' <- d2
return (HPJ.hang d1' n d2')
-- punctuate uses the same definition as Text.PrettyPrint | 160 | hang d1 n d2 = do d1' <- d1
d2' <- d2
return (HPJ.hang d1' n d2')
-- punctuate uses the same definition as Text.PrettyPrint | 160 | false | false | 0 | 10 | 61 | 46 | 21 | 25 | null | null |
jeffreyrosenbluth/flourine | src/Fluorine/HTML/Attributes.hs | bsd-3-clause | readonly :: Bool -> Attr i
readonly = attr $ attributeName "readonly" | 69 | readonly :: Bool -> Attr i
readonly = attr $ attributeName "readonly" | 69 | readonly = attr $ attributeName "readonly" | 42 | false | true | 2 | 7 | 11 | 32 | 13 | 19 | null | null |
bitemyapp/bloodhound | src/Bloodhound/Import.hs | bsd-3-clause | showText :: Show a => a -> Text
showText = T.pack . show | 56 | showText :: Show a => a -> Text
showText = T.pack . show | 56 | showText = T.pack . show | 24 | false | true | 0 | 8 | 12 | 35 | 15 | 20 | null | null |
kishoredbn/barrelfish | tools/mackerel/BitFieldDriver.hs | mit | -- Get the arguments right for array- and non-array registers
register_args pre r post =
pre ++
[ (dev_ptr, "_dev") ] ++
( if RT.is_array r then [("int","_i")] else [] ) ++ post | 207 | register_args pre r post =
pre ++
[ (dev_ptr, "_dev") ] ++
( if RT.is_array r then [("int","_i")] else [] ) ++ post | 145 | register_args pre r post =
pre ++
[ (dev_ptr, "_dev") ] ++
( if RT.is_array r then [("int","_i")] else [] ) ++ post | 145 | true | false | 0 | 10 | 62 | 62 | 35 | 27 | null | null |
quickdudley/varroa | Neural.hs | agpl-3.0 | feedforward :: NNet -> [Double] -> [Double]
feedforward = flip (foldl' feedlayer) | 81 | feedforward :: NNet -> [Double] -> [Double]
feedforward = flip (foldl' feedlayer) | 81 | feedforward = flip (foldl' feedlayer) | 37 | false | true | 0 | 9 | 11 | 41 | 19 | 22 | null | null |
ksaveljev/hake-2 | src/Client/MenuGlobals.hs | bsd-3-clause | initialMenuGlobals :: MenuGlobals
initialMenuGlobals = MenuGlobals
{ _mgMenuFrameworks = V.replicate 13 newMenuFrameworkS
, _mgMenuListSItems = V.fromList
[ newMenuListS -- 0 modeList
, newMenuListS -- 1 refList
, newMenuListS -- 2 fsBox
, newMenuListS -- 3 stippleBox
, newMenuListS -- 4 palettedTextureBox
, newMenuListS -- 5 vSyncBox
, newMenuListS -- 6 windowedMouse
, newMenuListS -- 7 optionsFreeLookBox
, newMenuListS -- 8 optionsNoAltTabBox
, newMenuListS -- 9 optionsAlwaysRunBox
, newMenuListS -- 10 optionsInvertMouseBox
, newMenuListS -- 11 optionsLookSpringBox
, newMenuListS -- 12 optionsLookStrafeBox
, newMenuListS -- 13 optionsCrosshairBox
, newMenuListS -- 14 optionsJoystickBox
, newMenuListS -- 15 optionsCdVolumeBox
, newMenuListS -- 16 optionsQualityList
, newMenuListS -- 17 startMapList
, newMenuListS -- 18 rulesBox
, newMenuListS -- 19 friendlyFireBox
, newMenuListS -- 20 fallsBox
, newMenuListS -- 21 weaponsStayBox
, newMenuListS -- 22 instantPowerUpsBox
, newMenuListS -- 23 powerUpsBox
, newMenuListS -- 24 healthBox
, newMenuListS -- 25 spawnFarthestBox
, newMenuListS -- 26 teamPlayBox
, newMenuListS -- 27 sameLevelBox
, newMenuListS -- 28 forceRespawnBox
, newMenuListS -- 29 armorBox
, newMenuListS -- 30 allowExitBox
, newMenuListS -- 31 infiniteAmmoBox
, newMenuListS -- 32 fixedFovBox
, newMenuListS -- 33 quadDropBox
, newMenuListS -- 34 noMinesBox
, newMenuListS -- 35 noNukesBox
, newMenuListS -- 36 stackDoubleBox
, newMenuListS -- 37 noSpheresBox
, newMenuListS -- 38 allowDownloadBox
, newMenuListS -- 39 allowDownloadMapsBox
, newMenuListS -- 40 allowDownloadModelsBox
, newMenuListS -- 41 allowDownloadPlayersBox
, newMenuListS -- 42 allowDownloadSoundsBox
, newMenuListS -- 43 playerModelBox
, newMenuListS -- 44 playerSkinBox
, newMenuListS -- 45 playerHandednessBox
, newMenuListS -- 46 playerRateBox
]
, _mgMenuSliderSItems = V.fromList
[ newMenuSliderS -- tqSlider
, newMenuSliderS -- screenSizeSlider
, newMenuSliderS -- brightnessSlider
, newMenuSliderS -- optionsSensitivitySlider
, newMenuSliderS -- optionsSfxVolumeSlider
]
, _mgMenuActionSItems = V.fromList
( menuActions
++ replicate maxSaveGames newMenuActionS -- loadGameActions
++ replicate maxSaveGames newMenuActionS -- saveGameActions
++ replicate Constants.maxLocalServers newMenuActionS -- joinServerActions
)
, _mgMenuSeparatorSItems = V.fromList
[ newMenuSeparatorS -- blankLine
, newMenuSeparatorS -- joinServerServerTitle
, newMenuSeparatorS -- downloadTitle
, newMenuSeparatorS -- playerSkinTitle
, newMenuSeparatorS -- playerModelTitle
, newMenuSeparatorS -- playerHandTitle
, newMenuSeparatorS -- playerRateTitle
]
, _mgMenuFieldSItems = V.fromList (menuFields ++ replicate Constants.numAddressBookEntries newMenuFieldS) -- addressBookFields
, _mgLayers = V.replicate maxMenuDepth newMenuLayerT
, _mgDrawFunc = Nothing
, _mgKeyFunc = Nothing
, _mgEnterSound = False
, _mgMenuDepth = 0
, _mgMainCursor = 0
, _mgCached = False
, _mgGameCursor = 0
, _mgSaveStrings = V.replicate maxSaveGames ""
, _mgSaveValid = V.replicate maxSaveGames False
, _mgLocalServerNames = V.replicate Constants.maxLocalServers ""
, _mgLocalServerNetAdr = V.replicate Constants.maxLocalServers newNetAdrT
, _mgCreditsStartTime = 0
, _mgCredits = idCredits
, _mgNumServers = 0
, _mgBindGrab = False
, _mgDmOptionsStatusBar = Nothing
, _mgMapNames = Nothing
} | 4,177 | initialMenuGlobals :: MenuGlobals
initialMenuGlobals = MenuGlobals
{ _mgMenuFrameworks = V.replicate 13 newMenuFrameworkS
, _mgMenuListSItems = V.fromList
[ newMenuListS -- 0 modeList
, newMenuListS -- 1 refList
, newMenuListS -- 2 fsBox
, newMenuListS -- 3 stippleBox
, newMenuListS -- 4 palettedTextureBox
, newMenuListS -- 5 vSyncBox
, newMenuListS -- 6 windowedMouse
, newMenuListS -- 7 optionsFreeLookBox
, newMenuListS -- 8 optionsNoAltTabBox
, newMenuListS -- 9 optionsAlwaysRunBox
, newMenuListS -- 10 optionsInvertMouseBox
, newMenuListS -- 11 optionsLookSpringBox
, newMenuListS -- 12 optionsLookStrafeBox
, newMenuListS -- 13 optionsCrosshairBox
, newMenuListS -- 14 optionsJoystickBox
, newMenuListS -- 15 optionsCdVolumeBox
, newMenuListS -- 16 optionsQualityList
, newMenuListS -- 17 startMapList
, newMenuListS -- 18 rulesBox
, newMenuListS -- 19 friendlyFireBox
, newMenuListS -- 20 fallsBox
, newMenuListS -- 21 weaponsStayBox
, newMenuListS -- 22 instantPowerUpsBox
, newMenuListS -- 23 powerUpsBox
, newMenuListS -- 24 healthBox
, newMenuListS -- 25 spawnFarthestBox
, newMenuListS -- 26 teamPlayBox
, newMenuListS -- 27 sameLevelBox
, newMenuListS -- 28 forceRespawnBox
, newMenuListS -- 29 armorBox
, newMenuListS -- 30 allowExitBox
, newMenuListS -- 31 infiniteAmmoBox
, newMenuListS -- 32 fixedFovBox
, newMenuListS -- 33 quadDropBox
, newMenuListS -- 34 noMinesBox
, newMenuListS -- 35 noNukesBox
, newMenuListS -- 36 stackDoubleBox
, newMenuListS -- 37 noSpheresBox
, newMenuListS -- 38 allowDownloadBox
, newMenuListS -- 39 allowDownloadMapsBox
, newMenuListS -- 40 allowDownloadModelsBox
, newMenuListS -- 41 allowDownloadPlayersBox
, newMenuListS -- 42 allowDownloadSoundsBox
, newMenuListS -- 43 playerModelBox
, newMenuListS -- 44 playerSkinBox
, newMenuListS -- 45 playerHandednessBox
, newMenuListS -- 46 playerRateBox
]
, _mgMenuSliderSItems = V.fromList
[ newMenuSliderS -- tqSlider
, newMenuSliderS -- screenSizeSlider
, newMenuSliderS -- brightnessSlider
, newMenuSliderS -- optionsSensitivitySlider
, newMenuSliderS -- optionsSfxVolumeSlider
]
, _mgMenuActionSItems = V.fromList
( menuActions
++ replicate maxSaveGames newMenuActionS -- loadGameActions
++ replicate maxSaveGames newMenuActionS -- saveGameActions
++ replicate Constants.maxLocalServers newMenuActionS -- joinServerActions
)
, _mgMenuSeparatorSItems = V.fromList
[ newMenuSeparatorS -- blankLine
, newMenuSeparatorS -- joinServerServerTitle
, newMenuSeparatorS -- downloadTitle
, newMenuSeparatorS -- playerSkinTitle
, newMenuSeparatorS -- playerModelTitle
, newMenuSeparatorS -- playerHandTitle
, newMenuSeparatorS -- playerRateTitle
]
, _mgMenuFieldSItems = V.fromList (menuFields ++ replicate Constants.numAddressBookEntries newMenuFieldS) -- addressBookFields
, _mgLayers = V.replicate maxMenuDepth newMenuLayerT
, _mgDrawFunc = Nothing
, _mgKeyFunc = Nothing
, _mgEnterSound = False
, _mgMenuDepth = 0
, _mgMainCursor = 0
, _mgCached = False
, _mgGameCursor = 0
, _mgSaveStrings = V.replicate maxSaveGames ""
, _mgSaveValid = V.replicate maxSaveGames False
, _mgLocalServerNames = V.replicate Constants.maxLocalServers ""
, _mgLocalServerNetAdr = V.replicate Constants.maxLocalServers newNetAdrT
, _mgCreditsStartTime = 0
, _mgCredits = idCredits
, _mgNumServers = 0
, _mgBindGrab = False
, _mgDmOptionsStatusBar = Nothing
, _mgMapNames = Nothing
} | 4,177 | initialMenuGlobals = MenuGlobals
{ _mgMenuFrameworks = V.replicate 13 newMenuFrameworkS
, _mgMenuListSItems = V.fromList
[ newMenuListS -- 0 modeList
, newMenuListS -- 1 refList
, newMenuListS -- 2 fsBox
, newMenuListS -- 3 stippleBox
, newMenuListS -- 4 palettedTextureBox
, newMenuListS -- 5 vSyncBox
, newMenuListS -- 6 windowedMouse
, newMenuListS -- 7 optionsFreeLookBox
, newMenuListS -- 8 optionsNoAltTabBox
, newMenuListS -- 9 optionsAlwaysRunBox
, newMenuListS -- 10 optionsInvertMouseBox
, newMenuListS -- 11 optionsLookSpringBox
, newMenuListS -- 12 optionsLookStrafeBox
, newMenuListS -- 13 optionsCrosshairBox
, newMenuListS -- 14 optionsJoystickBox
, newMenuListS -- 15 optionsCdVolumeBox
, newMenuListS -- 16 optionsQualityList
, newMenuListS -- 17 startMapList
, newMenuListS -- 18 rulesBox
, newMenuListS -- 19 friendlyFireBox
, newMenuListS -- 20 fallsBox
, newMenuListS -- 21 weaponsStayBox
, newMenuListS -- 22 instantPowerUpsBox
, newMenuListS -- 23 powerUpsBox
, newMenuListS -- 24 healthBox
, newMenuListS -- 25 spawnFarthestBox
, newMenuListS -- 26 teamPlayBox
, newMenuListS -- 27 sameLevelBox
, newMenuListS -- 28 forceRespawnBox
, newMenuListS -- 29 armorBox
, newMenuListS -- 30 allowExitBox
, newMenuListS -- 31 infiniteAmmoBox
, newMenuListS -- 32 fixedFovBox
, newMenuListS -- 33 quadDropBox
, newMenuListS -- 34 noMinesBox
, newMenuListS -- 35 noNukesBox
, newMenuListS -- 36 stackDoubleBox
, newMenuListS -- 37 noSpheresBox
, newMenuListS -- 38 allowDownloadBox
, newMenuListS -- 39 allowDownloadMapsBox
, newMenuListS -- 40 allowDownloadModelsBox
, newMenuListS -- 41 allowDownloadPlayersBox
, newMenuListS -- 42 allowDownloadSoundsBox
, newMenuListS -- 43 playerModelBox
, newMenuListS -- 44 playerSkinBox
, newMenuListS -- 45 playerHandednessBox
, newMenuListS -- 46 playerRateBox
]
, _mgMenuSliderSItems = V.fromList
[ newMenuSliderS -- tqSlider
, newMenuSliderS -- screenSizeSlider
, newMenuSliderS -- brightnessSlider
, newMenuSliderS -- optionsSensitivitySlider
, newMenuSliderS -- optionsSfxVolumeSlider
]
, _mgMenuActionSItems = V.fromList
( menuActions
++ replicate maxSaveGames newMenuActionS -- loadGameActions
++ replicate maxSaveGames newMenuActionS -- saveGameActions
++ replicate Constants.maxLocalServers newMenuActionS -- joinServerActions
)
, _mgMenuSeparatorSItems = V.fromList
[ newMenuSeparatorS -- blankLine
, newMenuSeparatorS -- joinServerServerTitle
, newMenuSeparatorS -- downloadTitle
, newMenuSeparatorS -- playerSkinTitle
, newMenuSeparatorS -- playerModelTitle
, newMenuSeparatorS -- playerHandTitle
, newMenuSeparatorS -- playerRateTitle
]
, _mgMenuFieldSItems = V.fromList (menuFields ++ replicate Constants.numAddressBookEntries newMenuFieldS) -- addressBookFields
, _mgLayers = V.replicate maxMenuDepth newMenuLayerT
, _mgDrawFunc = Nothing
, _mgKeyFunc = Nothing
, _mgEnterSound = False
, _mgMenuDepth = 0
, _mgMainCursor = 0
, _mgCached = False
, _mgGameCursor = 0
, _mgSaveStrings = V.replicate maxSaveGames ""
, _mgSaveValid = V.replicate maxSaveGames False
, _mgLocalServerNames = V.replicate Constants.maxLocalServers ""
, _mgLocalServerNetAdr = V.replicate Constants.maxLocalServers newNetAdrT
, _mgCreditsStartTime = 0
, _mgCredits = idCredits
, _mgNumServers = 0
, _mgBindGrab = False
, _mgDmOptionsStatusBar = Nothing
, _mgMapNames = Nothing
} | 4,143 | false | true | 0 | 13 | 1,250 | 518 | 337 | 181 | null | null |
rueshyna/gogol | gogol-storage/gen/Network/Google/Resource/Storage/Objects/Patch.hs | mpl-2.0 | -- | Makes the operation conditional on whether the object\'s current
-- metageneration does not match the given value.
opIfMetagenerationNotMatch :: Lens' ObjectsPatch (Maybe Int64)
opIfMetagenerationNotMatch
= lens _opIfMetagenerationNotMatch
(\ s a -> s{_opIfMetagenerationNotMatch = a})
. mapping _Coerce | 322 | opIfMetagenerationNotMatch :: Lens' ObjectsPatch (Maybe Int64)
opIfMetagenerationNotMatch
= lens _opIfMetagenerationNotMatch
(\ s a -> s{_opIfMetagenerationNotMatch = a})
. mapping _Coerce | 202 | opIfMetagenerationNotMatch
= lens _opIfMetagenerationNotMatch
(\ s a -> s{_opIfMetagenerationNotMatch = a})
. mapping _Coerce | 139 | true | true | 0 | 10 | 52 | 56 | 29 | 27 | null | null |
dwb/koenigsrufen-haskell | src/KRBot/Players.hs | lgpl-3.0 | addVoidsForPlayer :: PlayerVoids -> PlayerPosition -> [Suit] -> PlayerVoids
addVoidsForPlayer pv p ss = Map.insertWith (++) p ss pv | 131 | addVoidsForPlayer :: PlayerVoids -> PlayerPosition -> [Suit] -> PlayerVoids
addVoidsForPlayer pv p ss = Map.insertWith (++) p ss pv | 131 | addVoidsForPlayer pv p ss = Map.insertWith (++) p ss pv | 55 | false | true | 0 | 8 | 18 | 46 | 24 | 22 | null | null |
kim/amazonka | amazonka-ml/gen/Network/AWS/MachineLearning/CreateEvaluation.hs | mpl-2.0 | -- | A user-supplied ID that uniquely identifies the 'Evaluation'.
ceEvaluationId :: Lens' CreateEvaluation Text
ceEvaluationId = lens _ceEvaluationId (\s a -> s { _ceEvaluationId = a }) | 186 | ceEvaluationId :: Lens' CreateEvaluation Text
ceEvaluationId = lens _ceEvaluationId (\s a -> s { _ceEvaluationId = a }) | 119 | ceEvaluationId = lens _ceEvaluationId (\s a -> s { _ceEvaluationId = a }) | 73 | true | true | 0 | 9 | 27 | 40 | 22 | 18 | null | null |
asilvestre/haskell-neo4j-rest-client | src/Database/Neo4j/Transactional/Cypher.hs | mit | transactionReq :: S.ByteString -> T.Text -> Params -> Neo4j (Either TransError Result)
transactionReq path cmd params = Neo4j $ \conn -> runResponse <$> httpCreate conn path (queryBody cmd params) | 196 | transactionReq :: S.ByteString -> T.Text -> Params -> Neo4j (Either TransError Result)
transactionReq path cmd params = Neo4j $ \conn -> runResponse <$> httpCreate conn path (queryBody cmd params) | 196 | transactionReq path cmd params = Neo4j $ \conn -> runResponse <$> httpCreate conn path (queryBody cmd params) | 109 | false | true | 0 | 10 | 28 | 73 | 36 | 37 | null | null |
ben-schulz/Idris-dev | src/Idris/Main.hs | bsd-3-clause | idris :: [Opt] -> IO (Maybe IState)
idris opts = do res <- runExceptT $ execStateT totalMain idrisInit
case res of
Left err -> do putStrLn $ pshow idrisInit err
return Nothing
Right ist -> return (Just ist)
where totalMain = do idrisMain opts
ist <- getIState
case idris_totcheckfail ist of
((fc, msg):_) -> ierror . At fc . Msg $ "Could not build: "++ msg
[] -> return ()
-- | Execute the provided Idris expression. | 612 | idris :: [Opt] -> IO (Maybe IState)
idris opts = do res <- runExceptT $ execStateT totalMain idrisInit
case res of
Left err -> do putStrLn $ pshow idrisInit err
return Nothing
Right ist -> return (Just ist)
where totalMain = do idrisMain opts
ist <- getIState
case idris_totcheckfail ist of
((fc, msg):_) -> ierror . At fc . Msg $ "Could not build: "++ msg
[] -> return ()
-- | Execute the provided Idris expression. | 612 | idris opts = do res <- runExceptT $ execStateT totalMain idrisInit
case res of
Left err -> do putStrLn $ pshow idrisInit err
return Nothing
Right ist -> return (Just ist)
where totalMain = do idrisMain opts
ist <- getIState
case idris_totcheckfail ist of
((fc, msg):_) -> ierror . At fc . Msg $ "Could not build: "++ msg
[] -> return ()
-- | Execute the provided Idris expression. | 576 | false | true | 0 | 16 | 272 | 180 | 84 | 96 | null | null |
lettier/gifcurry | src/gui/Main.hs | bsd-3-clause | updateStartAndEndTimeSpinButtonFractions
:: GR.GuiComponents
-> IO ()
updateStartAndEndTimeSpinButtonFractions
GR.GuiComponents
{ GR.startTimeSpinButton
, GR.endTimeSpinButton
}
= do
setSpinButtonFraction startTimeSpinButton
setSpinButtonFraction endTimeSpinButton | 290 | updateStartAndEndTimeSpinButtonFractions
:: GR.GuiComponents
-> IO ()
updateStartAndEndTimeSpinButtonFractions
GR.GuiComponents
{ GR.startTimeSpinButton
, GR.endTimeSpinButton
}
= do
setSpinButtonFraction startTimeSpinButton
setSpinButtonFraction endTimeSpinButton | 290 | updateStartAndEndTimeSpinButtonFractions
GR.GuiComponents
{ GR.startTimeSpinButton
, GR.endTimeSpinButton
}
= do
setSpinButtonFraction startTimeSpinButton
setSpinButtonFraction endTimeSpinButton | 214 | false | true | 4 | 6 | 44 | 43 | 23 | 20 | null | null |
brendanhay/gogol | gogol-accesscontextmanager/gen/Network/Google/AccessContextManager/Types/Product.hs | mpl-2.0 | -- | Creates a value of 'ReplaceAccessLevelsResponse' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'ralrAccessLevels'
replaceAccessLevelsResponse
:: ReplaceAccessLevelsResponse
replaceAccessLevelsResponse =
ReplaceAccessLevelsResponse' {_ralrAccessLevels = Nothing} | 359 | replaceAccessLevelsResponse
:: ReplaceAccessLevelsResponse
replaceAccessLevelsResponse =
ReplaceAccessLevelsResponse' {_ralrAccessLevels = Nothing} | 153 | replaceAccessLevelsResponse =
ReplaceAccessLevelsResponse' {_ralrAccessLevels = Nothing} | 90 | true | true | 1 | 7 | 48 | 28 | 16 | 12 | null | null |
Cahu/krpc-hs | src/KRPCHS/SpaceCenter.hs | gpl-3.0 | {-
- The mission elapsed time in seconds.
-}
getVesselMET :: KRPCHS.SpaceCenter.Vessel -> RPCContext (Double)
getVesselMET thisArg = do
let r = makeRequest "SpaceCenter" "Vessel_get_MET" [makeArgument 0 thisArg]
res <- sendRequest r
processResponse res | 266 | getVesselMET :: KRPCHS.SpaceCenter.Vessel -> RPCContext (Double)
getVesselMET thisArg = do
let r = makeRequest "SpaceCenter" "Vessel_get_MET" [makeArgument 0 thisArg]
res <- sendRequest r
processResponse res | 219 | getVesselMET thisArg = do
let r = makeRequest "SpaceCenter" "Vessel_get_MET" [makeArgument 0 thisArg]
res <- sendRequest r
processResponse res | 154 | true | true | 0 | 13 | 47 | 73 | 33 | 40 | null | null |
cullina/Extractor | src/GreedyIndSet.hs | bsd-3-clause | addListIntMaps [] ys = ys | 25 | addListIntMaps [] ys = ys | 25 | addListIntMaps [] ys = ys | 25 | false | false | 0 | 6 | 4 | 13 | 6 | 7 | null | null |
bgold-cosmos/Tidal | src/Sound/Tidal/Params.hs | gpl-3.0 | -- aliases
voi :: Pattern Double -> ControlPattern
voi = voice | 63 | voi :: Pattern Double -> ControlPattern
voi = voice | 51 | voi = voice | 11 | true | true | 0 | 7 | 11 | 26 | 11 | 15 | null | null |
bartolkaruza/software-testing-2014-group-W1 | week1/week_1_group_w1/TAMO.hs | apache-2.0 | test6b = lequiv (\ p q -> p || q) (\ p q -> q || p) | 51 | test6b = lequiv (\ p q -> p || q) (\ p q -> q || p) | 51 | test6b = lequiv (\ p q -> p || q) (\ p q -> q || p) | 51 | false | false | 0 | 8 | 16 | 39 | 21 | 18 | null | null |
brendanhay/gogol | gogol-android-enterprise/gen/Network/Google/Resource/AndroidEnterprise/Grouplicenses/Get.hs | mpl-2.0 | -- | The ID of the enterprise.
ggEnterpriseId :: Lens' GrouplicensesGet Text
ggEnterpriseId
= lens _ggEnterpriseId
(\ s a -> s{_ggEnterpriseId = a}) | 156 | ggEnterpriseId :: Lens' GrouplicensesGet Text
ggEnterpriseId
= lens _ggEnterpriseId
(\ s a -> s{_ggEnterpriseId = a}) | 125 | ggEnterpriseId
= lens _ggEnterpriseId
(\ s a -> s{_ggEnterpriseId = a}) | 79 | true | true | 0 | 8 | 30 | 43 | 22 | 21 | null | null |
vTurbine/ghc | compiler/utils/Util.hs | bsd-3-clause | thdOf3 (_,_,c) = c | 24 | thdOf3 (_,_,c) = c | 24 | thdOf3 (_,_,c) = c | 24 | false | false | 0 | 6 | 9 | 18 | 10 | 8 | null | null |
sdiehl/ghc | testsuite/tests/plugins/plugins12.hs | bsd-3-clause | x = map show [1,2,3] | 20 | x = map show [1,2,3] | 20 | x = map show [1,2,3] | 20 | false | false | 1 | 5 | 4 | 24 | 11 | 13 | null | null |
Mahdi89/eTeak | src/Finish.hs | bsd-3-clause | finish :: ParseTreeTraverse node => node -> node
finish c = c'
where
(_, _, typeStrippedC) = traverse typeStripApply [] () c
(_, _, c') = traverse finishApply emptyFinishContext () typeStrippedC | 230 | finish :: ParseTreeTraverse node => node -> node
finish c = c'
where
(_, _, typeStrippedC) = traverse typeStripApply [] () c
(_, _, c') = traverse finishApply emptyFinishContext () typeStrippedC | 226 | finish c = c'
where
(_, _, typeStrippedC) = traverse typeStripApply [] () c
(_, _, c') = traverse finishApply emptyFinishContext () typeStrippedC | 177 | false | true | 0 | 8 | 66 | 88 | 43 | 45 | null | null |
brendanhay/gogol | gogol-docs/gen/Network/Google/Docs/Types/Product.hs | mpl-2.0 | -- | Indicates if there was a suggested change to margin_right.
dsssMarginRightSuggested :: Lens' DocumentStyleSuggestionState (Maybe Bool)
dsssMarginRightSuggested
= lens _dsssMarginRightSuggested
(\ s a -> s{_dsssMarginRightSuggested = a}) | 249 | dsssMarginRightSuggested :: Lens' DocumentStyleSuggestionState (Maybe Bool)
dsssMarginRightSuggested
= lens _dsssMarginRightSuggested
(\ s a -> s{_dsssMarginRightSuggested = a}) | 185 | dsssMarginRightSuggested
= lens _dsssMarginRightSuggested
(\ s a -> s{_dsssMarginRightSuggested = a}) | 109 | true | true | 0 | 9 | 35 | 48 | 25 | 23 | null | null |
SAdams601/HaRe | old/testing/duplication/LetIn1AST.hs | bsd-3-clause | ram = (let fred = (let x = 5 in x)
dref = (let x = 5 in x)
in fred + x) +
1 | 126 | ram = (let fred = (let x = 5 in x)
dref = (let x = 5 in x)
in fred + x) +
1 | 126 | ram = (let fred = (let x = 5 in x)
dref = (let x = 5 in x)
in fred + x) +
1 | 126 | false | false | 1 | 15 | 75 | 65 | 31 | 34 | null | null |
mettekou/ghc | compiler/iface/IfaceType.hs | bsd-3-clause | pprIfaceContext preds = parens (fsep (punctuate comma (map ppr preds))) | 72 | pprIfaceContext preds = parens (fsep (punctuate comma (map ppr preds))) | 72 | pprIfaceContext preds = parens (fsep (punctuate comma (map ppr preds))) | 72 | false | false | 0 | 11 | 10 | 34 | 16 | 18 | null | null |
Borracc/FuncLang | homework1/toDigits.hs | gpl-3.0 | --toDigits.hs--
--Integer -> [Integer]--
toDigits x | x<=0 = [] | 64 | toDigits x | x<=0 = [] | 22 | toDigits x | x<=0 = [] | 22 | true | false | 0 | 8 | 10 | 27 | 12 | 15 | null | null |
ccqpein/Arithmetic-Exercises | Total-Hamming-Distance/THD.hs | apache-2.0 | diffHam :: (Integral a) => a -> a -> a
diffHam a b
| a == 0 && b == 0 = 0
| otherwise = let rr = if (mod a 2) /= (mod b 2)
then 1
else 0
in rr + diffHam (div a 2) (div b 2) | 236 | diffHam :: (Integral a) => a -> a -> a
diffHam a b
| a == 0 && b == 0 = 0
| otherwise = let rr = if (mod a 2) /= (mod b 2)
then 1
else 0
in rr + diffHam (div a 2) (div b 2) | 236 | diffHam a b
| a == 0 && b == 0 = 0
| otherwise = let rr = if (mod a 2) /= (mod b 2)
then 1
else 0
in rr + diffHam (div a 2) (div b 2) | 197 | false | true | 0 | 13 | 114 | 131 | 63 | 68 | null | null |
acowley/ghc | compiler/deSugar/DsArrows.hs | bsd-3-clause | do_arr :: DsCmdEnv -> Type -> Type -> CoreExpr -> CoreExpr
do_arr ids b_ty c_ty f = mkApps (arr_id ids) [Type b_ty, Type c_ty, f] | 129 | do_arr :: DsCmdEnv -> Type -> Type -> CoreExpr -> CoreExpr
do_arr ids b_ty c_ty f = mkApps (arr_id ids) [Type b_ty, Type c_ty, f] | 129 | do_arr ids b_ty c_ty f = mkApps (arr_id ids) [Type b_ty, Type c_ty, f] | 70 | false | true | 0 | 8 | 24 | 62 | 31 | 31 | null | null |
thomie/vector | Data/Vector/Mutable.hs | bsd-3-clause | take = G.take | 13 | take = G.take | 13 | take = G.take | 13 | false | false | 1 | 6 | 2 | 12 | 4 | 8 | null | null |
unsw-comp4181/accelerate-c-stub | Data/Array/Accelerate/C/Acc.hs | bsd-3-clause | -- Shapes
-- ------
-- Determine the dimensionality of an array.
--
arrDim :: forall sh e. (Shape sh, Elt e) => Array sh e -> Int
arrDim _dummy = dim (undefined::sh) | 166 | arrDim :: forall sh e. (Shape sh, Elt e) => Array sh e -> Int
arrDim _dummy = dim (undefined::sh) | 97 | arrDim _dummy = dim (undefined::sh) | 35 | true | true | 0 | 8 | 32 | 57 | 32 | 25 | null | null |
hguenther/nbis | Value.hs | agpl-3.0 | valCond (ConditionValue x _) = x | 32 | valCond (ConditionValue x _) = x | 32 | valCond (ConditionValue x _) = x | 32 | false | false | 0 | 6 | 5 | 18 | 8 | 10 | null | null |
carletes/matasano | src/Matasano.hs | bsd-3-clause | -- | Generates a random AES-128 IV.
randomIV :: IO B.ByteString
randomIV = randomBytes 16 | 89 | randomIV :: IO B.ByteString
randomIV = randomBytes 16 | 53 | randomIV = randomBytes 16 | 25 | true | true | 0 | 7 | 14 | 25 | 11 | 14 | null | null |
jabolopes/fmark | src/Parser.hs | bsd-3-clause | section :: [Int] -> Int -> [Token]
section [] _ = error "section: idns is empty" | 80 | section :: [Int] -> Int -> [Token]
section [] _ = error "section: idns is empty" | 80 | section [] _ = error "section: idns is empty" | 45 | false | true | 0 | 7 | 15 | 35 | 18 | 17 | null | null |
jystic/pointfree | Plugin/Pl/Transform.hs | mit | unLet (Lambda v e) = Lambda v (unLet e) | 39 | unLet (Lambda v e) = Lambda v (unLet e) | 39 | unLet (Lambda v e) = Lambda v (unLet e) | 39 | false | false | 0 | 7 | 8 | 28 | 13 | 15 | null | null |
palas/detparaminf | src/DetParamInf/TranMerge.hs | bsd-2-clause | mergePars (h1:t1) (h2:t2) = nub (h1 ++ h2):mergePars t1 t2 | 58 | mergePars (h1:t1) (h2:t2) = nub (h1 ++ h2):mergePars t1 t2 | 58 | mergePars (h1:t1) (h2:t2) = nub (h1 ++ h2):mergePars t1 t2 | 58 | false | false | 0 | 8 | 9 | 44 | 22 | 22 | null | null |
foreverbell/fm-client | lib/Data/Aeson/Extra.hs | bsd-3-clause | -- | Parses a JSON value as a 'JSON.Array'.
onArray :: (JSON.Array -> JSON.Parser a) -> JSON.Value -> JSON.Parser a
onArray = JSON.withArray "Array" | 148 | onArray :: (JSON.Array -> JSON.Parser a) -> JSON.Value -> JSON.Parser a
onArray = JSON.withArray "Array" | 104 | onArray = JSON.withArray "Array" | 32 | true | true | 0 | 9 | 23 | 46 | 23 | 23 | null | null |
beni55/ghcjs | src/Gen2/Prim.hs | mit | genPrim _ _ CloneSmallArrayOp [r] [a,o,n] = PrimInline [j| `r` = `a`.slice(`o`,`o`+`n`); |] | 108 | genPrim _ _ CloneSmallArrayOp [r] [a,o,n] = PrimInline [j| `r` = `a`.slice(`o`,`o`+`n`); |] | 108 | genPrim _ _ CloneSmallArrayOp [r] [a,o,n] = PrimInline [j| `r` = `a`.slice(`o`,`o`+`n`); |] | 108 | false | false | 0 | 6 | 29 | 36 | 21 | 15 | null | null |
green-haskell/ghc | compiler/prelude/TysPrim.hs | bsd-3-clause | mkArrayPrimTy :: Type -> Type
mkArrayPrimTy elt = TyConApp arrayPrimTyCon [elt] | 89 | mkArrayPrimTy :: Type -> Type
mkArrayPrimTy elt = TyConApp arrayPrimTyCon [elt] | 89 | mkArrayPrimTy elt = TyConApp arrayPrimTyCon [elt] | 59 | false | true | 0 | 6 | 20 | 26 | 13 | 13 | null | null |
EarthCitizen/baskell | src/Eval.hs | bsd-3-clause | eval v@(IntegerValue _) = Right $ v | 36 | eval v@(IntegerValue _) = Right $ v | 36 | eval v@(IntegerValue _) = Right $ v | 36 | false | false | 1 | 9 | 7 | 28 | 11 | 17 | null | null |
mrak/coreutils.hs | src/lib/Coreutils.hs | mit | versionOption :: String -> Version -> Parser (a -> a)
versionOption n v =
infoOption (n ++ " (Mrak coreutils) " ++ showVersion v)
( long "version"
<> help "output version information and exit"
) | 210 | versionOption :: String -> Version -> Parser (a -> a)
versionOption n v =
infoOption (n ++ " (Mrak coreutils) " ++ showVersion v)
( long "version"
<> help "output version information and exit"
) | 210 | versionOption n v =
infoOption (n ++ " (Mrak coreutils) " ++ showVersion v)
( long "version"
<> help "output version information and exit"
) | 156 | false | true | 0 | 9 | 50 | 67 | 32 | 35 | null | null |
robdockins/edison | edison-core/src/Data/Edison/Seq/BinaryRandList.hs | mit | filter = filterUsingFoldr | 25 | filter = filterUsingFoldr | 25 | filter = filterUsingFoldr | 25 | false | false | 1 | 5 | 2 | 10 | 3 | 7 | null | null |
romanb/amazonka | amazonka-emr/gen/Network/AWS/EMR/Types.hs | mpl-2.0 | -- | To launch the job flow in Amazon Virtual Private Cloud (Amazon VPC), set
-- this parameter to the identifier of the Amazon VPC subnet where you want the
-- job flow to launch. If you do not specify this value, the job flow is
-- launched in the normal Amazon Web Services cloud, outside of an Amazon VPC.
--
-- Amazon VPC currently does not support cluster compute quadruple extra large
-- (cc1.4xlarge) instances. Thus you cannot specify the cc1.4xlarge instance
-- type for nodes of a job flow launched in a Amazon VPC.
jficEc2SubnetId :: Lens' JobFlowInstancesConfig (Maybe Text)
jficEc2SubnetId = lens _jficEc2SubnetId (\s a -> s { _jficEc2SubnetId = a }) | 664 | jficEc2SubnetId :: Lens' JobFlowInstancesConfig (Maybe Text)
jficEc2SubnetId = lens _jficEc2SubnetId (\s a -> s { _jficEc2SubnetId = a }) | 137 | jficEc2SubnetId = lens _jficEc2SubnetId (\s a -> s { _jficEc2SubnetId = a }) | 76 | true | true | 0 | 9 | 114 | 53 | 32 | 21 | null | null |
ghcjs/jsaddle-dom | src/JSDOM/Generated/DocumentAndElementEventHandlers.hs | mit | -- | <https://developer.mozilla.org/en-US/docs/Web/API/DocumentAndElementEventHandlers.onbeforecut Mozilla DocumentAndElementEventHandlers.onbeforecut documentation>
beforeCut ::
(IsDocumentAndElementEventHandlers self, IsEventTarget self) =>
EventName self ClipboardEvent
beforeCut = unsafeEventName (toJSString "beforecut") | 348 | beforeCut ::
(IsDocumentAndElementEventHandlers self, IsEventTarget self) =>
EventName self ClipboardEvent
beforeCut = unsafeEventName (toJSString "beforecut") | 181 | beforeCut = unsafeEventName (toJSString "beforecut") | 52 | true | true | 0 | 7 | 43 | 41 | 21 | 20 | null | null |
frenetic-lang/netcore-1.0 | testsuite/Tests/Frenetic/Util.hs | bsd-3-clause | kCompleteQ :: Integral k => k -> [[Action]] -> (Topo.Graph, [([Node], Slice, Policy)])
kCompleteQ k queries = (topo, map mkCombined $ zip sliceNodes queries) where
k' = fromIntegral k
topo = TG.kComplete k'
length = k' `quot` 2
-- [0, 1, 2], [1, 2, 3], ..., [4, 5, 6], [5, 6, 0], [6, 0, 1]
sliceNodes = take k' . map (take length) . List.tails . cycle $ [1 .. k']
mkCombined (nodes, q) = (nodes, slice, policy) where
topo' = Topo.subgraph (Set.fromList nodes) topo
slice = internalSlice topo'
policy = simuFloodQuery topo' q
-- |Construct a k-complete graph and k slices on floor(k/2) nodes with two hosts
-- on each switch. Each slice is assigned the IP address of its lowest member.
-- Requires k queries. | 733 | kCompleteQ :: Integral k => k -> [[Action]] -> (Topo.Graph, [([Node], Slice, Policy)])
kCompleteQ k queries = (topo, map mkCombined $ zip sliceNodes queries) where
k' = fromIntegral k
topo = TG.kComplete k'
length = k' `quot` 2
-- [0, 1, 2], [1, 2, 3], ..., [4, 5, 6], [5, 6, 0], [6, 0, 1]
sliceNodes = take k' . map (take length) . List.tails . cycle $ [1 .. k']
mkCombined (nodes, q) = (nodes, slice, policy) where
topo' = Topo.subgraph (Set.fromList nodes) topo
slice = internalSlice topo'
policy = simuFloodQuery topo' q
-- |Construct a k-complete graph and k slices on floor(k/2) nodes with two hosts
-- on each switch. Each slice is assigned the IP address of its lowest member.
-- Requires k queries. | 733 | kCompleteQ k queries = (topo, map mkCombined $ zip sliceNodes queries) where
k' = fromIntegral k
topo = TG.kComplete k'
length = k' `quot` 2
-- [0, 1, 2], [1, 2, 3], ..., [4, 5, 6], [5, 6, 0], [6, 0, 1]
sliceNodes = take k' . map (take length) . List.tails . cycle $ [1 .. k']
mkCombined (nodes, q) = (nodes, slice, policy) where
topo' = Topo.subgraph (Set.fromList nodes) topo
slice = internalSlice topo'
policy = simuFloodQuery topo' q
-- |Construct a k-complete graph and k slices on floor(k/2) nodes with two hosts
-- on each switch. Each slice is assigned the IP address of its lowest member.
-- Requires k queries. | 646 | false | true | 0 | 13 | 152 | 217 | 119 | 98 | null | null |
itsbruce/hackerrank | func/misc/removeDuplidates.hs | unlicense | uniq [] = [] | 12 | uniq [] = [] | 12 | uniq [] = [] | 12 | false | false | 1 | 6 | 3 | 17 | 6 | 11 | null | null |
antitypical/Surface | src/Data/Name/Internal.hs | mit | showNumeral :: Integral i => String -> i -> String
showNumeral "" _ = "" | 72 | showNumeral :: Integral i => String -> i -> String
showNumeral "" _ = "" | 72 | showNumeral "" _ = "" | 21 | false | true | 0 | 7 | 14 | 31 | 15 | 16 | null | null |
eiji-a/aya | src/Aya/InitWorld.hs | bsd-3-clause | eey = eex <**> eyedir | 24 | eey = eex <**> eyedir | 24 | eey = eex <**> eyedir | 24 | false | false | 4 | 5 | 7 | 18 | 8 | 10 | null | null |
DavidAlphaFox/ghc | libraries/transformers/Control/Monad/Trans/State/Strict.hs | bsd-3-clause | -- | Uniform lifting of a @callCC@ operation to the new monad.
-- This version rolls back to the original state on entering the
-- continuation.
liftCallCC :: CallCC m (a,s) (b,s) -> CallCC (StateT s m) a b
liftCallCC callCC f = StateT $ \ s ->
callCC $ \ c ->
runStateT (f (\ a -> StateT $ \ _ -> c (a, s))) s | 318 | liftCallCC :: CallCC m (a,s) (b,s) -> CallCC (StateT s m) a b
liftCallCC callCC f = StateT $ \ s ->
callCC $ \ c ->
runStateT (f (\ a -> StateT $ \ _ -> c (a, s))) s | 173 | liftCallCC callCC f = StateT $ \ s ->
callCC $ \ c ->
runStateT (f (\ a -> StateT $ \ _ -> c (a, s))) s | 111 | true | true | 0 | 17 | 74 | 112 | 61 | 51 | null | null |
input-output-hk/cardano-sl | chain/src/Pos/Chain/Lrc/Fts.hs | apache-2.0 | -- | Sort values by their local slot indices, then strip the indices.
arrangeBySlots :: [(LocalSlotIndex, a)] -> [a]
arrangeBySlots = map snd . sortWith fst | 156 | arrangeBySlots :: [(LocalSlotIndex, a)] -> [a]
arrangeBySlots = map snd . sortWith fst | 86 | arrangeBySlots = map snd . sortWith fst | 39 | true | true | 0 | 8 | 25 | 44 | 22 | 22 | null | null |
mikehat/blaze-css | src/Text/Blaze/Css21/Value.hs | bsd-3-clause | to_string Ltr = "ltr" | 40 | to_string Ltr = "ltr" | 40 | to_string Ltr = "ltr" | 40 | false | false | 0 | 5 | 22 | 9 | 4 | 5 | null | null |
caneroj1/Crypto-hs | app/Challenges/Challenge6.hs | bsd-3-clause | removeLines :: BS.ByteString -> BS.ByteString
removeLines = BS.filter nonWSDelim
where newLineByte = fromIntegral $ ord '\n'
cReturn = fromIntegral $ ord '\r'
nonWSDelim x = x /= newLineByte && x /= cReturn | 227 | removeLines :: BS.ByteString -> BS.ByteString
removeLines = BS.filter nonWSDelim
where newLineByte = fromIntegral $ ord '\n'
cReturn = fromIntegral $ ord '\r'
nonWSDelim x = x /= newLineByte && x /= cReturn | 227 | removeLines = BS.filter nonWSDelim
where newLineByte = fromIntegral $ ord '\n'
cReturn = fromIntegral $ ord '\r'
nonWSDelim x = x /= newLineByte && x /= cReturn | 181 | false | true | 0 | 8 | 52 | 78 | 36 | 42 | null | null |
dorchard/gram_lang | frontend/src/Language/Granule/Syntax/Span.hs | bsd-3-clause | nullSpanNoFile :: Span
nullSpanNoFile = Span (0, 0) (0, 0) "" | 61 | nullSpanNoFile :: Span
nullSpanNoFile = Span (0, 0) (0, 0) "" | 61 | nullSpanNoFile = Span (0, 0) (0, 0) "" | 38 | false | true | 0 | 6 | 10 | 39 | 18 | 21 | null | null |
bus000/Dikunt | src/Types/Internal/Servername.hs | bsd-3-clause | getServerName :: Servername
-- ^ Servername to get servername from.
-> String
getServerName (Servername server) = server | 128 | getServerName :: Servername
-- ^ Servername to get servername from.
-> String
getServerName (Servername server) = server | 128 | getServerName (Servername server) = server | 42 | false | true | 0 | 9 | 24 | 31 | 14 | 17 | null | null |
rprospero/NeutronPipe | Neutron.hs | mit | advance :: (Epsilon a, Floating a, Num a) => a -> Neutron a -> Neutron a
-- ^ Progress forward along the z direction
advance d n = n {position = position n + (d / z dir) *^ dir}
where
dir = direction n | 211 | advance :: (Epsilon a, Floating a, Num a) => a -> Neutron a -> Neutron a
advance d n = n {position = position n + (d / z dir) *^ dir}
where
dir = direction n | 167 | advance d n = n {position = position n + (d / z dir) *^ dir}
where
dir = direction n | 94 | true | true | 0 | 11 | 54 | 91 | 46 | 45 | null | null |
rueshyna/gogol | gogol-sqladmin/gen/Network/Google/SQLAdmin/Types/Product.hs | mpl-2.0 | -- | Creates a value of 'BackupRun' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'brStatus'
--
-- * 'brStartTime'
--
-- * 'brKind'
--
-- * 'brError'
--
-- * 'brWindowStartTime'
--
-- * 'brSelfLink'
--
-- * 'brEndTime'
--
-- * 'brId'
--
-- * 'brType'
--
-- * 'brEnQueuedTime'
--
-- * 'brDescription'
--
-- * 'brInstance'
backupRun
:: BackupRun
backupRun =
BackupRun'
{ _brStatus = Nothing
, _brStartTime = Nothing
, _brKind = "sql#backupRun"
, _brError = Nothing
, _brWindowStartTime = Nothing
, _brSelfLink = Nothing
, _brEndTime = Nothing
, _brId = Nothing
, _brType = Nothing
, _brEnQueuedTime = Nothing
, _brDescription = Nothing
, _brInstance = Nothing
} | 806 | backupRun
:: BackupRun
backupRun =
BackupRun'
{ _brStatus = Nothing
, _brStartTime = Nothing
, _brKind = "sql#backupRun"
, _brError = Nothing
, _brWindowStartTime = Nothing
, _brSelfLink = Nothing
, _brEndTime = Nothing
, _brId = Nothing
, _brType = Nothing
, _brEnQueuedTime = Nothing
, _brDescription = Nothing
, _brInstance = Nothing
} | 398 | backupRun =
BackupRun'
{ _brStatus = Nothing
, _brStartTime = Nothing
, _brKind = "sql#backupRun"
, _brError = Nothing
, _brWindowStartTime = Nothing
, _brSelfLink = Nothing
, _brEndTime = Nothing
, _brId = Nothing
, _brType = Nothing
, _brEnQueuedTime = Nothing
, _brDescription = Nothing
, _brInstance = Nothing
} | 371 | true | true | 0 | 7 | 192 | 122 | 84 | 38 | null | null |
lexml/lexml-linker | src/main/haskell/LexML/Linker/Municipios.hs | gpl-2.0 | limpaChar 'ü' = 'u' | 19 | limpaChar 'ü' = 'u' | 19 | limpaChar 'ü' = 'u' | 19 | false | false | 0 | 5 | 3 | 9 | 4 | 5 | null | null |
ComputationWithBoundedResources/ara-inference | doc/tpdb_trs/Haskell/basic_haskell/divMod_1.hs | mit | primEqInt (Neg Zero) (Pos Zero) = MyTrue | 40 | primEqInt (Neg Zero) (Pos Zero) = MyTrue | 40 | primEqInt (Neg Zero) (Pos Zero) = MyTrue | 40 | false | false | 0 | 7 | 6 | 23 | 11 | 12 | null | null |
uuhan/Idris-dev | src/Idris/ASTUtils.hs | bsd-3-clause | opt_detaggable :: Field OptInfo Bool
opt_detaggable = Field detaggable (\v opt -> opt{ detaggable = v }) | 104 | opt_detaggable :: Field OptInfo Bool
opt_detaggable = Field detaggable (\v opt -> opt{ detaggable = v }) | 104 | opt_detaggable = Field detaggable (\v opt -> opt{ detaggable = v }) | 67 | false | true | 1 | 9 | 16 | 42 | 21 | 21 | null | null |
christiaanb/DepCore | Test.hs | bsd-2-clause | check' env (Pair l r) (VSigma ty s) = do
check env l (extract ty)
let s' = instantiate1Name l s
check env r s' | 116 | check' env (Pair l r) (VSigma ty s) = do
check env l (extract ty)
let s' = instantiate1Name l s
check env r s' | 116 | check' env (Pair l r) (VSigma ty s) = do
check env l (extract ty)
let s' = instantiate1Name l s
check env r s' | 116 | false | false | 0 | 10 | 30 | 70 | 31 | 39 | null | null |
jahaynes/smashy | src/Data/Smashy/Set.hs | mit | elem :: (CE.Serialize a) => HashSet a -> a -> IO Bool
elem hs k = elemBs hs . CE.encode $ k | 106 | elem :: (CE.Serialize a) => HashSet a -> a -> IO Bool
elem hs k = elemBs hs . CE.encode $ k | 91 | elem hs k = elemBs hs . CE.encode $ k | 37 | false | true | 0 | 9 | 36 | 59 | 27 | 32 | null | null |
sashabu/libcspm | src/CSPM/Syntax/Types.hs | bsd-3-clause | evaluateYields (TDatatype n) = TDatatype n | 42 | evaluateYields (TDatatype n) = TDatatype n | 42 | evaluateYields (TDatatype n) = TDatatype n | 42 | false | false | 0 | 7 | 5 | 18 | 8 | 10 | null | null |
hgeg/spawn | Main.hs | gpl-3.0 | runCommand "clean" opts = checkConfig opts cClean | 50 | runCommand "clean" opts = checkConfig opts cClean | 50 | runCommand "clean" opts = checkConfig opts cClean | 50 | false | false | 1 | 5 | 7 | 18 | 7 | 11 | null | null |
Ragnaroek/orwell | src/Orwell/Analyse.hs | gpl-3.0 | parseToFileChange :: [B.ByteString] -> FileChange
parseToFileChange [_,add,del,file] = FileChange (B.unpack file) (readGitLineChange add) (readGitLineChange del) | 161 | parseToFileChange :: [B.ByteString] -> FileChange
parseToFileChange [_,add,del,file] = FileChange (B.unpack file) (readGitLineChange add) (readGitLineChange del) | 161 | parseToFileChange [_,add,del,file] = FileChange (B.unpack file) (readGitLineChange add) (readGitLineChange del) | 111 | false | true | 0 | 8 | 14 | 62 | 33 | 29 | null | null |
uemurax/carettah | Config.hs | gpl-2.0 | curPage, nextPage, prevPage, topPage, endPage :: MonadIO m => m ()
curPage = do s <- queryCarettahState slides
let maxpage = length s - 1
updatePage (\p -> if p >= maxpage then maxpage else p) | 218 | curPage, nextPage, prevPage, topPage, endPage :: MonadIO m => m ()
curPage = do s <- queryCarettahState slides
let maxpage = length s - 1
updatePage (\p -> if p >= maxpage then maxpage else p) | 218 | curPage = do s <- queryCarettahState slides
let maxpage = length s - 1
updatePage (\p -> if p >= maxpage then maxpage else p) | 151 | false | true | 7 | 12 | 61 | 99 | 44 | 55 | null | null |
martindavid/code-sandbox | comp90048/assignments/project1/attempt2/HaskellTest.hs | mit | runTest fhandle l n limit verbose (Ratio tcase) = do
(n1,t,s,c) <- runTest fhandle l n limit verbose tcase
return (n1,t/c,1,1) | 134 | runTest fhandle l n limit verbose (Ratio tcase) = do
(n1,t,s,c) <- runTest fhandle l n limit verbose tcase
return (n1,t/c,1,1) | 134 | runTest fhandle l n limit verbose (Ratio tcase) = do
(n1,t,s,c) <- runTest fhandle l n limit verbose tcase
return (n1,t/c,1,1) | 134 | false | false | 0 | 9 | 28 | 80 | 41 | 39 | null | null |
mcmaniac/ghc | compiler/nativeGen/X86/CodeGen.hs | bsd-3-clause | condIntCode' is32Bit cond x y | isOperand is32Bit y = do
(x_reg, x_code) <- getNonClobberedReg x
(y_op, y_code) <- getOperand y
let
code = x_code `appOL` y_code `snocOL`
CMP (cmmTypeSize (cmmExprType x)) y_op (OpReg x_reg)
-- in
return (CondCode False cond code)
-- anything vs anything | 334 | condIntCode' is32Bit cond x y | isOperand is32Bit y = do
(x_reg, x_code) <- getNonClobberedReg x
(y_op, y_code) <- getOperand y
let
code = x_code `appOL` y_code `snocOL`
CMP (cmmTypeSize (cmmExprType x)) y_op (OpReg x_reg)
-- in
return (CondCode False cond code)
-- anything vs anything | 334 | condIntCode' is32Bit cond x y | isOperand is32Bit y = do
(x_reg, x_code) <- getNonClobberedReg x
(y_op, y_code) <- getOperand y
let
code = x_code `appOL` y_code `snocOL`
CMP (cmmTypeSize (cmmExprType x)) y_op (OpReg x_reg)
-- in
return (CondCode False cond code)
-- anything vs anything | 334 | false | false | 0 | 16 | 93 | 125 | 60 | 65 | null | null |
scott-fleischman/greek-grammar | haskell/unicode-script/unicode-script.hs | mit | letterCaseNames :: [(Text, Text)]
letterCaseNames =
[ ("CAPITAL", haskellUppercaseName)
, ("SMALL", "Lowercase")
] | 120 | letterCaseNames :: [(Text, Text)]
letterCaseNames =
[ ("CAPITAL", haskellUppercaseName)
, ("SMALL", "Lowercase")
] | 120 | letterCaseNames =
[ ("CAPITAL", haskellUppercaseName)
, ("SMALL", "Lowercase")
] | 86 | false | true | 0 | 6 | 18 | 38 | 24 | 14 | null | null |
timtylin/scholdoc-texmath | src/Text/TeXMath/Readers/TeX.hs | gpl-2.0 | circ 'c' = "ĉ" | 14 | circ 'c' = "ĉ" | 14 | circ 'c' = "ĉ" | 14 | false | false | 0 | 5 | 3 | 9 | 4 | 5 | null | null |
phischu/fragnix | tests/packages/scotty/Control.Concurrent.Lifted.hs | bsd-3-clause | -- | Generalized version of 'C.isCurrentThreadBound'.
isCurrentThreadBound :: MonadBase IO m => m Bool
isCurrentThreadBound = liftBase C.isCurrentThreadBound | 157 | isCurrentThreadBound :: MonadBase IO m => m Bool
isCurrentThreadBound = liftBase C.isCurrentThreadBound | 103 | isCurrentThreadBound = liftBase C.isCurrentThreadBound | 54 | true | true | 0 | 6 | 17 | 29 | 14 | 15 | null | null |
osa1/chsc | Utilities.hs | bsd-3-clause | -- NB: this render function is exported instead of the one from the library
render :: Doc -> String
render = renderStyle (style { lineLength = 120 }) | 149 | render :: Doc -> String
render = renderStyle (style { lineLength = 120 }) | 73 | render = renderStyle (style { lineLength = 120 }) | 49 | true | true | 0 | 8 | 27 | 37 | 18 | 19 | null | null |
Mahdi89/eTeak | src/Eval.hs | bsd-3-clause | evalPostCaseDeclGuard _ (r, node) = (r, node) | 45 | evalPostCaseDeclGuard _ (r, node) = (r, node) | 45 | evalPostCaseDeclGuard _ (r, node) = (r, node) | 45 | false | false | 0 | 6 | 6 | 23 | 13 | 10 | null | null |
GaloisInc/msf-haskell | src/MSF/Event.hs | bsd-3-clause | onLoot :: (HandlerRef -> Loot -> MSF s ()) -> MSF s HandlerRef
onLoot handler = do
k <- mkHandler handler
cont <- controlHandle
io (addLootHandler cont k)
-- | Disconnect a loot handler. | 196 | onLoot :: (HandlerRef -> Loot -> MSF s ()) -> MSF s HandlerRef
onLoot handler = do
k <- mkHandler handler
cont <- controlHandle
io (addLootHandler cont k)
-- | Disconnect a loot handler. | 196 | onLoot handler = do
k <- mkHandler handler
cont <- controlHandle
io (addLootHandler cont k)
-- | Disconnect a loot handler. | 133 | false | true | 0 | 10 | 43 | 73 | 34 | 39 | null | null |
phaazon/OpenGLRaw | src/Graphics/Rendering/OpenGL/Raw/Tokens.hs | bsd-3-clause | gl_MAX_RATIONAL_EVAL_ORDER_NV :: GLenum
gl_MAX_RATIONAL_EVAL_ORDER_NV = 0x86D7 | 78 | gl_MAX_RATIONAL_EVAL_ORDER_NV :: GLenum
gl_MAX_RATIONAL_EVAL_ORDER_NV = 0x86D7 | 78 | gl_MAX_RATIONAL_EVAL_ORDER_NV = 0x86D7 | 38 | false | true | 0 | 4 | 5 | 11 | 6 | 5 | null | null |
takano-akio/mapmaybe-benchmarks | MapMaybe.hs | cc0-1.0 | -- definition copied from Data.Maybe
mapMaybe :: (a -> Maybe b) -> [a] -> [b]
mapMaybe _ [] = [] | 96 | mapMaybe :: (a -> Maybe b) -> [a] -> [b]
mapMaybe _ [] = [] | 59 | mapMaybe _ [] = [] | 18 | true | true | 0 | 8 | 19 | 45 | 24 | 21 | null | null |
rahulmutt/ghcvm | compiler/Eta/Types/TyCon.hs | bsd-3-clause | -- | Is this 'TyCon' unlifted (i.e. cannot contain bottom)? Note that this can
-- only be true for primitive and unboxed-tuple 'TyCon's
isUnLiftedTyCon :: TyCon -> Bool
isUnLiftedTyCon (PrimTyCon {isUnLifted = is_unlifted}) = is_unlifted | 238 | isUnLiftedTyCon :: TyCon -> Bool
isUnLiftedTyCon (PrimTyCon {isUnLifted = is_unlifted}) = is_unlifted | 102 | isUnLiftedTyCon (PrimTyCon {isUnLifted = is_unlifted}) = is_unlifted | 69 | true | true | 0 | 8 | 35 | 37 | 19 | 18 | null | null |
NCrashed/Kaissa | source/Parser/GraphLoader.hs | gpl-3.0 | secondCell :: CSVParser String
secondCell = manyTill anyChar (char ',') | 71 | secondCell :: CSVParser String
secondCell = manyTill anyChar (char ',') | 71 | secondCell = manyTill anyChar (char ',') | 40 | false | true | 0 | 7 | 9 | 25 | 12 | 13 | null | null |
mrb/codeclimate-shellcheck | src/CC/ShellCheck/ShellScript.hs | gpl-3.0 | findShellScripts :: [FilePath] -> IO [FilePath]
findShellScripts paths = do
dotShFiles <- concat . fst <$> globDir patterns "."
allScripts <- filterM validateScript $! dotShFiles ++ otherFiles
return $ fmap clean allScripts
where
dirs :: [FilePath]; otherFiles :: [FilePath]
(dirs, otherFiles) = partition hasTrailingPathSeparator paths
clean :: String -> String
clean ('.':'/':x) = x
clean x = x
patterns :: [Pattern]
patterns = fmap (compile . (++ "**/*.sh")) dirs
validateScript :: FilePath -> IO Bool
validateScript x = doesFileExist x &&^ isShellScript x | 606 | findShellScripts :: [FilePath] -> IO [FilePath]
findShellScripts paths = do
dotShFiles <- concat . fst <$> globDir patterns "."
allScripts <- filterM validateScript $! dotShFiles ++ otherFiles
return $ fmap clean allScripts
where
dirs :: [FilePath]; otherFiles :: [FilePath]
(dirs, otherFiles) = partition hasTrailingPathSeparator paths
clean :: String -> String
clean ('.':'/':x) = x
clean x = x
patterns :: [Pattern]
patterns = fmap (compile . (++ "**/*.sh")) dirs
validateScript :: FilePath -> IO Bool
validateScript x = doesFileExist x &&^ isShellScript x | 606 | findShellScripts paths = do
dotShFiles <- concat . fst <$> globDir patterns "."
allScripts <- filterM validateScript $! dotShFiles ++ otherFiles
return $ fmap clean allScripts
where
dirs :: [FilePath]; otherFiles :: [FilePath]
(dirs, otherFiles) = partition hasTrailingPathSeparator paths
clean :: String -> String
clean ('.':'/':x) = x
clean x = x
patterns :: [Pattern]
patterns = fmap (compile . (++ "**/*.sh")) dirs
validateScript :: FilePath -> IO Bool
validateScript x = doesFileExist x &&^ isShellScript x | 558 | false | true | 13 | 10 | 129 | 211 | 107 | 104 | null | null |
lfritz/python-type-inference | python-type-inference/src/Language/Python/TypeInference/CFG/ToFragment.hs | bsd-3-clause | toParameter scope (AST.UnPackTuple _ _ _) =
throwError $ CFGError "tuple unpack parameters don't exist in Python 3" | 119 | toParameter scope (AST.UnPackTuple _ _ _) =
throwError $ CFGError "tuple unpack parameters don't exist in Python 3" | 119 | toParameter scope (AST.UnPackTuple _ _ _) =
throwError $ CFGError "tuple unpack parameters don't exist in Python 3" | 119 | false | false | 0 | 8 | 21 | 30 | 14 | 16 | null | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.