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 OverloadedStrings #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE QuasiQuotes #-}
{-# LANGUAGE DataKinds #-}
module Main where
import Data.Default
import Text.Haiji
import qualified Data.Text as T
import qualified Data.Text.Lazy as LT
import qualified Data.Text.Lazy.IO as LT
main :: IO ()
main = LT.put... | notogawa/haiji | example.hs | bsd-3-clause | 828 | 0 | 14 | 275 | 219 | 143 | 76 | 21 | 1 |
-- | UI of inventory management.
module Game.LambdaHack.Client.UI.InventoryM
( Suitability(..), ResultItemDialogMode(..)
, getFull, getGroupItem, getStoreItem
, skillCloseUp, placeCloseUp, factionCloseUp
#ifdef EXPOSE_INTERNAL
-- * Internal operations
, ItemDialogState(..), accessModeBag, storeItemPrompt, g... | LambdaHack/LambdaHack | engine-src/Game/LambdaHack/Client/UI/InventoryM.hs | bsd-3-clause | 35,792 | 0 | 26 | 11,144 | 9,273 | 4,763 | 4,510 | -1 | -1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveAnyClass #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE StandaloneDeriving #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE TypeSynonymInstances #-}
module CommonRe... | Garygunn94/DFS | CommonResources/src/CommonResources.hs | bsd-3-clause | 5,480 | 16 | 21 | 1,084 | 1,707 | 926 | 781 | 136 | 2 |
module Main where
import Data.Maybe (isNothing, isJust)
import System.IO
import Network.Socket
import qualified System.Process as SysProc
import qualified System.Process.Internals as SysProcInt (withProcessHandle, ProcessHandle__(..))
import Control.Concurrent.MVar
import qualified System.Posix.Signals as Sig
main ::... | diekmann/tinyrsh | rsh-impls/hs-idiomatic/tinyrsh/app/Main.hs | bsd-3-clause | 2,836 | 0 | 17 | 751 | 800 | 396 | 404 | 56 | 3 |
{-# LANGUAGE RecursiveDo #-}
-- Example: Analysis of a PERT-type Network
--
-- It is described in different sources [1, 2]. So, this is chapter 14 of [2] and section 7.11 of [1].
--
-- PERT is a technique for evaluating and reviewing a project consisting of
-- interdependent activities. A number of books have been w... | dsorokin/aivika-experiment-chart | examples/PERT/Model.hs | bsd-3-clause | 5,728 | 0 | 14 | 1,761 | 717 | 397 | 320 | 60 | 1 |
module Graph.MST.Plain where
import qualified Graph.Weighted as W
import qualified Graph.MST.Kruskal
import Graph.Kreisfrei
import Graph.Connected
import Graph.Util
import Autolib.Dot ( peng, Layout_Program (..) )
import Autolib.Graph.Util ( isZusammen , anzKanten , anzKnoten )
import Autolib.Graph.SpanTree ( weigh... | florianpilz/autotool | src/Graph/MST/Plain.hs | gpl-2.0 | 3,464 | 53 | 11 | 1,008 | 535 | 371 | 164 | -1 | -1 |
{-# LANGUAGE OverloadedStrings #-}
module KAT_PubKey.DSA (dsaTests) where
import qualified Crypto.PubKey.DSA as DSA
import Crypto.Hash
import Imports
data VectorDSA = VectorDSA
{ pgq :: DSA.Params
, msg :: ByteString
, x :: Integer
, y :: Integer
, k :: Integer
, r :: Integer
, s :: Integ... | vincenthz/cryptonite | tests/KAT_PubKey/DSA.hs | bsd-3-clause | 31,104 | 0 | 12 | 3,692 | 2,199 | 1,356 | 843 | 299 | 1 |
{-# LANGUAGE Trustworthy #-}
{-# LANGUAGE CPP, NoImplicitPrelude #-}
-----------------------------------------------------------------------------
-- |
-- Module : Foreign.C.String
-- Copyright : (c) The FFI task force 2001
-- License : BSD-style (see the file libraries/base/LICENSE)
--
-- Maintainer : ... | rahulmutt/ghcvm | libraries/base/Foreign/C/String.hs | bsd-3-clause | 14,674 | 0 | 16 | 2,986 | 2,344 | 1,290 | 1,054 | 161 | 3 |
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE TupleSections #-}
module HERMIT.Dictionary.Unfold
( externals
, betaReducePlusR
, unfoldR
, unfoldPredR
, unfoldNameR
, unfoldNamesR
, unfoldSaturatedR
, specializeR
) whe... | conal/hermit | src/HERMIT/Dictionary/Unfold.hs | bsd-2-clause | 4,084 | 0 | 13 | 885 | 1,024 | 540 | 484 | 70 | 2 |
module IOFullyQualifiedUsed where
import qualified System.IO (putStrLn)
main :: IO ()
main = System.IO.putStrLn "test"
| serokell/importify | test/test-data/base@basic/24-IOFullyQualifiedUsed.hs | mit | 121 | 0 | 6 | 17 | 36 | 21 | 15 | 4 | 1 |
{-|
Module : Idris.Completion
Description : Support for command-line completion at the REPL and in the prover.
Copyright :
License : BSD3
Maintainer : The Idris Community.
-}
module Idris.Completion (replCompletion, proverCompletion) where
import Idris.AbsSyntax (runIO)
import Idris.AbsSyntaxTree
import Id... | markuspf/Idris-dev | src/Idris/Completion.hs | bsd-3-clause | 9,713 | 0 | 16 | 2,688 | 2,675 | 1,402 | 1,273 | 159 | 17 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE FlexibleInstances #-}
module TcCustomSolverSuper where
import GHC.TypeLits
import Data.Typeable
{-
When solving super-class instances, GHC solves the evidence without
using the solver (see `tcSuperClasses` in `TcInstDecls`).
However, some classes need to be excepted from this... | sdiehl/ghc | testsuite/tests/typecheck/should_compile/TcCustomSolverSuper.hs | bsd-3-clause | 726 | 0 | 6 | 136 | 63 | 34 | 29 | -1 | -1 |
<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE helpset PUBLIC "-//Sun Microsystems Inc.//DTD JavaHelp HelpSet Version 2.0//EN" "http://java.sun.com/products/javahelp/helpset_2_0.dtd">
<helpset version="2.0" xml:lang="sr-SP">
<title>AJAX Spider | ZAP Extensions</title>
<maps>
<homeID>top</homeID>
<mapref... | kingthorin/zap-extensions | addOns/spiderAjax/src/main/javahelp/org/zaproxy/zap/extension/spiderAjax/resources/help_sr_SP/helpset_sr_SP.hs | apache-2.0 | 973 | 78 | 66 | 159 | 413 | 209 | 204 | -1 | -1 |
{-# LANGUAGE CPP #-}
module Distribution.Simple.GHCJS (
configure, getInstalledPackages, getPackageDBContents,
buildLib, buildExe,
replLib, replExe,
startInterpreter,
installLib, installExe,
libAbiHash,
hcPkgInfo,
registerPackage,
componentGhcOptio... | Helkafen/cabal | Cabal/Distribution/Simple/GHCJS.hs | bsd-3-clause | 41,352 | 0 | 23 | 13,289 | 8,181 | 4,270 | 3,911 | 708 | 8 |
{-# LANGUAGE OverloadedStrings #-}
module Clay.Attributes where
import Clay.Selector
-- From: http://www.whatwg.org/specs/web-apps/current-work/multipage/section-index.html#index
accept, acceptCharset, accesskey, action, alt, async, autocomplete, autofocus,
autoplay, challenge, charset, checked, class_, cols, cols... | Heather/clay | src/Clay/Attributes.hs | bsd-3-clause | 3,332 | 0 | 5 | 481 | 782 | 556 | 226 | 126 | 1 |
{-# LANGUAGE DataKinds, TypeOperators, TypeFamilies #-}
{-# LANGUAGE UndecidableInstances, ScopedTypeVariables, FlexibleContexts #-}
module T11990b where
import GHC.TypeLits
import Data.Proxy
type family PartialTF t :: Symbol where
PartialTF Int = "Int"
PartialTF Bool = "Bool"
PartialTF a = TypeError (Text... | ezyang/ghc | testsuite/tests/typecheck/should_fail/T11990b.hs | bsd-3-clause | 981 | 0 | 11 | 207 | 252 | 135 | 117 | 21 | 1 |
{-# LANGUAGE Unsafe #-}
{-# LANGUAGE CPP, NoImplicitPrelude, MagicHash, RoleAnnotations #-}
{-# OPTIONS_HADDOCK hide #-}
-----------------------------------------------------------------------------
-- |
-- Module : GHC.Ptr
-- Copyright : (c) The FFI Task Force, 2000-2002
-- License : see libraries/base/... | tolysz/prepare-ghcjs | spec-lts8/base/GHC/Ptr.hs | bsd-3-clause | 6,465 | 0 | 15 | 1,196 | 711 | 423 | 288 | 44 | 2 |
{-# OPTIONS_GHC -O -funbox-strict-fields #-}
-- The combination of unboxing and a recursive newtype crashed GHC 6.6.1
-- Trac #1255
-- Use -O to force the unboxing to happen
module Foo where
newtype Bar = Bar Bar -- Recursive
data Gah = Gah { baaz :: !Bar }
| urbanslug/ghc | testsuite/tests/typecheck/should_compile/tc226.hs | bsd-3-clause | 265 | 0 | 9 | 55 | 33 | 22 | 11 | 6 | 0 |
module HAD.Y2014.M03.D21.Exercise where
-- $setup
-- >>> import Test.QuickCheck
-- >>> import Data.Maybe (fromJust)
-- | minmax
-- get apair of the min and max element of a list (in one pass)
-- returns Nothing on empty list
--
-- Point-free: checked
--
-- The function signature follows the idea of the methods in the... | geophf/1HaskellADay | exercises/HAD/Y2014/M03/D21/Exercise.hs | mit | 722 | 0 | 8 | 132 | 64 | 47 | 17 | 3 | 1 |
{-# LANGUAGE Arrows, FlexibleContexts #-}
module QNDA.ImageReader where
import Text.XML.HXT.Core hiding (xshow)
import System.Directory (copyFile, doesFileExist, getCurrentDirectory)
import qualified System.FilePath.Posix as FP
import qualified System.Process as Prc (readProcess)
import Network.HTTP.Base (urlEnco... | k16shikano/wikipepub | QNDA/ImageReader.hs | mit | 2,938 | 0 | 23 | 854 | 924 | 493 | 431 | 65 | 4 |
{-# LANGUAGE PatternGuards #-}
-----------------------------------------------------------------------------
-- |
-- Module : Game.Tournament
-- Copyright : (c) Eirik Albrigtsen 2012
-- License : MIT
-- Maintainer : Eirik <clux> Albrigtsen
-- Stability : unstable
--
-- Tournament construction and mai... | clux/tournament.hs | Game/Tournament.hs | mit | 29,171 | 0 | 18 | 7,041 | 7,752 | 4,178 | 3,574 | -1 | -1 |
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE QuasiQuotes #-}
module AoC201607
( runDay,
) where
import Data.List (tails)
import Str
import Text.Parsec
import Text.Parsec.String
runDay :: IO ()
runDay = do
let tlsCount = execute addressesParser fullInput
let sslCount = execute2 addressesParser fullInput
p... | rickerbh/AoC | AoC2016/src/AoC201607.hs | mit | 183,702 | 0 | 13 | 2,752 | 1,449 | 750 | 699 | 93 | 2 |
{-# LANGUAGE DeriveFunctor #-}
module Compiler.PreAST.Type.Statement where
import Compiler.Serializable
import Compiler.PreAST.Type.Symbol
import Compiler.PreAST.Type.Expression
--------------------------------------------------------------------------------
-- Statement
data Statement a = Assignment a (Expression ... | banacorn/mini-pascal | src/Compiler/PreAST/Type/Statement.hs | mit | 1,334 | 0 | 13 | 371 | 422 | 220 | 202 | 26 | 0 |
-- | This module provides utilities for rendering the 'Ann' type of the
-- API. 'Ann' gives extra structure to textual information provided by
-- the backend, by adding nested annotations atop the text.
--
-- In the current School of Haskell code, 'Ann' is used for source
-- errors and type info. This allows things lik... | fpco/schoolofhaskell | soh-client/src/View/Annotation.hs | mit | 5,613 | 8 | 14 | 1,070 | 1,165 | 619 | 546 | -1 | -1 |
{-# htermination elemIndex :: (Eq a, Eq k) => (a, k) -> [(a, k)] -> Maybe Int #-}
import List
| ComputationWithBoundedResources/ara-inference | doc/tpdb_trs/Haskell/full_haskell/List_elemIndex_12.hs | mit | 94 | 0 | 3 | 20 | 5 | 3 | 2 | 1 | 0 |
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE RecordWildCards #-}
module Main where
import qualified Data.ByteString.Char8 as B8
import Data.Char (toLower)
import Data.Monoid
import qualified Data.Text as T
import Myracloud
import Myracloud.Types hiding (value)
import Opti... | zalora/myrapi | src/Main.hs | mit | 4,358 | 0 | 15 | 1,126 | 1,181 | 590 | 591 | 130 | 3 |
{-# LANGUAGE DeriveAnyClass #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE UndecidableInstances #-}
module Betfair.APING.Types.InstructionReportStatus
... | joe9/betfair-api | src/Betfair/APING/Types/InstructionReportStatus.hs | mit | 739 | 0 | 9 | 163 | 108 | 68 | 40 | 19 | 0 |
module Main where
import Base
import Simple
import Infeasible
import Clustering
import Stupid
main :: IO ()
main
= do putStrLn "Simple"
simple
putStrLn "Infeasible"
infeasible
putStrLn "Clustering"
clustering
putStrLn "Stupid"
stupid
| amosr/limp-cbc | examples/Test.hs | mit | 296 | 0 | 7 | 94 | 70 | 33 | 37 | 16 | 1 |
module Handler.Github where
import Import
import Blaze.ByteString.Builder (copyByteString, toByteString)
getGithubR :: Handler ()
getGithubR = do
_ <- requireProfile
mdest <- lookupGetParam "dest"
dest <-
case mdest of
Nothing -> fmap ($ ProfileR) getUrlRender
Just dest -> ... | fpco/schoolofhaskell.com | src/Handler/Github.hs | mit | 1,365 | 0 | 15 | 361 | 303 | 150 | 153 | -1 | -1 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
module SyntheticWeb.Observer
( service
) where
import Control.Applicative ((<|>))
import Control.Monad (forM_)
import Control.Monad.IO.Class (liftIO)
import qualified Data.ByteString.Char8 as BS
import Data.Time (NominalDiffTime)
import ... | kosmoskatten/synthetic-web | src/SyntheticWeb/Observer.hs | mit | 5,709 | 0 | 13 | 1,904 | 1,226 | 657 | 569 | 127 | 1 |
module Carbon.DataStructures.Trees.SelfBalancingBinarySearchTree (Tree (..), create, from_list, to_list, remove, removeall, count, find, size, height, add, prettyprint, rotate_cw, rotate_ccw) where
import qualified Carbon.DataStructures.Trees.GenericBinaryTree as GenericBinaryTree
import Data.List (foldl')
import Deb... | Raekye/Carbon | haskell/src/Carbon/DataStructures/Trees/SelfBalancingBinarySearchTree.hs | mit | 5,693 | 31 | 20 | 1,237 | 2,819 | 1,464 | 1,355 | 119 | 9 |
module Main where
import Serve
import Handler.Scim.Portal
main = serve "13573" scimPortalHandler | stnma7e/scim_serv | portal/Main.hs | mit | 98 | 0 | 5 | 13 | 23 | 14 | 9 | 4 | 1 |
--------------------------------------------------------------------------------
-- |
-- Module : System.Socket.Unsafe
-- Copyright : (c) Lars Petersen 2015
-- License : MIT
--
-- Maintainer : info@lars-petersen.net
-- Stability : experimental
---------------------------------------------------------... | lpeterse/haskell-socket | src/System/Socket/Unsafe.hs | mit | 3,952 | 0 | 25 | 848 | 811 | 434 | 377 | 55 | 3 |
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE ScopedTypeVariables #-}
module Solver where
import Control.Monad
import Control.Monad.Loops
import Data.Bifunctor
import Data.List
import Data.List.HT
import Data.Monoid
import Data.Ratio
import qualified Gaussian as G
{-
Notes about this module:
for the purpose o... | Javran/misc | gaussian-elim/src/Solver.hs | mit | 6,510 | 0 | 23 | 2,263 | 2,349 | 1,251 | 1,098 | 151 | 6 |
-- | Data.TSTP.V module.
-- Adapted from https://github.com/agomezl/tstp2agda.
module Data.TSTP.V
( V
( V )
) where
------------------------------------------------------------------------------
import Athena.Utils.PrettyPrint ( Pretty ( pretty ) )
import Athena.Translation.Utils ( stdName )
-------------... | jonaprieto/athena | src/Data/TSTP/V.hs | mit | 696 | 0 | 8 | 113 | 108 | 67 | 41 | 11 | 0 |
{-# language NoImplicitPrelude, DoAndIfThenElse, OverloadedStrings, ExtendedDefaultRules #-}
{-# LANGUAGE CPP #-}
-- | Description : Shell scripting wrapper using @Shelly@ for the @notebook@, and
-- @console@ commands.
module IHaskell.IPython (
replaceIPythonKernelspec,
defaultConfFile,
get... | sumitsahrawat/IHaskell | src/IHaskell/IPython.hs | mit | 10,974 | 0 | 20 | 2,728 | 2,561 | 1,324 | 1,237 | 223 | 4 |
module Monoid3 where
import Data.Semigroup
import Test.QuickCheck
import SemiGroupAssociativeLaw
import MonoidLaws
import ArbitrarySum
data Two a b = Two a b deriving (Eq, Show)
instance (Semigroup a, Semigroup b) => Semigroup (Two a b) where
(Two x1 y1) <> (Two x2 y2) = Two (x1 <> x2) (y1 <> y2)
instance... | NickAger/LearningHaskell | HaskellProgrammingFromFirstPrinciples/Chapter15.hsproj/Monoid3.hs | mit | 869 | 0 | 12 | 181 | 390 | 203 | 187 | 20 | 1 |
{-# LANGUAGE CPP, GeneralizedNewtypeDeriving, OverloadedStrings #-}
{-
compatibility with older GHC
-}
module Compiler.Compat ( PackageKey
, packageKeyString
, modulePackageKey
, stringToPackageKey
, primPackageKey
... | ghcjs/ghcjs | src/Compiler/Compat.hs | mit | 3,659 | 0 | 13 | 914 | 768 | 421 | 347 | 83 | 1 |
import Data.List (delete)
-- adorable solution by Mgccl
permute [] = [[]]
permute xs = concat $ map (\x-> map (x:) (permute (delete x xs))) xs
printColumn [] = putStrLn ""
printColumn (x:xs) = do
putStrLn $ unwords $ map show x
printColumn xs
n = 4
main = do
let l = [1..n]
let p = permute l
... | forgit/Rosalind | perm.hs | gpl-2.0 | 358 | 1 | 13 | 99 | 180 | 87 | 93 | 13 | 1 |
{-# LANGUAGE TypeSynonymInstances, FlexibleInstances #-}
{- |
Module : $Header$
Description : Abstract syntax for EnCL
Copyright : (c) Dominik Dietrich, Ewaryst Schulz, DFKI Bremen 2010
License : GPLv2 or higher, see LICENSE.txt
Maintainer : Ewaryst.Schulz@dfki.de
Stability : experimental
Portabili... | nevrenato/Hets_Fork | CSL/AS_BASIC_CSL.hs | gpl-2.0 | 18,108 | 0 | 25 | 5,560 | 3,753 | 2,110 | 1,643 | 343 | 51 |
type Op a x = x -> a | hmemcpy/milewski-ctfp-pdf | src/content/2.4/code/haskell/snippet03.hs | gpl-3.0 | 20 | 0 | 5 | 7 | 13 | 8 | 5 | 1 | 0 |
module Test.Control.Monad.Progress where
| Purview/purview | test/Test/Control/Monad/Progress.hs | gpl-3.0 | 42 | 0 | 3 | 4 | 8 | 6 | 2 | 1 | 0 |
module Math.Structure.Module
( LinearSemiringLeftAction
, LinearSemiringRightAction
, LeftModule
, RightModule
, Module
, NonUnitalLeftModule
, NonUnitalRightModule
, NonUnitalModule
, SemiLeftAlgebra
, SemiRightAlgebra
, SemiAlgebra
, LeftAlgebra
, RightAlgebra
, Algebra
, NonUnitalL... | martinra/algebraic-structures | src/Math/Structure/Module.hs | gpl-3.0 | 504 | 0 | 4 | 86 | 81 | 55 | 26 | 21 | 0 |
module Main where
import Data.Foldable
import Diagrams.Prelude
import Diagrams.Backend.Cairo.CmdLine
import Debug.Trace
centerDot :: Diagram B
centerDot = circle 0.5 # fc red
data Label = Label
{ label :: String
, posX :: Double
, posY :: Double
, parity :: Bool
}
boxed :: Label -> Diagram B
boxed L... | gallais/potpourri | haskell/stopmotion/src/Main.hs | gpl-3.0 | 2,162 | 0 | 22 | 610 | 967 | 496 | 471 | -1 | -1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-dataproc/gen/Network/Google/Resource/Dataproc/Projects/Regions/Operations/SetIAMPolicy.hs | mpl-2.0 | 6,160 | 0 | 16 | 1,298 | 783 | 459 | 324 | 122 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-identity-toolkit/gen/Network/Google/Resource/IdentityToolkit/RelyingParty/SetProjectConfig.hs | mpl-2.0 | 3,457 | 0 | 13 | 706 | 308 | 189 | 119 | 55 | 1 |
{-# LANGUAGE BangPatterns
, CPP
, RecordWildCards
, TypeFamilies
, TypeOperators #-}
module Vision.Image.RGB.Type (
RGB, RGBPixel (..), RGBDelayed
) where
#if __GLASGOW_HASKELL__ < 710
import Control.Applicative ((<$>), (<*>))
#endif
import Data.Word
import Forei... | RaphaelJ/friday | src/Vision/Image/RGB/Type.hs | lgpl-3.0 | 1,945 | 0 | 12 | 594 | 547 | 300 | 247 | 52 | 0 |
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TemplateHaskell #-}
{- |
This is where all the real code for the cartographer lives.
-}
module Network.Eureka.Cartographer.HTTP (
Config(..),
withEureka,
website
) where
import Prelude hiding (lookup)... | SumAll/haskell-cartographer-server | src/Network/Eureka/Cartographer/HTTP.hs | apache-2.0 | 7,188 | 0 | 17 | 1,486 | 1,685 | 937 | 748 | 156 | 2 |
module FFMpegCommandSpec where
import Test.HUnit
import FFMpegCommand
runFFMpegCommandTests = runTestTT tests
tests = TestList [ TestLabel "Test Single Time" testSingleTime
, TestLabel "Test Two Times" testTwoTimes ]
testSingleTime = TestCase (
assertEqual "test.mkv 00:00:01" (Just "ffmpeg -i tes... | connrs/ffsplitgen | test/FFMpegCommandSpec.hs | apache-2.0 | 1,087 | 0 | 10 | 162 | 167 | 88 | 79 | 12 | 1 |
{-# LANGUAGE EmptyDataDecls #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE GADTs #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE QuasiQuotes #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANG... | coursestitch/coursestitch-api | lib/CourseStitch/Models/Tables.hs | apache-2.0 | 1,841 | 0 | 7 | 447 | 91 | 61 | 30 | 18 | 0 |
-- http://www.codewars.com/kata/5467e4d82edf8bbf40000155
module DescendingOrder where
import Data.List
descendingOrder :: Integer -> Integer
descendingOrder = foldl (\acc n -> acc * 10 + n) 0 . sortBy (flip compare) . map (`mod`10) . takeWhile (>0) . iterate (`div`10)
| Bodigrim/katas | src/haskell/7-Descending-Order.hs | bsd-2-clause | 271 | 0 | 13 | 39 | 97 | 55 | 42 | 4 | 1 |
{-# OPTIONS -fglasgow-exts #-}
-----------------------------------------------------------------------------
{-| Module : QSystemTrayIcon_h.hs
Copyright : (c) David Harley 2010
Project : qtHaskell
Version : 1.1.4
Modified : 2010-09-02 17:02:18
Warning : this file is machine generated ... | keera-studios/hsQt | Qtc/Gui/QSystemTrayIcon_h.hs | bsd-2-clause | 13,411 | 0 | 18 | 2,866 | 4,196 | 2,003 | 2,193 | -1 | -1 |
module Spring13.Week4.Week4Spec where
import Test.Hspec
import Test.QuickCheck
import Spring13.Week4.Week4
main :: IO ()
main = hspec spec
spec :: Spec
spec =
do describe "fun1'" $
do it "property" $
do property $ \xs -> fun1' xs == fun1 (xs :: [Integer])
describe "fun2'" $
do it "c... | bibaijin/cis194 | test/Spring13/Week4/Week4Spec.hs | bsd-3-clause | 2,272 | 0 | 22 | 1,173 | 705 | 350 | 355 | 60 | 2 |
{-# LANGUAGE DataKinds #-}
module Data.SoftHeap.SHselect(shSelect) where
import Data.SoftHeap
import Control.Monad.ST
import Data.Natural
sOne=SSucc SZero
sTwo=SSucc sOne
sThree=SSucc sTwo
--returns
partition :: (Ord k) => [k] -> k -> Int
partition l x = undefined
slice :: Int -> Int -> [k] -> [k]
slice from to xs... | formrre/soft-heap-haskell | soft-heap/src/Data/SoftHeap/SHselect.hs | bsd-3-clause | 1,213 | 0 | 16 | 289 | 629 | 314 | 315 | 35 | 2 |
{-# LANGUAGE LambdaCase, RankNTypes #-}
module Sloch
( LangToSloc
, PathToLangToSloc
, sloch
, summarize
, summarize'
) where
import Data.Map (Map)
import qualified Data.Map as M
import Data.Map.Extras (adjustWithDefault)
import Dirent (makeDirent, direntsAtDepth)
import Language ... | mitchellwrosen/Sloch | src/sloch/Sloch.hs | bsd-3-clause | 1,888 | 0 | 14 | 396 | 439 | 240 | 199 | 32 | 2 |
module Traduisons.Client where
import Control.Monad.Except
import Control.Monad.State
import qualified Data.Map as M
import Data.List
import Data.List.Split
import Traduisons.API
import Traduisons.Types
import Traduisons.Util
helpMsg :: String
helpMsg = "Help yourself."
runTest :: String -> ExceptT TraduisonsError... | bitemyapp/traduisons-hs | src/Traduisons/Client.hs | bsd-3-clause | 3,789 | 0 | 14 | 724 | 1,271 | 629 | 642 | 82 | 5 |
module Lang.Csharp where
import Lang.Value
import Generic.Control.Function
import Generic.Data.Bool
import Generic.Data.Either
import Generic.Data.List
import Generic.Data.Maybe
import Generic.Data.Number
import Generic.Data.Tuple
import qualified Prelude
data Csharp
type Cs a = Val Csharp a
instance Prelude.Show (P... | tomlokhorst/AwesomePrelude | src/Lang/Csharp.hs | bsd-3-clause | 2,713 | 0 | 16 | 685 | 1,206 | 651 | 555 | -1 | -1 |
module System.Taffybar.Widget.Text.MemoryMonitor (textMemoryMonitorNew, showMemoryInfo) where
import Control.Monad.IO.Class ( MonadIO )
import qualified Data.Text as T
import qualified Text.StringTemplate as ST
import System.Taffybar.Information.Memory
import System.Taffybar.Widget.Generic.PollingLabel ( pollingLabelN... | teleshoes/taffybar | src/System/Taffybar/Widget/Text/MemoryMonitor.hs | bsd-3-clause | 2,323 | 0 | 11 | 821 | 505 | 281 | 224 | 55 | 5 |
module TodoFormat
(
MyTime
, hasTime
, whenToRec
, unWhen
, whenToDay
, whenToTime
, whenToDayOfMonth
, whenToDayOfWeek
, whenToDuration
, matchDay
, compareTime
, toMyTime
, toMyTimeAllDay
, daily
, monthl... | sejdm/smartWallpaper | src/TodoFormat.hs | bsd-3-clause | 3,701 | 0 | 13 | 849 | 1,159 | 602 | 557 | 82 | 6 |
-- | Double-buffered storage
--
-- This module provides a safer alternative to the methods of the classes
-- 'Manifestable' and 'Manifestable2':
--
-- * 'store' instead of 'manifest'
-- * 'store2' instead of 'manifest2'
-- * 'setStore' instead of 'manifestStore'
-- * 'setStore2' instead of 'manifestStore2'
--
-- Consid... | kmate/raw-feldspar | src/Feldspar/Data/Buffered.hs | bsd-3-clause | 6,440 | 0 | 14 | 1,613 | 1,388 | 701 | 687 | -1 | -1 |
{-|
Funsat aims to be a reasonably efficient modern SAT solver that is easy to
integrate as a backend to other projects. SAT is NP-complete, and thus has
reductions from many other interesting problems. We hope this implementation is
efficient enough to make it useful to solve medium-size, real-world problem
mappe... | dbueno/funsat | src/Funsat/Solver.hs | bsd-3-clause | 35,895 | 0 | 26 | 10,425 | 8,319 | 4,385 | 3,934 | -1 | -1 |
-----------------------------------------------------------------------------
-- |
-- Module : Distribution.Simple.Bench
-- Copyright : Johan Tibell 2011
-- License : BSD3
--
-- Maintainer : cabal-devel@haskell.org
-- Portability : portable
--
-- This is the entry point into running the benchmarks in a... | sopvop/cabal | Cabal/Distribution/Simple/Bench.hs | bsd-3-clause | 5,187 | 0 | 22 | 1,661 | 974 | 496 | 478 | 87 | 5 |
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE RankNTypes #-}
module Data.Logic.Boolean.Class where
import Control.Applicative
import Data.Functor.Identity
import Data.Functor.Compose
class Boolean r where
tt :: r
ff :: r
fromBool :: Bool -> r
fromBool b = if b then tt else ff
data AnyBoolean = AnyBoolean
... | kylcarte/finally-logical | src/Data/Logic/Boolean/Class.hs | bsd-3-clause | 1,653 | 0 | 11 | 464 | 711 | 391 | 320 | 70 | 0 |
module Paths_AutoComplete (
version,
getBinDir, getLibDir, getDataDir, getLibexecDir,
getDataFileName
) where
import Data.Version (Version(..))
import System.Environment (getEnv)
version :: Version
version = Version {versionBranch = [0,1], versionTags = []}
bindir, libdir, datadir, libexecdir :: FilePa... | satvikc/Trie | dist/build/autogen/Paths_AutoComplete.hs | bsd-3-clause | 1,013 | 0 | 10 | 144 | 277 | 159 | 118 | 22 | 1 |
import System.Environment
import System.Directory
import System.IO
import Control.Exception
import qualified Data.ByteString.Lazy as B
main = do
(fileName1:fileName2:_) <- getArgs
copy fileName1 fileName2
copy source dest = do
contents <- B.readFile source
bracketOnError
(openTempFile "." "tem... | ku00/h-book | src/ByteStringCopy.hs | bsd-3-clause | 575 | 0 | 13 | 157 | 165 | 83 | 82 | 19 | 1 |
{-# LANGUAGE DeriveDataTypeable #-}
import System.Console.CmdArgs
import Data.Word
import Contract.Types
import Contract.Symbols
data Arguments = Arguments { symbol :: Symbol
, startTime :: TimeOffset
, startRate :: Rate
, points :... | thlorenz/Pricetory | src/spikes/CmdArgsSample.hs | bsd-3-clause | 830 | 0 | 10 | 280 | 177 | 96 | 81 | 17 | 1 |
{-# LANGUAGE TemplateHaskell, ScopedTypeVariables#-}
module UUTReader where
import Control.Monad
import Data.String.Utils
import Language.Haskell.TH
import GHC.Generics
import Sized
import Arbitrary
import TemplateAllv
import TemplateArbitrary
import TemplateSized
import UUT
import UUTReaderUtilities
import UUTReader... | pegartillo95/CaseGenerator | src/UUTReader.hs | bsd-3-clause | 1,873 | 0 | 17 | 339 | 451 | 240 | 211 | 32 | 2 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE TupleSections #-}
module Application (
app
) where
import Control.Exception
import Control.Monad (when)
import Data.Default.Class
import Data.Int (Int64)
import Data.Monoid
import Data.Pool (Pool)
import Data.Text.Lazy as Text
impo... | zalora/sproxy-web | src/Application.hs | mit | 12,687 | 0 | 15 | 3,040 | 3,267 | 1,582 | 1,685 | 245 | 6 |
{-# LANGUAGE TemplateHaskell, FunctionalDependencies, FlexibleContexts #-}
-- {-# OPTIONS_GHC -fno-warn-warnings-deprecations #-}
{-| Creates a client out of list of RPC server components.
-}
{-
Copyright (C) 2014 Google Inc.
This program is free software; you can redistribute it and/or modify
it under the terms o... | ribag/ganeti-experiments | src/Ganeti/THH/HsRPC.hs | gpl-2.0 | 3,961 | 0 | 15 | 735 | 738 | 391 | 347 | -1 | -1 |
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE ScopedTypeVariables #-}
-- |
-- Module : Network.AWS.Data.Numeric
-- Copyright : (c) 2013-2015 Brendan Hay
-- License : Mozilla Public License, v. 2.0.
-- M... | fmapfmapfmap/amazonka | core/src/Network/AWS/Data/Numeric.hs | mpl-2.0 | 1,925 | 0 | 14 | 692 | 370 | 205 | 165 | 50 | 1 |
{-# LANGUAGE FlexibleContexts, GeneralizedNewtypeDeriving, OverloadedStrings #-}
{-# LANGUAGE ScopedTypeVariables #-}
-- | Module : Network.MPD.Core
-- Copyright : (c) Ben Sinclair 2005-2009, Joachim Fasting 2010
-- License : MIT (see LICENSE)
-- Maintainer : Joachim Fasting <joachifm@fastmail.fm>
-- Stabili... | bens/libmpd-haskell | src/Network/MPD/Core.hs | lgpl-2.1 | 9,335 | 0 | 17 | 2,877 | 2,467 | 1,353 | 1,114 | 181 | 12 |
module Tandoori.GHC.Parse (parseMod, getDecls) where
import Tandoori.GHC.Internals
import HsSyn (hsmodDecls)
import Parser (parseModule)
import Lexer (unP, mkPState, ParseResult(..))
import StringBuffer (hGetStringBuffer)
import DynFlags (defaultDynFlags)
getDecls mod = hsmodDecls $ unLoc mod
parseM... | bitemyapp/tandoori | src/Tandoori/GHC/Parse.hs | bsd-3-clause | 746 | 0 | 12 | 235 | 187 | 99 | 88 | 14 | 2 |
{-# LANGUAGE CPP #-}
-----------------------------------------------------------------------------
-- |
-- Module : Distribution.Simple.GHC
-- Copyright : Isaac Jones 2003-2007
-- License : BSD3
--
-- Maintainer : cabal-devel@haskell.org
-- Portability : portable
--
-- This is a fairly large module. It... | seereason/cabal | Cabal/Distribution/Simple/GHC.hs | bsd-3-clause | 50,626 | 0 | 23 | 15,600 | 9,499 | 4,990 | 4,509 | 800 | 19 |
-----------------------------------------------------------------------------
-- |
-- Module : Control.Monad.Trans.State.Strict
-- Copyright : (c) Andy Gill 2001,
-- (c) Oregon Graduate Institute of Science and Technology, 2001
-- License : BSD-style (see the file LICENSE)
--
-- Maintainer ... | jwiegley/ghc-release | libraries/transformers/Control/Monad/Trans/State/Strict.hs | gpl-3.0 | 11,638 | 0 | 17 | 2,874 | 2,281 | 1,276 | 1,005 | 120 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# L... | romanb/amazonka | amazonka-iam/gen/Network/AWS/IAM/GetGroup.hs | mpl-2.0 | 5,619 | 0 | 16 | 1,348 | 862 | 508 | 354 | 89 | 1 |
-- (c) The University of Glasgow, 1997-2006
{-# LANGUAGE BangPatterns, CPP, MagicHash, UnboxedTuples,
GeneralizedNewtypeDeriving #-}
{-# OPTIONS_GHC -O -funbox-strict-fields #-}
-- We always optimise this, otherwise performance of a non-optimised
-- compiler is severely affected
-- |
-- There are two principal st... | olsner/ghc | compiler/utils/FastString.hs | bsd-3-clause | 20,911 | 0 | 26 | 4,819 | 4,110 | 2,128 | 1,982 | 331 | 5 |
module Snap.App
(module Snap.Core
,module Snap.App.Types
,module Snap.App.Controller
,module Snap.App.Model)
where
import Snap.Core
import Snap.App.Types
import Snap.App.Controller
import Snap.App.Model
| lwm/haskellnews | upstream/snap-app/src/Snap/App.hs | bsd-3-clause | 214 | 0 | 5 | 30 | 58 | 39 | 19 | 9 | 0 |
{-# OPTIONS_GHC -fno-warn-orphans #-}
{-# LANGUAGE ExistentialQuantification, FlexibleContexts, FlexibleInstances, StandaloneDeriving #-}
--------------------------------------------------------------------
-- |
-- Module : XMonad.Util.NamedActions
-- Copyright : 2009 Adam Vogt <vogt.adam@gmail.com>
-- License... | pjones/xmonad-test | vendor/xmonad-contrib/XMonad/Util/NamedActions.hs | bsd-2-clause | 12,707 | 0 | 16 | 2,907 | 3,056 | 1,755 | 1,301 | -1 | -1 |
module FVTests where
import FVision
import GraphicsZ
import GeometryZ
import qualified GeometryStatic as GS
import qualified Graphics as G
import FRP
import FRPSignal
import FRPTask
import qualified NXVision2 as XV
import IOExts (unsafePerformIO)
dotAt c p = withColor c $ moveTo p $ stretch 10 $ circle
testF p = r... | jatinshah/autonomous_systems | project/fvision.hugs/fvtests.hs | mit | 10,742 | 0 | 22 | 3,979 | 3,850 | 2,045 | 1,805 | 194 | 5 |
main = print $ foldl1 (+) [i | i <- [0..(1000 - 1)], i `mod` 3 == 0 || i `mod` 5 == 0]
| liuyang1/euler | 001.hs | mit | 87 | 0 | 13 | 24 | 68 | 38 | 30 | 1 | 1 |
{-# LANGUAGE ScopedTypeVariables #-}
-- | Effectful functions that create and convert disk image files.
module B9.DiskImageBuilder
( materializeImageSource,
substImageTarget,
preferredDestImageTypes,
preferredSourceImageTypes,
resolveImageSource,
createDestinationImage,
resizeImage,
impor... | sheyll/b9-vm-image-builder | src/lib/B9/DiskImageBuilder.hs | mit | 19,278 | 0 | 23 | 4,686 | 4,732 | 2,348 | 2,384 | -1 | -1 |
module Graphics.Urho3D.UI.Internal.FileSelector(
FileSelector
, fileSelectorCntx
, sharedFileSelectorPtrCntx
, weakFileSelectorPtrCntx
, SharedFileSelector
, WeakFileSelector
, FileSelectorEntry(..)
, HasName(..)
, HasDirectory(..)
) where
import Control.Lens
import GHC.Generics
import Graphics.U... | Teaspot-Studio/Urho3D-Haskell | src/Graphics/Urho3D/UI/Internal/FileSelector.hs | mit | 1,165 | 0 | 11 | 172 | 232 | 150 | 82 | -1 | -1 |
module Main where
import System.Environment
import Lib
main :: IO ()
main = do
env <- getEnvironment
let port = maybe 3000 read $ lookup "PORT" env
startApp port
| aaronshim/whenisbad | app/Main.hs | mit | 170 | 0 | 11 | 37 | 63 | 31 | 32 | 8 | 1 |
module System.AtomicWrite.Writer.Text.BinarySpec (spec) where
import Test.Hspec (Spec, describe, it,
shouldBe)
import System.AtomicWrite.Writer.Text.Binary (atomicWriteFile,
... | stackbuilders/atomic-write | spec/System/AtomicWrite/Writer/Text/BinarySpec.hs | mit | 5,286 | 0 | 18 | 1,629 | 884 | 433 | 451 | 77 | 1 |
module Oracles.Flag (
Flag (..), flag, platformSupportsSharedLibs,
ghcWithSMP, ghcWithNativeCodeGen, supportsSplitObjects
) where
import Hadrian.Oracles.TextFile
import Base
import Oracles.Setting
data Flag = ArSupportsAtFile
| CrossCompiling
| GccIsClang
| GccLt44
... | izgzhen/hadrian | src/Oracles/Flag.hs | mit | 2,920 | 0 | 14 | 840 | 605 | 316 | 289 | 64 | 12 |
module Language.Binal.StyleGuidance where
import Control.Applicative
import Control.Monad
import Control.Monad.Trans
import Control.Monad.State
import qualified Text.Trifecta as T
import qualified Text.Trifecta.Delta as D
import Language.Binal.Types
import qu... | pasberth/binal1 | Language/Binal/StyleGuidance.hs | mit | 3,787 | 0 | 17 | 948 | 1,308 | 657 | 651 | 94 | 7 |
module Phb.Db
( module Phb.Db.Internal
, module Phb.Db.Esqueleto
, module Phb.Db.Event
, module Phb.Db.Backlog
, module Phb.Db.Customer
, module Phb.Db.Action
, module Phb.Db.Person
, module Phb.Db.PersonLogin
, module Phb.Db.Project
, module Phb.Db.Heartbeat
, module Phb.Db.Success
, module Phb... | benkolera/phb | hs/Phb/Db.hs | mit | 965 | 0 | 5 | 279 | 216 | 149 | 67 | 33 | 0 |
{-# LANGUAGE OverloadedStrings #-}
-- | Style attributes.
--
-- See http://www.graphviz.org/doc/info/attrs.html#k:style for more info on graphviz styles
module Text.Dot.Attributes.Styles where
import Text.Dot.Types.Internal
-- * Style attributes
style :: AttributeName
style = "style"
-- * Style attribute... | NorfairKing/haphviz | src/Text/Dot/Attributes/Styles.hs | mit | 760 | 0 | 4 | 124 | 122 | 78 | 44 | 23 | 1 |
module Main where
import Control.Concurrent
import Control.Monad
import Network
import System.IO
main = do
putStrLn "aclick client"
forever $ do
h <- connectTo "localhost" (PortNumber (fromIntegral 6666))
hGetLine h
getLine >>= hPutStrLn h
hGetLine h >>= putStrLn
hClose h
| ZerglingRush/aclick | src/Client.hs | mit | 299 | 0 | 15 | 65 | 96 | 45 | 51 | 13 | 1 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TemplateHaskell #-}
module Main where
import Data.ByteString (ByteString)
import qualified Data.ByteString.Char8 as BC
import Data.FileEmbed (embedFile)
import Data.Foldable (traverse_)
import Data.List ... | genos/online_problems | advent_of_code_2016/day3/src/Main.hs | mit | 1,041 | 0 | 11 | 275 | 359 | 202 | 157 | 28 | 1 |
{-# LANGUAGE ScopedTypeVariables #-}
module TruthTable.Logic where
import TruthTable.Types
import TruthTable.Mapping
import Data.List (nub)
import qualified Data.Map.Strict as Map
uniqueVariables :: Statement -> [Variable]
uniqueVariables = nub . vars
where vars (StatementResult _) = []
vars (NestedSta... | tjakway/truth-table-generator | src/TruthTable/Logic.hs | mit | 3,033 | 0 | 15 | 947 | 855 | 436 | 419 | 52 | 5 |
{-# LANGUAGE CPP #-}
module GHCJS.DOM.SQLTransaction (
#if (defined(ghcjs_HOST_OS) && defined(USE_JAVASCRIPTFFI)) || !defined(USE_WEBKIT)
module GHCJS.DOM.JSFFI.SQLTransaction
#else
#endif
) where
#if (defined(ghcjs_HOST_OS) && defined(USE_JAVASCRIPTFFI)) || !defined(USE_WEBKIT)
import GHCJS.DOM.JSFFI.SQLTransactio... | plow-technologies/ghcjs-dom | src/GHCJS/DOM/SQLTransaction.hs | mit | 335 | 0 | 5 | 33 | 31 | 24 | 7 | 4 | 0 |
-- |Netrium is Copyright Anthony Waite, Dave Hewett, Shaun Laurens & Contributors 2009-2018, and files herein are licensed
-- |under the MIT license, the text of which can be found in license.txt
--
{-# LANGUAGE DeriveFunctor, GADTs, PatternGuards #-}
module DecisionTreeSimplify (
decisionTreeSimple,
decision... | netrium/Netrium | src/DecisionTreeSimplify.hs | mit | 5,104 | 0 | 21 | 1,808 | 943 | 500 | 443 | 60 | 11 |
{-# LANGUAGE TemplateHaskell #-}
{-# OPTIONS_GHC -O0 -fno-warn-missing-signatures -fno-warn-partial-type-signatures #-}
module Example.Extras where
name = "plugin"
| sboosali/simple-plugins | executables/Example/Extras.hs | mit | 165 | 0 | 4 | 17 | 13 | 9 | 4 | 4 | 1 |
module Jhc.ForeignPtr(
ForeignPtr(),
newPlainForeignPtr_,
newForeignPtr_,
mallocPlainForeignPtrAlignBytes,
mallocForeignPtrAlignBytes,
unsafeForeignPtrToPtr,
castForeignPtr,
touchForeignPtr
) where
import Jhc.Addr
import Jhc.IO
import Jhc.Prim.Rts
import Jhc.Basics
type FinalizerPt... | m-alvarez/jhc | lib/jhc/Jhc/ForeignPtr.hs | mit | 2,928 | 22 | 11 | 600 | 630 | 337 | 293 | -1 | -1 |
module Main where
import Control.Monad
import Control.Concurrent
import Control.Concurrent.STM
import Data.List
import System.Random
fromYear :: Integer
fromYear = 1900
toYear :: Integer
toYear = 1920
supportedYears :: [Integer]
supportedYears = [fromYear .. toYear]
randomYear :: IO Integer
randomYear =
do
g... | hnfmr/beginning_haskell | ex8.2/src/Main.hs | mit | 1,268 | 0 | 11 | 324 | 471 | 237 | 234 | 48 | 2 |
{-# LANGUAGE CPP #-}
{-# LANGUAGE OverloadedStrings #-}
module Text.Inflections.UnderscoreSpec (spec) where
import Test.Hspec
import Text.Inflections
#if !MIN_VERSION_base(4,8,0)
import Control.Applicative
#endif
spec :: Spec
spec = describe "underscore" $
it "converts a word list to snake case" $ d... | stackbuilders/inflections-hs | test/Text/Inflections/UnderscoreSpec.hs | mit | 451 | 0 | 10 | 88 | 101 | 55 | 46 | 12 | 1 |
module Example.Sorting where
import Control.Category hiding ((>>>),(<<<))
import Control.Applicative
import Prelude hiding ((.), id)
import Melchior.Control
import Melchior.Data.String
import Melchior.Dom
import Melchior.Dom.Events
import Melchior.Dom.Html
import Melchior.Dom.Selectors
import Melchior.EventSources.Mo... | kjgorman/melchior | example/assets/hs/sorting.hs | mit | 1,565 | 0 | 14 | 274 | 633 | 336 | 297 | 37 | 2 |
{-# htermination ($!) :: (a -> b) -> a -> b #-}
| ComputationWithBoundedResources/ara-inference | doc/tpdb_trs/Haskell/full_haskell/Prelude_DOLLARBANG_1.hs | mit | 48 | 0 | 2 | 12 | 3 | 2 | 1 | 1 | 0 |
module JobReport.Insert where
import Control.Monad
import Database.HDBC
import Database.HDBC.Sqlite3
import JobReport.Database
newtype InsertOptions = InsertOptions Working
deriving (Read, Show)
data Job = Job
{ jobName :: String
} deriving (Read, Show)
data Payment = Payment
{ paymentJob :: Job
... | haliner/jobreport | src/JobReport/Insert.hs | mit | 2,126 | 0 | 11 | 652 | 535 | 290 | 245 | 58 | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.