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
module Module3.Task12 where import Data.Char delAllUpper :: String -> String delAllUpper = unwords . (filter $ any isLower) . words
dstarcev/stepic-haskell
src/Module3/Task12.hs
bsd-3-clause
133
0
9
21
43
24
19
4
1
{-# LANGUAGE RankNTypes, ScopedTypeVariables, GADTs, DataKinds, KindSignatures #-} module Network.LambdaBridge.Bridge ( -- * Bridge Bridge(..) , Fragmentation(..) , Integrity(..) -- * Bridge Roots , connection , mVarBridge , handleBridge -- * Bri...
ku-fpg/lambda-bridge
Network/LambdaBridge/Bridge.hs
bsd-3-clause
10,070
9
19
4,231
1,959
979
980
172
4
{-# LANGUAGE NamedFieldPuns #-} ----------------------------------------------------------------------------- -- | -- Module : XMonad.Actions.TopicSpace -- Description : Turns your workspaces into a more topic oriented system. -- Copyright : (c) Nicolas Pouillard -- License : BSD-style (see LICENSE) -- -...
xmonad/xmonad-contrib
XMonad/Actions/TopicSpace.hs
bsd-3-clause
15,744
0
17
3,658
2,089
1,202
887
153
1
{-# LANGUAGE DataKinds #-} {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE MultiParamTypeClasses #-} {-# LANGUAGE NoImplicitPrelude #-} {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE TypeFamilies #-} -- | -- Module: $HEADER$ -- Description: TODO -...
FPBrno/dht-dks
src/Data/DHT/DKS/Type/Message/LeaveRetry.hs
bsd-3-clause
938
0
9
151
161
105
56
23
0
{-| Module : Werewolf.Command.Circle Description : Options and handler for the circle subcommand. Copyright : (c) Henry J. Wylde, 2016 License : BSD3 Maintainer : public@hjwylde.com Options and handler for the circle subcommand. -} module Werewolf.Command.Circle ( -- * Options Options(..), -...
hjwylde/werewolf
app/Werewolf/Command/Circle.hs
bsd-3-clause
1,235
0
12
255
283
155
128
25
2
-------------------------------------------------------------------------------- module Copilot.Kind.ProofScheme where import Control.Monad.Writer -------------------------------------------------------------------------------- type PropId = String type ProofScheme = Writer [Action] () data Action = Check P...
jonathan-laurent/copilot-kind
src/Copilot/Kind/ProofScheme.hs
bsd-3-clause
1,007
0
10
151
260
141
119
22
1
{-# LANGUAGE CPP, OverloadedStrings, ExistentialQuantification #-} module MOO.Task ( -- * Monad Interface MOO , Environment(..) , initEnvironment , liftVTx , liftSTM -- * World Interface , World(..) , newWorld , getWorld , getWorld' , putWorld , modifyWorld , updateConnections , getDa...
verement/etamoo
src/MOO/Task.hs
bsd-3-clause
50,457
0
23
13,472
13,380
7,049
6,331
1,087
10
import Depend import Distribution.Package import Distribution.Version import Distribution.PackageDescription import Distribution.PackageDescription.Parse import Distribution.Verbosity import Data.Maybe main :: IO () main = do gpd <- readPackageDescription normal "cabal2ebuild.cabal" -- print $ snd $ head $ condExec...
YoshikuniJujo/cabal2ebuild
test/testDepend.hs
bsd-3-clause
975
0
8
166
81
47
34
11
1
-- | -- Module : Tests.Tests.hs -- License : BSD-Style -- Copyright : Copyright © 2014 Nicolas DI PRIMA -- -- Maintainer : Nicolas DI PRIMA <nicolas@di-prima.fr> -- Stability : experimental -- Portability : unknown -- {-# LANGUAGE OverloadedStrings #-} import Test.Tasty import Test.Tasty.HUnit import Dat...
NicolasDP/hs-bspack
Tests/Tests.hs
bsd-3-clause
3,801
0
13
746
623
320
303
42
2
{-| Effect Types and Their Noun Conversions -} module Urbit.Arvo.Effect where import Urbit.Prelude import Urbit.Time import Urbit.Arvo.Common (KingId(..), ServId(..)) import Urbit.Arvo.Common (Header, HttpEvent, HttpServerConf, Method, Mime) import Urbit.Arvo.Common (AmesDest, Turf) import Urbit.Arvo.Common (ReOr...
jfranklin9000/urbit
pkg/hs/urbit-king/lib/Urbit/Arvo/Effect.hs
mit
5,146
0
14
1,269
1,302
707
595
-1
-1
{-# LANGUAGE TemplateHaskell #-} module Rewriting.Derive.Config where import qualified Rewriting.Roller as R import Autolib.TES.Identifier import Autolib.Symbol import Autolib.ToDoc import Autolib.Reader import Data.Typeable data ( Symbol c, Symbol v ) => Config v c = Config { system_roller :: R.Config v c ...
florianpilz/autotool
src/Rewriting/Derive/Config.hs
gpl-2.0
786
0
10
235
195
119
76
23
1
module HEP.Data.ParserUtil (skipTillEnd, parseEvent) where import Control.Monad.Trans.State.Strict (StateT (..)) import Data.Attoparsec.ByteString (skipWhile) import Data.Attoparsec.ByteString.Char8 hiding (skipWhile) import Data.ByteString.Char8 (ByteString) im...
cbpark/hep-kinematics
src/HEP/Data/ParserUtil.hs
bsd-3-clause
766
0
12
238
233
127
106
13
2
-- Copyright (c) 1998-1999 Chris Okasaki. -- See COPYRIGHT file for terms and conditions. -- These Braun sequences support cons in O(log n) -- time, but snoc in O(log^2 n) time. By keeping -- track of the size, we could get snoc down to O(log n) -- as well. module BraunSeq {-# DEPRECATED "This module is unmaintai...
alekar/hugs
fptools/hslibs/data/edison/Seq/BraunSeq.hs
bsd-3-clause
14,270
2
14
4,945
6,977
3,593
3,384
336
7
module Settings.Packages.Ghci (ghciPackageArgs) where import Expression ghciPackageArgs :: Args ghciPackageArgs = package ghci ? notStage0 ? builder GhcCabal ? arg "--flags=ghci"
bgamari/shaking-up-ghc
src/Settings/Packages/Ghci.hs
bsd-3-clause
181
0
8
23
46
25
21
4
1
module Helper ( module Test.Hspec , module Test.Mockery.Directory , module Control.Applicative , withTempDirectory , module System.FilePath , withCurrentDirectory ) where import Test.Hspec import Test.Mockery.Directory import Control.Applicative import System.Directory (getCur...
yamadapc/hpack-convert
test/Helper.hs
mit
830
0
11
164
197
109
88
22
1
{- - Monadic Constraint Programming - http://www.cs.kuleuven.be/~toms/Haskell/ - Tom Schrijvers -} {-# LANGUAGE TransformListComp #-} {-# LANGUAGE Rank2Types #-} {-# LANGUAGE TypeFamilies #-} module Control.CP.FD.FDSugar where import Control.CP.SearchTree hiding (label) import Control.CP.Transformers import ...
neothemachine/monadiccp
src/Control/CP/FD/FDSugar.hs
bsd-3-clause
4,163
1
17
1,018
1,542
802
740
87
2
{-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE MultiParamTypeClasses #-} {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE TupleSections #-} -- | Cache information about previous builds module Stack.Build.Cache ( tryGetBuildCache , tryGetConfigCache , tryGetCabalMod , getInstalledExes ...
wskplho/stack
src/Stack/Build/Cache.hs
bsd-3-clause
9,817
0
15
2,701
2,459
1,256
1,203
211
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="bs-BA"> <title>Eval Villain Add-On</title> <maps> <homeID>evalvillain</homeID> <mapref ...
thc202/zap-extensions
addOns/evalvillain/src/main/javahelp/org/zaproxy/addon/evalvillain/resources/help_bs_BA/helpset_bs_BA.hs
apache-2.0
972
77
67
157
413
209
204
-1
-1
module Aws.Ses.Commands.SetIdentityFeedbackForwardingEnabled ( SetIdentityFeedbackForwardingEnabled(..) , SetIdentityFeedbackForwardingEnabledResponse(..) ) where import Data.Text (Text) import Data.Text.Encoding as T (encodeUtf8) import Data.Typeable import Aws.Core import Aws.Ses.Core -- | Change whethe...
RayRacine/aws
Aws/Ses/Commands/SetIdentityFeedbackForwardingEnabled.hs
bsd-3-clause
1,968
0
10
311
273
158
115
-1
-1
module ScopeNamesPropStruct where import ScopeNames import ScopeNamesBaseStruct(extdef,exttvar,pairEnv) import DefinedNames import DefinedNamesPropStruct() import FreeNames import PropSyntaxStruct --import MUtils import EnvM --extdef ext b = inModEnv . ext $ definedNames b instance (ScopeNames i e pa1 pa2,ScopeNames ...
forste/haReFork
tools/property/defs/ScopeNamesPropStruct.hs
bsd-3-clause
1,812
6
16
488
771
395
376
-1
-1
module B8 where --Any type/data constructor name declared in this module can be renamed. --Any type variable can be renamed. --Rename type Constructor 'BTree' to 'MyBTree' data BTree a = Empty | T a (BTree a) (BTree a) deriving Show buildtree :: (Monad m, Ord a) => [a] -> m (BTree a) buildtree [] = ...
mpickering/HaRe
old/testing/unfoldAsPatterns/B8_TokOut.hs
bsd-3-clause
756
0
11
253
299
152
147
18
1
{-# LANGUAGE MultiParamTypeClasses #-} module T5001 where import T5001a data T = T instance Comorphism Float Int Char T
urbanslug/ghc
testsuite/tests/deSugar/should_compile/T5001.hs
bsd-3-clause
125
0
5
24
28
16
12
5
0
module Backward where import qualified Vector3f import qualified Forward move_backward :: Vector3f.T -> Vector3f.T -> Float -> Vector3f.T move_backward p forward d = Forward.move_forward p forward (-d)
io7m/jcamera
com.io7m.jcamera.documentation/src/main/resources/com/io7m/jcamera/documentation/haskell/Backward.hs
isc
204
0
8
29
61
34
27
5
1
import Prelude hiding (id,(.)) import System.Random import Control.Category import Graphics.Rendering.OpenGL hiding (R, get) import Graphics.UI.GLFW import qualified Data.Vector as V import Data.Label import Data.List import Data.Vect.Double import Data.Vect.Double.OpenGL import Data.IORef import Control.Concurrent ...
fatuhoku/haskell-ball-mosaic
src/Main.hs
mit
10,397
1
22
2,458
1,907
988
919
146
8
#!/usr/bin/env runhaskell import Control.Monad (mapM_) import System.Libnotify.Server import System.Libnotify.Types main :: IO () main = getServerInfo >>= \si -> putStrLn "Server information" >> putStrLn ("name: " ++ serverName si) >> putStrLn ("vendor: " ++ serverVendor si) >> pu...
supki/libnotify
tests/server-info-caps-test.hs
mit
531
0
16
136
144
73
71
13
1
module Rebase.Text.Show ( module Text.Show ) where import Text.Show
nikita-volkov/rebase
library/Rebase/Text/Show.hs
mit
71
0
5
12
20
13
7
4
0
{-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE NamedFieldPuns #-} {-# LANGUAGE OverloadedStrings #-} {- Exports -} module Lib (module Lib , Types.RomeVersion , Utils.romeVersionToString ) where {- Imports -} import qualified Codec.Archive.Zip as Zip impor...
mheinzel/Rome
src/Lib.hs
mit
72,130
7
27
21,619
11,030
5,639
5,391
1,062
6
module Test.Test where import Test.Framework (defaultMainWithArgs, testGroup, Test) import Test.Framework.Providers.HUnit (testCase) import Test.Framework.Providers.QuickCheck2 (testProperty) import Test.QuickCheck (Property, NonNegative(..)) import Test.QuickCheck.Monadic (assert, monadicIO, run) import Test.HUnit (...
yanatan16/tybee
tests/Test/Test.hs
mit
750
0
7
97
211
125
86
16
1
{-# LANGUAGE ViewPatterns, GeneralizedNewtypeDeriving, TemplateHaskell #-} module Web.Slack.Types.Time where import Data.Aeson import Data.Aeson.Encoding import Data.Aeson.Types import Data.Scientific (floatingOrInteger) import qualified Data.Text as T import Control.Applicative import Control.Error import Control.Len...
mpickering/slack-api
src/Web/Slack/Types/Time.hs
mit
1,733
0
16
407
447
238
209
-1
-1
{-# LANGUAGE BangPatterns #-} {-# LANGUAGE RecordWildCards #-} module Data.Stream.Algorithms.DGIM.Internal ( -- * Type (with constructors) DGIM(..) -- * Creation , mkDGIM -- * Insertion , insert , insert_ -- * Querying , querySince , queryAll , queryLen ) where import Control.Exception ( as...
musically-ut/haskell-dgim
src/Data/Stream/Algorithms/DGIM/Internal.hs
mit
4,188
0
19
1,201
1,091
575
516
79
6
-- | A simple executable to run Hablog {-# LANGUAGE LambdaCase #-} module Main where import Data.List (intercalate) import Data.Text.Lazy (pack, unpack) import Options.Applicative import Web.Hablog main :: IO () main = do cfg <- execParser configParserInfo run cfg -------------------- -- Options Parser -------...
soupi/hablog
app/Main.hs
mit
1,813
0
14
528
517
255
262
70
2
removeNode :: Eq a => a -> [a] -> [a] removeNode _ [] = [] removeNode x (y:ys) | x == y = ys | otherwise = y : removeNode x ys
Kiandr/CrackingCodingInterview
Haskell/src/chapter-2/remove-node.hs
mit
147
0
8
52
86
42
44
4
1
-- | The render core defines the basic types and helper functions for a basic -- UI system. -- -- The fundamental data type is the 'Renderer', which is declared in a -- hierarchical fashion. module Game.Render.Core ( Renderer(..) , Offset , defaultRenderer ...
bfops/Chess
src/Game/Render/Core.hs
mit
6,571
0
14
2,780
1,003
573
430
74
3
module Jaml.Util ( joinStrs ) where import Data.List (intersperse) joinStrs :: String -> [String] -> String joinStrs sep strs = concat $ intersperse sep strs
marklar/jaml
Jaml/Util.hs
mit
160
0
7
27
56
31
25
5
1
module Parse where import Ant (Ant(..), AntList) import Change (Change(..)) import qualified Text.Parsec as P charToAnt :: Char -> Ant charToAnt c | c == 'К' = K | c == 'Л' = L | c == 'П' = P | c == 'Х' = H numbers :: String numbers = "0123456789" is_num :: Char -> Bool is_num x = x `elem` numbers ant...
Valiev/contests
darkus/201509/Parse.hs
mit
1,855
0
11
412
747
377
370
61
2
{-# LANGUAGE DeriveFunctor #-} module Forths ( Forth, Expr(FInt, FString, FWord, End), pushInt, pushString, word, end, pretty, eval, evalInEnv ) where import Control.Monad.Free import qualified Data.Map as Map -- only for interpreter, refactor -- Questions: -- 1. I have been ...
radix/Forths
Forths.hs
mit
3,371
0
12
734
1,252
655
597
60
1
module Happstack.Server.Env ( simpleHTTP , module Happstack.Server ) where import Happstack.Server hiding (simpleHTTP) import qualified Happstack.Server as Happstack import Safe (readMay) import System.Environment (getEnvironment) -- | An alternate @simpleHT...
fpco/web-fpco
Happstack/Server/Env.hs
mit
983
0
15
293
180
96
84
18
3
module CABI.X86_64 (convertFunc) where import CABI.Common (Arg(Arg), ArgType(..), removeNames) import Control.Monad (forM_) import Control.Monad.Writer (WriterT, writer, execWriterT) import Control.Monad.State (StateT, modify, get, evalStateT) import Control.Monad.Trans (lift) import Data.Word (Word32) import Data.Lis...
elegios/datalang
src/CABI/x86_64.hs
mit
3,592
0
14
718
1,475
774
701
-1
-1
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE OverloadedLists #-} module Language.Rowling.TypeCheck.Builtins ( builtInTypes ) where import Language.Rowling.Common import Language.Rowling.Definitions.Types import qualified Data.Set as S builtInTypes :: TypeMap builtInTypes = [("+", "Int" ==> "Int" ==> "Int"), ...
thinkpad20/rowling
src/Language/Rowling/TypeCheck/Builtins.hs
mit
508
0
10
110
140
82
58
12
1
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE StrictData #-} {-# LANGUAGE TupleSections #-} -- | http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-wafregional-sizeconstraintset.html module Stratosphere.Resources.WAFRegionalSizeConstraintSet where import Str...
frontrowed/stratosphere
library-gen/Stratosphere/Resources/WAFRegionalSizeConstraintSet.hs
mit
2,397
0
15
248
279
162
117
31
1
module Type where removeNonUpperCase :: [Char] -> [Char] removeNonUpperCase cs = [ c | c <- cs, c `elem` ['A'..'Z'] ] -- *Type> removeNonUpperCase "abcdEFG" -- "EFG" -- Int - bounded integers 2^32 -- Integer - boundless integers factorial :: Integer -> Integer factorial n = product [1..n] -- *Type> factorial 5...
ardumont/haskell-lab
src/learn-you-a-haskell-for-great-good/type.hs
gpl-2.0
627
0
8
111
116
70
46
7
1
{-# OPTIONS -w -O0 #-} {- | Module : RelationalScheme/ATC_RelationalScheme.der.hs Description : generated Typeable, ShATermConvertible instances Copyright : (c) DFKI Bremen 2008 License : GPLv2 or higher, see LICENSE.txt Maintainer : Christian.Maeder@dfki.de Stability : provisional Portability : n...
nevrenato/Hets_Fork
RelationalScheme/ATC_RelationalScheme.hs
gpl-2.0
14,044
0
22
3,018
4,260
2,202
2,058
286
1
{-# LANGUAGE OverloadedStrings #-} module ControlThreadTests where import Prelude hiding (readFile) import Control.Lens import System.IO import Control.Concurrent -- import Test.Tasty.HUnit (testCase, (@?=)) import FuncTorrent.ControlThread hiding (controlThreadMain) import FuncTorrent.Peer import FuncTorrent.PeerT...
dfordivam/functorrent
test/ControlThreadTests.hs
gpl-3.0
1,072
0
7
171
114
73
41
15
1
{-# LANGUAGE DeriveGeneric, OverloadedStrings #-} module P44ProductSearch where import Data.Aeson import GHC.Generics import Data.Text (Text) import Data.List (isInfixOf) import qualified Data.ByteString.Lazy as B import qualified Data.Text as T import Library -- TODO: add files back to JSON file if product not found...
ciderpunx/57-exercises-for-programmers
src/P44ProductSearch.hs
gpl-3.0
1,412
0
18
368
439
227
212
47
2
{-# LANGUAGE RecordWildCards, StandaloneDeriving, OverloadedStrings #-} {-| An 'Account' has a name, a list of subaccounts, an optional parent account, and subaccounting-excluding and -including balances. -} module Hledger.Data.Account where import Data.List import Data.Maybe import qualified Data.Map as M import S...
mstksg/hledger
hledger-lib/Hledger/Data/Account.hs
gpl-3.0
7,219
0
16
1,649
1,703
916
787
104
2
module LiName.Undo ( saveUndoInfo ) where import LiName.Types import Control.Applicative ((<$>)) import Control.Monad (when) import Data.Time.Clock (getCurrentTime) import Data.Time.Format (formatTime, defaultTimeLocale) import System.Directory (createDirectory, doesDirectoryExist, getHomeDirectory) import System....
anekos/liname-hs
src/LiName/Undo.hs
gpl-3.0
825
0
11
127
239
128
111
20
1
{-# LANGUAGE DeriveDataTypeable #-} module Error (HackPortError(..), throwEx, catchEx, hackPortShowError) where import Data.Typeable import Control.Exception.Extensible as EE data HackPortError = ArgumentError String | ConnectionFailed String String | PackageNotFound String | InvalidTarballURL String...
Heather/hackport
Error.hs
gpl-3.0
3,236
0
13
566
601
311
290
49
18
module CLI where import Control.Lens import qualified Data.Map as M import qualified Data.Set as S import qualified Data.Text as T import System.Console.Haskeline import H.IO import H.Prelude import Text.Parsec.Applicative import CLI.Output import Command import Command.BuyAircraft import Command.ChangeFlight import...
ktvoelker/airline
src/CLI.hs
gpl-3.0
5,509
0
21
1,184
1,916
1,002
914
-1
-1
{- pandoc-citeproc-preamble --- Insert a preamble before pandoc-citeproc's bibliography Copyright (C) 2015-2016, 2019 Sean Whitton This file is part of pandoc-citeproc-preamble. pandoc-citeproc-preamble is free software: you can redistribute it and/or modify it under the terms of the GNU Genera...
spwhitton/pandoc-citeproc-preamble
src/pandoc-citeproc-preamble.hs
gpl-3.0
2,953
4
15
795
582
301
281
45
3
module Character.Actor where import Misc.Point --Not sure if this typeclass is totally necessary yet. class Actor a where getLocation :: a -> Point getX :: a -> Int getY :: a -> Int
MortimerMcMire315/rogue_nads
src/Character/Actor.hs
gpl-3.0
195
0
7
46
48
27
21
6
0
import Data.Time import System.Locale (defaultTimeLocale) import Data.Maybe plusOneTime :: UTCTime -> ZonedTime plusOneTime t = utcToZonedTime (hoursToTimeZone 1) t fmtTime t = formatTime defaultTimeLocale "%Y-%m-%d %H:%M %z" t timeParsed :: String -> UTCTime timeParsed line = fromJust t where t = parseTime ...
jsavatgy/talvipaivanseisauksen-ajanlasku
bmt-test-03.hs
gpl-3.0
843
0
13
174
267
137
130
28
1
{-# LANGUAGE DeriveDataTypeable #-} module Calculator ( calculateLine, NumberType, CalculatingErrorMessage, InvalidCommand, calcTreeTest, divideTextLineTest, dividedCommandToTreeTest, mainTest ) where import Data.Functor import Control.Applicative import Control...
collia/SimpleCalc
src/Calculator.hs
gpl-3.0
8,322
0
14
2,458
2,668
1,337
1,331
115
4
----------------------------------------------------------------------------- -- -- Module : Data.DICOM.FileMetaInformation -- Copyright : Copyright (c) DICOM Grid 2015 -- License : GPL-3 -- -- Maintainer : paf31@cantab.net -- Stability : experimental -- Portability : -- -- | Functions for dealing wi...
dicomgrid/dicom-haskell-library
src/Data/DICOM/FileMetaInformation.hs
gpl-3.0
1,308
0
8
203
171
104
67
21
1
-- Copyright 2011 by Joshua Simmons <joshua.simmons@emptypath.com> {-# LANGUAGE NamedFieldPuns #-} module Game where import SGF import Data.Map (Map) import qualified Data.Map as M import Data.Set (Set) import qualified Data.Set as S import Data.Maybe import Data.List (foldl',sort,sortBy) import qualified Data.List a...
kadoban/sgf
Game.hs
agpl-3.0
6,577
0
16
2,643
2,388
1,262
1,126
140
11
{- Network.Lifx - A Library to interact with Lifx light bulbs. (lifx.co) Copyright (C) 2014 Josh Proehl <josh@daedalusdreams.com> *************************************************************************** This program is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser Genera...
joshproehl/lifx-haskell
src/Network/Lifx.hs
lgpl-3.0
5,045
0
15
1,187
1,048
560
488
55
1
module Main where import Test.Hspec import Test.Hspec.QuickCheck import Test.QuickCheck.Property import Test.QuickCheck.Assertions import Data.AEq import Numeric.IEEE check, check2 :: (Double -> Double -> Result) -> (Double -> Double -> Result) -> (Double -> Double -> Bool) -> Double -> Double -> Property check ck1 c...
s9gf4ult/quickcheck-assertions
tests/main.hs
lgpl-3.0
1,468
0
15
390
687
369
318
36
1
{-# LANGUAGE ScopedTypeVariables, MultiParamTypeClasses, FlexibleInstances, CPP #-} -- The following is all rather brittle: We need to pre-process this file with GHC -- in order to get the __GLASGOW_HASKELL__ macro (which we should replace with a -- version test of the array package). At the same time we need to versi...
juhp/gtk2hs
cairo/Graphics/Rendering/Cairo.hs
lgpl-3.0
84,338
2
16
17,467
10,083
5,669
4,414
-1
-1
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE ScopedTypeVariables #-} module Github.Review.TypesSpec (spec) where import Control.Error import Control.Monad (unless) import Data.Default import Github.Data import Github.Review import Test.Hspec import Test.HUnit import Test.QuickCheck spec :: Spec spec = des...
erochest/gitreview-core
specs/Github/Review/TypesSpec.hs
apache-2.0
2,635
0
22
995
841
385
456
49
3
module Codec.FFMpeg ( initFFMpeg, AVMediaType, video ) where import Codec.FFMpeg.Internal.Util initFFMpeg :: IO () initFFMpeg = c_av_register_all foreign import ccall "av_register_all" c_av_register_all :: IO ()
waldheinz/ffmpeg-effects
src/Codec/FFMpeg.hs
apache-2.0
233
0
7
46
56
33
23
8
1
-- -- Copyright (c) 2013, Carl Joachim Svenn -- All rights reserved. -- -- Redistribution and use in source and binary forms, with or without -- modification, are permitted provided that the following conditions are met: -- -- 1. Redistributions of source code must retain the above copyright notice...
karamellpelle/MEnv
source/OpenGL.hs
bsd-2-clause
2,220
0
5
438
173
127
46
16
0
{-# LANGUAGE TypeSynonymInstances #-} {-# LANGUAGE GADTs #-} -- This data structure has the graphic/midi data stored into a list. -- The tree is integrated into the list. -- Each element can be a 'list node', 'tree node', or 'nil' -- See fmap to get sense of operation -- Purpose is to be able to click on HTML ca...
nickgeoca/music-browserside
ListTree.hs
bsd-3-clause
6,053
0
13
1,929
1,040
548
492
64
4
{-# LANGUAGE JavaScriptFFI #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE DataKinds, FlexibleInstances, MultiParamTypeClasses #-} ----------------------------------------------------------------------------- -- | -- Module : Program.Settings -- Copyright : (c) Artem Chirkin -- License : MIT -- -- Mai...
achirkin/ghcjs-modeler
src/Program/Settings.hs
bsd-3-clause
4,887
43
11
1,146
1,049
583
466
-1
-1
module Language.Commands ( Command, VarTable, CommandTable, ScriptState(..), command_tb ) where import System.Directory import System.FilePath.Posix import System.Environment import System.IO import System.IO.Error (ioeGetFileName, ioeGetErrorString, userError) import Control.Exception (catch, throw) imp...
edi-smoljan/FER-PUH-2014-Hash
Language/Commands.hs
bsd-3-clause
8,633
0
23
2,274
2,888
1,492
1,396
218
5
-------------------------------------------------------------------------------- -- | -- Module : Graphics.Rendering.OpenGL.Raw.ARB.TextureRGB10A2UI -- Copyright : (c) Sven Panne 2015 -- License : BSD3 -- -- Maintainer : Sven Panne <svenpanne@gmail.com> -- Stability : stable -- Portability : portabl...
phaazon/OpenGLRaw
src/Graphics/Rendering/OpenGL/Raw/ARB/TextureRGB10A2UI.hs
bsd-3-clause
660
0
4
78
37
31
6
3
0
module PPrint ( pprint ) where import Base pprint :: Term -> String pprint TermTrue = "true" pprint TermFalse = "false" pprint t = show (go t) where go :: Term -> Int go TermZero = 0 go (TermSucc nv) = succ $ go nv go _ = undefined
foreverbell/unlimited-plt-toys
tapl/arith/PPrint.hs
bsd-3-clause
254
0
9
71
102
53
49
11
3
module Main where --import FRP.Timeless import FRP.Timeless.Framework.SDL main :: IO () main = testApp
carldong/timeless-SDL
app/Main.hs
bsd-3-clause
105
0
6
16
27
17
10
4
1
module Main where import Test.Hspec import Bio.Sequence as S import Data.Clustering.Hierarchical import Global import Output -- -- test Output module -- leaf :: String -> Int -> Dendrogram (AnnSeq a) leaf fileName seqNumber = let header = S.fromStr "Sequence header" content = S.fromStr "GATTACA" dumm...
j-larson/bio-acai
Tests.hs
bsd-3-clause
1,299
0
16
342
412
221
191
35
1
module D6Lib where import Data.List import Util fixMessage :: [String] -> String fixMessage = fixer sorter where sorter (c1, f1) (c2, f2) = compare f2 f1 -- want freq-desc fixModMessage :: [String] -> String fixModMessage = fixer sorter where sorter (c1, f1) (c2, f2) = compare f1 f2 -- want freq-asc fix...
wfleming/advent-of-code-2016
2016/src/D6Lib.hs
bsd-3-clause
492
0
9
104
183
101
82
12
1
{-# LANGUAGE OverloadedStrings #-} module Chrome where import Control.Applicative ((<$>)) import Control.Monad (forever, mzero) import Control.Monad.Trans (liftIO) import Control.Monad.IO.Class (MonadIO) import Control.Concurrent (forkIO, ThreadId) import ...
rvion/chrome-reloader
src/Chrome.hs
bsd-3-clause
2,739
0
15
679
657
373
284
58
2
{-# LANGUAGE DeriveDataTypeable #-} module Data.FieldML.Level1Structure where import qualified Data.ByteString as BS import Data.Data data SrcSpan = SrcSpan { srcFile :: String, srcStartRow :: Int, srcStartColumn :: Int, srcEndRow :: Int, srcEndColumn :: Int } deriving (Eq, Ord, Data, Typeable) ...
A1kmm/declarative-fieldml-prototype
src/Data/FieldML/Level1Structure.hs
bsd-3-clause
13,874
0
14
5,497
2,445
1,469
976
204
0
module Handler.TemplateCopySpec (spec) where import TestImport spec :: Spec spec = withApp $ do describe "getTemplateCopyR" $ do error "Spec not implemented: getTemplateCopyR"
Ulrar/cstodo
test/Handler/TemplateCopySpec.hs
bsd-3-clause
192
0
11
39
44
23
21
6
1
module EFA2.Example.Circular (circular) where import Data.Graph.Inductive import qualified Data.Map as M import Control.Monad.Error import EFA2.Signal.Arith import EFA2.Term.TermData import EFA2.Term.Env import EFA2.Graph.GraphData import EFA2.Graph.Graph import EFA2.Example.SymSig numOf = 3 sigs :: LRPowerEnv...
energyflowanalysis/efa-2.1
attic/src/EFA2/Example/Circular.hs
bsd-3-clause
1,220
0
14
218
547
284
263
30
1
module CallByReference.Suites where import qualified CallByReference.EvaluatorSuite as EvalTest import qualified CallByReference.ParserSuite as ParseTest import Test.HUnit tests = TestList [ EvalTest.tests, ParseTest.tests ]
li-zhirui/EoplLangs
test/CallByReference/Suites.hs
bsd-3-clause
240
0
7
37
45
29
16
5
1
{-# LANGUAGE PatternGuards, FlexibleContexts, FlexibleInstances, MultiParamTypeClasses, TupleSections #-} ----------------------------------------------------------------------------- -- | -- Module : XMonad.Layout.AvoidFloats -- Description : Avoid floats when placing tiled windows. -- Copyright : (c) 2014 ...
xmonad/xmonad-contrib
XMonad/Layout/AvoidFloats.hs
bsd-3-clause
12,080
0
22
3,353
3,107
1,637
1,470
140
2
{-# LANGUAGE ForeignFunctionInterface #-} -- | -- Module : Crypto.Hash.BLAKE2 -- Copyright : (c) Austin Seipp 2013 -- License : BSD3 -- -- Maintainer : aseipp@pobox.com -- Stability : experimental -- Portability : portable -- -- BLAKE2b\/2bp and BLAKE2s\/2sp hashes. -- -- For more information visit <https...
thoughtpolice/hs-nacl
src/Crypto/Hash/BLAKE2.hs
bsd-3-clause
4,630
0
19
938
550
338
212
44
2
newtype State s a = State { runState :: s -> (a, s) } newtype Reader r a = Reader { runReader :: r -> a } -- isomorphism type Iso a b = (a -> b, b -> a) newtype Sum a = Sum { getSum :: a } sumIsIsomorphicWithItsContents :: Iso a (Sum a) sumIsIsomorphicWithItsContents = (Sum, getSum)
chengzh2008/hpffp
src/ch23-State/start.hs
bsd-3-clause
288
0
8
64
109
70
39
6
1
{-| Module : Idris.Elab.Provider Description : Code to elaborate type providers. Copyright : License : BSD3 Maintainer : The Idris Community. -} {-# LANGUAGE PatternGuards #-} module Idris.Elab.Provider(elabProvider) where import Idris.AbsSyntax import Idris.Core.Evaluate import Idris.Core.Execute import I...
uuhan/Idris-dev
src/Idris/Elab/Provider.hs
bsd-3-clause
3,982
0
20
1,336
966
483
483
67
5
module Experiments.Concurrency.SimpleSTM where import Control.Applicative import Control.Concurrent import Control.Concurrent.STM import Control.Monad import Data.Monoid threadRuns :: IO () -> Int -> IO ThreadId threadRuns handler times = forkIO $ replicateM_ times h...
rumblesan/haskell-experiments
src/Experiments/Concurrency/SimpleSTM.hs
bsd-3-clause
2,207
0
14
504
733
350
383
61
1
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE NoMonomorphismRestriction #-} ------------------------------------------------------------------------------------- -- Parsing the SVG path command, see <http://www.w3.org/TR/SVG/paths.html#PathData> -----------------------------------------------------------------------...
diagrams/diagrams-input
src/Diagrams/SVG/Path.hs
bsd-3-clause
14,820
0
19
3,908
6,263
3,434
2,829
211
8
{-# LANGUAGE DefaultSignatures, EmptyDataDecls, FlexibleInstances, FunctionalDependencies, KindSignatures, OverlappingInstances, ScopedTypeVariables, TypeOperators, UndecidableInstances, ViewPatterns, NamedFieldPuns, FlexibleContexts, PatternGuards, RecordWildCards #-} {-# OPTIONS_GHC -fno-warn-orphans ...
lykahb/aeson
Data/Aeson/Types/Generic.hs
bsd-3-clause
30,433
0
18
8,260
7,530
3,853
3,677
-1
-1
module Control.ConstraintClasses.KeyFoldable ( -- * Constraint KeyFoldable CKeyFoldable (..) ) where import Control.ConstraintClasses.Domain import Control.ConstraintClasses.Key import Control.ConstraintClasses.Foldable import Data.Key -- base import Data.Functor.Product import Data.Functor.Sum import Data...
guaraqe/constraint-classes
src/Control/ConstraintClasses/KeyFoldable.hs
bsd-3-clause
2,122
0
12
356
504
284
220
47
0
{- Data/Metrology/Units.hs The units Package Copyright (c) 2013 Richard Eisenberg eir@cis.upenn.edu This file defines the class Unit, which is needed for user-defined units. -} {-# LANGUAGE TypeFamilies, DataKinds, DefaultSignatures, MultiParamTypeClasses, ConstraintKinds, UndecidableInst...
hesiod/units
Data/Metrology/Units.hs
bsd-3-clause
6,448
1
12
1,229
863
491
372
-1
-1
{-# LANGUAGE DeriveGeneric #-} module Config ( getConfig , JsonResponse(..) , AppName(..) , StatusKey(..) , SSAppMonitor(..) , MSAppMonitor(..) , MyConfig(..) , AppConfig(..)) where import Control.Applicative import qualified Data.ByteString.Lazy.Internal as BS import qualified Data.Text.Internal as TI import Data.Yam...
blischalk/servermon
src/Config.hs
bsd-3-clause
1,893
0
10
546
465
269
196
54
1
{-# language CPP #-} -- | = Name -- -- VK_NV_cooperative_matrix - device extension -- -- == VK_NV_cooperative_matrix -- -- [__Name String__] -- @VK_NV_cooperative_matrix@ -- -- [__Extension Type__] -- Device extension -- -- [__Registered Extension Number__] -- 250 -- -- [__Revision__] -- 1 -- -- [__Exte...
expipiplus1/vulkan
src/Vulkan/Extensions/VK_NV_cooperative_matrix.hs
bsd-3-clause
32,143
2
19
6,139
4,646
2,731
1,915
-1
-1
{-# OPTIONS_GHC -fno-warn-unused-binds #-} {-# LANGUAGE ConstraintKinds , EmptyDataDecls , FlexibleContexts , FlexibleInstances , DeriveGeneric , GADTs , GeneralizedNewtypeDeriving , MultiParamTypeClasses , OverloadedStrings ...
prowdsponsor/esqueleto
test/Test.hs
bsd-3-clause
53,594
0
36
22,840
15,164
7,426
7,738
1,057
2
import Control.Monad import Data.List import Data.Ord import Results import System.Environment import Text.Printf main :: IO () main = do args <- getArgs forM_ args $ \file -> do printf "%-10s %10s %10s\n" ("Division" :: String) ("Mean" :: String) ("Std Dev" :: String) printf "%-10s %10s %10s\n" ("--------...
mfine/nfl-divisions-power-rankings
main/Simple.hs
bsd-3-clause
524
0
16
104
192
100
92
15
1
{-# OPTIONS_GHC -fno-warn-orphans #-} {- | Module : Data.Graph.Inductive.Arbitrary Description : Arbitrary definition for fgl graphs Copyright : (c) Ivan Lazar Miljenovic License : BSD3 Maintainer : Ivan.Miljenovic@gmail.com This module provides default definitions for use with QuickCheck's ...
quchen/fgl
fgl-arbitrary/Data/Graph/Inductive/Arbitrary.hs
bsd-3-clause
5,109
0
12
1,454
1,322
737
585
75
2
{-# LANGUAGE PatternGuards #-} module Ant.Graph ( Graph , grCreate , grNeighbors , grEdge , grNeighbor , grEdges , grEdgeIndices , grIndex , grSize , grRegions , grNodes , grEmpty , grBFS , grAStar , grSucc , grTest ) where import Ant...
Saulzar/Ants
Ant/Graph.hs
bsd-3-clause
4,128
3
15
1,115
1,390
761
629
101
1
{-# language DeriveDataTypeable #-} module Brainfuck.Env.SimpleEnv where import qualified Data.List import Brainfuck.Syntax import Machine.History import Autolib.ToDoc import Data.Typeable data Env = Env { left :: [ Integer ] , right :: [ Integer ] , input :: [ Integer ] , output :: [ Integer ] , c...
florianpilz/autotool
src/Brainfuck/Env/SimpleEnv.hs
gpl-2.0
3,539
2
16
1,168
1,964
1,094
870
61
9
{-# LANGUAGE BangPatterns, DeriveDataTypeable, FlexibleInstances, MultiParamTypeClasses #-} module Text.DescriptorProtos.FieldDescriptorProto.Label (Label(..)) where import Prelude ((+), (/), (.)) import qualified Prelude as Prelude' import qualified Data.Typeable as Prelude' import qualified Data.Data as Prelude' impo...
edahlgren/protocol-buffers
descriptor/src-auto-generated/Text/DescriptorProtos/FieldDescriptorProto/Label.hs
apache-2.0
2,612
0
11
402
637
347
290
55
1
{-# LANGUAGE ViewPatterns, TupleSections, RecordWildCards, ScopedTypeVariables, PatternGuards #-} module Action.Test(actionTest) where import Query import Action.CmdLine import Action.Search import Action.Server import General.Util import Input.Item import Input.Haddock import System.IO.Extra import Control.Monad im...
wolftune/hoogle
src/Action/Test.hs
bsd-3-clause
863
0
16
165
222
108
114
28
1
{-# LANGUAGE NamedFieldPuns #-} -- | The CompPipeline monad and associated ops -- -- Defined in separate module so that it can safely be imported from Hooks module Eta.Main.PipelineMonad ( CompPipeline(..), evalP , PhasePlus(..) , PipeEnv(..), PipeState(..), PipelineOutput(..) , getPipeEnv, getPipeState, setD...
rahulmutt/ghcvm
compiler/Eta/Main/PipelineMonad.hs
bsd-3-clause
4,049
0
13
969
826
472
354
63
1
{-# LANGUAGE TemplateHaskell, QuasiQuotes, MultiParamTypeClasses, FlexibleInstances, DeriveDataTypeable, ScopedTypeVariables, TypeSynonymInstances #-} module Text.VCard ( -- $doc VCard(..) , CommonName , IndividualNames(..) , VCardProperty(..) , AddrType(..) , TelType(..) , EmailType(...
GaloisInc/pads-haskell
Examples/VCard-infinite.hs
bsd-3-clause
13,180
0
10
3,913
303
178
125
37
5
module Machine.History where -- $Id$ import Autolib.ToDoc detail :: Int detail = 7 class History conf where -- | ergibt den Pfad im Berechnungsbaum, der zu der Konfiguration führt -- (in falscher reihenfolge, d. h. wurzel des baums kommt zuletzt) -- konfiguration selbst ist nicht in der liste hist...
florianpilz/autotool
src/Machine/History.hs
gpl-2.0
839
12
13
236
253
129
124
19
2
{-# LANGUAGE FlexibleContexts #-} module Test.ParserTest (runTest2, tests, parserTest, parseString) where -- module Test.ParserTest (runTests, runTest2, tests, parserTest) where -- import HN.Parser2 import Text.Parsec.Prim import Text.Parsec.Combinator import Text.Parsec.Char import Utils (packL) -- import HN.Intermed...
kayuri/HNC
Test/ParserTest.hs
lgpl-3.0
8,352
4
10
1,665
325
177
148
22
2
module Dotnet.System.StringTy where import qualified Dotnet ( Object ) import Dotnet.System.ObjectTy data String_ a type StringTy a = Object (String_ a)
FranklinChen/Hugs
dotnet/lib/Dotnet/System/StringTy.hs
bsd-3-clause
155
0
7
23
42
27
15
-1
-1
module Dotnet.System.Xml.XmlSpace where import Dotnet import qualified Dotnet.System.Enum data XmlSpace_ a type XmlSpace a = Dotnet.System.Enum.Enum (XmlSpace_ a)
alekar/hugs
dotnet/lib/Dotnet/System/Xml/XmlSpace.hs
bsd-3-clause
167
0
7
22
42
28
14
-1
-1
{-| Module : Idris.Core.WHNF Description : Reduction to Weak Head Normal Form Copyright : License : BSD3 Maintainer : The Idris Community. -} {-# LANGUAGE FlexibleContexts, PatternGuards #-} {-# OPTIONS_GHC -fwarn-incomplete-patterns #-} module Idris.Core.WHNF(whnf, whnfArgs, WEnv) where import Idris.Core...
Heather/Idris-dev
src/Idris/Core/WHNF.hs
bsd-3-clause
10,782
0
19
3,869
3,954
2,019
1,935
188
45
{-# LANGUAGE CPP, MultiParamTypeClasses, DeriveGeneric, DeriveDataTypeable #-} module Plates where #if !(MIN_VERSION_base(4,8,0)) import Control.Applicative #endif import Control.Lens import GHC.Generics import Data.Data data Expr = Var Int | Pos Expr String | Neg Expr | Add Expr Expr deriving (Eq,Ord,Show,Read,Gener...
ddssff/lens
examples/Plates.hs
bsd-3-clause
928
0
8
196
445
226
219
21
1
{-# OPTIONS -fno-warn-tabs #-} -- The above warning supression flag is a temporary kludge. -- While working on this module you are encouraged to remove it and -- detab the module (please do the detabbing in a separate patch). See -- http://hackage.haskell.org/trac/ghc/wiki/Commentary/CodingStyle#TabsvsSpaces -- fo...
mcmaniac/ghc
compiler/nativeGen/X86/Cond.hs
bsd-3-clause
1,043
12
5
219
248
142
106
43
1