code stringlengths 5 1.03M | repo_name stringlengths 5 90 | path stringlengths 4 158 | license stringclasses 15
values | size int64 5 1.03M | n_ast_errors int64 0 53.9k | ast_max_depth int64 2 4.17k | n_whitespaces int64 0 365k | n_ast_nodes int64 3 317k | n_ast_terminals int64 1 171k | n_ast_nonterminals int64 1 146k | loc int64 -1 37.3k | cycloplexity int64 -1 1.31k |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
module Init.Pages (init) where
import Elm.Utils ((|>))
import Prelude hiding (init)
import System.Directory (getDirectoryContents)
import System.FilePath ((</>), (<.>), dropExtension, hasExtension, joinPath, takeExtension)
import qualified Init.FileTree as FT
import Init.Helpers (makeWithStyle, write)
init :: IO [(... | inchingforward/elm-lang.org | src/backend/Init/Pages.hs | bsd-3-clause | 1,588 | 0 | 16 | 392 | 559 | 288 | 271 | 38 | 1 |
import Data.Int
import Data.Word
main = do
print [5 `div` (minBound+k::Int) | k <- [0 .. 10]]
print [5 `div` (minBound+k::Int8) | k <- [0 .. 10]]
print [5 `div` (minBound+k::Int16) | k <- [0 .. 10]]
print [5 `div` (minBound+k::Int32) | k <- [0 .. 10]]
print [5 `div` (minBound+k::Int64) | k <- [0 .. 1... | ghc-android/ghc | testsuite/tests/numeric/should_run/T7233.hs | bsd-3-clause | 609 | 0 | 11 | 144 | 406 | 229 | 177 | 13 | 1 |
{-# LANGUAGE OverloadedStrings #-}
{-|
This module provides the API that is exposed to users; it is based
around the 'Entry' type.
Users directly interacting with blobs presents two problems:
Information leakage: if Alice wants to determine if someone already
has a copy of some data, she attempts to read its SHA-25... | kisom/nebulahs | src/Nebula/Entry.hs | mit | 9,182 | 0 | 14 | 2,338 | 1,261 | 663 | 598 | 115 | 3 |
module Y2017.M07.D03.Exercise where
{--
It's a question of Ord.
From the Mensa Genius Quiz-a-Day Book by Dr. Abbie F. Salny, July 1 problem:
Tom is younger than Rose, but older than Will and Jack, in that order. Rose is
younger than Susie, but older than Jack. Jack is younger than Jim. Susie is
older than Rose, but ... | geophf/1HaskellADay | exercises/HAD/Y2017/M07/D03/Exercise.hs | mit | 675 | 0 | 6 | 133 | 92 | 55 | 37 | 7 | 1 |
import qualified Data.Array.Unboxed as A
import Data.Char
solve :: Int
solve = product $ map ((digits A.!)) [1, 10, 100, 1000, 10000, 100000, 1000000]
where
digits :: A.UArray Int Int
digits = A.listArray (1,1000000) $ map ((subtract 48) . ord) $ concatMap (show) [1::Int ..]
main :: IO ()
main = p... | jwtouron/haskell-play | ProjectEuler/Problem40.hs | mit | 331 | 0 | 13 | 75 | 151 | 86 | 65 | 8 | 1 |
-- Switch to conduit instead?
module Util.ReadLines where
import qualified Data.ByteString as BS
import System.IO
--import System.IO.Error
readLines :: FilePath -> IO [BS.ByteString]
readLines f = withFile f ReadMode hReadLines
hReadLines :: Handle -> IO [BS.ByteString]
hReadLines h =
liftM2 (:) (BS.hGetLine h)... | dancor/melang | src/Util/ReadLines.hs | mit | 406 | 0 | 10 | 73 | 134 | 74 | 60 | 10 | 2 |
{-# OPTIONS -fvia-C #-}
{-# OPTIONS -fno-warn-name-shadowing #-}
-- 6.4 gives a name shadow warning I haven't tracked down.
--
-- | This marvellous module contributed by Thomas J\344ger
--
module Language.Haskell.Pointfree.Rules (RewriteRule(..), rules, fire) where
import Language.Haskell.Pointfree.Common
import Dat... | substack/hs-disappoint | src/Language/Haskell/Pointfree/Rules.hs | mit | 24,721 | 0 | 22 | 7,499 | 11,116 | 6,607 | 4,509 | -1 | -1 |
-- |
-- Module : Southpaw.Utilities.Utilities
-- Description : General functional bits and bobs
-- Copyright : (c) Jonatan H Sundqvist, 2015
-- License : MIT
-- Maintainer : Jonatan H Sundqvist
-- Stability : experimental|stable
-- Portability : POSIX (not sure)
--
-- Created March 08 2015
-- TODO | -
-... | SwiftsNamesake/Southpaw | lib/Southpaw/Utilities/Utilities.hs | mit | 6,398 | 0 | 12 | 1,196 | 1,294 | 706 | 588 | 67 | 14 |
{-# LANGUAGE JavaScriptFFI, CPP, OverloadedStrings, ScopedTypeVariables #-}
module Main where
import Control.Monad
import Control.Concurrent
import GHCJS.Foreign
import GHCJS.Foreign.Callback
import GHCJS.Marshal
import GHCJS.Types
import GHCJS.Prim hiding (getProp)
import Data.JSString
import JavaScript.Cast
import ... | abarbu/haskell-mobile | hello/app/App.hs | mit | 5,181 | 38 | 15 | 1,184 | 968 | 476 | 492 | 74 | 2 |
{-# LANGUAGE TemplateHaskell #-}
module Data.Vectors(
Axis(..),
Vector2(..),
Vector3(..),
Vector(..),
fromTuple,
fromTriple,
toInt2,
fromInt2,
toInt3,
fromInt3
) where
import Data.List
import Control.Lens
data Axis = X | Y | Z deriving (Show, Eq)
data Vector2 a = Vector2 a a deriving (Show, Eq, Or... | 5outh/textlunky | src/Data/Vectors.hs | mit | 2,776 | 6 | 12 | 825 | 1,222 | 641 | 581 | 72 | 4 |
module Control.Disruptor.FixedSequenceGroup where
import Control.Disruptor.Sequence
import qualified Data.Foldable as F
import qualified Data.Vector as V
newtype FixedSequenceGroup = FixedSequenceGroup { fromFixedSequenceGroup :: V.Vector Sequence }
fixedSequenceGroup :: F.Foldable f => f Sequence -> FixedS... | iand675/disruptor | src/Control/Disruptor/FixedSequenceGroup.hs | mit | 498 | 0 | 8 | 66 | 102 | 60 | 42 | 9 | 1 |
moduele Main where
import Text.ParserCombinators.Parsec hiding (spaces)
import System.Environment
import Control.Monad
import Control.Monad.Error
import System.IO
import Data.IORef
| pie-lang/pie | proto/parser.hs | mit | 182 | 0 | 5 | 18 | 47 | 27 | 20 | -1 | -1 |
{-# LANGUAGE OverloadedStrings #-}
module Y2016.Bench where
import Criterion (Benchmark, bench, bgroup, nf, whnf)
import Criterion.Main (env)
import Y2016
bathroomDirections = unlines
[ "ULL"
, "RRDDD"
, "LURDL"
, "UUUUD"
]
benchmarks :: Benchmark
benchmarks =
bgroup "Y2016"
[ bgrou... | tylerjl/adventofcode | benchmark/Y2016/Bench.hs | mit | 906 | 0 | 15 | 334 | 218 | 117 | 101 | 23 | 1 |
{-# LANGUAGE PatternSynonyms, ForeignFunctionInterface, JavaScriptFFI #-}
module GHCJS.DOM.JSFFI.Generated.HTMLAnchorElement
(js_toString, toString, js_setCharset, setCharset, js_getCharset,
getCharset, js_setCoords, setCoords, js_getCoords, getCoords,
js_setDownload, setDownload, js_getDownload,... | plow-technologies/ghcjs-dom | src/GHCJS/DOM/JSFFI/Generated/HTMLAnchorElement.hs | mit | 21,050 | 298 | 11 | 3,505 | 4,587 | 2,417 | 2,170 | 336 | 1 |
{-# LANGUAGE FlexibleContexts #-}
module Util
( executeSqlFile
, updateOrInsert
, trySql
, prompt
, getOrCreate
, getDbConnection
, getCategoryId
, getAccountId
, getEnvelopeId
, defaultFromSql
, readInteger100
, promptPassword
, parseLocalTime
, numberOfOccurren... | jpotterm/manila-hs | src/Util.hs | cc0-1.0 | 3,577 | 0 | 13 | 767 | 1,064 | 533 | 531 | 95 | 2 |
rome
| dalonng/hellos | haskell.hello/decimalismToDecimalism.hs | gpl-2.0 | 6 | 0 | 4 | 2 | 4 | 1 | 3 | -1 | -1 |
module Demo where
{-
seq :: a -> b -> b -- îïðåäåëåí êàê ôóíêöèÿ 2 àðãóìåíòîâ
seq _|_ b = _|_ -- çäåñü èñïîëüçóåòñÿ êîíñòðóêöèÿ îñíîâàíèå, êîòîðàÿ îáîçíà÷àåò ðàñõîäÿùèåñÿ âû÷èñëåíèÿ
seq a b = b
-}
{- Ïðè âû÷èñëåíèè êàêèõ èç ïåðå÷èñëåííûõ íèæå ôóíêöèé èñïîëüçîâàíèå seq ïðåäîòâðàòèò íàðàñòàíèå êîëè÷åñòâà íåâû÷èñëåííûõ ... | devtype-blogspot-com/Haskell-Examples | Seq/Demo.hs | gpl-3.0 | 1,016 | 0 | 12 | 406 | 335 | 185 | 150 | 20 | 1 |
dimap f id (p b b) :: p a b | hmemcpy/milewski-ctfp-pdf | src/content/3.10/code/haskell/snippet02.hs | gpl-3.0 | 27 | 1 | 7 | 9 | 28 | 12 | 16 | -1 | -1 |
module SampleCells where
import MetaLife
metaCells = map (map zeroCellCreator) cellsGlider
cells' = [[alive, alive, dead, alive, alive]]
cells'' = [[alive, alive, alive]]
cellsGlider = [ [ dead, alive, dead]
, [alive, dead, dead]
, [alive, alive, alive] ]
cells''' = [ [dead, dead, d... | graninas/Haskell-Algorithms | Programs/GameOfLifeComonad/SampleCells.hs | gpl-3.0 | 1,724 | 0 | 14 | 529 | 680 | 428 | 252 | 42 | 1 |
module Scaner(
scaner,
Token(..),
Lexem
) where
import qualified Data.List as Lists
import qualified Data.Char as Chars
import IdKeywords
import Delimiters
import StringLiterals
import UnknownLexem
data Token = None | Unknown | IK IdKeyw | D Delims | Str String
deriving(Eq,Ord,Show)
getToken'::String->Int->(S... | geva995/murlyka | src/Utils/Scaner.hs | gpl-3.0 | 1,803 | 0 | 16 | 368 | 926 | 522 | 404 | 43 | 2 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-android-enterprise/gen/Network/Google/Resource/AndroidEnterprise/Installs/Delete.hs | mpl-2.0 | 5,963 | 0 | 23 | 1,537 | 948 | 551 | 397 | 137 | 1 |
{-# LANGUAGE PackageImports #-}
{-
Copyright 2019 The CodeWorld Authors. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2... | alphalambda/codeworld | codeworld-base/src/Image.hs | apache-2.0 | 1,472 | 0 | 8 | 263 | 145 | 90 | 55 | -1 | -1 |
-----------------------------------------------------------------------------
-- Copyright 2019, Ideas project team. This file is distributed under the
-- terms of the Apache License 2.0. For more information, see the files
-- "LICENSE.txt" and "NOTICE.txt", which are included in the distribution.
-----------------... | ideas-edu/ideas | src/Ideas/Text/OpenMath/Tests.hs | apache-2.0 | 1,913 | 0 | 16 | 346 | 405 | 246 | 159 | 31 | 2 |
-----------------------------------------------------------------------------
-- |
-- Module : VecaTests
-- Copyright : (c) 2017 Pascal Poizat
-- License : Apache-2.0 (see the file LICENSE)
--
-- Maintainer : pascal.poizat@lip6.fr
-- Stability : experimental
-- Portability : unknown
--
-- Test file ... | pascalpoizat/veca-haskell | test/VecaTests.hs | apache-2.0 | 16,917 | 0 | 13 | 4,797 | 6,572 | 3,481 | 3,091 | 414 | 1 |
{-# LANGUAGE OverloadedStrings #-}
module DB.Models.Tournament (
Tournament(..)
) where
import Data.Dates (DateTime(..)) -- only required for mock!
import Control.Monad (liftM)
import Data.Tournament
import DB.Model (Model)
import qualified DB.Model as Model
import qualified DB.Models.Location
instance Eq Tou... | Sventimir/turniejowo | src/DB/Models/Tournament.hs | apache-2.0 | 5,107 | 0 | 12 | 3,157 | 868 | 523 | 345 | 108 | 0 |
module Model.Simple.IVar where
import Control.Concurrent.MVar
import Control.Exception
import Control.Monad
import GHC.IO
import Model.Exception
data IVar a = IVar {-# UNPACK #-} !(MVar a) a
newIVar :: IO (IVar a)
newIVar = do
x <- newEmptyMVar
IVar x <$> unsafeDupableInterleaveIO (readMVar x) `catch` \BlockedIn... | ekmett/models | src/Model/Simple/IVar.hs | bsd-2-clause | 689 | 0 | 13 | 141 | 288 | 143 | 145 | 21 | 1 |
{-# OPTIONS -fglasgow-exts #-}
-----------------------------------------------------------------------------
{-| Module : QDockWidget.hs
Copyright : (c) David Harley 2010
Project : qtHaskell
Version : 1.1.4
Modified : 2010-09-02 17:02:30
Warning : this file is machine generated - do n... | keera-studios/hsQt | Qtc/Gui/QDockWidget.hs | bsd-2-clause | 49,191 | 0 | 14 | 7,890 | 15,905 | 8,068 | 7,837 | -1 | -1 |
{-# LANGUAGE RecordWildCards #-}
module Main where
import Control.Applicative ((<$>))
import Control.Monad (when)
import Data.List (intersperse, nub)
import Data.Maybe
import Development.Shake
import ... | konn/hskk | Builder.hs | bsd-3-clause | 6,247 | 0 | 19 | 1,823 | 1,909 | 979 | 930 | 132 | 1 |
{-# LANGUAGE RecordWildCards #-}
module Data.GrowingArray.Generic
( GrowingArray
, new
, newSingleton
, insert
, unsafeFreeze
) where
import Control.Monad.Primitive
import Data.Primitive.MutVar
import Data.Vector.Generic (Vector, Mutable)
import qualified Data.Vector.Generic as... | schernichkin/BSPM | graphomania/src/Data/GrowingArray/Generic.hs | bsd-3-clause | 1,973 | 0 | 17 | 508 | 672 | 339 | 333 | 65 | 2 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE ScopedTypeVariables #-}
module Day8
( day8
) where
import Control.Applicative
import Data.Array.Repa ((:.) (..), Z (..))
import qualified Data.Array.Repa as R
import qualified Data.Array.Repa.Eval as RE
import Data.Attop... | Rydgel/advent-of-code-2016 | src/Day8.hs | bsd-3-clause | 3,009 | 0 | 15 | 759 | 1,187 | 619 | 568 | 83 | 2 |
{-# LANGUAGE OverloadedStrings #-}
module Network.Syncthing.Types.Model
( Model(..)
, ModelState(..)
) where
import Control.Applicative ((<$>), (<*>))
import Control.Monad (MonadPlus (mzero))
import Data.Aeson (FromJSON, ... | jetho/syncthing-hs | Network/Syncthing/Types/Model.hs | bsd-3-clause | 2,219 | 0 | 21 | 775 | 550 | 326 | 224 | 58 | 1 |
{-|
Copyright : (c) Dave Laing, 2017
License : BSD3
Maintainer : dave.laing.80@gmail.com
Stability : experimental
Portability : non-portable
-}
module Fragment.TyVar.Helpers (
tyVar
) where
import Control.Lens (review)
import Ast.Type
tyVar :: a -> Type ki ty a
tyVar = review _TyVar
| dalaing/type-systems | src/Fragment/TyVar/Helpers.hs | bsd-3-clause | 302 | 0 | 6 | 61 | 52 | 30 | 22 | 6 | 1 |
module Util where
import Types
rangeMatch :: Range -> Char -> Maybe Char
rangeMatch Nothing c = Just c
rangeMatch (Just as) c
| c `elem` as = Just c
| otherwise = Nothing
| matthiasgoergens/redgrep | src/Util.hs | bsd-3-clause | 180 | 0 | 8 | 43 | 76 | 38 | 38 | 7 | 1 |
{-# LANGUAGE OverloadedStrings #-}
-- | Tests.
module Main where
import Clockin
import Data.Maybe
import Data.Monoid
import Data.Time.Format
import Data.Time.LocalTime
import System.Exit
import System.Locale
-- | Test that the 'inToday' function works properly.
main :: IO ()
main =
either (\(ts,expected,actual,cu... | chrisdone/clockin | src/Test.hs | bsd-3-clause | 2,206 | 0 | 15 | 786 | 723 | 376 | 347 | 49 | 3 |
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE MultiWayIf #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE OverloadedStrings #-}
module Lazyfoo.Lesson17 (main) where
import Prelude hiding (foldl1)
import Control.Applicative
import Control.Monad
import Data.Foldable
import Data.Monoid
import Data.Maybe
import Foreign.C.Type... | svenkeidel/sdl2 | examples/lazyfoo/Lesson17.hs | bsd-3-clause | 4,846 | 3 | 17 | 1,357 | 1,456 | 732 | 724 | 119 | 4 |
module Lava.Test where
import Lava.Signal
import Lava.Sequential
import Lava.Generic
import Lava.LavaRandom
( newRnd
)
----------------------------------------------------------------
-- test
test :: (Constructive a, Show b, Generic b) => (a -> b) -> IO [b]
test circ =
do rnd <- newRnd
let res = simulate... | dfordivam/lava | Lava/Test.hs | bsd-3-clause | 479 | 0 | 15 | 86 | 146 | 77 | 69 | 12 | 1 |
--------------------------------------------------------------------------------
-- |
-- Module : Graphics.Rendering.OpenGL.Raw.Version20
-- Copyright : (c) Sven Panne 2015
-- License : BSD3
--
-- Maintainer : Sven Panne <svenpanne@gmail.com>
-- Stability : stable
-- Portability : portable
--
------... | phaazon/OpenGLRaw | src/Graphics/Rendering/OpenGL/Raw/Version20.hs | bsd-3-clause | 28,077 | 0 | 4 | 4,313 | 4,279 | 2,860 | 1,419 | 1,414 | 0 |
-- DOM representation and parsing functionality
{-# LANGUAGE OverloadedStrings #-}
module HTML
( DTree (..)
, DElemType (..)
, DAttr (..)
, noAttr
, textElem
, fullTree
, childrenTree
, singletonTree
, parseHTML
) where
import qualified Data.Map.Strict as M
import qualified Dat... | qnnguyen/howser | src/HTML.hs | bsd-3-clause | 1,128 | 0 | 8 | 235 | 241 | 140 | 101 | 33 | 1 |
-----------------------------------------------------------------------------
-- |
-- Module : Graphics.X11.Xlib.Window
-- Copyright : (c) Alastair Reid, 1999-2003
-- License : BSD-style (see the file libraries/base/LICENSE)
--
-- Maintainer : libraries@haskell.org
-- Stability : provisional
-- Porta... | FranklinChen/hugs98-plus-Sep2006 | packages/X11/Graphics/X11/Xlib/Window.hs | bsd-3-clause | 11,523 | 102 | 18 | 2,176 | 1,764 | 966 | 798 | 135 | 1 |
-- (c) The University of Glasgow 2006
{-# LANGUAGE CPP #-}
{-# LANGUAGE KindSignatures #-}
{-# LANGUAGE ConstraintKinds #-}
{-# LANGUAGE BangPatterns #-}
#if __GLASGOW_HASKELL__ < 800
-- For CallStack business
{-# LANGUAGE ImplicitParams #-}
{-# LANGUAGE FlexibleContexts #-}
#endif
-- | Highly random utility function... | mettekou/ghc | compiler/utils/Util.hs | bsd-3-clause | 44,657 | 5 | 34 | 13,132 | 11,340 | 6,209 | 5,131 | 655 | 7 |
module CallByNeed.Evaluator
( valueOf
, run
, eval
, evalProgram
) where
import CallByNeed.Data
import CallByNeed.Parser
import Control.Applicative ((<|>))
import Control.Monad.Trans.State.Lazy (evalStateT)
type EvaluateResult = StatedTry ExpressedValue
liftMaybe ::... | li-zhirui/EoplLangs | src/CallByNeed/Evaluator.hs | bsd-3-clause | 9,949 | 0 | 13 | 2,298 | 3,297 | 1,663 | 1,634 | 219 | 9 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE TypeApplications #-}
module Data.Diverse.WhichBench where
import qualified Criterion.Main as C
import Data.Diverse
bgroup = C.bgroup "Which"
[ C.bench "read" $ C.whnf (read @(Which '[Int, Bool])) "pickN @0 Proxy 5"
]
| louispan/data-diverse | bench/Data/Diverse/WhichBench.hs | bsd-3-clause | 268 | 0 | 15 | 47 | 75 | 43 | 32 | 7 | 1 |
{-# LANGUAGE
TemplateHaskell,
StandaloneDeriving
#-}
-----------------------------------------------------------------------------
-- |
-- Module : HGene.JSCompiler.JSBase
-- License : http://www.gnu.org/copyleft/gpl.html
--
-- Maintainer : mmirman@andrew.cmu.edu
-- Stability : experimental
-- Portabil... | mmirman/haskogeneous | src/HGene/JSCompiler/JSBase.hs | bsd-3-clause | 489 | 0 | 7 | 78 | 42 | 29 | 13 | 6 | 1 |
--------------------------------------------------------------------
-- |
-- Module: HTrade.Backend.Backend
--
-- Main entry point for the backend service.
-- The backend service loads a set of configurations (initially from a default directory)
-- and continues to accept commands from the stdin.
module Main where
im... | davnils/distr-btc | src/HTrade/Backend/Backend.hs | bsd-3-clause | 2,371 | 1 | 18 | 589 | 571 | 303 | 268 | 38 | 6 |
{-# OPTIONS -fglasgow-exts #-}
module API where
import Data.Dynamic
data Unsafe = Unsafe {
field :: String
}
deriving (Typeable, Show)
unsafe :: Unsafe
unsafe = Unsafe { field = "default value" }
| abuiles/turbinado-blog | tmp/dependencies/hs-plugins-1.3.1/testsuite/makewith/unsafeio/api/API.hs | bsd-3-clause | 229 | 0 | 8 | 66 | 54 | 33 | 21 | 8 | 1 |
{-# LANGUAGE BangPatterns #-}
{-# LANGUAGE CPP #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE MagicHash #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE Rank2Types #-}
{-# LANGUAGE Trustworthy #-}
{-# LANGUAGE UnboxedTuples #-}
module Snap.Internal.Http.Serve... | sopvop/snap-server | src/Snap/Internal/Http/Server/Parser.hs | bsd-3-clause | 16,296 | 0 | 23 | 5,047 | 3,680 | 1,874 | 1,806 | 314 | 6 |
#!/usr/bin/runhaskell
-- This is an alternate version of Setup.hs which doesn't use Template Haskell.
-- It's appropriate for Cabal >= 1.18 && < 1.22
module Main where
import Control.Monad
import Data.Char
import Data.List
import Data.Maybe
import Distribution.Simple
import Distribution.Simple.BuildPaths
import Distr... | johntyree/HsQML | SetupNoTH.hs | bsd-3-clause | 12,105 | 0 | 20 | 2,539 | 3,710 | 1,897 | 1,813 | 252 | 3 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE KindSignatures #-}
{-# LANGUAGE ExistentialQuantification #-}
module Ivory.Language.Scope where
-- | Definition scopes for values.
data RefScope
= Global -- ^ Globally allocated
| forall s. Stack s -- ^ Stack allocated
| GaloisInc/ivory | ivory/src/Ivory/Language/Scope.hs | bsd-3-clause | 276 | 0 | 6 | 55 | 30 | 21 | 9 | 7 | 0 |
module Jann01 where
@Export 1.02
@Export2 "Hello"
@Hello { }
@Hello1 []
@Hello2 [ "name", "name", "name" ]
data Hello = Hello { thing :: String, value :: String }
@Hello { value = "hello" }
data Hello1 = Hello1 {
@Value
thing1 :: String,
@Override
@Mutable { name = "Hello" }
value1 :: String
}
... | rahulmutt/ghcvm | tests/suite/annotations/compile/jann01.hs | bsd-3-clause | 595 | 7 | 9 | 161 | 192 | 113 | 79 | -1 | -1 |
{-# LANGUAGE CPP #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE PolyKinds #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE UndecidableInstances #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeApplications #-}
module Main where
import qualified ... | k0001/haskell-money | safe-money-serialise/test/Main.hs | bsd-3-clause | 8,450 | 0 | 18 | 1,562 | 2,546 | 1,333 | 1,213 | 168 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# L... | romanb/amazonka | amazonka-rds/gen/Network/AWS/RDS/DeleteDBSecurityGroup.hs | mpl-2.0 | 3,524 | 0 | 9 | 703 | 336 | 209 | 127 | 47 | 1 |
{-# LANGUAGE NamedFieldPuns #-}
module VerifyImageTrans where
import Verify.Graphics.Vty.Image
import Graphics.Vty.Image.Internal
import Verify
import Data.Word
isHorizTextOfColumns :: Image -> Int -> Bool
isHorizTextOfColumns (HorizText { outputWidth = inW }) expectedW = inW == expectedW
isHorizTextOfColumns (BGF... | jtdaugherty/vty | test/VerifyImageTrans.hs | bsd-3-clause | 1,463 | 0 | 12 | 331 | 279 | 147 | 132 | 23 | 1 |
{-# LANGUAGE ViewPatterns, TemplateHaskell #-}
{-# LANGUAGE GeneralizedNewtypeDeriving,
ViewPatterns,
ScopedTypeVariables #-}
module Bad where
import Control.Applicative ((<$>))
import System.Directory (doesFileExist)
import qualified Data.Map as M
import Data.Map ((!), keys, Map)
data Po... | silkapp/stylish-haskell | examples/Bad.hs | bsd-3-clause | 411 | 0 | 8 | 89 | 84 | 56 | 28 | 13 | 0 |
--------------------------------------------------------------------
-- |
-- Module : MediaWiki.API.Output
-- Description : Serializing MediaWiki API types
-- Copyright : (c) Sigbjorn Finne, 2008
-- License : BSD3
--
-- Maintainer: Sigbjorn Finne <sof@forkIO.com>
-- Stability : provisional
-- Portability: po... | neobrain/neobot | mediawiki/MediaWiki/API/Output.hs | bsd-3-clause | 6,655 | 0 | 12 | 1,537 | 2,263 | 1,106 | 1,157 | 151 | 32 |
--------------------------------------------------------------------
-- |
-- Module : MediaWiki.API.Query.AllUsers
-- Description : Representing 'allusers' requests.
-- Copyright : (c) Sigbjorn Finne, 2008
-- License : BSD3
--
-- Maintainer: Sigbjorn Finne <sof@forkIO.com>
-- Stability : provisional
-- Porta... | neobrain/neobot | mediawiki/MediaWiki/API/Query/AllUsers.hs | bsd-3-clause | 1,521 | 0 | 11 | 330 | 305 | 179 | 126 | 34 | 1 |
{-
(c) The GRASP/AQUA Project, Glasgow University, 1993-1998
-----------------
A demand analysis
-----------------
-}
{-# LANGUAGE CPP #-}
module DmdAnal ( dmdAnalProgram ) where
#include "HsVersions.h"
import DynFlags
import WwLib ... | christiaanb/ghc | compiler/stranal/DmdAnal.hs | bsd-3-clause | 49,748 | 0 | 14 | 14,581 | 6,054 | 3,225 | 2,829 | 408 | 3 |
{-# LANGUAGE GADTs #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE UnliftedNewtypes #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE PolyKinds #-}
{-# LANGUAGE TypeInType #-}
module UnliftedNewtypesLevityBinder where
import GHC.Types (RuntimeRep,TYPE,Coercible)
newtype Ident :: forall (r :: RuntimeRep). TYPE r -> TYPE r whe... | sdiehl/ghc | testsuite/tests/typecheck/should_fail/UnliftedNewtypesLevityBinder.hs | bsd-3-clause | 462 | 0 | 9 | 80 | 125 | 76 | 49 | -1 | -1 |
{-# LANGUAGE GADTs, RecordWildCards, MagicHash, ScopedTypeVariables, CPP,
UnboxedTuples #-}
{-# OPTIONS_GHC -fno-warn-name-shadowing #-}
-- |
-- Execute GHCi messages
--
module GHCi.Run
( run, redirectInterrupts
, toSerializableException, fromSerializableException
) where
import GHCi.CreateBCO
import GHCi.I... | tolysz/prepare-ghcjs | spec-lts8/ghci/GHCi/Run.hs | bsd-3-clause | 13,523 | 0 | 18 | 2,940 | 3,064 | 1,493 | 1,571 | 228 | 34 |
module BaseStruct2Alfa{-(transModule,modPath)-} where
import TiDecorate(DeclsUseType,TiPat(..),drop_use)
import TiPrelude(prelFlip,prelOtherwise,prelTrue)
import PNT(PNT(..))
import TypedIds(IdTy(ConstrOf,Class),ConInfo(..),TypeInfo(..))
import UniqueNames as UN(PN(..),Orig(..),orig)
import HasBaseName
import NameMaps
... | forste/haReFork | tools/hs2alfa/BaseStruct2Alfa.hs | bsd-3-clause | 32,831 | 295 | 22 | 9,179 | 10,716 | 5,867 | 4,849 | -1 | -1 |
module Aws.S3.Commands.DeleteObjects where
import Aws.Core
import Aws.S3.Core
import qualified Data.Map as M
import Data.Maybe
import qualified Data.Text as T
import qualified Data.Text.Encoding as T
import qualified Network.HTTP.Conduit as HTTP
import qualified N... | Soostone/aws | Aws/S3/Commands/DeleteObjects.hs | bsd-3-clause | 5,036 | 0 | 14 | 1,658 | 1,112 | 623 | 489 | -1 | -1 |
module Distribution.Types.ComponentInclude (
ComponentInclude(..),
ci_id,
ci_pkgid,
ci_cname
) where
import Distribution.Types.PackageId
import Distribution.Types.ComponentName
import Distribution.Types.AnnotatedId
-- Once ci_id is refined to an 'OpenUnitId' or 'DefUnitId',
-- the 'includeRequiresRn' ... | mydaum/cabal | Cabal/Distribution/Types/ComponentInclude.hs | bsd-3-clause | 1,002 | 0 | 9 | 195 | 151 | 92 | 59 | 18 | 1 |
#!/usr/bin/env runhaskell
import Control.Concurrent (threadDelay)
main = do
threadDelay $ 5 * 60 * (round $ 1e6)
| tlevine/www.thomaslevine.com | content/!/sleep/sleep-hs.hs | mit | 115 | 0 | 9 | 19 | 39 | 21 | 18 | 3 | 1 |
-- |
-- Stability: stable
--
-- Hspec is a testing framework for Haskell.
--
-- This is the library reference for Hspec.
-- The <http://hspec.github.io/ User's Manual> contains more in-depth
-- documentation.
module Test.Hspec (
-- * Types
Spec
, SpecWith
, Arg
, Example
-- * Setting expectations
, module Test.Hspec... | beni55/hspec | src/Test/Hspec.hs | mit | 1,331 | 0 | 10 | 284 | 221 | 146 | 75 | 39 | 1 |
{-# LANGUAGE OverloadedStrings #-}
module Main (main) where
import qualified Control.Concurrent as Conc
import Criterion (bench, bgroup)
import Criterion.Main (defaultMain, nfIO)
import Data.Default (def)
import qualified Frinfo.Structure as F
import qualified Frinfo.Free as FF
import qualified Frinfo.INotify as IN
i... | Arguggi/Frinfo | benchmark/Main.hs | mit | 1,091 | 0 | 18 | 283 | 302 | 170 | 132 | 26 | 1 |
{-
TRANSFORMERZ - Monad Transformer in vanilla Haskell
Nothing imported - just code
Author: Marco Faustinelli (contacts@faustinelli.net)
Web: http://faustinelli.net/
http://faustinelli.wordpress.com/
Version: 1.0
The MIT License - Copyright (c) 2015 Transformerz Project
-}
module TestNilsson_20 where
... | Muzietto/transformerz | haskell/nilsson/TestNilsson_20.hs | mit | 1,557 | 0 | 11 | 408 | 353 | 191 | 162 | 37 | 1 |
module Main (main) where
import Data.List (isSuffixOf)
import System.Environment (setEnv)
import XMonad.Actions.CycleWS
import XMonad.Actions.DwmPromote
import XMonad.Actions.FlexibleManipulate hiding (position)
import XMonad.Actions.WithAll
import XMonad.Config.Gnome (gnomeRegister)
import XMonad.Hooks.EwmhDesktops
i... | mgsloan/compconfig | env/src/xmonad.hs | mit | 12,775 | 0 | 25 | 2,905 | 2,827 | 1,566 | 1,261 | 250 | 4 |
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE PatternSynonyms #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE UndecidableInstances #-}
{-# LANGUAGE UnicodeSyntax #-}
module TT.Judgement.Bidirectional where
import Control.Applicative
import Control.Lens
import Control.Monad
i... | jonsterling/itt-bidirectional | src/TT/Judgement/Bidirectional.hs | mit | 6,051 | 1 | 20 | 1,801 | 2,997 | 1,477 | 1,520 | 183 | 0 |
{-|
Module : Control.Flower.Compose
Description : Directional composition combinators
-}
module Control.Flower.Compose ((<.), (.>)) where
{- $setup
>>> import Control.Flower.Apply.Lazy
>>> let x = 3
>>> let y = 4
>>> let f = (+2)
>>> let g = (*2)
>>> let h = (+)
-}
{-| Right-flowing, left-associative compositi... | expede/flower | src/Control/Flower/Compose.hs | mit | 808 | 0 | 8 | 184 | 129 | 76 | 53 | 7 | 1 |
{-# LANGUAGE Rank2Types #-}
--
module Main where
import Data.List
import Data.Function
import Data.Monoid
import Options.Applicative
import Control.Applicative -- Compiler slow
{-
basic comments
-}
{- Basics
-- Type
True
sort [1, 2, 3, 4]
case Foo of True -> 1
False -> 2
-- let ... | Airtnp/Freshman_Simple_Haskell_Lib | Intro/hello-world.hs | mit | 42,745 | 0 | 19 | 11,908 | 7,102 | 4,084 | 3,018 | -1 | -1 |
-- Taken from blog post http://blog.tmorris.net/20-intermediate-haskell-exercises/
class Fluffy f where
furry :: (a -> b) -> f a -> f b
-- Exercise 1
-- Relative Difficulty: 1
instance Fluffy [] where
-- furry :: (a -> b) -> [a] -> [b]
furry = map
-- Exercise 2
-- Relative Difficulty: 1
instance Fluffy Maybe... | maurotrb/hs-exercises | 20IntermediateHaskellExercises.hs | mit | 4,481 | 0 | 14 | 1,292 | 1,474 | 777 | 697 | 71 | 1 |
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE DeriveGeneric #-}
-- Refactoring
-- TODO: перейти на lens
module Compiler.Rum.Internal.AST where
import Control.Applicative (Alternative)
import Control.Monad.State (MonadIO, MonadState, StateT)
import Control.Monad.Tr... | vrom911/Compiler | src/Compiler/Rum/Internal/AST.hs | mit | 3,369 | 0 | 9 | 1,030 | 913 | 561 | 352 | 58 | 0 |
module Person
( Address (..)
, Born (..)
, Name (..)
, Person (..)
, bornStreet
, renameStreets
, setBirthMonth
, setCurrentStreet
) where
import Data.Time.Calendar (Day)
data Person = Person { _name :: Name
, _born :: Born
, _address :: Address... | exercism/xhaskell | exercises/practice/lens-person/src/Person.hs | mit | 1,213 | 0 | 8 | 442 | 264 | 156 | 108 | 29 | 1 |
{-# OPTIONS_GHC -fno-warn-orphans #-}
{-# LANGUAGE CPP #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE TemplateHaskell #-}
module Init (
(@/=), (@==), (==@)
, assertNotEqual
, assertNotEmpty
, assertEmpty
, isTravis
, BackendMonad
... | pseudonom/persistent | persistent-test/src/Init.hs | mit | 9,187 | 0 | 14 | 1,880 | 1,708 | 982 | 726 | 125 | 2 |
-- Exercise 0
--
_foldl1 f a bs = foldr (\b -> \g -> (\a -> g (f a b))) id bs a
_foldl2 f a bs = foldr (\a b -> f b a) a bs
_foldl3 f = flip $ foldr (\a b g -> b (f g a)) id
_foldl4 = foldr . flip | anwb/fp-one-on-one | lecture-13-hw.hs | mit | 208 | 0 | 13 | 68 | 139 | 72 | 67 | 4 | 1 |
{-# LANGUAGE CPP #-}
module GHCJS.DOM.NavigatorUserMediaErrorCallback (
#if (defined(ghcjs_HOST_OS) && defined(USE_JAVASCRIPTFFI)) || !defined(USE_WEBKIT)
module GHCJS.DOM.JSFFI.Generated.NavigatorUserMediaErrorCallback
#else
#endif
) where
#if (defined(ghcjs_HOST_OS) && defined(USE_JAVASCRIPTFFI)) || !defined(USE_... | plow-technologies/ghcjs-dom | src/GHCJS/DOM/NavigatorUserMediaErrorCallback.hs | mit | 406 | 0 | 5 | 33 | 33 | 26 | 7 | 4 | 0 |
module Tach.Migration.RoutesSpec (main, spec) where
import Test.Hspec
import Data.ByteString.Lazy.Char8
import Yesod.Test
import Yesod
import Tach.Migration.Routes
import Yesod.Default.Config
import Tach.Impulse.Types.TimeValue
import Data.Aeson
main :: IO ()
main = hspec spec
spec :: Spec
spec = do
yesodSpecWithS... | smurphy8/tach | core-types/tach-migration-routes/test/Tach/Migration/RoutesSpec.hs | mit | 798 | 0 | 12 | 131 | 274 | 149 | 125 | 20 | 1 |
module Tests where
import Prelude hiding (lex, catch)
import Syntax.Lexer
import Syntax.Parser
import Syntax.Term
import Interpreter
import Typechecker
import Control.Exception
import System.Console.ANSI
greenColor = setSGR [SetColor Foreground Vivid Green]
yellowColor = setSGR [SetColor Foreground Vivid Yellow]
redC... | drx/petal | Tests.hs | mit | 9,425 | 0 | 21 | 3,844 | 872 | 427 | 445 | 75 | 3 |
{-# OPTIONS_GHC -fno-warn-unused-imports -fno-warn-unused-binds -fno-warn-orphans #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TupleSections #-}
-- | A test specification for Web.TSBot.ClientQuery.Parse
module Web.TSBot.ClientQuery.ParseSpec (spec) where
import ... | taktoa/TSBot | test-suite/Web/TSBot/ClientQuery/ParseSpec.hs | mit | 2,021 | 0 | 18 | 706 | 487 | 261 | 226 | 44 | 2 |
{-# LANGUAGE PatternSynonyms, ForeignFunctionInterface, JavaScriptFFI #-}
module GHCJS.DOM.JSFFI.Generated.HTMLTitleElement
(js_setText, setText, js_getText, getText, HTMLTitleElement,
castToHTMLTitleElement, gTypeHTMLTitleElement)
where
import Prelude ((.), (==), (>>=), return, IO, Int, Float, Do... | plow-technologies/ghcjs-dom | src/GHCJS/DOM/JSFFI/Generated/HTMLTitleElement.hs | mit | 1,898 | 14 | 11 | 271 | 502 | 302 | 200 | 34 | 1 |
{-# LANGUAGE ExistentialQuantification #-}
module Dumblisp.Eval (eval) where
import Dumblisp.Types
import Dumblisp.Env
import Dumblisp.Primitives
import Control.Monad.Error
import Data.Maybe (isNothing)
makeFunc varargs env params body = return $ Func (map showVal params) varargs body env
makeNormalFunc = makeFunc N... | mmailhot/Dumblisp | Dumblisp/Eval.hs | mit | 2,617 | 0 | 14 | 540 | 1,112 | 545 | 567 | 59 | 3 |
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE LambdaCase #-}
module RWPAS.Role.Psychic
( AuraType(..)
, activate )
where
import Control.Lens
import Control.Monad.State.Strict
i... | Noeda/rwpas | src/RWPAS/Role/Psychic.hs | mit | 4,882 | 0 | 29 | 1,367 | 1,428 | 720 | 708 | -1 | -1 |
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE ScopedTypeVariables #-}
module Main where
import RIO
import qualified RIO.Text as Text
import qualified System.Etc as Etc
import Paths_etc_plain_example (getDataFileName)
------------------------------------------------... | roman/Haskell-etc | examples/etc-plain-example/src/Main.hs | mit | 955 | 0 | 12 | 175 | 176 | 94 | 82 | 20 | 1 |
module Logic.PropositionalLogic.Terms where
import Notes
makeDefs [
"Propositional logic"
, "boolean value"
, "implication"
, "equivalence"
, "valid"
, "satisfiable"
, "unsatisfiable"
, "logically equivalent"
, "conjunctive normal form"
]
| NorfairKing/the-notes | src/Logic/PropositionalLogic/Terms.hs | gpl-2.0 | 293 | 0 | 6 | 84 | 43 | 27 | 16 | -1 | -1 |
module Git.Commit where
import Foreign.ForeignPtr hiding (newForeignPtr)
import Foreign.Concurrent
import Foreign.Ptr
import Foreign.Marshal.Alloc
import Foreign.Marshal.Array
import Foreign.Marshal.Utils
import Foreign.Storable
import Foreign.C.String
import Git.Result
import Git.Repository
import Git.Oid
import Git.... | sakari/hgit | src/Git/Commit.hs | gpl-2.0 | 2,990 | 0 | 48 | 606 | 922 | 473 | 449 | 56 | 2 |
{- | Module : $Header$
- Description : Implementation of logic instance Coalition Logic
- Copyright : (c) Daniel Hausmann & Georgel Calin & Lutz Schroeder, DFKI Lab Bremen,
- Rob Myers & Dirk Pattinson, Department of Computing, ICL
- License : GPLv2 or higher, see LICENSE.txt
- Mainta... | nevrenato/Hets_Fork | GMP/GMP-CoLoSS/GMP/Logics/C.hs | gpl-2.0 | 7,147 | 7 | 21 | 2,602 | 1,758 | 916 | 842 | -1 | -1 |
module Graphics.Implicit.Export.Symbolic.Rebound2 (rebound2) where
import Data.VectorSpace
import Graphics.Implicit.Definitions
rebound2 :: BoxedObj2 -> BoxedObj2
rebound2 (obj, (a,b)) =
let
d :: ℝ2
d = (b ^-^ a) ^/ 10
in
(obj, ((a ^-^ d), (b ^+^ d)))
| silky/ImplicitCAD | Graphics/Implicit/Export/Symbolic/Rebound2.hs | gpl-2.0 | 290 | 0 | 11 | 72 | 107 | 64 | 43 | 9 | 1 |
module Network.Gitit.Plugins.PlantUML (plugin) where
{-
This plugin allows you to include a plantuml diagram
in a page like this:
~~~ {.plantuml name="plantuml_diagram1"}
@startuml
Bob -> Alice : hello
@enduml
~~~
Must be installed and in the path:
- Java virtual machine (java... | jraygauthier/jrg-gitit-plugins | src/Network/Gitit/Plugins/PlantUML.hs | gpl-2.0 | 6,232 | 0 | 23 | 1,804 | 1,197 | 639 | 558 | 81 | 4 |
module Antimony.Resource.Primitives where
import H.Generic
import Antimony.Resource.Core
import Antimony.Types
data Role = RoleOwner | RoleGroup | RoleOther
deriving (Eq, Ord, Enum, Bounded, Show, Typeable)
data Permissions =
Permissions
{ canRead :: Bool
, canWrite :: Bool
, canExecute :: Bool
} ... | ktvoelker/Antimony | src/Antimony/Resource/Primitives.hs | gpl-3.0 | 920 | 0 | 10 | 182 | 328 | 184 | 144 | 29 | 0 |
{-# LANGUAGE ExistentialQuantification, Rank2Types #-}
{-# LANGUAGE LambdaCase #-}
module Craeft.TypedAST.Pass where
import Control.Lens
import Control.Monad
import Debug.Trace (trace)
import Craeft.TypedAST.Impl
import Craeft.TypedAST.Lens
import qualified Craeft.Types as Types
import ... | ikuehne/craeft-hs | lib/Craeft/TypedAST/Pass.hs | gpl-3.0 | 3,326 | 0 | 13 | 963 | 851 | 424 | 427 | 66 | 6 |
module Jason
(
JValue (..),
stringify,
parse,
) where
import Jason.Core
import Jason.Parse
import Jason.Stringify
| TOSPIO/jason | src/Jason.hs | gpl-3.0 | 156 | 0 | 5 | 57 | 35 | 23 | 12 | 8 | 0 |
module DataHand.USB.Descriptors where
import System.USB.Descriptors
import Data.EnumSet hiding (empty)
import Data.ByteString (empty)
deviceDescriptor = DeviceDesc {
deviceUSBSpecReleaseNumber = (0, 0, 0, 2)
, deviceReleaseNumber = (0, 0, 0, 1)
, deviceClass = 0
, deviceSubClass = 0
, deviceProtocol = 0
... | elitak/hs-datahand | src/DataHand/USB/Descriptors.hs | gpl-3.0 | 5,972 | 0 | 8 | 2,866 | 298 | 223 | 75 | 24 | 1 |
{-# LANGUAGE NoImplicitPrelude, DeriveGeneric, OverloadedStrings, PatternGuards, RecordWildCards #-}
module Lamdu.Expr.Scheme
( Scheme(..), schemeForAll, schemeConstraints, schemeType
, make, mono, any
, alphaEq
) where
import Prelude.Compat hiding (any)
import Control.DeepSeq (NFD... | da-x/Algorithm-W-Step-By-Step | Lamdu/Expr/Scheme.hs | gpl-3.0 | 4,664 | 0 | 18 | 1,246 | 1,308 | 714 | 594 | 105 | 2 |
{-
- Lowlevel IRC client library for HircBot.
- Copyright (C) 2008-2019 Madis Janson
-
- This file is part of HircBot.
-
- HircBot 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 ... | mth/hirc | Hirc.hs | gpl-3.0 | 8,947 | 0 | 21 | 2,880 | 3,130 | 1,566 | 1,564 | -1 | -1 |
module Engine where
import Grid
import Language
import Control.Monad.Reader
--type RoboM a = ReaderT Prog (State [Instr]) a
--runRobo :: RoboM a -> Prog -> a
--runRobo m prog = evalState (runReaderT m prog) $ head prog
step :: Game -> [Instr] -> Reader Prog (Game, [Instr])
step game instrs = do
let (Instr cond a... | ad0/robozzle-hs | src/Engine.hs | gpl-3.0 | 2,102 | 0 | 18 | 739 | 700 | 359 | 341 | 47 | 7 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | rueshyna/gogol | gogol-groups-settings/gen/Network/Google/Resource/GroupsSettings/Groups/Get.hs | mpl-2.0 | 2,646 | 0 | 12 | 606 | 299 | 184 | 115 | 49 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-android-publisher/gen/Network/Google/Resource/AndroidPublisher/Systemapks/Variants/List.hs | mpl-2.0 | 5,478 | 0 | 20 | 1,317 | 806 | 467 | 339 | 121 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# L... | dysinger/amazonka | amazonka-s3/gen/Network/AWS/S3/CopyObject.hs | mpl-2.0 | 21,998 | 0 | 21 | 5,649 | 3,095 | 1,811 | 1,284 | 299 | 1 |
module HelperSequences.A007814 (a007814) where
a007814 n = last $ takeWhile (\a -> n `mod` 2^a == 0) [0..]
| peterokagey/haskellOEIS | src/HelperSequences/A007814.hs | apache-2.0 | 108 | 0 | 11 | 19 | 53 | 30 | 23 | 2 | 1 |
-- Copyright 2016 TensorFlow authors.
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compliance with the License.
-- You may obtain a copy of the License at
--
-- http://www.apache.org/licenses/LICENSE-2.0
--
-- Unless required by applicable law or agree... | tensorflow/haskell | tensorflow/src/TensorFlow/Nodes.hs | apache-2.0 | 5,616 | 0 | 16 | 1,281 | 1,591 | 839 | 752 | 89 | 2 |
{-# LANGUAGE TemplateHaskell #-}
module Main(main) where
import Data.Int
import DNA
import DDP
import DDP_Slice
----------------------------------------------------------------
-- Distributed dot product
--
-- Note that actors which do not spawn actors on other nodes do not
-- receive CAD.
------------------------... | SKA-ScienceDataProcessor/RC | MS2/dna-programs/ddp-in-memory-large.hs | apache-2.0 | 1,497 | 0 | 16 | 362 | 345 | 182 | 163 | 26 | 2 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.