code
stringlengths
2
1.05M
repo_name
stringlengths
5
101
path
stringlengths
4
991
language
stringclasses
3 values
license
stringclasses
5 values
size
int64
2
1.05M
{-# LANGUAGE QuasiQuotes, TemplateHaskell, TypeFamilies #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE MultiParamTypeClasses #-} module MySite ( MySite (..) , MySiteRoute (..) , resourcesMySite , Handler , Widget , maybeAuth , requireAuth , module Yesod.Helpers.Static , module Y...
Tarrasch/Nollform
MySite.hs
Haskell
bsd-2-clause
6,094
{-# OPTIONS_GHC -fno-warn-redundant-constraints #-} module Language.Drasil.CodeExpr (new, newWithNamedArgs, message, msgWithNamedArgs) where import Language.Drasil import Language.Drasil.Chunk.Code (CodeIdea) import Control.Lens ((^.)) new :: (Callable f, HasUID f, CodeIdea f) => f -> [Expr] -> Expr new c ps = Ne...
JacquesCarette/literate-scientific-software
code/drasil-code/Language/Drasil/CodeExpr.hs
Haskell
bsd-2-clause
1,307
module Graphics.XHB.Connection.Types where import Graphics.XHB.Shared import Graphics.XHB.Connection.Open import Control.Concurrent.STM import Control.Concurrent import System.IO import Data.Word import Data.Map(Map) import Graphics.XHB.Gen.Xproto.Types data Connection = Connection {conn_error_queue :: TChan ...
aslatter/xhb
Graphics/XHB/Connection/Types.hs
Haskell
bsd-3-clause
1,021
-- | HTML elements {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE DeriveFunctor #-} {-# LANGUAGE DeriveFoldable #-} {-# LANGUAGE DeriveTraversable #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE RankNTypes #-} module VirtualHom.Internal.Element where import Control.Appli...
j-mueller/virtual-hom
src/VirtualHom/Internal/Element.hs
Haskell
bsd-3-clause
5,477
{-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE FunctionalDependencies #-} {-# LANGUAGE MultiParamTypeClasses #-} {-# LANGUAGE NoImplicitPrelude #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE TemplateHaskell #-} ...
jeremyjh/free-agent
examples/famon/FreeAgent/Plugins/Nagios.hs
Haskell
bsd-3-clause
4,621
module BitD.Util.State ( modify' ) where import qualified Control.Monad.State as State modify' :: State.MonadState s m => (s -> s) -> m () modify' f = do v <- State.get State.put $! f v
benma/bitd
src/BitD/Util/State.hs
Haskell
bsd-3-clause
226
module Common.Utils ( if' , (?) , isqrt , modifyArray , initArray , submasks , combmasks ) where import Control.Monad (forM_) import Data.Array.MArray (MArray, newArray, readArray, writeArray) import Data.Bits (shiftL, shiftR, complement, (.&.), (.|.)) import Data.Ix (Ix) if' :: Bool -> t -> t -> t {-# INLINE if' #...
foreverbell/project-euler-solutions
lib/Common/Utils.hs
Haskell
bsd-3-clause
1,307
{-# LANGUAGE PolyKinds #-} module Data.Vinyl.Class.Implication where import Data.Constraint import Data.List.TypeLevel.Cmp (eqTProxy) import Data.List.TypeLevel.Constraint (ListAll) import Data.Proxy (Proxy (Proxy)) import Data.Tagged.Functo...
andrewthad/vinyl-vectors
src/Data/Vinyl/Class/Implication.hs
Haskell
bsd-3-clause
2,741
{-# LANGUAGE OverloadedStrings #-} module Web.Spock.FrameworkSpecHelper where import Test.Hspec import Test.Hspec.Wai import Data.Monoid import Data.Word import qualified Data.ByteString.Lazy.Char8 as BSLC import qualified Data.Text as T import qualified Data.Text.Encoding as T import qualified Network.Wai as Wai si...
nmk/Spock
test/Web/Spock/FrameworkSpecHelper.hs
Haskell
bsd-3-clause
5,541
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE DeriveDataTypeable #-} module Data.IHO.S57.DSID where import Control.Lens import Data.Text (Text) import Data.Data (Data) import Data.Typeable (Typeable) import Data.Tree import Data.IHO.S57.Types data DataStructure = CartographicS...
alios/iho-s57
library/Data/IHO/S57/DSID.hs
Haskell
bsd-3-clause
6,252
{-# LANGUAGE DefaultSignatures #-} {-# LANGUAGE ExistentialQuantification #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE ScopedTypeVariables #-} {-# LANGUAGE GeneralizedNewtypeDeriving #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE FlexibleInstances #-} {-# OPTIONS -fno-warn-orphans #-} module Database.Sqroll.I...
pacak/sqroll
src/Database/Sqroll/Internal.hs
Haskell
bsd-3-clause
15,751
-- | Calculate 2D distance fields via the Grevera improved 8SED (Danielsson) -- using small kernel sweeps across the data stored as a 2D array. module Grevera8SEDFast1 ( grevera8SED ) where import Prelude as P import Data.Vector.Unboxed as U dX, dY, dXY :: Double dX = 1 dY ...
tau-tao/DistField-2D
src/Grevera8SEDFast1.hs
Haskell
bsd-3-clause
1,633
module System.Keychain (getLogin, setLogin, askAndSetLogin) where import Control.Monad import Control.Monad.IO.Class import System.Console.Haskeline import System.Exit (ExitCode (..)) import System.Process (readProcess, ...
madjar/fhue
src/System/Keychain.hs
Haskell
bsd-3-clause
1,406
{-# LANGUAGE CPP, OverloadedStrings #-} -- | DNS Resolver and generic (lower-level) lookup functions. module CacheDNS.DNS.Resolver ( -- * Documentation -- ** Configuration for resolver FileOrNumericHost(..), ResolvConf(..), defaultResolvConf -- ** Intermediate data type for resolver , ResolvSeed, makeResol...
DavidAlphaFox/CacheDNS
src/CacheDNS/DNS/Resolver.hs
Haskell
bsd-3-clause
17,592
module AlphabetSoup where import Rumpus start :: Start start = do let n = 0.3 forM_ (take 100 $ cycle ['!'..'~']) $ \letter -> do pos <- V3 <$> randomRange (-n,n) <*> randomRange (-n,n) <*> randomRange (-n,n) let (V3 x y z) = pos spawnC...
lukexi/rumpus
pristine/Room/AlphabetSoup.hs
Haskell
bsd-3-clause
820
{-# LANGUAGE CPP #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE ScopedTypeVariables #-} ------------------------------------------------------------------------------- -- -- | Dynamic flags -- -- Most flags are dynamic flags, which means they can change from compilation -- to compilation using @OPTIONS_GHC@ pragm...
mettekou/ghc
compiler/main/DynFlags.hs
Haskell
bsd-3-clause
220,181
{-# LANGUAGE CPP, FlexibleContexts, ScopedTypeVariables #-} {-# LANGUAGE ConstraintKinds #-} -- for LFScan {-# OPTIONS_GHC -Wall #-} -- {-# OPTIONS_GHC -fno-warn-unused-imports #-} -- TEMP -- {-# OPTIONS_GHC -fno-warn-unused-binds #-} -- TEMP ---------------------------------------------------------------------- --...
conal/lambda-ccc
src/LambdaCCC/RadixSort.hs
Haskell
bsd-3-clause
3,778
{-# LANGUAGE NPlusKPatterns #-} {-# LANGUAGE ScopedTypeVariables #-} module Chap01 where import Prelude hiding (last, foldr, foldl, take, drop, zip, concat, inits, reverse) -- | Ex 1.1 -- solution 1 k1 x = if k1 x == 0 then 1 else 0 -- solution 2 k2 x = not (k2 x) -- solution 3 k3 x = k3 x + 1 -- solution 4 k4 x =...
cutsea110/aop
src/Chap01.hs
Haskell
bsd-3-clause
22,782
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE UndecidableInstances #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE StandaloneDeriving #-} {-# LANGUAGE ConstraintKinds #-} {-# LANGUAGE MultiParamTypeClasses #-} {-# LANGUAGE TupleSections #-} {-# LANGU...
mrakgr/futhark
src/Futhark/Representation/Kernels/Kernel.hs
Haskell
bsd-3-clause
47,575
module Language.Iso.Target.Scala where import Language.Iso.App import Language.Iso.Fls import Language.Iso.Ite import Language.Iso.Lam import Language.Iso.Tru import Language.Iso.Var newtype Scala = Scala { runScala :: String } instance Show Scala where show (Scala ps) = ps instance Var Scala ...
joneshf/iso
src/Language/Iso/Target/Scala.hs
Haskell
bsd-3-clause
798
{-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE NoImplicitPrelude #-} {-# LANGUAGE TypeFamilies #-} module HMenu.Search ( createIndex, search, Index, tokenCount, Indexable(..) ) where import ClassyPrelude hiding (Index) import Control.DeepSeq import Control...
Adirelle/hmenu
src/HMenu/Search.hs
Haskell
bsd-3-clause
3,635
{-# LANGUAGE LambdaCase #-} {-# LANGUAGE NoImplicitPrelude #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} module VYPe15.Internal.AssemblyGenerator ( generateAssembly ) where import Prelude (Integral, Num, error, fromIntegral, negate) import Control.Applicative (pure) import Control...
Tr1p0d/VYPe15
src/VYPe15/Internal/AssemblyGenerator.hs
Haskell
bsd-3-clause
12,875
{-# LANGUAGE AllowAmbiguousTypes #-} -- | Different key/value serialization helpers abstracted over -- 'MonadDB'. module Pos.DB.Functions ( -- * Encoded putting/getting dbGetBi , dbPutBi -- * Decoding/encoding primitives and iteration related , encodeWithKeyPrefix ,...
input-output-hk/pos-haskell-prototype
db/src/Pos/DB/Functions.hs
Haskell
mit
2,818
{-# LANGUAGE LambdaCase #-} module Statistics.Graph ( graphF , writeGraph ) where import Universum hiding (unlines) import Control.Foldl (Fold (..)) import Data.Graph.Inductive.Graph (Graph (mkGraph)) import Data.Graph.Inductive.PatriciaTree (Gr) import Da...
input-output-hk/pos-haskell-prototype
tools/post-mortem/src/Statistics/Graph.hs
Haskell
mit
2,946
module Language.Entry ( main, ) where import Language.Repl main :: IO () main = repl
airtial/hellolisp.scala
src/Language/Entry.hs
Haskell
mit
89
{-# LANGUAGE RankNTypes #-} {-| Implementation of a reader for the job queue. -} {- Copyright (C) 2013 Google Inc. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code mu...
mbakke/ganeti
src/Ganeti/JQScheduler.hs
Haskell
bsd-2-clause
24,689
module Cauterize.Dynamic.Meta.Types ( MetaType(..) , MetaHeader(..) ) where import Cauterize.Dynamic.Types import Data.Word data MetaHeader = MetaHeader { metaLength :: Integer , metaTag :: [Word8] } deriving (Show, Eq, Ord) data MetaType = MetaType { unMetaType :: CautType } ...
cauterize-tools/cauterize
src/Cauterize/Dynamic/Meta/Types.hs
Haskell
bsd-3-clause
345
-- (c) The University of Glasgow 2006 -- (c) The GRASP/AQUA Project, Glasgow University, 1998 -- -- Type - public interface {-# LANGUAGE CPP #-} {-# OPTIONS_GHC -fno-warn-orphans #-} -- | Main functions for manipulating types and type-related things module Type ( -- Note some of this is just re-exports from T...
TomMD/ghc
compiler/types/Type.hs
Haskell
bsd-3-clause
66,827
----------------------------------------------------------------------------- -- | -- Module : Data.Foldable -- Copyright : Ross Paterson 2005 -- License : BSD-style (see the LICENSE file in the distribution) -- -- Maintainer : ross@soi.city.ac.uk -- Stability : experimental -- Portability : portabl...
alekar/hugs
packages/base/Data/Foldable.hs
Haskell
bsd-3-clause
9,271
{-# LANGUAGE Haskell2010 #-} {-# LINE 1 "Control/Concurrent/STM/TMVar.hs" #-} {-# LANGUAGE CPP, DeriveDataTypeable, MagicHash, UnboxedTuples #-} {-# LANGUAGE Trustworthy #-} ----------------------------------------------------------------------------- -- | -- Module ...
phischu/fragnix
tests/packages/scotty/Control.Concurrent.STM.TMVar.hs
Haskell
bsd-3-clause
4,914
{-# LANGUAGE CPP #-} {-# LANGUAGE ExistentialQuantification #-} {-# LANGUAGE PatternGuards #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE RankNTypes #-} -- | Some helpers for parsing data out of a raw WAI 'Request'. module Network.Wai.Parse ( parseHttpAccept , parseRequestBody , RequestBodyType (..) , ...
frontrowed/wai
wai-extra/Network/Wai/Parse.hs
Haskell
mit
14,689
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE helpset PUBLIC "-//Sun Microsystems Inc.//DTD JavaHelp HelpSet Version 2.0//EN" "http://java.sun.com/products/javahelp/helpset_2_0.dtd"> <helpset version="2.0" xml:lang="sr-CS"> <title>Passive Scan Rules - Alpha | ZAP Extension</title> <maps> <homeID>top</homeI...
0xkasun/security-tools
src/org/zaproxy/zap/extension/pscanrulesAlpha/resources/help_sr_CS/helpset_sr_CS.hs
Haskell
apache-2.0
988
{- Copyright 2015 Google Inc. 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.0 Unless required by applicable law or a...
Ye-Yong-Chi/codeworld
codeworld-base/src/System/IO.hs
Haskell
apache-2.0
733
{-# LANGUAGE CPP #-} {-# LANGUAGE NoImplicitPrelude #-} #ifdef FAY import Prelude #else this is invalid code #endif #ifdef FAY main :: Fay () #endif #ifndef FAY more invalid code #if FAY this should not be used #endif #else #if FAY main = print True #else invalid and nested #endif #endif
fpco/fay
tests/CPP.hs
Haskell
bsd-3-clause
316
import Control.Concurrent.STM main = do x <- atomically $ do t <- newTVar 1 writeTVar t 2 ((readTVar t >> retry) `orElse` return ()) `orElse` return () readTVar t print x
gridaphobe/packages-stm
tests/stm064.hs
Haskell
bsd-3-clause
211
{-# LANGUAGE Safe #-} {-# LANGUAGE NoImplicitPrelude #-} ----------------------------------------------------------------------------- -- | -- Module : Foreign.C -- Copyright : (c) The FFI task force 2001 -- License : BSD-style (see the file libraries/base/LICENSE) -- -- Maintainer : ffi@haskell.org --...
alexander-at-github/eta
libraries/base/Foreign/C.hs
Haskell
bsd-3-clause
716
module Foo where import Prelude hiding (putStr, putStrLn) import qualified System.IO (putStr, putStrLn) import Data.Maybe import qualified ValidHoleFits ps :: String -> IO () ps = putStrLn a :: Int -> IO Int a _ = return 1 b :: Int -> IO Int b _ = return 2 c :: Int -> IO Int c _ = do { x <- a 0 ; y <- _ x ...
sdiehl/ghc
testsuite/tests/typecheck/should_compile/valid_hole_fits.hs
Haskell
bsd-3-clause
612
{-# LANGUAGE Trustworthy #-} {-# LANGUAGE CPP , NoImplicitPrelude , MagicHash , UnboxedTuples #-} {-# OPTIONS_HADDOCK hide #-} ----------------------------------------------------------------------------- -- | -- Module : GHC.TopHandler -- Copyright : (c) The University of G...
beni55/haste-compiler
libraries/ghc-7.10/base/GHC/TopHandler.hs
Haskell
bsd-3-clause
7,332
{-# LANGUAGE CPP #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE BangPatterns #-} module Main where import Control.Exception (throwIO, throw) import Control.Monad import qualified Data.ByteString as S --import Data.ByteString.Char8 (ByteString) import qualified Data.ByteString.Char8 as B (unpack) import qualified...
creichert/wai
warp/bench/Parser.hs
Haskell
mit
7,847
module Tach.Impulse.Types.TimeValueSeriesSpec (main, spec) where import Tach.Impulse.Types.TimeValueSeries import Tach.Impulse.Types.TimeValue import Control.Applicative import qualified Data.Sequence as S import Test.Hspec import Test.QuickCheck main :: IO () main = hspec spec spec :: Spec spec = do describe "TVSim...
smurphy8/tach
core-types/tach-impulse-series-types/test/Tach/Impulse/Types/TimeValueSeriesSpec.hs
Haskell
mit
848
{-# LANGUAGE OverloadedStrings #-} module UserInputParserSpec (spec) where import Test.Hspec import Test.QuickCheck import Control.Exception (evaluate) import Data.ByteString.Char8 hiding (filter, length) import Test.Hspec.Attoparsec import Pipes.ByteString hiding (filter, length, lines) import Prelude hiding (readFi...
tort/mud-drifter
test/UserInputParserSpec.hs
Haskell
mit
2,953
{-# LANGUAGE JavaScriptFFI #-} -- | FIXME: doc module GHCJS.Electron.BrowserWindow where
taktoa/ghcjs-electron
src/GHCJS/Electron/BrowserWindow.hs
Haskell
mit
90
{-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE MultiParamTypeClasses #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE RankNTypes #-} {-# LANGUAGE TemplateHaskell #-} module ForwardVector where import Numeric.AD.Internal.Forward.Double import Numeric.AD.Internal.On import Numeric.AD.Mode import Numeric.AD.Internal.Iden...
fhaust/aer-utils
src/ForwardVector.hs
Haskell
mit
3,403
module Main where import Control.Concurrent.MVar (newMVar) import Server.Web (runServer) import Server.Types (newServerState) import Server.ProgramOptions (parseOptions) main :: IO () main = do programOptions <- parseOptions serverState <- newMVar newServerState runServer serverState...
best-coloc-ever/twitch-cast
streamer/app/Main.hs
Haskell
mit
336
----------------------------------------------------------------------------- -- | -- Module : Writer.Formats.Acacia -- License : MIT (see the LICENSE file) -- Maintainer : Felix Klein (klein@react.uni-saarland.de) -- -- Transforms a specification to the Acacia+ format. -- ---------------------------------...
reactive-systems/syfco
src/lib/Writer/Formats/Acacia.hs
Haskell
mit
3,221
module Interpreter.DataTypes ( Frame , Environment(..) , Expression(..) , addBinding , lookupValue , extendEnvironment , pairToList ) where import qualified Data.Map as Map -- A frame contains mappings from variable names to Lisp values. type Frame = Map.Map String Expression -- An Environment is a frame coupled with...
IvanIvanov/haskell-lisp-interpreter
src/DataTypes.hs
Haskell
mit
3,302
-- TODO: Write module docs. module Main where import Lib main :: IO () main = do someFunc
xnil/ply
app/Main.hs
Haskell
mit
96
{-# LANGUAGE OverloadedStrings #-} module Graph.JSON.Cypher.Read.Rows where import Data.Aeson import Data.Aeson.Types (Parser) import qualified Data.ByteString.Lazy.Char8 as BL import Data.Map (Map) import qualified Data.Map as Map import Data.Maybe (fromJust, mapMaybe) import Data.Set (Set) import qualified Dat...
geophf/1HaskellADay
exercises/HAD/Graph/JSON/Cypher/Read/Rows.hs
Haskell
mit
3,740
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE StrictData #-} {-# LANGUAGE TupleSections #-} -- | http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-launchtemplate-ipv6add.html module Stratosphere.ResourceProperties.EC2LaunchTemplateIpv6Add where import...
frontrowed/stratosphere
library-gen/Stratosphere/ResourceProperties/EC2LaunchTemplateIpv6Add.hs
Haskell
mit
1,429
{-# LANGUAGE Trustworthy #-} {-# LANGUAGE NoImplicitPrelude, BangPatterns, MagicHash, UnboxedTuples #-} module Data.Word.Word24.Internal ( Word24(..) , byteSwap24 ) where import Data.X24Bit.Internal import GHC.Word import Data.Bits import Data.Maybe import GHC.Base import GHC.Enum import GHC.Num import ...
nickspinale/24-bit
src/Data/Word/Word24/Internal.hs
Haskell
mit
6,764
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE StrictData #-} {-# LANGUAGE TupleSections #-} -- | http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-aliastarget.html module Stratosphere.ResourceProperties.Route53RecordSetAliasTarget where import Str...
frontrowed/stratosphere
library-gen/Stratosphere/ResourceProperties/Route53RecordSetAliasTarget.hs
Haskell
mit
2,676
{-# LANGUAGE MultiParamTypeClasses, TypeSynonymInstances, FlexibleInstances #-} module FRP.Yampa.SDL.Graphic where import Control.Monad (void) import Graphics.UI.SDL as SDL import Graphics.UI.SDL.TTF type Screen = SDL.Surface newtype Graphic = Graphic { paintGraphic :: Screen -> IO () } type GraphicOpt = Rect -> Gr...
scan/yampa-sdl
src/FRP/Yampa/SDL/Graphic.hs
Haskell
mit
3,094
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE StrictData #-} {-# LANGUAGE TupleSections #-} -- | http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-spotfleet-spotfleetrequestconfigdata-launchspecifications-networkinterfaces-privateipaddresses.html modul...
frontrowed/stratosphere
library-gen/Stratosphere/ResourceProperties/EC2SpotFleetPrivateIpAddressSpecification.hs
Haskell
mit
2,706
module GameServer.State where import Control.Concurrent.STM import Control.Monad.Except import Control.Monad.State import Control.Monad.Trans (MonadIO(..)) import Data.Aeson (FromJSON, ToJSON) import qualified Data.Map as Map import Data.Text (Text) import GHC.Generics (Generic) import GHC.Natural import System.Random...
abailly/acquire
game-server/src/GameServer/State.hs
Haskell
apache-2.0
3,979
{-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE DataKinds #-} module Novelist.FSopsSpec where -- base import Control.Monad (void) -- containers import qualified Data.Map.Lazy as Map -- Hspec import Test.Hspec (Spec, describe, it, shouldBe, Expectation) -- microlens-ghc im...
kgadek/novelist
test/Novelist/FSopsSpec.hs
Haskell
bsd-2-clause
5,999
-- | __Warning: internal module!__ This means that the API may change -- arbitrarily between versions without notice. Depending on this module may -- lead to unexpected breakages, so proceed with caution! -- -- This module provides debugging helpers for inspecting 'Doc's. -- -- Use the @pretty-simple@ package to get a ...
quchen/prettyprinter
prettyprinter/src/Prettyprinter/Internal/Debug.hs
Haskell
bsd-2-clause
2,963
module Drasil.GlassBR.Body where import Control.Lens ((^.)) import Language.Drasil hiding (organization) import qualified Drasil.SRS as SRS import Drasil.DocumentLanguage (AppndxSec(..), AuxConstntSec(..), DocSection(..), GSDSec(GSDProg2), GSDSub(UsrChars, SystCons), --DocSection uses everything but Verbatim Intro...
JacquesCarette/literate-scientific-software
People/Dan/Presentations/CommitteeMeeting4/BodyNew.hs
Haskell
bsd-2-clause
32,942
{-# LANGUAGE OverloadedStrings #-} module Main where import Application.HXournal.NetworkClipboard.Server.Type import Application.HXournal.NetworkClipboard.Server.Yesod () import Yesod import qualified Data.Map as M import Data.Acid -- import Data.Xournal.Simple -- import Data.Strict.Tuple -- import Data.UUID.V5 i...
wavewave/hxournalclip-server
exe/hxournalclip-server.hs
Haskell
bsd-2-clause
718
module Text.FastAleck.Text ( module Text.FastAleck , fastAleck ) where -------------------------------------------------------------------------------- import Data.Text (Text) import qualified Data.Text.Encoding as T ----------------------------------------------------------...
jaspervdj/fast-aleck-hs
src/Text/FastAleck/Text.hs
Haskell
bsd-3-clause
642
{-# LANGUAGE CPP, RecordWildCards, NamedFieldPuns, RankNTypes #-} -- | Planning how to build everything in a project. -- module Distribution.Client.ProjectPlanning ( -- * elaborated install plan types ElaboratedInstallPlan, ElaboratedConfiguredPackage(..), ElaboratedPlanPackage, ElaboratedSharedCon...
headprogrammingczar/cabal
cabal-install/Distribution/Client/ProjectPlanning.hs
Haskell
bsd-3-clause
100,058
module Htads where import System.IO import qualified Data.Char as Char import qualified Data.Map.Strict as Map import qualified Data.List as List import qualified Data.Text as Text import qualified Data.Maybe as Maybe import qualified Data.Set as Set import GHC.Generics -- local module import Alias import qualified U...
Danl2620/htads
src/Htads.hs
Haskell
bsd-3-clause
9,945
module TicTacToe.Game where import qualified TicTacToe.Data.Board as B import qualified TicTacToe.Data.Move as M import qualified TicTacToe.Data.Token as T import qualified TicTacToe.Internal.Matrix as MX import qualified TicTacToe.Internal.Move as IM startingBoard :: B.Board startingBoard = B.Board...
rodamber/haskell-tic-tac-toe
src/TicTacToe/Game.hs
Haskell
bsd-3-clause
460
{- Copyright 2013-2019 Mario Blazevic License: BSD3 (see BSD3-LICENSE.txt file) -} -- | This module defines the monoid transformer data type 'Concat'. -- {-# LANGUAGE Haskell2010 #-} module Data.Monoid.Instances.Concat ( Concat, concatenate, extract, force ) where import Control.Applicative -- (App...
blamario/monoid-subclasses
src/Data/Monoid/Instances/Concat.hs
Haskell
bsd-3-clause
12,540
{-# LANGUAGE Trustworthy #-} {-# LANGUAGE CPP, NoImplicitPrelude, ScopedTypeVariables, MagicHash #-} {-# LANGUAGE BangPatterns #-} {-# OPTIONS_HADDOCK hide #-} ----------------------------------------------------------------------------- -- | -- Module : GHC.List -- Copyright : (c) The University of Glasgow 1...
sdzivanovich/cs1699_deliverable5
MyList.hs
Haskell
bsd-3-clause
23,442
module Lava.Signal where import Lava.Ref import Lava.Sequent import Lava.Error import Data.List ( transpose ) ---------------------------------------------------------------- -- Signal, Symbol, S newtype Signal a = Signal Symbol newtype Symbol = Symbol (Ref (S Symbol)) data S s = Bool Bool | Inv ...
dfordivam/lava
Lava/Signal.hs
Haskell
bsd-3-clause
8,701
module Lib where someFunc :: IO () someFunc = putStrLn "someFunc" data CatA = AA | AB deriving (Eq, Show) type FA = (CatA -> CatA) data CatB = BA | BB deriving (Eq, Show) type GB = (CatB -> CatB) f :: CatA -> CatA f AA = AB f AB = AA g :: CatB -> CatB g BA = BB g BB = ...
matthewfranglen/category-set-graph
src/Lib.hs
Haskell
bsd-3-clause
523
import System.Environment import System.Directory import System.IO import qualified Data.Text as T import qualified Data.Text.Lazy as L import qualified Data.Text.Lazy.IO as LIO import qualified Data.Map as M import qualified Data.List as DL import Control.Monad import Parser import ParserTypes import Interpretor ...
planrich/abstractmachines
src/Main.hs
Haskell
bsd-3-clause
3,221
module Dang where
elliottt/dang
src/Dang.hs
Haskell
bsd-3-clause
18
module Day1 (run) where import Data.Char import Data.List.Split dirs :: [(Int, Int)] dirs = [(0, 1), (1, 0), (0, -1), (-1, 0)] start = ([(0, 0)], 0) parse :: String -> (Int, Int) parse = head . parseSaving parseSaving :: String -> [(Int, Int)] parseSaving = fst . foldl (flip move) start . splitOn ", ...
ulyssesp/AoC
src/day1.hs
Haskell
bsd-3-clause
1,907
{-# LANGUAGE PolyKinds #-} module ODE where import FAD import Taylor import Data.Number.IReal -- .Rounded import Data.Number.IReal(VarPrec(..)) import Data.Number.IReal.Auxiliary import Data.Maybe import Plot {- A solver for the initial value problem x' = f t x, t >= t0 x t0 = x0 using a Taylor method, combine...
sydow/ireal
applications/ODE.hs
Haskell
bsd-3-clause
2,803
-- HilbertCurve.hs {-# OPTIONS_GHC -Wall #-} module Lab2.HilbertCurve( makeHilbertCurve , drawHilbertCurve , xy2d , d2xy ) where import Graphics.Gloss import Data.Bits import Lab2.HilbertCoord drawHilbertCurve :: Int -...
ghorn/cs240h-class
Lab2/HilbertCurve.hs
Haskell
bsd-3-clause
2,600
{-# LANGUAGE DeriveGeneric #-} module Tutorial.Chapter10.Martian (Martian(..), run) where import Tutorial.Chapter10.Rock (Rock) import Tutorial.Chapter10.Plant (Plant) import qualified Tutorial.Chapter10.Plant as P (tryMating) import Tutorial.Chapter10.Bug (Bug) import qualified Tutorial.Chapter10.Bug as B (tryMating)...
mhwombat/creatur-examples
src/Tutorial/Chapter10/Martian.hs
Haskell
bsd-3-clause
1,506
module EFS(EFS, Proof, ProofLine, Formula, JustificationType(..), LineNo, sProof, proof, isEmpty, justification, sentence, rest, firstLine, letter, var, ax...
dillonhuff/EFSChecker
src/EFS.hs
Haskell
bsd-3-clause
2,343
{-# LANGUAGE DataKinds #-} {-# LANGUAGE TypeOperators #-} module V1.Api (Api, server) where import Servant import qualified V1.Projects.Api as Projects (Api, server) type Api = "projects" :> Projects.Api server :: Server Api server = Projects.server
thiagorp/deployments-web
app/v1/Api.hs
Haskell
bsd-3-clause
254
module Day17 where import Data.List partOne = length filtered partTwo = length $ takeWhile (\c -> length c == minimumNum) sorted where sorted = sortOn length filtered minimumNum = length $ head sorted filtered = filter (\i -> sum i == 150) $ subsequences input input :: [Int] input = map read $ w...
z0isch/advent-of-code
src/Day17.hs
Haskell
bsd-3-clause
387
{-# LANGUAGE Rank2Types #-} module STPermute ( tests_STPermute, smoke_STPermute ) where import Control.Monad import Control.Monad.ST import Data.Permute import Data.Permute.ST import Driver import Debug.Trace import Test.QuickCheck import Text.Printf import Test.Permute() import qualified Test....
patperry/permutation
tests/STPermute.hs
Haskell
bsd-3-clause
6,700
----------------------------------------------------------------------------- -- | -- Module : TestSuite.CodeGeneration.GCD -- Copyright : (c) Levent Erkok -- License : BSD3 -- Maintainer : erkokl@gmail.com -- Stability : experimental -- -- Test suite for Data.SBV.Examples.CodeGeneration.GCD --------...
josefs/sbv
SBVTestSuite/TestSuite/CodeGeneration/GCD.hs
Haskell
bsd-3-clause
835
{-# LANGUAGE CPP #-} #ifdef FILE_EMBED {-# LANGUAGE TemplateHaskell #-} #endif -- | The information from Paths_shake cleaned up module Development.Shake.Internal.Paths( shakeVersionString, initDataDirectory, hasManualData, copyManualData, readDataFileHTML ) where import Control.Monad.Extra import...
ndmitchell/shake
src/Development/Shake/Internal/Paths.hs
Haskell
bsd-3-clause
3,205
{-# OPTIONS_GHC -Wno-deprecations #-} module Main (main) where -------------------------------------------------------------------------------- import Data.IORef import Numeric.Natural import Prelude import System.Exit import System.IO.Unsafe import Test.QuickCheck import Control.Monad (when) import Data.B...
jfranklin9000/urbit
pkg/hs/urbit-atom/test/Main.hs
Haskell
mit
5,857
{-# LANGUAGE CPP #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE KindSignatures #-} {-# LANGUAGE ScopedTypeVariables #-} {-# LANGUAGE TypeApplications #-} module Ntp.Util ( ntpPort , WithAddrFamily (..) ...
input-output-hk/cardano-sl
networking/src/Ntp/Util.hs
Haskell
apache-2.0
10,248
-------------------------------------------------------------------- -- | -- Copyright : (c) Edward Kmett and Dan Doel 2012-2013 -- License : BSD2 -- Maintainer: Edward Kmett <ekmett@gmail.com> -- Stability : experimental -- Portability: non-portable -- ------------------------------------------------------------...
PipocaQuemada/ermine
src/Ermine/Parser/Keywords.hs
Haskell
bsd-2-clause
1,333
module SubHask.Compatibility.HyperLogLog where import SubHask.Algebra import SubHask.Category import SubHask.Internal.Prelude import qualified Data.HyperLogLog as H import qualified Data.Reflection as R import qualified Data.Semigroup as S import qualified Prelude as P -- FIXME: move the below imports to separat...
Drezil/subhask
src/SubHask/Compatibility/HyperLogLog.hs
Haskell
bsd-3-clause
1,150
------------------------------------------------------------------------------------- -- | -- Copyright : (c) Hans Hoglund 2012 -- -- License : BSD-style -- -- Maintainer : hans@hanshoglund.se -- Stability : experimental -- Portability : portable -- -- A Haskell representation of MusicXML. -- You may want to ...
music-suite/musicxml2
src/Data/Music/MusicXml.hs
Haskell
bsd-3-clause
3,371
module Database.DSH.VSL.VirtSegAlgebra where
ulricha/dsh
src/Database/DSH/VSL/VirtSegAlgebra.hs
Haskell
bsd-3-clause
45
----------------------------------------------------------------------------- -- | -- Module : System.Taffybar.Support.PagerHints -- Copyright : (c) José A. Romero L. -- License : BSD3-style (see LICENSE) -- -- Maintainer : José A. Romero L. <escherdragon@gmail.com> -- Stability : unstable -- Portability ...
teleshoes/taffybar
src/System/Taffybar/Support/PagerHints.hs
Haskell
bsd-3-clause
3,992
-- Monadic command line checkers.. -- @2013 Angel Alvarez module OptsCheck where -- Main module needed imports import Control.Exception (SomeException,evaluate,try) import Control.Monad(foldM,liftM,ap) import Control.Monad.IO.Class import Control.Monad.Trans.Either import Data.List (find) import Data.Maybe ( fromMay...
felipeZ/Dynamics
src/OptsCheck.hs
Haskell
bsd-3-clause
5,822
module Main where import Tandoori.GHC import Tandoori.GHC.Parse import Tandoori.GHC.Scope import GHC import Outputable import IOEnv import System.Environment import Tandoori.Typing.Infer import Tandoori.Typing.Show typecheckMod mod = runDyn $ do env <- getSession ...
bitemyapp/tandoori
src/main.hs
Haskell
bsd-3-clause
1,106
module PigLatin (translate) where import Data.Char (isLetter) import Data.List (isSuffixOf) consonantCluster :: String -> (String, String) consonantCluster = qu . break (`elem` "aeiou") where qu (cs, ('u':rest)) | "q" `isSuffixOf` cs = (cs ++ "u", rest) qu pair = pair translateWord :: String -> String trans...
pminten/xhaskell
pig-latin/example.hs
Haskell
mit
569
{- Copyright 2015 Google Inc. 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.0 Unless required by applicable law or a...
Ye-Yong-Chi/codeworld
codeworld-base/src/GHC/Int.hs
Haskell
apache-2.0
729
{-# LANGUAGE Rank2Types #-} -- | Internal types to the library. module Stack.Types.Internal where import Control.Concurrent.MVar import Control.Monad.Logger (LogLevel) import Data.Monoid.Extra import Data.Text (Text) import Lens.Micro import Network.HTTP.Client.Conduit (Manager,HasHttpManager(..)) import Stack.Types...
phadej/stack
src/Stack/Types/Internal.hs
Haskell
bsd-3-clause
4,124
module SwapArgsSpec (main, spec) where import Test.Hspec -- import qualified GHC as GHC -- import qualified GhcMonad as GHC -- import qualified RdrName as GHC -- import qualified SrcLoc as GHC import Language.Haskell.Refact.Refactoring.SwapArgs import TestUtils import System.Directory -- -------...
RefactoringTools/HaRe
test/SwapArgsSpec.hs
Haskell
bsd-3-clause
1,382
module PackageTests.OrderFlags.Check where import Test.Tasty.HUnit import PackageTests.PackageTester import System.FilePath import Control.Exception #if !MIN_VERSION_base(4,6,0) import Prelude hiding (catch) #endif suite :: FilePath -> Assertion suite ghcPath = do let spec = PackageSpec { directory =...
Helkafen/cabal
Cabal/tests/PackageTests/OrderFlags/Check.hs
Haskell
bsd-3-clause
685
-------------------------------------------------------------------------------- {-# LANGUAGE OverloadedStrings #-} module Hakyll.Core.Runtime.Tests ( tests ) where -------------------------------------------------------------------------------- import qualified Data.ByteString as B import Syste...
Minoru/hakyll
tests/Hakyll/Core/Runtime/Tests.hs
Haskell
bsd-3-clause
2,676
<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE helpset PUBLIC "-//Sun Microsystems Inc.//DTD JavaHelp HelpSet Version 2.0//EN" "http://java.sun.com/products/javahelp/helpset_2_0.dtd"> <helpset version="2.0" xml:lang="bs-BA"> <title>Forced Browse Add-On</title> <maps> <homeID>top</homeID> <mapref locatio...
thc202/zap-extensions
addOns/bruteforce/src/main/javahelp/org/zaproxy/zap/extension/bruteforce/resources/help_bs_BA/helpset_bs_BA.hs
Haskell
apache-2.0
965
module Test1 where f = e1 + e2 where e1 = 1 + 2 e2 = 1 - 2
kmate/HaRe
old/testing/refacSlicing/Test1.hs
Haskell
bsd-3-clause
94
{-# LANGUAGE FlexibleInstances, MultiParamTypeClasses, TypeSynonymInstances #-} ----------------------------------------------------------------------------- -- | -- Module : XMonad.Layout.Accordion -- Copyright : (c) glasser@mit.edu -- License : BSD -- -- Maintainer : glasser@mit.edu -- Stability : ...
adinapoli/xmonad-contrib
XMonad/Layout/Accordion.hs
Haskell
bsd-3-clause
1,949
{-# LANGUAGE OverloadedStrings #-} module Tests.JSON where import Haste import Haste.JSON import Haste.Serialize import Control.Applicative data ABC = A | B | C deriving (Show, Read) data Foo = Foo { string :: String, number :: Int, bool :: Bool, nested :: Either String Foo, enum :: ABC } ...
beni55/haste-compiler
Tests/JSON.hs
Haskell
bsd-3-clause
1,304
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE helpset PUBLIC "-//Sun Microsystems Inc.//DTD JavaHelp HelpSet Version 2.0//EN" "http://java.sun.com/products/javahelp/helpset_2_0.dtd"> <helpset version="2.0" xml:lang="hr-HR"> <title>AJAX Spider | ZAP Extensions</title> <maps> <homeID>top</homeID> <mapre...
msrader/zap-extensions
src/org/zaproxy/zap/extension/spiderAjax/resources/help_hr_HR/helpset_hr_HR.hs
Haskell
apache-2.0
974
{-# LANGUAGE TypeFamilies #-} -- This is actually perfectly ok! module NonLinearSigErr where type family E a b type instance E a (a :: *) = [a]
urbanslug/ghc
testsuite/tests/indexed-types/should_fail/NonLinearSigErr.hs
Haskell
bsd-3-clause
147
-- !!! Test exceptions in a foreign import "wrapper" import Foreign import Foreign.C import System.Exit type IOF = IO () foreign import ccall "wrapper" wrap_f_io :: IOF -> IO (FunPtr IOF) foreign import ccall "dynamic" call_io :: FunPtr IOF -> IOF mk_error = error "this is an error" main = do f <- wrap_f_io mk_err...
holzensp/ghc
testsuite/tests/ffi/should_run/ffi008.hs
Haskell
bsd-3-clause
334