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 CPP #-}
-- (c) Rahul Muttineni 2016-2017
-- (c) The University of Glasgow 2002-2006
--
{-# OPTIONS_GHC -O #-}
-- We always optimise this, otherwise performance of a non-optimised
-- compiler is severely affected
-- | Binary interface file support.
module ETA.Iface.BinIface (
writeBinIface,
... | pparkkin/eta | compiler/ETA/Iface/BinIface.hs | bsd-3-clause | 16,373 | 0 | 19 | 4,533 | 3,590 | 1,825 | 1,765 | 282 | 11 |
{-# LANGUAGE Haskell98, CPP, BangPatterns, DeriveGeneric #-}
{-# LINE 1 "src/Text/PrettyPrint/HughesPJ.hs" #-}
{-# OPTIONS_HADDOCK not-home #-}
{-# LANGUAGE Safe #-}
{-# LANGUAGE DeriveGeneric #-}
----------------------------------------------------------------------... | phischu/fragnix | tests/packages/scotty/Text.PrettyPrint.HughesPJ.hs | bsd-3-clause | 13,159 | 0 | 12 | 3,133 | 2,371 | 1,388 | 983 | 208 | 1 |
module Main where
import System.Exit (ExitCode(..), exitSuccess, exitWith)
import Control.Monad (unless, when, (>=>))
import Data.Foldable (foldrM)
import Data.Maybe (fromMaybe)
import Idris.AbsSyntax
import Idris.CmdOptions
import Idris.Error
import Idris.Info.Show
import Idris.Main
import Idris.Options
import Idri... | Heather/Idris-dev | main/Main.hs | bsd-3-clause | 3,009 | 0 | 18 | 676 | 953 | 484 | 469 | 68 | 4 |
{-# LANGUAGE DeriveDataTypeable #-}
module Text.Peggy.SrcLoc (
SrcLoc(..),
SrcPos(..),
advance,
) where
import Data.Data
data SrcLoc
= LocPos !SrcPos
| LocSpan !SrcPos !SrcPos
deriving (Show, Eq, Ord, Typeable, Data)
data SrcPos =
SrcPos
{ locFile :: !FilePath
, locAbs :: {-# UNPACK #-} !In... | tanakh/Peggy | Text/Peggy/SrcLoc.hs | bsd-3-clause | 711 | 0 | 16 | 189 | 299 | 165 | 134 | 33 | 3 |
{-
some instances for printing the StgSyn AST in Haskell syntax.
-}
{-# LANGUAGE CPP #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE StandaloneDeriving #-}
module Gen2.StgAst where
import Data.Char (isSpace)
import qualified Data.Foldable as F
... | flowbox-public/ghcjs | src/Gen2/StgAst.hs | mit | 5,509 | 0 | 17 | 1,353 | 1,679 | 854 | 825 | -1 | -1 |
{-# LANGUAGE RecordWildCards #-}
module Tinc.Cabal where
import qualified Tinc.Nix as Nix
import Tinc.Facts
cabal :: Facts -> [String] -> (String, [String])
cabal facts@Facts{..}
| factsUseNix = Nix.cabal facts
| otherwise = (,) "cabal"
| sol/tinc | src/Tinc/Cabal.hs | mit | 253 | 0 | 8 | 50 | 88 | 49 | 39 | 8 | 1 |
<?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="ms-MY">
<title>AdvFuzzer Add-On</title>
<maps>
<homeID>top</homeID>
<mapref location="m... | thc202/zap-extensions | addOns/fuzz/src/main/javahelp/org/zaproxy/zap/extension/fuzz/resources/help_ms_MY/helpset_ms_MY.hs | apache-2.0 | 961 | 89 | 29 | 156 | 393 | 211 | 182 | -1 | -1 |
{-# LANGUAGE CPP #-}
-- ----------------------------------------------------------------------------
-- | Base LLVM Code Generation module
--
-- Contains functions useful through out the code generator.
--
module LlvmCodeGen.Base (
LlvmCmmDecl, LlvmBasicBlock,
LiveGlobalRegs,
LlvmUnresData, L... | shlevy/ghc | compiler/llvmGen/LlvmCodeGen/Base.hs | bsd-3-clause | 20,855 | 0 | 19 | 4,783 | 4,194 | 2,243 | 1,951 | 293 | 6 |
{-# LANGUAGE NoRelaxedLayout #-}
module ShouldFail where
-- Erroneously allowed by GHC 6.2.x
f x = case x of
False -> do
{ return x; }
-- this line should close the 'case' context and cause the 'do' to be empty.
-- Update: arguably this should be allowed. The fix to the Haskell
-- layout rule to allow ... | ezyang/ghc | testsuite/tests/parser/should_fail/readFail027.hs | bsd-3-clause | 554 | 0 | 10 | 119 | 39 | 25 | 14 | -1 | -1 |
-- Check error message for groups if we don't have the right extension turned on
module Foo where
import Data.List
import GHC.Exts
foo = [ ()
| x <- [1..10]
, then group by x using groupWith
, then group by x using groupWith
, then group using inits
]
| tibbe/ghc | testsuite/tests/parser/should_fail/readFail043.hs | bsd-3-clause | 300 | 0 | 8 | 98 | 62 | 36 | 26 | 8 | 1 |
{-# LANGUAGE EmptyDataDecls, TypeFamilies, TypeOperators, ScopedTypeVariables #-}
module Overflow where
import Control.Concurrent
data (:*:) a b
data (:+:) a b
data family PChan a
data instance PChan (a :+: b) = E (IO (PChan a)) (IO (PChan b))
newtype instance PChan (a :*: b) = O (IO (Either (PChan a) (PChan b)))
... | siddhanathan/ghc | testsuite/tests/indexed-types/should_fail/T2664.hs | bsd-3-clause | 1,353 | 0 | 12 | 346 | 371 | 200 | 171 | -1 | -1 |
import Data.List
data Colour = Black | White deriving (Show)
data Image = Image { width :: Int, height :: Int, pixels :: [[Colour]] } deriving (Show)
type Vec3 = (Float, Float, Float)
data Object = Sphere Vec3 Float deriving (Show)
-- PBM file support
colourToPBM :: Colour -> String
colourToPBM Black = "1"
colourToP... | jeremyroman/hsray | ray.hs | mit | 2,529 | 1 | 12 | 621 | 1,142 | 611 | 531 | 58 | 2 |
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE QuasiQuotes #-}
{-# LANGUAGE TemplateHaskell #-}
module Handler.Home where
import Foundation
import Yesod.Core
import Yesod.Persist
import Model
getHomeR :: Handler Html
getHomeR = do
pasteEnt <- runDB $ selectList [] [ LimitTo 20, Desc PasteTimestamp ]
... | cuklev/huseless-pastebin | src/Handler/Home.hs | mit | 454 | 0 | 12 | 93 | 105 | 53 | 52 | 15 | 1 |
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
-- |
-- Module: Network.SIP.Parser.RequestMethod
-- Description: Request method parser.
-- Copyright: Copyright (c) 2015-2016 Jan Sipr
-- License: MIT
module Network.SIP.Parser.RequestMethod
( requestMethodParser
)
where
imp... | Siprj/ragnarok | src/Network/SIP/Parser/RequestMethod.hs | mit | 887 | 0 | 10 | 126 | 204 | 125 | 79 | 15 | 1 |
module Day12 where
import Data.List.Split
import Data.Char
import Data.List
part1 = do
txt <- readFile "lib/day12-input.txt"
let res = sumUp txt
print res
delims '\"' = False
delims '}' = False
delims '{' = False
delims ':' = False
delims ']' = False
delims '[' = False
delims x
| isAlpha x = False
deli... | cirquit/Personal-Repository | Haskell/Playground/AdventOfCode/advent-coding/src/Day12.hs | mit | 2,538 | 0 | 15 | 935 | 1,121 | 583 | 538 | 61 | 6 |
{-# htermination fromEnum :: () -> Int #-}
| ComputationWithBoundedResources/ara-inference | doc/tpdb_trs/Haskell/full_haskell/Prelude_fromEnum_2.hs | mit | 43 | 0 | 2 | 8 | 3 | 2 | 1 | 1 | 0 |
module Control.Flower.Apply (
module Control.Flower.Apply.Lazy,
module Control.Flower.Apply.Strict
) where
import Control.Flower.Apply.Lazy
import Control.Flower.Apply.Strict
| expede/flower | src/Control/Flower/Apply.hs | mit | 180 | 0 | 5 | 18 | 39 | 28 | 11 | 5 | 0 |
module Interpreter.Evaluator
( eval
, evalSequence
) where
import Interpreter.DataTypes
-- The "eval" function is the heart of the evaluator. It takes an environment
-- with variable bindings and a Lisp Expression to evaluate. The Expression is
-- evaluated returning a new environment, possibly containing new bindings... | IvanIvanov/haskell-lisp-interpreter | src/Evaluator.hs | mit | 3,335 | 0 | 14 | 628 | 911 | 480 | 431 | 58 | 4 |
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE OverloadedStrings #-}
module Data.Aeson.Traversal
( module Data.Aeson.Traversal.Value
, module Data.Aeson.Traversal.Primitive
, integer
, double
, integralv
, nonNull
, primitive
, primitive'
, key
, nth
, decoded
) where
import Prelude hiding(null)
--... | statusfailed/aeson-traversal | src/Data/Aeson/Traversal.hs | mit | 2,441 | 0 | 11 | 453 | 551 | 323 | 228 | 51 | 3 |
{-# LANGUAGE FlexibleContexts, OverloadedStrings #-}
-- | An API for creating and fetching Gists from GitHub. Most of the functions
-- here have very generic types over monad typeclasses; it may be helpful to
-- note that for the most part either 'ResourceT' 'IO' or 'IO' will fit
-- depending on if the resulting monad ... | jhance/github | Web/GitHub/Gist.hs | mit | 11,818 | 0 | 25 | 3,074 | 2,463 | 1,331 | 1,132 | 206 | 2 |
module Main where
import Build.Derive.List()
main = return()
| sboosali/derive-monoid | test/Tests.hs | mit | 64 | 0 | 6 | 11 | 23 | 14 | 9 | 3 | 1 |
module AnsibleModules.Pip where
import Data.Monoid
import Data.Sansible.Playbook
import Data.Sansible
import qualified Data.Text as T
import qualified Data.Aeson.TH as A
data State = Present | Absent | Latest
$(A.deriveToJSON encodingOptions ''State)
type PackageName = T.Text
type Version = T.Text
data P... | ostapneko/sansible | src/AnsibleModules/Pip.hs | mit | 1,555 | 0 | 10 | 573 | 368 | 212 | 156 | -1 | -1 |
{-# LANGUAGE OverloadedStrings, FlexibleInstances, UndecidableInstances #-}
{-# LANGUAGE ScopedTypeVariables, TypeOperators, GADTs, FlexibleContexts #-}
{-# LANGUAGE DeriveGeneric, GeneralizedNewtypeDeriving, TypeFamilies, CPP #-}
{-# LANGUAGE DataKinds #-}
{-# OPTIONS_GHC -fno-warn-orphans #-}
-- | Selda is not LINQ, ... | valderman/selda | selda/src/Database/Selda.hs | mit | 15,772 | 0 | 13 | 3,463 | 4,344 | 2,440 | 1,904 | -1 | -1 |
-- | UIVars, settable and gettable properties in the `UIAction` monad.
--
module Graphics.UI.UIVar
( UIVar()
, UIVar'
, uivar
, (<--)
, readVar )
where
import Graphics.UI.Internal
import Data.Profunctor
-- | `UIVar` is something you can get and set but those actions require
-- `UIAction` mona... | Noeda/userinterface | src/Graphics/UI/UIVar.hs | mit | 998 | 0 | 13 | 259 | 296 | 164 | 132 | 32 | 1 |
{-# LANGUAGE OverloadedStrings #-}
-- | Everything to do with formatting text.
--
-- In general, functions should be added here, rather than formatting
-- implemented ad-hoc elsewhere, to maintain consistency.
module Imageboard.Formatting
( -- * Thing names
formatThreadName
, formatPostName
, formatAttachmen... | barrucadu/nagi | lib/Imageboard/Formatting.hs | mit | 4,471 | 0 | 15 | 824 | 1,051 | 563 | 488 | 82 | 3 |
{- |
Module : ./CommonLogic/PredefinedCASLAxioms.hs
Description : Central datastructures for development graphs
Copyright : (c) Till Mossakowski, Uni Bremen 2002-2006
License : GPLv2 or higher, see LICENSE.txt
Maintainer : till@informatik.uni-bremen.de
Stability : provisional
Portability : non-port... | spechub/Hets | CommonLogic/PredefinedCASLAxioms.hs | gpl-2.0 | 4,162 | 0 | 13 | 1,106 | 1,079 | 592 | 487 | 120 | 1 |
{-# LANGUAGE QuasiQuotes #-}
module Ocram.Print.Test
-- export {{{1
(
tests
) where
-- import {{{1
import Data.List (nub)
import Language.C.Syntax.AST (CTranslUnit)
import Ocram.Analysis (analysis, Analysis(..))
import Ocram.Print (render_with_log)
import Ocram.Test.Lib (enumTestGroup, lpaste, enrich, reduce, TBreak... | copton/ocram | ocram/src/Ocram/Print/Test.hs | gpl-2.0 | 21,250 | 0 | 11 | 6,978 | 2,635 | 1,638 | 997 | 177 | 2 |
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
module Util.UnionSolve(
C(),
solve,
Fixable(..),
Topped(..),
Result(..),
cAnnotate,
islte,isgte,equals,
(@<=),(@>=),(@=),(@<=@),(@>=@),(@=@)
) where
import Control.Monad(unless, forM_)
import Data.List(intersperse)
import Data.Monoid
impor... | dec9ue/jhc_copygc | src/Util/UnionSolve.hs | gpl-2.0 | 14,296 | 38 | 33 | 4,877 | 6,022 | 3,078 | 2,944 | -1 | -1 |
{-|
This module implements transformations which take the form of
replacing parts of a model with new parts.
Generally names with either parts or other names.
-}
module Language.Pepa.Transform.Replace
( -- * Renaming processes
ProcessRename
, ProcessRenameMap
, replaceComponentNames
, renameC... | allanderek/ipclib | Language/Pepa/Transform/Replace.hs | gpl-2.0 | 10,169 | 0 | 15 | 2,186 | 1,786 | 958 | 828 | 158 | 2 |
-- ParesCriticos.hs
-- Implementación de los pares críticos
-- Sevilla, 6 de Noviembre de 2016
-- ------------------------------------------------------------------
module ParesCriticos where
import Terminos
-- | (indiceMaximo t) es el mayor índice que aparece en t. Por ejemplo,
-- >>> indiceMaximo (V ("x",3)... | migpornar/SRTenHaskell | Codigo_Haskell/ParesCriticos.hs | gpl-3.0 | 4,627 | 0 | 18 | 1,072 | 797 | 451 | 346 | 35 | 3 |
module GameActionParser (parseGameAction) where
import Data.Char (isDigit)
import Data.Maybe (listToMaybe)
import DataTypes
import Text.ParserCombinators.ReadP
( ReadP,
many1,
readP_to_S,
satisfy,
string,
choice
)
parseGameAction :: String -> Maybe GameAction
parseGameAction = listToMaybe . ma... | MoritzR/CurseOfDestiny | src/GameActionParser.hs | gpl-3.0 | 1,279 | 0 | 8 | 240 | 369 | 188 | 181 | 49 | 1 |
module Dist where
import Data.List
import Data.Set (Set)
import qualified Data.Set as Set
import Data.Map (Map)
import qualified Data.Map as Map
import Utils
import Rel
import Syntax
data Dist = Dist (Rel Name Name) deriving (Eq, Ord)
showDist:: Dist -> String
showDist (Dist d) = concats $ intersperse "," (fold... | fredokun/piexplorer | src/Dist.hs | gpl-3.0 | 3,013 | 0 | 13 | 708 | 1,236 | 621 | 615 | 62 | 2 |
do x <- [1,2,3]
y <- [1,2,3]
True <- return (x /= y)
return (x,y)
| kuitang/damon | inc.hs | unlicense | 76 | 0 | 10 | 25 | 65 | 33 | 32 | -1 | -1 |
module Main where
import Data.List
import Text.ParserCombinators.Parsec
data Expr = Atom String
| List [Expr]
deriving (Eq, Show)
mkTrue = Atom "true"
mkFalse = Atom "false"
isTrue (Atom "true") = True
isTrue otherwise = False
isFalse (Atom "false") = True
isFalse otherwise = False
mkLambda params body... | ulan/hisp | level0/Hisp0.hs | unlicense | 3,093 | 0 | 16 | 974 | 1,501 | 755 | 746 | 74 | 14 |
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
module Bantam.Service.Path (
encodedPath
, encodedPathText
, loginPath
, registrationPath
, imgPath
, cssPath
, fightsPath
, fightPath
, lemmasPath
, currentLemmaPath
, lemmaPath
, reviewPath
) where
import Bant... | charleso/bantam | bantam-service/src/Bantam/Service/Path.hs | unlicense | 1,742 | 0 | 8 | 363 | 471 | 265 | 206 | 61 | 1 |
ham :: (Integral a) => a -> a
ham a
| a == 1 = 1
| otherwise = (mod a 2) + ham (div a 2)
| ccqpein/Arithmetic-Exercises | Number-of-1-Bits/No1B.hs | apache-2.0 | 93 | 1 | 8 | 31 | 72 | 34 | 38 | 4 | 1 |
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE TypeFamilies #-}
-- | Data types for K3 dataflow provenance
module Language.K3.Analysis.Provenance.Core where
import Control.DeepSeq
import GHC.Generics (Generic)
import Data.List
import Data.Tree
impor... | yliu120/K3 | src/Language/K3/Analysis/Provenance/Core.hs | apache-2.0 | 3,800 | 0 | 18 | 1,009 | 898 | 495 | 403 | 73 | 1 |
isParenthesised :: [Char] -> Bool
isParenthesised str = str !! 0 == '(' && str !! ((length str) - 1) == ')'
slice :: Int -> Int -> [a]
slice from to xs = take (to - from + 1) (drop from xs)
parseExpr :: [Char] -> [[Char]]
parseExpr expr
| not (isParenthesised expr) = error "s-expr.hs: expression isn't parenthesised... | joshhartigan/proglang | s-expr.hs | bsd-2-clause | 475 | 1 | 10 | 96 | 194 | 99 | 95 | 9 | 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.
{-# LANGUAGE GADTs #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE OverloadedStrings #-}
module Duckling.Temperatur... | facebookincubator/duckling | Duckling/Temperature/PT/Rules.hs | bsd-3-clause | 2,277 | 0 | 18 | 508 | 542 | 303 | 239 | 61 | 3 |
{-# LANGUAGE RecordWildCards #-}
module Data.ClassFile.MethodInfo
( MethodInfo (..)
, putMethodInfo
) where
import Control.Monad
import Data.Binary
import Data.Binary.Put
import Data.ClassFile.Access
import Data.ClassFile.AttributeInfo
data MethodInfo = MethodInfo
{ accessFlags... | sonyandy/tnt | Data/ClassFile/MethodInfo.hs | bsd-3-clause | 725 | 0 | 9 | 197 | 148 | 83 | 65 | 21 | 1 |
module Problem1Tests
( problem1Tests
) where
import Test.HUnit
import Problem1
testSolution1 :: Test
testSolution1 = TestCase $ do
assertEqual "(solution 1) sum of multiples of 3 and 5 below 10" 23 (solveProblem1 10)
assertEqual "(solution 2) sum of multiples of 3 and 5 below 10" 23 (solveProblem1' 10)
a... | candidtim/euler | test/Problem1Tests.hs | bsd-3-clause | 450 | 0 | 10 | 84 | 90 | 46 | 44 | 10 | 1 |
--
-- Module : System.MIDI
-- Version : 0.2.1
-- License : BSD3
-- Author : Balazs Komuves
-- Maintainer : bkomuves (plus) hackage (at) gmail (dot) com
-- Stability : experimental
-- Portability : not portable
-- Tested with : GHC 7.4.2
--
-- | A lowest common denominator interface to the Win32 a... | chpatrick/hmidi | System/MIDI.hs | bsd-3-clause | 5,446 | 0 | 8 | 934 | 663 | 400 | 263 | 64 | 1 |
{-# LANGUAGE TypeSynonymInstances #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE BangPatterns #-}
module LVM where
import LuaLoader
import LuaObjects
import qualified Data.Map.Strict as Map
import Control.Monad.ST as ST
import Data.Either
import Data.Maybe
import Data.STRef
import Data.Array.IArray as Array
imp... | AndreasPK/yalvm | src/LVM.hs | bsd-3-clause | 29,933 | 276 | 24 | 6,475 | 6,649 | 3,489 | 3,160 | 485 | 50 |
{-#LANGUAGE GADTs, StandaloneDeriving #-}
module Genome.Dna.Replication where
import Data.Map (Map, (!))
import Data.List (sortBy)
import qualified Data.Map as M
import Data.Set (Set)
import qualified Data.Set as Set
import Data.Maybe
import Genome.Dna.Dna
cummsum :: (Foldable t, Num a) => t a -> [a]
cummsum xs = re... | visood/bioalgo | src/lib/Genome/Dna/Replication.hs | bsd-3-clause | 1,173 | 0 | 12 | 279 | 491 | 271 | 220 | 26 | 3 |
{-# OPTIONS_GHC -funbox-strict-fields #-}
{-|
Module : Database.MySQL.Protocol.MySQLValue
Description : Text and binary protocol
Copyright : (c) Winterland, 2016
License : BSD
Maintainer : drkoster@qq.com
Stability : experimental
Portability : PORTABLE
Core text and binary row decoder/encoder machinery.... | winterland1989/mysql-haskell | Database/MySQL/Protocol/MySQLValue.hs | bsd-3-clause | 27,875 | 0 | 24 | 9,193 | 6,169 | 3,111 | 3,058 | -1 | -1 |
{-# LANGUAGE CPP #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE Trustworthy #-}
{-# LANGUAGE TypeOperators #-}
module Language.SexpGrammar.Base
( position
-- * Atoms
, real
, double
, int
, integer
, string... | esmolanka/sexp-grammar | sexp-grammar/src/Language/SexpGrammar/Base.hs | bsd-3-clause | 14,164 | 0 | 21 | 3,052 | 3,887 | 2,097 | 1,790 | 241 | 3 |
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE GADTs #-}
{-# LANGUAGE KindSignatures #-}
{-# LANGUAGE PolyKinds #-}
{-# LANGUAGE QuasiQuotes #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE ViewPatterns #-}
{-# LANGUAGE PatternGua... | eddywestbrook/hobbits | src/Data/Binding/Hobbits/NameSet.hs | bsd-3-clause | 6,073 | 4 | 15 | 1,169 | 1,786 | 967 | 819 | -1 | -1 |
module MakeConfig where
import System.Directory
import System.FilePath
import Text.Printf
import System.Console.Haskeline
import Control.Monad
import Data.ByteString.Char8 (ByteString(..), pack, unpack)
import Data.ByteString.Base64 (encode)
import Data.List (intercalate)
import Config
import Jira
main :: IO ()
mai... | candidtim/tempo | app/MakeConfig.hs | bsd-3-clause | 4,413 | 0 | 14 | 1,090 | 837 | 395 | 442 | 92 | 3 |
module BoolExpr.UnitTests.BoolExpr ( runTests ) where
import Test.HUnit
import BoolExpr.BoolExpr
import BoolExpr.Env as Env
runTests :: IO Counts
runTests = runTestTT tests
tests :: Test
tests = TestList
[ testEvalZero
, testEvalOne
, testEvalNot
, testEvalOneAndOne
, testEvalOneAndZero
, testEvalOneOrZ... | robrene/robdd-with-template-hs | test/BoolExpr/UnitTests/BoolExpr.hs | bsd-3-clause | 1,294 | 0 | 10 | 226 | 355 | 195 | 160 | 39 | 1 |
{-# LANGUAGE OverlappingInstances #-}
{-# OPTIONS_GHC -fno-warn-deprecated-flags #-}
module Database.PostgreSQL.PQTypes.Class (
MonadDB(..)
) where
import Control.Monad.Trans
import Control.Monad.Trans.Control
import Database.PostgreSQL.PQTypes.FromRow
import Database.PostgreSQL.PQTypes.Internal.Connection
impo... | scrive/hpqtypes | src/Database/PostgreSQL/PQTypes/Class.hs | bsd-3-clause | 3,822 | 0 | 12 | 704 | 469 | 276 | 193 | -1 | -1 |
{-|
Module : Game.GoreAndAsh.Network
Description : Network backend for TCP transport.
Copyright : (c) Anton Gushcha, 2015-2017
License : BSD3
Maintainer : ncrashed@gmail.com
Stability : experimental
Portability : POSIX
-}
module Game.GoreAndAsh.Network.Backend.TCP(
TCPBackend
, TCPPeer
-- * Option... | Teaspot-Studio/gore-and-ash-network | src/Game/GoreAndAsh/Network/Backend/TCP.hs | bsd-3-clause | 13,227 | 0 | 34 | 3,076 | 3,306 | 1,679 | 1,627 | -1 | -1 |
-- from Real World Haskell chapter 24
module Hisg.MapReduce
(
mapReduce
, simpleMapReduce
-- exported for convenience
, rnf
, rwhnf
) where
import Control.Parallel (pseq)
import Control.Parallel.Strategies
import Control.DeepSeq
{-- snippet simpleMapReduce.type --}
simpleMapReduce
::... | ane/hisg | src/Hisg/MapReduce.hs | bsd-3-clause | 1,185 | 0 | 11 | 291 | 214 | 127 | 87 | 26 | 1 |
module Main
where
import System.Environment
import System.Exit
import System.Console.GetOpt
import System.FilePath
import System.Directory
import System.IO (hPutStrLn, stderr)
import Data.Either
import Data.List
import Control.Monad
import Control.Monad.State
import HeaderParser
import HaskellGen
import Options
impor... | anttisalonen/cgen | src/CgenHs.hs | bsd-3-clause | 3,026 | 0 | 15 | 801 | 887 | 477 | 410 | 65 | 2 |
-- | Code for Saving and Rendering Annotations
{-# LANGUAGE OverloadedStrings #-}
module Language.Nano.Annots (
-- * Type for Annotation Map
AnnInfo
-- * Adding new Annotations
, addAnnot
-- * Rendering Annotations
, annotByteString
) where
import qualified Data.List ... | UCSD-PL/nano-js | Language/Nano/Annots.hs | bsd-3-clause | 6,633 | 0 | 17 | 1,740 | 1,688 | 917 | 771 | 93 | 1 |
{-# LANGUAGE JavaScriptFFI, GeneralizedNewtypeDeriving #-}
module GHCJS.Three.Light (
Light(..), mkLight,
AmbientLight(..), mkAmbientLight,
DirectionalLight(..), mkDirectionalLight, shadowCamera, lightTarget, setLightTarget,
setShadowCameraLeft, setShadowCameraRight,
setShadowCameraTop, setShadowCam... | manyoo/ghcjs-three | src/GHCJS/Three/Light.hs | bsd-3-clause | 4,791 | 94 | 7 | 734 | 1,159 | 621 | 538 | 87 | 1 |
{-# OPTIONS -F -pgmF lisk #-}
(module demo
"A demo program!")
(import data.char system.io (data.map :as map))
(:: main ('io ()))
(= main (do (<- line get-line)
(let (= the-line line)
(= some-map map.empty))
(case :do get-line
("" (put-str-ln "* * Empty!"))
... | haskell-lisp/historic-lisk | examples/Foo.hs | bsd-3-clause | 890 | 34 | 15 | 316 | 549 | 290 | 259 | -1 | -1 |
-- {-# OPTIONS_GHC -F -pgmF hspec-discover #-}
--------------------------------------------------
-- Imports ---------------------------------------
--------------------------------------------------
import "tasty" Test.Tasty
import "tasty-hunit" Test.Tasty.HUnit
import "tasty-quickcheck" Test.Tasty.Q... | sboosali/enumerate | enumerate/tests/UnitTests.hs | mit | 2,379 | 0 | 12 | 511 | 312 | 181 | 131 | -1 | -1 |
module GuardedGuard where
f | 3 = 5
| roberth/uu-helium | test/typeerrors/Examples/GuardedGuard.hs | gpl-3.0 | 37 | 0 | 7 | 9 | 15 | 8 | 7 | 2 | 1 |
{-
Copyright 2012-2015 Vidar Holen
This file is part of ShellCheck.
http://www.vidarholen.net/contents/shellcheck
ShellCheck 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... | icyfork/shellcheck | shellcheck.hs | gpl-3.0 | 11,625 | 150 | 24 | 3,281 | 2,549 | 1,415 | 1,134 | 275 | 9 |
{-# LANGUAGE OverloadedStrings #-}
-- Derived from AWS service descriptions, licensed under Apache 2.0.
-- |
-- Module : Network.AWS.Glacier.Types
-- Copyright : (c) 2013-2015 Brendan Hay
-- License : Mozilla Public License, v. 2.0.
-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
-- Stability : au... | olorin/amazonka | amazonka-glacier/gen/Network/AWS/Glacier/Types.hs | mpl-2.0 | 6,187 | 0 | 13 | 1,381 | 919 | 533 | 386 | 146 | 1 |
{-# LANGUAGE CPP #-}
-----------------------------------------------------------------------------------------
{-| Module : ParseC
Copyright : (c) Daan Leijen 2003
License : BSD-style
Maintainer : wxhaskell-devel@lists.sourceforge.net
Stability : provisional
Portability : portab... | jacekszymanski/wxHaskell | wxdirect/src/ParseC.hs | lgpl-2.1 | 12,584 | 0 | 51 | 3,300 | 3,722 | 1,782 | 1,940 | 280 | 3 |
<?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="hu-HU">
<title>Quick Start | ZAP Extension</title>
<maps>
<homeID>top</homeID>
<mapref... | msrader/zap-extensions | src/org/zaproxy/zap/extension/quickstart/resources/help_hu_HU/helpset_hu_HU.hs | apache-2.0 | 973 | 98 | 29 | 160 | 409 | 213 | 196 | -1 | -1 |
{-# OPTIONS_GHC -fno-warn-orphans #-}
module Application
( getApplicationDev
, appMain
, develMain
, makeFoundation
-- * for DevelMain
, getApplicationRepl
, shutdownApp
-- * for GHCI
, handler
) where
import Control.Monad.Logger (liftLoc)
import Import
import La... | mtesseract/ingscale-yesod | Application.hs | bsd-3-clause | 5,438 | 0 | 16 | 1,430 | 838 | 449 | 389 | -1 | -1 |
{-# LANGUAGE CPP #-}
{-# OPTIONS -fvectorise #-}
module CommonVectorised where
import Data.Array.Parallel.Prelude.Bool
import Data.Array.Parallel.Prelude.Double
import qualified Prelude as P
#include "Common.inc.hs"
| mainland/dph | dph-examples/examples/spectral/Pluecker/CommonVectorised.hs | bsd-3-clause | 220 | 0 | 4 | 26 | 29 | 23 | 6 | 6 | 0 |
module UU.Scanner.GenTokenOrd() where
import UU.Scanner.GenToken(GenToken(..))
instance (Eq key, Eq tp) => Eq (GenToken key tp val) where
Reserved x _ == Reserved y _ = x == y
ValToken tx _ _ == ValToken ty _ _ = tx == ty
_ == _ = False
instance (Ord key, Ord tp) => Ord ... | UU-ComputerScience/uulib | src/UU/Scanner/GenTokenOrd.hs | bsd-3-clause | 573 | 0 | 8 | 209 | 250 | 126 | 124 | 11 | 0 |
{-
(c) The University of Glasgow 2006
(c) The GRASP/AQUA Project, Glasgow University, 1992-1998
-}
{-# LANGUAGE CPP #-}
module Eta.TypeCheck.TcValidity (
Rank, UserTypeCtxt(..), checkValidType, checkValidMonoType,
expectedKindInCtxt,
checkValidTheta, checkValidFamPats,
checkValidInstance, validDerivPred,
che... | rahulmutt/ghcvm | compiler/Eta/TypeCheck/TcValidity.hs | bsd-3-clause | 55,911 | 425 | 23 | 15,649 | 8,087 | 4,355 | 3,732 | -1 | -1 |
-- {-# OPTIONS_GHC -fno-warn-redundant-constraints #-}
{-# LANGUAGE MultiParamTypeClasses, FunctionalDependencies,
FlexibleInstances, FlexibleContexts, UndecidableInstances #-}
-- Example of improvement, due to George Russel
module Folders where
data Folder = Folder
newtype SB x = SB x
newtype SS x = S... | rahulmutt/ghcvm | tests/suite/typecheck/compile/tc181.hs | bsd-3-clause | 1,280 | 0 | 12 | 291 | 326 | 173 | 153 | 23 | 1 |
module Snap.TestCommon where
------------------------------------------------------------------------------
import Control.Exception (try, SomeException)
import Control.Monad.Trans (lift)
import qualified Data.Text as T
import qualified GHC.Read ... | sopvop/snap | test/suite/Snap/TestCommon.hs | bsd-3-clause | 3,220 | 0 | 15 | 817 | 887 | 472 | 415 | -1 | -1 |
module Rules.Nofib where
import Base
import Expression
import Oracles.Setting
import Packages
import System.Environment
import System.Exit
nofibLogFile :: FilePath
nofibLogFile = "nofib-log"
-- | Rules for running the @nofib@ benchmark suite.
nofibRules :: Rules ()
nofibRules = do
root <- buildRootRules
--... | snowleopard/shaking-up-ghc | src/Rules/Nofib.hs | bsd-3-clause | 1,827 | 0 | 17 | 484 | 416 | 212 | 204 | 34 | 2 |
import Control.Applicative
import Control.Monad
import GHCJS.Marshal
import GHCJS.Foreign
import GHCJS.Types
import System.IO
import Control.Concurrent
import ConvertJS
import Entry
import Propositions
foreign import javascript unsafe "incredibleLogic_ = $1"
js_set_logic :: JSFun a -> IO ()
foreign import javas... | psibi/incredible | logic/js/JSInterface.hs | mit | 1,551 | 38 | 8 | 412 | 379 | 197 | 182 | 40 | 3 |
{- 12 coins puzzle.
You are given 12 coins and a balance scale. You are told that 11 of the coins
weight exactly the same as each other. 1 of the coins has a different weight
than the rest. You can take 3 measurements using the balance scale. Plan a
set of weighings that will enable you to find the odd coin as well as... | glguy/5puzzle | Coins.hs | isc | 3,620 | 0 | 14 | 773 | 1,023 | 535 | 488 | 66 | 2 |
{- |
Module : SettingsTypes
Description : Types for program configuration and structure
-}
module SettingsTypes (
L10n
, CLArgs (..)
, L10nScheme (..)
, Game (..), IsGame (..)
, IsGameData (..)
, IsGameState (..)
, Settings (..)
, setGameL10n
, PP, PPT
, ... | HairyDude/pdxparse | src/SettingsTypes.hs | mit | 16,661 | 0 | 16 | 4,248 | 3,594 | 1,953 | 1,641 | -1 | -1 |
module Escrita
( exec
, f
, f'
, qs
, qs'
) where
f x = case x of { 0 -> 1; 1 -> 5; 2 -> 2; _ -> 1}
f' x = case x of
0 -> 1
1 -> 5
2 -> 2
_ -> 1
{- qs : quicksort -}
-- idented
qs [] = []
qs (x:xs) = qs lt ++ [x] ++ qs ge where
lt = [y | y <- xs, y < x]
... | tonussi/freezing-dubstep | pratica-05/Escrita.hs | mit | 592 | 0 | 10 | 236 | 356 | 195 | 161 | 20 | 4 |
module Mdcat(
render,
debugMessage
) where
import System.Environment (getArgs, lookupEnv)
import Text.Pandoc
import System.Directory
import System.Console.ANSI
import Control.Monad
import System.Console.Terminfo.Base
import System.Console.Terminfo.Cursor
import Data.IORef
import System.IO.U... | dorafmon/mdcat | src/Mdcat.hs | mit | 2,816 | 11 | 16 | 778 | 959 | 470 | 489 | 86 | 7 |
doubleIt x = x + x
doubleIt2 x y = doubleIt x + doubleIt y
| SametSisartenep/haskelling | doublingFunctions.hs | mit | 60 | 0 | 6 | 16 | 33 | 15 | 18 | 2 | 1 |
module GameStep
(
GameStep(GameStep),
)
where
data GameStep = GameStep Double Double
| bitc/crap-chopper-game | GameStep.hs | mit | 87 | 0 | 6 | 14 | 25 | 16 | 9 | 6 | 0 |
module FUSEOps
( dfsOps
) where
import Control.Monad.Except (runExceptT)
import Data.ByteString.Base64 (decodeLenient, encode)
import qualified Data.ByteString.Char8 as BS
import Foreign.C.Types (CSize(..))
import Servant
import Servant.Client (parseBaseUrl, BaseUr... | houli/distributed-file-system | fuse-file-system/app/FUSEOps.hs | mit | 8,884 | 0 | 23 | 3,177 | 2,212 | 1,131 | 1,081 | 171 | 4 |
{-# LANGUAGE CPP #-}
{-# OPTIONS_GHC -fno-warn-missing-import-lists #-}
{-# OPTIONS_GHC -fno-warn-implicit-prelude #-}
module Paths_svg_loading (
version,
getBinDir, getLibDir, getDynLibDir, getDataDir, getLibexecDir,
getDataFileName, getSysconfDir
) where
import qualified Control.Exception as Exception
... | cirquit/Personal-Repository | Haskell/svg-loading/.stack-work/dist/x86_64-linux-nopie/Cabal-1.24.2.0/build/autogen/Paths_svg_loading.hs | mit | 2,476 | 0 | 10 | 239 | 410 | 238 | 172 | 33 | 1 |
{-|
Module : PostgREST.Error
Description : PostgREST error HTTP responses
-}
{-# OPTIONS_GHC -fno-warn-orphans #-}
{-# LANGUAGE RecordWildCards #-}
module PostgREST.Error
( errorResponseFor
, ApiRequestError(..)
, PgError(..)
, Error(..)
, errorPayload
, checkIsFatal
, singularityError
) where
im... | steve-chavez/postgrest | src/PostgREST/Error.hs | mit | 13,074 | 0 | 18 | 3,015 | 3,636 | 1,936 | 1,700 | 251 | 31 |
{- |
Module : Selection.hs
Description : .
Maintainer : Benjamin Kodera (c)
License : MIT
Stability : stable
The Selection-module handles multiple character selection as well as copy and paste functionality.
-}
module Selection (
handleSelection,
updateCells,
... | SWP-Ubau-SoSe2014-Haskell/SWPSoSe14 | src/RailEditor/Selection.hs | mit | 7,982 | 0 | 19 | 1,547 | 3,002 | 1,552 | 1,450 | 159 | 2 |
module Rebase.Data.Scientific
(
module Data.Scientific
)
where
import Data.Scientific
| nikita-volkov/rebase | library/Rebase/Data/Scientific.hs | mit | 89 | 0 | 5 | 12 | 20 | 13 | 7 | 4 | 0 |
module JSDOM.Custom.RTCPeerConnectionError (
) where
| ghcjs/jsaddle-dom | src/JSDOM/Custom/RTCPeerConnectionError.hs | mit | 57 | 0 | 3 | 9 | 10 | 7 | 3 | 1 | 0 |
{-#LANGUAGE DataKinds #-}
{-#LANGUAGE GADTs #-}
{-#LANGUAGE KindSignatures #-}
{-#LANGUAGE PolyKinds #-}
{-#LANGUAGE TypeFamilies #-}
{-#LANGUAGE MultiParamTypeClasses #-}
{-#LANGUAGE ScopedTypeVariables #-}
{-#LANGUAGE FlexibleContexts #-}
module UTMTypes() where
type Step a = Either (Char, TMState a) (Char, TMState... | krakrjak/haskell-playground | TypeFunctions/UTMTypes.hs | gpl-2.0 | 3,954 | 0 | 13 | 1,088 | 1,492 | 788 | 704 | 81 | 13 |
-- Copyright 2014 Karim Sumun
-- This file is part of Karim's Haskell Learning Project.
-- Karim's Haskell Learning Project is free software: you can
-- redistribute it and/or modify it under the terms of the GNU General
-- Public License as published by the Free Software Foundation, either
-- version 3 of the License... | trooble/simpleserver | Fat/Server.hs | gpl-2.0 | 2,531 | 0 | 10 | 578 | 516 | 270 | 246 | 44 | 2 |
import Control.Concurrent
import Control.Monad
import System.IO
import System.Environment
import Text.Printf
import Logger
import qualified Phonebook as P
main :: IO ()
main = do
[arg] <- getArgs
case arg of
"ab" -> outputAB
"reminder" -> reminder
"reminder2" -> reminder2
"mvar" -> mvar
"logge... | y-kamiya/parallel-concurrent-haskell | src/Mvar/Main.hs | gpl-2.0 | 1,515 | 0 | 12 | 414 | 578 | 270 | 308 | 67 | 7 |
--
-- Copyright (c) 2013 Bonelli Nicola <bonelli@antifork.org>
--
-- This program is free software; you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation; either version 2 of the License, or
-- (at your option) any later version.
--... | YelaSeamless/cgrep | src/CGrep/Semantic/WildCard.hs | gpl-2.0 | 7,679 | 0 | 18 | 3,236 | 1,900 | 995 | 905 | 110 | 21 |
module Sara.Ast.OperatorsTest (operatorsGroup) where
import Sara.Ast.Operators
import Sara.TestUtils.AstGenUtils()
import Test.Framework
import Test.Framework.Providers.QuickCheck2
import Test.QuickCheck
prop_unarySymbolInjective :: UnaryOperator -> UnaryOperator -> Property
prop_unarySymbolInjective a b = a /= b ==... | Lykos/Sara | tests/Sara/Ast/OperatorsTest.hs | gpl-3.0 | 754 | 0 | 7 | 123 | 157 | 85 | 72 | -1 | -1 |
module GrammarOfReducedSearches where
import qualified Data.Vector as V
frst (x,_,_) = x
scnd (_,x,_) = x
thrd (_,_,x) = x
vectorSize = 256
init_i = 0
init_END = 0
init_CHILD = V.fromList $ take vectorSize $ repeat 0
init_SIBLING = V.fromList $ take vectorSize $ repeat 0
init_PARENT = V.fromList $ take... | joshuaunderwood7/HaskeLinGeom | GrammarOfReducedSearches.hs | gpl-3.0 | 1,728 | 0 | 10 | 549 | 423 | 221 | 202 | 44 | 2 |
module FastCorr where
import Data.Vector.Storable as V
import Data.Array.CArray
import System.IO.Unsafe
import Complex
import qualified Math.FFT as FFT
-- oh the humanity! (really please don't do anything but read the CArray)
vectorToCArray :: (Storable a) => Vector a -> CArray Int a
vectorToCArray v = let (ptr, of... | peddie/OpenVLBA | FastCorr.hs | gpl-3.0 | 1,151 | 0 | 9 | 261 | 360 | 186 | 174 | 24 | 1 |
{-# LANGUAGE ConstraintKinds #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE PatternGuards #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE TupleSections #-}
{-# LANGUAGE ViewPatterns #-}
{-
Copyright 2019 The CodeWorld Authors. All rights reserv... | pranjaltale16/codeworld | codeworld-compiler/src/CodeWorld/Compile.hs | apache-2.0 | 9,662 | 0 | 23 | 2,278 | 2,403 | 1,250 | 1,153 | 236 | 4 |
import AdventOfCode (readInputFile)
import Data.IntMap (IntMap)
import qualified Data.IntMap as IntMap
import Prelude hiding (rem)
-- This dynamic programming is gratuitous.
-- Brute-forcing through `subsequences` still runs in < 0.1 seconds.
-- However, with dynamic programming we run in about 0.02 seconds.
ways ::... | petertseng/adventofcode-hs | bin/17_containers.hs | apache-2.0 | 973 | 7 | 12 | 237 | 351 | 174 | 177 | 20 | 1 |
{-# LANGUAGE ScopedTypeVariables, BangPatterns, OverloadedStrings #-}
-- | Native binary I/O
module Native
( Native(..)
, save
, load
) where
import Data.Binary.Get
import Data.Binary.Put
import Data.Binary.IEEE754
import qualified Data.ByteString.Lazy as BL
import Data.Int
import Data.Vector.Unboxed (Vector)... | eddysystems/quibble | Native.hs | bsd-2-clause | 2,113 | 0 | 18 | 526 | 709 | 367 | 342 | 67 | 1 |
--
-- Copyright (c) 2013, Carl Joachim Svenn
-- All rights reserved.
--
-- Redistribution and use in source and binary forms, with or without
-- modification, are permitted provided that the following conditions are met:
--
-- 1. Redistributions of source code must retain the above copyright notice... | karamellpelle/MEnv | source/GUI/Widget.hs | bsd-2-clause | 2,590 | 0 | 13 | 619 | 254 | 154 | 100 | 32 | 0 |
-- ------------------------------------------------------------------------------------
-- Molcas 2010 output file parser
-- @2013 The ResMol Group
-- Authors: Angel Alvarez, Felipe Zapata
--
-- 2013-01 Initial design
-- Molcas:
-- Another bunch of ancient and (somewhat) heroic Fortran routines dating back from the
... | felipeZ/Dynamics | src/copiaMolcas.hs | bsd-3-clause | 20,744 | 0 | 17 | 6,089 | 3,070 | 1,490 | 1,580 | 341 | 3 |
{-# LANGUAGE PackageImports #-}
module Control.Concurrent.Chan (module M) where
import "base" Control.Concurrent.Chan as M
| silkapp/base-noprelude | src/Control/Concurrent/Chan.hs | bsd-3-clause | 128 | 0 | 4 | 18 | 23 | 17 | 6 | 3 | 0 |
-- |
-- Module : $Header$
-- Copyright : (c) 2013-2014 Galois, Inc.
-- License : BSD3
-- Maintainer : cryptol@galois.com
-- Stability : provisional
-- Portability : portable
{-# LANGUAGE FlexibleContexts #-}
module Cryptol.ModuleSystem.Monad where
import Cryptol.Eval.Env (EvalEnv)
impor... | dylanmc/cryptol | src/Cryptol/ModuleSystem/Monad.hs | bsd-3-clause | 9,640 | 0 | 17 | 2,021 | 2,917 | 1,499 | 1,418 | 219 | 2 |
--------------------------------------------------------------------------------
-- Copyright © 2011 National Institute of Aerospace / Galois, Inc.
--------------------------------------------------------------------------------
{-# LANGUAGE Trustworthy #-}
{-# LANGUAGE ExistentialQuantification #-}
{-# LANGUAGE Rank2... | leepike/copilot-core | src/Copilot/Core/External.hs | bsd-3-clause | 4,981 | 0 | 12 | 1,476 | 1,390 | 716 | 674 | 98 | 10 |
{-# LANGUAGE UndecidableInstances #-}
module Data.ByteString.Mp4.Boxes.SyncLayerConfigDescriptor where
import Data.ByteString.IsoBaseFileFormat.ReExports
import Data.ByteString.Mp4.Boxes.BaseDescriptor
data Mp4SyncLayerDescriptor :: Extends (Descriptor 'SLConfigDescr)
-- | In the holy scripture, ISO-14496-14 sectio... | sheyll/isobmff-builder | src/Data/ByteString/Mp4/Boxes/SyncLayerConfigDescriptor.hs | bsd-3-clause | 811 | 0 | 10 | 115 | 82 | 52 | 30 | -1 | -1 |
{-# LANGUAGE Rank2Types #-}
module Main (main) where
import Prelude hiding (read, length)
import qualified Prelude as P
import Control.Monad.ST
import Control.Monad.Error
import Data.Char
import Data.Ord (comparing)
import Data.List (maximumBy)
import Data.Vector.Unboxed.Mutable
import qualified Data.Vector.Algo... | tolysz/vector-algorithms | bench/Main.hs | bsd-3-clause | 7,525 | 0 | 20 | 2,117 | 2,468 | 1,277 | 1,191 | 154 | 14 |
{-# LANGUAGE QuasiQuotes #-}
import LiquidHaskell
[lq| autosize List |]
data List a = N | Cons a (List a)
nil = N
cons = Cons
foo :: List a -> Int
foo N = 0
foo (Cons x xs) = 1 + foo xs
[lq| autosize Exp |]
data Exp = EConst Int | EBinOp Int Exp Exp
expSize :: Exp -> Int
expSize (EConst _) = 0
expSize (EBi... | spinda/liquidhaskell | tests/gsoc15/unknown/pos/AutoSize.hs | bsd-3-clause | 367 | 0 | 8 | 95 | 172 | 93 | 79 | 14 | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.