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 RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TupleSections #-}
-- | http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-wafregional-sqlinjectionmatchset-fieldtomatch.html
module Stratosphere.ResourceProperties.WAFRegionalSqlInjec... | frontrowed/stratosphere | library-gen/Stratosphere/ResourceProperties/WAFRegionalSqlInjectionMatchSetFieldToMatch.hs | mit | 2,446 | 0 | 13 | 214 | 267 | 153 | 114 | 28 | 1 |
module HLint.Default where
import Control.Arrow
import Control.Exception
import Control.Monad
import Data.Function
import Data.Int
import Data.List as X
import Data.Maybe
import Data.Monoid
import System.IO
import IO as System.IO
import List as Data.List
import Maybe as Data.Maybe
import Monad as Control.Monad
-- I... | alphaHeavy/hlint | data/Default.hs | gpl-2.0 | 17,195 | 0 | 11 | 3,905 | 6,285 | 3,255 | 3,030 | -1 | -1 |
{-# LANGUAGE CPP #-}
#if __GLASGOW_HASKELL__ < 710
{-# LANGUAGE OverlappingInstances #-}
#endif
{-# LANGUAGE ViewPatterns, RankNTypes, ScopedTypeVariables, TypeSynonymInstances, FlexibleInstances #-}
module Graphics.Implicit.ExtOpenScad.Util.OVal where
import Graphics.Implicit.Definitions
import Graphics.Implicit.Ex... | silky/ImplicitCAD | Graphics/Implicit/ExtOpenScad/Util/OVal.hs | gpl-2.0 | 4,519 | 0 | 18 | 1,260 | 1,633 | 847 | 786 | 108 | 5 |
{-# OPTIONS -fglasgow-exts -fno-monomorphism-restriction #-}
----------------------------------------------------------------------------
-- |
-- Module : Text.XML.Schema.SOAP11.Encoding
-- Copyright : (c) Simon Foster 2004
-- License : GPL version 2 (see COPYING)
--
-- Maintainer : aca01sdf@shef.ac.uk... | twopoint718/haifa | src/Text/XML/SOAP11/Encoding.hs | gpl-2.0 | 1,801 | 0 | 5 | 274 | 108 | 81 | 27 | 14 | 1 |
module Test.QuickFuzz.Derive
( module Test.QuickFuzz.Derive.Actions
, module Test.QuickFuzz.Derive.Arbitrary
, module Test.QuickFuzz.Derive.Fixable
, module Test.QuickFuzz.Derive.Mutation
, module Test.QuickFuzz.Derive.Show
, module Test.QuickFuzz.Derive.Generator
) where
import Test.QuickFuzz.Derive.Actions... | elopez/QuickFuzz | src/Test/QuickFuzz/Derive.hs | gpl-3.0 | 558 | 0 | 5 | 95 | 99 | 72 | 27 | 13 | 0 |
module SpacialGameMsg.SGModelMsg where
import System.Random
import Control.Monad.STM
import Debug.Trace
import qualified PureAgentsAct as PA
import qualified Data.Map as Map
data SGState = Defector | Cooperator deriving (Eq, Show)
data SGMsg = NeighbourPayoff (SGState, Double) | NeighbourState SGState deriving (Eq, ... | thalerjonathan/phd | public/ArtIterating/code/haskell/PureAgentsAct/src/SpacialGameMsg/SGModelMsg.hs | gpl-3.0 | 7,875 | 0 | 15 | 2,582 | 2,360 | 1,293 | 1,067 | 158 | 2 |
{-# LANGUAGE MultiParamTypeClasses, FlexibleInstances #-}
{-|
Module : Label
Description : Label widget for the Minitel
Copyright : (c) Frédéric BISSON, 2014
License : GPL-3
Maintainer : zigazou@free.fr
Stability : experimental
Portability : POSIX
This module provides a Label widget for the Minitel. A l... | Zigazou/HaMinitel | src/Minitel/UI/Label.hs | gpl-3.0 | 1,778 | 0 | 9 | 497 | 379 | 221 | 158 | 41 | 1 |
{-# LANGUAGE PackageImports #-}
import "WebShelf" Application (getApplicationDev)
import Network.Wai.Handler.Warp
(runSettings, defaultSettings, settingsPort)
import Control.Concurrent (forkIO)
import System.Directory (doesFileExist, removeFile)
import System.Exit (exitSuccess)
import Control.Concurrent (threadDela... | k-bx/web_shelf | WebShelf/devel.hs | gpl-3.0 | 709 | 0 | 10 | 123 | 186 | 101 | 85 | 23 | 2 |
import System.Exit
import Test.HUnit
import BlackJack
import TestDecks
tests =
[
TestCase $ assertEqual "value of King" 10
(getValueCard (Card Hearts King)) ,
TestCase $ assertEqual "blackjack" 21
(getValueHand [Card Hearts King, Card Clubs Nine, Card Spades Two]),
TestCas... | Norberg/cardgame | test/BlackJackTest.hs | gpl-3.0 | 3,687 | 0 | 12 | 1,009 | 1,026 | 487 | 539 | 74 | 1 |
module REPL (runREPL) where
import Control.Monad.IO.Class (liftIO)
import Data.Text (pack)
import System.Console.Haskeline
import Hython.Interpreter (defaultInterpreterState, interpret)
runREPL :: IO ()
runREPL = do
state <- defaultInterpreterState "<repl>"
runInputT settings (loop state)
where
loop s... | mattgreen/hython | src/REPL.hs | gpl-3.0 | 816 | 0 | 18 | 271 | 233 | 116 | 117 | 21 | 4 |
module Mescaline.Sampler.Keyboard where
import Control.Concurrent.Chan
import Control.Monad.Trans (liftIO)
import Data.IORef
import Data.Map (Map)
import qualified Data.Map as Map
import Graphics.UI.Gtk.Gdk.EventM
-- import Graphics.UI.Gtk (Event)
-- import qualifie... | kaoskorobase/mescaline | tools/sampler/Mescaline/Sampler/Keyboard.hs | gpl-3.0 | 1,518 | 2 | 19 | 548 | 404 | 211 | 193 | 35 | 3 |
{-# LANGUAGE ExistentialQuantification #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE TupleSections #-}
{-# LANGUAGE TypeSy... | input-output-hk/rscoin-haskell | test/Test/RSCoin/Pure/Update.hs | gpl-3.0 | 2,065 | 0 | 10 | 572 | 587 | 327 | 260 | 41 | 1 |
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
-- |
-- Module : Network.Google.Classroom.T... | rueshyna/gogol | gogol-classroom/gen/Network/Google/Classroom/Types/Product.hs | mpl-2.0 | 93,104 | 0 | 27 | 23,844 | 17,740 | 10,219 | 7,521 | 1,950 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-consumersurveys/gen/Network/Google/Resource/ConsumerSurveys/Surveys/Stop.hs | mpl-2.0 | 2,703 | 0 | 13 | 619 | 305 | 187 | 118 | 50 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | rueshyna/gogol | gogol-deploymentmanager/gen/Network/Google/Resource/DeploymentManager/Operations/List.hs | mpl-2.0 | 6,574 | 0 | 18 | 1,441 | 679 | 409 | 270 | 94 | 1 |
-- brittany { lconfig_columnAlignMode: { tag: ColumnAlignModeDisabled }, lconfig_indentPolicy: IndentPolicyLeft }
autocheckCases =
[ ("Never Deadlocks", representative deadlocksNever)
, ("No Exceptions", representative exceptionsNever)
, ("Consistent Result", alwaysSame) -- already representative
]
| lspitzner/brittany | data/Test521.hs | agpl-3.0 | 308 | 0 | 7 | 39 | 41 | 25 | 16 | 4 | 1 |
module Model.AssetSegment.TypesTest (test_all) where
import Test.Tasty
import Test.Tasty.HUnit
import Model.Asset.Types
import Model.AssetSlot.Types
import Model.AssetSegment.Types
import Model.Container.Types
import Model.Id.Types
import Model.Release.Types
import Model.Segment (fullSegment)
import Model.Slot.Types
... | databrary/databrary | test/Model/AssetSegment/TypesTest.hs | agpl-3.0 | 7,230 | 0 | 13 | 2,012 | 1,023 | 595 | 428 | 132 | 2 |
{-# LANGUAGE PackageImports #-}
module ProjectM36.Sessions where
import Control.Concurrent.STM
#if MIN_VERSION_stm_containers(1,0,0)
import qualified StmContainers.Map as StmMap
import qualified StmContainers.Set as StmSet
#else
import qualified STMContainers.Map as StmMap
import qualified STMContainers.Set as StmSet
#... | agentm/project-m36 | src/lib/ProjectM36/Sessions.hs | unlicense | 1,735 | 0 | 16 | 224 | 344 | 195 | 149 | 25 | 1 |
module PowerDivisibility.A254733Spec (main, spec) where
import Test.Hspec
import PowerDivisibility.A254733 (a254733)
main :: IO ()
main = hspec spec
spec :: Spec
spec = describe "A254733" $
it "correctly computes the first 20 elements" $
take 20 (map a254733 [1..]) `shouldBe` expectedValue where
expectedV... | peterokagey/haskellOEIS | test/PowerDivisibility/A254733Spec.hs | apache-2.0 | 385 | 0 | 10 | 59 | 160 | 95 | 65 | 10 | 1 |
-- Copyright 2020 Google LLC
--
-- 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 agreed to in ... | google/hrepl | hrepl/tests/Chain2Dupe.hs | apache-2.0 | 664 | 0 | 5 | 115 | 36 | 26 | 10 | 3 | 1 |
module Codec.JVM.Const
(Const(..),
ConstVal(..),
constTag,
constValType,
cclass,
cstring,
cint,
clong,
cfloat,
cdouble,
getObjConst,
isConstCategory2
)
where
import Data.Text (Text)
import Data.Word (Word8)
import Data.Int (Int32,Int64)
import Codec.JVM.Types (IClassName(..), Fie... | rahulmutt/codec-jvm | src/Codec/JVM/Const.hs | apache-2.0 | 2,451 | 0 | 9 | 514 | 761 | 414 | 347 | 75 | 1 |
{-# LANGUAGE GADTs #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecursiveDo #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE UnicodeSyntax #-}
{-# OPTIONS_GHC -fno-warn-missing-import-lists ... | gspia/reflex-dom-htmlea | lib/src/Reflex/Dom/HTML5/Component/Common/DrawFuns.hs | bsd-3-clause | 8,890 | 0 | 16 | 2,939 | 1,694 | 912 | 782 | 123 | 3 |
{-# LANGUAGE OverloadedStrings #-}
module DTX2MIDI.MIDI
( MIDI (..),
updateInitialTempo,
bpmToTempo,
)
where
import Codec.Midi (Midi (..))
import qualified Codec.Midi as Midi
type MIDI = Midi
type BPM = Double
-- | Euterpeaの固定テンポ(bpm = 120, tempo = 500000)を上書きする
updateInitialTempo :: Midi.Tempo -> MIDI... | akiomik/dtx2midi | src/DTX2MIDI/MIDI.hs | bsd-3-clause | 718 | 0 | 10 | 134 | 201 | 114 | 87 | 17 | 2 |
import DSL.Abstract.Api
type Literal = String
a, b, c :: Literal
a = "A"
b = "B"
c = "C"
example1 :: Model Literal
example1 = Abst [a, b, c] [(a, b), (b, c)]
example2 :: Model Literal
example2 = Abst [a, b] [(a, b), (b, a)]
d, e :: Literal
d = "D"
e = "E"
example3 :: Mo... | shingoOKAWA/hsarg-haskell | src/DSL/Abstract/Test.hs | bsd-3-clause | 503 | 0 | 7 | 152 | 294 | 183 | 111 | 17 | 1 |
module Renderer where
import StringUtils
import Category
import PaymentTracker
import Data.Char
import Data.List (intercalate)
chartPaymentsByCat :: [Payment] -> String
chartPaymentsByCat payments =
let presentable = presentableChartForCats . percentPerCategory $ payments
catsChart = map joinCategoryAndBars... | Sam-Serpoosh/WatchIt | src/Renderer.hs | bsd-3-clause | 3,121 | 0 | 13 | 542 | 984 | 521 | 463 | 58 | 2 |
{-# LANGUAGE DeriveDataTypeable #-}
-- | Possible options passed to The ABS-Haskell compiler
module ABS.Compiler.CmdOpt where
import System.Console.CmdArgs
import System.IO.Unsafe (unsafePerformIO)
{-# NOINLINE cmdOpt #-}
cmdOpt :: CmdOpt
cmdOpt = unsafePerformIO (cmdArgs cmdOptSpec)
data CmdOpt = CmdOpt {
abs... | abstools/habs | src/ABS/Compiler/CmdOpt.hs | bsd-3-clause | 1,787 | 0 | 12 | 445 | 239 | 137 | 102 | 25 | 1 |
{-# LANGUAGE OverloadedStrings #-}
module Main where
import Control.Applicative
import Control.Concurrent (forkIO, killThread)
import qualified Control.Exception as CE
import Control.Monad (unless)
import qualified Data.ByteString as B
import qualified Data.ByteString.Char8 as C8
import qualified Data.ByteString.Lazy... | kcharter/spdy-base | examples/SServe.hs | bsd-3-clause | 4,156 | 0 | 15 | 1,047 | 1,084 | 563 | 521 | 91 | 3 |
{-# LANGUAGE TypeFamilies, FlexibleContexts, TypeOperators, FlexibleInstances #-}
-- |
-- Module : Control.FiniteStateMachine
-- Copyright : (C) Robert Atkey 2013
-- License : BSD3
--
-- Maintainer : bob.atkey@gmail.com
-- Stability : experimental
-- Portability : unknown
--
-- This mod... | bobatkey/Forvie | src/Data/FiniteStateMachine.hs | bsd-3-clause | 6,764 | 0 | 12 | 1,735 | 1,399 | 749 | 650 | 94 | 2 |
--------------------------------------------------------------------------------
-- |
-- Module : Graphics.Rendering.OpenGL.Raw.AMD.SamplePositions
-- Copyright : (c) Sven Panne 2015
-- License : BSD3
--
-- Maintainer : Sven Panne <svenpanne@gmail.com>
-- Stability : stable
-- Portability : portable... | phaazon/OpenGLRaw | src/Graphics/Rendering/OpenGL/Raw/AMD/SamplePositions.hs | bsd-3-clause | 755 | 0 | 4 | 88 | 49 | 40 | 9 | 5 | 0 |
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE ConstraintKinds #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE UndecidableInstances #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE TypeFamilies #-}
module Data.Logic.CNF where
import Data.Logi... | kylcarte/finally-logical | src/Data/Logic/CNF.hs | bsd-3-clause | 4,908 | 0 | 11 | 991 | 1,929 | 1,023 | 906 | 120 | 1 |
module Main where
import Data.Maybe
import Lib
main :: IO ()
main = print . fromMaybe "Problem not solved" $ problem "15"
| anup-2s/project-euler | app/Main.hs | bsd-3-clause | 124 | 0 | 7 | 24 | 41 | 22 | 19 | 5 | 1 |
{-|
Module : Idris.IBC
Description : Core representations and code to generate IBC files.
Copyright :
License : BSD3
Maintainer : The Idris Community.
-}
{-# LANGUAGE FlexibleInstances, TypeSynonymInstances #-}
{-# OPTIONS_GHC -fwarn-incomplete-patterns #-}
{-# OPTIONS_GHC -fwarn-unused-imports #-}
module... | uuhan/Idris-dev | src/Idris/IBC.hs | bsd-3-clause | 42,794 | 0 | 21 | 16,245 | 13,518 | 6,647 | 6,871 | 1,005 | 17 |
{-# LANGUAGE OverloadedStrings #-}
import Data.Text (Text)
import qualified Data.Text as T (pack)
import Shelly
( Sh, StdHandle(InHandle, OutHandle, ErrorHandle)
, StdStream(CreatePipe, Inherit, UseHandle), liftIO, echo_err, errExit, exit
, lastExitCode, runHandles, shelly, silently
)
import System.Environment... | yanhan/bin-src | hs-src/git-commit-time.hs | bsd-3-clause | 2,399 | 0 | 25 | 725 | 602 | 308 | 294 | 58 | 3 |
module Main where
import Hack.Handler.Hyena
import Hack.Contrib.Middleware.ContentLength
import Hack.Frontend.Happstack
import Network.Gitit
main = do
conf <- getDefaultConfig
createStaticIfMissing conf
createTemplateIfMissing conf
createRepoIfMissing conf
initializeGititState conf
run . content_length $ ... | nfjinjing/hack-handler-hyena | src/gitit.hs | bsd-3-clause | 347 | 0 | 10 | 45 | 84 | 42 | 42 | 12 | 1 |
-- 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. An additional grant
-- of patent rights can be found in the PATENTS file in the same directory.
module Duckling.D... | rfranek/duckling | tests/Duckling/Duration/PT/Tests.hs | bsd-3-clause | 603 | 0 | 9 | 96 | 80 | 51 | 29 | 11 | 1 |
{-# LANGUAGE ViewPatterns #-}
module FizzBuzz where
import Control.Monad
import Control.Monad.Trans.State
data FizzBuzz = FizzBuzz | Fizz | Buzz
fb :: Integer -> Maybe FizzBuzz
fb n | n `mod` 15 == 0 = Just FizzBuzz
| n `mod` 5 == 0 = Just Fizz
| n `mod` 3 == 0 = Just Buzz
| other... | vasily-kirichenko/haskell-book | src/FizzBuzz.hs | bsd-3-clause | 882 | 0 | 10 | 203 | 361 | 185 | 176 | 26 | 1 |
-- | This module exposes a function which can relativize URL's on a webpage.
--
-- This means that one can deploy the resulting site on
-- @http:\/\/example.com\/@, but also on @http:\/\/example.com\/some-folder\/@
-- without having to change anything (simply copy over the files).
--
-- To use it, you should use absolu... | sol/hakyll | src/Hakyll/Web/Urls/Relativize.hs | bsd-3-clause | 1,624 | 0 | 10 | 305 | 258 | 156 | 102 | 20 | 2 |
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE TypeSynonymInstances #-}
{-# LANGUAGE FlexibleInstances #-}
module Rogue.Types where
import Control.Lens hiding (Level)
import Control.Lens.TH (declareLenses,declarePrisms)
import Data.Array (Array,bounds)
imp... | elliottt/rogue | src/Rogue/Types.hs | bsd-3-clause | 3,519 | 0 | 9 | 1,260 | 683 | 376 | 307 | 105 | 1 |
{-# LANGUAGE NoImplicitPrelude #-}
module Mafia.Twine.Queue (
Queue
, newQueue
, readQueue
, tryReadQueue
, writeQueue
, isQueueEmpty
) where
import Control.Concurrent.STM.TBQueue (TBQueue, newTBQueue, tryReadTBQueue
, readTBQueue, writeTBQueue,... | ambiata/mafia | src/Mafia/Twine/Queue.hs | bsd-3-clause | 925 | 0 | 8 | 259 | 261 | 143 | 118 | 31 | 1 |
-- | Example:
--
-- @
-- {-\# LANGUAGE QuasiQuotes \#-}
-- module Main where
--
-- import Control.Monad (when)
-- import Data.Char (toUpper)
-- import System.Environment (getArgs)
-- import System.Console.Docopt
--
-- patterns :: Docopt
-- patterns = [docopt|
-- docopt-sample version 0.1.0
--
-- Usage:
-- docopt-samp... | docopt/docopt.hs | System/Console/Docopt.hs | mit | 1,230 | 0 | 5 | 262 | 79 | 68 | 11 | 6 | 0 |
{- Bloop, Copyright (C) 2005, Jaap Weel -- 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 program is distributed in the h... | jaapweel/bloop | ParseBloop.hs | gpl-2.0 | 6,628 | 0 | 13 | 2,306 | 1,565 | 767 | 798 | 129 | 2 |
module Sound.Tidal.Params where
-- Please note, this file is generated by bin/generate-params.hs
-- Submit any pull requests against that file and/or params-header.hs
-- in the same folder, thanks.
{-
Params.hs - Provides the basic control patterns available to TidalCycles by default
Copyright (C) 2021, Alex ... | bgold-cosmos/Tidal | src/Sound/Tidal/Params.hs | gpl-3.0 | 145,052 | 0 | 14 | 23,387 | 49,354 | 25,614 | 23,740 | 2,679 | 1 |
module ExprIfCond where
f = if 3 then 4 else 5
| roberth/uu-helium | test/typeerrors/Examples/ExprIfCond.hs | gpl-3.0 | 48 | 0 | 5 | 12 | 17 | 11 | 6 | 2 | 2 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# L... | romanb/amazonka | amazonka-elastictranscoder/gen/Network/AWS/ElasticTranscoder/ListPresets.hs | mpl-2.0 | 4,787 | 0 | 12 | 1,036 | 676 | 399 | 277 | 73 | 1 |
module Hans.Nat where
import Hans.Addr (toAddr)
import qualified Hans.Nat.State as Nat
import Hans.Network (Network)
import Hans.Tcp.Packet (TcpPort)
import Hans.Types
import Hans.Udp.Packet (UdpPort)
-- | Add a TCP port-forwarding rule.
forwardTcpPort :: Network add... | GaloisInc/HaNS | src/Hans/Nat.hs | bsd-3-clause | 2,101 | 0 | 12 | 810 | 378 | 208 | 170 | 45 | 1 |
module Distribution.Query.TH where
import MonadUtils
import Data.DeriveTH
import Language.Haskell.TH
deriveMany :: Derivation -> [Name] -> Q [Dec]
deriveMany = concatMapM . derive
| beni55/cabal-query | src/Distribution/Query/TH.hs | bsd-3-clause | 182 | 0 | 8 | 24 | 52 | 31 | 21 | 6 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE GADTs #-}
{-# LANGUAGE PolyKinds #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE UnicodeSyntax #-}
module T16326_Compile1 where
import Data.Kind
type DApply a (b :: a -> Type) (f :: forall (x :: a) -> b x) (x :: a) =
f... | sdiehl/ghc | testsuite/tests/dependent/should_compile/T16326_Compile1.hs | bsd-3-clause | 1,344 | 0 | 14 | 452 | 530 | 314 | 216 | -1 | -1 |
--
-- 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/XenMgr/Connect/Xenvm.hs | gpl-2.0 | 14,597 | 4 | 16 | 4,506 | 4,193 | 2,085 | 2,108 | 309 | 5 |
{-# LANGUAGE MagicHash #-}
import GHC.Exts hiding (fromList)
import Unsafe.Coerce
import Data.Map.Strict
newtype Age = Age Int
fooAge :: Map Int Int -> Map Int Age
fooAge = fmap Age
fooCoerce :: Map Int Int -> Map Int Age
fooCoerce = fmap coerce
fooUnsafeCoerce :: Map Int Int -> Map Int Age
fooUnsafeCoerce = fmap un... | shockkolate/containers | tests-ghc/unreliable/mapcoercesmap.hs | bsd-3-clause | 598 | 1 | 12 | 132 | 277 | 135 | 142 | 20 | 2 |
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE TupleSections #-}
-- | Construct a @Plan@ for how to build
module Stack.Build.ConstructPlan
( constr... | Denommus/stack | src/Stack/Build/ConstructPlan.hs | bsd-3-clause | 21,884 | 0 | 27 | 7,017 | 5,590 | 2,809 | 2,781 | 479 | 9 |
{-# LANGUAGE DeriveFunctor #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TemplateHaskell #-}
module NN.Backend.Torch.Codegen where
import Control.Applicative
import Control.Lens hiding (assign)
import ... | sjfloat/dnngraph | NN/Backend/Torch/Codegen.hs | bsd-3-clause | 2,980 | 0 | 14 | 785 | 923 | 471 | 452 | 73 | 1 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE TemplateHaskell, CPP #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE PatternGuards #-}
-- | Static file serving for WAI.
module Network.Wai.Application.Static
( -- * WAI application
staticApp
-- ** Default Settings
... | AndrewRademacher/wai | wai-app-static/Network/Wai/Application/Static.hs | mit | 10,596 | 0 | 18 | 3,049 | 2,503 | 1,306 | 1,197 | 195 | 9 |
-----------------------------------------------------------------------------
-- |
-- Module : Distribution.Client.Dependency
-- Copyright : (c) David Himmelstrup 2005,
-- Bjorn Bringert 2007
-- Duncan Coutts 2008
-- License : BSD-like
--
-- Maintainer : cabal-devel... | DavidAlphaFox/ghc | libraries/Cabal/cabal-install/Distribution/Client/Dependency.hs | bsd-3-clause | 26,991 | 1 | 16 | 6,898 | 4,519 | 2,488 | 2,031 | 460 | 4 |
module C2(myFringe, Tree(..), SameOrNot(..)) where
data Tree a = Leaf a | Branch (Tree a) (Tree a)
sumTree:: (Num a) => Tree a -> a
sumTree (Leaf x ) = x
sumTree (Branch left right) = sumTree left + sumTree right
myFringe:: Tree a -> [a]
myFringe (Leaf x ) = [x]
myFringe (Branch left right) = myFringe l... | kmate/HaRe | old/testing/moveDefBtwMods/C2_TokOut.hs | bsd-3-clause | 505 | 0 | 8 | 143 | 235 | 124 | 111 | 14 | 1 |
{-# LANGUAGE Arrows #-}
module Arrow where
import Control.Arrow
import qualified Control.Category as Cat
addA :: Arrow a => a b Int -> a b Int -> a b Int
addA f g = proc x -> do
y <- f -< x
z <- g -< x
returnA -< y + z
newtype Circuit a b = Circuit { unCircuit :: a -> ... | olsner/ghc | testsuite/tests/printer/Ppr002.hs | bsd-3-clause | 1,381 | 4 | 14 | 437 | 636 | 341 | 295 | -1 | -1 |
module SPARC.CodeGen.Base (
InstrBlock,
CondCode(..),
ChildCode64(..),
Amode(..),
Register(..),
setFormatOfRegister,
getRegisterReg,
mangleIndexTree
)
where
import SPARC.Instr
import SPARC.Cond
import SPARC.AddrMode
import SPARC.Regs
import Format
impo... | wxwxwwxxx/ghc | compiler/nativeGen/SPARC/CodeGen/Base.hs | bsd-3-clause | 3,202 | 0 | 11 | 840 | 473 | 267 | 206 | 58 | 2 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE OverloadedLists #-}
{-# LANGUAGE TemplateHaskell #-}
module Tests.Math.Hclaws.Systems.TveitoWinther1995_3 (
tests
) where
import Test.Tasty (TestTree, testGroup)
import qualified Test.Tasty.QuickCheck as QC
import qualified Test.Tasty.SmallCheck as SC
import Test.Tasty.HUni... | mikebenfield/hclaws | test/Tests/Math/Hclaws/Systems/TveitoWinther1995_3.hs | isc | 1,581 | 0 | 10 | 388 | 403 | 238 | 165 | 50 | 1 |
module Utils
( module Utils
) where
import Utils.Calendar as Utils
import Utils.Email as Utils
import Utils.Ldap as Utils
import Utils.Protobuf as Utils
import Utils.Session as Utils
import Utils.Visual as Utils
| dgonyeo/lambdollars | Utils.hs | mit | 231 | 0 | 4 | 50 | 52 | 37 | 15 | 8 | 0 |
{-# LANGUAGE RankNTypes #-}
module Evo.Type where
import System.Random.MWC
import Data.STRef
import Control.Monad.ST
import Control.Monad.Reader
type Genotype = [Bool]
type Phenotype = Genotype
type Population = [Genotype]
data Ref s = Ref
{ gen :: STRef s (GenST s)
}
type Evo s a = ReaderT (Ref s) (ST s) ... | banacorn/evo | src/Evo/Type.hs | mit | 3,233 | 0 | 11 | 818 | 409 | 247 | 162 | 26 | 1 |
module ProjectEuler.Problem013 (solve) where
solve :: Integer
solve = read . take 10 . show . sum $ xs
where
xs :: [Integer]
xs = [ 37107287533902102798797998220837590246510135740250
, 46376937677490009712648124896970078050417018260538
, 74324986199524741059474233309513058123726617309629
... | hachibu/project-euler | src/ProjectEuler/Problem013.hs | mit | 6,343 | 0 | 9 | 1,137 | 355 | 231 | 124 | 104 | 1 |
{-# LANGUAGE PatternSynonyms, ForeignFunctionInterface, JavaScriptFFI #-}
module GHCJS.DOM.JSFFI.Generated.SVGUseElement
(js_getX, getX, js_getY, getY, js_getWidth, getWidth, js_getHeight,
getHeight, SVGUseElement, castToSVGUseElement, gTypeSVGUseElement)
where
import Prelude ((.), (==), (>>=), re... | manyoo/ghcjs-dom | ghcjs-dom-jsffi/src/GHCJS/DOM/JSFFI/Generated/SVGUseElement.hs | mit | 2,525 | 24 | 10 | 320 | 638 | 377 | 261 | 36 | 1 |
module Game
(Game(Game)
,bestAnswer
,bestAnswers
)
where
import Data.Maybe
import Data.List
import Expression
data Game = Game [Int] Int
without :: (Eq a) => (a, a) -> [a] -> [a]
without (i1, i2) xs = (delete i1) . (delete i2) $ xs
expressions :: (Expression -> Expression -> Expression) -> [Expressio... | wharris/countdown | Game.hs | mit | 1,239 | 0 | 10 | 312 | 553 | 296 | 257 | 39 | 1 |
module Flags
( Flags(..)
, initFlags
, getFlags
, getTimeLeft
, getTimeSpent
, getTimeSpentS
)
where
{-
Paradox/Equinox -- Copyright (c) 2003-2007, Koen Claessen, Niklas Sorensson
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation ... | msakai/folkung | Haskell/Flags.hs | mit | 9,911 | 1 | 18 | 3,175 | 2,890 | 1,576 | 1,314 | 222 | 5 |
{-# LANGUAGE OverloadedStrings, GADTs #-}
-- | Data structures pertaining to gateway dispatch 'Event's
module Network.Discord.Types.Events where
import Control.Monad (mzero)
import Data.Aeson
import Network.Discord.Types.Channel
import Network.Discord.Types.Gateway
import Network.Discord.Types.Guild (Member... | jano017/Discord.hs | src/Network/Discord/Types/Events.hs | mit | 4,518 | 0 | 15 | 1,681 | 757 | 394 | 363 | 81 | 29 |
module Paths_advent_coding (
version,
getBinDir, getLibDir, getDataDir, getLibexecDir,
getDataFileName, getSysconfDir
) where
import qualified Control.Exception as Exception
import Data.Version (Version(..))
import System.Environment (getEnv)
import Prelude
catchIO :: IO a -> (Exception.IOException -> I... | cirquit/Personal-Repository | Haskell/Playground/AdventOfCode/advent-coding/.stack-work/dist/x86_64-linux/Cabal-1.22.4.0/build/autogen/Paths_advent_coding.hs | mit | 1,978 | 0 | 10 | 177 | 362 | 206 | 156 | 28 | 1 |
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE StandaloneDeriving #-}
{-# OPTIONS_GHC -fno-war... | schell/caltrops | src/Caltrops/Common.hs | mit | 1,270 | 0 | 8 | 254 | 227 | 135 | 92 | 35 | 0 |
{-|
Module : DavisPutnam
Description : Implementation of DP and DPLL algorithms
Copyright : (c) Alex Nelson, 2015
License : MIT
Maintainer : pqnelson@gmail.com
Stability : experimental
Portability : POSIX
A slightly optimized method for checking satisfiability.
-}
module DavisPutnam
(
dp... | pqnelson/surak | src/DavisPutnam.hs | mit | 11,365 | 0 | 19 | 2,955 | 2,796 | 1,522 | 1,274 | 165 | 4 |
{-# LANGUAGE DeriveFunctor #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE UndecidableInstances #-}
-- | An implementation of @RWST@ built on top of mutable references,
-- providing a pr... | fpco/monad-unlift | monad-unlift-ref/Control/Monad/Trans/RWS/Ref.hs | mit | 7,486 | 0 | 13 | 2,459 | 2,574 | 1,354 | 1,220 | 172 | 1 |
module Verba.CLI (runCLI) where
import Data.List (intersperse, intercalate)
import System.IO (hFlush, stdout)
import Verba.Solver (solve)
import Verba.Dictionary (Dictionary)
import Verba.Puzzle (Puzzle)
import Verba.Formatting
import Verba.Utils
import qualified Verba.Dictionary as Dictionary
import qualified Verba.P... | Jefffrey/Verba | src/Verba/CLI.hs | mit | 2,551 | 0 | 15 | 681 | 696 | 360 | 336 | 55 | 3 |
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE LambdaCase #-}
-- | Transformations on distilled expressions. Before transforming expressions,
-- they should first be renumbered, type checked, and had their source
-- annotations deleted.
module Distill.Transform
( lambdaLift
, aNormalizeExpr
) where
import... | DNoved1/distill | src/Distill/Transform.hs | mit | 6,438 | 0 | 18 | 2,043 | 2,118 | 1,052 | 1,066 | -1 | -1 |
import Control.Arrow
import Data.List
main :: IO ()
main = do
_ <- getLine
interact $ lines >>> map (read >>> solve >>> showRes) >>> intercalate "\n"
solve :: Integer -> Bool
solve n = elem n $ takeWhile (<=n) fibs
fibs :: [Integer]
fibs = 0 : 1 : zipWith (+) fibs (tail fibs)
showRes :: Bool -> String
showR... | Dobiasd/HackerRank-solutions | Algorithms/Warmup/Is_Fibo/Main.hs | mit | 366 | 0 | 12 | 79 | 159 | 82 | 77 | 13 | 1 |
module Domain.Roles where
import Database.Persist
import DBTypes
import Models
import Operation
import Data.Text
import Control.Monad.Trans
dbCreateRole :: MonadIO m => Role -> OperationT (TransactionT m) (Maybe RoleId)
dbCreateRole = lift . insertUnique
dbGetRole :: MonadIO m => Role... | wz1000/haskell-webapps | ServantPersistent/src/Domain/Roles.hs | mit | 641 | 0 | 12 | 125 | 212 | 109 | 103 | 15 | 1 |
{-# LANGUAGE QuasiQuotes #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE CPP #-}
module Yesod.Form.Fields
( -- * i18n
FormMessage (..)
, defaultFormMessage
-- * Fields
, textField
... | wujf/yesod | yesod-form/Yesod/Form/Fields.hs | mit | 26,432 | 0 | 22 | 7,368 | 7,078 | 3,790 | 3,288 | -1 | -1 |
{-# LANGUAGE PatternSynonyms, ForeignFunctionInterface, JavaScriptFFI #-}
module GHCJS.DOM.JSFFI.Generated.ANGLEInstancedArrays
(js_drawArraysInstancedANGLE, drawArraysInstancedANGLE,
js_drawElementsInstancedANGLE, drawElementsInstancedANGLE,
js_vertexAttribDivisorANGLE, vertexAttribDivisorANGLE,... | manyoo/ghcjs-dom | ghcjs-dom-jsffi/src/GHCJS/DOM/JSFFI/Generated/ANGLEInstancedArrays.hs | mit | 3,266 | 40 | 9 | 568 | 655 | 382 | 273 | 50 | 1 |
type Peg = String
type Move = (Peg, Peg)
hanoi :: Integer -> Peg -> Peg -> Peg -> [Move]
hanoi 1 orig dest temp = [(orig, dest)]
hanoi n orig dest temp = hanoi (n-1) orig temp dest ++ [(orig, dest)] ++ hanoi (n-1) temp dest orig
| julitopower/HaskellLearning | hanoi.hs | mit | 230 | 0 | 9 | 49 | 129 | 71 | 58 | 5 | 1 |
module Philed.Data.Rect (Rect,
left, right, top, bottom,
topLeft, topRight, bottomLeft, bottomRight,
width, height, mkRect) where
import Control.Applicative
import Data.Binary
import Philed.Data.Vector
import Philed.Data.NNeg
import Test.QuickC... | Chattered/PhilEdCommon | Philed/Data/Rect.hs | mit | 1,374 | 0 | 9 | 359 | 606 | 313 | 293 | 34 | 1 |
import Data.Char
import qualified Data.List as L
superDigit :: Int -> Int
superDigit n =
if n `div` 10 == 0 then
n
else superDigit $ sum $ map (\x -> ord x - ord '0') $ show n
main = do
line <- getLine
let [num,times] = (words line)
n = (read times) :... | m00nlight/hackerrank | functional/recursion/Super-Digits/main.hs | gpl-2.0 | 429 | 0 | 15 | 167 | 184 | 96 | 88 | 14 | 2 |
module DarkPlaces.ProtocolConstants where
u_morebits_bit :: Int
u_morebits_bit = 0
u_origin1_bit :: Int
u_origin1_bit = 1
u_origin2_bit :: Int
u_origin2_bit = 2
u_origin3_bit :: Int
u_origin3_bit = 3
u_angle2_bit :: Int
u_angle2_bit = 4
u_step_bit :: Int
u_step_bit = 5
u_frame_bit :: Int
u_frame_bit = 6
u_signal_bit ... | bacher09/darkplaces-demo | src/DarkPlaces/ProtocolConstants.hs | gpl-2.0 | 7,121 | 0 | 4 | 1,007 | 1,676 | 1,006 | 670 | 335 | 1 |
module OpenBookModule where
import System.Random
import System.IO.Unsafe
import Board
import MoveModule
import FileModule
type OpeningBook = [(Int, Int, String, String)]
--Every move represented by a 4-tuple (ID, Parent, White, Black).
--Black king side castling: e8g8
--Black queen side castling: e8c8
--White king s... | adityashah30/haskellchess | chessEngine/OpenBookModule.hs | gpl-2.0 | 6,149 | 0 | 17 | 891 | 1,716 | 950 | 766 | 73 | 2 |
module Errors ( LispError(..)
, ThrowsError
, throwError
, trapError
, extractValue
) where
import Control.Monad.Except (throwError, catchError, MonadError)
import Text.ParserCombinators.Parsec
import Types
-- for an example of how to use a custom... | quakehead/haskell-scheme | Errors.hs | gpl-3.0 | 2,169 | 0 | 8 | 600 | 404 | 218 | 186 | 31 | 1 |
{-# LANGUAGE DeriveGeneric, DeriveAnyClass #-}
module WildFire.WildFireModelStatic where
import System.Random
import qualified PureAgentsSeq as PA
type WFCell = (Int, Int)
data WFState = Living | Burning | Dead deriving (Eq, Show)
data WFMsg = Ignite
data WFAgentState = WFAgentState {
wfState :: WFState,
b... | thalerjonathan/phd | public/ArtIterating/code/haskell/PureAgentsSeq/src/WildFire/WildFireModelStatic.hs | gpl-3.0 | 3,752 | 0 | 12 | 963 | 1,401 | 784 | 617 | 84 | 2 |
module Tests.Conversion where
import QHaskell.MyPrelude
import qualified Language.Haskell.TH.Syntax as TH
import qualified QHaskell.Expression.ADTUntypedNamed as AUN
import qualified QHaskell.Expression.ADTUntypedDebruijn as AUD
import qualified QHaskell.Expression.GADTTyped as GTD
import ... | shayan-najd/QHaskell | Tests/Conversion.hs | gpl-3.0 | 4,817 | 0 | 26 | 1,453 | 1,727 | 930 | 797 | -1 | -1 |
{-# LANGUAGE OverloadedStrings #-}
module Main where
import Affection as A
import qualified SDL
import Linear as L
import NanoVG hiding (V2(..), V4(..))
import Control.Concurrent.MVar
import Control.Monad (when, void)
import Data.String (fromString)
-- internal imports
import Types
import StateMachine ()
import... | nek0/haskelloids | src/Main.hs | gpl-3.0 | 2,437 | 0 | 21 | 635 | 878 | 441 | 437 | 74 | 3 |
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
module ArgsParser (parseArgs) where
import BasicPrelude (error)
import Common hiding (error)
import Options.Applicative
parseArgs :: IO ProgArgs
parseArgs = execParser $ info (helper <*> argsParser) idm
argsParser :: Parser ProgArgs
argsParser = ... | d12frosted/kitsunebook-v1 | src/ArgsParser.hs | gpl-3.0 | 5,759 | 0 | 15 | 1,337 | 1,522 | 791 | 731 | 164 | 1 |
module Language.Octopus.Parser.Tokens where
import qualified Text.Parsec as P
import Language.Octopus.Data
import Language.Octopus.Data.Shortcut
import Language.Octopus.Parser.Import
import Language.Octopus.Parser.Whitespace
import Language.Octopus.Parser.Policy
------ Atoms ------
atom :: Parser Val
atom = P.choic... | Zankoku-Okuno/octopus | Language/Octopus/Parser/Tokens.hs | gpl-3.0 | 2,884 | 0 | 14 | 685 | 962 | 493 | 469 | 74 | 1 |
-- | This module is responsible for interacting with the backing database. The
-- rest of the program communicates with it over a pair of TChans. The first
-- TChan is used by the `restore` function, which reads the database and sends
-- all the schedule entry over the chan. The reciever must then construct a
-- schedu... | joelwilliamson/reddit-digest | Persist.hs | gpl-3.0 | 4,430 | 0 | 17 | 955 | 990 | 516 | 474 | 71 | 2 |
{-# 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/Projects/EnableXpnHost.hs | mpl-2.0 | 3,975 | 0 | 14 | 837 | 398 | 242 | 156 | 63 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | rueshyna/gogol | gogol-compute/gen/Network/Google/Resource/Compute/TargetPools/AddInstance.hs | mpl-2.0 | 4,353 | 0 | 18 | 1,046 | 547 | 324 | 223 | 89 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-logging/gen/Network/Google/Resource/Logging/Exclusions/Delete.hs | mpl-2.0 | 4,692 | 0 | 15 | 1,043 | 702 | 412 | 290 | 100 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-cloudsearch/gen/Network/Google/Resource/CloudSearch/Debug/Datasources/Items/SearchByViewURL.hs | mpl-2.0 | 6,268 | 0 | 18 | 1,353 | 789 | 461 | 328 | 124 | 1 |
{-# LANGUAGE ScopedTypeVariables #-}
{- The picture DSL.
This section introduces the domain-specific language for
constructing visualizations. It is divided into three
sections: colour schemes, data derivation, and then
picture construction.
-}
module PictureDSL where
import Data.List (genericLength)
i... | kvelicka/Fizz | PictureDSL.hs | lgpl-2.1 | 4,581 | 0 | 15 | 1,294 | 1,158 | 606 | 552 | 78 | 3 |
module Example where
import Induction.Structural
-- | A small test envirenment of Ordinals, Naturals, Integers,
-- Lists, Trees and Expressions.
testEnv :: TyEnv String String
testEnv t = case t of
"Ord" -> Just [("zero",[])
,("succ",[Rec "Ord"])
,("lim",[Exp "Nat -> Ord" ["N... | danr/structural-induction | example/Example.hs | lgpl-3.0 | 2,351 | 0 | 13 | 750 | 865 | 492 | 373 | 47 | 5 |
{-# LANGUAGE DeriveGeneric #-}
{- © Utrecht University (Department of Information and Computing Sciences) -}
module Domain.Scenarios.Expression where
import Control.Arrow
import Data.Binary
import qualified Data.Map as M
import Data.Maybe
import GHC.Generics
import Domain.Scenarios.Condition
import Domain.Scenarios.... | UURAGE/ScenarioReasoner | src/Domain/Scenarios/Expression.hs | apache-2.0 | 1,965 | 0 | 20 | 395 | 533 | 280 | 253 | 36 | 6 |
module Main (
main
) where
import IFind.Config
import IFind.Opts
import IFind.UI
import System.Console.CmdArgs
import qualified Data.Text as T
import qualified Data.Text.IO as TIO
iFindOpts :: IFindOpts
iFindOpts =
IFindOpts { inDir = "." &= help "directory to search recursively"
, outFi... | andreyk0/ifind | Main.hs | apache-2.0 | 1,347 | 0 | 12 | 406 | 255 | 134 | 121 | 30 | 2 |
module Database.VCache.Open
( openVCache
) where
import Control.Monad
import Control.Exception
import System.FileLock (FileLock)
import qualified System.FileLock as FileLock
import qualified System.EasyFile as EasyFile
import qualified System.IO.Error as IOE
import Foreign.Storable
import Foreign.Marshal.Alloc... | bitemyapp/haskell-vcache | hsrc_lib/Database/VCache/Open.hs | bsd-2-clause | 9,125 | 0 | 22 | 2,351 | 1,929 | 1,020 | 909 | 165 | 3 |
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
-- | Announce things happening in scrobbling process
module Control.Scrobbler.Announce
( Announce(..)
, pprint
, announce
) where
import Control.Monad.Trans (MonadIO, liftIO)
import Control.Wire
import Data.ByteStr... | supki/scrobblers | src/Control/Scrobbler/Announce.hs | bsd-2-clause | 1,828 | 0 | 12 | 394 | 536 | 288 | 248 | 35 | 1 |
{-# LANGUAGE NamedFieldPuns, RecordWildCards, PatternGuards #-}
module Shades(shades) where
import Graphics.SpriteKit
import Actions
import Constants
import Convenience
import GameState
import Random
import Data.List
shades :: ShadesScene
shades
= spawnNewblock $ (sceneWithSize (Size width height))
{ scen... | gckeller/shades | Shades.hsproj/Shades.hs | bsd-2-clause | 12,209 | 0 | 17 | 4,143 | 3,021 | 1,619 | 1,402 | 214 | 4 |
{-|
Module : Module.Run
Description : Tests that execute Binary.Neko bytecode
Copyright : (c) Petr Penzin, 2015
License : BSD2
Module.Runtainer : penzin.dev@gmail.com
Stability : stable
Portability : cross-platform
Execute Binary.Neko bytecode to check compatibility
-}
module Module.Run where
import T... | ppenzin/neko-lib-hs | src/test/Module/Run.hs | bsd-2-clause | 2,372 | 0 | 15 | 544 | 495 | 281 | 214 | 38 | 1 |
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TupleSections #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE UndecidableInstances #-}
{-
- Early parser for TAGs. Third preliminary version :-).
-}
module NLP.LTAG.Early3 where
import Control.Applicative ((<$>))
import Control.Monad (guard... | kawu/ltag | src/NLP/LTAG/Early3.hs | bsd-2-clause | 17,262 | 0 | 15 | 4,861 | 4,206 | 2,195 | 2,011 | -1 | -1 |
{-# LANGUAGE OverloadedStrings #-}
-- | The @babel@ package is used to write documents in languages
-- other than US English.
--
-- CTAN page for babel: <http://ctan.org/pkg/babel>.
module Text.LaTeX.Packages.Babel (
-- * Babel package
babel
-- * Babel languages
, Language (..)
, uselanguage
, LangConf... | dmcclean/HaTeX | Text/LaTeX/Packages/Babel.hs | bsd-3-clause | 3,201 | 0 | 10 | 685 | 523 | 318 | 205 | 55 | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.