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 Tests.Old (tests) where
import Test.Framework (testGroup, Test )
import Test.Framework.Providers.HUnit
import Test.HUnit ( assertBool )
import System.Environment.Executable (getExecutablePath)
import System.IO ( openTempFile, stderr )
import System.Process ( runProcess, waitForProcess )
import System.FilePath (... | peter-fogg/pardoc | tests/Tests/Old.hs | gpl-2.0 | 11,672 | 0 | 20 | 3,414 | 2,961 | 1,607 | 1,354 | 220 | 5 |
module Main where
import Meisel
import Iterationsgleichungen
-- main = print (startposition 1 2)
import Graphics.Rendering.Chart.Easy
import Graphics.Rendering.Chart.Backend.Diagrams
circle :: [(Double,Double)]
circle = [ (r a * sin (a*dr),r a * cos (a*dr)) | a <- [0,0.5..360::Double] ]
where
dr = 2 * pi / 360
... | Lotterleben/meisel.hs | src/Main.hs | gpl-3.0 | 586 | 0 | 12 | 117 | 218 | 118 | 100 | 13 | 1 |
import System.IO
import System.Hardware.Serialport
import Data.Binary.Get as G
import Data.Binary.Put
import Data.Binary.Strict.BitGet as BG
import Control.Monad
import Control.Concurrent
import Data.Word
import qualified Data.ByteString as BS
import qualified Data.ByteString.Builder as BB
import Data.ByteString.Buil... | JackTheEngineer/Drone | scripts/SendBytes.hs | gpl-3.0 | 1,050 | 0 | 10 | 247 | 283 | 159 | 124 | 32 | 1 |
{-# LANGUAGE BangPatterns, OverloadedStrings #-}
-- | Code to deal with each specific type of site
--
-- Contains all the special case code that differs per site
module PasteWatch.Sites
(
checkContent,
createCounters,
createGauges,
doCheck,
getNewPastes,
getNewPastes'... | ArthurClune/pastewatch | src/PasteWatch/Sites.hs | gpl-3.0 | 8,140 | 0 | 24 | 2,515 | 1,974 | 1,025 | 949 | 144 | 7 |
module ANFIS where
import Control.Arrow
import Control.Monad
import Data.Tuple.Curry
import Data.Vector (Vector, (!))
import qualified Data.Vector as V
import Layers
import Sample
import Utility
type MembershipLayer = Vector... | mrlovre/super-memory | Pro6/src/ANFIS.hs | gpl-3.0 | 5,415 | 0 | 24 | 1,277 | 1,479 | 770 | 709 | -1 | -1 |
{-# LANGUAGE FlexibleContexts #-}
module Language.LCC.Target where
import Control.Applicative
import Control.Monad.Reader (MonadReader, asks)
import Control.Monad.Writer (MonadWriter, censor, tell)
import qualified Data.DList as DL
import Data.Text.Format
import qualified Data.Text.Lazy as T
import Data.Text.Builda... | xcv-/LCC | lib/Language/LCC/Target.hs | gpl-3.0 | 2,070 | 0 | 16 | 555 | 749 | 392 | 357 | 56 | 2 |
-- TODO: Put current client's ThreadID into mvar and kill it once new one comes
{-
A little snap server that lives at localhost that
- communicates over websockets at "localhost:PORT/ws"
- answers HTTP requests on any other localhost URL combination
-}
{-# LANGUAGE OverloadedStrings #-}
module Qui... | tepf/QuickPlot | src/QuickPlot/IPC/Server.hs | gpl-3.0 | 5,289 | 0 | 13 | 1,352 | 764 | 402 | 362 | 91 | 3 |
-- P25 Generate a random permutation of the elements of a list.
import System.Random
import Data.List
-- The obvious answer is P23.f1 (length xs) xs
-- Let's directly select a random permutation for a different implementation
f1 :: RandomGen g => [a] -> g -> [a]
f1 g xs = let (i, _) = randomR (0, total - 1) g in perm... | pavelfatin/ninety-nine | haskell/p25.hs | gpl-3.0 | 411 | 0 | 11 | 98 | 120 | 63 | 57 | 6 | 1 |
import HsTri
import qualified Data.Vector.Generic as VG
import Triangulation.PreTriangulation
-- tr_7
--tr = snd ([ tr | tr <- closedOrCensus6, numberOfTetrahedra tr > 3 ] !! 0)
tr = tr_0
ss = dds tr
ss' = quadToStandardSolSet tr (qVertexSolutions tr)
res = sscr_final ss'
main = do
-- pr (ppDDRes ss)
-- p... | DanielSchuessler/hstri | scratch-test.hs | gpl-3.0 | 503 | 0 | 9 | 106 | 83 | 48 | 35 | 10 | 1 |
{-# LANGUAGE OverloadedStrings #-}
module Html.Login where
import Prelude
import Html.Url
import Html.Common
import Text.Blaze.Html5
import qualified Text.Blaze.Html5 as H
import Text.Blaze.Html5.Attributes
import qualified Text.Blaze.Html5.Attributes as A
loginHtml :: String -> Html
loginHtml r = let login = toValue... | schell/pusher | src/Html/Login.hs | gpl-3.0 | 982 | 0 | 18 | 250 | 293 | 145 | 148 | 22 | 1 |
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE FlexibleInstances #-}
module Database.Design.Ampersand.Output.ToJSON.Concepts
(Concepts)
where
import Database.Design.Ampersand.Output.ToJSON.JSONutils
import Database.Design.Ampersand.Core.AbstractSyntaxTree
import Database.Desig... | 4ZP6Capstone2015/ampersand | src/Database/Design/Ampersand/Output/ToJSON/Concepts.hs | gpl-3.0 | 3,080 | 0 | 13 | 793 | 842 | 463 | 379 | 73 | 0 |
-- | Definition of various kinds of omega automata
module OmegaAutomata.Automata where
import qualified Data.Set as S
import Data.Graph.Inductive
import qualified Data.Map as M
import qualified Data.Bimap as B
import Data.List (groupBy, nub)
type State = Int
data Rank = Rank Int | Bot deriving (Eq, Ord, Show)
type R... | stefanjaax/omega-automata | src/OmegaAutomata/Automata.hs | gpl-3.0 | 16,093 | 0 | 23 | 6,420 | 5,571 | 2,993 | 2,578 | 244 | 5 |
{-# 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/Routes/Delete.hs | mpl-2.0 | 3,040 | 0 | 15 | 742 | 388 | 233 | 155 | 62 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-healthcare/gen/Network/Google/Resource/Healthcare/Projects/Locations/DataSets/DicomStores/SearchForInstances.hs | mpl-2.0 | 8,037 | 0 | 17 | 1,433 | 795 | 472 | 323 | 126 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-logging/gen/Network/Google/Resource/Logging/BillingAccounts/Locations/Operations/List.hs | mpl-2.0 | 7,860 | 0 | 19 | 1,691 | 984 | 575 | 409 | 145 | 1 |
{-
F.hs
2014-11 xavier.pinho.g@gmail.com
A minimal functional programming language.
-}
module F where
type Ident = String
data Expr
-- Core
= Var Ident
| App Expr Expr
| Fun Ident Expr
-- Pair
| Pair Expr Expr
| Fst Expr
| Snd Expr
-- Conditional
| IfThenElse Expr Expr Expr
-- Let/Let rec... | xavierpinho/CAM | src/F.hs | unlicense | 522 | 0 | 6 | 143 | 129 | 80 | 49 | 18 | 0 |
newtype CharList = CharList { getCharList :: [Char] } deriving(Eq, Show)
newtype Pair b a = Pair { getPair :: (a, b) }
instance Functor (Pair c) where
fmap f (Pair (x, y)) = Pair (f x, y)
| EricYT/Haskell | src/chapter-12-1.hs | apache-2.0 | 195 | 0 | 9 | 45 | 97 | 57 | 40 | 4 | 0 |
module Kernel.GPU.ScatterGrid
( prepare
, prepareHints
, createGrid
, phaseRotate
, grid
, gridHints
, degrid
, degridHints
) where
import Control.Monad
import Data.Function ( on )
import Data.List
import Data.Word
import Foreign.Storable ( sizeOf )
import Data
import Kernel.GPU.Common as CUDA
impo... | SKA-ScienceDataProcessor/RC | MS4/dna-programs/Kernel/GPU/ScatterGrid.hs | apache-2.0 | 8,670 | 0 | 23 | 2,029 | 2,466 | 1,268 | 1,198 | -1 | -1 |
module TF.Subtypes
( getDefaultSubtypes
, subtypeRelation'
, primitiveTypes
, isSubtypeOf ) where
import TF.Types
import Data.Tree
import TF.ForthTypes as FT
import qualified Data.Set as S
import Control.Lens ((^?!), dimap)
import TF.Errors
import TF.Type.StackEffect
-- pri... | sleepomeno/TForth | src/TF/Subtypes.hs | apache-2.0 | 2,087 | 0 | 15 | 496 | 646 | 344 | 302 | 40 | 1 |
module Gitlog.Utils
( split
, startsWith
, getName
, getVersion
, (.&&.)
, (<>)
) where
import Data.Monoid ( Monoid, mappend )
import Data.List ( stripPrefix )
import Data.Version ( showVersion )
import Paths_gitlog ( version )
----------------------------------------------------------------------... | kongo2002/gitlog | src/Gitlog/Utils.hs | apache-2.0 | 1,586 | 0 | 10 | 302 | 355 | 204 | 151 | 35 | 2 |
{-# LANGUAGE RankNTypes #-}
{-| You can 'deploy' a simple incrementing pipe like this:
> -- deploy.hs
>
> import Pipes
> import qualified Pipes.Prelude as P
> import Pipes.Web
>
> p :: Pipe Int Int IO r
> p = P.map (+ 1)
>
> main = withSocketsDo $ deploy HostAny "8080" p
This deploys a server that listens on por... | Gabriel439/pipes-web | src/Pipes/Web.hs | bsd-3-clause | 5,408 | 2 | 25 | 1,948 | 1,180 | 625 | 555 | 98 | 4 |
{-# LANGUAGE CPP #-}
-- -----------------------------------------------------------------------------
--
-- (c) The University of Glasgow 1994-2004
--
-- -----------------------------------------------------------------------------
module PPC.Regs (
-- squeeze functions
virtualRegSqueeze,
real... | sdiehl/ghc | compiler/nativeGen/PPC/Regs.hs | bsd-3-clause | 9,649 | 0 | 15 | 3,089 | 2,356 | 1,222 | 1,134 | 219 | 13 |
module Process.TorrentManager
( start
) where
import Control.Concurrent
import Control.Concurrent.STM
import Control.Monad.State
import Control.Monad.Reader
import BCode
import FS
import Process
import Process.StatusChan
import Process.TorrentManagerChan
import qualified Process.Tracker as Tracker
import Proc... | artems/htorr | src/Process/TorrentManager.hs | bsd-3-clause | 3,550 | 0 | 19 | 870 | 899 | 443 | 456 | 83 | 4 |
{-# LANGUAGE GADTs #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE UndecidableInstances #-}
{-# LANGUAGE MultiParamTypeClasses #-}
--
-- Copyright (c) 2009-2011, ERICSSON AB
-- All rights reserved.
--
-- Redistribution an... | emwap/feldspar-language | src/Feldspar/Core/Constructs/NoInline.hs | bsd-3-clause | 2,717 | 0 | 9 | 484 | 283 | 166 | 117 | -1 | -1 |
{-# LANGUAGE DeriveFunctor, DeriveFoldable, DeriveTraversable, GeneralizedNewtypeDeriving #-}
module Environment ( Env(..)
, empty
, lookup
, add
, addAll
, update
, union
, keys
) whe... | OliverFlecke/Funci | src/Environment.hs | bsd-3-clause | 1,207 | 0 | 10 | 362 | 539 | 283 | 256 | 31 | 1 |
{-------------------------------------------------------------------------------
Builds a WxLW model from a distributional memory by rearranging the tensor
elements into a WxLW matrix. Targets are retained and output as strings,
whereas contexts are replaced by indices.
Hadoop version. Use "-m" for mapper and "-r... | jsnajder/dsem | src/dm2dep-hadoop.hs | bsd-3-clause | 2,360 | 2 | 19 | 637 | 755 | 387 | 368 | 51 | 4 |
{-# LANGUAGE CPP, DataKinds #-}
-----------------------------------------------------------------------------
-- |
-- Module : Data.Geometry
-- Copyright : Copyright (C) 2015 Artem M. Chirkin <chirkin@arch.ethz.ch>
-- License : BSD3
--
-- Maintainer : Artem M. Chirkin <chirkin@arch.ethz.ch>
-- Stability... | achirkin/fastvec | src/Data/Geometry.hs | bsd-3-clause | 1,470 | 0 | 6 | 274 | 225 | 171 | 54 | 13 | 0 |
-- generate test enumerations
g =
let n = 256
in unwords
[ "data E" ++ show n
, "="
, intercalate " | " $ map (("N" ++) . show) [1 .. n]
, "deriving (Show,Generic,Flat)"
]
| tittoassini/flat | test/GenEnum.hs | bsd-3-clause | 243 | 1 | 10 | 109 | 72 | 37 | 35 | 7 | 1 |
{-# LANGUAGE OverloadedStrings #-}
module Bower
( install ) where
import Prelude ()
import MyLittlePrelude
import Data.Monoid ((<>))
import qualified Data.Text as Text
import System.Process (readProcessWithExitCode)
import System.Exit (ExitCode (..))
import Sys... | zudov/purescript-inspection | worker/Bower.hs | bsd-3-clause | 931 | 0 | 12 | 189 | 230 | 124 | 106 | 21 | 1 |
module Data.Leonine.Dense where
import Data.Bits
import Data.Convertible
import Data.Monoid
import qualified Data.Vector.Algorithms.Insertion as VA
import Data.Vector.Unboxed (Unbox, Vector)
import qualified Data.Vector.Unboxed as V
import qualified Dat... | thsutton/leonine | lib/Data/Leonine/Dense.hs | bsd-3-clause | 3,455 | 0 | 13 | 916 | 900 | 501 | 399 | 59 | 1 |
-- | This module exports the types used to clear fields.
module Data.Factual.Write.Clear
(
-- * Clear type
Clear(..)
-- * Required modules
, module Data.Factual.Shared.Table
) where
import Data.Factual.Write
import Data.Factual.Shared.Table
import Data.List.Utils (join)
import qualified Data.Map as M... | rudyl313/factual-haskell-driver | Data/Factual/Write/Clear.hs | bsd-3-clause | 1,143 | 0 | 11 | 326 | 211 | 128 | 83 | 18 | 0 |
{-|
Copyright : (c) Dave Laing, 2017
License : BSD3
Maintainer : dave.laing.80@gmail.com
Stability : experimental
Portability : non-portable
-}
{-# LANGUAGE ConstraintKinds #-}
module Fragment.TmLam.Rules.Term (
TmLamEvalConstraint
, tmLamEvalRules
) where
import Control.Lens (preview)
import Rules.T... | dalaing/type-systems | src/Fragment/TmLam/Rules/Term.hs | bsd-3-clause | 734 | 0 | 9 | 163 | 194 | 104 | 90 | 21 | 1 |
module RPG.Data.City
( City (..)
, Size (..)
) where
data Size = Tiny | Small | Medium | Large | Huge
data City = City
{ hasInn :: Bool
-- TODO(sandy): specialize later
, hasShop :: Bool
, size :: Size
}
| isovector/rpg-gen | src/RPG/Data/City.hs | bsd-3-clause | 240 | 0 | 8 | 79 | 70 | 46 | 24 | 8 | 0 |
{-# LANGUAGE ScopedTypeVariables #-}
{--
Copyright (c) 2006, Peng Li
2006, Stephan A. Zdancewic
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... | Tener/HaNS | src/Network/TCP/Pure.hs | bsd-3-clause | 4,308 | 0 | 16 | 902 | 747 | 422 | 325 | 66 | 2 |
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE TypeSynonymInstances #-}
module Graphics.GChart.ChartItems.Colors where
import Graphics.GChart.Types
import Graphics.GChart.ChartItems.Util
import Data.List(intercalate)
-- Chart Colors
instance ChartItem ChartColors where
set colors = updateChart $ \chart -> chart ... | deepakjois/hs-gchart | Graphics/GChart/ChartItems/Colors.hs | bsd-3-clause | 1,895 | 0 | 15 | 977 | 373 | 199 | 174 | 26 | 5 |
{-# LANGUAGE Rank2Types, NoMonomorphismRestriction, ImplicitParams, ParallelListComp, FlexibleInstances #-}
module Box(
-- * Modules
module Box.Types,
-- * Layout
atomic,
moved,movedTo,centered,padded,scaled',colored,
align,Alignment(..),
glH,glV,
(#-),(#-#),(#|),(#|#),
-- * Contruction
para,cube,... | lih/Epsilon | src/Box.hs | bsd-3-clause | 9,593 | 2 | 18 | 2,400 | 4,943 | 2,603 | 2,340 | -1 | -1 |
{-# LANGUAGE OverloadedStrings #-}
module Views.DomainList (domainListT) where
import Data.Text.Lazy (Text)
import Data.Monoid
import Text.Blaze.Html5
import qualified Text.Blaze.Html5 as H
import Text.Blaze.Html5.Attributes
import qualified Text.Blaze.Html5.Attributes as A
i... | alpmestan/spw | src/Views/DomainList.hs | bsd-3-clause | 2,193 | 0 | 30 | 916 | 520 | 247 | 273 | 48 | 1 |
{-
(c) The University of Glasgow 2006
(c) The GRASP/AQUA Project, Glasgow University, 1992-1998
\section[TcBinds]{TcBinds}
-}
{-# LANGUAGE RankNTypes, ScopedTypeVariables #-}
module ETA.TypeCheck.TcBinds ( tcLocalBinds, tcTopBinds, tcRecSelBinds,
tcHsBootSigs, tcPolyCheck,
PragFun, ... | alexander-at-github/eta | compiler/ETA/TypeCheck/TcBinds.hs | bsd-3-clause | 71,324 | 1 | 21 | 20,828 | 12,677 | 6,650 | 6,027 | 808 | 10 |
module LinearRegression where
import Util
import GradientDescent
import Numeric.LinearAlgebra
import Numeric.LinearAlgebra.Util
import Debug.Trace
-- The cost function J
-- Compute regularized cost for linear regression with multiple variables
-- computes the cost of using theta as the parameter for linear
-- regress... | thade/haskellml | src/LinearRegression.hs | bsd-3-clause | 1,738 | 0 | 16 | 456 | 525 | 278 | 247 | 28 | 1 |
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE FunctionalDependencies #-}
{-# LANGUAGE FlexibleInstances #-}
module Revelation.Point (
Point(..)
, Dim(..)
, PElemT
, ExtractPoint(..)
) where
import Revelation.Core
import Revelation.Mat
import OpenCV
import Foreign
import Foreig... | arjuncomar/revelation | Revelation/Point.hs | bsd-3-clause | 5,539 | 0 | 9 | 1,343 | 1,679 | 870 | 809 | -1 | -1 |
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
module BotCommands
( BotCmd (..)
, addNote
, readCommand
, showNew
, showOld
) where
import Control.Monad (void)
import Data.Char (isSpace)
import Data.Foldable (for_)
import Data.Text (T... | MCL1303/TaskBot | lib/BotCommands.hs | bsd-3-clause | 2,816 | 0 | 16 | 925 | 721 | 387 | 334 | 70 | 4 |
#! /usr/bin/env runhaskell
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE QuasiQuotes #-}
import Control.Applicative
import System.Process
import Control.Mo... | jfischoff/twitch | examples/doodles.hs | mit | 926 | 0 | 8 | 143 | 79 | 50 | 29 | 17 | 1 |
{-# LANGUAGE DeriveGeneric, FlexibleInstances #-}
module Beetle.UK.PropertyData where
import Data.Aeson
import Data.Aeson.Types
import GHC.Generics
import Beetle.Base
type Postcode = String
data Prices = Prices Postcode Int
data Demographics = Demographics Postcode
instance ToURL (Key Prices) where
toURL (Key k... | filopodia/open | beetle/src/Beetle/UK/PropertyData.hs | mit | 977 | 0 | 10 | 178 | 284 | 154 | 130 | 27 | 1 |
import System.Environment
import System.Directory
import System.FilePath
import qualified Data.ByteString.Lazy as B
import Control.Exception
import Data.Aeson
import Data.Aeson.Encode.Pretty
import Graphics.Gloss.Interface.IO.Game
import Level.Level
import Play.PlayState
import Play.Events
import Play.Step
import P... | beni55/pinhole | Pinhole/Main.hs | gpl-3.0 | 2,680 | 0 | 15 | 866 | 769 | 381 | 388 | 72 | 3 |
-- |
-- This is an internal relapse module.
--
-- It contains multiple implementations of if expressions.
module Data.Katydid.Relapse.IfExprs
( IfExprs
, IfExpr
, newIfExpr
, evalIfExprs
, compileIfExprs
, ZippedIfExprs
, zipIfExprs
, evalZippedIfExprs
)
where
import Data.Katydid.Parser.Pa... | katydid/haslapse | src/Data/Katydid/Relapse/IfExprs.hs | bsd-3-clause | 3,319 | 0 | 11 | 912 | 965 | 519 | 446 | 60 | 2 |
--------------------------------------------------------------------------
-- 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 writing to:
-- ETH Zurich D-INFK, Haldeneggsteig... | utsav2601/cmpe295A | hake/ARMv5.hs | mit | 7,047 | 8 | 17 | 2,719 | 1,037 | 576 | 461 | 129 | 1 |
module HList
( H
, repH
, absH
) where
type H a = [a] -> [a]
-- {-# INLINE repH #-}
repH :: [a] -> H a
repH xs = (xs ++)
-- {-# INLINE absH #-}
absH :: H a -> [a]
absH f = f []
-- -- Should be in a "List" module
-- {-# RULES "++ []" forall xs . xs ++ [] = xs #-}
-- {-# RULES "++ strict... | conal/hermit | examples/qsort/HList.hs | bsd-2-clause | 773 | 0 | 6 | 255 | 98 | 61 | 37 | 9 | 1 |
module Text.Pandoc.Readers.DocBook ( readDocBook ) where
import Data.Char (toUpper)
import Text.Pandoc.Shared (safeRead)
import Text.Pandoc.Options
import Text.Pandoc.Definition
import Text.Pandoc.Builder
import Text.XML.Light
import Text.Pandoc.Compat.TagSoupEntity (lookupEntity)
import Data.Either (rights)
import Dat... | infotroph/pandoc | src/Text/Pandoc/Readers/DocBook.hs | gpl-2.0 | 53,252 | 0 | 24 | 15,972 | 7,560 | 3,744 | 3,816 | 517 | 112 |
{-# LANGUAGE BangPatterns #-}
module Lib where
data T1 a = T1 a
newtype T2 a = T2 a
f :: T1 a -> Bool -> ()
f _ True = ()
f (T1 _) True = ()
f _ _ = ()
g :: T2 a -> Bool -> ()
g _ True = ()
g (T2 _) True = () -- redundant
g !_ True = () -- inaccessible
g _ _ = ()
| sdiehl/ghc | testsuite/tests/pmcheck/should_compile/T17248.hs | bsd-3-clause | 298 | 0 | 7 | 110 | 159 | 84 | 75 | 13 | 1 |
module WhereIn1 where
--A definition can be demoted to the local 'where' binding of a friend declaration,
--if it is only used by this friend declaration.
--Demoting a definition narrows down the scope of the definition.
--In this example, demote the top level 'sq' to 'sumSquares'
--This example also aims to test the... | kmate/HaRe | old/testing/demote/WhereIn1_TokOut.hs | bsd-3-clause | 478 | 0 | 7 | 118 | 83 | 44 | 39 | 7 | 2 |
{-# LANGUAGE CPP #-}
-----------------------------------------------------------------------------
-- |
-- Module : Distribution.Client.Freeze
-- Copyright : (c) David Himmelstrup 2005
-- Duncan Coutts 2011
-- License : BSD-like
--
-- Maintainer : cabal-devel@gmail.com
-- Stability ... | Helkafen/cabal | cabal-install/Distribution/Client/Freeze.hs | bsd-3-clause | 8,369 | 0 | 20 | 2,133 | 1,546 | 832 | 714 | 160 | 4 |
{-# LANGUAGE MagicHash #-}
module ShouldFail where
-- The danger here is getting a type like
-- f :: forall (a::??). a -> Bool
-- and hence allowing the bogus calls that follow
f x = True
h v = (f 3#, f 4.3#, f True)
| hvr/jhc | regress/tests/1_typecheck/4_fail/ghc/tcfail123.hs | mit | 221 | 0 | 6 | 50 | 42 | 24 | 18 | 4 | 1 |
module Mixfix where
import List (intersperse)
mixfix' :: String -> [ShowS] -> ShowS
mixfix' ('_':cs) (p:ps) = p . mixfix' cs ps
mixfix' ('\\':c:cs) ps = showChar c . mixfix' cs ps
mixfix' (c:cs) ps = showChar c . mixfix' cs ps
mixfix' _ _ = id
mixfix :: String -> [ShowS] -> Int -> Int -> ShowS
mixfix cs ps p0 p = sho... | forste/haReFork | tools/hs2isabelle/AST/Mixfix.hs | bsd-3-clause | 800 | 0 | 8 | 155 | 366 | 185 | 181 | 22 | 1 |
{-# LANGUAGE GADTs, KindSignatures,
MultiParamTypeClasses, FunctionalDependencies #-}
-- Program from Josef Svenningsson
-- Just a short explanation of the program. It contains
-- some class declarations capturing some definitions from
-- category theory. Further down he have a data type for well typed
-... | sdiehl/ghc | testsuite/tests/gadt/josef.hs | bsd-3-clause | 2,419 | 0 | 11 | 615 | 609 | 319 | 290 | -1 | -1 |
-- GSoC 2015 - Haskell bindings for OpenCog.
{-# LANGUAGE DataKinds #-}
module MosesModel (mosesModel) where
import OpenCog.AtomSpace (Atom(..),AtomType(ImplicationT),stv,noTv,(|>),(\>))
mosesModel :: Atom ImplicationT
mosesModel = ImplicationLink (stv 0.875 0.44)
(OrLink noTv
|... | ruiting/opencog | examples/pln/moses-pln-synergy/haskell/MosesModel.hs | agpl-3.0 | 520 | 0 | 9 | 137 | 108 | 63 | 45 | 9 | 1 |
-- |Computations in the vectorisation monad concerned with naming and fresh variable generation.
module Vectorise.Monad.Naming
( mkLocalisedName
, mkDerivedName
, mkVectId
, cloneVar
, newExportedVar
, newLocalVar
, newLocalVars
, newDummyVar
, newTyVar
)
where
import Vectorise.Monad.Base
import ... | siddhanathan/ghc | compiler/vectorise/Vectorise/Monad/Naming.hs | bsd-3-clause | 3,927 | 0 | 13 | 938 | 786 | 409 | 377 | 66 | 1 |
module T5243A where
bar = True
| olsner/ghc | testsuite/tests/parser/should_compile/T5243A.hs | bsd-3-clause | 31 | 0 | 4 | 6 | 9 | 6 | 3 | 2 | 1 |
--
-- Licensed to the Apache Software Foundation (ASF) under one
-- or more contributor license agreements. See the NOTICE file
-- distributed with this work for additional information
-- regarding copyright ownership. The ASF licenses this file
-- to you under the Apache License, Version 2.0 (the
-- "License"); you ma... | jcgruenhage/dendrite | vendor/src/github.com/apache/thrift/tutorial/hs/HaskellClient.hs | apache-2.0 | 2,164 | 0 | 13 | 496 | 369 | 204 | 165 | 39 | 1 |
-----------------------------------------------------------------------------
--
-- Module : Language.PureScript.AST.Declarations
-- Copyright : (c) 2013-15 Phil Freeman, (c) 2014-15 Gary Burgess
-- License : MIT (http://opensource.org/licenses/MIT)
--
-- Maintainer : Phil Freeman <paf31@cantab.net>
-- ... | michaelficarra/purescript | src/Language/PureScript/AST/Declarations.hs | mit | 13,365 | 0 | 14 | 2,497 | 2,264 | 1,347 | 917 | 151 | 2 |
module Config where
--
import qualified SDL as SDL
import Linear.V2 (V2(..))
--
--
winW = 640
winH = 480
winV2 = V2 winW winH
--
winConfig = SDL.defaultWindow
{ SDL.windowPosition = SDL.Centered
, SDL.windowInitialSize = V2 winW winH
}
rdrConfig = SDL.RendererConfig
{ SDL.rendererType = SDL.AcceleratedVS... | jaiyalas/sdl2-examples | src/Config.hs | mit | 375 | 0 | 7 | 73 | 107 | 66 | 41 | 12 | 1 |
{- this module coordinates the whole shebang.
First splits input into `of interest' and `computer generated'
Then parses 'of interest', and plucks out data and newtype declarations and
processor commands
The commands are combined with the parsed data, and if any data is missing,
derive goes hunting for it, lo... | ajhc/drift | src/ChaseImports.hs | mit | 4,588 | 41 | 18 | 1,000 | 1,356 | 771 | 585 | 95 | 3 |
{-# LANGUAGE OverloadedStrings #-}
module Client.CSSSpec ( spec ) where
import Helper
spec :: Spec
spec = do
describe "method" $ do
it "should do something" $ do
False `shouldBe` (True :: Bool)
| slogsdon/url | test/Client/CSSSpec.hs | mit | 225 | 0 | 14 | 64 | 60 | 33 | 27 | 8 | 1 |
module LogicAndCodesSpec (main, spec) where
import Test.Hspec
import LogicAndCodes
main :: IO ()
main = hspec spec
spec :: Spec
spec = do
describe "Problem 46" $ do
describe "not'" $ do
it "returns False when a = True" $ do
not' True `shouldBe` False
it "returns True when a = False" $ do
... | yyotti/99Haskell | src/test/LogicAndCodesSpec.hs | mit | 6,006 | 0 | 26 | 1,846 | 1,667 | 844 | 823 | 123 | 1 |
-- |
-- Module: Math.NumberTheory.UniqueFactorisationTests
-- Copyright: (c) 2016 Andrew Lelechenko
-- Licence: MIT
-- Maintainer: Andrew Lelechenko <andrew.lelechenko@gmail.com>
-- Stability: Provisional
--
-- Tests for Math.NumberTheory.ArithmeticFunctions
--
{-# LANGUAGE CPP #-}
{-# LA... | cfredric/arithmoi | test-suite/Math/NumberTheory/UniqueFactorisationTests.hs | mit | 1,408 | 0 | 14 | 266 | 334 | 191 | 143 | 26 | 1 |
module Agda.Parser where
--------------------------------------------------------------------------------
import Agda.Syntax.Parser (parseFile, runPMIO, tokensParser)
import Agda.Syntax.Parser.Tokens (Token)
import Agda.Syntax.Position (Position' (posPos), PositionWithoutFile, Range, getRange, rEnd', rStart')
import ... | banacorn/agda-language-server | src/Agda/Parser.hs | mit | 2,217 | 0 | 27 | 482 | 662 | 352 | 310 | 44 | 5 |
{-# LANGUAGE TypeSynonymInstances, FlexibleInstances #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE DeriveFunctor, DeriveGeneric #-}
module IHaskell.Display.Diagrams.Animation
( animation
, ManuallySampled, withAnimFps
) where
import qualified Data.Text as T
impor... | gibiansky/IHaskell | ihaskell-display/ihaskell-diagrams/IHaskell/Display/Diagrams/Animation.hs | mit | 5,133 | 0 | 16 | 1,327 | 1,456 | 755 | 701 | 90 | 4 |
-- | Settings are centralized, as much as possible, into this file. This
-- includes database connection settings, static file locations, etc.
-- In addition, you can configure a number of different aspects of Yesod
-- by overriding methods in the Yesod typeclass. That instance is
-- declared in the Foundation.hs file.... | dphilipson/word_guesser_web | Settings.hs | mit | 2,877 | 0 | 9 | 511 | 293 | 188 | 105 | -1 | -1 |
module Tictactoe.Base (
Coords,
BoardField,
Board,
BoardState(Won,Lost,Tie,Ongoing),
RowInfo(RowInfo),
matchSign,
free,
fieldExists,
coordsEqual,
mySign,
oppSign,
rowsInfos,
gameState
) where
import Data.Maybe
data RowInfo = RowInfo {
free :: [Coords]
, match... | viktorasl/tictactoe-bot | src/Tictactoe/Base.hs | mit | 2,641 | 0 | 20 | 682 | 1,071 | 592 | 479 | 68 | 4 |
{-
T.M. Nicholl, D.T. Lee, R.A. Nicholl, “An efficient new algorithm for 2D line clipping: Its development and analysis”, Computer Graphics, volume 21, number 4, July 1987
left top | centre top | right top
---------------+---------------+---------------
left middle | centre middle | right middle
---------... | mietek/map-cutter | src/Geometry/LineClipping.hs | mit | 8,144 | 0 | 12 | 1,808 | 2,920 | 1,427 | 1,493 | 118 | 1 |
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
-- | A concrete context implement SMT provided *for convenience*
module Z3.Context (Z3SMT, localSMT, checkPre) where
import Z3.Monad
import Z3.Base.Class
import Z3.Base.SMTR
import Z3.Datatypes
import qualified Data.Map as M
import Control.Monad.State
import Control.Mona... | izgzhen/z3-encoding | src/Z3/Context.hs | mit | 1,920 | 0 | 17 | 543 | 617 | 323 | 294 | -1 | -1 |
-- Problem 1
-- myLast
-- Find the last element of a list
myLast :: [a] -> a
myLast [] = error "Not enough elements in list"
myLast [x] = x
myLast (x:xs) = myLast xs
-- Problem 2
-- myButLast
-- Find the last but one element of a list
myButLast :: [a] -> a
myButLast = myLast . init
-- Problem 3
-- elementAt
... | CrazyMerlyn/99problems-haskell | 1-10.hs | mit | 1,887 | 0 | 11 | 512 | 685 | 376 | 309 | 35 | 2 |
module QuantumComputer.Qbits
( Qbit(..)
, flipQbit
, qbitToInt
) where
-- make new qstate (single qbit) of superpositon of |0> and |1>
data Qbit = Up | Down deriving (Eq)
instance Show Qbit where
show (Up) = "|1>"
show (Down) = "|0>"
-- Flip a Qbit over
flipQbit :: Qbit -> Qbit
flipQbit (Up)... | VictorLoren/quantum-computer-haskell | QuantumComputer/Qbits.hs | mit | 429 | 0 | 7 | 120 | 126 | 72 | 54 | 14 | 1 |
{--
-- Natume -- an implementation of Kana-Kanji conversion in Haskell
-- Copyright (C) 2006-2012 Takayuki Usui
--
-- 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 th... | takayuki/natume | ScmParse.hs | gpl-2.0 | 7,925 | 0 | 15 | 3,309 | 2,854 | 1,504 | 1,350 | 183 | 5 |
{-# LANGUAGE UndecidableInstances #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE ImpredicativeTypes #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE GADTs #-}
{-# LANGUAGE StandaloneDeriv... | alexstachnik/High-Level-C | src/Language/HLC/HighLevelC/HLC.hs | gpl-2.0 | 9,771 | 6 | 16 | 1,896 | 3,045 | 1,557 | 1,488 | -1 | -1 |
module Rewriting.TRS.Derive where
import Rewriting.TRS
import Type.Tree
import Rewriting.TRS.Instance
import Rewriting.TRS.Step
import Rewriting.TRS.Steps
import Rewriting.Derive.Quiz
import Rewriting.Derive.Config
import Autolib.Reporter
import Autolib.ToDoc
import Autolib.Reader
import Autolib.FiniteMap
import Ch... | marcellussiegburg/autotool | collection/src/Rewriting/TRS/Derive.hs | gpl-2.0 | 2,075 | 0 | 16 | 661 | 664 | 341 | 323 | -1 | -1 |
module PulseLambda.TokenStream
( Token(..)
, TokenValue(..)
, showListOfTokens
, isKeywordToken
, isStringToken
, isCharToken
, isIntToken
, isNaturalToken
, isLargeIntToken
, isRealToken
, isIdentifierToken
, isOperatorToken
, isPunctuationToken
, isNewlineToken
, isEndToken
, TokenStream
, getCodeStream
, getCurrToke... | brunoczim/PulseLambda | PulseLambda/TokenStream.hs | gpl-3.0 | 16,346 | 0 | 15 | 3,665 | 4,623 | 2,399 | 2,224 | 403 | 3 |
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE TypeSynonymInstances #-}
module Main where
import System.IO.Unsafe
import Test.QuickCheck
import Test.QuickCheck.Batch
import Prelude hiding ((&&))
import qualified Data.List as List
import qualified Qlogic.Assign as A
import Qlogic.Boolean
import Qlogic.Formula
import ... | mzini/qlogic | Qlogic/Test/NatSat.hs | gpl-3.0 | 7,315 | 0 | 14 | 3,076 | 1,410 | 732 | 678 | 86 | 3 |
module P38FilterSpec (main,spec) where
import Test.Hspec
import Test.Hspec.QuickCheck
import P38Filter hiding (main)
main :: IO ()
main = hspec spec
spec :: Spec
spec = do
describe "filt" $ do
it "filters even numbers when passed evn as an predicate and a list of numbers" $ do
filt evn [1,2,3,4] `shou... | ciderpunx/57-exercises-for-programmers | test/P38FilterSpec.hs | gpl-3.0 | 1,097 | 0 | 15 | 305 | 340 | 168 | 172 | 29 | 1 |
{-# LANGUAGE ScopedTypeVariables #-}
module HLinear.Test.Matrix.Algebra
where
import HLinear.Utility.Prelude
import HLinear.Matrix.Sized
import Math.Structure.Tasty
import Test.Tasty
properties
:: forall ctx
. ReifiesNModContext ctx
=> Reader (Proxy ctx) TestTree
properties = pure $
testGroup "Algebraic p... | martinra/hlinear | test/HLinear/Test/Matrix/Algebra.hs | gpl-3.0 | 1,156 | 0 | 17 | 289 | 347 | 180 | 167 | -1 | -1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# L... | romanb/amazonka | amazonka-ec2/gen/Network/AWS/EC2/CreateSecurityGroup.hs | mpl-2.0 | 6,631 | 0 | 9 | 1,369 | 667 | 416 | 251 | 73 | 1 |
module Git.Command.Instaweb (run) where
run :: [String] -> IO ()
run args = return () | wereHamster/yag | Git/Command/Instaweb.hs | unlicense | 86 | 0 | 7 | 15 | 42 | 23 | 19 | 3 | 1 |
module KthDifferences.A327743 (a327743_list, a327743) where
import Data.Set (Set)
import qualified Data.Set as Set
import Data.Maybe (Maybe, mapMaybe)
type KthDifferences = [(Integer, Set Integer)]
-- Each list of k-th differences distinct.
a327743_list :: [Integer]
a327743_list = recurse [] where
recurse kthDiffer... | peterokagey/haskellOEIS | src/KthDifferences/A327743.hs | apache-2.0 | 946 | 0 | 12 | 150 | 324 | 180 | 144 | 19 | 1 |
module Subsets.A272011Spec (main, spec) where
import Test.Hspec
import Subsets.A272011 (a272011)
main :: IO ()
main = hspec spec
spec :: Spec
spec = describe "A272011" $
it "correctly computes the first 20 elements" $
take 20 (map a272011 [0..]) `shouldBe` expectedValue where
expectedValue = [0,1,1,0,2,2,... | peterokagey/haskellOEIS | test/Subsets/A272011Spec.hs | apache-2.0 | 349 | 0 | 10 | 59 | 160 | 95 | 65 | 10 | 1 |
import Data.Char
data Operator = Plus | Minus | Times | Div deriving (Show, Eq)
data Token = TokOp Operator
| TokIdent String
| TokNum Int
deriving (Show, Eq)
operator :: Char -> Operator
operator c | c == '+' = Plus
| c == '-' = Minus
| c == '*' = Times
... | egaburov/funstuff | Haskell/BartoszBofH/7_TokenizerHOF/tokenizer_gold.hs | apache-2.0 | 854 | 17 | 13 | 276 | 357 | 185 | 172 | 25 | 1 |
{-# LANGUAGE RankNTypes #-}
module Graphics.GL.Low.Framebuffer (
-- | By default, rendering commands output graphics to the default framebuffer.
-- This includes the color buffer, the depth buffer, and the stencil buffer. It
-- is possible to render to a texture instead. This is important for many
-- techniques. Rende... | evanrinehart/lowgl | Graphics/GL/Low/Framebuffer.hs | bsd-2-clause | 7,934 | 0 | 12 | 1,623 | 816 | 511 | 305 | 74 | 1 |
{-# language CPP #-}
-- No documentation found for Chapter "QueryControlFlagBits"
module Vulkan.Core10.Enums.QueryControlFlagBits ( QueryControlFlags
, QueryControlFlagBits( QUERY_CONTROL_PRECISE_BIT
... | expipiplus1/vulkan | src/Vulkan/Core10/Enums/QueryControlFlagBits.hs | bsd-3-clause | 2,399 | 1 | 10 | 608 | 332 | 199 | 133 | -1 | -1 |
#define IncludedmakeNewIndicesNullLeft
#ifdef IncludedmakeIndicesNull
#else
#include "../Proofs/makeIndicesNull.hs"
#endif
makeNewIndicesNullLeft :: RString -> RString -> Proof
{-@ makeNewIndicesNullLeft
:: s:RString
-> t:RString
-> {makeNewIndices s stringEmp t == N } @-}
makeNewIndicesNullLeft s t
... | nikivazou/verified_string_matching | src/Proofs/makeNewIndicesNullLeft.hs | bsd-3-clause | 843 | 2 | 15 | 233 | 242 | 119 | 123 | 15 | 1 |
-- |
-- Module : $Header$
-- Copyright : (c) 2013-2014 Galois, Inc.
-- License : BSD3
-- Maintainer : cryptol@galois.com
-- Stability : provisional
-- Portability : portable
module Cryptol.ModuleSystem.Base where
import Cryptol.ModuleSystem.Env (DynamicEnv(..), deIfaceDecls)
import Cryptol.ModuleS... | TomMD/cryptol | src/Cryptol/ModuleSystem/Base.hs | bsd-3-clause | 10,173 | 0 | 19 | 2,267 | 2,910 | 1,476 | 1,434 | -1 | -1 |
{-# LANGUAGE GeneralizedNewtypeDeriving,
DoAndIfThenElse,
ScopedTypeVariables,
DeriveFunctor,
TypeFamilies #-}
module Control.StartStop.Core where
import Control.Applicative
import Control.Concurrent.MVar
import Control.Monad.Reader
import Control.Monad.Writer.Stric... | tylerwx51/StartStopFRP | Control/StartStop/core.hs | bsd-3-clause | 16,789 | 1 | 34 | 5,130 | 6,053 | 2,952 | 3,101 | -1 | -1 |
module T402 where
import Data.Kind
import Data.Singletons.TH
type family Any :: k
$(singletons [d| type AnyOfKind (k :: Type) = Any :: k |])
| goldfirere/singletons | singletons-base/tests/compile-and-dump/Singletons/T402.hs | bsd-3-clause | 143 | 0 | 7 | 26 | 37 | 23 | 14 | -1 | -1 |
{-# LANGUAGE CPP #-}
{-# LANGUAGE FlexibleContexts #-}
module Heist.Tests
( tests
) where
------------------------------------------------------------------------------
import Blaze.ByteString.Builder
import Control.Monad.State
import qualified Data.ByteString.Char8 as ... | snapframework/heist | test/suite/Heist/Tests.hs | bsd-3-clause | 8,353 | 0 | 13 | 1,995 | 1,626 | 815 | 811 | -1 | -1 |
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
module Notate.Core where
import Control.Monad.Fail
import Control.Monad.IO.Class
import Control.Monad.State
import IHaskell.IPython.EasyKernel (KernelConfig(..))
import System.Directory (withCurrentDirectory)
data NotateEnv = NotateEnv
{ nsStackYaml :: FilePath
, nsCon... | ejconlon/notate | src/Notate/Core.hs | bsd-3-clause | 643 | 0 | 8 | 93 | 174 | 102 | 72 | 17 | 1 |
{-# LANGUAGE FlexibleInstances #-}
module Data.Ranges
(range, ranges, Range, Ranges, inRange, inRanges, toSet, single, addRange)
where
import Data.Set (Set)
import qualified Data.Set as Set
data Ord a => Range a = Single !a | Range !a !a
instance (Ord a, Show a) => Show (Range a) where
show (Single x) = concat ["("... | Porges/ranges-hs | Data/Ranges.hs | bsd-3-clause | 2,471 | 6 | 10 | 579 | 1,200 | 612 | 588 | 56 | 2 |
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE MagicHash #-}
{-# LANGUAGE ViewPatterns #-}
{-# LANGUAGE PartialTypeSignatures #-}
{-# LANGUAGE BangPatterns #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE CPP #-}
module Data.VectorBuilder.Storable
(VectorBuilder, new, indexFromEnd, insert, push, pop, updateStackEl... | pepeiborra/bytestring-xml | src/Data/VectorBuilder/Storable.hs | bsd-3-clause | 6,591 | 0 | 16 | 1,321 | 2,275 | 1,142 | 1,133 | -1 | -1 |
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
module Ballast.Client where
import Ballast.Types
import Data.Aeson (eitherDecode, encode)
import Data.Aeson.Types
import qualified Data.ByteString.Char8 as BS8
import ... | bitemyapp/ballast | src/Ballast/Client.hs | bsd-3-clause | 14,343 | 0 | 15 | 2,482 | 3,119 | 1,613 | 1,506 | 214 | 2 |
{-# LANGUAGE DeriveDataTypeable, RankNTypes, FlexibleInstances, FlexibleContexts,
KindSignatures, ScopedTypeVariables #-}
module Game.DeckBuild.Dominion.Types where
import Data.Typeable
import Control.Monad.State
import Data.List
import Data.Ord (comparing)
import Language.DeckBuild.Syntax hiding (Card, ... | cronburg/deckbuild | Game/DeckBuild/Dominion/Types.hs | bsd-3-clause | 9,485 | 0 | 28 | 2,289 | 1,726 | 978 | 748 | 112 | 2 |
{-# LANGUAGE TupleSections #-}
module Main where
import Test
import Config
import Benchmark
import Prelude hiding (catch)
import Data.List
import Data.Maybe
import Control.Arrow
import Control.Monad
import System.Environment
import System.Console.CmdArgs (cmdArgs, whenNormal, getVerbosity, Verbosi... | blambo/accelerate-examples | src/Main.hs | bsd-3-clause | 2,260 | 0 | 15 | 627 | 684 | 363 | 321 | 50 | 4 |
-- UUAGC 0.9.50 (src-ag/AbstractSyntax.ag)
module AbstractSyntax where
{-# LINE 2 "./src-ag/AbstractSyntax.ag" #-}
-- AbstractSyntax.ag imports
import Data.Set(Set)
import Data.Map(Map)
import Patterns (Pattern(..),Patterns)
import Expression (Expression(..))
import Macro --marcos
import CommonTypes
import Error... | norm2782/uuagc | src-generated/AbstractSyntax.hs | bsd-3-clause | 5,150 | 0 | 15 | 1,511 | 505 | 312 | 193 | 19 | 0 |
{-# LANGUAGE OverloadedStrings #-}
module Network.Mail.Locutoria.Cli.Ui
( ui
) where
import Control.Concurrent (newChan, writeChan)
import Control.Lens
import Control.Monad.Trans (liftIO)
import Data.Default (def)
import qualified Data.Text as Text
import qualified Graphics... | hallettj/locutoria | Network/Mail/Locutoria/Cli/Ui.hs | bsd-3-clause | 2,769 | 0 | 19 | 781 | 798 | 419 | 379 | 63 | 6 |
module Sound.Player.AudioPlay (
play,
pause,
resume,
stop
) where
import System.Process (ProcessHandle, StdStream(CreatePipe),
CreateProcess(std_err), createProcess, proc, terminateProcess)
import System.Posix (ProcessID)
import System.Posix.Signals (signalProcess)
import System.Process.Internals (ProcessHan... | potomak/haskell-player | src/Sound/Player/AudioPlay.hs | bsd-3-clause | 1,594 | 0 | 12 | 285 | 359 | 200 | 159 | 29 | 2 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.