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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
-- Typeclass
class BasicEq a where
isEqual :: a -> a -> Bool
instance BasicEq Bool where
isEqual True True = True
isEqual False False = True
isEqual _ _ = False
| EricYT/Haskell | src/chapter-6-1.hs | apache-2.0 | 177 | 0 | 8 | 47 | 62 | 31 | 31 | 6 | 0 |
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
module Transaction where
import Control.Lens
import Control.Lens.TH
import Data.Function
import Data.Hashable
import Commutating
import TransactionState
newtype TransactionID = TransactionID Int deriving(Eq, Ord, Hashable)
data Transacti... | kdkeyser/halvin | src/halvin/Transaction.hs | apache-2.0 | 987 | 0 | 9 | 163 | 297 | 166 | 131 | 28 | 1 |
{-# LANGUAGE CPP #-}
{-# LANGUAGE BangPatterns #-}
module Score
( Score
, Input(..)
, Choice(..)
, score
, positive
#ifdef TEST
, minimum
#endif
) where
import Control.Applicative
import Control.Monad
import Data.Maybe (mapMaybe)
import Data.Text (Text)
import qual... | supki/wybor | src/Score.hs | bsd-2-clause | 1,706 | 0 | 17 | 434 | 635 | 334 | 301 | 42 | 3 |
{-# LANGUAGE DeriveDataTypeable #-}
module Data.Mathematica.Type where
import System.Console.CmdArgs
data Mathematica_data = Test
deriving (Show,Data,Typeable)
test :: Mathematica_data
test = Test
mode = modes [test]
| wavewave/mathematica-data | lib/Data/Mathematica/Type.hs | bsd-2-clause | 240 | 0 | 6 | 48 | 57 | 34 | 23 | 8 | 1 |
module Application.DiagramDrawer.Verbatim where
import Language.Haskell.TH.Quote
import Language.Haskell.TH.Lib
verbatim :: QuasiQuoter
verbatim = QuasiQuoter { quoteExp = litE . stringL
, quotePat = undefined
, quoteType = undefined
, quoteDec = ... | wavewave/diagdrawer | lib/Application/DiagramDrawer/Verbatim.hs | bsd-2-clause | 357 | 0 | 7 | 130 | 61 | 40 | 21 | 8 | 1 |
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE TypeFamilies #-}
-- |
-- Module: $HEADER$
-- Description: TODO
-- Copyright: (c) 2016, Peter Trško
-- License: BSD3
--
-- Maintainer: peter.trsko@gmail.com
-- Stability: experimental
-- Portability: MultiParamTyp... | trskop/data-analysis | src/DataAnalysis/Decode.hs | bsd-3-clause | 1,404 | 0 | 9 | 281 | 251 | 151 | 100 | 37 | 1 |
module Entity.Bound where
import qualified Data.List as L
import qualified Gamgine.Math.BoxTree as BT
import qualified Gamgine.Math.Box as B
import qualified GameData.Entity as E
import qualified GameData.Animation as A
import qualified Entity.Position as EP
bound :: E.Entity -> E.Bound
bound E.Player {E.playerPositi... | dan-t/layers | src/Entity/Bound.hs | bsd-3-clause | 699 | 0 | 9 | 105 | 253 | 149 | 104 | 16 | 1 |
module Connection where
import Prelude ()
import Prelude.MH
import Brick.BChan
import Control.Concurrent ( forkIO, threadDelay )
import qualified Control.Concurrent.STM as STM
import Control.Exception ( SomeException, catch )
import qualified Data.HashMap.Strict as HM... | aisamanra/matterhorn | src/Connection.hs | bsd-3-clause | 3,589 | 0 | 20 | 783 | 957 | 494 | 463 | -1 | -1 |
{-# OPTIONS_GHC -Wall -fno-warn-unused-do-bind #-}
module Parse.Type where
import Data.List (intercalate)
import Text.Parsec ((<|>), (<?>), char, many1, string, try)
import Parse.Helpers
import qualified Reporting.Annotation as A
import AST.V0_16
tvar :: IParser Type
tvar =
addLocation
(TypeVariable <$> lowVa... | fredcy/elm-format | parser/src/Parse/Type.hs | bsd-3-clause | 3,357 | 0 | 16 | 1,143 | 979 | 486 | 493 | 112 | 5 |
{- Copyright (c) 2008 David Roundy
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following... | droundy/franchise | Distribution/Franchise/SplitFile.hs | bsd-3-clause | 3,540 | 0 | 17 | 977 | 571 | 283 | 288 | 38 | 3 |
{-# LANGUAGE QuasiQuotes #-}
import LiquidHaskell
import Language.Haskell.Liquid.Prelude
--------------------------------------------------------------------
-------------- Defining A List Type --------------------------------
--------------------------------------------------------------------
[lq| data List [l... | spinda/liquidhaskell | tests/gsoc15/unknown/pos/ListISort-LType.hs | bsd-3-clause | 1,395 | 3 | 9 | 324 | 327 | 188 | 139 | 30 | 1 |
module Text.Roundtrip.Classes where
import Prelude hiding ((<*>), pure)
import Data.Eq (Eq)
import Data.Char (Char)
import Data.Text as T
import Data.XML.Types (Name(..), Content)
import Control.Isomorphism.Partial (IsoFunctor)
infixl 3 <|>
infixl 3 <||>
infixr 6 <*>
class ProductFunctor f where
(<*>) :: f alph... | skogsbaer/roundtrip | src/Text/Roundtrip/Classes.hs | bsd-3-clause | 1,566 | 0 | 11 | 361 | 512 | 271 | 241 | 36 | 0 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE QuasiQuotes #-}
{-# LANGUAGE RecordWildCards #-}
module Ticket.Site
( routes
) where
import Data.ByteString (ByteString)
import Data.ByteString.Char8 (unpack)
import Snap.Core
import Snap.Snaplet
... | ExternalReality/features | src/Ticket/Site.hs | bsd-3-clause | 3,927 | 0 | 16 | 1,326 | 916 | 475 | 441 | 84 | 2 |
module SyntaxHighlighting.AsLatexPt where
import Utils.Utils
import Data.Char
import TypeSystem
import SyntaxHighlighting.Coloring
import SyntaxHighlighting.Renderer
import Text.PrettyPrint.ANSI.Leijen
data LatexRenderer = LatexRenderer FullColoring SyntaxStyle
instance Renderer LatexRenderer where
create = Lat... | pietervdvn/ALGT | src/SyntaxHighlighting/AsLatexPt.hs | bsd-3-clause | 3,663 | 129 | 13 | 678 | 1,527 | 796 | 731 | 112 | 2 |
module Crete.Product.Product where
import Text.ParserCombinators.Parsec (parse)
import Data.Maybe (catMaybes)
import Data.Either (partitionEithers)
import qualified Data.List as List
import qualified Data.Map as Map
import qualified Crete.Product.ProductParser as PP
import Crete.Store.StoreTypes (ProductMap, Pr... | fphh/crete | src/Crete/Product/Product.hs | bsd-3-clause | 1,298 | 0 | 15 | 352 | 457 | 250 | 207 | 29 | 6 |
-- Copyright (c) 2016-present, Facebook, Inc.
-- All rights reserved.
--
-- This source code is licensed under the BSD-style license found in the
-- LICENSE file in the root directory of this source tree.
{-# LANGUAGE OverloadedStrings #-}
module Duckling.Time.TimeZone.Parse
( parseTimezone
) where
import Data.... | facebookincubator/duckling | Duckling/Time/TimeZone/Parse.hs | bsd-3-clause | 7,587 | 0 | 10 | 1,760 | 3,020 | 1,715 | 1,305 | 178 | 1 |
{-# LANGUAGE DeriveDataTypeable #-}
module Error
(
PullE(..),
CommandError(..),
putErr
)
where
import System.IO
import System.Exit (ExitCode(..))
import Data.Typeable
import Control.Exception
import Data.ConfigFile
data CommandError =
ProjectExist
| NoProject
| PatchingError
| DiffError ExitCode
|... | lambda-zorn/det | src/Error.hs | bsd-3-clause | 1,519 | 0 | 9 | 287 | 349 | 190 | 159 | 49 | 1 |
{-# LANGUAGE RecordWildCards #-}
module Material where
import Control.Monad (when)
import Foreign.Ptr
import Graphics.GL
import Graphics.GL.Ext.EXT.TextureFilterAnisotropic
import Prelude hiding (any, ceiling)
import Util
import qualified Codec.Picture as JP
import qualified Codec.Picture.Types as JP
import qualified ... | ocharles/hadoom | hadoom/Material.hs | bsd-3-clause | 3,629 | 0 | 23 | 1,463 | 723 | 355 | 368 | 90 | 6 |
-----------------------------------------------------------------------------
-- |
-- Module : Distribution.Simple.Program.Strip
--
-- Maintainer : cabal-devel@haskell.org
-- Portability : portable
--
-- This module provides an library interface to the @strip@ program.
module Distribution.Simple.Program.Strip... | sopvop/cabal | Cabal/Distribution/Simple/Program/Strip.hs | bsd-3-clause | 2,855 | 0 | 20 | 871 | 541 | 283 | 258 | 44 | 8 |
{-# LANGUAGE DeriveDataTypeable, DeriveFoldable, DeriveTraversable, DeriveFunctor #-}
module Language.Haskell.AST.Exts.HSX
where
import Data.Data
import Data.Foldable (Foldable)
import Data.Traversable (Traversable)
import Language.Haskell.AST.Core hiding ( Module, Pat, Exp )
-- | XML extenstions to the @GModule@ t... | jcpetruzza/haskell-ast | src/Language/Haskell/AST/Exts/HSX.hs | bsd-3-clause | 3,682 | 0 | 10 | 1,117 | 1,205 | 639 | 566 | 55 | 0 |
module Lava.Smv
( smv
)
where
import Lava.Signal
import Lava.Netlist
import Lava.Generic
import Lava.Sequent
import Lava.Property
import Lava.Error
import Lava.LavaDir
import Lava.Verification
import Data.List
( intersperse
, nub
)
import System.IO
( openFile
, IOMode(..)
, hPutStr
, hClose
)
i... | dfordivam/lava | Lava/Smv.hs | bsd-3-clause | 3,975 | 0 | 24 | 1,546 | 1,196 | 583 | 613 | 106 | 16 |
module Database.TokyoCabinet.Sequence where
import Foreign.Ptr
import Foreign.Storable (peek)
import Foreign.Marshal (alloca, mallocBytes, copyBytes)
import Foreign.ForeignPtr
import Database.TokyoCabinet.List.C
import Database.TokyoCabinet.Storable
class Sequence a where
withList :: (Storable s) => a s -> (Ptr... | tom-lpsd/tokyocabinet-haskell | Database/TokyoCabinet/Sequence.hs | bsd-3-clause | 2,356 | 0 | 17 | 897 | 754 | 368 | 386 | 53 | 0 |
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE MultiParamTypeClasses #-} --these two for Isomorphic class
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE FlexibleContexts #-} -- necessary for Shapely Generics instances
{-# LANGUAGE TypeOperators #-} -- for our cons synonym
{-# LANGUA... | jberryman/shapely-data | src/Data/Shapely/Classes.hs | bsd-3-clause | 3,973 | 0 | 13 | 853 | 532 | 319 | 213 | 32 | 0 |
{-# LANGUAGE OverloadedStrings #-}
module Database.MetaStorage.Spec (metaStorageSpec) where
import Test.Hspec
import Test.QuickCheck
import Filesystem.Path.CurrentOS
import Crypto.Hash
import Filesystem
import Database.MetaStorage
import Database.MetaStorage.Types
metaStorageSpec :: Spec
metaStorageSpec = do
desc... | alios/metastorage | Database/MetaStorage/Spec.hs | bsd-3-clause | 1,588 | 0 | 18 | 390 | 382 | 188 | 194 | 40 | 1 |
module Network.Tangaroa.Byzantine.Server
( runRaftServer
) where
import Data.Binary
import Control.Concurrent.Chan.Unagi
import Control.Lens
import qualified Data.Set as Set
import Network.Tangaroa.Byzantine.Handler
import Network.Tangaroa.Byzantine.Types
import Network.Tangaroa.Byzantine.Util
import Network.Tang... | chrisnc/tangaroa | src/Network/Tangaroa/Byzantine/Server.hs | bsd-3-clause | 808 | 0 | 14 | 134 | 268 | 145 | 123 | 23 | 1 |
{-# LANGUAGE ApplicativeDo #-}
{-# LANGUAGE EmptyCase #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE GADTs #-}
{-# LANGUAGE InstanceSigs #-}
{-# LANGUAGE KindSignatures #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANG... | mstksg/tensor-ops | src/TensorOps/Backend/BTensor.hs | bsd-3-clause | 30,700 | 0 | 36 | 11,375 | 13,033 | 6,750 | 6,283 | -1 | -1 |
-- | this module contains the defs of common data types and type classes
module Text.Regex.Deriv.Common
( Range(..), range, minRange, maxRange
, Letter
, PosEpsilon (..)
, IsEpsilon (..)
, IsPhi (..)
, Simplifiable (..)
, myHash
, myLookup
, GFlag (..)
, IsGreedy (..)
, nub2... | awalterschulze/xhaskell-regex-deriv | Text/Regex/Deriv/Common.hs | bsd-3-clause | 3,221 | 0 | 13 | 937 | 1,159 | 649 | 510 | 88 | 2 |
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
module State6502 where
import Data.Word
import Deque
import Data.Array
import Data.Time.Clock
import Control.Lens
import Control.Monad.State
import Data.Bits.Lens
import System.Console.Haskeline
import Data.Array.IO
import qualified Data.Int... | dpiponi/Bine | src/State6502.hs | bsd-3-clause | 1,646 | 0 | 10 | 436 | 447 | 254 | 193 | 83 | 1 |
{-# LANGUAGE DeriveDataTypeable #-}
{-# OPTIONS_GHC -fno-warn-missing-fields #-}
{-# OPTIONS_GHC -fno-warn-missing-signatures #-}
{-# OPTIONS_GHC -fno-warn-name-shadowing #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
------------------------------------------------------... | csabahruska/GFXDemo | Thrift/ContentProvider_Client.hs | bsd-3-clause | 1,913 | 0 | 14 | 392 | 416 | 231 | 185 | 45 | 3 |
{-# Language ScopedTypeVariables #-}
{-# Language DeriveGeneric #-}
{-# Language DeriveDataTypeable #-}
module StateManager where
import Control.Distributed.Process
import Control.Monad (filterM)
import Control.Monad.Trans.State.Strict
import Control.Monad.Trans.Class (lift)
import Data.Binary (Binary)
import Data.Ma... | sgeop/side-batch | src/StateManager.hs | bsd-3-clause | 1,333 | 0 | 18 | 274 | 391 | 207 | 184 | 40 | 2 |
{-# LANGUAGE ConstraintKinds #-}
{-# LANGUAGE ExistentialQuantification #-}
{-# LANGUAGE FunctionalDependencies #-}
{-# LANGUAGE GADTs #-}
{-# LANGUAGE PolyKinds #-}
{-# LANGUAGE RankNTypes #-}
{-# OPTIONS_GHC -fno-warn-orphans #-}
module Cardano.Wa... | input-output-hk/pos-haskell-prototype | wallet/src/Cardano/Wallet/API/Indices.hs | mit | 6,558 | 0 | 17 | 1,529 | 1,346 | 725 | 621 | -1 | -1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# L... | kim/amazonka | amazonka-support/gen/Network/AWS/Support/CreateCase.hs | mpl-2.0 | 9,316 | 0 | 10 | 1,952 | 1,066 | 649 | 417 | 109 | 1 |
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
-- ... | fmapfmapfmap/amazonka | amazonka-kms/gen/Network/AWS/KMS/GetKeyRotationStatus.hs | mpl-2.0 | 4,673 | 0 | 13 | 961 | 585 | 351 | 234 | 76 | 1 |
-- Copyright 2012-2013 Greg Horn
--
-- This file is part of rawesome.
--
-- rawesome is free software: you can redistribute it and/or modify
-- it under the terms of the GNU Lesser General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later v... | ghorn/rawesome | wtfviz/src/KiteSim.hs | lgpl-3.0 | 7,212 | 0 | 26 | 1,892 | 2,576 | 1,357 | 1,219 | 145 | 3 |
-----------------------------------------------------------------------------
-- |
-- Module : Control.Monad.Indexed.Fix
-- Copyright : (C) 2008 Edward Kmett
-- License : BSD-style (see the file LICENSE)
--
-- Maintainer : Edward Kmett <ekmett@gmail.com>
-- Stability : experimental
-- Portability : ... | urska19/MFP---Samodejno-racunanje-dvosmernih-preslikav | Control/Monad/Indexed/Fix.hs | apache-2.0 | 575 | 4 | 10 | 93 | 84 | 51 | 33 | 5 | 0 |
{-# LANGUAGE Haskell98 #-}
{-# LINE 1 "src/Data/Foldable/Compat.hs" #-}
{-# LANGUAGE CPP, NoImplicitPrelude #-}
module Data.Foldable.Compat (
module Base
, maximumBy
, minimumBy
) where
import Data.Foldable as Base hiding (maximumBy, minimumBy)
import Prelude (Orderin... | phischu/fragnix | tests/packages/scotty/Data.Foldable.Compat.hs | bsd-3-clause | 902 | 0 | 9 | 298 | 210 | 115 | 95 | 19 | 2 |
--
-- Copyright (c) 2013 Citrix Systems, Inc.
--
-- 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 the License, or
-- (at your option) any later version.
--
-- This progra... | jean-edouard/manager | xenmgr/Vm/State.hs | gpl-2.0 | 3,845 | 0 | 14 | 653 | 768 | 395 | 373 | 67 | 2 |
{-
(c) The GRASP/AQUA Project, Glasgow University, 1992-1998
\section[PrimOp]{Primitive operations (machine-level)}
-}
{-# LANGUAGE CPP #-}
module PrimOp (
PrimOp(..), PrimOpVecCat(..), allThePrimOps,
primOpType, primOpSig,
primOpTag, maxPrimOpTag, primOpOcc,
tagToEnumKey,
p... | siddhanathan/ghc | compiler/prelude/PrimOp.hs | bsd-3-clause | 23,245 | 0 | 11 | 6,302 | 1,556 | 858 | 698 | -1 | -1 |
module Test20 where
y c = c
f n y = n y
g = (f 1 1)
h = (+1) 1
| kmate/HaRe | old/testing/refacFunDef/Test20.hs | bsd-3-clause | 67 | 0 | 6 | 26 | 50 | 27 | 23 | 5 | 1 |
{-
(c) The University of Glasgow 2006
(c) The GRASP/AQUA Project, Glasgow University, 1992-1998
@Uniques@ are used to distinguish entities in the compiler (@Ids@,
@Classes@, etc.) from each other. Thus, @Uniques@ are the basic
comparison key in the compiler.
If there is any single operation that needs to be fast, i... | acowley/ghc | compiler/basicTypes/Unique.hs | bsd-3-clause | 11,873 | 0 | 12 | 3,227 | 1,840 | 994 | 846 | 150 | 3 |
{-# LANGUAGE OverloadedLabels, DataKinds, FlexibleContexts #-}
import GHC.OverloadedLabels
-- No instance for (OverloadedLabel "x" t0)
a = #x
-- No instance for (OverloadedLabel "x" (t0 -> t1), OverloadedLabel "y" t0)
b = #x #y
-- Could not deduce (OverloadedLabel "y" t) from (OverloadedLabel "x" t)
c :: IsLabel "x... | olsner/ghc | testsuite/tests/overloadedrecflds/should_fail/overloadedlabelsfail01.hs | bsd-3-clause | 354 | 0 | 6 | 64 | 52 | 29 | 23 | 7 | 1 |
{-# OPTIONS_HADDOCK hide #-}
module Ticket61_Hidden where
class C a where
-- | A comment about f
f :: a
| DavidAlphaFox/ghc | utils/haddock/html-test/src/Ticket61_Hidden.hs | bsd-3-clause | 110 | 0 | 6 | 26 | 20 | 12 | 8 | 4 | 0 |
{-# LANGUAGE DuplicateRecordFields #-}
module OverloadedRecFldsRun02_A (U(..), V(MkV, x), Unused(..), u) where
data U = MkU { x :: Bool, y :: Bool }
data V = MkV { x :: Int }
data Unused = MkUnused { unused :: Bool }
u = MkU False True
| shlevy/ghc | testsuite/tests/overloadedrecflds/should_run/OverloadedRecFldsRun02_A.hs | bsd-3-clause | 239 | 0 | 8 | 50 | 94 | 60 | 34 | 9 | 1 |
{-# htermination min :: Char -> Char -> Char #-}
| ComputationWithBoundedResources/ara-inference | doc/tpdb_trs/Haskell/full_haskell/Prelude_min_3.hs | mit | 49 | 0 | 2 | 10 | 3 | 2 | 1 | 1 | 0 |
{-# LANGUAGE TupleSections #-}
-- | Parser for .prof files generated by GHC.
module ProfFile
( Time(..)
, Line(..)
, lIndividualTime
, lInheritedTime
, lIndividualAlloc
, lInheritedAlloc
, parse
, processLines
, findStart
) where
import Control.Arrow (second, left)
import Data.C... | fpco/ghc-prof-flamegraph | ProfFile.hs | mit | 6,019 | 0 | 21 | 1,535 | 1,618 | 885 | 733 | 106 | 7 |
module Monoid8 where
import Data.Monoid
import Test.QuickCheck
import SemiGroupAssociativeLaw
import Test.HUnit
import MonoidLaws
import Text.Show.Functions
import ArbitrarySum
newtype Mem s a = Mem { runMem :: s -> (a,s) } deriving Show
mappendMem :: Monoid a => Mem s a -> Mem s a -> Mem s a
mappendMem f1 f2 =
... | NickAger/LearningHaskell | HaskellProgrammingFromFirstPrinciples/Chapter15.hsproj/Monoid8.hs | mit | 2,666 | 0 | 13 | 593 | 971 | 513 | 458 | 42 | 1 |
-- Copyright (c) 2016-present, SoundCloud Ltd.
-- All rights reserved.
--
-- This source code is distributed under the terms of a MIT license,
-- found in the LICENSE file.
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE TemplateHaskell #-}
module Kubern... | soundcloud/haskell-kubernetes | lib/Kubernetes/Model/V1/Binding.hs | mit | 2,009 | 0 | 14 | 731 | 345 | 206 | 139 | 43 | 1 |
--------------------------------------------------------------------
-- |
-- Copyright : © Oleg Grenrus 2014
-- License : MIT
-- Maintainer: Oleg Grenrus <oleg.grenrus@iki.fi>
-- Stability : experimental
-- Portability: non-portable
--
-- This module re-exports tree-based implementation.
-------------------------... | phadej/boolean-normal-forms | src/Data/Algebra/Boolean/NNF.hs | mit | 484 | 0 | 5 | 52 | 37 | 30 | 7 | 3 | 0 |
{-# language NoImplicitPrelude, DoAndIfThenElse, OverloadedStrings, ExtendedDefaultRules #-}
module IHaskell.Publish (publishResult) where
import IHaskellPrelude
import qualified Data.Text as T
import qualified Data.Text.Encoding as E
import IHaskell.Display
import IHaskell.Types
import... | sumitsahrawat/IHaskell | src/IHaskell/Publish.hs | mit | 3,310 | 0 | 15 | 916 | 586 | 299 | 287 | 52 | 6 |
module Interpreter where
-- union = union (|||), delete = remove (---)
import Parsing
import Data.List
-- Free variables of a term (variables that are not bound by a lambda)
freeVariables :: Term -> [Var]
freeVariables (Constant _) = []
freeVariables (Variable v) = [v]
freeVariables (Application (a, b)) = (freeVari... | JorisM/HLambdaCalculus | Interpreter.hs | mit | 2,187 | 6 | 15 | 402 | 832 | 433 | 399 | 39 | 2 |
-- ch4.hs
module Ch4 where
isPalindrome :: (Eq a) => [a] -> Bool
isPalindrome xs = (reverse xs) == xs
myAbs :: Integer -> Integer
myAbs x = if x >= 0 then x else (-x)
f :: (a, b) -> (c, d) -> ((b, d), (a, c))
f x y = ((snd x, snd y), (fst x, fst y)) | candu/haskellbook | ch4/ch4.hs | mit | 252 | 0 | 8 | 62 | 161 | 92 | 69 | 7 | 2 |
module Language.Asol.Expression where
data Instruction = Push Integer
| Top Int
| Pop
| Print
| Read
| Emit
| Mul
| Sub
| Add
| Div
| Mod
... | kmein/asol | Language/Asol/Expression.hs | mit | 468 | 0 | 6 | 314 | 74 | 47 | 27 | 18 | 0 |
-- Core stuff: Tic Tac Toe struct, win conditions
module Core where
data Place = X | O | E
deriving (Show, Eq)
-- X, O or Empty
data Player = PX | PO | N
deriving (Show, Eq)
-- N is to be used only for a full board where no one has won
getPlace :: Player -> Place
getPlace player = case player of
PX -> X
... | quantum-dan/tictactoe-ai | Core.hs | mit | 3,579 | 0 | 12 | 1,013 | 1,542 | 806 | 736 | 86 | 7 |
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE ViewPatterns #-}
module Commands.TH.Data where
import Commands.Grammar
import Data.List.NonEmpty (toList)
import Data.Functor
import Language.Haskell.TH
import Language.Haskell.TH.Syntax
-- |
-- given the input 'Production':
--
-- > Production ''Command [
-- > Varian... | sboosali/Haskell-DragonNaturallySpeaking | sources/Commands/TH/Data.hs | mit | 1,628 | 0 | 11 | 331 | 272 | 163 | 109 | 21 | 2 |
{-------------------------------------------------------------------------------
Consider the consecutive primes p₁ = 19 and p₂ = 23. It can be verified that 1219 is the smallest number such that the last digits are formed by p₁ whilst also being divisible by p₂.
In fact, with the exception of p₁ = 3 and p₂ = 5, for ... | dpieroux/euler | 0134.hs | mit | 1,797 | 0 | 17 | 443 | 427 | 228 | 199 | 23 | 2 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE ConstraintKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
module WS.App where
import Control.Applicative ((<$>), (<*>))
import Control.Exception (Exception)
import Control.Monad.Catch (MonadThrow, MonadCatch, throwM... | krdlab/haskell-webapp-testing-experimentation | src/WS/App.hs | mit | 4,212 | 0 | 15 | 1,058 | 1,380 | 712 | 668 | 109 | 2 |
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE FlexibleInstances #-}
class TooMany a where
tooMany :: a -> Bool
instance TooMany Int where
tooMany n = n > 42
{-
newtype Goats = Goats Int deriving Show
-}
-- with GeneralizedNewtypeDeriving, we can get this automatically:
newtype Goats = Goats Int ... | JustinUnger/haskell-book | ch11/learn.hs | mit | 1,105 | 0 | 9 | 241 | 231 | 131 | 100 | 16 | 0 |
{-# LANGUAGE BangPatterns, CPP, FlexibleContexts #-}
-- |
-- Module : Statistics.Correlation.Kendall
--
-- Fast O(NlogN) implementation of
-- <http://en.wikipedia.org/wiki/Kendall_tau_rank_correlation_coefficient Kendall's tau>.
--
-- This module implementes Kendall's tau form b which allows ties in the data.
-- T... | kaizhang/statistics-correlation | Statistics/Correlation/Kendall.hs | mit | 5,569 | 0 | 18 | 1,731 | 1,746 | 881 | 865 | 107 | 2 |
module Hoton.Types
(
Number
) where
type Number = Double
| woufrous/hoton | src/Hoton/Types.hs | mit | 63 | 0 | 4 | 16 | 17 | 11 | 6 | 4 | 0 |
-- |
-- Module: Math.NumberTheory.Zeta.Hurwitz
-- Copyright: (c) 2018 Alexandre Rodrigues Baldé
-- Licence: MIT
-- Maintainer: Alexandre Rodrigues Baldé <alexandrer_b@outlook.com>
--
-- Hurwitz zeta function.
{-# LANGUAGE ScopedTypeVariables #-}
module Math.NumberTheory.Zeta.Hurwitz
( zetaHurwitz
) wh... | Bodigrim/arithmoi | Math/NumberTheory/Zeta/Hurwitz.hs | mit | 4,891 | 0 | 16 | 1,596 | 731 | 424 | 307 | 50 | 1 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE PartialTypeSignatures #-}
module Web.Views.Index where
import Model.CoreTypes
import Web.Utils
import Web.Routes as R
import Web.Views.DiamondButton
import Text.Blaze.Html5 ((!))
import qualified Text.Blaze.Html5 as H
import qualified Text.Bl... | tomleb/portfolio | src/Web/Views/Index.hs | mit | 1,036 | 0 | 13 | 284 | 243 | 130 | 113 | 25 | 1 |
module Main where
import qualified Data.ByteString.Lazy.Char8 as BS
import Data.Maybe (fromJust)
import Data.Aeson (decode)
import LevelParser
import ParitySolver
main :: IO ()
main = do
fc <- BS.readFile "story.json"
let levels = map f... | jcla1/parity-solver | Main.hs | mit | 498 | 0 | 12 | 160 | 129 | 67 | 62 | 12 | 1 |
isPrime::Integer->Bool
isPrime n = null [x | x <- [2..(floor(sqrt(fromInteger n)))], mod n x == 0]
factors::Integer->[Integer]
factors n = [x | x <- [1..n], mod n x == 0]
main::IO()
main = print $ last $ takeWhile isPrime $ factors 600851475143
| neutronest/eulerproject-douby | e3/e3.hs | mit | 247 | 0 | 15 | 44 | 150 | 76 | 74 | 6 | 1 |
{-# language TemplateHaskell #-}
{-# language DeriveDataTypeable #-}
module DPLLT.Trace where
import DPLLT.Data
import qualified Fourier_Motzkin as FM
import Autolib.Reader
import Autolib.ToDoc
import Autolib.Reporter
import Autolib.Size
import qualified Autolib.Relation as R
import qualified Data.Map.Strict as M
... | marcellussiegburg/autotool | collection/src/DPLLT/Trace.hs | gpl-2.0 | 10,756 | 0 | 25 | 3,886 | 3,334 | 1,668 | 1,666 | 239 | 14 |
{-# LANGUAGE DeriveDataTypeable #-}
module ArrayBonn.Program where
import Autolib.Reader
import Autolib.ToDoc
import Autolib.TES.Identifier
import Autolib.Size
import Data.Typeable
data Program st = Program [ st ]
deriving ( Typeable )
plength ( Program sts ) = length sts
instance ToDoc st => ToDoc ( Program ... | Erdwolf/autotool-bonn | src/ArrayBonn/Program.hs | gpl-2.0 | 583 | 1 | 11 | 133 | 206 | 104 | 102 | 18 | 1 |
module Inference.Builtin (builtinTypes) where
import Types
import Inference.Types
builtinTypes :: [(String, Inference Type)]
builtinTypes = [ ("dup", dup_)
, ("i", i_)
, ("drop", drop_)
, ("swap", swap_)
, ("quote", quote_)
]
dup_ :: Inferenc... | breestanwyck/stack-unification | src/Inference/Builtin.hs | gpl-2.0 | 824 | 0 | 13 | 299 | 339 | 184 | 155 | 28 | 1 |
-- Copyright (C) 2006-2008 Angelos Charalambidis <a.charalambidis@di.uoa.gr>
--
-- 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, or (at your option)
-- any later version... | acharal/hopes | src/basic/Pretty.hs | gpl-2.0 | 3,353 | 0 | 12 | 946 | 1,105 | 576 | 529 | 63 | 2 |
{-# LANGUAGE DeriveGeneric #-}
module Language.Mulang.Transform.Normalizer (
normalize,
unnormalized,
NormalizationOptions (..),
SequenceSortMode (..)) where
import GHC.Generics
import Data.List (sort, nub)
import Data.List.Extra (unwind)
import Language.Mulang.Ast
import Language.Mulang.A... | mumuki/mulang | src/Language/Mulang/Transform/Normalizer.hs | gpl-3.0 | 7,931 | 0 | 10 | 1,803 | 2,366 | 1,208 | 1,158 | 128 | 4 |
module HEP.Automation.MadGraph.Dataset.Processes where
data Process = TTBar | TTBar0or1J | SingleTZpSemiLep | TTBarSemiZp | TZpLep | TTBarSemiZpNotFull | TTBarSemiLep | SingleTZpJDecay | UUDijet | EEDijet | WBZprimeDecay | WGDijet
deriving (Show, Eq)
preDefProcess :: Process -> [Char]
preDefProcess TTBa... | wavewave/madgraph-auto-dataset | src/HEP/Automation/MadGraph/Dataset/Processes.hs | gpl-3.0 | 2,336 | 0 | 6 | 624 | 168 | 94 | 74 | 16 | 1 |
fromY id :: b -> a | hmemcpy/milewski-ctfp-pdf | src/content/2.6/code/haskell/snippet02.hs | gpl-3.0 | 18 | 3 | 4 | 5 | 13 | 6 | 7 | -1 | -1 |
module Numbering
( dividable
, is_prime
) where
dividable :: Int -> Int -> Bool
dividable x y = (x `mod` y) == 0
is_prime :: Int -> Bool
is_prime 1 = False
is_prime x = length dividers == 0
where dividers = (filter (dividable x) [2..floor (sqrt (fromIntegral x))])
| susu/haskell-problems | ProjectEuler/Numbering.hs | gpl-3.0 | 272 | 0 | 14 | 57 | 121 | 65 | 56 | 9 | 1 |
{-# LANGUAGE CPP #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE StandaloneDeriving #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE... | tamarin-prover/tamarin-prover | lib/term/src/Term/LTerm.hs | gpl-3.0 | 29,024 | 0 | 17 | 7,449 | 7,597 | 4,019 | 3,578 | 464 | 6 |
{-
Copyright (C) 2008 John Goerzen <jgoerzen@complete.org>
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 3 of the License, or
(at your option) any later version.
... | jgoerzen/tarfilter | tarf.hs | gpl-3.0 | 2,459 | 0 | 12 | 612 | 475 | 240 | 235 | 40 | 3 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-games/gen/Network/Google/Resource/Games/Leaderboards/List.hs | mpl-2.0 | 5,420 | 0 | 19 | 1,333 | 887 | 512 | 375 | 123 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-plus/gen/Network/Google/Resource/Plus/People/ListByActivity.hs | mpl-2.0 | 4,632 | 0 | 16 | 1,032 | 560 | 332 | 228 | 90 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-compute/gen/Network/Google/Resource/Compute/Disks/SetLabels.hs | mpl-2.0 | 5,068 | 0 | 19 | 1,216 | 638 | 380 | 258 | 96 | 1 |
module MapJoin where
import Data.Maybe
import Data.Map (Map)
import qualified Data.Map as Map
naturalJoin, (⋈) :: Ord k => Map k a -> Map k b -> Map k (a,b)
leftSemiJoin, (⋉) :: Ord k => Map k a -> Map k b -> Map k a
rightSemiJoin, (⋊) :: Ord k => Map k a -> Map k b -> Map k b
leftOuterJoin, (⟕) :: Ord k => Ma... | DanielG/kvm-in-a-box | src/MapJoin.hs | agpl-3.0 | 1,184 | 0 | 13 | 263 | 581 | 320 | 261 | 25 | 1 |
module MAC (MAC, enumerateMACs, showMAC, readMAC, nullMAC, toModifiedEUI64) where
import GHC.Generics
import Control.DeepSeq
import Control.Arrow
import Numeric
import Data.Bits
import Data.Word
import Data.List
import Data.List.Split
import Data.Function
import Safe
import BitUtils
import Read
newtype MAC = MAC [Wo... | DanielG/kvm-in-a-box | src/MAC.hs | agpl-3.0 | 1,306 | 0 | 14 | 308 | 555 | 302 | 253 | -1 | -1 |
module Haskell.Codewars.LuckyNumbers where
filterLucky :: [Int] -> [Int]
filterLucky = filter (\x -> elem '7' $ show x)
| ice1000/OI-codes | codewars/1-100/find-the-lucky-numbers.hs | agpl-3.0 | 121 | 0 | 9 | 19 | 48 | 27 | 21 | 3 | 1 |
import System.Plugins.Eval
main = do r <- eval "map toUpper \"haskell\"" ["Data.Char"]
either putStrLn putStrLn r
| Changaco/haskell-plugins | testsuite/eval/eval2/Main.hs | lgpl-2.1 | 125 | 0 | 9 | 27 | 37 | 18 | 19 | 3 | 1 |
diffHam :: (Integral a) => a -> a -> a
diffHam a b
| a == 0 && b == 0 = 0
| otherwise = let rr = if (mod a 2) /= (mod b 2)
then 1
else 0
in rr + diffHam (div a 2) (div b 2)
totalHammingDistance :: (Integral a) => [a] -> a
totalHammingDistance [] = 0
t... | ccqpein/Arithmetic-Exercises | Total-Hamming-Distance/THD.hs | apache-2.0 | 402 | 0 | 13 | 144 | 195 | 98 | 97 | 10 | 2 |
import Text.CSV
import Data.List as L
import Text.Nagato.NagatoIO as NagatoIO
import Text.Nagato.Models as Models
import Text.Nagato.MeCabTools as MeCabTools
import qualified Text.Nagato.Classify as NC
import qualified Text.Nagato.Train as Train
import qualified Text.Nagato.Train_complement as Train_compl
main = do
... | haru2036/nagato | samples/tester.hs | apache-2.0 | 3,593 | 0 | 18 | 568 | 1,201 | 599 | 602 | 76 | 2 |
import Data.Set (Set)
import qualified Data.Set as Set
-- See TorusLatticeWalk.hs, this is mostly copied and pasted from there with
-- some changes to nextStatesRight and nextStatesUp
-- Notes: I can prove that the number of all cylinder walks is w^h where w is
-- the width, and h is the right. (At each height, take 0... | peterokagey/haskellOEIS | src/Sandbox/CylinderLatticeWalk.hs | apache-2.0 | 3,524 | 0 | 13 | 708 | 782 | 431 | 351 | 41 | 3 |
module Arbitrary.File where
import Test.QuickCheck
--import qualified Data.Test as T
import Filesystem.Path.CurrentOS
import Prelude hiding (FilePath, writeFile)
import qualified Data.Set as S
import Control.Applicative
import Data.ModulePath
import Control.Lens
import Arbitrary.TestModule (toGenerated, testModulePath... | jfeltz/tasty-integrate | tests/Arbitrary/File.hs | bsd-2-clause | 2,787 | 0 | 18 | 622 | 977 | 512 | 465 | 69 | 2 |
module Ovid.Prelude
( JsCFAState (..)
, CFAOpts (..)
, emptyCFAOpts
, message
, warnAt
, enableUnlimitedRecursion, enablePreciseArithmetic, enablePreciseConditionals
-- source positions
, SourcePos, sourceName
-- Monads
, module Control.Monad
, module Control.Monad.Trans
, module Control.Monad.... | brownplt/ovid | src/Ovid/Prelude.hs | bsd-2-clause | 4,321 | 0 | 13 | 686 | 842 | 506 | 336 | 72 | 2 |
{-# OPTIONS -fglasgow-exts #-}
-----------------------------------------------------------------------------
{-| Module : QTreeWidget_h.hs
Copyright : (c) David Harley 2010
Project : qtHaskell
Version : 1.1.4
Modified : 2010-09-02 17:02:27
Warning : this file is machine generated - do... | keera-studios/hsQt | Qtc/Gui/QTreeWidget_h.hs | bsd-2-clause | 132,988 | 0 | 18 | 29,090 | 44,415 | 21,297 | 23,118 | -1 | -1 |
{-# LANGUAGE OverloadedStrings #-}
module Main where
import Control.Lens
import Data.Bool (bool)
import Data.Maybe (fromMaybe)
import Data.Text (Text)
import Network.URI (URI)
import Hackerspace.Space
import qualified Network.Browser as Browser
import qualified Network.HTTP as HTTP
import qualified Network.URI ... | HackerspaceBielefeld/hackerspaceapi-haskell | src/Main.hs | bsd-2-clause | 1,121 | 0 | 15 | 221 | 361 | 202 | 159 | 34 | 1 |
{- OPTIONS_GHC -fplugin Brisk.Plugin #-}
{- OPTIONS_GHC -fplugin-opt Brisk.Plugin:main #-}
{-# LANGUAGE TemplateHaskell #-}
module SpawnSym where
import Control.Monad (forM, foldM)
import Control.Distributed.Process
import Control.Distributed.BriskStatic
import Control.Distributed.Process.Closure
import Control.Distri... | abakst/brisk-prelude | tests/pos/SpawnSymForM.hs | bsd-3-clause | 1,036 | 0 | 12 | 266 | 337 | 169 | 168 | 29 | 2 |
{-# language CPP #-}
-- | = Name
--
-- VK_EXT_physical_device_drm - device extension
--
-- == VK_EXT_physical_device_drm
--
-- [__Name String__]
-- @VK_EXT_physical_device_drm@
--
-- [__Extension Type__]
-- Device extension
--
-- [__Registered Extension Number__]
-- 354
--
-- [__Revision__]
-- 1
--
-- [... | expipiplus1/vulkan | src/Vulkan/Extensions/VK_EXT_physical_device_drm.hs | bsd-3-clause | 9,168 | 0 | 14 | 1,634 | 1,499 | 897 | 602 | -1 | -1 |
module Sexy.Instances.Show.Double () where
import Sexy.Classes (Show(..))
import Sexy.Data (Double)
import qualified Prelude as P
instance Show Double where
show = P.show
| DanBurton/sexy | src/Sexy/Instances/Show/Double.hs | bsd-3-clause | 176 | 0 | 6 | 27 | 56 | 36 | 20 | 6 | 0 |
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE UndecidableInstances #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE TypeInType #-}
{-# LANGUAGE TypeFamilyDependencies #-}
{-# LANGUAGE TypeApplications #-}
{-# LANGUAGE ExplicitForAll #-}
{-# LANGUAGE Inst... | sleexyz/haskell-fun | Singletons.hs | bsd-3-clause | 2,511 | 65 | 9 | 512 | 938 | 510 | 428 | 63 | 1 |
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE ScopedTypeVariables #-}
--
-- A Mandelbrot set generator.
-- Originally submitted by Simon Marlow as part of Issue #49.
--
module Mandel (
-- Types
View, Render, Bitmap,
-- Pretty pictures
mandelbrot, prettyRGBA,
) where
import Prelude ... | vollmerm/shallow-fission | tests/mandelbrot/src-acc/Mandel.hs | bsd-3-clause | 5,237 | 0 | 19 | 1,931 | 895 | 490 | 405 | 50 | 1 |
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE QuasiQuotes #-}
{-# LANGUAGE ForeignFunctionInterface #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE ViewPatterns #-}
module Physics.Bullet.PointToPointConstrain... | lukexi/bullet-mini | src/Physics/Bullet/PointToPointConstraint.hs | bsd-3-clause | 2,693 | 0 | 11 | 605 | 308 | 169 | 139 | 31 | 1 |
module CC.Language where
import Data.List (transpose)
import Data.Map (Map)
import qualified Data.Map as Map
import Data.Set (Set)
import qualified Data.Set as Set
--
-- * Syntax
--
-- | Minimal, generic, binary choice calculus syntax.
data CC t e =
Obj (e (CC t e))
| Chc t (CC t e) (CC t e)
class Obj e w... | walkie/CC-Minimal | src/CC/Language.hs | bsd-3-clause | 2,559 | 0 | 12 | 616 | 1,003 | 528 | 475 | 46 | 3 |
module Language.Interpreter.StdLib.BlockHandling
( addBlockHandlingStdLib
)
where
import Language.Ast ( Value(Null) )
import Language.Interpreter.Types ( InterpreterProcess
, setBuiltIn
... | rumblesan/proviz | src/Language/Interpreter/StdLib/BlockHandling.hs | bsd-3-clause | 923 | 0 | 7 | 393 | 154 | 83 | 71 | 16 | 1 |
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE OverloadedStrings #-}
module Prosper.Commands
( invest
, account
, allListings
, notes
, listingFromNote
, listingCSV
, AccountException (..)
, UnauthorizedException (..)
) where
import Control.Exception (Exception, ... | WraithM/prosper | src/Prosper/Commands.hs | bsd-3-clause | 2,860 | 0 | 12 | 728 | 628 | 336 | 292 | 59 | 1 |
module Lint where
import Control.Monad.Writer
import Data.List (intercalate)
import Statement
import Expression (Name, Expr(..))
-- Quick 'n dirty! Unused variables are any variable that's in an assignment
-- statement, but not in any expression. As a proof-of-concept, we do directly
-- this, and first make a pass ove... | shawa/delorean | src/Lint.hs | bsd-3-clause | 1,872 | 0 | 10 | 420 | 639 | 323 | 316 | 34 | 3 |
{-# LANGUAGE CPP #-}
module MacAddress where
import Data.Binary (decode)
import qualified Data.ByteString.Lazy as BSL
import Safe (headDef)
#ifdef ETA_VERSION
import Java
import Data.Maybe (catMaybes)
import Data.Traversable (for)
import Data.Word (Word64... | cblp/crdt | crdt/lib/MacAddress.hs | bsd-3-clause | 1,697 | 8 | 14 | 396 | 284 | 154 | 130 | 18 | 1 |
import System.Environment (getArgs)
import Data.List (sort)
bat :: Int -> Int -> Int -> Int -> Int -> Int -> Int -> [Int] -> Int
bat l d n c s t tx xs | s > l - 6 = c
| s > tx - d && t == n = bat l d n c (tx+d) t (l-6+d) xs
| s > tx - d ... | nikai3d/ce-challenges | moderate/bats.hs | bsd-3-clause | 680 | 0 | 13 | 280 | 396 | 199 | 197 | 14 | 1 |
{-
- Hacq (c) 2013 NEC Laboratories America, Inc. All rights reserved.
-
- This file is part of Hacq.
- Hacq is distributed under the 3-clause BSD license.
- See the LICENSE file for more details.
-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE MultiParamTypeClasses #-}
module Data.MexSet (MexSet, ... | ti1024/hacq | src/Data/MexSet.hs | bsd-3-clause | 3,215 | 0 | 11 | 768 | 1,235 | 644 | 591 | 81 | 2 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.