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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
import System.Directory (getDirectoryContents, setCurrentDirectory)
import Criterion.Main
import qualified Data.Text.IO as TIO
import Hasmin
main :: IO ()
main = do
setCurrentDirectory "../hasmin-benchmarks/bnch"
xs <- getDirectoryContents "."
ys <- traverse TIO.readFile (filter (flip notElem [".", ".."]) ... | contivero/hasmin | benchmarks/Benchmarks.hs | bsd-3-clause | 400 | 0 | 14 | 63 | 133 | 68 | 65 | 10 | 1 |
{-# OPTIONS -fno-warn-unused-imports #-}
#include "HsConfigure.h"
-- #hide
module Data.Time.LocalTime.TimeOfDay
(
-- * Time of day
TimeOfDay(..),midnight,midday,makeTimeOfDayValid,
utcToLocalTimeOfDay,localToUTCTimeOfDay,
timeToTimeOfDay,timeOfDayToTime,
dayFractionToTimeOfDay,timeOfDayToDayFraction
) where
impor... | takano-akio/time | Data/Time/LocalTime/TimeOfDay.hs | bsd-3-clause | 3,461 | 14 | 13 | 586 | 887 | 479 | 408 | 57 | 1 |
module Sesyrel.Expression.Ratio (
Ratio,
Rational,
RealInfinite(..),
numerator,
denominator,
(%)) where
import Sesyrel.Expression.RealInfinite
import Prelude hiding (Rational)
import qualified Data.Ratio as R (numerator, denominator, (%))
data Ratio a = !a :% !a
numerator, denominator :: Ratio a -> a
nu... | balodja/sesyrel | src/Sesyrel/Expression/Ratio.hs | bsd-3-clause | 2,131 | 0 | 11 | 583 | 1,309 | 685 | 624 | 62 | 1 |
{-# language CPP #-}
-- | = Name
--
-- VK_KHR_format_feature_flags2 - device extension
--
-- == VK_KHR_format_feature_flags2
--
-- [__Name String__]
-- @VK_KHR_format_feature_flags2@
--
-- [__Extension Type__]
-- Device extension
--
-- [__Registered Extension Number__]
-- 361
--
-- [__Revision__]
-- 1
-... | expipiplus1/vulkan | src/Vulkan/Extensions/VK_KHR_format_feature_flags2.hs | bsd-3-clause | 6,902 | 0 | 8 | 1,312 | 352 | 274 | 78 | -1 | -1 |
module Main where
import Riot
import Data.Aeson
-- Just (TAPI {champions = fromList [Tchampions {botMmEnabled = False, freeToPlay = True, botEnabled = False, active = False, id = 4.0, rankedPlayEnabled = False}]})
main = do
print $ (decode test :: Maybe TAPI)
test = "{\"champions\":[{\"botMmEnabled\":false,\"id\":... | mxswd/json-sampler | examples/Main.hs | bsd-3-clause | 412 | 0 | 9 | 50 | 42 | 24 | 18 | 6 | 1 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE CPP #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE TypeFamilies #-}
{-|
Yesod.Test is a pragmatic framework for testing web applications built
using wai and persistent.
By pragmatic I may also mean '... | Daniel-Diaz/yesod | yesod-test/Yesod/Test.hs | mit | 33,635 | 0 | 19 | 8,389 | 6,720 | 3,603 | 3,117 | 542 | 9 |
module Queens (boardString, canAttack) where
type Square = (Int, Int)
boardString :: Maybe Square -> Maybe Square -> String
boardString whiteQueen blackQueen = unlines $ map (unwords . squares) [0..7]
where
squares row = map (\ col -> symbol $ Just (row, col)) [0..7]
symbol square
| square == whiteQue... | Bugfry/exercises | exercism/haskell/queen-attack/src/Queens.hs | mit | 514 | 0 | 12 | 125 | 230 | 121 | 109 | 12 | 1 |
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE FlexibleInstances #-}
-- the base concept of location
-- spatial properties and relations
-- vector geometry could be represented as well-known text (http://en.wikipedia.org/wiki/Well-known_text)
-- better alternative encoding would be GeoJSON (http://www.macwright.... | liangcun/ConceptsOfSpatialInformation | extras/CoreConceptsHs Backup/Location.hs | apache-2.0 | 4,261 | 0 | 11 | 773 | 649 | 357 | 292 | 39 | 1 |
{-| Converts a configuration state into a Ssconf map.
As TemplateHaskell require that splices be defined in a separate
module, we combine all the TemplateHaskell functionality that HTools
needs in this module (except the one for unittests).
-}
{-
Copyright (C) 2014 Google Inc.
All rights reserved.
Redistribution a... | bitemyapp/ganeti | src/Ganeti/WConfd/Ssconf.hs | bsd-2-clause | 6,454 | 0 | 17 | 1,535 | 1,250 | 691 | 559 | -1 | -1 |
{-# LANGUAGE TemplateHaskell #-}
{-# OPTIONS_GHC -fno-warn-orphans #-}
{-| Tests for lock allocation.
-}
{-
Copyright (C) 2014 Google Inc.
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. Redistri... | mbakke/ganeti | test/hs/Test/Ganeti/Locking/Allocation.hs | bsd-2-clause | 14,925 | 0 | 27 | 3,125 | 3,385 | 1,812 | 1,573 | 230 | 2 |
{-# LANGUAGE BangPatterns, ForeignFunctionInterface, MultiParamTypeClasses, CPP #-}
-----------------------------------------------------------------------------
--
-- Module : Data.Digest.Pure.MD5
-- License : BSD3
-- Maintainer : Thomas.DuBuisson@gmail.com
-- Stability : experimental
-- Portability : port... | sordina/PureMD5Improvements | Data/Digest/Pure/MD5.hs | bsd-3-clause | 12,396 | 20 | 16 | 4,243 | 4,027 | 2,029 | 1,998 | 234 | 2 |
{-# LANGUAGE CPP, FlexibleContexts #-}
#include "fusion-phases.h"
-- | Definition of the PArray type, and functions that work on it. The PArray
-- type is a PData with an array length. The functions we export from this
-- module are just wrappers for the PD functions from Data.Array.Parallel.PArray.PRepr.
--
-- ... | mainland/dph | dph-lifted-copy/Data/Array/Parallel/PArray/Base.hs | bsd-3-clause | 4,423 | 0 | 11 | 896 | 1,221 | 643 | 578 | -1 | -1 |
{-# OPTIONS_GHC -Wall #-}
{-# LANGUAGE OverloadedStrings #-}
module Generate.JavaScript.Builder (stmtsToText) where
import qualified Data.List as List
import Data.Monoid ((<>))
import qualified Data.Text.Lazy as LazyText
import Data.Text.Lazy.Builder
import Data.Text.Lazy.Builder.Int (decimal)
import Data.Text.Lazy.Bu... | mgold/Elm | src/Generate/JavaScript/Builder.hs | bsd-3-clause | 11,559 | 0 | 17 | 3,805 | 3,575 | 1,802 | 1,773 | 346 | 25 |
{-# LANGUAGE Haskell2010 #-}
{-# LINE 1 "dist/dist-sandbox-261cd265/build/System/Posix/Semaphore.hs" #-}
{-# LINE 1 "System/Posix/Semaphore.hsc" #-}
{-# LINE 2 "System/Posix/Semaphore.hsc" #-}
{-# LANGUAGE Safe #-}
{-# LINE 6 "System/Posix/Semaphore.hsc" #-}
-----------------------------------------------------------... | phischu/fragnix | tests/packages/scotty/System.Posix.Semaphore.hs | bsd-3-clause | 5,466 | 0 | 16 | 1,633 | 1,009 | 528 | 481 | 81 | 4 |
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
module Distribution.Types.ForeignLibOption(
ForeignLibOption(..)
) where
import Prelude ()
import Distribution.Compat.Prelude
import Text.PrettyPrint
import qualified Distribution.Compat.ReadP as Parse
import Distribution.Text
data ForeignLibOpt... | mydaum/cabal | Cabal/Distribution/Types/ForeignLibOption.hs | bsd-3-clause | 882 | 0 | 12 | 160 | 146 | 84 | 62 | 17 | 0 |
-- A start sequence byte (0xE0) followed by an invalid continuation:
bad = "ð."
| forked-upstream-packages-for-ghcjs/ghc | testsuite/tests/parser/unicode/utf8_022.hs | bsd-3-clause | 81 | 0 | 4 | 15 | 7 | 4 | 3 | 1 | 1 |
{-
import Gui
import Game
import GoNetwork ( startServer, startClient )
import Board ( Cell(..), opposite )
import System.Environment
import Data.Char ( toLower )
import Data.Lens.Lazy ( (^=), (^.) )
import Control.Monad ( unless )
getBoardSize :: IO Int
getBoardSize = do putStrLn "Choose board size: s - Small (9), ... | xarts19/GoHaskell | Main.hs | mit | 3,886 | 0 | 12 | 1,459 | 253 | 133 | 120 | 21 | 2 |
-- Haskell implementation of Nim --
-- Amman Vedi - Haskell Coursework 2 - 2012 --
-- basic operation of the gameplay implementation
-- game state -> player moves -> new game state -> show new game state
-- loops recirsivley until the game state returns a [0,0,0] list
import System.IO
import Data.Char
import Data.Lis... | ammanvedi/haskell-nim-game | nim.hs | mit | 2,995 | 0 | 12 | 1,026 | 760 | 368 | 392 | 57 | 1 |
{-# LANGUAGE ImplicitParams #-}
module Main where
import Control.Lens
import Control.Monad
import qualified Data.ByteString.Char8 as BS
import qualified Data.Map as M
import Data.Monoid
import qualified Data.Text as T
import qualified Data.Text.IO as T
import qualified Data.Yaml.Pretty a... | nushio3/formura | exe-src/formura.hs | mit | 3,398 | 0 | 15 | 817 | 1,005 | 515 | 490 | -1 | -1 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE QuasiQuotes #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE TypeFamilies #-}
import Yesod
data App = App
mkYesod "App" [parseRoutes|
/ HomeR GET
|]
instance Yesod App
getHomeR = defaultLayout $ do
setTitle "My Page Title"
toWidget [luciu... | michalc/haskell-experiments | yes.hs | mit | 1,000 | 0 | 8 | 333 | 122 | 69 | 53 | 22 | 1 |
module Rebase.GHC.IO.Encoding
(
module GHC.IO.Encoding
)
where
import GHC.IO.Encoding
| nikita-volkov/rebase | library/Rebase/GHC/IO/Encoding.hs | mit | 89 | 0 | 5 | 12 | 23 | 16 | 7 | 4 | 0 |
{-# LANGUAGE TemplateHaskell #-}
module Diagrams.Plots.Line
( line
, LineOpts
, lineshape
) where
import Diagrams.Prelude
import Data.Default
import Control.Lens (makeLenses, (^.))
import Data.Maybe
import Diagrams.Plots.Types
import Diagrams.Plots.Utils (hasNaN)
data LineOpts = LineOpts
{ _lin... | kaizhang/haskell-plot | src/Diagrams/Plots/Line.hs | mit | 792 | 0 | 11 | 211 | 261 | 139 | 122 | 23 | 1 |
{-# LANGUAGE GADTs #-}
{-# LANGUAGE DataKinds, KindSignatures #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoMonomorphismRestriction #-}
{-# LANGUAGE PolyKinds #-}
--{-# LANGUAGE Scoped... | vladfi1/hs-misc | DeBruijn.hs | mit | 3,242 | 0 | 9 | 712 | 1,047 | 565 | 482 | 64 | 1 |
{-# LANGUAGE PatternSynonyms #-}
-- For HasCallStack compatibility
{-# LANGUAGE ImplicitParams, ConstraintKinds, KindSignatures #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
module JSDOM.Generated.SVGAnimatedAngle
(getBaseVal, getAnimVal, SVGAnimatedAngle(..),
gTypeSVGAnimatedAngle)
where
impor... | ghcjs/jsaddle-dom | src/JSDOM/Generated/SVGAnimatedAngle.hs | mit | 1,586 | 0 | 10 | 183 | 398 | 252 | 146 | 25 | 1 |
{-# LANGUAGE QuasiQuotes #-}
module Hpack.Syntax.DefaultsSpec (spec) where
import Helper
import Data.Aeson.Config.FromValueSpec hiding (spec)
import Data.Aeson.Config.FromValue
import Hpack.Syntax.Defaults
defaultsGithub :: String -> String -> String -> [FilePath] -> Defaults... | sol/hpack | test/Hpack/Syntax/DefaultsSpec.hs | mit | 5,095 | 0 | 21 | 1,592 | 869 | 441 | 428 | 89 | 1 |
data Person =
Person {name :: String
, age :: Int }
deriving (Eq, Show)
jm = Person "julie" 108
ca = Person "chris" 16 | candu/haskellbook | ch11/personRecord.hs | mit | 132 | 0 | 8 | 38 | 53 | 29 | 24 | 6 | 1 |
{-|
Module : Control.Flower
Description : Modern, readable, directional Haskell
== Use
>>> import Control.Flower
== Rationale
> Mathematics, rightly viewed, possesses not only truth,
> but supreme beauty -- a beauty cold and austere, like that of sculpture,
> without appeal to any part of our weaker nature, wi... | expede/flower | src/Control/Flower.hs | mit | 2,552 | 0 | 5 | 412 | 76 | 53 | 23 | 11 | 0 |
{-
**************************************************************
* Filename : AutomatonInterface.hs *
* Author : Markus Forsberg *
* d97forma@dtek.chalmers.se *
* Last Modified : 6 July, 2001 ... | SAdams601/ParRegexSearch | test/fst-0.9.0.1/FST/AutomatonInterface.hs | mit | 2,191 | 0 | 9 | 906 | 398 | 208 | 190 | 34 | 1 |
module First where
import Data.Monoid (Monoid(mempty,mappend))
import Data.Maybe (isNothing)
class BoolLike a where
falsy :: a -> Bool
bempty :: a
instance BoolLike [a] where
bempty = []
falsy = null
newtype First a = MkFirst { getFirst :: a } deriving (Show, Eq)
instance BoolLike a => Monoid (Firs... | olivierverdier/Norvigs-Spelling-Corrector | src/First.hs | mit | 533 | 0 | 9 | 124 | 194 | 109 | 85 | 16 | 0 |
-- A set of functions for determining metrics of a cluster in the format [(x, y, c)]
-- Depends on the module statistics-linreg for linear regression algorithm; hackage.haskell.org/package/statistics-linreg
-- Real documentation coming soon...
module TimepixData.ClusterProperties
( clusterProperties
) where
import qu... | InstituteForResearchInSchools/FunctionalTimepixAnalysis | TimepixData/ClusterProperties.hs | mit | 2,675 | 0 | 12 | 524 | 736 | 399 | 337 | 39 | 1 |
{-# LANGUAGE OverloadedStrings, RankNTypes, GADTs, FlexibleContexts #-}
module Models.Events
( module Models.Events.Types
, module Models.Events.Projections
, module Models.Events.Database
)
where
import Models.Events.Database
import Models.Events.Projections
import Models.Events.Types
import Models.Projectio... | CarstenKoenig/MyWebSite | src/Models/Events.hs | mit | 323 | 0 | 5 | 38 | 53 | 36 | 17 | 9 | 0 |
module Chapter14ListTest where
--import Test.Hspec
import Test.QuickCheck
import Data.List (sort)
-- for any list you apply sort to
-- this property should hold
listOrdered :: (Ord a) => [a] -> Bool
listOrdered xs =
snd $ foldr go (Nothing, True) xs
where
go _ status@(_, False) = status
go y (Nothing, t)... | brodyberg/Notes | addition/Chapter14ListTest.hs | mit | 546 | 0 | 9 | 126 | 213 | 119 | 94 | 13 | 3 |
module Rebase.Control.Monad.Trans.State.Strict
(
module Control.Monad.Trans.State.Strict
)
where
import Control.Monad.Trans.State.Strict
| nikita-volkov/rebase | library/Rebase/Control/Monad/Trans/State/Strict.hs | mit | 140 | 0 | 5 | 12 | 29 | 22 | 7 | 4 | 0 |
module Main where
import qualified ImportSort.Sort as S
main :: IO ()
main = getContents >>= putStrLn . S.sortImport
| joshuaclayton/import-sort | app/Main.hs | mit | 119 | 0 | 6 | 21 | 37 | 22 | 15 | 4 | 1 |
{-# LANGUAGE OverloadedStrings #-}
module CryptoSpec (main, spec) where
import Test.Hspec
import Test.QuickCheck
import Prelude as P
import Data.Maybe
import Data.ByteString as BS
import Data.ByteString.Arbitrary
import Data.Serialize as DS
import Data.Byteable
import Crypto.Curve25519
import Crypto.Random
import Cry... | danoctavian/bit-smuggler | BitSmuggler/test/unit/CryptoSpec.hs | gpl-2.0 | 2,320 | 0 | 12 | 409 | 586 | 320 | 266 | 50 | 1 |
{-# LANGUAGE MultiParamTypeClasses, TypeSynonymInstances, FlexibleInstances #-}
{- |
Module : ./ExtModal/Logic_ExtModal.hs
Description : Instance of class Logic for ExtModal
Copyright : DFKI GmbH 2009
License : GPLv2 or higher, see LICENSE.txt
Maintainer : Christian.Maeder@dfki.de
Stability : experi... | spechub/Hets | ExtModal/Logic_ExtModal.hs | gpl-2.0 | 5,840 | 0 | 17 | 1,195 | 1,153 | 593 | 560 | 112 | 1 |
{-# LANGUAGE ForeignFunctionInterface #-}
module OpenGL.Helpers
(
module Linear,
localMatrix,
statevarLocal,
enableLocal,
disableLocal,
setProjModV,
setModelView,
setProjection,
color4,
multMat4,
rotateX,
rotateY,
rotateZ,
scaleXYZ,
module OpenGL.Helper... | karamellpelle/grid | designer/source/OpenGL/Helpers.hs | gpl-3.0 | 3,135 | 0 | 12 | 838 | 1,030 | 522 | 508 | 92 | 1 |
join :: Monoid w => Writer w (Writer w a) -> Writer w a
join (Writer ((Writer (a, w')), w)) = Writer (a, w `mappend` w') | hmemcpy/milewski-ctfp-pdf | src/content/3.4/code/haskell/snippet16.hs | gpl-3.0 | 120 | 0 | 11 | 25 | 82 | 43 | 39 | 2 | 1 |
module A1Nat where
-- This is our simple Natural numbers data type.
--
-- S is a successor, Z is zero.
-- 1 is S Z (the successor of zero).
-- 2 is S (S Z).
-- And so on.
data Nat = Z -- Zero
| S Nat -- Successor
deriving Show -- This is a special syntax for automatically giving us
... | alexander-b/thug-beginners | lessonA/A1Nat.hs | gpl-3.0 | 9,661 | 0 | 9 | 2,392 | 969 | 581 | 388 | 65 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | rueshyna/gogol | gogol-apps-tasks/gen/Network/Google/Resource/Tasks/Tasks/Delete.hs | mpl-2.0 | 2,873 | 0 | 14 | 705 | 385 | 231 | 154 | 60 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-dialogflow/gen/Network/Google/Resource/DialogFlow/Projects/Locations/SecuritySettings/Create.hs | mpl-2.0 | 6,198 | 0 | 17 | 1,383 | 784 | 458 | 326 | 125 | 1 |
module Data.GI.CodeGen.Code
( Code(..)
, ModuleInfo(..)
, ModuleFlag(..)
, BaseCodeGen
, CodeGen
, ExcCodeGen
, CGError(..)
, genCode
, evalCodeGen
, writeModuleTree
, listModuleTree
, codeToText
, transitiveModuleDeps
, minBaseVersion
, BaseVersion(..)
,... | ford-prefect/haskell-gi | lib/Data/GI/CodeGen/Code.hs | lgpl-2.1 | 32,696 | 0 | 16 | 8,584 | 7,483 | 3,982 | 3,501 | -1 | -1 |
{-# OPTIONS_GHC -Wall #-}
module HW04 where
import Data.List
newtype Poly a = P [a]
-- Exercise 1 -----------------------------------------
x :: Num a => Poly a
x = P [0, 1]
-- Exercise 2 ----------------------------------------
instance (Num a, Eq a) => Eq (Poly a) where
(==) (P as) (P bs) = (==) as bs
-- ... | redongjun/haskellschool | homework/HW04.hs | unlicense | 2,652 | 0 | 14 | 812 | 1,025 | 533 | 492 | 50 | 3 |
-- module with tools for combinatoric formulae
module Maths.Combinatorics.Sums
( sumOfSquares,
squarePyramid
) where
-- the sum of squares of a finite list of numbers
sumOfSquares :: Num a => [a] -> a
sumOfSquares xs = sum [x^2 | x <- xs]
-- the n'th square pyramidal number
-- see http://en.wikipedia.org/wiki/Squar... | mathemage/htools | Maths/Combinatorics/Formulae.hs | apache-2.0 | 453 | 0 | 12 | 80 | 115 | 65 | 50 | 7 | 1 |
{-# LANGUAGE BangPatterns #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TupleSections #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE UndecidableInstances #-}
{-# OPTIONS_GHC... | input-output-hk/cardano-sl | chain/test/Test/Pos/Chain/Block/Arbitrary.hs | apache-2.0 | 23,124 | 0 | 25 | 6,268 | 4,132 | 2,215 | 1,917 | -1 | -1 |
{-# LANGUAGE BangPatterns, RankNTypes, GeneralizedNewtypeDeriving, ScopedTypeVariables #-}
module LDPC.Array.Decode where
import Data.Array.Matrix
import Data.Bit
import Data.Array
import ECC
decoder :: Int -> M Bit -> V Double -> V Bit
decoder = ldpc
ldpc :: forall d. (Floating d, Ord d) => Int -> M Bit -> V d -> ... | ku-fpg/ldpc | src/LDPC/Array/Decode.hs | bsd-2-clause | 2,431 | 0 | 25 | 1,092 | 1,037 | 537 | 500 | -1 | -1 |
{-# LANGUAGE Trustworthy #-}
{-# LANGUAGE CPP, NoImplicitPrelude, CApiFFI #-}
-----------------------------------------------------------------------------
-- |
-- Module : System.IO
-- Copyright : (c) The University of Glasgow 2001
-- License : BSD-style (see the file libraries/base/LICENSE)
--
-- Maint... | GaloisInc/halvm-ghc | libraries/base/System/IO.hs | bsd-3-clause | 21,742 | 0 | 22 | 5,465 | 2,857 | 1,639 | 1,218 | 236 | 5 |
{-# LANGUAGE TypeFamilies #-}
module Aws.Swf.Commands.RecordActivityTaskHeartbeat
where
import Aws.Core (AsMemoryResponse (..),
ResponseConsumer (..), Transaction)
import qualified Aws.Core.Sign as S (ServiceConfiguration)
import qualified Aws.Co... | RayRacine/aws | Aws/Swf/Commands/RecordActivityTaskHeartbeat.hs | bsd-3-clause | 2,387 | 0 | 9 | 539 | 437 | 259 | 178 | -1 | -1 |
{-# LANGUAGE BangPatterns, DeriveDataTypeable, DeriveGeneric, FlexibleInstances, MultiParamTypeClasses, OverloadedStrings #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
module GTFS.Realtime.Internal.Com.Google.Transit.Realtime.Alert.Cause (Cause(..)) where
import Prelude ((+), (/), (.))
import qualified Prelude as P... | romanofski/gtfsbrisbane | src/GTFS/Realtime/Internal/Com/Google/Transit/Realtime/Alert/Cause.hs | bsd-3-clause | 4,883 | 0 | 11 | 855 | 1,264 | 703 | 561 | 114 | 1 |
module NativeInfo (module System.Info) where
import System.Info
| OS2World/DEV-UTIL-HUGS | oldlib/NativeInfo.hs | bsd-3-clause | 64 | 0 | 5 | 7 | 17 | 11 | 6 | 2 | 0 |
{-# LANGUAGE OverloadedStrings #-}
module ETA.CodeGen.ArgRep
(ArgRep(..),
toArgRep,
jrepType,
isNonV,
idArgRep,
idPrimRep,
primRepFieldType_maybe,
primRepFieldType,
ftArgRep,
typeArgRep,
repFieldTypes,
repFieldType_maybe,
contextLoad,
contextStore,
slowCallPattern,
argRepF... | AlexeyRaga/eta | compiler/ETA/CodeGen/ArgRep.hs | bsd-3-clause | 5,728 | 0 | 12 | 1,795 | 1,732 | 943 | 789 | 160 | 15 |
module Physics where
import Math
import Prelude()
limitPower :: Scalar DPower -> Vector DForce -> Vector DVelocity -> Vector DForce
limitPower max force speed = mulSV coeff force where
coeff | power > max = max / power
| otherwise = 1 *~ one
power = dotV force speed
rotationVelocity :: Scalar DLength -> ... | Rotsor/wheeled-vehicle | Physics.hs | bsd-3-clause | 661 | 0 | 10 | 178 | 167 | 84 | 83 | 13 | 1 |
module Categorizer.Util.List
( safeHead ) where
safeHead :: [a] -> Maybe a
safeHead (x:_) = Just x
safeHead _ = Nothing
| ameingast/categorizer | src/Categorizer/Util/List.hs | bsd-3-clause | 126 | 0 | 7 | 27 | 53 | 29 | 24 | 5 | 1 |
module Network.OpenFlow.Message.OfpType where
data OfpType =
-- Immutable messages
OfptHello
| OfptError
| OfptEchoRequest
| OfptEchoReply
| OfptExperimenter
-- Switch configuration messages
| OfptFeaturesRequest
| OfptFeaturesReply
| OfptGetConfigRequest
| OfptGetConfigRe... | utky/openflow | src/Network/OpenFlow/Message/OfpType.hs | bsd-3-clause | 3,263 | 0 | 8 | 1,067 | 637 | 327 | 310 | 99 | 31 |
module IptAdmin.EditIpForwPage where
import Control.Monad.Error
import Happstack.Server.SimpleHTTP
import IptAdmin.EditIpForwForm.Render
import IptAdmin.Render
import IptAdmin.System
import IptAdmin.Types
import IptAdmin.Utils
import Iptables
import Iptables.Types
import Text.Blaze.Renderer.Pretty (renderHtml)
pageH... | etarasov/iptadmin | src/IptAdmin/EditIpForwPage.hs | bsd-3-clause | 1,701 | 0 | 12 | 382 | 229 | 121 | 108 | 28 | 3 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# OPTIONS_GHC -w #-}
module Dipper (
HadoopEnv(..)
, dipperMain
, clouderaEnv
) where
import Control.Applicative ((<|>))
import Control.Concurrent.Async (Concurrently(..))
import Control.Monad (void, ... | jystic/dipper | src/Dipper.hs | bsd-3-clause | 8,432 | 0 | 17 | 2,341 | 2,274 | 1,203 | 1,071 | 176 | 4 |
{-
Joseph Eremondi
UU# 4229924
APA Project 2
April 17, 2015
-}
{-# LANGUAGE FlexibleInstances #-}
module Type.Effect.Pattern where
import Control.Arrow (second)
import Control.Applicative ((<$>))
import qualified Control.Monad as Monad
import Control.Monad.Error
import qualified Data.Map as Map
import qualified Text... | JoeyEremondi/elm-type-effect | src/Type/Effect/Pattern.hs | bsd-3-clause | 15,680 | 0 | 28 | 4,274 | 3,863 | 1,988 | 1,875 | 225 | 7 |
module Module4.Task16 where
import Data.Char(isDigit)
findDigit :: [Char] -> Maybe Char
findDigit [] = Nothing
findDigit (x:xs) | isDigit x = Just x
| otherwise = findDigit xs
| dstarcev/stepic-haskell | src/Module4/Task16.hs | bsd-3-clause | 203 | 0 | 8 | 55 | 80 | 40 | 40 | 6 | 1 |
module Sexy.Data.Maybe (
Maybe(..)
, maybe'
, fromJust'
) where
data Maybe a = Just a | Nothing
maybe' :: (a -> b) -> b -> Maybe a -> b
maybe' f _ (Just x) = f x
maybe' _ x Nothing = x
-- fromJust = maybe id
fromJust' :: a -> Maybe a -> a
fromJust' _ (Just x) = x
fromJust' x Nothing = x
| DanBurton/sexy | src/Sexy/Data/Maybe.hs | bsd-3-clause | 304 | 0 | 8 | 84 | 138 | 75 | 63 | 11 | 1 |
-- | Combinators for use with the Web type. This module allows one to easily opt into a small subset of Quiz.Web.Prelude.
-- NOTE: These combinators are defined in Quiz.Web.Prelude and not here to avoid a circular dependency.
module Quiz.Web.Prelude.Helpers () where
import Quiz.Web.Prelude
| michael-swan/quick-quiz | src/Quiz/Web/Prelude/Combinators.hs | bsd-3-clause | 294 | 0 | 4 | 47 | 19 | 14 | 5 | 2 | 0 |
{-# LANGUAGE FlexibleInstances, FlexibleContexts, TypeSynonymInstances
, UndecidableInstances, OverlappingInstances, MultiParamTypeClasses #-}
{- |
Module : ./CSL/ReduceInterpreter.hs
Description : Reduce instance for the AssignmentStore class
Copyright : (c) Ewaryst Schulz, DFKI Bremen 2010
License : ... | spechub/Hets | CSL/ReduceInterpreter.hs | gpl-2.0 | 9,005 | 0 | 16 | 2,154 | 2,102 | 1,076 | 1,026 | 183 | 2 |
{-| Generic data loader.
This module holds the common code for parsing the input data after it
has been loaded from external sources.
-}
{-
Copyright (C) 2009, 2010, 2011, 2012 Google Inc.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided t... | bitemyapp/ganeti | src/Ganeti/HTools/Loader.hs | bsd-2-clause | 17,434 | 0 | 20 | 4,539 | 3,696 | 1,972 | 1,724 | 275 | 2 |
{-# LANGUAGE DeriveDataTypeable #-}
module Network.IRC.Bot.Log where
import Data.ByteString (ByteString)
import qualified Data.ByteString.Char8 as C
import Data.Data
data LogLevel
= Debug
| Normal
| Important
deriving (Eq, Ord, Read, Show, Data, Typeable)
type Logger = LogLevel -> ByteString -> IO ... | eigengrau/haskell-ircbot | Network/IRC/Bot/Log.hs | bsd-3-clause | 549 | 0 | 8 | 114 | 163 | 89 | 74 | 17 | 1 |
{- |
Module : $Header$
Description : Overload resolution
Copyright : (c) Martin Kuehl, T. Mossakowski, C. Maeder, 2004-2007
License : GPLv2 or higher, see LICENSE.txt
Maintainer : Christian.Maeder@dfki.de
Stability : provisional
Portability : portable
Overload resolution (injections are inserted ... | keithodulaigh/Hets | CASL/Overload.hs | gpl-2.0 | 23,545 | 0 | 27 | 6,358 | 7,348 | 3,675 | 3,673 | 398 | 15 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# L... | romanb/amazonka | amazonka-route53/gen/Network/AWS/Route53/DeleteHealthCheck.hs | mpl-2.0 | 3,744 | 0 | 9 | 755 | 372 | 228 | 144 | 49 | 1 |
{-# LANGUAGE BangPatterns #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE GADTs #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE... | harendra-kumar/stack | src/Stack/PackageIndex.hs | bsd-3-clause | 14,468 | 0 | 19 | 5,224 | 3,311 | 1,688 | 1,623 | 302 | 10 |
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TemplateHaskell #-}
module Stack.Init
( findCabalFiles
, initProject
, InitOpts (..)
, SnapPref (..)
, Method (..)
, makeConcreteResolver
) where
import ... | adinapoli/stack | src/Stack/Init.hs | bsd-3-clause | 10,453 | 0 | 20 | 3,517 | 2,439 | 1,232 | 1,207 | 207 | 8 |
{-# LANGUAGE ScopedTypeVariables #-}
module Main where
import qualified CV.Matrix as M
import CV.Transforms
main = do
let mat = M.fromList (5,2) . concatMap (\(x,y) -> [x,y])
source = [(1,1)
,(1,2)
,(2,1)
,(5,5)
,(2,4)]
tr = map (\(x,y) -> (x+10... | TomMD/CV | examples/homography.hs | bsd-3-clause | 569 | 0 | 14 | 164 | 288 | 163 | 125 | 16 | 1 |
{-# LANGUAGE CPP #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE OverloadedStrings #-}
#if __GLASGOW_HASKELL__ >= 800
{-# OPTIONS_GHC -Wno-redundant-constraints #-}
#endif
-- | Execute commands within the properly configured Stack
-- environment.
module Stack.Exec where
import ... | deech/stack | src/Stack/Exec.hs | bsd-3-clause | 3,290 | 0 | 13 | 700 | 608 | 340 | 268 | 58 | 2 |
module MediaWiki.API.Query.Blocks.Import where
import MediaWiki.API.Utils
import MediaWiki.API.Query.Blocks
import Text.XML.Light.Types
import Control.Monad
import Data.Maybe
stringXml :: String -> Either (String,[{-Error msg-}String]) BlocksResponse
stringXml s = parseDoc xml s
xml :: Element -> Maybe BlocksRespo... | HyperGainZ/neobot | mediawiki/MediaWiki/API/Query/Blocks/Import.hs | bsd-3-clause | 1,598 | 1 | 11 | 431 | 563 | 290 | 273 | 49 | 1 |
{-# LANGUAGE DeriveGeneric #-}
module Auto.G.BigSum where
import Control.DeepSeq
import Data.Aeson
import GHC.Generics (Generic)
import Options
data BigSum = F01 | F02 | F03 | F04 | F05
| F06 | F07 | F08 | F09 | F10
| F11 | F12 | F13 | F14 | F15
| F16 | F17 | F18 | F19 | F20
... | dmjio/aeson | benchmarks/bench/Auto/G/BigSum.hs | bsd-3-clause | 638 | 0 | 7 | 175 | 199 | 119 | 80 | 21 | 1 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TypeFamilies #-}
{-# OPTIONS_GHC -Wno-orphans #-}
module Database.Persist.Redis.Config
( RedisAuth (..)
, RedisConf (..)
, R.RedisCtx
, R.Redis
, R.Connection
, R.PortID (..)
, RedisT
, runRedisPool
, withRedisConn
, thisConnection... | paul-rouse/persistent | persistent-redis/Database/Persist/Redis/Config.hs | mit | 3,273 | 0 | 12 | 832 | 829 | 466 | 363 | 75 | 1 |
{-# LANGUAGE NumericUnderscores #-}
{-# LANGUAGE BinaryLiterals #-}
{-# LANGUAGE MagicHash #-}
{-# LANGUAGE NegativeLiterals #-}
-- Test for NumericUnderscores extension.
-- See Trac #14473
-- This is a testcase for unboxed literals.
import GHC.Types
main :: IO ()
main = do
-- Each case corresponds to the defini... | shlevy/ghc | testsuite/tests/parser/should_run/NumericUnderscores1.hs | bsd-3-clause | 2,222 | 0 | 12 | 744 | 560 | 299 | 261 | 37 | 1 |
{-# LANGUAGE CPP #-}
#if !defined(TESTING) && __GLASGOW_HASKELL__ >= 703
{-# LANGUAGE Safe #-}
#endif
-----------------------------------------------------------------------------
-- |
-- Module : Data.Map.Lazy
-- Copyright : (c) Daan Leijen 2002
-- (c) Andriy Palamarchuk 2008
-- License : ... | technogeeky/d-A | include/containers-0.5.0.0/Data/Map/Lazy.hs | gpl-3.0 | 5,877 | 0 | 5 | 2,386 | 452 | 331 | 121 | 106 | 0 |
import Control.Monad.Fix
import Data.IORef
data N a = N (IORef Bool, N a, a, N a)
newNode :: N a -> a -> N a -> IO (N a)
newNode b c f = do v <- newIORef False
return (N (v, b, c, f))
ll = mdo n0 <- newNode n3 0 n1
n1 <- newNode n0 1 n2
n2 <- newNode n1 2 n3
n3 <- newNo... | frantisekfarka/ghc-dsi | testsuite/tests/ghci.debugger/mdo.hs | bsd-3-clause | 1,012 | 1 | 14 | 439 | 525 | 257 | 268 | -1 | -1 |
{-# LANGUAGE TypeSynonymInstances, FlexibleInstances #-}
-- Utility functions for the test suite.
module Tests.Helpers ( test
, (=?>)
, property
, ToString(..)
, ToPandoc(..)
)
where
import Te... | gbataille/pandoc | tests/Tests/Helpers.hs | gpl-2.0 | 2,524 | 0 | 15 | 746 | 765 | 416 | 349 | 67 | 2 |
{-# LANGUAGE GADTs, TypeFamilies #-}
module T10562 where
type family Flip a
data QueryRep qtyp a where
QAtom :: a -> QueryRep () a
QOp :: QueryRep (Flip qtyp) a -> QueryRep qtyp a
instance Eq (QueryRep qtyp a) where
(==) = error "urk"
instance (Ord a) => Ord (QueryRep qtyp a) where
compare (QOp a) (QO... | urbanslug/ghc | testsuite/tests/typecheck/should_compile/T10562.hs | bsd-3-clause | 341 | 0 | 9 | 80 | 137 | 75 | 62 | 10 | 0 |
-- @Author: Zeyuan Shang
-- @Date: 2016-06-01 19:22:05
-- @Last Modified by: Zeyuan Shang
-- @Last Modified time: 2016-06-01 19:25:14
data Tree a = Node a [Tree a]
deriving (Eq, Show)
ipl :: Tree a -> Int
ipl = ipl' 0
where ipl' x (Node _ ts) = x + (sum $ map (ipl' (x + 1)) ts)
tree1 = Node 'a' []
tree2 =... | zeyuanxy/haskell-playground | ninety-nine-haskell-problems/vol8/71.hs | mit | 640 | 19 | 12 | 207 | 282 | 146 | 136 | 16 | 1 |
module Ives.ExampleGen.Conc (concretify, send) where
import qualified Data.Map.Strict as Map
import qualified Data.Set as Set
import Control.Monad
import Language.Haskell.TH
import Language.Haskell.TH.Syntax
send :: Name -> Q Exp
send nm = do
return $ VarE nm
preferredTys :: Q [Type]
... | santolucito/ives | Ives/ExampleGen/Conc.hs | mit | 2,964 | 5 | 16 | 623 | 1,051 | 510 | 541 | 69 | 4 |
module Recursion where
fib :: Int -> Int
fib 0 = 0
fib 1 = 1
fib x = fib (x-1) + fib (x-2)
altMaximum' :: (Ord a) => [a] -> a
altMaximum' [] = error "maximum of empty list"
altMaximum' [x] = x
altMaximum' (x:xs)
| x > maxTail = x
| otherwise = maxTail
where maxTail = altMaximum' xs
maximum' :: (Ord a) =... | bionikspoon/playing-with-haskell---learnyouahaskell | recursion.hs | mit | 1,326 | 0 | 12 | 341 | 835 | 443 | 392 | 47 | 1 |
-- |
-- Module: Math.NumberTheory.Powers.Integer
-- Copyright: (c) 2011-2014 Daniel Fischer
-- Licence: MIT
-- Maintainer: Daniel Fischer <daniel.is.fischer@googlemail.com>
-- Stability: Provisional
-- Portability: Non-portable (GHC extensions)
--
-- Potentially faster power function for 'Integer' base an... | Bodigrim/integer-logarithms | src/Math/NumberTheory/Powers/Integer.hs | mit | 1,775 | 0 | 6 | 322 | 98 | 75 | 23 | 12 | 1 |
------------------------------------------------------------------------------
-- | This module is where all the routes and handlers are defined for the
-- site. The 'haskitterInit' function is the initializer that combines everything
-- together and is exported by this module.
module Site
( haskitterInit
) w... | lkania/Haskitter | src/Site.hs | mit | 7,596 | 0 | 14 | 1,500 | 1,713 | 867 | 846 | 117 | 12 |
module HsPredictor.ANN where
import HFANN
fannDef :: [Int]
fannDef = [6, 3, 1]
{-| Train artificial neural network and save trained network to file. -}
trainAndSaveANN :: String -- ^ path to exported file
-> String -- ^ where save network
-> Int -- ^ number of epochs
... | Taketrung/HsPredictor | library/HsPredictor/ANN.hs | mit | 963 | 0 | 11 | 255 | 184 | 97 | 87 | 20 | 1 |
{-# OPTIONS_GHC -fno-warn-unused-binds -fno-warn-orphans #-}
{-# LANGUAGE UndecidableInstances #-} -- FIXME
{-# LANGUAGE QuasiQuotes #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE NoMonomorphismRestriction #-}
{-# LANGUAGE CPP #-}
{-# LANGUAGE... | pseudonom/persistent | persistent-test/src/PersistentTest.hs | mit | 33,819 | 14 | 25 | 9,756 | 9,216 | 4,401 | 4,815 | 654 | 1 |
module Handler.CommandSpec
( main
, spec
) where
import SpecHelper
import Data.UUID (fromText)
data Response = Response Token
instance FromJSON Response where
parseJSON = withObject "Response" $ \o -> Response
<$> (parseToken =<< o .: "token")
where
parseToken = maybe mzero (re... | pbrisbin/tee-io | test/Handler/CommandSpec.hs | mit | 1,592 | 0 | 20 | 539 | 434 | 212 | 222 | 37 | 1 |
{-# OPTIONS_GHC -fno-warn-orphans #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE TypeSynonymInstances #-}
module PostgREST.Error (pgErrResponse, errResponse) where
import Data.Aeson ((.=))
import qualified Data.Aeson as JSON
import Data.Monoid (... | motiz88/postgrest | src/PostgREST/Error.hs | mit | 3,821 | 0 | 13 | 819 | 1,207 | 656 | 551 | 76 | 25 |
{- |
Module representing a JSON-API resource object.
Specification: <http://jsonapi.org/format/#document-resource-objects>
-}
module Network.JSONApi.Resource
( Resource (..)
, Relationships
, ResourcefulEntity (..)
, Relationship
, mkRelationship
, mkRelationships
) where
import Control.Lens.TH
import Data.Aeson (ToJ... | toddmohney/json-api | src/Network/JSONApi/Resource.hs | mit | 4,164 | 0 | 13 | 805 | 1,039 | 558 | 481 | -1 | -1 |
module Problem0030 where
import Data.Char
import Data.List(sort)
type Composite = (OriginalNumber, SumOfPowers, DigitsLeft, SumIsLessThanOrEqualToNumber, SumIsEqualToOriginal)
type OriginalNumber = Int
type SumOfPowers = Int
type DigitsLeft = [Int]
type SumIsLessThanOrEqualToNumber = Bool
type SumIsEq... | Sobieck00/practice | pe/nonvisualstudio/haskell/problem0030/Solution.hs | mit | 2,497 | 0 | 17 | 618 | 656 | 363 | 293 | 47 | 2 |
{-# LANGUAGE TypeFamilies #-}
module Drifter.Types where
import Data.Text
type Name = Text
type Description = Text
data Change a = Change
{ changeName :: Name
, changeDescription :: Maybe Description
, changeDependencies :: [Name]
, changeMethod :: Met... | MichaelXavier/drifter | src/Drifter/Types.hs | mit | 478 | 0 | 12 | 148 | 121 | 71 | 50 | 14 | 0 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE BangPatterns #-}
{-# LANGUAGE KindSignatures #-}
{-# LANGUAGE MagicHash #-}
{-# LANGUAGE MultiWayIf #-}
{-# LANGUAGE PostfixOperators #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE BangPatterns #-}
--------------------------------------------------------------------------... | expipiplus1/exact-real | src/Data/CReal/Internal.hs | mit | 25,738 | 2 | 22 | 7,974 | 7,483 | 3,908 | 3,575 | 463 | 6 |
module Handler.Purge where
import Import
import Handler.Common
purge = runDB $ do
deleteWhere ([] :: [Filter Poll])
deleteWhere ([] :: [Filter Votes])
compareIp :: Text -> HandlerT App IO Bool
compareIp myIp = do
ip <- getIp
return $ ip == myIp
getPurgeR :: Handler Html
getPurgeR = do
approval ... | sramekj/lunchvote | Handler/Purge.hs | mit | 663 | 0 | 14 | 221 | 182 | 93 | 89 | -1 | -1 |
{-# LANGUAGE OverloadedStrings #-}
module Presenter.FileAuto (
-- *Functions
fileAuto
) where
import Control.Auto(arrM)
import Control.Exception(SomeException(..), try)
import Control.Monad(void, when)
import Control.Monad.Trans(liftIO)
import qualified Data.Text as T
import System.Directo... | jvilar/hrows | lib/Presenter/FileAuto.hs | gpl-2.0 | 3,546 | 0 | 21 | 988 | 1,147 | 567 | 580 | 76 | 6 |
Config {
font = "xft:Dejavu Sans Mono:size=10:regular:antialias=true"
-- bgColor = "#362b12",
fgColor = "#fff897",
bgColor = "#000000",
-- fgColor = "#ffffff",
position = Static { xpos = 0, ypos = 0, width = 1920, height = 25 },
lowerOnStart = True,
commands = [
Run Weather "UU... | ulyanin/xmonad-config | xmobar.hs | gpl-3.0 | 1,961 | 2 | 9 | 703 | 382 | 239 | 143 | -1 | -1 |
{-# Language TemplateHaskell #-}
module Infsabot.Parameters(
LinearF(LinearF), apply,
Parameters(Parameters),
paramBoardSize,
paramNoopCost,
paramMoveCost,
paramDigCost,
paramNewRobotCost,
paramFireCost,
paramInitialHP,
... | kavigupta/Infsabot | Infsabot/Parameters.hs | gpl-3.0 | 1,665 | 0 | 9 | 438 | 372 | 226 | 146 | 58 | 1 |
{-# OPTIONS -cpp #-}
{-# LANGUAGE ScopedTypeVariables #-}
import System.Environment (getArgs)
import System.Directory
import System.Plugins
import Data.List
import PluginAPI
import Control.Applicative
import Pipes.Safe (Base, MonadSafe, bracket)
import Control.Monad (unless, when)
import Pipes (lift, every, runEffect,... | glueckself/mhaskell-ss14 | Main.hs | gpl-3.0 | 2,024 | 0 | 14 | 511 | 569 | 295 | 274 | 41 | 2 |
module Main where
import qualified Jinzamomi.Driver as D
import System.Log.Logger
import System.Log.Handler.Syslog
import System.Log.Handler.Simple
import System.Log.Handler (setFormatter)
import System.Log.Formatter
import qualified GHC.IO.Handle.FD as FD
import System.Environment (getArgs)
import Options.Applicative... | ledyba/Jinzamomi | app/Main.hs | gpl-3.0 | 2,194 | 0 | 13 | 431 | 534 | 276 | 258 | 58 | 1 |
module Model.PerpetualGrant where
import Data.Aeson
import Import
instance ToJSON (Entity PerpetualGrant) where
toJSON (Entity pgid pg) = object
[ "id" .= pgid
, "recordingUID" .= perpetualGrantRecordingUID pg
, "recipientKeyFingerprint" .= perpetualGr... | rumuki/rumuki-server | src/Model/PerpetualGrant.hs | gpl-3.0 | 476 | 0 | 9 | 155 | 94 | 49 | 45 | 10 | 0 |
module Dragonfly.Application (
showRootPage,
handleRoot,
handleSignOut
) where
import Control.Monad
import Data.ByteString.Lazy (unpack)
import Data.Char (chr)
import Text.XHtml
import Text.XHtml.Strict
import Happstack.Server
import Ha... | colin-adams/dragonfly-website | Dragonfly/Application.hs | gpl-3.0 | 2,336 | 0 | 20 | 689 | 615 | 320 | 295 | 53 | 3 |
module Synacor.Debugger where
import Control.Monad
import Control.Monad.Fix (fix)
import Control.Concurrent
import Control.Concurrent.MVar
import Control.Exception
import qualified Data.Map as M
import Data.Word
import Network.Socket
import System.Exit (di... | ChrisCoffey/synacor_challenge | Synacor/src/Synacor/Debugger.hs | gpl-3.0 | 4,220 | 0 | 19 | 1,912 | 1,232 | 597 | 635 | 109 | 9 |
-- (C) Copyright Chris Banks 2011
-- This file is part of The Continuous Pi-calculus Workbench (CPiWB).
-- CPiWB is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License... | continuouspi/cpiwb | CPi/Semantics.hs | gpl-3.0 | 23,339 | 7 | 24 | 7,909 | 8,141 | 4,242 | 3,899 | 404 | 18 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.