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 : Graphics.X11
-- Copyright : (c) Alastair Reid, 1999-2003
-- License : BSD-style (see the file libraries/base/LICENSE)
--
-- Maintainer : [email protected]
-- Stability : provisional
-- Portability : p... | mgsloan/X11 | Graphics/X11.hs | bsd-3-clause | 694 | 0 | 5 | 101 | 37 | 30 | 7 | 3 | 0 |
<?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="tr-TR">
<title>Requester</title>
<maps>
<homeID>requester</homeID>
<mapref location="ma... | kingthorin/zap-extensions | addOns/requester/src/main/javahelp/help_tr_TR/helpset_tr_TR.hs | apache-2.0 | 960 | 77 | 66 | 155 | 404 | 205 | 199 | -1 | -1 |
{-# OPTIONS_JHC -fno-prelude #-}
module Jhc.Inst.Show() where
import Jhc.Basics
import Jhc.Class.Num
import Jhc.Class.Ord
import Jhc.Class.Real
import Jhc.Show
import Jhc.Type.C
-- we convert them to Word or WordMax so the showIntAtBase specialization can occur.
fromIntegral :: (Integral a, Num b) => a -> b
fromIn... | hvr/jhc | lib/jhc/Jhc/Inst/Show.hs | mit | 3,166 | 0 | 15 | 714 | 1,192 | 614 | 578 | 72 | 2 |
{-# LANGUAGE TemplateHaskell #-}
{-# OPTIONS_GHC -Wall #-}
module Bug where
import Language.Haskell.TH
-- Warnings should be preserved through recover
main :: IO ()
main = putStrLn $(recover (stringE "splice failed")
[| let x = "a" in let x = "b" in x |])
| sdiehl/ghc | testsuite/tests/th/TH_recover_warns.hs | bsd-3-clause | 284 | 0 | 10 | 72 | 49 | 29 | 20 | 7 | 1 |
{-# LANGUAGE PatternGuards, DeriveFunctor #-}
module IRTS.Lang where
import Control.Monad.State hiding (lift)
import Control.Applicative hiding (Const)
import Idris.Core.TT
import Idris.Core.CaseTree
import Data.List
import Debug.Trace
data Endianness = Native | BE | LE deriving (Show, Eq)
data LVar = Loc Int | G... | osa1/Idris-dev | src/IRTS/Lang.hs | bsd-3-clause | 14,464 | 0 | 17 | 5,378 | 5,508 | 2,783 | 2,725 | 287 | 22 |
<?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="hi-IN">
<title>Getting started Guide</title>
<maps>
<homeID>top</homeID>
<mapref locat... | ccgreen13/zap-extensions | src/org/zaproxy/zap/extension/gettingStarted/resources/help_hi_IN/helpset_hi_IN.hs | apache-2.0 | 967 | 79 | 66 | 158 | 411 | 208 | 203 | -1 | -1 |
-- Test we don't get a cycle for "phantom" superclasses
{-# LANGUAGE ConstraintKinds, MultiParamTypeClasses, FlexibleContexts #-}
module TcOK where
class A cls c where
meth :: cls c => c -> c
class A B c => B c where
| forked-upstream-packages-for-ghcjs/ghc | testsuite/tests/typecheck/should_compile/tc259.hs | bsd-3-clause | 223 | 0 | 8 | 46 | 51 | 26 | 25 | -1 | -1 |
{-# LANGUAGE RecordWildCards #-}
module Network.HTTP.Download.VerifiedSpec where
import Crypto.Hash
import Control.Monad (unless)
import Control.Monad.Trans.Reader
import Control.Retry (limitRetries)
import Data.Maybe
import Network.HTTP.Client.Conduit
import Network.HTTP.Download.Verified
import Path
import System.Di... | akhileshs/stack | src/test/Network/HTTP/Download/VerifiedSpec.hs | bsd-3-clause | 6,282 | 0 | 22 | 1,218 | 1,496 | 759 | 737 | 122 | 1 |
module Main(main) where
import System.Random
tstRnd rng = checkRange rng (genRnd 50 rng)
genRnd n rng = take n (randomRs rng (mkStdGen 2))
checkRange (lo,hi) = all pred
where
pred
| lo <= hi = \ x -> x >= lo && x <= hi
| otherwise = \ x -> x >= hi && x <= lo
main :: IO ()
main = do
print (tstRnd ... | danse/ghcjs | test/pkg/base/rand001.hs | mit | 460 | 0 | 12 | 112 | 271 | 141 | 130 | 15 | 1 |
module CodeModel.Core where
import CodeModel.Function
import CodeModel.Signature
data Core = Core String [Function]
instance Show Core where
show (Core name funs) = "core " ++ name ++ "\n" ++ unlines (map show funs)
getFunction :: Core -> String -> Maybe Function
getFunction (Core _ fs) s = (\filtered -> if null ... | MarcusVoelker/Recolang | CodeModel/Core.hs | mit | 423 | 0 | 13 | 76 | 176 | 92 | 84 | 8 | 2 |
module Y2018.M05.D08.Exercise where
{--
Okay, now that we have the new articles downloaded from the REST endpoint and
the ArticleMetaData context from the database, let's do some triage!
So, just like with the ArticleMetaData, we have to generalize the Article-
TriageInformation type from the specific Package and (Da... | geophf/1HaskellADay | exercises/HAD/Y2018/M05/D08/Exercise.hs | mit | 2,432 | 0 | 13 | 419 | 257 | 159 | 98 | 24 | 1 |
import Test.Hspec.Attoparsec
import Test.Tasty
import Test.Tasty.Hspec
import Data.Attoparsec.ByteString.Char8
import qualified Data.ByteString.Char8 as C8
import Data.STEP.Parsers
main :: IO ()
main = do
specs <- createSpecs
let tests = testGroup "Tests" [specs]
defaultMain tests
createSpecs = testSpec "Pars... | Newlifer/libstep | test/test.hs | mit | 659 | 0 | 13 | 136 | 200 | 109 | 91 | 19 | 1 |
import Test.Tasty
import Test.Tasty.QuickCheck
import Coreutils
import Data.List (intersperse)
main :: IO ()
main = defaultMain tests
tests :: TestTree
tests = testGroup "Unit tests" [libTests]
libTests :: TestTree
libTests = testGroup "coreutils" [splitTests]
splitTests :: TestTree
splitTests = testGroup "split"
... | mrak/coreutils.hs | tests/unit/Main.hs | mit | 768 | 0 | 17 | 216 | 241 | 126 | 115 | -1 | -1 |
{-# LANGUAGE OverloadedStrings #-}
module Main where
import Data.ByteString (ByteString)
import qualified Data.ByteString.Char8 as BC
import Data.Foldable (traverse_)
input :: ByteString
input = "10001001100000001"
bitFlip :: Char -> Char
bitFlip '0' = '1'
bitFlip _ = '0'
dragon... | genos/online_problems | advent_of_code_2016/day16/hask/src/Main.hs | mit | 1,652 | 0 | 11 | 464 | 589 | 320 | 269 | 44 | 2 |
-----------------------------------------------------------------------------
--
-- Module : Language.PureScript.CoreFn.Ann
-- Copyright : (c) 2013-14 Phil Freeman, (c) 2014 Gary Burgess, and other contributors
-- License : MIT
--
-- Maintainer : Phil Freeman <[email protected]>, Gary Burgess <gary.burge... | michaelficarra/purescript | src/Language/PureScript/CoreFn/Ann.hs | mit | 1,048 | 0 | 6 | 148 | 153 | 104 | 49 | 10 | 1 |
import Data.List
combinations :: Int -> [a] -> [[a]]
combinations 0 _ = [ [] ]
combinations n xs = [ y:ys | y:xs' <- tails xs
, ys <- combinations (n-1) xs']
| curiousily/haskell-99problems | 26.hs | mit | 187 | 0 | 10 | 62 | 95 | 50 | 45 | 5 | 1 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE DeriveGeneric #-}
module Codec.Xlsx.Types.Internal.CommentTable where
import Data.ByteString.Lazy (ByteString)
import qualified Data.ByteString.Lazy as LB
import qualified Data.ByteString.Lazy.Char8 as LBC8
import Data.List.Extra (nubOr... | qrilka/xlsx | src/Codec/Xlsx/Types/Internal/CommentTable.hs | mit | 4,940 | 0 | 16 | 1,068 | 1,104 | 611 | 493 | 100 | 2 |
-- | Biegunka - configuration development library
module Control.Biegunka
( -- * Interpreters control
biegunka, Settings, defaultSettings, runRoot, biegunkaRoot
, Templates(..), templates
-- * Interpreters
, Interpreter
, pause, confirm, changes, run, check
-- * Types
, Script, Scope(..)
-- * ... | biegunka/biegunka | src/Control/Biegunka.hs | mit | 1,687 | 0 | 7 | 304 | 453 | 302 | 151 | 37 | 1 |
import Data.Char
import Data.List (sort)
{- Chapter 7 :: Higher-order functions -}
twice :: (a -> a) -> a -> a
twice f x = f (f x)
map' :: (a -> b) -> [a] -> [b]
map' f xs = [f x | x <- xs]
-- map defined by recursion
map'' :: (a -> b) -> [a] -> [b]
map'' f [] = []
map'' f (x:xs) = f x : map'' f xs
filter' :: (a ... | rad1al/hutton_exercises | notes_ch07.hs | gpl-2.0 | 6,499 | 0 | 10 | 1,692 | 2,125 | 1,160 | 965 | 114 | 2 |
module Physics.ImplicitEMC () where
| firegurafiku/ImplicitEMC | src/Physics/ImplicitEMC.hs | gpl-2.0 | 37 | 0 | 3 | 5 | 9 | 6 | 3 | 1 | 0 |
{- This module was generated from data in the Kate syntax
highlighting file vhdl.xml, version 1.12, by Rocky Scaletta ([email protected]), Stefan Endrullis ([email protected]), Florent Ouchet ([email protected]), Chris Higgs ([email protected]), Jan Michel ([email protected]) -}
module Text.Highligh... | ambiata/highlighting-kate | Text/Highlighting/Kate/Syntax/Vhdl.hs | gpl-2.0 | 32,109 | 0 | 20 | 4,197 | 8,369 | 4,497 | 3,872 | 548 | 43 |
module Data.FNLP
(
module Data.Convertible
, module Data.Convertible.Auto
) where
import Data.Convertible
import Data.Convertible.Auto
| RoboNickBot/fnlp | src/Data/FNLP.hs | gpl-3.0 | 154 | 0 | 5 | 33 | 32 | 21 | 11 | 6 | 0 |
{-# LANGUAGE TypeSynonymInstances #-}
{-# LANGUAGE FlexibleInstances #-}
module Board where
import Piece
import qualified Data.Sequence as S
import qualified Data.List as L
import qualified Data.Foldable as F
type Row = S.Seq Piece
instance Pretty Row where
pretty o r = "│ " ++ L.intercalate " ... | HalosGhost/stratagem | src/Board.hs | gpl-3.0 | 5,425 | 0 | 21 | 2,350 | 1,579 | 824 | 755 | 95 | 2 |
{-# LANGUAGE RecordWildCards, OverloadedStrings, TemplateHaskell, DeriveGeneric #-}
module Lamdu.GUI.ExpressionEdit.HoleEdit.State
( HoleState(..), hsSearchTerm
, emptyState, setHoleStateAndJump, assocStateRef
) where
import qualified Control.Lens as Lens
import Control.MonadA (MonadA)
import ... | rvion/lamdu | Lamdu/GUI/ExpressionEdit/HoleEdit/State.hs | gpl-3.0 | 1,392 | 0 | 11 | 236 | 326 | 191 | 135 | 31 | 1 |
{- -----------------------------------------------------------------------------
PTrader is a Personal Stock Trader Toolbox.
Copyright (C) 2012 Luis Cabellos
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 Foun... | zhensydow/ptrader | examples/example01.hs | gpl-3.0 | 1,870 | 0 | 10 | 268 | 220 | 125 | 95 | 22 | 1 |
module Main where
import Control.Applicative
import Control.Concurrent.Async
import Control.Concurrent.STM
import Control.Monad
import qualified Data.ByteString as BS
import qualified Data.ByteString.Lazy as BSL
import Data.Function (on)
import Data.List (foldl')
import Data.Map.KDMap
import Data.Monoid
import Data.Ti... | imalsogreg/tetrode-ephys | utils/drawKD.hs | gpl-3.0 | 4,889 | 0 | 16 | 1,294 | 1,681 | 882 | 799 | 113 | 2 |
module Objects where
import Geometry3
import Types
printObj :: Object -> String
printObj (Sphere c r _) = "Sphere " ++ show c ++ " " ++ show r
printObj (Triangle a b c _ _) = "Triangle " ++ show a ++ " " ++
show b ++ " " ++ show c
calcNormal :: Vec3 -> Vec3 -> Vec3 -> Vec3
calcNorm... | jrraymond/ray-tracer | src/Objects.hs | gpl-3.0 | 1,849 | 0 | 10 | 589 | 729 | 386 | 343 | 44 | 1 |
module Util where
import Ast
import Char
import Data.Bits
import Text.ParserCombinators.Parsec.Pos
hex d v = hex_ d (fromInteger v)
hex_ 0 v = ""
hex_ d v = (hex_ (d-1) (v `div` 16)) ++ [(hx (v `mod` 16))]
bv n b = if (testBit b n) then "1" else "0"
bz 0 v = ""
bz n v = (bv (n-... | luebbers/reconos | tools/fsmLanguage/kurm/assembler/Util.hs | gpl-3.0 | 2,160 | 0 | 13 | 1,016 | 1,163 | 602 | 561 | 45 | 13 |
module MLSB.Eval where
import qualified Data.Map as Map
import Data.Functor.Foldable (Fix(..), Recursive(..), Corecursive(..))
import Data.Monoid((<>))
import Data.Map (Map, (!))
import MLSB.Types
data Val =
ValC Const
| ValFn (Val -> Val)
printVal :: Val -> String
printVal val =
case val of
ValC c ->... | grwlf/ml-df | src/MLSB/Eval.hs | gpl-3.0 | 1,867 | 0 | 20 | 527 | 807 | 426 | 381 | 57 | 8 |
module Types where
-- Name representa el nombre de una lista de peliculas.
type Name = String
-------------------------
-- AST
data Comm = Seq Comm Comm -- secuencia de comandos
| Def Name FList -- define una lista
| Add Name FList -- operador <<
| Rem Name FLis... | g-deluca/yts-dl | app/Types.hs | gpl-3.0 | 3,686 | 0 | 9 | 1,749 | 433 | 276 | 157 | 53 | 0 |
module View.Project
( editProjectForm
, projectContactForm
, inviteForm
, projectBlogForm
, projectConfirmSharesForm
, renderBlogPost
, renderProject
, viewForm
) where
import Import
import Data.Filter
import Data.Order
import Model.Currency
import ... | Happy0/snowdrift | View/Project.hs | agpl-3.0 | 5,569 | 0 | 30 | 1,429 | 1,580 | 796 | 784 | -1 | -1 |
import System.Plugins
import API
src = "../Plugin.hs"
wrap = "../Wrapper.hs"
apipath = "../api"
main = do status <- make src ["-i"++apipath]
case status of
MakeSuccess _ _ -> f
MakeFailure e-> mapM_ putStrLn e
where f = do v <- load "../Plugin.o" ["../api"] []... | Changaco/haskell-plugins | testsuite/pdynload/null/prog/Main.hs | lgpl-2.1 | 465 | 0 | 11 | 168 | 116 | 58 | 58 | 11 | 2 |
{-
Copyright (C) 2009 Andrejs Sisojevs <[email protected]>
All rights reserved.
For license and copyright information, see the file COPYRIGHT
-}
--------------------------------------------------------------------------
--------------------------------------------------------------------------
... | Andrey-Sisoyev/PCLT-DB | examples/HelloWorld/HelloWorld.hs | lgpl-2.1 | 16,119 | 0 | 29 | 5,323 | 1,814 | 963 | 851 | -1 | -1 |
module FreePalace.Handlers.Incoming where
import Control.Concurrent
import Control.Exception
import qualified System.Log.Logger as Log
import qualified FreePalace.Domain.Chat as Chat
import qualified FreePalace.Domain.GUI ... | psfblair/freepalace | src/FreePalace/Handlers/Incoming.hs | apache-2.0 | 14,645 | 0 | 17 | 2,460 | 2,529 | 1,218 | 1,311 | 183 | 3 |
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE ViewPatterns #-}
{-# OPTIONS_GHC -fno-warn-incomplete-patterns #-}
module FreezePredicateParserSpec where
import Bio.Motions.Types
import Bio.Motions.Representation.Common
import Bio.Motions.Utils.FreezePredicateParser
import GHC.Exts
import Data.Either
import Text.Parsec... | Motions/motions | test/FreezePredicateParserSpec.hs | apache-2.0 | 3,060 | 0 | 14 | 804 | 767 | 405 | 362 | 71 | 1 |
-- "Treealize" expression terms
module OperationExtension2 where
import Data.Tree
import DataBase
import DataExtension
class ToTree x
where
toTree :: x -> Tree String
instance ToTree Lit
where
toTree (Lit i) = Node "Lit" []
instance (Exp x, Exp y, ToTree x, ToTree y) => ToTree (Add x y)
where
toTree (Add... | egaburov/funstuff | Haskell/tytag/xproblem_src/samples/expressions/Haskell/OpenDatatype1/OperationExtension2.hs | apache-2.0 | 454 | 0 | 8 | 97 | 196 | 100 | 96 | 12 | 0 |
------------------------------------------------------------------------------
-- Copyright 2012 Microsoft Corporation.
--
-- This is free software; you can redistribute it and/or modify it under the
-- terms of the Apache License, Version 2.0. A copy of the License can be
-- found in the file "license.txt" at the root... | lpeterse/koka | src/Kind/Constructors.hs | apache-2.0 | 4,461 | 0 | 15 | 894 | 951 | 506 | 445 | 74 | 2 |
{-# LANGUAGE OverloadedStrings #-}
module Database.HXournal.Store.Config where
import Data.Configurator as C
import Data.Configurator.Types
import Control.Applicative
import Control.Concurrent
import Control.Monad
import System.Environment
import System.Directory
import System.FilePath
data HXournalStoreConfiguratio... | wavewave/hxournal-store | lib/Database/HXournal/Store/Config.hs | bsd-2-clause | 1,079 | 0 | 12 | 175 | 237 | 122 | 115 | 28 | 1 |
{-# LANGUAGE PackageImports #-}
import Control.Applicative hiding (many)
import qualified Data.Attoparsec as P
import Data.Attoparsec.Char8 -- as P8
import qualified Data.ByteString.Char8 as B hiding (map)
import HEP.Parser.LHEParser
import Debug.Trace
import qualified Data.Iteratee as Iter
import qualified ... | wavewave/LHEParser | test/test.hs | bsd-2-clause | 1,490 | 0 | 16 | 403 | 489 | 245 | 244 | 35 | 5 |
import Data.List (nub)
main = print $ length $ nub [ a^b | a <- [2 .. 100], b <- [2 .. 100] ]
| foreverbell/project-euler-solutions | src/29.hs | bsd-3-clause | 95 | 0 | 10 | 25 | 62 | 34 | 28 | 2 | 1 |
{-# LANGUAGE TypeFamilies, CPP #-}
-- | Simple interface for shell scripting-like tasks.
module Control.Shell
( -- * Running Shell programs
Shell, ExitReason (..)
, shell, shell_, exitString
-- * Error handling and control flow
, (|>), capture, captureStdErr, capture2, capture3, stream, lift
, try, orE... | valderman/shellmate | shellmate/Control/Shell.hs | bsd-3-clause | 4,736 | 0 | 13 | 889 | 1,149 | 676 | 473 | 84 | 1 |
module Network.Kontiki.SerializationSpec where
import Data.Binary (Binary, decode, encode)
import Network.Kontiki.Raft
import Test.Hspec
import Test.QuickCheck
serializationSpec :: Spec
serializationSpec = do
describe "Messages" $ do
it "Message Int" $ property ... | abailly/kontiki | test/Network/Kontiki/SerializationSpec.hs | bsd-3-clause | 1,225 | 0 | 14 | 252 | 363 | 179 | 184 | 22 | 1 |
module Language.GhcHaskell.Parser
where
import Control.Monad
import qualified Language.Haskell.Exts.Parser as P
import Language.Haskell.AST.HSE
import Language.GhcHaskell.AST
parsePat :: String -> ParseResult (Parsed Pat)
parsePat = P.parse >=> fromHsePat
parseExp :: String -> ParseResult (Parsed Exp)
parseExp = ... | jcpetruzza/haskell-ast | src/Language/GhcHaskell/Parser.hs | bsd-3-clause | 609 | 0 | 8 | 83 | 180 | 100 | 80 | 15 | 1 |
{-# LANGUAGE Haskell2010 #-}
module Maybe1 where
instance Functor Maybe' where
fmap f m = m >>= pure . f
instance Applicative Maybe' where
pure = Just'
f1 <*> f2 = f1 >>= \v1 -> f2 >>= (pure . v1)
data Maybe' a = Nothing' | Just' a
instance Monad Maybe' where
return = pure
Nothing' >>= _ = Noth... | hvr/Hs2010To201x | testcases/H2010/Maybe1.expected.hs | bsd-3-clause | 373 | 0 | 10 | 106 | 137 | 71 | 66 | 13 | 0 |
module Main where
import ImageFlatten
import Data.Maybe
import Data.Char
import Options.Applicative
import System.IO
import System.Environment
import System.FilePath
data Options = Options
{ input :: String,
output :: String,
combine :: Bool,
remove :: Bool,
avg :: Bool,
thre... | iansullivan88/image-flatten | app/Main.hs | bsd-3-clause | 3,056 | 0 | 17 | 993 | 744 | 374 | 370 | 54 | 4 |
{-# LANGUAGE MultiParamTypeClasses, FlexibleInstances, DeriveFunctor,
DeriveDataTypeable, TypeSynonymInstances, PatternGuards #-}
module Idris.AbsSyntaxTree where
import Idris.Core.TT
import Idris.Core.Evaluate
import Idris.Core.Elaborate hiding (Tactic(..))
import Idris.Core.Typecheck
import Idris.Docst... | MetaMemoryT/Idris-dev | src/Idris/AbsSyntaxTree.hs | bsd-3-clause | 103,703 | 0 | 22 | 33,350 | 35,399 | 18,304 | 17,095 | 1,835 | 98 |
module Yesod.Helpers.Yaml (
module Yesod.Helpers.Yaml
, DefaultEnv(..)
) where
import Prelude
import Data.Yaml
import Yesod
import Data.Text (Text)
import Data.Aeson (withObject)
import qualified Data.Text as T
import Data.Maybe ... | yoo-e/yesod-helpers | Yesod/Helpers/Yaml.hs | bsd-3-clause | 2,512 | 0 | 23 | 1,090 | 541 | 286 | 255 | -1 | -1 |
module QueryArrow.Control.Monad.Logger.HSLogger where
import Control.Monad.Logger
import System.Log.FastLogger
import System.Log.Logger
import qualified Data.Text as T
import Data.Text.Encoding
instance MonadLogger IO where
monadLoggerLog loc logsource loglevel msg = do
let priority = case loglevel of
... | xu-hao/QueryArrow | log-adapter/src/QueryArrow/Control/Monad/Logger/HSLogger.hs | bsd-3-clause | 706 | 0 | 16 | 216 | 167 | 90 | 77 | 17 | 0 |
{-# LANGUAGE ViewPatterns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE NoImplicitPrelude #-}
-- | Wiki page view.
module HL.V.Wiki where
import HL.V
import HL.V.Code
import HL.V.Template
import Data.List (isPrefixOf)
import Data.Text (unpack,pack)
import Language.Haskell.HsColour.CSS (hscolour)
import Prelud... | yogsototh/hl | src/HL/V/Wiki.hs | bsd-3-clause | 2,130 | 0 | 21 | 579 | 651 | 349 | 302 | 53 | 3 |
module Yesod.Helpers.Auth where
import Prelude
import Yesod
import Yesod.Auth
import Control.Monad.Catch (MonadThrow)
import Control.Monad
import qualified Data.Text as T
yesodAuthIdDo :: (YesodAuth master, MonadIO m, MonadThrow m, MonadBaseControl IO m) =>
(AuthId ... | yoo-e/yesod-helpers | Yesod/Helpers/Auth.hs | bsd-3-clause | 3,357 | 0 | 14 | 913 | 893 | 449 | 444 | -1 | -1 |
module Main where
import Language.ECMAScript3.Syntax
import Language.ECMAScript3.Syntax.Annotations
import Language.ECMAScript3.Parser
import Language.ECMAScript3.PrettyPrint
import Data.Set (Set)
import qualified Data.Set as Set
import Data.Data (Data)
--import System.IO
import Data.Generics.Uniplate.Data
import Data... | achudnov/jsapia | Main.hs | bsd-3-clause | 4,038 | 0 | 19 | 1,208 | 1,167 | 604 | 563 | 76 | 7 |
module Main where
import MenuIO
main :: IO ()
main = menu []
| arthurmgo/regex-ftc | app/Main.hs | bsd-3-clause | 63 | 0 | 6 | 15 | 27 | 15 | 12 | 4 | 1 |
module OutputDirectory
(outdir) where
outdir = "_data"
| pnlbwh/test-tensormasking | config-output-paths/OutputDirectory.hs | bsd-3-clause | 58 | 0 | 4 | 10 | 14 | 9 | 5 | 3 | 1 |
{-# LANGUAGE DeriveDataTypeable #-}
module WFF where
import qualified Data.Map as M
import Test.QuickCheck hiding ((.||.), (==>), (.&&.))
import qualified Data.Set as S
import Data.Data
import Data.Generics.Uniplate.Data
import Data.List hiding (lookup, union)
import Prelude hiding (lookup)
import Control.Applicative h... | patrikja/GRACeFUL | ConstraintModelling/WFF.hs | bsd-3-clause | 2,457 | 0 | 17 | 1,138 | 1,016 | 522 | 494 | 58 | 1 |
#!/usr/bin/env runhaskell
{-# LANGUAGE BangPatterns
#-}
{-| The Sphere Online Judge is a collection of problems. One problem, problem
450, came up on the mailing list as a sensible benchmark for fast integer
parsing.
-}
{- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
htt... | solidsnack/bytestring-nums | SPOJObvious.hs | bsd-3-clause | 1,328 | 0 | 11 | 476 | 294 | 161 | 133 | 19 | 1 |
squareM = #x -> `(,x * ,x) -- `#` indicates macro-lambda
unittest "squareM" [
(squareM 3, 9),
(let a = 3 in squareM a, 9),
]
a = "a"
unittest "macro_expand" [
(macro_expand {squareM 3}, (*) 3 3),
(macro_expand {(squareM 3) + 1}, (+) ((*) 3 3) 1),
(macro_expand {squar... | ocean0yohsuke/Simply-Typed-Lambda | Start/UnitTest/Macro.hs | bsd-3-clause | 926 | 24 | 11 | 281 | 470 | 270 | 200 | -1 | -1 |
import Control.Arrow ((***))
import Control.Monad (join)
{-- snippet adler32 --}
import Data.Char (ord)
import Data.Bits (shiftL, (.&.), (.|.))
base = 65521
adler32 xs = helper 1 0 xs
where helper a b (x:xs) = let a' = (a + (ord x .&. 0xff)) `mod` base
b' = (a' + b) `mod` base
... | binesiyu/ifl | examples/ch04/Adler32.hs | mit | 1,188 | 0 | 16 | 403 | 548 | 313 | 235 | 22 | 2 |
{-@ LIQUID "--no-termination" @-}
module Lec02 where
import Text.Printf (printf)
import Debug.Trace (trace)
incr :: Int -> Int
incr x = x + 1
zincr :: Int -> Int
zincr = \x -> x + 1
eleven = incr (10 + 2)
-- sumList xs = case xs of
-- [] -> 0
-- (x:xs) -> x + sumList xs
sumList ::... | ucsd-progsys/131-web | static/hs/lec-1-17-2018.hs | mit | 1,707 | 0 | 11 | 586 | 724 | 381 | 343 | 50 | 4 |
module Main where
comb :: [([Char], [Char])]
color = ["blue", "red", "green"]
comb = [(x, y) | x <- color, y <- color, x < y] | momo9/seven-lang | haskell/src/combination.hs | mit | 125 | 0 | 7 | 25 | 76 | 46 | 30 | 4 | 1 |
{-# LANGUAGE DeriveFunctor #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TupleSections #-}
{- |
Module : Network.MPD.Applicative.Internal
Copyright : (c) Simon Hengel 2012
License : MIT
Maintainer : [email protected]
Stability : stable
Portability : unportable
Applicative MPD command interface... | bens/libmpd-haskell | src/Network/MPD/Applicative/Internal.hs | lgpl-2.1 | 3,046 | 0 | 13 | 725 | 755 | 415 | 340 | 59 | 4 |
{-# LANGUAGE CPP, ScopedTypeVariables #-}
--
-- (c) The University of Glasgow 2002
--
-- Binary I/O library, with special tweaks for GHC
--
-- Based on the nhc98 Binary library, which is copyright
-- (c) Malcolm Wallace and Colin Runciman, University of York, 1998.
-- Under the terms of the license for that software, w... | k0001/gtk2hs | tools/c2hs/base/general/Binary.hs | gpl-3.0 | 27,010 | 2 | 19 | 8,071 | 7,275 | 3,626 | 3,649 | -1 | -1 |
{-# LANGUAGE DataKinds, PolyKinds, TypeOperators, TypeFamilies
, TypeApplications #-}
module DumpTypecheckedAst where
import Data.Kind
data Peano = Zero | Succ Peano
type family Length (as :: [k]) :: Peano where
Length (a : as) = Succ (Length as)
Length '[] = Zero
data T f (a :: k) = MkT (f a)... | sdiehl/ghc | testsuite/tests/parser/should_compile/DumpTypecheckedAst.hs | bsd-3-clause | 431 | 2 | 8 | 109 | 158 | 92 | 66 | -1 | -1 |
-- | Settings are centralized, as much as possible, into this file. This
-- includes database connection settings, static file locations, etc.
-- In addition, you can configure a number of different aspects of Yesod
-- by overriding methods in the Yesod typeclass. That instance is
-- declared in the Foundation.hs file.... | SuetakeY/nomnichi_yesod | Settings.hs | bsd-2-clause | 2,742 | 0 | 9 | 483 | 287 | 182 | 105 | -1 | -1 |
{-# LANGUAGE Trustworthy #-}
{-# LANGUAGE NoImplicitPrelude
, RecordWildCards
, BangPatterns
, NondecreasingIndentation
, RankNTypes
#-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
{-# OPTIONS_GHC -fno-warn-name-shadowing #-}
{-# OPTIONS_HADDOCK hide #-}
-----------------... | frantisekfarka/ghc-dsi | libraries/base/GHC/IO/Handle/Internals.hs | bsd-3-clause | 35,776 | 0 | 23 | 8,646 | 6,855 | 3,469 | 3,386 | 543 | 6 |
{-# LANGUAGE TypeOperators #-}
module Language.LSP.Server
( module Language.LSP.Server.Control
, VFSData(..)
, ServerDefinition(..)
-- * Handlers
, Handlers(..)
, Handler
, transmuteHandlers
, mapHandlers
, notificationHandler
, requestHandler
, ClientMessageHandler(..)
, Options(..)
, defau... | wz1000/haskell-lsp | lsp/src/Language/LSP/Server.hs | mit | 1,139 | 0 | 5 | 228 | 209 | 147 | 62 | -1 | -1 |
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE TypeFamilies #-}
module Data.Modable.Tests where
import Data.Maybe (isNothing)
import Data.Modable
import Test.Framework
import Test.Framework.Providers.QuickCheck2
import Test.QuickCheck
testModable :: forall a b.
( Eq a, Show a, ... | Soares/Dater.hs | test/Data/Modable/Tests.hs | mit | 980 | 0 | 13 | 233 | 388 | 208 | 180 | 26 | 2 |
{-# LANGUAGE DeriveAnyClass #-}
{-# LANGUAGE DeriveGeneric #-}
module HttpApp.BotKey.Api.Types where
import Data.Aeson (FromJSON, ToJSON)
import GHC.Generics (Generic)
import HttpApp.BotKey.Types (BotKey, Label, Secret)
data BKNewResp = BKNewResp
{ _nrespBotKey ::... | rubenmoor/skull | skull-server/src/HttpApp/BotKey/Api/Types.hs | mit | 749 | 0 | 9 | 168 | 189 | 114 | 75 | 22 | 0 |
module Main.DB
(
session,
oneRow,
unit,
integerDatetimes,
serverVersion,
)
where
import Main.Prelude hiding (unit)
import Control.Monad.Trans.Reader
import Control.Monad.IO.Class
import qualified Database.PostgreSQL.LibPQ as LibPQ
import qualified Data.ByteString as ByteString; import Data.ByteString (ByteSt... | nikita-volkov/postgresql-binary | tasty/Main/DB.hs | mit | 2,908 | 0 | 20 | 724 | 872 | 447 | 425 | -1 | -1 |
{-# LANGUAGE OverloadedStrings #-}
-- | Entry point to the Post Correspondence Programming Language
module Language.PCPL
( module Language.PCPL.Syntax
, module Language.PCPL.Pretty
, module Language.PCPL.CompileTM
-- * Execute PCPL programs
, runProgram
-- * Utility
, topString
-- * E... | davidlazar/PCPL | src/Language/PCPL.hs | mit | 2,530 | 0 | 11 | 634 | 745 | 470 | 275 | 53 | 1 |
module Ch2 where
import Test.QuickCheck
import Test.Hspec
ch2 :: IO ()
ch2 = hspec $ do
describe "_______________________Chapter 2 tests_______________________" $ do
it "should have tests" $ do
True
| Kiandr/CrackingCodingInterview | Haskell/src/chapter-2/Ch2.hs | mit | 214 | 0 | 13 | 44 | 56 | 28 | 28 | 8 | 1 |
{-# OPTIONS_HADDOCK show-extensions #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE GADTs #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE DataKinds #-}
{-|
Module : Data.Nat.Peano
Description : Peano natural numbers
Copyright : (c) Lars Brünjes, 2016
License : MIT
Maintainer : [email protected]
Stability ... | brunjlar/heap | src/Data/Nat/Peano.hs | mit | 2,067 | 32 | 10 | 650 | 603 | 315 | 288 | 57 | 0 |
{-# OPTIONS_GHC -fglasgow-exts -fallow-undecidable-instances #-}
{-| This library provides a collection of monad transformers that
can be combined to produce various monads.
-}
module MonadLibMorph (
-- * Types
-- $Types
Id, Lift, ReaderT, WriterT, StateT, ExceptionT, ContT,
-- * Lifting
-- $Lifting
M... | yav/monadlib | experimental/MonadLibMorph.hs | mit | 17,481 | 0 | 15 | 4,745 | 6,379 | 3,353 | 3,026 | -1 | -1 |
import Data.Char (digitToInt)
main = print problem40Value
problem40Value :: Int
problem40Value = d1 * d10 * d100 * d1000 * d10000 * d100000 * d1000000
where d1 = digitToInt $ list !! 0
d10 = digitToInt $ list !! 9
d100 = digitToInt $ list !! 99
d1000 = digitToInt $ list !! 999
... | jchitel/ProjectEuler.hs | Problems/Problem0040.hs | mit | 496 | 8 | 19 | 158 | 181 | 87 | 94 | 12 | 1 |
{-# LANGUAGE MultiWayIf #-}
{-# LANGUAGE OverloadedStrings #-}
module Arith where
import Control.Exception
import Data.Int
import Data.Text as T
type T = Int64
zero :: T
zero = 0
neg :: T -> T
neg x | x == minBound = throw Overflow
| otherwise = -x
add :: T -> T -> T
add x y =
if | p x && p y && n sum -> t... | gip/cinq-cloches-ledger | src/Arith.hs | mit | 1,475 | 0 | 14 | 486 | 642 | 325 | 317 | 45 | 4 |
module TestLib (mkTestSuite, run, (<$>)) where
import Test.HUnit
import AsciiMath hiding (run)
import Prelude hiding ((<$>))
import Control.Applicative ((<$>))
unComment :: [String] -> [String]
unComment [] = []
unComment ("":ss) = "" : unComment ss
unComment (('#':_):ss) = unComment ss
unComment (s:ss) = s : unComme... | Kerl13/AsciiMath | tests/TestLib.hs | mit | 1,037 | 0 | 13 | 214 | 445 | 235 | 210 | 28 | 2 |
module Language.Egison.Typing where
import Data.Set (Set)
import qualified Data.Set as S
import Data.Map (Map)
import qualified Data.Map as M
import Language.Egison.Types
-- I will deprecate this synonym
type EgisonType = EgisonTypeExpr
type TypeVar = String
type ConsName = String
data TypeCons = TCons ConsName -- N... | tokiwoousaka/egison4 | hs-src/Language/Egison/Typing.hs | mit | 504 | 1 | 7 | 103 | 124 | 80 | 44 | -1 | -1 |
-- | Utility functions for dealing with the conversion of Output to Xml
module Util.Xml.Output (
outputToXmlString,
stringToXmlString,
xmlStringToOutput,
outputToXOutput
) where
import qualified Util.Xml.OutputDTD as X
import qualified Autolib.Output as O
import Util.Xml.Representation
-- import Tex... | marcellussiegburg/autotool | server-interface/src/Util/Xml/Output.hs | gpl-2.0 | 4,780 | 0 | 17 | 1,211 | 1,608 | 823 | 785 | 102 | 15 |
-- |
-- Module : Setup
-- Copyright : (C) 2007-2008 Bryan O'Sullivan
-- (C) 2012-2014 Jens Petersen
--
-- Maintainer : Jens Petersen <[email protected]>
-- Stability : alpha
-- Portability : portable
--
-- Explanation: Command line option processing for building RPM
-- packages.... | opensuse-haskell/cabal-rpm | src/Setup.hs | gpl-3.0 | 6,406 | 0 | 28 | 1,797 | 1,545 | 858 | 687 | 124 | 2 |
{-# LANGUAGE Trustworthy #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# OPTIONS -Wall -fno-warn-unused-binds #-}
-----------------------------------------------------------------------------
-- |
-- Module : Data.Fixed
-- Copyright : (c) Ashley Yakeley 2005, 2006, 2009
-- Lic... | jwiegley/ghc-release | libraries/base/Data/Fixed.hs | gpl-3.0 | 7,207 | 0 | 15 | 1,558 | 2,296 | 1,207 | 1,089 | 147 | 2 |
{-# LANGUAGE MultiParamTypeClasses, KindSignatures, TypeFamilies #-}
-----------------------------------------------------------------------------
-- |
-- Module : Numerical.Petsc.Internal.Mutable
-- Copyright : (c) Marco Zocca 2015
-- License : LGPL3
-- Maintainer : zocca . marco . gmail . com
-- Stabi... | ocramz/petsc-hs | src/Numerical/PETSc/Internal/Mutable.hs | gpl-3.0 | 2,823 | 0 | 12 | 732 | 322 | 193 | 129 | 17 | 0 |
{-# 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/SecurityPolicies/GetRule.hs | mpl-2.0 | 4,091 | 0 | 17 | 943 | 494 | 291 | 203 | 80 | 1 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators ... | brendanhay/gogol | gogol-bigquery/gen/Network/Google/Resource/BigQuery/Models/Patch.hs | mpl-2.0 | 3,776 | 0 | 17 | 944 | 543 | 322 | 221 | 86 | 1 |
{-# LANGUAGE RecordWildCards #-}
-- | 'Ktx' is the only format can handle all sorts of textures available
-- among OpenGL [ES] implementations. This library holds any Texture as 'Ktx'
-- internally.
module Graphics.TextureContainer.KTX where
import Control.Applicative
import Control.Exception
import Control.Monad
impor... | capsjac/opengles | src/Graphics/TextureContainer/KTX.hs | lgpl-3.0 | 4,142 | 7 | 22 | 848 | 742 | 394 | 348 | 56 | 2 |
-- | To represent a "package-name.cabal" file.
-- We only care about the dependencies, but we also need to preserve
-- everything else (including the whitespace!) because we will write the file
-- back to disk and we don't want to obliterate the user's indentation style.
module CabalFile.Types where
import Data.... | gelisam/cabal-rangefinder | src/CabalFile/Types.hs | unlicense | 1,179 | 0 | 11 | 220 | 282 | 152 | 130 | -1 | -1 |
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE OverloadedStrings #-}
module Spark.Core.GroupsSpec where
import Test.Hspec
import Data.Text(Text)
import Spark.Core.Context
import Spark.Core.Functions
import Spark.Core.ColumnFunctions
import Spark.Core.Column
import Spark.Core.IntegrationUtilities
import Spark.Co... | krapsh/kraps-haskell | test-integration/Spark/Core/GroupsSpec.hs | apache-2.0 | 915 | 0 | 13 | 181 | 336 | 179 | 157 | 30 | 1 |
sequence' :: Monad m => [m a] -> m [a]
sequence' [] = return []
sequence' (m:ms) = m >>= \ a -> do as <- sequence' ms
return (a: as)
sequence'' ms = foldr func (return []) ms
where
func :: (Monad m) => m a -> m [a] -> m [a]
func m acc = do x <- m
xs <- a... | dongarerahul/edx-haskell | chapter-8-hw.hs | apache-2.0 | 2,479 | 4 | 12 | 1,016 | 1,251 | 608 | 643 | 54 | 2 |
import Controller (withOR)
import System.IO (hPutStrLn, stderr)
import Network.Wai.Middleware.Debug (debug)
import Network.Wai.Handler.Warp (run)
main :: IO ()
main = do
let port = 3000
hPutStrLn stderr $ "Application launched, listening on port " ++ show port
withOR $ run port . debug
| snoyberg/orangeroster | test.hs | bsd-2-clause | 300 | 0 | 9 | 55 | 101 | 54 | 47 | 9 | 1 |
-- |Interactions with the user.
module Ovid.Interactions
( tell
, options
) where
import Ovid.Prelude
import qualified System.Console.Editline.Readline as R
-- |Prompt the user.
tell s = liftIO (putStrLn s)
-- |Asks the user to pick an item from a list.
options :: (MonadIO m, Show a) => [a] -> m a
options xs ... | brownplt/ovid | src/Ovid/Interactions.hs | bsd-2-clause | 972 | 0 | 20 | 329 | 293 | 146 | 147 | 25 | 3 |
-- | Helper functions for dealing with text values
module Language.Terraform.Util.Text(
template,
show
) where
import Prelude hiding(show)
import qualified Prelude(show)
import qualified Data.Text as T
show :: (Show a) => a -> T.Text
show = T.pack . Prelude.show
-- | `template src substs` will replace all occu... | timbod7/terraform-hs | src/Language/Terraform/Util/Text.hs | bsd-3-clause | 547 | 0 | 13 | 106 | 178 | 102 | 76 | 11 | 1 |
module Validations.Types
( module Validations.Types.Checker
) where
import Validations.Types.Checker
| mavenraven/validations | src/Validations/Types.hs | bsd-3-clause | 106 | 0 | 5 | 14 | 21 | 14 | 7 | 3 | 0 |
{-# LANGUAGE OverloadedStrings #-}
module Futhark.Compiler
(
runPipelineOnProgram
, runCompilerOnProgram
, runPipelineOnSource
, interpretAction'
, FutharkConfig (..)
, newFutharkConfig
, dumpError
)
where
import Data.Monoid
import Control.Monad
import C... | mrakgr/futhark | src/Futhark/Compiler.hs | bsd-3-clause | 4,305 | 0 | 16 | 1,127 | 1,138 | 571 | 567 | 112 | 2 |
{-# LANGUAGE OverloadedStrings,GADTs,DeriveDataTypeable,DeriveFunctor,GeneralizedNewtypeDeriving,MultiParamTypeClasses,QuasiQuotes,TemplateHaskell,TypeFamilies,PackageImports,NamedFieldPuns,RecordWildCards,TypeSynonymInstances,FlexibleContexts #-}
module Main where
import Data.Crawler
import Data.C... | tkemps/bcbs-crawler | src/BcbsCrawler-old.hs | bsd-3-clause | 13,475 | 0 | 35 | 5,011 | 3,673 | 1,866 | 1,807 | 287 | 6 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# OPTIONS_GHC -fno-warn-orphans #-}
module Main where
import System.Remote.Monitoring
import Web.Auth.OAuth2
import Web.Auth.Service
import Web.Orion
import Web.Scotty.Trans
import Web.Temp... | schell/orion | src/Main.hs | bsd-3-clause | 4,457 | 0 | 21 | 1,883 | 680 | 341 | 339 | 66 | 2 |
{-# LANGUAGE DeriveAnyClass #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DeriveFunctor #-}
module Data.Queue (
Queue
, empty, singleton, fromList
, toList, enqueue, dequeue, enqueueAll
) where
import Control.DeepSeq (NFData)
import GHC.Generics (Generic)
data Queue a = Q [a] [a]
deriving (Show, Eq, Functor,... | stefan-hoeck/labeled-graph | Data/Queue.hs | bsd-3-clause | 898 | 0 | 10 | 224 | 454 | 237 | 217 | -1 | -1 |
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE FlexibleInstances #-}
{-# OPTIONS_GHC -fno-warn-orphans #-}
{-# LANGUAGE CPP #-}
#if __GLASGOW_HASKELL__ >= 800
{-# OPTIONS_GHC -fno-warn... | cdornan/idiot | Text/RE/PCRE/ByteString.hs | bsd-3-clause | 2,516 | 0 | 8 | 658 | 484 | 287 | 197 | 50 | 1 |
module SlaeGauss where
import Data.Bifunctor
import qualified Data.Matrix as Mx
import qualified Data.Vector as Vec
import Library
compute :: Matrix -> Either ComputeError Vector
compute = fmap backtrackPermuted . triangulate
where
backtrackPermuted (mx, permutations) =
Ve... | hrsrashid/nummet | lib/SlaeGauss.hs | bsd-3-clause | 2,689 | 0 | 13 | 749 | 1,141 | 595 | 546 | 58 | 2 |
module Paths_variants (
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 -> IO a) ... | josephDunne/variants | dist/build/autogen/Paths_variants.hs | bsd-3-clause | 1,313 | 0 | 10 | 177 | 362 | 206 | 156 | 28 | 1 |
{-# LANGUAGE PatternSignatures #-}
module Main where
import GHC.Conc
import Control.Exception
import Foreign.StablePtr
import System.IO
import GHC.Conc.Sync (atomicallyWithIO)
inittvar :: STM (TVar String)
inittvar = newTVar "Hello world"
deadlock0 :: STM String
deadlock0 = retry
deadlock1 :: TVar String -> STM Str... | mcschroeder/ghc | libraries/base/tests/Concurrent/stmio047.hs | bsd-3-clause | 1,402 | 0 | 17 | 438 | 386 | 192 | 194 | 30 | 2 |
{-# LANGUAGE RecordWildCards #-}
module Main (main) where
import GeoLabel (toString, fromString')
import GeoLabel.Strings (format, parse)
import GeoLabel.Strings.Wordlist (wordlist)
import GeoLabel.Geometry.QuadTree (Subface(A,B,C,D))
import GeoLabel.Geometry.Point (lengthOf, (<->))
import GeoLabel.Geometry.Conversio... | wyager/GeoLabel | src/GeoLabel/Test.hs | bsd-3-clause | 2,776 | 0 | 15 | 535 | 947 | 535 | 412 | 55 | 2 |
{-|
Module : Reactive.DOM.Children.MonotoneList
Description : Definition of the MonotoneList children container.
Copyright : (c) Alexander Vieth, 2016
Licence : BSD3
Maintainer : [email protected]
Stability : experimental
Portability : non-portable (GHC only)
-}
{-# LANGUAGE StandaloneDeriving #-}
{-# LA... | avieth/reactive-dom | Reactive/DOM/Children/MonotoneList.hs | bsd-3-clause | 1,438 | 0 | 12 | 250 | 302 | 166 | 136 | 24 | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.