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 ScopedTypeVariables, RecordWildCards #-} module Language.Haskell.GhcMod.GHCApi ( withGHC , withGHC' , initializeFlagsWithCradle , setTargetFiles , getDynamicFlags , getSystemLibDir , withDynFlags , withCmdFlags , setNoWaringFlags , setAllWaringFlags ) where import Language.Haskell...
darthdeus/ghc-mod-ng
Language/Haskell/GhcMod/GHCApi.hs
bsd-3-clause
6,789
0
14
1,356
1,563
824
739
139
1
{-# LANGUAGE OverloadedStrings #-} {-# OPTIONS_GHC -Wwarn #-} -- | For practical examples see "Qualys.Cookbook.WasAuthRecord". module Qualys.WasAuthRecord ( -- * Actions getWasAuthRecCount , runWasSearchAuthRec , getWasAuthRecDetail -- * Filters ) where import Control.Monad (joi...
ahodgen/qualys
Qualys/WasAuthRecord.hs
bsd-3-clause
1,090
0
11
239
250
132
118
25
1
module HTMLGen ( generateHTML , generateHTML' ) where import Types htmlHead, htmlFooter :: String htmlHead = "<!DOCTYPE html>\n\ \<meta charset=\"utf-8\"/>\ \<html>\n\ \ <head>\n\ \ <title>\n\ \ Generated by md2html\n\ \ </title>\n\ \ </head>\n\ \ <body>\n" htmlFooter = "</body>\n</html>" ...
ob-cs-hm-edu/compiler-md2html
src/HTMLGen.hs
bsd-3-clause
738
0
11
150
186
96
90
18
1
-- -- (c) The University of Glasgow -- module Avail ( Avails, AvailInfo(..), availsToNameSet, availsToNameEnv, availName, availNames, stableAvailCmp, gresFromAvails, gresFromAvail ) where import Name import NameEnv import NameSet import RdrName import Binary import Outputable import...
ekmett/ghc
compiler/basicTypes/Avail.hs
bsd-3-clause
4,193
0
15
1,412
906
480
426
73
2
module IRC.Data (SCM.Msg(..) ,COM.Command(..) ,SCM.parseMsg ,COM.sendCommand ,COM.loginUser ,COM.requestMembership ) where import qualified IRC.Data.ServerClientMessage as SCM import qualified IRC.Data.Command as COM
TheRedPepper/YBot
src/IRC/Data.hs
bsd-3-clause
246
0
5
49
64
43
21
9
0
{-# LANGUAGE RankNTypes #-} -- | A report showing account totals as a percent of the parent. module Penny.Pctree where import qualified Control.Lens as Lens import Control.Monad (guard, mzero) import Data.Foldable (foldl') import Data.Sequence (Seq) import qualified Data.Sequence as Seq import qualified Data.Text as X...
massysett/penny
penny/lib/Penny/Pctree.hs
bsd-3-clause
4,101
0
15
854
852
455
397
96
2
{-# OPTIONS_GHC -fno-warn-deprecations #-} {-# LANGUAGE TemplateHaskell #-} -- | This module deals with validating API changelogs and migrating -- JSON data between different versions of a schema. module Data.API.Changes ( migrateDataDump -- * Validating changelogs , validateChanges , dataMatchesA...
adinapoli/api-tools
src/Data/API/Changes.hs
bsd-3-clause
58,407
0
16
16,052
15,195
7,804
7,391
861
16
{-# LANGUAGE RankNTypes #-} -- | Verifying, aggregating and displaying binding of keys to commands. module Game.LambdaHack.Client.UI.KeyBindings ( keyHelp, okxsN ) where import Prelude () import Game.LambdaHack.Core.Prelude import qualified Data.EnumMap.Strict as EM import qualified Data.Map.Strict as M import q...
LambdaHack/LambdaHack
engine-src/Game/LambdaHack/Client/UI/KeyBindings.hs
bsd-3-clause
15,976
0
28
5,668
4,108
2,295
1,813
-1
-1
-- http://hackage.haskell.org/packages/archive/mtp/latest/doc/html/src/Foreign-Handle.html {-# LANGUAGE ForeignFunctionInterface #-} module ForeignHandle ( fdopen, fflush, fclose, handleToCFile ) where import GHC.IO.Handle (Handle, hDuplicate) import Foreign (Ptr) import Foreign.C (CInt(..), CString, CFil...
bradlarsen/hs-cudd
src/ForeignHandle.hs
bsd-3-clause
1,001
0
10
167
249
138
111
20
1
{-# OPTIONS_GHC -fno-warn-unused-do-bind #-} module SimpleLang.NanoParsec where import Control.Applicative import Control.Monad import Data.Char data Parser a = Parser {parse :: String -> [(a, String)]} runParser :: Parser a -> String -> Either String a runParser p s = case parse p s ...
AlphaMarc/WYAH
src/SimpleLang/NanoParsec.hs
bsd-3-clause
2,617
0
14
933
1,097
552
545
78
3
{-# LANGUAGE TemplateHaskell #-} {-| Module : AERN2.MPBallWithGlobalPrec Description : MPBall parametrised by a global precision Copyright : (c) Michal Konecny License : BSD3 Maintainer : mikkonecny@gmail.com Stability : experimental Portability : portable This typ...
michalkonecny/aern2
aern2-net/src/AERN2/MPBallWithGlobalPrec.hs
bsd-3-clause
2,003
2
14
395
362
218
144
-1
-1
{- Copyright James d'Arcy 2010 All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the followi...
jamesdarcy/Hastur
src/Hastur.hs
bsd-3-clause
17,930
5
22
4,206
5,111
2,418
2,693
397
4
-- | This module defines the central type class `LargeHashable` of this package. {-# LANGUAGE BangPatterns #-} {-# LANGUAGE DefaultSignatures #-} {-# LANGUAGE TypeOperators #-} {-# LANGUAGE FlexibleContexts #-} module Data.LargeHashable.Class ( LargeHashable(..), largeHash, LargeHashable'(..) ) where -...
sternenseemann/large-hashable
src/Data/LargeHashable/Class.hs
bsd-3-clause
18,029
0
16
3,492
4,682
2,402
2,280
342
2
{-# LANGUAGE CPP #-} module Happstack.Server.Internal.LogFormat ( formatTimeCombined , formatRequestCombined ) where #if MIN_VERSION_time(1,5,0) import Data.Time.Format (FormatTime(..), formatTime, defaultTimeLocale) #else import Data.Time.Format (FormatTime(..), formatTime) import System.Locale (defaultTimeL...
Happstack/happstack-server
src/Happstack/Server/Internal/LogFormat.hs
bsd-3-clause
2,153
0
13
462
217
130
87
29
1
module Turing.Machine where -- $Id$ import Machine.Class import Machine.Akzeptieren import qualified Challenger as C import qualified Machine.Acceptor.Type as A import Turing.Type import Turing.Konfiguration import Turing.Nachfolger ( folgekonfigurationen ) import Autolib.Reporter import Autolib.Reporter.Set imp...
florianpilz/autotool
src/Turing/Machine.hs
gpl-2.0
2,152
5
15
527
425
221
204
-1
-1
{-# LANGUAGE Safe #-} {-# LANGUAGE NoImplicitPrelude #-} ----------------------------------------------------------------------------- -- | -- Module : Data.Word -- Copyright : (c) The University of Glasgow 2001 -- License : BSD-style (see the file libraries/base/LICENSE) -- -- Maintainer : libraries@h...
alexander-at-github/eta
libraries/base/Data/Word.hs
bsd-3-clause
1,875
0
4
389
58
45
13
8
0
{-# LANGUAGE CPP, MagicHash #-} -- | -- Module : Data.Primitive.Internal.Compat -- Copyright : (c) Roman Leshchinskiy 2011-2012 -- License : BSD-style -- -- Maintainer : Roman Leshchinskiy <rl@cse.unsw.edu.au> -- Portability : non-portable -- -- Compatibility functions -- module Data.Primitive.Internal.Co...
fpco/primitive
Data/Primitive/Internal/Compat.hs
bsd-3-clause
671
0
5
108
78
55
23
8
1
{- GCBackend: Flounder stub generator for generic code Part of Flounder: a message passing IDL for Barrelfish Copyright (c) 2007-2010, ETH Zurich. All rights reserved. This file is distributed under the terms in the attached LICENSE file. If you do not find this file, copies can be found by wri...
linusyang/barrelfish
tools/flounder/GCBackend.hs
mit
17,499
6
18
5,927
4,456
2,353
2,103
290
2
{-# LANGUAGE MagicHash #-} import GHC.Exts hiding (fromList) import Unsafe.Coerce import Data.Sequence newtype Age = Age Int fooAge :: Seq Int -> Seq Age fooAge = fmap Age fooCoerce :: Seq Int -> Seq Age fooCoerce = fmap coerce fooUnsafeCoerce :: Seq Int -> Seq Age fooUnsafeCoerce = fmap unsafeCoerce same :: a -> b...
iu-parfunc/containers
tests-ghc/unreliable/mapcoerceseq.hs
bsd-3-clause
560
0
11
126
229
113
116
20
2
-- A Pandoc filter to use SyntaxHighlighter for Pandoc -- Code blocks in HTML output -- Matti Pastell 2011 <matti.pastell@helsinki.fi> -- More filters in https://bitbucket.org/mpastell/pandoc-filters/ -- Requires Pandoc 1.8 import Text.Pandoc import Text.Pandoc.Shared import Char(toLower) main = interact $ jsonFil...
david415/tails
wiki/src/promote/slides/Tails-SIT_conference-201206/pandoc-filters/syntaxhighlight.hs
gpl-3.0
572
0
12
120
118
66
52
10
1
{-# LANGUAGE TypeSynonymInstances, QuasiQuotes #-} module IHaskell.Display.Aeson () where import Data.Text as T import Data.ByteString.Lazy as LBS import Data.Text.Encoding as E import Data.Aeson import Data.Aeson.Encode.Pretty import Data.String.Here impo...
artuuge/IHaskell
ihaskell-display/ihaskell-aeson/IHaskell/Display/Aeson.hs
mit
614
0
11
152
129
78
51
13
0
----------------------------------------------------------------------------- -- | -- Module : XMonad.Prompt.Window -- Copyright : Devin Mullins <me@twifkak.com> -- Andrea Rossato <andrea.rossato@unibz.it> -- License : BSD-style (see LICENSE) -- -- Maintainer : Devin Mullins <me@twifkak....
pjones/xmonad-test
vendor/xmonad-contrib/XMonad/Prompt/Window.hs
bsd-2-clause
3,301
0
13
718
447
256
191
38
3
{-# LANGUAGE TemplateHaskell #-} -- See #1678 module TH where import Language.Haskell.TH -- foo = $(fail "hi") foo = $(runIO (fail "hi"))
sdiehl/ghc
testsuite/tests/th/TH_runIO.hs
bsd-3-clause
148
0
9
32
31
19
12
4
1
{-| Module : Idris.DataOpts Description : Optimisations for Idris code i.e. Forcing, detagging and collapsing. Copyright : License : BSD3 Maintainer : The Idris Community. -} {-# LANGUAGE PatternGuards #-} module Idris.DataOpts(applyOpts) where import Idris.AbsSyntax import Idris.AbsSyntaxTree import Idri...
tpsinnem/Idris-dev
src/Idris/DataOpts.hs
bsd-3-clause
4,577
0
16
1,196
1,830
902
928
81
4
module AST4ModSys where import qualified HsModule as Hs import HsModuleMaps() import HsIdent(getHSName) import qualified Ents (Ent(Ent)) import DefinedNames(DefinedNames(definedNames)) --import TypedIds (NameSpace(..)) import Relations import Names import ModSysAST import HasBaseName import Products((><)) -- added ...
kmate/HaRe
old/tools/base/Modules/AST4ModSys.hs
bsd-3-clause
3,837
0
15
999
1,250
662
588
91
4
module Front2AST where import Syntax type Name = String data Op = Plus | Mult | IntEq | IntLess data LS = Lazy | Strict deriving Eq data Pat = Pconst Integer -- { 5 } | Pvar Name -- { x } | Ptuple [Pat] -- { (p1,p2) } | Pcondata Name [Pat] -- data T1 = C1 t1 t2 \nl {C1 p1 ...
forste/haReFork
tools/interp/Front2AST.hs
bsd-3-clause
6,025
2
18
2,278
2,524
1,300
1,224
143
16
----------------------------------------------------------------------------- -- | -- Module : Distribution.Simple.LHC -- Copyright : Isaac Jones 2003-2007 -- License : BSD3 -- -- Maintainer : cabal-devel@haskell.org -- Portability : portable -- -- This is a fairly large module. It contains most of the...
kolmodin/cabal
Cabal/Distribution/Simple/LHC.hs
bsd-3-clause
32,424
0
25
9,262
7,235
3,730
3,505
571
6
{-# LANGUAGE DataKinds, PolyKinds #-} module BadTelescope where import Data.Kind data SameKind :: k -> k -> * data X a k (b :: k) (c :: SameKind a b)
sdiehl/ghc
testsuite/tests/dependent/should_fail/BadTelescope.hs
bsd-3-clause
154
0
6
34
48
31
17
-1
-1
-- Trac #1608 module ShouldFail where newtype Ego a = Ego a deriving (Ord) f :: Ord a => Ego a -> Ego a -> Bool f e1 e2 = e1 < e2
urbanslug/ghc
testsuite/tests/deriving/should_fail/drvfail012.hs
bsd-3-clause
133
0
8
36
61
33
28
4
1
{-# LANGUAGE OverloadedStrings #-} {-| Module : Deadlock.Runner Description : Main module for deadlock and reachability analysis. Copyright : (c) Freek Verbeek, Sanne Wouda 2015-2016, Tessa Belder 2016 This module uses command line input to execute the smt and nuxmv deadlock algorithms. -} module Deadlock.Runn...
julienschmaltz/madl
src/Deadlock/Runner.hs
mit
14,261
0
26
4,804
3,236
1,696
1,540
199
21
{-# LANGUAGE BangPatterns, DataKinds, DeriveDataTypeable, FlexibleInstances, MultiParamTypeClasses #-} {-# OPTIONS_GHC -fno-warn-unused-imports #-} module Hadoop.Protos.QJournalProtocolProtos.DiscardSegmentsResponseProto (DiscardSegmentsResponseProto(..)) where import Prelude ((+), (/)) import qualified Prelude as Prel...
alexbiehl/hoop
hadoop-protos/src/Hadoop/Protos/QJournalProtocolProtos/DiscardSegmentsResponseProto.hs
mit
3,013
1
16
538
554
291
263
53
0
{-| Module: Flaw.Graphics.Canvas Description: 2D painting. License: MIT -} {-# LANGUAGE PatternSynonyms #-} module Flaw.Graphics.Canvas ( Canvas , initCanvas , drawBorderedRectangle , drawCubicBezierCurve ) where import qualified Data.ByteString.Unsafe as B import Data.Default import Foreign.Marshal.Array ...
quyse/flaw
flaw-canvas/Flaw/Graphics/Canvas.hs
mit
8,918
96
21
2,186
2,429
1,328
1,101
213
11
-------------------------------------------------------------------------------- -- Summation of primes -- Problem 10 -- The sum of the primes below 10 is 2 + 3 + 5 + 7 = 17. -- Find the sum of all the primes below two million. -------------------------------------------------------------------------------- import Da...
bertdouglas/euler-haskell
001-050/10a.hs
mit
507
0
10
105
90
49
41
10
2
{-# LANGUAGE NoImplicitPrelude #-} -- {-# LANGUAGE #-} {-| -} module Commands.Spiros.Server.Invoke where -- import Commands.Extra (displayAddress) import Data.Text.Lazy (Text) import qualified Data.Text.Lazy as T import qualified "uglymemo" Data.MemoUgly as Ugly import qualified "MemoTrie" Data.MemoTrie...
sboosali/commands
commands-spiros/config/Commands/Spiros/Server/Invoke.hs
mit
3,169
0
11
636
582
336
246
-1
-1
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE StrictData #-} {-# LANGUAGE TupleSections #-} -- | http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-elb-accessloggingpolicy.html module Stratosphere.ResourceProperties.ElasticLoadBalancingLoadBalancerAcces...
frontrowed/stratosphere
library-gen/Stratosphere/ResourceProperties/ElasticLoadBalancingLoadBalancerAccessLoggingPolicy.hs
mit
4,127
0
13
318
449
255
194
39
1
module Main where import Lib import Control.Monad.State main :: IO () main = do putStrLn "Hello world!"
Jinxit/firestone
app/Main.hs
mit
111
0
7
24
34
19
15
6
1
{-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE GeneralizedNewtypeDeriving #-} {-# LANGUAGE MultiParamTypeClasses #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE...
houli/distributed-file-system
dfs-shared/src/Models.hs
mit
2,223
0
8
445
364
219
145
-1
-1
{-# LANGUAGE OverloadedStrings #-} {-| Module: Octobunce.Parser Description: Parse IRC messages Copyright: © 2014 Josh Holland License: MIT Maintainer: josh@inv.alid.pw Stability: experimental Portability: any -} module Octobunce.Parser ( ircMessage ) where import Data.Attoparsec.ByteS...
jshholland/octobunce
src/Octobunce/Parser.hs
mit
4,630
0
13
1,502
1,021
501
520
110
46
module Unscramble.Download ( fetch ) where import Control.Monad import qualified Data.Conduit as C import Data.Conduit.Binary (sinkFile) import Network.HTTP.Conduit import System.Directory import System.FilePath import System.IO import Unscramble....
pikajude/unscramble
src/Unscramble/Download.hs
mit
1,075
0
17
394
272
130
142
31
1
{-# OPTIONS_GHC -F -pgmF htfpp #-} import Prelude import Test.Framework import qualified Cases main = htfMain $ htf_thisModulesTests test_spinalizeCamelCase = do assertEqual "abc-def" $ Cases.spinalize "abcDef" assertEqual "abc-def" $ Cases.spinalize "abcDEF" assertEqual "my-html-processor" $ Cases.spinalize ...
nikita-volkov/cases
api-tests/APITests.hs
mit
1,801
0
9
249
443
191
252
39
1
module Main ( main ) where import qualified JSaddleHello (main) import Language.Javascript.JSaddle.WKWebView (run) main = run JSaddleHello.main
ghcjs/jsaddle-hello
src-exe/WKWebViewMain.hs
mit
146
0
6
19
40
25
15
4
1
{-# LANGUAGE MultiParamTypeClasses, FunctionalDependencies #-} module Data.API.LinkedIn.QueryResponsePair ( QueryResponsePair(..) ) where class QueryResponsePair q r | q -> r where
whittle/linkedin-api
Data/API/LinkedIn/QueryResponsePair.hs
mit
196
0
5
35
35
22
13
-1
-1
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE StrictData #-} {-# LANGUAGE TupleSections #-} -- | http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-guardduty-threatintelset.html module Stratosphere.Resources.GuardDutyThreatIntelSet where import Stratosphere....
frontrowed/stratosphere
library-gen/Stratosphere/Resources/GuardDutyThreatIntelSet.hs
mit
3,645
0
15
429
552
313
239
48
1
module Main ( main ) where import qualified JSaddleHello (main) import Language.Javascript.JSaddle.WebKitGTK (run) main = run JSaddleHello.main
ghcjs/jsaddle-hello
src-exe/WebKitGTKMain.hs
mit
146
0
6
19
40
25
15
4
1
module Tema_17d_ConjuntoPropiedades_Spec (main, spec) where import Tema_17.ConjuntoPropiedades import Test.Hspec import Test.QuickCheck main :: IO () main = hspec spec spec :: Spec spec = do describe "ConjuntoPropiedades" $ do it "p1" $ property prop_independencia_repeticiones it "p2" $ propert...
jaalonso/I1M-Cod-Temas
test/Tema_17d_ConjuntoPropiedades_Spec.hs
gpl-2.0
657
0
11
154
169
76
93
25
1
module Flowskell.Display ( reshapeHandler, displayHandler, initDisplay ) where import Control.Monad (when, forM_) import Data.Maybe (isJust, fromJust) import Data.IORef import Graphics.UI.GLUT hiding (Bool, Float) import Graphics.Rendering.GLU.Raw import Graphics.Rendering.OpenGL hiding (Bool, Float) import Gra...
lordi/flowskell
src/Flowskell/Display.hs
gpl-2.0
9,275
0
23
2,017
2,885
1,362
1,523
96
1
----------------------------------------------------------------------------- -- | -- Module : Language.K.Core.Pretty.KMode -- Copyright : (c) David Lazar, 2011 -- License : MIT -- -- Maintainer : lazar6@illinois.edu -- Stability : experimental -- Portability : unknown -- -- Convert (pretty print) a...
bakineggs/k-framework
tools/language-k/Language/K/Core/Pretty/KMode.hs
gpl-2.0
1,525
0
10
325
361
194
167
24
2
-- Copyright 2016 Peter Beard -- Distributed under the GNU GPL v2. For full terms, see the LICENSE file. -- -- Problem #4 -- -- A palindromic number reads the same both ways. The largest palindrome made -- from the product of two 2-digit numbers is 9009 = 91 × 99. -- -- Find the largest palindrome made from the produc...
PeterBeard/project-euler
haskell/src/problem-004.hs
gpl-2.0
1,040
0
12
210
242
128
114
12
1
{-# LANGUAGE GeneralizedNewtypeDeriving, FlexibleInstances #-} module Maps.DataType ( Contextable, DataSet(..), Context(..), StvOrdinal, StvNominal, StvRatio, RetHue, hue, RetLightless, lightless, RetSize, size', generateDataset, generateRelationset, dsToNominal, dsTransform, compositeDs ) where imp...
sc14lga/Maps
src/Maps/DataType.hs
gpl-2.0
11,873
52
16
2,199
2,708
1,499
1,209
132
1
{- | Module : $Header$ Description : hets server queries Copyright : (c) Christian Maeder, DFKI GmbH 2010 License : GPLv2 or higher, see LICENSE.txt Maintainer : Christian.Maeder@dfki.de Stability : provisional Portability : non-portable (via imports) query strings -} module PGIP.Query where {-...
nevrenato/Hets_Fork
PGIP/Query.hs
gpl-2.0
10,907
0
28
3,281
3,399
1,798
1,601
215
12
import System.Environment import System.Exit import Distribution.Simple main :: IO () main = do args <- getArgs case args of [prefix, pkgdb] -> do defaultMainArgs ["configure", "--user", "--libdir=" ++ prefix, "--package-db=" ++ pkgdb] ...
GDCN/GDCN
GDCN_proj/TaskBuilder/src/main/haskell/gdcn-trusted/Setup.hs
gpl-3.0
613
0
14
250
128
63
65
16
2
{-# LANGUAGE DeriveDataTypeable #-} module Main where import Rendering import System.Console.CmdArgs data CommitBook = CommitBook { width :: Int, height :: Int, files :: [String] } deriving (Show, Data, Typeable) options = CommitBook { width = 3180, height = 2382, ...
bneijt/commitbook
src/Main.hs
gpl-3.0
475
0
9
133
137
78
59
16
1
{-# LANGUAGE DataKinds #-} {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE NoImplicitPrelude #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE TypeOperators ...
rueshyna/gogol
gogol-analytics/gen/Network/Google/Resource/Analytics/Management/Experiments/Delete.hs
mpl-2.0
4,524
0
19
1,059
551
326
225
90
1
{-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE NoImplicitPrelude #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} {-# OPTIONS_GHC -fno-warn-unused-binds #-} {-# OPTIONS_GHC -fno-warn-unused-imports #-} -- | -- Module : Network.Google.Container.T...
rueshyna/gogol
gogol-container/gen/Network/Google/Container/Types/Product.hs
mpl-2.0
69,003
0
38
16,414
11,521
6,690
4,831
1,279
1
{-# LANGUAGE DataKinds #-} {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE NoImplicitPrelude #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE TypeOperators ...
brendanhay/gogol
gogol-serviceusage/gen/Network/Google/Resource/ServiceUsage/Services/Disable.hs
mpl-2.0
5,694
0
16
1,301
792
467
325
112
1
-- Main.hs -- Initiates Mancala game import Types import Board import Rules import Data.List(elemIndex) showBoard :: Board -> String showBoard (s1, s2) = " " ++ playerBBoard ++ " \n " ++ show (last(s2)) ++ " " ++ replicate ((length s1 - 1) * 8) '-' ++ " " ++ show (last(s1)) ++ " \n" ++ " " ++ playerABoard ...
julianalucena/mancala
Main.hs
lgpl-3.0
1,832
0
18
481
683
338
345
39
5
module Data.TagSet where import Data.Set as Set import Data.Tag import Data.Text (Text) type TagSet = Set Tag tagset :: [Tag] -> TagSet tagset = fromList tags :: TagSet -> [Tag] tags = toList keys :: TagSet -> [Text] keys = toList . Set.map tagKey vals :: TagSet -> [Text] vals = toList . Set.map tagVal hasKey ::...
bflyblue/tag
Data/TagSet.hs
unlicense
465
0
8
92
191
107
84
17
1
import Control.Monad import Data.Char {- main = forever $ do l <- getLine putStrLn $ map toUpper l -} main = do -- getContents :: IO String -- getContents is lazy - stops when it encounters the EOF character contents <- getContents -- putStr $ map toUpper contents putStr (shortLinesOnly contents) short...
alexliew/learn_you_a_haskell
code/shortlinesonly.hs
unlicense
420
0
11
86
79
42
37
7
1
{-# LANGUAGE DeriveDataTypeable, TypeFamilies, TypeOperators, StandaloneDeriving, FlexibleContexts #-} -- Workaround {-# LANGUAGE CPP, UndecidableInstances #-} module Main where import Flow import Flow.Builder import Flow.Kernel import Flow.Vector import Control.Monad import Data.Typeable -- --------...
SKA-ScienceDataProcessor/RC
MS6/programs/imaging.hs
apache-2.0
11,921
0
15
2,430
3,182
1,578
1,604
-1
-1
module Bankotrav.Counting (nPossibleBoards) where import Bankotrav.Types import Bankotrav.Base nPossibleBoards :: BoardIncomplete -> Int nPossibleBoards bi = sum $ map boardPermPossibilities perms where perms = filter (boardCanEndInPerm bi) $ concatMap boardKindPermutations $ filter...
Athas/banko
bankotrav/src/Bankotrav/Counting.hs
bsd-2-clause
1,109
0
18
390
384
202
182
23
5
{-# LANGUAGE BangPatterns #-} {-# LANGUAGE CPP #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE TypeFamilies #-} {-# OPTIONS_GHC -Wall -fno-warn-orphans #-} ----------------------------------------------------------...
kfish/zoom-cache
Data/ZoomCache/Numeric/Word.hs
bsd-2-clause
20,909
0
12
5,594
1,987
1,183
804
284
1
-- http://www.codewars.com/kata/51fd6bc82bc150b28e0000ce module Codewars.Oddities where noOdds :: Integral n => [n] -> [n] noOdds = filter even
Bodigrim/katas
src/haskell/7-No-oddities-here.hs
bsd-2-clause
144
0
7
17
37
21
16
3
1
{-# LANGUAGE LambdaCase, NamedFieldPuns, ScopedTypeVariables #-} module Mote.LoadFile ( loadFile ) where import ErrUtils (pprErrMsgBag) import Exception import GHC import GhcMonad import HscTypes (srcErrorMessages) import Out...
imeckler/mote
Mote/LoadFile.hs
bsd-3-clause
4,515
0
23
1,308
1,163
600
563
91
6
{-# LANGUAGE OverloadedStrings #-} module New where import Control.Remote.Monad.Fresh import Control.Remote.Monad.JSON.Debug import Control.Remote.Monad.JSON (Args(..), SendAPI(..)) import qualified Data.Text as Text import Data.Aeson import Control.Remote.Monad.JSON.Client testme...
ku-fpg/remote-json
remote-json-test/New.hs
bsd-3-clause
965
0
16
222
323
160
163
26
1
{-# LANGUAGE OverloadedStrings #-} module Dhall.Csv.Util (encodeCsvDefault, decodeCsvDefault) where import Data.Csv (NamedRecord, Record) import Data.List (sort) import Data.Text (Text) import qualified Data.ByteString.Lazy as ByteString import qualified Data.ByteString.Lazy.Char8 as ByteString.Char8 import q...
Gabriel439/Haskell-Dhall-Library
dhall-csv/src/Dhall/Csv/Util.hs
bsd-3-clause
1,820
0
12
314
473
264
209
32
2
-- | These graph traversal functions mirror the ones in Cabal, but work with -- the more complete (and fine-grained) set of dependencies provided by -- PackageFixedDeps rather than only the library dependencies provided by -- PackageInstalled. {-# LANGUAGE ScopedTypeVariables #-} {-# LANGUAGE CPP #-} module Distributio...
seereason/cabal
cabal-install/Distribution/Client/PlanIndex.hs
bsd-3-clause
12,105
0
16
2,959
1,981
1,111
870
154
5
{-# LANGUAGE NoImplicitPrelude , DataKinds , TypeOperators , TypeFamilies , ScopedTypeVariables , FlexibleContexts #-} {-# OPTIONS_GHC -Wall -fwarn-tabs #-} module Tests.RoundTrip where import Prelude ((.), ($), asTypeOf) import qualified Data...
zaxtax/hakaru
haskell/Tests/RoundTrip.hs
bsd-3-clause
57,638
0
117
26,231
22,256
11,759
10,497
1,155
1
{-# LANGUAGE CPP #-} {-# LANGUAGE BangPatterns #-} {-# LANGUAGE PatternGuards #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE MultiParamTypeClasses #-} #include "lens-common.h" ----------------------------------------------------------------------------- -- | -- Module : Control.Lens.Internal.Deque -- Copyri...
ddssff/lens
src/Control/Lens/Internal/Deque.hs
bsd-3-clause
5,620
0
16
1,363
2,027
1,066
961
142
1
{-# language CPP #-} -- No documentation found for Chapter "PipelineMultisampleStateCreateFlags" module Vulkan.Core10.Enums.PipelineMultisampleStateCreateFlags (PipelineMultisampleStateCreateFlags(..)) where import Vulkan.Internal.Utils (enumReadPrec) import Vulkan.Internal.Utils (enumShowsPrec) import GHC.Show (show...
expipiplus1/vulkan
src/Vulkan/Core10/Enums/PipelineMultisampleStateCreateFlags.hs
bsd-3-clause
2,286
0
10
360
305
184
121
-1
-1
module ShooterSubFileDownload ( downloadSubFiles ) where import ShooterSubQueryResult import Network.URL import Network.URI import Network.HTTP import Network.HTTP.Headers import Network.Stream import Data.List import System.IO import Control.Monad import Data.Maybe import System.FilePath.Posix import qualifie...
chainone/HSub
src/ShooterSubFileDownload.hs
bsd-3-clause
2,088
1
14
429
605
300
305
41
2
{-# LANGUAGE TemplateHaskell, QuasiQuotes, ScopedTypeVariables #-} module Network.AWS.Config ( AWSSetup(..) , loadSetupFromFile ) where import Data.ByteString (ByteString) import qualified Data.ByteString as BS import Text.Config import Text.Parsec (parse) mkConfig "configParser" [config| AWSSetup acc...
IanConnolly/aws-service-api
src/Network/AWS/Config.hs
bsd-3-clause
671
0
11
163
139
75
64
15
2
{-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE QuasiQuotes #-} {-# LANGUAGE TypeOperators #-} {-# LANGUAGE DataKinds #-} {-# OPTIONS_GHC -fno-warn-orphans #-} module SizeOf where import Ivory.Language [ivory| struct foo { f1 :: Stored Uint8 ; f2 :: Stored Uint32 } |] test :: Def ('[] ':-> Uint8) test = ...
GaloisInc/ivory
ivory-examples/examples/SizeOf.hs
bsd-3-clause
493
0
16
95
125
68
57
14
1
{-# LANGUAGE CPP #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE Rank2Types #-} #if __GLASGOW_HASKELL__ >= 702 && __GLASGOW_HASKELL__ < 710 {-# LANGUAGE Trustworthy #-} #endif ------------------------------------------------------------------------------------------- -- | -- Copyright : 2008-2013 Edward Kmett -- License : BSD...
xuwei-k/kan-extensions
src/Data/Functor/Kan/Lan.hs
bsd-3-clause
3,657
0
13
706
1,015
542
473
58
1
{-# LANGUAGE GeneralizedNewtypeDeriving, FlexibleInstances, FlexibleContexts, MultiParamTypeClasses, PatternGuards, TypeSynonymInstances, CPP #-} {-# OPTIONS_GHC -Wall #-} -- |This is where we do stuff. module System.Console.ShSh.Shell ( Shell, ShellT, ...
shicks/shsh
System/Console/ShSh/Shell.hs
bsd-3-clause
30,909
0
21
11,243
7,865
4,047
3,818
450
4
module Network.HTTP2.Priority.Queue ( Precedence(..) , TPriorityQueue , new , isEmpty , enqueue , dequeue , delete ) where import Control.Concurrent.STM import Network.HTTP2.Priority.PSQ (PriorityQueue, Key, Precedence(..)) import qualified Network.HTTP2.Priority.PSQ as Q ---------------------------...
kazu-yamamoto/http2
Network/HTTP2/Priority/Queue.hs
bsd-3-clause
1,128
0
13
229
424
222
202
32
2
{-# LANGUAGE MultiParamTypeClasses, FlexibleInstances, PatternGuards #-} {- Implements a proof state, some primitive tactics for manipulating proofs, and some high level commands for introducing new theorems, evaluation/checking inside the proof system, etc. --} module Core.ProofState(ProofState(..), newProof, ...
christiaanb/Idris-dev
src/Core/ProofState.hs
bsd-3-clause
31,900
3
27
13,183
12,166
6,087
6,079
642
30
{-# LANGUAGE OverloadedStrings #-} import Prelude hiding (div) import Clay -------------------------------------------------------------------------------- defaultStyle :: Css defaultStyle = do body ? do color black fontSize (px 16) margin 0 auto 0 auto width (px 600) div # "#heade...
bmjames/hakyll-sandbox
css/default.hs
bsd-3-clause
1,325
0
12
399
465
202
263
46
1
{-# LANGUAGE OverloadedStrings, DeriveGeneric, ScopedTypeVariables, NoImplicitPrelude, QuasiQuotes, GeneralizedNewtypeDeriving #-} {-# OPTIONS_GHC -fno-warn-unused-binds -fno-warn-unused-matches #-} ----------------------------------------------------------------------------- -- | -- Module : NeoParodyInterface...
stephenjbarr/parody-bot
src/NeoParodyInterface.hs
bsd-3-clause
12,629
0
16
3,281
2,212
1,170
1,042
-1
-1
module VisualiseAst where import FPPrac import Parser import RoseTree vis (AstProg dcl cs) = RoseNode ("Prog") [visDecl dcl, visCStmnt cs] visDecl (AstVar ids) = RoseNode ("Decl") [RoseNode ("Var") (visVars ids)] where visVars [] = [] visVars (x:xs) = (visIdentifier x) : (visVars xs) visCStmnt (As...
tscheepers/Simple-Compiler
VisualiseAst.hs
bsd-3-clause
2,411
0
9
383
1,048
528
520
37
2
module TAPL.Alex ( AlexInput , alexInputPrevChar , alexGetByte ) where import Data.Bits (shiftR, (.&.)) import Data.Char (ord) import Data.Word (Word8) utf8Encode :: Char -> [Word8] utf8Encode = map fromIntegral . go . ord where go oc | oc <= 0x7f = [ oc ] | oc <= 0x7ff = [ 0xc0 + (oc `shiftR` 6) ...
foreverbell/unlimited-plt-toys
tapl/tapl-base/TAPL/Alex.hs
bsd-3-clause
1,269
0
13
497
482
278
204
30
1
module PureSpec (spec) where import Test.Hspec import Test.Hspec.QuickCheck (prop) import Numeric.Search.Bounded as B import Numeric.Search.Integer as I import Numeric.Search.Range spec :: Spec spec = do describe "Integer search" $ do prop "finds n when search for (>= n)" $ \n -> I.search (>= n)...
nushio3/binary-search
test/PureSpec.hs
bsd-3-clause
1,905
0
17
512
608
315
293
36
4
module Main where import Inactive import Graphics.UI.FLTK.LowLevel.FLTKHS import qualified Graphics.UI.FLTK.LowLevel.FL as FL import Graphics.UI.FLTK.LowLevel.Fl_Types import Graphics.UI.FLTK.LowLevel.Fl_Enumerations main :: IO () main = do w <- make_window showWidget w _ <- FL.run return ()
deech/fltkhs-fluid-examples
src/fluid-inactive.hs
mit
302
0
8
42
87
52
35
12
1
module ExprLetShadowVar where main :: Int main = let { x :: a; x = x main } in let { x :: Int; x = 1 } in x
roberth/uu-helium
test/staticwarnings/ExprLetShadowVar.hs
gpl-3.0
110
0
10
32
55
32
23
3
1
{-# LANGUAGE DataKinds #-} {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE GeneralizedNewtypeDeriving #-} {-# LANGUAGE LambdaCase #-} {-# LANGUAGE NoImplicitPrelude #-} {-# LANGUAGE OverloadedStrings #-} {-# L...
romanb/amazonka
amazonka-opsworks/gen/Network/AWS/OpsWorks/RebootInstance.hs
mpl-2.0
3,386
0
9
681
360
221
139
48
1
----------------------------------------------------------------------------- -- | -- Module : Control.Monad.Indexed.State -- Copyright : (C) 2008 Edward Kmett -- License : BSD-style (see the file LICENSE) -- -- Maintainer : Edward Kmett <ekmett@gmail.com> -- Stability : experimental -- Portability ...
urska19/MFP---Samodejno-racunanje-dvosmernih-preslikav
Control/Monad/Indexed/State.hs
apache-2.0
4,936
6
18
1,017
2,030
1,069
961
-1
-1
module GramLab.Morfette.Evaluation ( accuracy , tokenAccuracy , sentenceAccuracy , showAccuracy ) where import GramLab.Morfette.Token import Data.Maybe import GramLab.Utils (lowerc...
bitemyapp/morfette
src/GramLab/Morfette/Evaluation.hs
bsd-2-clause
3,518
0
17
1,555
1,082
576
506
55
2
{-# LANGUAGE TypeFamilies #-} -- | -- Module: -- Data.FastMutableIntMap -- Description: -- A mutable version of 'IntMap' module Data.FastMutableIntMap ( FastMutableIntMap , new , newEmpty , insert , isEmpty , getFrozenAndClear , size , applyPatch , PatchIntMap (..) , traverseIntMapPatchWithKey ...
reflex-frp/reflex
src/Data/FastMutableIntMap.hs
bsd-3-clause
3,247
0
13
562
808
418
390
60
1
module PTS.Syntax.Telescope ( Telescope , foldTelescope ) where import PTS.Syntax.Names type Telescope t = [([Name], t)] -- | Desugar a telescope in a binder with multiple arguments like this: -- -- > lambda (x1 : e1) (x2 x3 : e2) . e -- -- to a series of nested single argument binders: -- -- > lambda x1 : e1 ...
Blaisorblade/pts
src-lib/PTS/Syntax/Telescope.hs
bsd-3-clause
617
0
10
134
192
111
81
9
1
-- {-# OPTIONS_GHC -fno-warn-redundant-constraints #-} {-# LANGUAGE MultiParamTypeClasses, FlexibleInstances, UndecidableInstances #-} -- Instances compile fine but instance selection loops in GHC 6.2. -- try: :t foo (T1a 1) -- This is essentially the same as LoopOfTheDay2.hs -- but with the innocent (?) ...
rahulmutt/ghcvm
tests/suite/typecheck/compile/LoopOfTheDay3.hs
bsd-3-clause
676
0
9
177
179
91
88
-1
-1
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE TemplateHaskell #-} module Ros.Std_msgs.Header where import qualified Prelude as P import Prelude ((.), (+), (*)) import qualified Data.Typeable as T import Control.Applicative import Ros.Internal.RosBinar...
acowley/roshask
msgs/Std_msgs/Ros/Std_msgs/Header.hs
bsd-3-clause
1,086
1
10
208
295
175
120
29
0
{-# LANGUAGE CPP #-} {-# LANGUAGE DeriveDataTypeable #-} -- | A full tutorial for this module is available on FP School of Haskell: -- <https://www.fpcomplete.com/user/snoyberg/library-documentation/data-conduit-process>. -- -- Note that, while the tutorial covers @Data.Streaming.Process@, this module is -- the basis o...
phadej/streaming-commons
Data/Streaming/Process.hs
mit
7,583
0
14
1,840
1,216
692
524
111
2
{-# LANGUAGE Trustworthy #-} {-# LANGUAGE CPP , NoImplicitPrelude , RecordWildCards , BangPatterns , NondecreasingIndentation , MagicHash #-} {-# OPTIONS_GHC -Wno-name-shadowing #-} {-# OPTIONS_GHC -Wno-unused-matches #-} {-# OPTIONS_HADDOCK hide #-} -----------...
oldmanmike/ghc
libraries/base/GHC/IO/Handle/Text.hs
bsd-3-clause
38,272
0
26
12,015
7,733
3,946
3,787
560
7
{-# LANGUAGE MagicHash #-} {-# OPTIONS_GHC -dcore-lint #-} module Main where import GHC.Exts ( Int#, Int(I#) ) import Prelude anInt :: Int anInt = 42 anInt# :: () -> Int# anInt# = \() -> 42# anIntFromI# :: Int anIntFromI# = I# 42# thing1 :: Bool -> Int -> Int thing1 b n = if b then n else 0 thing2 :: Bool -> In...
lukemaurer/sequent-core
examples/Sizes.hs
bsd-3-clause
604
0
8
147
204
111
93
19
2
{-# LANGUAGE CPP #-} #define PLATFORM_NAME Windows #define IS_WINDOWS True #include "Include.hs"
chrisdone/path
src/Path/Windows.hs
bsd-3-clause
104
0
2
19
6
5
1
1
0
{-# OPTIONS_GHC -cpp #-} {-# LANGUAGE MagicHash #-} {-# LANGUAGE MultiParamTypeClasses, OverlappingInstances, UndecidableInstances, FunctionalDependencies, NoMonomorphismRestriction #-} {-# LANGUAGE StandaloneDeriving,DeriveDataTypeable #-} -----------------------------------------------------------------------------...
SAdams601/HaRe
old/tools/base/defs/FiniteMap1.hs
bsd-3-clause
30,876
324
25
6,339
6,313
3,357
2,956
-1
-1
module A where -- Test for refactor of remove bracket foo = (id)
RefactoringTools/HaRe
test/testdata/Simple/A.hs
bsd-3-clause
66
0
5
14
13
9
4
2
1
{-# OPTIONS_JHC -fno-prelude -fffi #-} {-# LANGUAGE ForeignFunctionInterface #-} module Unsafe.Coerce(unsafeCoerce) where foreign import primitive unsafeCoerce :: a -> b
m-alvarez/jhc
lib/haskell-extras/Unsafe/Coerce.hs
mit
171
1
5
21
25
16
9
-1
-1
module Foo () where import Language.Haskell.Liquid.Prelude -- gpp :: Monad m => m Int -> m Int gpp z = do x <- z return $ liquidAssert (x >= 0) (x + 1) gpp' z n = do x <- z n return $ liquidAssert (x >= 0) (x + 1) myabs :: Int -> Int myabs x | x >= 0 = x | otherwise = 0-x mya...
ssaavedra/liquidhaskell
tests/pos/monad5.hs
bsd-3-clause
554
0
10
189
271
134
137
17
1
-- Test trac #719 (shouldn't give the entire do block in the error message) module ShouldFail where foo = do putChar putChar 'a' putChar 'a' putChar 'a' putChar 'a' putChar 'a' putChar 'a' putChar 'a' putChar 'a' putC...
siddhanathan/ghc
testsuite/tests/typecheck/should_fail/tcfail168.hs
bsd-3-clause
1,406
0
7
729
361
124
237
61
1
{-# LANGUAGE BangPatterns #-} module Brixy.Compiler (defSettings, compile, compile_complete) where import Brixy.AST import qualified Brainfuck.Types as BF import qualified Data.Map as M import qualified Data.Set as S import Data.Int import Data.List import Data.Word import ...
EXio4/brixy
src/Brixy/Compiler.hs
mit
18,204
1
20
7,623
5,799
2,904
2,895
348
24