code stringlengths 5 1.03M | repo_name stringlengths 5 90 | path stringlengths 4 158 | license stringclasses 15
values | size int64 5 1.03M | n_ast_errors int64 0 53.9k | ast_max_depth int64 2 4.17k | n_whitespaces int64 0 365k | n_ast_nodes int64 3 317k | n_ast_terminals int64 1 171k | n_ast_nonterminals int64 1 146k | loc int64 -1 37.3k | cycloplexity int64 -1 1.31k |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | rueshyna/gogol | gogol-dfareporting/gen/Network/Google/Resource/DFAReporting/AdvertiserGroups/Get.hs | mpl-2.0 | 3,365 | 0 | 14 | 779 | 421 | 249 | 172 | 65 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | rueshyna/gogol | gogol-compute/gen/Network/Google/Resource/Compute/Licenses/Get.hs | mpl-2.0 | 3,238 | 0 | 15 | 782 | 393 | 237 | 156 | 64 | 1 |
{-# LANGUAGE InstanceSigs #-}
module MaybeT where
newtype MaybeT m a =
MaybeT { runMaybeT :: m (Maybe a) }
-- instance (Functor f, Functor g) =>
-- Functor (Compose f g) where
-- fmap f (Compose fga) =
-- Compose $ (fmap . fmap) f fga
instance (Functor m) => Functor (MaybeT m) whe... | dmvianna/haskellbook | src/Ch26-MaybeT.hs | unlicense | 1,899 | 0 | 14 | 592 | 853 | 425 | 428 | 56 | 2 |
{-
Copyright 2020 The CodeWorld Authors. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicab... | google/codeworld | codeworld-compiler/test/testcases/differentModuleName/source.hs | apache-2.0 | 678 | 0 | 6 | 124 | 24 | 15 | 9 | 2 | 1 |
{-# LANGUAGE BangPatterns, DeriveDataTypeable, DeriveGeneric, FlexibleInstances, MultiParamTypeClasses #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
module Network.Riak.Protocol.PingRequest (PingRequest(..)) where
import Prelude ((+), (/))
import qualified Prelude as Prelude'
import qualified Data.Typeable as Prelu... | k-bx/riak-haskell-client | protobuf/src/Network/Riak/Protocol/PingRequest.hs | apache-2.0 | 2,631 | 1 | 16 | 524 | 569 | 301 | 268 | 55 | 0 |
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE TemplateHaskell #-}
module Database.SqlServer.Definition.FullTextCatalog
(
FullTextCatalog
) where
import Database.SqlServer.Definition.Identifier
import Database.SqlServer.Definition.Entity
import Test.QuickCheck
import Text.PrettyPrint
import Data.... | SuperDrew/sql-server-gen | src/Database/SqlServer/Definition/FullTextCatalog.hs | bsd-2-clause | 1,202 | 0 | 11 | 254 | 242 | 129 | 113 | 29 | 1 |
{-# LANGUAGE FlexibleInstances, MultiParamTypeClasses, FlexibleContexts #-}
--------------------------------------------------------------------------------
-- This code is generated by util/genC.hs.
--------------------------------------------------------------------------------
module Graphics.UI.GLFW.C where
--... | bsl/GLFW-b | Graphics/UI/GLFW/C.hs | bsd-2-clause | 27,656 | 0 | 10 | 5,169 | 6,622 | 3,190 | 3,432 | 623 | 0 |
{-# LANGUAGE UndecidableInstances #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE ConstraintKinds #-}
{-# LANGUAGE TypeFamilies #-}
module Futhark.Analysis.SymbolTable
( SymbolTable (bindings)
, empty
, fromScope
-- * Entries
, Entry
, deepen
, bindingDepth
, valueRange
, loopVariable
, entryBi... | mrakgr/futhark | src/Futhark/Analysis/SymbolTable.hs | bsd-3-clause | 21,977 | 0 | 20 | 6,090 | 5,744 | 2,944 | 2,800 | 457 | 12 |
module Ntha.Type.Type where
import Ntha.State
import Ntha.Z3.Assertion
import Ntha.Z3.Class
import Ntha.Z3.Logic
import Z3.Monad
import Control.Monad (foldM, liftM)
import System.IO.Unsafe (unsafePerformIO)
import Data.IORef
import ... | zjhmale/Ntha | src/Ntha/Type/Type.hs | bsd-3-clause | 9,167 | 0 | 18 | 2,704 | 3,512 | 1,718 | 1,794 | -1 | -1 |
module Main where
import Web.Scotty
import Data.Monoid (mconcat)
import System.Environment (getEnv)
import Data.Time.Clock (getCurrentTime)
import Data.Aeson hiding (json)
import Data.Aeson.Types
import Data.Text (Text)
import Control.Concurrent.MVar
import System.Exit
import Control.Monad.IO.Class
import System.Posix... | AKurilin/useless | Main.hs | bsd-3-clause | 1,182 | 0 | 18 | 316 | 280 | 147 | 133 | 27 | 2 |
-- !!! Testing static, dynamic and wrapped import of trig function
-- Imports kept minimal to avoid pulling in Storable and other
-- things which use even more ffi.
import System.IO.Unsafe( unsafePerformIO )
import Foreign.Ptr( FunPtr, freeHaskellFunPtr )
tests = do
putStrLn "\nTesting sin==mysin (should return lo... | FranklinChen/Hugs | tests/ffi/Sin.hs | bsd-3-clause | 1,422 | 0 | 13 | 244 | 414 | 208 | 206 | 22 | 1 |
{-# LANGUAGE TupleSections #-}
{-# LANGUAGE CPP #-}
{-# LANGUAGE RecordWildCards #-}
--
-- GHC plugin to generate srcloc info.
--
-- (c) 2014 Galois, Inc.
--
module Ivory.Tower.SrcLoc.Plugin (plugin) where
import DynamicLoading
import GhcPlugins
import GHC.Plugins.SrcSpan
plugin :: Plugin
plugi... | GaloisInc/tower | tower/src/Ivory/Tower/SrcLoc/Plugin.hs | bsd-3-clause | 2,780 | 0 | 12 | 654 | 723 | 362 | 361 | 55 | 1 |
{- arch-tag: Test runner
Copyright (C) 2004-2011 John Goerzen <jgoerzen@complete.org>
License: BSD3
-}
module Main where
import Test.HUnit
import Tests
main = runTestTT tests
| jgoerzen/hslogger | testsrc/runtests.hs | bsd-3-clause | 180 | 0 | 5 | 29 | 21 | 13 | 8 | 4 | 1 |
-- | Unsafe code posted <https://www.reddit.com/r/haskell/comments/3vlb8v/reading_data_problems/ on Reddit> and turned into safe code using NonEmpty.
module NonEmptyListExample where
-- <http://hackage.haskell.org/package/split split> utility library
import qualified Data.List.Split as Split
import qualified Data.Li... | FranklinChen/twenty-four-days2015-of-hackage | src/NonEmptyListExample.hs | bsd-3-clause | 2,329 | 0 | 15 | 459 | 657 | 361 | 296 | 35 | 2 |
{-# LANGUAGE TypeFamilies, OverloadedStrings #-}
module DeepBanana.Layer.CUDA.CuRAND (
splitGenerator
, uniform
, normal
, logNormal
, dropout
) where
import Debug.Trace
import Foreign.Marshal
import System.IO.Unsafe
import Unsafe.Coerce
import DeepBanana.Device
import qualified DeepBanana.Device.Monad a... | alexisVallet/deep-banana | src/DeepBanana/Layer/CUDA/CuRAND.hs | bsd-3-clause | 4,482 | 0 | 31 | 1,087 | 1,611 | 793 | 818 | -1 | -1 |
-- |
-- Module: Data.Aeson
-- Copyright: (c) 2011-2016 Bryan O'Sullivan
-- (c) 2011 MailRank, Inc.
-- License: BSD3
-- Maintainer: Bryan O'Sullivan <bos@serpentine.com>
-- Stability: experimental
-- Portability: portable
--
-- Types and functions for working efficiently with JSON data.
--
-- ... | sol/aeson | Data/Aeson.hs | bsd-3-clause | 14,742 | 0 | 8 | 2,987 | 1,116 | 810 | 306 | 118 | 1 |
{-# LANGUAGE OverlappingInstances, UndecidableInstances #-}
module HJScript.Objects.JQuery where
import HJScript.Lang
import HJScript.DOM.Window
import HJScript.DOM.ElementNode
data JQuery = JQuery deriving Show
instance IsClass JQuery
-- | Constructors for Date
instance HasConstructor JQuery JString String
jQuery... | seereason/HJScript | src/HJScript/Objects/JQuery.hs | bsd-3-clause | 1,848 | 0 | 10 | 371 | 642 | 314 | 328 | -1 | -1 |
{-# LANGUAGE OverloadedStrings, TemplateHaskell #-}
module StarDict.Format.Ifo(parse,Opt(..)) where
import Data.Text (Text)
import Data.Set (Set)
import qualified Data.Set as Set
import Data.Maybe (fromJust)
import Control.Applicative
import Data.Attoparsec.Text hiding (parse)
import Prelude hiding (unlines)
import Sta... | polachok/hdict | src/StarDict/Format/Ifo.hs | bsd-3-clause | 1,824 | 2 | 17 | 506 | 577 | 333 | 244 | 55 | 2 |
{-# OPTIONS_GHC -fno-warn-orphans #-}
module Tree.DeepSeq where
import Tree.Types
import Control.DeepSeq
instance NFData Tree where
rnf Leaf = ()
rnf (Fork a b) = rnf a `seq` rnf b `seq` ()
| thoughtpolice/binary-serialise-cbor | bench/Tree/DeepSeq.hs | bsd-3-clause | 198 | 0 | 8 | 39 | 71 | 39 | 32 | 7 | 0 |
module Main ( main ) where
import Data.Map ( Map )
import Data.Monoid
import Data.Set ( Set )
import System.Environment ( getArgs, withArgs )
import System.FilePath
import Test.HUnit ( assertEqual )
import LLVM.Analysis
import LLVM.Analysis.AccessPath
import LLVM.Analysis.CallGraph
import LLVM.Analysis.CallGraphSCCTr... | travitch/foreign-inference | tests/SAPTests.hs | bsd-3-clause | 1,989 | 0 | 13 | 424 | 451 | 253 | 198 | 47 | 3 |
module ML.Common where
import Foreign.C
toBool :: CUChar -> Bool
toBool = (/= 0)
| jxv/ml-hs | src/ML/Common.hs | bsd-3-clause | 83 | 0 | 5 | 16 | 29 | 18 | 11 | 4 | 1 |
{-# LANGUAGE CPP #-}
module TcSimplify(
simplifyInfer, InferMode(..),
growThetaTyVars,
simplifyAmbiguityCheck,
simplifyDefault,
simplifyTop, simplifyInteractive, solveEqualities,
simplifyWantedsTcM,
tcCheckSatisfiability,
-- For Rules we need these
solveW... | mettekou/ghc | compiler/typecheck/TcSimplify.hs | bsd-3-clause | 90,897 | 2 | 20 | 25,733 | 9,527 | 4,968 | 4,559 | 781 | 5 |
import Control.Monad.Trans.Free hiding (Pure)
import Data.Maybe (fromMaybe)
import Data.IORef
import Options.Applicative
import Pipes
import Pipes.Internal
import Data.Time.Clock
import Common (Step(..), search, parameters)
options :: Parser (String, Maybe Double, Int)
options = (,,)
<$> strOption (mconcat
... | Gabriel439/suns-cmd | Bench.hs | bsd-3-clause | 2,287 | 0 | 15 | 721 | 785 | 398 | 387 | 66 | 4 |
{-# LANGUAGE OverloadedStrings #-}
module ZMotor where
import System.Hardware.Serialport
import Control.Monad (void)
import qualified Data.ByteString.Char8 as BS
newtype ZMotor = ZMotor SerialPort
open :: FilePath -> IO ZMotor
open fname = do
dev <- openSerial fname settings
send dev "rate 1000\n"
retu... | bgamari/navigate | ZMotor.hs | bsd-3-clause | 547 | 0 | 11 | 121 | 178 | 91 | 87 | 17 | 1 |
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE Trustworthy #-}
module Network.Tox.DHT.KBucketsSpec where
import Test.Hspec
import Test.QuickCheck
import Control.Monad (unless, when)
impor... | iphydf/hs-toxcore | test/Network/Tox/DHT/KBucketsSpec.hs | gpl-3.0 | 5,327 | 0 | 21 | 1,501 | 1,295 | 681 | 614 | 108 | 4 |
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE helpset PUBLIC "-//Sun Microsystems Inc.//DTD JavaHelp HelpSet Version 2.0//EN" "http://java.sun.com/products/javahelp/helpset_2_0.dtd">
<helpset version="2.0" xml:lang="tr-TR">
<title>WebSockets | ZAP Uzantısı</title>
<maps>
<homeID>top</homeID>
<mapref l... | veggiespam/zap-extensions | addOns/websocket/src/main/javahelp/org/zaproxy/zap/extension/websocket/resources/help_tr_TR/helpset_tr_TR.hs | apache-2.0 | 985 | 80 | 66 | 160 | 427 | 215 | 212 | -1 | -1 |
-- |
-- Module : Statistics.Matrix.Algorithms
-- Copyright : 2014 Bryan O'Sullivan
-- License : BSD3
--
-- Useful matrix functions.
module Statistics.Matrix.Algorithms
(
qr
) where
import Control.Applicative ((<$>), (<*>))
import Control.Monad.ST (ST, runST)
import Prelude hiding (sum, replicate)
i... | fpco/statistics | Statistics/Matrix/Algorithms.hs | bsd-2-clause | 1,299 | 0 | 23 | 304 | 502 | 265 | 237 | 29 | 1 |
{-# LANGUAGE CPP #-}
-- -----------------------------------------------------------------------------
--
-- (c) The University of Glasgow 1994-2004
--
-- -----------------------------------------------------------------------------
module PPC.Regs (
-- squeeze functions
virtualRegSqueeze,
real... | vikraman/ghc | compiler/nativeGen/PPC/Regs.hs | bsd-3-clause | 10,028 | 0 | 15 | 3,174 | 2,493 | 1,296 | 1,197 | 226 | 13 |
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE BangPatterns #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE KindSignatures #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE OverloadedStrings #-}
-- | Reading from external processes.
module System.P... | AndreasPK/stack | src/System/Process/Read.hs | bsd-3-clause | 18,635 | 0 | 30 | 5,523 | 4,037 | 2,150 | 1,887 | 351 | 8 |
{-# LANGUAGE OverloadedStrings #-}
module LogWithSpec ( logWithSpec ) where
import TestInit
import Prelude hiding (FilePath)
import Control.Concurrent (newEmptyMVar, takeMVar, putMVar)
import Data.Text (Text)
default (Text)
logWithSpec :: Spec
logWithSpec =
describe "withOutputWriter" $
it "calls writer functi... | adinapoli/Shelly.hs | test/src/LogWithSpec.hs | bsd-3-clause | 588 | 0 | 12 | 111 | 133 | 71 | 62 | 16 | 1 |
module Tuura.Formula (Formulae, Input, Output, Equation,
parseFormula, getFormulae, loadFormulae, unloadFormulae
) where
import Foreign.C.String
newtype Input = Input String
newtype Output = Output String
newtype Equation = Equation String
data Formulae = Formulae
... | allegroCoder/scenco-1 | src/Tuura/Formula.hs | bsd-3-clause | 3,887 | 0 | 10 | 768 | 1,159 | 589 | 570 | 104 | 1 |
{-# LANGUAGE Trustworthy #-}
{-# OPTIONS -fno-warn-unused-imports #-}
#include "HsConfigure.h"
-- #hide
module Data.Time.Clock.Scale
(
-- * Universal Time
-- | Time as measured by the earth.
UniversalTime(..),
-- * Absolute intervals
DiffTime,
secondsToDiffTime, picosecondsToDiffTime
) where
import Contr... | jwiegley/ghc-release | libraries/time/Data/Time/Clock/Scale.hs | gpl-3.0 | 3,728 | 4 | 10 | 639 | 903 | 473 | 430 | 54 | 1 |
module Core
( ns )
where
import System.IO (hFlush, stdout)
import Control.Exception (catch)
import Control.Monad.Trans (liftIO)
import qualified Data.Map as Map
import Data.Time.Clock.POSIX (getPOSIXTime)
import Data.IORef (IORef, newIORef, readIORef, writeIORef)
import Readline (readline)
import Reader (read_str)
im... | jwalsh/mal | haskell/Core.hs | mpl-2.0 | 9,477 | 0 | 14 | 2,249 | 4,170 | 2,153 | 2,017 | 234 | 3 |
{-
(c) The University of Glasgow 2006
(c) The AQUA Project, Glasgow University, 1994-1998
Desugaring foreign calls
-}
{-# LANGUAGE CPP #-}
module Language.Haskell.Liquid.Desugar710.DsCCall
( dsCCall
, mkFCall
, unboxArg
, boxResult
, resultWrapper
) where
-- #include ... | spinda/liquidhaskell | src/Language/Haskell/Liquid/Desugar710/DsCCall.hs | bsd-3-clause | 14,609 | 0 | 19 | 4,611 | 2,842 | 1,475 | 1,367 | 224 | 3 |
--
-- Copyright (c) 2012 Citrix Systems, Inc.
--
-- This program is free software; you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation; either version 2 of the License, or
-- (at your option) any later version.
--
-- This progra... | jean-edouard/manager | disksync/VhdSync.hs | gpl-2.0 | 27,843 | 4 | 25 | 9,030 | 6,033 | 3,141 | 2,892 | -1 | -1 |
{-# LANGUAGE OverloadedStrings #-}
module Yi.Config.Default.Emacs (configureEmacs) where
import Lens.Micro.Platform ((%=), (.=), (.~))
import Yi.Buffer.Misc (identA, directoryContentA)
import Yi.Config.Misc (ScrollStyle (..))
import Yi.Editor (buffersA, newBufferE)... | yi-editor/yi | yi-keymap-emacs/src/Yi/Config/Default/Emacs.hs | gpl-2.0 | 2,096 | 0 | 12 | 573 | 524 | 300 | 224 | 43 | 2 |
<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE helpset PUBLIC "-//Sun Microsystems Inc.//DTD JavaHelp HelpSet Version 2.0//EN" "http://java.sun.com/products/javahelp/helpset_2_0.dtd">
<helpset version="2.0" xml:lang="sq-AL">
<title>JSON View</title>
<maps>
<homeID>jsonview</homeID>
<mapref location="map... | kingthorin/zap-extensions | addOns/jsonview/src/main/javahelp/help_sq_AL/helpset_sq_AL.hs | apache-2.0 | 959 | 77 | 66 | 156 | 407 | 206 | 201 | -1 | -1 |
{-# OPTIONS -fglasgow-exts #-}
-- This should work, because the type sig and the type
-- in the pattern match exactly
module Foo where
foo :: (forall a. a -> b) -> b
foo (f :: forall a. a -> b) = f undefined :: b
| hvr/jhc | regress/tests/1_typecheck/2_pass/ghc/uncat/tc198.hs | mit | 216 | 0 | 9 | 49 | 58 | 34 | 24 | -1 | -1 |
{-# LANGUAGE RankNTypes, PolyKinds, DataKinds, GADTs #-}
module T15743e where
import Data.Proxy
import Data.Kind
-- NO CUSK.
data T k (a :: k) (b :: Proxy k2) f c :: forall k3. Proxy k3 -> forall (k4 :: k5). Proxy k4 -> Type where
MkT :: f c -> T k a b f c d e
-- Want:
-- T :: forall {k3} {k7} {k6} (k2 :: k3) (k5... | sdiehl/ghc | testsuite/tests/dependent/should_compile/T15743e.hs | bsd-3-clause | 658 | 0 | 9 | 175 | 214 | 129 | 85 | -1 | -1 |
module HsModuleMaps where
import HsModule
import MUtils
import HsIdent(seqHsIdent)
instance Functor (HsImportDeclI m) where
fmap f (HsImportDecl s m q as optspec) =
HsImportDecl s m q as (fmap (apSnd (map (fmap f))) optspec)
instance Functor (HsExportSpecI m) where
fmap f e =
case e of
EntE espec ->... | forste/haReFork | tools/base/AST/HsModuleMaps.hs | bsd-3-clause | 1,631 | 0 | 14 | 379 | 708 | 343 | 365 | 41 | 4 |
-----------------------------------------------------------------------------
-- |
-- Module : Haddock.Backends.Html.Names
-- Copyright : (c) Simon Marlow 2003-2006,
-- David Waern 2006-2009,
-- Mark Lentczner 2010
-- License : BSD-like
--
-- Maintainer : haddo... | jwiegley/ghc-release | utils/haddock/src/Haddock/Backends/Xhtml/Names.hs | gpl-3.0 | 5,980 | 0 | 13 | 1,387 | 1,559 | 800 | 759 | 107 | 10 |
module T12042a (module T12042a, module T12042) where
import {-# SOURCE #-} T12042
type U = S
| olsner/ghc | testsuite/tests/typecheck/should_fail/T12042a.hs | bsd-3-clause | 93 | 0 | 4 | 16 | 24 | 17 | 7 | 3 | 0 |
module A where
import B
| forked-upstream-packages-for-ghcjs/ghc | testsuite/tests/ghci/prog009/A1.hs | bsd-3-clause | 25 | 0 | 3 | 6 | 7 | 5 | 2 | 2 | 0 |
import Control.Monad
import Data.List
readNumbers :: String -> [Int]
readNumbers = map read . words
-- the task is to find minimum of all a's and minimum of all b's and multiply the two
findMins = foldl' (\[min_a, min_b] [a, b] -> [min min_a a, min min_b b]) [maxBound :: Int, maxBound :: Int]
multiply [a, b] = a * ... | mgrebenets/hackerrank | alg/geometry/rectangular-game.hs | mit | 507 | 0 | 12 | 113 | 193 | 101 | 92 | 13 | 1 |
{- for ch04 DMA
- by Yue Wang
- -}
nextLexicalBitStirng :: (Num a, Eq a) => [a] -> [a]
nextLexicalBitStirng [] = []
nextLexicalBitStirng xs = if head rxs==0 then reverse(1:(tail rxs)) else nextLexicalBitStirng(take (length xs - 1) xs) ++ [0]
where rxs = reverse xs
| Mooophy/DMA | ch04/nextLexicalBitStirng.hs | mit | 316 | 0 | 12 | 98 | 121 | 63 | 58 | 4 | 2 |
module Y2016.M09.D15.Solution where
import Control.Monad (guard)
import Data.Array
import Data.Map (Map)
import qualified Data.Map as Map
import Data.Set (Set)
import qualified Data.Set as Set
-- the below import is available from the 1HaskellADay git repository
import Control.List (takeout)
import Data.Matrix
{--
... | geophf/1HaskellADay | exercises/HAD/Y2016/M09/D15/Solution.hs | mit | 4,409 | 0 | 20 | 992 | 1,472 | 815 | 657 | 74 | 2 |
{-# LANGUAGE PatternSynonyms, ForeignFunctionInterface, JavaScriptFFI #-}
module GHCJS.DOM.JSFFI.Generated.WebKitCSSTransformValue
(js__get, _get, pattern CSS_TRANSLATE, pattern CSS_TRANSLATEX,
pattern CSS_TRANSLATEY, pattern CSS_ROTATE, pattern CSS_SCALE,
pattern CSS_SCALEX, pattern CSS_SCALEY, ... | manyoo/ghcjs-dom | ghcjs-dom-jsffi/src/GHCJS/DOM/JSFFI/Generated/WebKitCSSTransformValue.hs | mit | 2,939 | 14 | 10 | 424 | 726 | 426 | 300 | 59 | 1 |
nwd :: Integer -> Integer -> Integer
nwd 0 y = abs y
nwd x 0 = abs x
nwd x y
| x < 0 = nwd (abs x) y
| y < 0 = nwd x (abs y)
| x == y = x
| x > y = if (x - y) > y then nwd (x - y) y else nwd y (x - y)
| x < y = nwd y x | RAFIRAF/HASKELL | nwdEu3.hs | mit | 228 | 0 | 9 | 86 | 182 | 87 | 95 | 9 | 2 |
import HUnit
| chris-wood/ccnx-pktgen | testsuite/tests/parser-tests.hs | mit | 15 | 0 | 3 | 4 | 4 | 2 | 2 | 1 | 0 |
-- | Blending stuff.
--
-- <https://www.opengl.org/wiki/Blending>
--
module Graphics.Caramia.Blend
(
-- * Data types
BlendSpec(..)
, BlendEquation(..)
, BlendFunc(..)
-- * Pre-defined blending specs
, preMultipliedAlpha
, nopBlend )
where
--import Graphics.Caramia.Prelude
import ... | Noeda/caramia | src/Graphics/Caramia/Blend.hs | mit | 1,011 | 0 | 7 | 230 | 184 | 121 | 63 | 27 | 1 |
-- | Utilities for controlling bluetooth.
--
-- Note that these only work when there is a tmux pane called btctl
-- that is running bluetoothctl. The approach using tmux comes from
-- https://serverfault.com/a/547144
--
-- TODO: Make it so that this starts the pane if it isn't already
-- running.
module Bluetooth where... | mgsloan/compconfig | env/src/Bluetooth.hs | mit | 1,116 | 0 | 13 | 212 | 320 | 169 | 151 | 19 | 2 |
module OCR (convert) where
convert :: String -> String
convert xs = error "You need to implement this function."
| exercism/xhaskell | exercises/practice/ocr-numbers/src/OCR.hs | mit | 114 | 0 | 5 | 20 | 29 | 16 | 13 | 3 | 1 |
{-# LANGUAGE OverloadedStrings #-}
module CoinApi.Types.Rate where
import CoinApi.Types.Internal
data Rate = Rate { time :: !UTCTime
, asset_id_base :: !Text
, asset_id_quote :: !Text
, rate :: !Scientific }
deriving (Show, Eq)
instance FromJ... | coinapi/coinapi-sdk | data-api/haskell-rest/CoinApi/Types/Rate.hs | mit | 639 | 0 | 17 | 303 | 127 | 70 | 57 | 22 | 0 |
-- Quasicrystals demo.
--
-- Based on code from:
-- http://mainisusuallyafunction.blogspot.com/2011/10/quasicrystals-as-sums-of-waves-in-plane.html
--
import Graphics.Gloss.Raster.Field
import System.Environment
import System.Exit
import Data.Char
-- Main ---------------------------------------------------------... | gscalzo/HaskellTheHardWay | gloss-try/gloss-master/gloss-examples/raster/Crystal/Main.hs | mit | 5,282 | 0 | 15 | 1,924 | 1,176 | 609 | 567 | -1 | -1 |
{-# LANGUAGE OverloadedStrings, NamedFieldPuns, Rank2Types #-}
module Client (clientMain) where
import Types
import Haste.App
-- TODO:
-- * persistence
-- * routing
import Control.Applicative
import Control.Monad
import Prelude hiding (div)
import Haste.Foreign
import Haste.Prim
import Lens.Family2
import React
i... | jeremyjh/react-haste-app | src/Client.hs | mit | 7,352 | 0 | 22 | 1,891 | 2,069 | 1,034 | 1,035 | -1 | -1 |
{-# htermination (splitAt :: MyInt -> (List a) -> Tup2 (List a) (List a)) #-}
import qualified Prelude
data MyBool = MyTrue | MyFalse
data List a = Cons a (List a) | Nil
data Tup2 a b = Tup2 a b ;
data MyInt = Pos Nat | Neg Nat ;
data Nat = Succ Nat | Zero ;
data Ordering = LT | EQ | GT ;
primMinusNat :... | ComputationWithBoundedResources/ara-inference | doc/tpdb_trs/Haskell/basic_haskell/splitAt_1.hs | mit | 2,995 | 0 | 11 | 635 | 1,384 | 725 | 659 | 73 | 1 |
{-# htermination properFraction :: Float -> (Int,Float) #-}
| ComputationWithBoundedResources/ara-inference | doc/tpdb_trs/Haskell/full_haskell/Prelude_properFraction_2.hs | mit | 60 | 0 | 2 | 8 | 3 | 2 | 1 | 1 | 0 |
module ProjectEuler.Problem30
( problem
) where
import Data.Char
import ProjectEuler.Types
problem :: Problem
problem = pureProblem 30 Solved result
testAllow :: Int -> Bool
testAllow x = sum (map ((^(5 :: Int)) . digitToInt) (show x)) == x
result :: Int
result = sum (filter testAllow [10.. (9^(5 :: Int) * 5)]... | Javran/Project-Euler | src/ProjectEuler/Problem30.hs | mit | 323 | 0 | 12 | 62 | 136 | 76 | 60 | 10 | 1 |
{-| This script builds any version of the Elm Platform from source.
Before you use it, make sure you have the Haskell Platform with a recent
version of cabal.
To install a released version of Elm, you will run something like this:
runhaskell BuildFromSource.hs 0.16
Before you do that, in some directory of your c... | ryansb/elm-dev-containers | BuildFromSource.hs | mit | 5,548 | 0 | 16 | 1,682 | 964 | 524 | 440 | 98 | 2 |
module GhostLang.ParserProps
( ghostModuleDefP
, moduleDeclP
, importDeclP
, valueRefP
, timeUnitRefP
, payloadRefP
, paceRefP
, methodP
, contentP
, intrinsicCommandP
, patternP
, procedureP
, operationP
) where
import GhostLang.Compiler.Grammar ( ghostModuleDe... | kosmoskatten/ghost-lang | ghost-lang/test/GhostLang/ParserProps.hs | mit | 3,088 | 2 | 8 | 1,172 | 506 | 290 | 216 | 74 | 2 |
module Handler.ListMeals where
import Import
import Handler.Common
import Handler.Cache
getListMealsR :: Handler Html
getListMealsR = do
-- ip <- getIp
-- putStrLn $ pack "Client list request from IP: " ++ ip
menuList <- lift $ getData
canVoteList <- filterM (\menuItem -> do
... | sramekj/lunchvote | Handler/ListMeals.hs | mit | 611 | 0 | 16 | 217 | 133 | 67 | 66 | -1 | -1 |
module Chess.Internal.Notation (parseMove, parseCoordinateNotation, parseCoordinateStringWithPromotion) where
import Chess.Internal.Move
import Chess.Internal.Board
import Chess.Internal.Piece
import Data.List
import Data.Char
import Data.Attoparsec.Text
import qualified Data.Text as T
import Control.Applicative
pars... | nablaa/hchesslib | src/Chess/Internal/Notation.hs | gpl-2.0 | 4,440 | 0 | 11 | 1,260 | 1,188 | 605 | 583 | 69 | 2 |
{- |
Module : $Header$
Description : abstract syntax of CASL architectural specifications
Copyright : (c) Klaus Luettich, Uni Bremen 2002-2006
License : GPLv2 or higher, see LICENSE.txt
Maintainer : till@informatik.uni-bremen.de
Stability : provisional
Portability : non-portable(imports Syntax.AS_S... | nevrenato/Hets_Fork | Syntax/AS_Architecture.hs | gpl-2.0 | 6,833 | 0 | 11 | 2,307 | 1,702 | 853 | 849 | 124 | 0 |
{-# LANGUAGE MultiParamTypeClasses #-}
module RSA.Quiz
( make
, Param (..)
, Config (..)
)
where
-- $Id$
import RSA.Param
import RSA.Break hiding ( make )
import RSA.Break.Data
import Faktor.Prim
import Faktor.Certify ( powmod )
import Autolib.Util.Zufall
-- import Autolib.Util.Wort
import Autolib.Util.Seed
imp... | Erdwolf/autotool-bonn | src/RSA/Quiz.hs | gpl-2.0 | 1,347 | 6 | 14 | 325 | 497 | 264 | 233 | 42 | 1 |
{-# LANGUAGE ExtendedDefaultRules, QuasiQuotes #-}
module Nirum.Cli (main, writeFiles) where
import Control.Concurrent (threadDelay)
import Control.Monad (forM_, forever, when)
import GHC.Exts (IsList (toList))
import System.IO
import qualified Data.ByteString as B
import qualified Data.Map.Strict as M
import qualifi... | spoqa/nirum | src/Nirum/Cli.hs | gpl-3.0 | 9,901 | 0 | 18 | 3,022 | 2,310 | 1,222 | 1,088 | 223 | 8 |
{-# LANGUAGE MultiParamTypeClasses #-}
module Message (
MessagePayload(..), RoutedMessage(..),
MessageSource, MessageSink, MessageIO,
Message(..), Routable(..),
-- * Message IDs
MessageId, MessageIdGen, mkMessageIdGen, nextMessageId
) where
import Control.Applicative ( (<$>), (<*>) )
import Control.C... | waldheinz/ads | src/lib/Message.hs | gpl-3.0 | 5,238 | 0 | 15 | 1,455 | 1,409 | 742 | 667 | 109 | 1 |
import System.Exit
import Test.HUnit
import StackMachine.Emulator
main = do
Counts _ _ errors failures <- runTestTT tests
if errors > 0 || failures > 0 then exitWith $ ExitFailure 1 else exitWith ExitSuccess
testMultibyteInstructions = TestCase (assertEqual "multi byte instructions initialization"
... | zebbo/stack-machine | test/EmulatorTests.hs | gpl-3.0 | 548 | 0 | 10 | 166 | 128 | 67 | 61 | 10 | 2 |
{-# LANGUAGE QuasiQuotes, OverloadedStrings #-}
module RunnerSpec (spec) where
import Test.Hspec
import Language.Mulang.Parsers.JavaScript
import Language.Mulang.Parsers.Python
import Language.Mulang.Interpreter.Runner
import Data.Text (unpack)
import NeatI... | mumuki/mulang | spec/RunnerSpec.hs | gpl-3.0 | 6,516 | 0 | 23 | 2,275 | 1,190 | 645 | 545 | 81 | 1 |
-- | Returns a pair of consecutive Fibonacci numbers a b,
-- where (a*b) is equal to the input, or proofs that the
-- number isn't a product of two consecutive Fibonacci
-- numbers.
productFib :: Integer -> (Integer, Integer, Bool)
productFib n = locationProductFibN n 2
-- i must >= 2
locationProductFibN :: Inte... | yannxia-self/code-war-hasekell-training | product_of_consecutive_fib_numbers.hs | gpl-3.0 | 659 | 0 | 12 | 156 | 276 | 143 | 133 | 12 | 1 |
{-# LANGUAGE OverloadedLists #-}
{-# LANGUAGE TemplateHaskell #-}
module Toy.Backend.Classify where
import AI.NN
import Data.Aeson
import Data.Aeson.TH
import Data.Text (pack)
import qualified Data.Vector as V
import Yesod.Core
data Classify = Classify PredictMo... | Qinka/reimagined-pancake | toy-backend/toy-backend-classify/src/nn/Toy/Backend/Classify.hs | gpl-3.0 | 704 | 0 | 11 | 188 | 224 | 122 | 102 | 21 | 3 |
{-# LANGUAGE TypeSynonymInstances #-}
module Database.Design.Ampersand.ADL1.Expression (
subst
,foldlMapExpression,foldrMapExpression
,primitives,isMp1, isEEps
,isPos,isNeg, deMorganERad, deMorganECps, deMorganEUni, deMorganEIsc, n... | 4ZP6Capstone2015/ampersand | src/Database/Design/Ampersand/ADL1/Expression.hs | gpl-3.0 | 9,113 | 0 | 13 | 2,432 | 3,692 | 1,905 | 1,787 | 155 | 21 |
-- Copyright 2016, 2017 Robin Raymond
--
-- This file is part of Purple Muon
--
-- Purple Muon is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) an... | r-raymond/purple-muon | src/PurpleMuon/Physics/Constants.hs | gpl-3.0 | 1,670 | 0 | 8 | 331 | 149 | 98 | 51 | 17 | 1 |
module Main (main) where
import LambdaFeed.Main (start)
main :: IO ()
main = start
| markus1189/lambda-feed | main/Main.hs | gpl-3.0 | 85 | 0 | 6 | 16 | 34 | 20 | 14 | 4 | 1 |
module Gui where
import Graphics.UI.Gtk
import SimpleListView
import Web
import Cache
import Data.IORef
data GuiData = GuiData [IO CacheEntry] (UpdateTreeView) Image Label Label | EmptyGuiData
guidata_get_cache_list (GuiData cache_list _ _ _ _) = cache_list
guidata_get_update_list (GuiData _ update_list _ _ _) = upd... | chyla/haskell-xkcd | src/Gui.hs | gpl-3.0 | 3,638 | 0 | 13 | 528 | 983 | 454 | 529 | 72 | 1 |
module Main where
import System.Arte.Tracker (runTracker)
main :: IO ()
main = runTracker
| imalsogreg/arte-ephys | exec/tracker.hs | gpl-3.0 | 92 | 0 | 6 | 15 | 30 | 18 | 12 | 4 | 1 |
module Nary_tree(make_tree, make_tree_dot) where
import Data.List
data NTree a =
NTreeFork a [(NTree a)]
| NTreeEmpty
deriving(Show,Eq)
make_tree a = let a' = reverse a in (build_dumb_tree NTreeEmpty a')
build_dumb_tree acc [] = acc
build_dumb_tree acc (a:as) =
let acc' = (NTreeFork a [acc]) in
build_dumb_tr... | luebbers/reconos | tools/fsmLanguage/fpga_scripts/generate_fsm/src/Nary_tree.hs | gpl-3.0 | 5,855 | 74 | 15 | 1,370 | 1,946 | 1,024 | 922 | 122 | 2 |
module Main where
import Brainfuck (runMachine, makeMachine, makeProgram, compileProgram)
helloworld :: String
helloworld="+++++++++[>++++++++>+++++++++++>+++++<<<-]>.>++.+++++++..+++.>-.------------.<++++++++.--------.+++.------.--------.>+."
echo :: String
echo = "+[>,.<]"
main::IO()
main = do prg <- return $ mak... | ledyba/Brainfucks | haskell/src/Main.hs | gpl-3.0 | 461 | 0 | 9 | 89 | 112 | 57 | 55 | 12 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | rueshyna/gogol | gogol-maps-engine/gen/Network/Google/Resource/MapsEngine/Rasters/Upload.hs | mpl-2.0 | 2,669 | 0 | 13 | 608 | 308 | 189 | 119 | 48 | 1 |
{-# LANGUAGE BangPatterns #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE TupleSections #-}
{-# OPTIONS_GHC -Wall #-}
-- The first step of compiling is to build all reactimated 'Event's into a
-- graph. The graph structure keeps track of the current heads.
module Reactive.Impulse.Internal.Gra... | JohnLato/impulse | src/Reactive/Impulse/Internal/Graph.hs | lgpl-3.0 | 14,841 | 2 | 24 | 4,121 | 4,117 | 2,054 | 2,063 | -1 | -1 |
-- ex0
-- halve xs = (take n xs, drop n xs)
-- where n = (length xs) `div` 2
-- halve xs = splitAt (length xs `div` 2) xs
-- ex1
safetail [] = []
safetail xs = tail xs
-- ex4
mult :: Num a => a -> a -> a -> a
mult = \x -> (\y -> (\z -> x * y * z))
| rranelli/rrfuncprog | week2/hw.hs | unlicense | 254 | 0 | 11 | 74 | 88 | 49 | 39 | 4 | 1 |
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TypeSynonymInstances #-}
module Gitomail.Opts
( Opts(..)
, Command(..)
, GitRef
, opts
, runCommand
, configPaths
, noImplicitConfigs
, repositoryPath
, repositoryName
, outputP... | kernelim/gitomail | src/Gitomail/Opts.hs | apache-2.0 | 6,011 | 0 | 23 | 1,921 | 1,349 | 714 | 635 | 123 | 1 |
module Lib
(
-- Types
Error
, UTF8String
, UTF8Char
-- Base64
, base64ToBytes
, bytesToBase64
-- Base16
, hexToBytes
, bytesToHex
, isHex
-- ByteString helper functions
, bitwiseCombine
, hammingDistance
, allPairsHammingDistance
, bytesToSt... | mjec/cryptopals-haskell | src/Lib.hs | bsd-3-clause | 15,425 | 0 | 16 | 3,641 | 4,300 | 2,569 | 1,731 | 351 | 3 |
module Main where
import Control.Monad.IO.Class
import Network.HTTP.Media ((//), (/:))
import Network.Wai
import Network.Wai.Handler.Warp
import Servant.Server
import Servant.API
import Data.Proxy
import System.Posix.User
import API
fromUserEnt :: UserEntry -> User
fromUserEnt (UserEntry name pass uid gid gecos h... | cl04/rest1 | hask-rest1/app/Server.hs | bsd-3-clause | 1,085 | 0 | 16 | 205 | 458 | 245 | 213 | -1 | -1 |
{-#LANGUAGE RecordWildCards #-}
{-# LANGUAGE LambdaCase #-}
module FileServer where
import Network hiding (accept, sClose)
import Network.Socket hiding (send, recv, sendTo, recvFrom, Broadcast)
import Network.Socket.ByteString
import Data.ByteString.Char8 (pack, unpack)
import System.Environment
import System.IO
imp... | Garygunn94/DFS | .stack-work/intero/intero18234Jfb.hs | bsd-3-clause | 7,344 | 194 | 17 | 1,861 | 1,911 | 984 | 927 | 135 | 6 |
module Main where
import Acme.Dont
main :: IO ()
main = don't $ do
return ()
return ()
| bennofs/ghc-server | tests/db-reloading/Main.hs | bsd-3-clause | 94 | 0 | 9 | 25 | 44 | 22 | 22 | 6 | 1 |
module Doukaku.BusTest (tests) where
import Distribution.TestSuite
import Doukaku.TestHelper
import qualified Doukaku.Bus as Bus
tests :: IO [Test]
tests = createTests $ newDoukakuTest {
tsvPath = "test/Doukaku/bus.tsv"
, solve = Bus.solve
}
| hiratara/doukaku-past-questions-advent-2013 | test/Doukaku/BusTest.hs | bsd-3-clause | 250 | 0 | 8 | 39 | 65 | 40 | 25 | 8 | 1 |
{- | = External Sort
When you don't have enough memory to sort a large number of values an
<https://en.wikipedia.org/wiki/External_sorting external sort>
can be used.
This library implements an /external sort/ algorithm using Gabriel Gonzales'
<https://hackage.haskell.org/package/pipes pipes> library and Ben Gamari's... | sseefried/external-sort | src/Data/ExternalSort.hs | bsd-3-clause | 2,451 | 0 | 5 | 401 | 40 | 31 | 9 | 5 | 0 |
module Yawn.Logger(
Level (LOG_INFO, LOG_DEBUG, LOG_ERROR),
doLog,
system,
trace
) where
import System.IO (IOMode (AppendMode), hPutStr, withFile)
import System.IO.Error (try)
import Yawn.Util.Time (getCalendarTime)
import Yawn.Configuration (Configuration, logRoot)
data Level = LOG_INFO | LOG_DEBUG | LOG_ERR... | ameingast/yawn | src/Yawn/Logger.hs | bsd-3-clause | 1,214 | 0 | 16 | 254 | 501 | 259 | 242 | 31 | 2 |
--------------------------------------------------------------------------------
-- |
-- Module : System.Information.StreamInfo
-- Copyright : (c) José A. Romero L.
-- License : BSD3-style (see LICENSE)
--
-- Maintainer : José A. Romero L. <escherdragon@gmail.com>
-- Stability : unstable
-- Portability : ... | Undeterminant/taffybar | src/System/Information/StreamInfo.hs | bsd-3-clause | 3,369 | 0 | 12 | 701 | 754 | 399 | 355 | 45 | 1 |
module Maven.Types.Pom (
Pom (Pom)
, DependencyManagement(DepMan)
, Dependency(..)
, Parent(..)
, groupId
, artifactId
, version
, dependencies
, dependencyManagement
) where
import Data.Map as Map
import Data.Text as T
data Pom = Pom
{ _groupId :: Maybe T.T... | wayofthepie/pom-analyzer | src/Maven/Types/Pom.hs | bsd-3-clause | 1,661 | 0 | 11 | 500 | 418 | 239 | 179 | 48 | 1 |
-- Copyright (c) 2016-present, Facebook, Inc.
-- All rights reserved.
--
-- This source code is licensed under the BSD-style license found in the
-- LICENSE file in the root directory of this source tree.
{-# LANGUAGE GADTs #-}
{-# LANGUAGE NoRebindableSyntax #-}
module Duckling.Rules
( allRules
, rulesFor
) w... | facebookincubator/duckling | Duckling/Rules.hs | bsd-3-clause | 9,272 | 0 | 11 | 1,124 | 2,302 | 1,287 | 1,015 | 225 | 1 |
{-
(c) The University of Glasgow 2006
(c) The GRASP/AQUA Project, Glasgow University, 1998
\section[Literal]{@Literal@: Machine literals (unboxed, of course)}
-}
{-# LANGUAGE CPP, DeriveDataTypeable #-}
module ETA.BasicTypes.Literal
(
-- * Main data type
Literal(..) -- Exported to... | AlexeyRaga/eta | compiler/ETA/BasicTypes/Literal.hs | bsd-3-clause | 18,943 | 0 | 16 | 5,777 | 4,673 | 2,422 | 2,251 | 309 | 2 |
module GraphReduction.Machine where
import Data.List (mapAccumL)
import Core.AST
import Core.Prelude
import Util.Heap
data GmState = GmState
{ code :: GmCode
, stack :: GmStack
, dump :: GmDump
, heap :: GmHeap
, globals :: GmGlobals
, stats :: GmStats
} deriving Show
type GmCode = [I... | WraithM/CoreCompiler | src/GraphReduction/Machine.hs | bsd-3-clause | 6,297 | 0 | 12 | 1,828 | 2,804 | 1,473 | 1,331 | 176 | 4 |
module Data.Array.Accelerate.BLAS.Internal.Axpy where
import Data.Array.Accelerate.BLAS.Internal.Common
import Data.Array.Accelerate
import Data.Array.Accelerate.CUDA.Foreign
import qualified Foreign.CUDA.BLAS as BL
import Prelude hiding (zipWith, map)
cudaAxpyF :: (Scalar Float, Vector Float, Vector Float)
... | alpmestan/accelerate-blas | src/Data/Array/Accelerate/BLAS/Internal/Axpy.hs | bsd-3-clause | 2,439 | 0 | 13 | 642 | 844 | 426 | 418 | 44 | 1 |
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE RecursiveDo #-}
module Reflex.Dom.Lists where
import GHCJS.Foreign ()
import Data.JSString()
import Reflex.Dom
import qualified Data.Map.Strict as M
import Control.Lens
addListWorkflow :: MonadWidget t m
=> a -- ^ default value
-> M.Map Int a ... | bartavelle/reflex-dom-bootstrap-components | src/Reflex/Dom/Lists.hs | bsd-3-clause | 2,952 | 0 | 20 | 842 | 946 | 482 | 464 | 57 | 2 |
{-# LANGUAGE NoMonomorphismRestriction, BangPatterns #-}
module Data.Iteratee.Parallel (
psequence_
-- ,psequence
,parE
,parI
,liftParI
,mapReduce
)
where
import Control.Monad.IO.Class
import Control.Monad.Trans.Class
import Data.Iteratee as I hiding (mapM_, zip, filter)
import q... | iteloo/tsuru-sample | iteratee-0.8.9.6/src/Data/Iteratee/Parallel.hs | bsd-3-clause | 4,112 | 0 | 16 | 1,114 | 905 | 479 | 426 | 66 | 3 |
{-# LANGUAGE CPP, ScopedTypeVariables, BangPatterns #-}
{-# OPTIONS_GHC -fno-warn-orphans #-}
-- |
-- Copyright : (c) 2011 Simon Meier
-- License : BSD3-style (see LICENSE)
--
-- Maintainer : Simon Meier <iridcode@gmail.com>
-- Stability : experimental
-- Portability : tested on GHC only
--
-- Testing composi... | markflorisson/hpack | testrepo/bytestring-0.10.2.0/tests/builder/Data/ByteString/Builder/Tests.hs | bsd-3-clause | 23,982 | 0 | 17 | 6,257 | 6,542 | 3,386 | 3,156 | -1 | -1 |
-- |
-- Module: Crypto.HKDF
-- Maintainer: Jiri Marsicek <jiri.marsicek@gmail.com>
--
-- This module provides implementation of HKDF function defined in
-- RFC-5869 (<http://www.ietf.org/rfc/rfc5869.txt>),
-- It is using "HashAlgorithm" from "cryptohash" as underlying implementation
--
module Crypto.HKDF
( hkdfExtr... | j1r1k/hkdf | src/Crypto/HKDF.hs | bsd-3-clause | 2,660 | 0 | 11 | 761 | 510 | 294 | 216 | 40 | 1 |
{-# LANGUAGE FlexibleInstances #-}
module LibSpec (main, spec) where
import Test.Hspec
import Test.QuickCheck
import Generic.Random.Generic
import Control.Lens hiding (elements)
import Lib hiding (main)
instance Arbitrary Location where
arbitrary = genericArbitrary' Z uniform
instance Arbitrary Target where
arb... | rubenpieters/gre-project | shared/test/LibSpec.hs | bsd-3-clause | 7,867 | 0 | 16 | 1,819 | 771 | 431 | 340 | 47 | 1 |
{-# LANGUAGE OverloadedStrings #-}
{- |
Module : Text.Pandoc.Filters.ShortcutLinks
License : BSD3
Maintainer : Artyom <yom@artyom.me>
This filter turns links that look like “[something](\@w)” into <https://en.wikipedia.org/wiki/Something>. For details, see <https://github.com/aelve/shortcut-links>.
-}
modu... | aelve/pandoc-contrib | lib/Text/Pandoc/Filters/ShortcutLinks.hs | bsd-3-clause | 2,367 | 0 | 23 | 567 | 595 | 310 | 285 | 47 | 4 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.