_id
stringlengths
64
64
repository
stringlengths
6
84
name
stringlengths
4
110
content
stringlengths
0
248k
license
null
download_url
stringlengths
89
454
language
stringclasses
7 values
comments
stringlengths
0
74.6k
code
stringlengths
0
248k
a086c94c2023cc9c4dd84b05c9e5aae9273cb02cce5f399cf99dd97d258d0e32
bcc32/advent-of-code
point.ml
open! Core open! Import type t = int * int [@@deriving compare, equal, hash, sexp_of] let dist_manhattan (x1, y1) (x2, y2) = Int.abs (x1 - x2) + Int.abs (y1 - y2) let dist_euclidean (x1, y1) (x2, y2) = Float.hypot (float (x1 - x2)) (float (y1 - y2)) let add (x, y) (dir : Dir.t) = match dir with | N -> x, y + 1 ...
null
https://raw.githubusercontent.com/bcc32/advent-of-code/653c0f130e2fb2f599d4e76804e02af54c9bb19f/2019/robot/point.ml
ocaml
open! Core open! Import type t = int * int [@@deriving compare, equal, hash, sexp_of] let dist_manhattan (x1, y1) (x2, y2) = Int.abs (x1 - x2) + Int.abs (y1 - y2) let dist_euclidean (x1, y1) (x2, y2) = Float.hypot (float (x1 - x2)) (float (y1 - y2)) let add (x, y) (dir : Dir.t) = match dir with | N -> x, y + 1 ...
153e4ba328d6a56a9d3a06486404fe5f0e66b13ca491bbba12109db43738a53c
soulomoon/haskell-katas
OddsAndEvens.hs
{-# LANGUAGE GADTs #-} module Katas.OddsAndEvens (spec) where import Kyu2.OddsAndEvens as S import Test.Hspec main :: IO () main = hspec spec spec :: Spec spec = describe "OddsAndEvens" $ do describe "(*)PlusOne" $ do it "evenPlusOne works" $ do fromOdd (S.evenPlusOne two) `shouldBe` 3 fromOdd (S.e...
null
https://raw.githubusercontent.com/soulomoon/haskell-katas/0861338e945e5cbaadf98138cf8f5f24a6ca8bb3/test/Katas/OddsAndEvens.hs
haskell
# LANGUAGE GADTs # Representations to Integers Numbers for help during tests
module Katas.OddsAndEvens (spec) where import Kyu2.OddsAndEvens as S import Test.Hspec main :: IO () main = hspec spec spec :: Spec spec = describe "OddsAndEvens" $ do describe "(*)PlusOne" $ do it "evenPlusOne works" $ do fromOdd (S.evenPlusOne two) `shouldBe` 3 fromOdd (S.evenPlusOne six) `should...
5228a1993721c37656a9b23c838e0c01bea61260c373c0e9d8da7f7c1ad251e7
pmatos/racket-binaryen
types.rkt
#lang racket/base ;; --------------------------------------------------------------------------------------------------- (require "private/binaryen-ffi.rkt" "private/types.rkt" racket/contract) (provide type-none type-int32 type-int64 type-float32 type-float64 type-vec128 type-funcref type-e...
null
https://raw.githubusercontent.com/pmatos/racket-binaryen/3535a9400b20f5e64d799bb70916d85466802e6d/types.rkt
racket
--------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------- ---------------------------------------------------------------------------------------------------
#lang racket/base (require "private/binaryen-ffi.rkt" "private/types.rkt" racket/contract) (provide type-none type-int32 type-int64 type-float32 type-float64 type-vec128 type-funcref type-externref type-anyref type-eqref type-i31ref type-dataref type-unreachable type-auto) (define ty...
47836008bc55c940d3b7f23c11af837495b57690b272fefc79678c5388b42d46
binsec/binsec
loader_types.mli
(**************************************************************************) This file is part of BINSEC . (* *) Copyright ( C ) 2016 - 2022 CEA ( Co...
null
https://raw.githubusercontent.com/binsec/binsec/8ed9991d36451a3ae7487b966c4b38acca21a5b3/src/loader/loader_types.mli
ocaml
************************************************************************ alternatives) you can redistribute it an...
This file is part of BINSEC . Copyright ( C ) 2016 - 2022 CEA ( Commissariat à l'énergie atomique et aux énergies Lesser General Public License as published by the Free Software Foundation , ve...
dc8596cee6bae45531cc30e7b5725c9f3e33cb5b8368dc97a7a323a46b984a26
karamellpelle/grid
Env.hs
grid is a game written in Haskell Copyright ( C ) 2018 -- -- This file is part of grid. -- -- grid 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 , or -- (at your optio...
null
https://raw.githubusercontent.com/karamellpelle/grid/56729e63ed6404fd6cfd6d11e73fa358f03c386f/designer/source/MEnv/GLFW/Env.hs
haskell
This file is part of grid. grid is free software: you can redistribute it and/or modify (at your option) any later version. grid is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GN...
grid is a game written in Haskell Copyright ( C ) 2018 it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3 of the License , or You should have received a copy of the GNU General Public License module MEnv.Env ( Env (..), EnvInit (..),...
a09d3bc458135910332e3595615fce43f15b094854ecd7d83e6b17cd2575326c
ohua-dev/ohua-core
Util.hs
module Ohua.DFLang.Util where import Ohua.Prelude import qualified Data.Foldable as F import qualified Data.HashMap.Strict as HM import qualified Data.HashSet as HS import qualified Data.Sequence as DS import Data.Sequence (Seq, (|>)) import Ohua.DFLang.Lang -- | Find the usages of a binding findUsages :: Foldable ...
null
https://raw.githubusercontent.com/ohua-dev/ohua-core/978fa3369922f86cc3fc474d5f2c554cc87fd60a/core/src/Ohua/DFLang/Util.hs
haskell
| Find the usages of a binding | Find the definition of a binding
module Ohua.DFLang.Util where import Ohua.Prelude import qualified Data.Foldable as F import qualified Data.HashMap.Strict as HM import qualified Data.HashSet as HS import qualified Data.Sequence as DS import Data.Sequence (Seq, (|>)) import Ohua.DFLang.Lang findUsages :: Foldable f => Binding -> f LetExpr -> [LetE...
82661a39b90d4536c976e1bdc66d2a7e851e7cce0bcb610c398853e0a707ab10
sdiehl/llvm-pp
Standalone.hs
module Standalone where -- Pretty Printer import LLVM.General.Pretty (ppllvm) AST import LLVM.General.AST import qualified LLVM.General.AST as AST import LLVM.General.AST.Global import Data.Text.Lazy.IO as TIO int :: Type int = IntegerType 32 defAdd :: Definition defAdd = GlobalDefinition functionDefaults { na...
null
https://raw.githubusercontent.com/sdiehl/llvm-pp/056dd82ddcdf775f03a6baea6c9fb68bb98f1337/Standalone.hs
haskell
Pretty Printer
module Standalone where import LLVM.General.Pretty (ppllvm) AST import LLVM.General.AST import qualified LLVM.General.AST as AST import LLVM.General.AST.Global import Data.Text.Lazy.IO as TIO int :: Type int = IntegerType 32 defAdd :: Definition defAdd = GlobalDefinition functionDefaults { name = Name "add" ...
2356833c33dcc9f1b62b14d66fe2d7b25c44f31c860c27d23bbc0db7e7d6901f
metabase/metabase
driver_test.clj
(ns metabase.driver-test (:require [clojure.test :refer :all] [metabase.driver :as driver] [metabase.driver.impl :as driver.impl] [metabase.plugins.classloader :as classloader] [metabase.test.data.env :as tx.env])) (set! *warn-on-reflection* true) (driver/register! ::test-driver, :abstract? true) (d...
null
https://raw.githubusercontent.com/metabase/metabase/56b28e5b07e73002d5c507f583e3d64439ba8b8c/test/metabase/driver_test.clj
clojure
we are not using the regular mt / test - driver or mt / test - drivers , because those involve initializing the driver and test data namespaces, which don't necessarily exist for all drivers (ex: googleanalytics), and besides which, we don't actually need sample data or test extensions for this test itself so inste...
(ns metabase.driver-test (:require [clojure.test :refer :all] [metabase.driver :as driver] [metabase.driver.impl :as driver.impl] [metabase.plugins.classloader :as classloader] [metabase.test.data.env :as tx.env])) (set! *warn-on-reflection* true) (driver/register! ::test-driver, :abstract? true) (d...
99c464cf21f8a7d84ec454c3e3622d440e53dd2381af7602334e6c93aa75c1c0
BitGameEN/bitgamex
usr_game.erl
%%%-------------------------------------------------------- %%% @Module: usr_game %%% @Description: 自动生成 %%%-------------------------------------------------------- -module(usr_game). -export([get_one/1, get_game_gids_by_game_type_and_open_status/1, set_one/1, set_field/3, del_one/1, syncdb/1, clean_all_cache/0, cache_...
null
https://raw.githubusercontent.com/BitGameEN/bitgamex/151ba70a481615379f9648581a5d459b503abe19/src/data/usr_game.erl
erlang
-------------------------------------------------------- @Module: usr_game @Description: 自动生成 --------------------------------------------------------
-module(usr_game). -export([get_one/1, get_game_gids_by_game_type_and_open_status/1, set_one/1, set_field/3, del_one/1, syncdb/1, clean_all_cache/0, cache_key/1]). -include("common.hrl"). -include("record_usr_game.hrl"). get_one(Game_id = Id) -> case run_data:in_trans() of true -> case run_data:trans_get(usr_gam...
7f5187a8a1dda04204de1a8f2584ba9eecceb828272c410bbaa140e352577288
toschoo/mom
Common.hs
module Common where import qualified System.ZMQ as Z import qualified Data.ByteString as B import Test.QuickCheck import Test.QuickCheck.Monadic import Network.Mom.Patterns.Types import Network.Mom.Patterns.Streams import Control.Applicative ((<$>)) imp...
null
https://raw.githubusercontent.com/toschoo/mom/b58ca23d05c98ab50d9e981bd4ad2cdb76846399/src/patterns/test/suite/Common.hs
haskell
---------------------------------------------------------------------- For debugging it's much nicer to work with digits ---------------------------------------------------------------------- ---------------------------------------------------------------------- Ease working with either ------------------------------...
module Common where import qualified System.ZMQ as Z import qualified Data.ByteString as B import Test.QuickCheck import Test.QuickCheck.Monadic import Network.Mom.Patterns.Types import Network.Mom.Patterns.Streams import Control.Applicative ((<$>)) imp...
d2b1263c823054e395969ee5b550c2587fd64d86a691d8f874839a7fb14c3564
chenyukang/eopl
test.scm
;; safely apply procedure fn to a list of args. ;; if successful, return (cons #t val) ;; if error is invoked, returns (cons #f string), where string is the ;; format string generated by error. If somebody manages to raise a ;; value other than an exception, then the raised value is reported. (define apply-safely ...
null
https://raw.githubusercontent.com/chenyukang/eopl/0406ff23b993bfe020294fa70d2597b1ce4f9b78/ch6/base/test.scm
scheme
safely apply procedure fn to a list of args. if successful, return (cons #t val) if error is invoked, returns (cons #f string), where string is the format string generated by error. If somebody manages to raise a value other than an exception, then the raised value is reported. catch any error evaluate to a fai...
(define apply-safely (lambda (proc args) (cons #f (if (exn? exn) (exn-message exn) exn)))]) (let ([actual (apply proc args)]) (cons #t actual))))) (define a...
8c83e94bbb99564b5af530c4112fbb12338605a5f30f01340c47bc3303fd5409
alexbs01/OCaml
pascal.ml
let strcomb p = try string_of_int (Comb.comb p) with _ -> "ERROR" in let n = int_of_string (Sys.argv.(1)) in for i = 0 to n do for j = 0 to i do print_string (strcomb (i,j) ^ " ") done; print_newline () done;;
null
https://raw.githubusercontent.com/alexbs01/OCaml/db31f5db69b3fb8cce566f2b869f30beef598aaa/comb/pascal.ml
ocaml
let strcomb p = try string_of_int (Comb.comb p) with _ -> "ERROR" in let n = int_of_string (Sys.argv.(1)) in for i = 0 to n do for j = 0 to i do print_string (strcomb (i,j) ^ " ") done; print_newline () done;;
c50e9f497fa2bcb95910c1a9621f2b395e6ed6803750667b91cb4541615806d8
input-output-hk/pvss-haskell
Main.hs
{-# LANGUAGE BangPatterns #-} # LANGUAGE CPP # module Main where import System.Environment import Control.Monad import Control.Exception import Control.DeepSeq import qualified Crypto.PVSS as PVSS import qualified Crypto.SCRAPE as SCRAPE import Data.List import ...
null
https://raw.githubusercontent.com/input-output-hk/pvss-haskell/a009676f58174d8e3c02ce9cf0325d1fc6759951/app/Main.hs
haskell
# LANGUAGE BangPatterns # timingP "escrow-new" $ timingP "commitments" $ timingP "shares" $ timingP (" chunk-" ++ show (fst $ head c)) $ timingP (" vchunk") $ timingP "keypair"
# LANGUAGE CPP # module Main where import System.Environment import Control.Monad import Control.Exception import Control.DeepSeq import qualified Crypto.PVSS as PVSS import qualified Crypto.SCRAPE as SCRAPE import Data.List import Time.Types import ...
16beeec39ec15ee089819c31f1f39a512576fa0a8e5abf773f812fea327ab46b
chshersh/iris
Colour.hs
| Module : . Colour Copyright : ( c ) 2022 SPDX - License - Identifier : MPL-2.0 Maintainer : < > Stability : Experimental Portability : Portable Functions to handle colouring of the output to terminal . @since 0.0.0.0 ...
null
https://raw.githubusercontent.com/chshersh/iris/8d5627284ac6b6814c6e026d709fde9ac07656a8/src/Iris/Colour.hs
haskell
$mode $formatting $mode Colouring mode in application. $formatting Formatting of Terminal output
| Module : . Colour Copyright : ( c ) 2022 SPDX - License - Identifier : MPL-2.0 Maintainer : < > Stability : Experimental Portability : Portable Functions to handle colouring of the output to terminal . @since 0.0.0.0 ...
bfbcc4ba1a77ce26f770582f0907050cce28174f4702ae156c9e6ff89b5a0156
hanshuebner/pixelisp
clock.lisp
(cl-log:log-message :info "running clock") (app:start :clock) (loop (sleep 1))
null
https://raw.githubusercontent.com/hanshuebner/pixelisp/f304dfb08130d5a2a7deb68fc4881e720df42a56/scripts/clock.lisp
lisp
(cl-log:log-message :info "running clock") (app:start :clock) (loop (sleep 1))
07d121e7c8329cdd840bad5f4c574c8a59e7a7c8e8c711523323564bdc513084
lamdu/lamdu
Db.hs
module Test.Lamdu.Db ( ramDB ) where import qualified Control.Lens as Lens import Data.IORef (IORef, newIORef, modifyIORef, readIORef) import qualified Data.Map as Map import Data.UUID.Types (UUID) import qualified Lamdu.Data.Db.Init as DbInit import Lamdu.Data.Db.Layout (DbM(..))...
null
https://raw.githubusercontent.com/lamdu/lamdu/2dba7d7ce3e5c8456e1b647326290d9aedaf6d9e/test/Test/Lamdu/Db.hs
haskell
| Make an action to efficiently generate a fresh RAM DB
module Test.Lamdu.Db ( ramDB ) where import qualified Control.Lens as Lens import Data.IORef (IORef, newIORef, modifyIORef, readIORef) import qualified Data.Map as Map import Data.UUID.Types (UUID) import qualified Lamdu.Data.Db.Init as DbInit import Lamdu.Data.Db.Layout (DbM(..))...
48b379d5cab30829f3de75cb561e75e0f9846e270ae57cc6ba3f28e976de208f
jackfirth/lens
string.rkt
#lang reprovide lens/private/string/main
null
https://raw.githubusercontent.com/jackfirth/lens/733db7744921409b69ddc78ae5b23ffaa6b91e37/lens-data/lens/data/string.rkt
racket
#lang reprovide lens/private/string/main
4f4e1367ef9b2e7c12dae98e4d4dc666fec98aea6e251368c6f39ae33bf2fd6a
jeffshrager/biobike
bbl-org-tests.lisp
-*- Package : bbl - test - user ; mode : lisp ; base : 10 ; Syntax : Common - Lisp ; -*- (in-package :bbl-test-user) ;;; +=========================================================================+ | Copyright ( c ) 2005 JP , , , | ;;; | ...
null
https://raw.githubusercontent.com/jeffshrager/biobike/5313ec1fe8e82c21430d645e848ecc0386436f57/BioLisp/Bbltests/bbl-org-tests.lisp
lisp
mode : lisp ; base : 10 ; Syntax : Common - Lisp ; -*- +=========================================================================+ | | | Permission is hereby granted, free of charge, to any person obtaining | | a copy of this software and as...
(in-package :bbl-test-user) | Copyright ( c ) 2005 JP , , , | | " Software " ) , to deal in the Software without restriction , including | | distribute , sublicense , and/or sell copies of the Software , and to | | permit persons to whom the Software is furnished to do so , subject to ...
ffcd59c3f394b0a6c753a7c37b383f9ccdfa79ff2cfe05df72e77f05c776ca1b
Dasudian/DSDIN
dsdns_utils_test.erl
-module(dsdns_utils_test). -include_lib("eunit/include/eunit.hrl"). to_ascii_test() -> ?assertEqual({error, no_registrar}, dsdns_utils:to_ascii(<<"abcdefg">>)), ?assertEqual({error, multiple_namespaces}, dsdns_utils:to_ascii(<<"abcd.efgh.dsdt">>)), ?assertEqual({error, r...
null
https://raw.githubusercontent.com/Dasudian/DSDIN/b27a437d8deecae68613604fffcbb9804a6f1729/apps/dsdns/test/dsdns_utils_test.erl
erlang
-module(dsdns_utils_test). -include_lib("eunit/include/eunit.hrl"). to_ascii_test() -> ?assertEqual({error, no_registrar}, dsdns_utils:to_ascii(<<"abcdefg">>)), ?assertEqual({error, multiple_namespaces}, dsdns_utils:to_ascii(<<"abcd.efgh.dsdt">>)), ?assertEqual({error, r...
49d7464087a4992da955b93eef163c17fcbbb84a037c5db3fd5e400d94f93446
yuanqing/code-problems
quick_sort.ml
let quick_sort (compare:'a -> 'a -> int) (xs:'a list) : 'a list = let rec partition xs pivot acc bcc = Partition ` xs ` into a pair of lists : ` acc ` containing elements smaller than the ` pivot ` , and ` bcc ` containing elements greater than the pivot . than the `pivot`, and `bcc` contai...
null
https://raw.githubusercontent.com/yuanqing/code-problems/30eb34ad616146306cddc50594a47deff111f341/src/quick_sort/quick_sort.ml
ocaml
We must reverse each list in order to maintain their original ordering in the original list. Otherwise, cons `x` to `bcc`.
let quick_sort (compare:'a -> 'a -> int) (xs:'a list) : 'a list = let rec partition xs pivot acc bcc = Partition ` xs ` into a pair of lists : ` acc ` containing elements smaller than the ` pivot ` , and ` bcc ` containing elements greater than the pivot . than the `pivot`, and `bcc` contai...
5fb1a8c09ed433168b687eda8ce975703ec7278ecdf38e3d4dc9132a46ba7231
tmcdonell/cuda
BandwidthTest.hs
-------------------------------------------------------------------------------- -- -- Module : Fold Copyright : ( c ) 2009 -- License : BSD -- -- Reduce a vector to a single value -- -------------------------------------------------------------------------------- module Main where -- Friends import PrettyP...
null
https://raw.githubusercontent.com/tmcdonell/cuda/b80e277845b63e85495a641a9af7070ed4c30937/examples/src/bandwidthTest/BandwidthTest.hs
haskell
------------------------------------------------------------------------------ Module : Fold License : BSD Reduce a vector to a single value ------------------------------------------------------------------------------ Friends ------------------------------------------------------------------------------ ...
Copyright : ( c ) 2009 module Main where import PrettyPrint System import Numeric import Data.List import Control.Monad import Control.Exception import System.Exit import System.Environment import System.Console.GetOpt import Text.PrettyPrint import Foreign import qualified Foreign.CUDA as CUDA...
384572a0dcfd838cb886928baae573e25333e317892c5e6b60200e1bd4e8c69e
ocaml-multicore/ocaml-tsan
odoc_extension.mli
(**************************************************************************) (* *) (* OCaml *) (* *) ...
null
https://raw.githubusercontent.com/ocaml-multicore/ocaml-tsan/f54002470cc6ab780963cc81b11a85a820a40819/ocamldoc/odoc_extension.mli
ocaml
************************************************************************ OCaml ...
, projet Cambium , INRIA Paris Copyright 2022 Institut National de Recherche en Informatique et the GNU Lesser General Public License version 2.1 , with the module Name = Odoc_name type private_flag = Asttypes.private_flag = Private | Public type extension_alias = ...
41380d60ccb73c1e1819fe9168277db787ac7dd7420b77d67df4b92602c79af9
ozusrl/SubtypedQuotedML
simpleEnv.ml
(*********************************************************************************************************************) (* *) ...
null
https://raw.githubusercontent.com/ozusrl/SubtypedQuotedML/7b09eb5518dea21fda3dc9db3b966a17225d91ff/src/toy/simpleEnv.ml
ocaml
******************************************************************************************************************* ...
, projet Cristal , INRIA Rocquencourt Copyright 2000 Institut National de Recherche en Informatique et Automatique . Distributed only by per...
ede97181792fdb07051bc8e65a62a449a45fe361b3c4169bfdfe40a5df8f4629
input-output-hk/cardano-ledger
Twiddle.hs
# LANGUAGE AllowAmbiguousTypes # # LANGUAGE ConstrainedClassMethods # # LANGUAGE DefaultSignatures # # LANGUAGE EmptyCase # # LANGUAGE FlexibleContexts # {-# LANGUAGE GADTs #-} {-# LANGUAGE RankNTypes #-} # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeApplications # # LANGUAGE TypeOperators # # LANGUAGE UndecidableIns...
null
https://raw.githubusercontent.com/input-output-hk/cardano-ledger/49a84725c4c2ecabc80f6dac215881bc23920962/libs/cardano-ledger-binary/testlib/Test/Cardano/Ledger/Binary/Twiddle.hs
haskell
# LANGUAGE GADTs # # LANGUAGE RankNTypes # | Introducing random variations into the CBOR encoding of a value while preserving the round-trip properties. For any value `x :: a`, where `a` derives `Twiddle`, and for any version of the decoder, the following property must hold: >>> fmap ((== x) . encodingToT...
# LANGUAGE AllowAmbiguousTypes # # LANGUAGE ConstrainedClassMethods # # LANGUAGE DefaultSignatures # # LANGUAGE EmptyCase # # LANGUAGE FlexibleContexts # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeApplications # # LANGUAGE TypeOperators # # LANGUAGE UndecidableInstances # module Test.Cardano.Ledger.Binary.Twiddle...
8f9b82b03f5e321de8635fb1bd597afbf8851b727172c5fc6c5304d2ddb4ddd2
anoma/juvix
Compile.hs
module Commands.Dev.Asm.Compile where import Commands.Base import Commands.Dev.Asm.Compile.Options import Commands.Extra.Compile qualified as Compile import Data.Text.IO qualified as TIO import Juvix.Compiler.Asm.Options qualified as Asm import Juvix.Compiler.Asm.Translation.FromSource qualified as Asm import Juvix.Co...
null
https://raw.githubusercontent.com/anoma/juvix/92042fa10c7dac83b53e5bd867a5489046ae82af/app/Commands/Dev/Asm/Compile.hs
haskell
module Commands.Dev.Asm.Compile where import Commands.Base import Commands.Dev.Asm.Compile.Options import Commands.Extra.Compile qualified as Compile import Data.Text.IO qualified as TIO import Juvix.Compiler.Asm.Options qualified as Asm import Juvix.Compiler.Asm.Translation.FromSource qualified as Asm import Juvix.Co...
eb1e06818d7fc199b49c6ae004af07a06a42c6cc81203a054514965225857413
uim/sigscheme
bench-takl.scm
(define (listn n) (if (not (= 0 n)) (cons n (listn (- n 1))) '())) (define l18 (listn 18)) (define l12 (listn 12)) (define l6 (listn 6)) (define (mas x y z) (if (not (shorterp y x)) z (mas (mas (cdr x) y z) (mas (cdr y) z x) (mas (...
null
https://raw.githubusercontent.com/uim/sigscheme/ccf1f92d6c2a0f45c15d93da82e399c2a78fe5f3/bench/bench-takl.scm
scheme
(define (listn n) (if (not (= 0 n)) (cons n (listn (- n 1))) '())) (define l18 (listn 18)) (define l12 (listn 12)) (define l6 (listn 6)) (define (mas x y z) (if (not (shorterp y x)) z (mas (mas (cdr x) y z) (mas (cdr y) z x) (mas (...
056865ec9ae1d3eeb5167fd2372330413ac113d340f48f17e1e71440e225c71b
yogthos/alpha-id
core.cljc
(ns alpha-id.core) (def ^:private dict-16 [\0 \1 \2 \3 \4 \5 \6 \7 \8 \9 \A \B \C \D \E \F]) (def ^:private dict-32 [\0 \1 \2 \3 \4 \5 \6 \7 \8 \9 \A \B \C \D \E \F \G \H \J \K \M \N \P \Q \R \S \T \U \V \W \X \Y \Z]) (def ^:private dict-64 [\0 \1 \2 \3 \4 \5 \6 \7 \8 \9 \A \B \C \D \E \F \G \H \I \J \K \L \M \N \O ...
null
https://raw.githubusercontent.com/yogthos/alpha-id/29569f10eced53aaeb38463d532b176916fe4b67/src/alpha_id/core.cljc
clojure
\< \>])
(ns alpha-id.core) (def ^:private dict-16 [\0 \1 \2 \3 \4 \5 \6 \7 \8 \9 \A \B \C \D \E \F]) (def ^:private dict-32 [\0 \1 \2 \3 \4 \5 \6 \7 \8 \9 \A \B \C \D \E \F \G \H \J \K \M \N \P \Q \R \S \T \U \V \W \X \Y \Z]) (def ^:private dict-64 [\0 \1 \2 \3 \4 \5 \6 \7 \8 \9 \A \B \C \D \E \F \G \H \I \J \K \L \M \N \O ...
32ebf078bbf431bf89a28bd08ccf4e8157e0608961c3c07e38784d3db40ccc5f
shirok/Gauche-makiki
methods.scm
(use gauche.parseopt) (use makiki) (define (main args) (let-args (cdr args) ([p "port=i"]) (start-http-server :access-log #t :error-log #t :port p)) 0) (define-http-handler (GET) "/" (^[req app] (respond/ok req "get"))) (define-http-handler (POST) "/" (^[req app] (respond/ok req "post"))) (define-http-handle...
null
https://raw.githubusercontent.com/shirok/Gauche-makiki/4e5b7d8eb867d09053e2376cc879c603efac6df5/tests/methods.scm
scheme
(use gauche.parseopt) (use makiki) (define (main args) (let-args (cdr args) ([p "port=i"]) (start-http-server :access-log #t :error-log #t :port p)) 0) (define-http-handler (GET) "/" (^[req app] (respond/ok req "get"))) (define-http-handler (POST) "/" (^[req app] (respond/ok req "post"))) (define-http-handle...
03ecc32f6a40c8d6c6f2531bca18f08636c86ff13c2f64b812536a724a833532
ocurrent/clarke
outputs.mli
module Flow : S.Output with type t = Eio.Flow.sink module Capnp : S.Output with type t = Capnp_client.t
null
https://raw.githubusercontent.com/ocurrent/clarke/521ec17a6c5d9333b7495561a77505adf7e03a0a/src/lib/outputs.mli
ocaml
module Flow : S.Output with type t = Eio.Flow.sink module Capnp : S.Output with type t = Capnp_client.t
3c33611773c3e8966fe9e710be1aa6f892ee9c5e281023241969858df1c15290
alesaccoia/festival_flinger
cmu_us_rxr_lexicon.scm
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; ;;; Carnegie Mellon University ; ; ; and and ; ; ; Copyright ( c ) 1998 - 2000 ...
null
https://raw.githubusercontent.com/alesaccoia/festival_flinger/87345aad3a3230751a8ff479f74ba1676217accd/lib/voices/us/cmu_us_rxr_cg/festvox/cmu_us_rxr_lexicon.scm
scheme
;;; ; ; ; ; ; ; ; ; ;;; Permission is hereby granted, free of charge, to use and distribute ;;; this software and its documentation without restriction, including ;;; withou...
CMU lexicon for US English (require 'postlex) (setup_cmu_lex) (define (cmu_us_rxr::select_lexicon) "(cmu_us_rxr::select_lexicon) Set up the CMU lexicon for US English." (lex.select "cmu") Post lexical rules (set! postlex_rules_hooks (list postlex_apos_s_check)) ) (define (cmu_us_rxr::reset_lexicon) "(cm...
8ff5dfb119112630b862e01a7b85190bd189e97bb78bfb8f511e74a11e4c2630
ChrisPenner/void-space
Enemy.hs
# LANGUAGE ScopedTypeVariables # # LANGUAGE FlexibleContexts # # LANGUAGE ViewPatterns # {-# LANGUAGE OverloadedStrings #-} module Actions.Enemy where import Actions.Health import Actions.Words import Config import Control.Applicative import Control.Lens ...
null
https://raw.githubusercontent.com/ChrisPenner/void-space/0058a78334921cd3efa425c53e900e173c3e3a5f/src/Actions/Enemy.hs
haskell
# LANGUAGE OverloadedStrings #
# LANGUAGE ScopedTypeVariables # # LANGUAGE FlexibleContexts # # LANGUAGE ViewPatterns # module Actions.Enemy where import Actions.Health import Actions.Words import Config import Control.Applicative import Control.Lens as L import Control.Mo...
93d68d6ed290f03c7a44201776a51836f1e5741ae7783c8384a4f88efe388222
tonyg/rmacs
info.rkt
#lang setup/infotab (define collection 'multi) (define deps '("base" "ansi" "syntax-color-lib" "gui-lib" "unix-signals" "diff-merge" ;; this for error reporting (only): "web-server-lib" ;; plus these, needed for the tests: ...
null
https://raw.githubusercontent.com/tonyg/rmacs/8c99dd5dfa22f1f34707bbe957de268dc6a7a632/info.rkt
racket
this for error reporting (only): plus these, needed for the tests:
#lang setup/infotab (define collection 'multi) (define deps '("base" "ansi" "syntax-color-lib" "gui-lib" "unix-signals" "diff-merge" "web-server-lib" "profile-lib" )) (define build-deps '("rackunit-lib"))
8680df11aada241aa65e1aadf30d8d0bf8e2857965bd57b2a6c3fee8d982e33a
thelema/ocaml-community
subst.ml
(***********************************************************************) (* *) (* OCaml *) (* *) , projet ...
null
https://raw.githubusercontent.com/thelema/ocaml-community/ed0a2424bbf13d1b33292725e089f0d7ba94b540/typing/subst.ml
ocaml
********************************************************************* OCaml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et en Automatique . All rights reserved . This file is distributed under the terms of the Q Public License version 1.0 . open Misc open Path open Types open Bt...
1c37fb1305c518766e7596d6ebb69bbd3b1eacdf5b80c64d59213b7fe2135264
blindglobe/clocc
lapack-tests.lisp
;;; Simple tests for selected LAPACK routines . ;;; $ I d : , v 1.11 2006/12/01 04:29:29 rtoy Rel $ ;;; (in-package "LAPACK") Convert the eigenvalues returned by DGEEV into an array (defun make-eigval (wr wi) (let ((e-val (make-array (length wr)))) (map-into e-val #'(lambda (r i) ;; Do we real...
null
https://raw.githubusercontent.com/blindglobe/clocc/a50bb75edb01039b282cf320e4505122a59c59a7/src/f2cl/packages/lapack/lapack-tests.lisp
lisp
Do we really want to do this? Should we just make all of the eigenvalues complex? matrix form. Skip over the next column, which we've already used Expected results from -ex/examples/results/dgeev-ex.r -6.5509E-01 -5.2363E-01 5.3622E-01 -9.5607E-02 ( 9.7182E-02,-3.0838E-01) (-1.9330E-0...
Simple tests for selected LAPACK routines . $ I d : , v 1.11 2006/12/01 04:29:29 rtoy Rel $ (in-package "LAPACK") Convert the eigenvalues returned by DGEEV into an array (defun make-eigval (wr wi) (let ((e-val (make-array (length wr)))) (map-into e-val #'(lambda (r i) (if (zerop i) r ...
a3ed4528abe22666f7de6900810ed014c79af8acee40304fe19f0aebfeafeaf4
hipsleek/hipsleek
globalvars.ml
#include "xdebug.cppo" open VarGen * Created 20 - May-2009 Convert global variables into reference parameters Convert global variables into reference parameters *) open Globals open Gen.Basic module I = Iast (* Data structure for set of identifiers *) module Ident = struct type t = ident let compare = comp...
null
https://raw.githubusercontent.com/hipsleek/hipsleek/596f7fa7f67444c8309da2ca86ba4c47d376618c/bef_indent/globalvars.ml
ocaml
Data structure for set of identifiers Data structure for graph of identifiers Global variables Utility functions * Convert a list of identifiers into a set of identifiers @param l list of identifiers @return the set of identifiers in l * Union a list of identifier sets into a unique identifier set @param...
#include "xdebug.cppo" open VarGen * Created 20 - May-2009 Convert global variables into reference parameters Convert global variables into reference parameters *) open Globals open Gen.Basic module I = Iast module Ident = struct type t = ident let compare = compare end module IdentSet = Set.Make(Ident) ...
4da8239a9cd39ff2ca6da02873fb08c6cbf752bd63feed2a367d88f1e10a0e71
Apress/practical-ocaml
ch_08.ml
compare 3 1;; compare 3 6;; compare 3 3;; type university = Grad_Student | Undergrad_Student |AtLarge_Student ~CCC | Adjunct_Professor | Professor | Staff;; let assortment = [Grad_Student;Staff;Adjunct_Professor;Undergrad_Student];; List.sort compare assortment;; let rank uni = match uni with Grad_Student -...
null
https://raw.githubusercontent.com/Apress/practical-ocaml/c0f1e36283eb0e495ff8db7f2a88cadbf1a3d49e/Chapter08/ch_08.ml
ocaml
Lists Arrays Hashtables Stacks Sets Maps
compare 3 1;; compare 3 6;; compare 3 3;; type university = Grad_Student | Undergrad_Student |AtLarge_Student ~CCC | Adjunct_Professor | Professor | Staff;; let assortment = [Grad_Student;Staff;Adjunct_Professor;Undergrad_Student];; List.sort compare assortment;; let rank uni = match uni with Grad_Student -...
e47484a2e6b080b0a3a06044cb184b45a8740356da95464a4a3665e61333355c
thepower/tpnode
tpnode_vmsrv.erl
%%%------------------------------------------------------------------- %% @doc tpnode_vmsrv gen_server %% @end %%%------------------------------------------------------------------- -module(tpnode_vmsrv). -author("cleverfox <>"). -create_date("2018-08-15"). -include("include/tplog.hrl"). -behaviour(gen_server). -defin...
null
https://raw.githubusercontent.com/thepower/tpnode/6212422bc9061d44d150ef2d777d6e694396ed15/apps/tpnode/src/tpnode_vmsrv.erl
erlang
------------------------------------------------------------------- @doc tpnode_vmsrv gen_server @end ------------------------------------------------------------------- ------------------------------------------------------------------ API Function Exports ---------------------------------------------------------...
-module(tpnode_vmsrv). -author("cleverfox <>"). -create_date("2018-08-15"). -include("include/tplog.hrl"). -behaviour(gen_server). -define(SERVER, ?MODULE). -export([start_link/0]). gen_server Function Exports -export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). ...
ae6a8a8b1cf3b5aa3187ac24c691d144c24fe111257d855b734d510671a7c870
johnlawrenceaspden/hobby-code
numericalintegrationIV.clj
;; Numerical Integration: Better Rules? ;; So far we've found a couple of approximations to 'the area under a graph'. (defn trapezium-rule [f a b] (* 1/2 (- b a) (+ (f a) (f b)))) (defn simpson-rule [f a b] (let [midpoint (+ a (/ (- b a) 2))] (* 1/6 (- b a) (+ (f a) (* 4 (f midpoint)) (f b))))) ;; And a way...
null
https://raw.githubusercontent.com/johnlawrenceaspden/hobby-code/48e2a89d28557994c72299962cd8e3ace6a75b2d/numericalintegrationIV.clj
clojure
Numerical Integration: Better Rules? So far we've found a couple of approximations to 'the area under a graph'. And a way of repeatedly splitting intervals and applying the rules to the sub-intervals to produce better and better approximations. don't get too large, these rules produce good approximations For this...
(defn trapezium-rule [f a b] (* 1/2 (- b a) (+ (f a) (f b)))) (defn simpson-rule [f a b] (let [midpoint (+ a (/ (- b a) 2))] (* 1/6 (- b a) (+ (f a) (* 4 (f midpoint)) (f b))))) (defn iterated-rule [rule f a b N] (if (= N 0) (rule f a b) (let [midpoint (+ a (/ (- b a) 2))] (+ (iterated-rule ...
3037e4aa16389fcb21f20c52211696e6ed557bb3844b55853adc3d05b5dbc359
racket/rhombus-prototype
pair.rkt
#lang racket/base (require (for-syntax racket/base syntax/parse/pre syntax/stx "srcloc.rkt") "provide.rkt" "composite.rkt" "expression.rkt" "binding.rkt" (submod "annotation.rkt" for-class) "static-info....
null
https://raw.githubusercontent.com/racket/rhombus-prototype/4e66c1361bdde51c2df9332644800baead49e86f/rhombus/private/pair.rkt
racket
#lang racket/base (require (for-syntax racket/base syntax/parse/pre syntax/stx "srcloc.rkt") "provide.rkt" "composite.rkt" "expression.rkt" "binding.rkt" (submod "annotation.rkt" for-class) "static-info....
2fb30c738f16fc15a1ff77bc46e45704776d21a6adb24771886d2dff1c749e58
OCamlPro/ocaml-benchs
echo_client_main.ml
open Core.Std open Async.Std let command = Command.async_basic ~summary:"Echo client" Command.Spec.( empty +> Echo_common.port_arg () +> Echo_common.nbr_arg () +> Echo_common.debug_arg () ) (fun port nbr debug () -> Echo_common.debug := debug; Echo_client.run ~port ~nbr ()) ...
null
https://raw.githubusercontent.com/OCamlPro/ocaml-benchs/98047e112574e6bf55137dd8058f227a9f40281b/async_echo/echo_client_main.ml
ocaml
open Core.Std open Async.Std let command = Command.async_basic ~summary:"Echo client" Command.Spec.( empty +> Echo_common.port_arg () +> Echo_common.nbr_arg () +> Echo_common.debug_arg () ) (fun port nbr debug () -> Echo_common.debug := debug; Echo_client.run ~port ~nbr ()) ...
3e929f882ae26fd481382905b1ab35fd03543eea44f143f82371f2007e27c6e4
Glue42/gateway-modules
t_filters.cljc
(ns gateway.domains.metrics.t-filters (:require [gateway.domains.metrics.filters :as f] [gateway.common.filters :as cf] [clojure.test :refer :all])) (deftest publisher-matching (testing "all matching keys succeed" (is (f/publisher-matches? {:system #"Connect.*" ...
null
https://raw.githubusercontent.com/Glue42/gateway-modules/be48a132134b5f9f41fd6a6067800da6be5e6eca/metrics-domain/test/gateway/domains/metrics/t_filters.cljc
clojure
(ns gateway.domains.metrics.t-filters (:require [gateway.domains.metrics.filters :as f] [gateway.common.filters :as cf] [clojure.test :refer :all])) (deftest publisher-matching (testing "all matching keys succeed" (is (f/publisher-matches? {:system #"Connect.*" ...
ec577199801efeac5ecd126bb9c13f6adbd9eed656a7dea8d6cbe9a9958bc0f4
liquidz/antq
github_action.clj
(ns antq.constant.github-action) (def type-key ::type)
null
https://raw.githubusercontent.com/liquidz/antq/71563266d314cffb69862684de5af75182ee1daf/src/antq/constant/github_action.clj
clojure
(ns antq.constant.github-action) (def type-key ::type)
606380cada8cad3cf47464683e432f072b4ac3d414e62299cd9e9a6a2b8ce929
gree/haskell-test-sandbox
HUnit.hs
author : < > # LANGUAGE ScopedTypeVariables # # LANGUAGE CPP # module Test.Sandbox.HUnit ( assertFailure , assertBool , assertEqual , assertString , assertException ) where import Test.Sandbox import Control.Exception.Lifted import qualified Test.HUnit #if MIN_VERSION_HUnit(1,5,0) import Test.H...
null
https://raw.githubusercontent.com/gree/haskell-test-sandbox/3d1593ec44d1e804d71a9a3ef8b1eeafcfafefbb/test-sandbox-hunit/src/Test/Sandbox/HUnit.hs
haskell
| Unconditionally signals that a failure has occured. ^ A message that is displayed with the assertion failure | Asserts that the specified condition holds. ^ The message that is displayed if the assertion fails ^ The condition | Asserts that the specified actual value is equal to the expected value. ^ The messa...
author : < > # LANGUAGE ScopedTypeVariables # # LANGUAGE CPP # module Test.Sandbox.HUnit ( assertFailure , assertBool , assertEqual , assertString , assertException ) where import Test.Sandbox import Control.Exception.Lifted import qualified Test.HUnit #if MIN_VERSION_HUnit(1,5,0) import Test.H...
ef0bf932b996683eb35f51428b6cac8d99c60870e05d9e0b3c8cf8b6f587b825
nasa/Common-Metadata-Repository
docker.clj
(ns cmr.dev.env.manager.components.docker (:require [cmr.dev.env.manager.components.dem.config :as config] [cmr.dev.env.manager.components.dem.messaging :as messaging] [cmr.dev.env.manager.process.docker :as docker] [com.stuartsierra.component :as component] [taoensso.timbre :as log])) ;;;;;;;;;;...
null
https://raw.githubusercontent.com/nasa/Common-Metadata-Repository/63001cf021d32d61030b1dcadd8b253e4a221662/other/cmr-exchange/dev-env-manager/src/cmr/dev/env/manager/components/docker.clj
clojure
Docker Component API ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Lifecycle Implementation ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Health-check Implementation ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; XXX http and ping TBD XXX move this into ...
(ns cmr.dev.env.manager.components.docker (:require [cmr.dev.env.manager.components.dem.config :as config] [cmr.dev.env.manager.components.dem.messaging :as messaging] [cmr.dev.env.manager.process.docker :as docker] [com.stuartsierra.component :as component] [taoensso.timbre :as log])) (defn get...
89d9365921ce6aa946571895fe99adaf8ac6884bc2a73d47f79dd9e270fcbf65
agda/agda-ocaml
Malfunction.hs
# LANGUAGE TupleSections # module Agda.Compiler.Malfunction (backend) where import Agda.Compiler.Backend import Agda.Utils.Pretty import Control.Monad import Control.Monad.Extra import Control.Monad.Trans import Data.Bifunctor import Data.Char impor...
null
https://raw.githubusercontent.com/agda/agda-ocaml/e38b699870ba638221828b07b12948d70a1bdaec/src/full/Agda/Compiler/Malfunction.hs
haskell
liftIO (putStrLn "post compile") this (in the calling function) partition [Definition] -> ([Function], [Primitive], ...) And then we can simply do the topologic sorting stuff on the functions only. This would certainly make this funciton a helluva lot cleaner. | Compiles a whole module ^ All visible definit...
# LANGUAGE TupleSections # module Agda.Compiler.Malfunction (backend) where import Agda.Compiler.Backend import Agda.Utils.Pretty import Control.Monad import Control.Monad.Extra import Control.Monad.Trans import Data.Bifunctor import Data.Char impor...
21612933fb6edb88623787623111ad6605506b2039f7dd7992134910b91f3d94
lemmih/hsSDL2
lesson5.sdl.hs
module Main where --FIXME: Add comments to this code. import Graphics.Rendering.OpenGL as OpenGL import Graphics.UI.SDL as SDL import System.Exit import System.Environment import Data.IORef import Control.Monad step = 0.5 main = withInit [InitVideo] $ do progName <- getProgName blendEquation $= FuncAdd blendF...
null
https://raw.githubusercontent.com/lemmih/hsSDL2/7a785dc1b8df28143155c8a7c36e4ab69a10df81/Examples/NeHe/lesson05/lesson5.sdl.hs
haskell
FIXME: Add comments to this code. Right Back Left Bottom Back Bottom Right Bottom Left Bottom Front Top Bottom Back Left Right
module Main where import Graphics.Rendering.OpenGL as OpenGL import Graphics.UI.SDL as SDL import System.Exit import System.Environment import Data.IORef import Control.Monad step = 0.5 main = withInit [InitVideo] $ do progName <- getProgName blendEquation $= FuncAdd blendFunc $= (OpenGL.SrcAlpha, OneMinusSrc...
d2061ae4c3a3fafd6d7d0c7f1db6edf19a99b270e0bc6bca35e491136c756286
rurban/clisp
preload.lisp
(make-package "GTK" :case-sensitive t :case-inverted t)
null
https://raw.githubusercontent.com/rurban/clisp/75ed2995ff8f5364bcc18727cde9438cca4e7c2c/modules/gtk2/preload.lisp
lisp
(make-package "GTK" :case-sensitive t :case-inverted t)
79533ec44b022b48b5cbea9efbee10e138857f3c4c2c5918f162afa66ef3e2be
ddssff/refact-global-hse
MoveSpec.hs
# LANGUAGE CPP # # LANGUAGE FlexibleContexts # {-# LANGUAGE RankNTypes #-} # LANGUAGE RecordWildCards # # LANGUAGE ScopedTypeVariables # # LANGUAGE TemplateHaskell # # LANGUAGE TupleSections # # LANGUAGE TypeFamilies # module MoveSpec(MoveSpec(MoveSpec) , applyMoveSpec , traceMoveSpec , moveDeclsByName ...
null
https://raw.githubusercontent.com/ddssff/refact-global-hse/519a017009cae8aa1a3db1b46eb560d76bd9895d/tests/input/rgh/MoveSpec.hs
haskell
# LANGUAGE RankNTypes # | Specifies where to move each declaration of each module. Given a departure module key and a declaration, return an arrival module key. | Build the argument to moveInstDecls | Build the argument to moveInstDecls
# LANGUAGE CPP # # LANGUAGE FlexibleContexts # # LANGUAGE RecordWildCards # # LANGUAGE ScopedTypeVariables # # LANGUAGE TemplateHaskell # # LANGUAGE TupleSections # # LANGUAGE TypeFamilies # module MoveSpec(MoveSpec(MoveSpec) , applyMoveSpec , traceMoveSpec , moveDeclsByName , moveInstDecls , instCl...
5d1172e551ce9ae4a77088e6dc99b21b1b10a41710fd6aa91ef4da8fe4ceaaa0
gregcman/sucle
physics.lisp
(in-package :sucle) ;;;;************************************************************************;;;; ;;;;<PHYSICS> ;;;math modify macros (define-modify-macro *= (&rest args) *) (define-modify-macro += (&rest args) +) (define-modify-macro -= (&rest args) -) (define-modify-macro /f (&rest args) /) (define-modify-macro &...
null
https://raw.githubusercontent.com/gregcman/sucle/258be4ac4daaceea06a55f893227584d3772bb47/src/sucle/physics.lisp
lisp
************************************************************************;;;; <PHYSICS> math modify macros end math modify macros axis which are zeroed the final clamping value for each axis Always return no contact state. path unobstructed. Is will the block being placed overlap with the given entity? position also che...
(in-package :sucle) (define-modify-macro *= (&rest args) *) (define-modify-macro += (&rest args) +) (define-modify-macro -= (&rest args) -) (define-modify-macro /f (&rest args) /) (define-modify-macro &= (&rest args) logand) (define-modify-macro ^= (&rest args) logxor) (define-modify-macro |\|=| (&rest args) logior) (...
48630a030e47e8f4110aa4896e89d133a97dae19e97fdd35fcd5522df3465276
15Galan/asignatura-204
ConnectedComponents.hs
------------------------------------------------------------------------------- Connected Components of a -- Data Structures . en Informática . UMA . , 2012 ------------------------------------------------------------------------------- module DataStructures.Graph.ConnectedComponents ( dftConnectedComps ...
null
https://raw.githubusercontent.com/15Galan/asignatura-204/894f33ff8e0f52a75d8f9ff15155c656f1a8f771/Recursos/data.structures/haskell/DataStructures/Graph/ConnectedComponents.hs
haskell
----------------------------------------------------------------------------- -----------------------------------------------------------------------------
Connected Components of a Data Structures . en Informática . UMA . , 2012 module DataStructures.Graph.ConnectedComponents ( dftConnectedComps ) where import DataStructures.Graph.Graph import DataStructures.Graph.GraphDFT import Data.List((\\)) type ConnectedComponent a = [a] dftConnectedComps:: (Ord ...
2b070abec3c14fd401d7204f6c49f46d0b810928e70d03f2f42ab406633c7431
tweag/asterius
T14936.hs
{-# LANGUAGE BangPatterns #-} # LANGUAGE ScopedTypeVariables # # LANGUAGE FlexibleContexts # module Main where import Prelude import qualified Foreign.Storable as Storable import qualified Control.Monad.State.Strict as S import Control.Monad.IO.Class import Foreign.Marshal.Alloc (mallocBytes) newtype Foo a = F...
null
https://raw.githubusercontent.com/tweag/asterius/e7b823c87499656860f87b9b468eb0567add1de8/asterius/test/ghc-testsuite/perf/T14936.hs
haskell
# LANGUAGE BangPatterns # This 'go' loop should allocate nothing, because it specialises
# LANGUAGE ScopedTypeVariables # # LANGUAGE FlexibleContexts # module Main where import Prelude import qualified Foreign.Storable as Storable import qualified Control.Monad.State.Strict as S import Control.Monad.IO.Class import Foreign.Marshal.Alloc (mallocBytes) newtype Foo a = Foo a intSize :: Int intSize =...
68a9853819cc7083606cda2353f847eb9d55c2a691a1ac1c94f8d929ba4919a7
McCLIM/McCLIM
editing-tests.lisp
;;; --------------------------------------------------------------------------- ;;; License: LGPL-2.1+ (See file 'Copyright' for details). ;;; --------------------------------------------------------------------------- ;;; ( c ) copyright 2005 < > ( c ) copyright 2006 - 2008 < > ;;; ;;; ------------------...
null
https://raw.githubusercontent.com/McCLIM/McCLIM/7c890f1ac79f0c6f36866c47af89398e2f05b343/Libraries/Drei/Tests/editing-tests.lisp
lisp
--------------------------------------------------------------------------- License: LGPL-2.1+ (See file 'Copyright' for details). --------------------------------------------------------------------------- --------------------------------------------------------------------------- Tests for the editing funct...
( c ) copyright 2005 < > ( c ) copyright 2006 - 2008 < > (cl:in-package #:drei-tests) (def-suite editing-tests :description "The test suite for DREI-EDITING related tests." :in drei-tests) (in-suite editing-tests) (defmacro with-buffer-action-test-functions (&body body) Anamorphic . `(labels ((test-...
2fef8ec9ffa25f44fac4f4ef9713e5a0235c6ea42a9abec52077ca5d220c7efb
dimitaruzunov/fp-2018
double.scm
(require rackunit rackunit/text-ui) (define (double f) (lambda (x) (f (f x)))) (define (1+ x) (+ x 1)) (define (square x) (* x x)) (define double-tests (test-suite "Tests for double" (check = ((double 1+) 0) 2) (check = ((double square) 2) 16) (check = ((double (double 1+)) 0) 4) (check = (((...
null
https://raw.githubusercontent.com/dimitaruzunov/fp-2018/f75f0cd009cc7f41ce55a5ec71fb4b8eadafc4eb/exercises/03/double.scm
scheme
(require rackunit rackunit/text-ui) (define (double f) (lambda (x) (f (f x)))) (define (1+ x) (+ x 1)) (define (square x) (* x x)) (define double-tests (test-suite "Tests for double" (check = ((double 1+) 0) 2) (check = ((double square) 2) 16) (check = ((double (double 1+)) 0) 4) (check = (((...
fdf57c6556b6aaab522eb4df4611f26a4a09c9286abc9097af0c4b067c918552
EveryTian/Haskell-Codewars
Base.hs
module Base (Error(..), rebase) where data Error a = InvalidInputBase | InvalidOutputBase | InvalidDigit a deriving (Show, Eq) rebase :: Integral a => a -> a -> [a] -> Either (Error a) [a] rebase inputBase outputBase inputDigits = case checkBase inputBase outputBase inputDigits of Just error -> Left ...
null
https://raw.githubusercontent.com/EveryTian/Haskell-Codewars/dc48d95c676ce1a59f697d07672acb6d4722893b/exercism/all-your-base/src/Base.hs
haskell
module Base (Error(..), rebase) where data Error a = InvalidInputBase | InvalidOutputBase | InvalidDigit a deriving (Show, Eq) rebase :: Integral a => a -> a -> [a] -> Either (Error a) [a] rebase inputBase outputBase inputDigits = case checkBase inputBase outputBase inputDigits of Just error -> Left ...
9e289d4e642dd8a401b54e6e38d992b72fb3533e240c8fe016961458c52cd7dc
fmthoma/shell-scripting-with-haskell
my-application.hs
#!/usr/bin/env stack -- stack runhaskell --resolver=lts-8.0 --package=turtle {-# LANGUAGE OverloadedStrings #-} import Turtle main = do command <- options "My Application" (pure ()) print command
null
https://raw.githubusercontent.com/fmthoma/shell-scripting-with-haskell/bf7738fbbc806d3a9a072809fe2a91ec5865d8ec/optparse/my-application.hs
haskell
stack runhaskell --resolver=lts-8.0 --package=turtle # LANGUAGE OverloadedStrings #
#!/usr/bin/env stack import Turtle main = do command <- options "My Application" (pure ()) print command
317668db0f22f649b5150ffa1b17e6b4f19a231d7474d848bd09411e14f27277
incoherentsoftware/defect-process
Sprites.hs
module Enemy.All.Claws.Sprites ( EnemySprites(..) , mkEnemySprites ) where import Control.Monad.IO.Class (MonadIO) import Enemy.Util import FileCache import Window.Graphics data EnemySprites = EnemySprites { _spawn :: Sprite , _idle :: Sprite , _hurt :: Sprite ...
null
https://raw.githubusercontent.com/incoherentsoftware/defect-process/8797aad1d93bff5aadd7226c39a48f45cf76746e/src/Enemy/All/Claws/Sprites.hs
haskell
module Enemy.All.Claws.Sprites ( EnemySprites(..) , mkEnemySprites ) where import Control.Monad.IO.Class (MonadIO) import Enemy.Util import FileCache import Window.Graphics data EnemySprites = EnemySprites { _spawn :: Sprite , _idle :: Sprite , _hurt :: Sprite ...
165c70955a6d6b34001ad896398b28973e35969c441eb0cc050d679ad23ba18c
LadyBoonami/wsedit
Buffer.hs
# OPTIONS_GHC -fno - warn - missing - import - lists # # LANGUAGE DeriveAnyClass , DeriveGeneric , StandaloneDeriving # , DeriveGeneric , StandaloneDeriving #-} module WSEdit.Buffer ( Buffer , pos , setPos , prefLength , sufLen...
null
https://raw.githubusercontent.com/LadyBoonami/wsedit/e836b81b743123df2fa21470072ccd5ee1083ee4/src/WSEdit/Buffer.hs
haskell
| Finite list of elements, alongside their hash, salted with the hash of the previous element. Allows for fast difference checking. | Create a new hash list from a regular one. | Concat a normal and a hash list. | Appends a single element in front of a hash list. scale only with distance from the position, no...
# OPTIONS_GHC -fno - warn - missing - import - lists # # LANGUAGE DeriveAnyClass , DeriveGeneric , StandaloneDeriving # , DeriveGeneric , StandaloneDeriving #-} module WSEdit.Buffer ( Buffer , pos , setPos , prefLength , sufLen...
12ea99f66b501ff10bca51b0563a3f6aea8898d85e3d5463c7687f7e1ddd27b0
snapframework/io-streams
Core.hs
# LANGUAGE GeneralizedNewtypeDeriving # {-# LANGUAGE OverloadedStrings #-} | Core types and functions for the @io - streams@ library . -- module System.IO.Streams.Core ( -- * Stream types InputStream , OutputStream -- * Creating streams , makeInputStream , makeOutputStream -- * Primitive stre...
null
https://raw.githubusercontent.com/snapframework/io-streams/ae692fee732adea9fe843fb3efe0dd43a6993844/src/System/IO/Streams/Core.hs
haskell
# LANGUAGE OverloadedStrings # * Stream types * Creating streams * Primitive stream operations * Connecting streams together * Utility streams * Generator monad ----------------------------------------------------------------------------
# LANGUAGE GeneralizedNewtypeDeriving # | Core types and functions for the @io - streams@ library . module System.IO.Streams.Core InputStream , OutputStream , makeInputStream , makeOutputStream , read , unRead , peek , write , writeTo , atEOF , connect , connectTo , supply , supplyTo , appendInpu...
a6c295c026531210104509d216fbf1792ed73302c3284888a836e69d72b63f81
metametadata/aide
model.cljs
(ns app.model (:require [schema.core :as s])) (def Friend {:id s/Int :name s/Str :username s/Str}) (s/defschema Model {:query s/Str :friends [Friend] :token s/Str}) (def initial-model {:query "" :friends [] :token ""})
null
https://raw.githubusercontent.com/metametadata/aide/0828b53503e8c7f54f84e1b140a1d02ad80aff36/examples/friend-list/src/app/model.cljs
clojure
(ns app.model (:require [schema.core :as s])) (def Friend {:id s/Int :name s/Str :username s/Str}) (s/defschema Model {:query s/Str :friends [Friend] :token s/Str}) (def initial-model {:query "" :friends [] :token ""})
072ec313e0b08fc6d61fd493912ddd8c2aa6afa94e13cee4f47908a598de8c8e
cse-bristol/110-thermos-ui
supply.cljc
This file is part of THERMOS , copyright © Centre for Sustainable Energy , 2017 - 2021 Licensed under the Reciprocal Public License v1.5 . See LICENSE for licensing details . (ns thermos-specs.supply (:require [clojure.spec.alpha :as s] [spec-tools.data-spec :as ds] [thermos-util :as util...
null
https://raw.githubusercontent.com/cse-bristol/110-thermos-ui/743bc6c33ef7e8cc4d5af3c2799016dbd0840b96/src/thermos_specs/supply.cljc
clojure
These are the "network" supply parameters which control the cost / etc of heat supply in the network model if this field contains a number, then the network model However, we also have supply parameters for the plant model These live in the document at the top level [{day type => values}] the keys for each entry...
This file is part of THERMOS , copyright © Centre for Sustainable Energy , 2017 - 2021 Licensed under the Reciprocal Public License v1.5 . See LICENSE for licensing details . (ns thermos-specs.supply (:require [clojure.spec.alpha :as s] [spec-tools.data-spec :as ds] [thermos-util :as util...
4bead4edece82c8572fd4f8735b2c321c31930dad487c47c776c1893c2f10337
peterholko/pax_server
log_manager.erl
-module(log_manager). -author("Ahmed Al-Issaei"). -license("MPL-1.1"). -include("../include/log4erl.hrl"). %% API -export([start_link/1]). -export([change_log_level/2]). -export([change_level/3]). -export([add_logger/1]). -export([add_appender/3]). -export([change_format/3]). -export([log/4]). start...
null
https://raw.githubusercontent.com/peterholko/pax_server/62b2ec1fae195ff915d19af06e56a7c4567fd4b8/lib/log4erl/src/log_manager.erl
erlang
API try Apps = gen_event:which_handlers(Logger) case lists:filter(fun({_,X}) -> X =:= Appender end, Apps) of [] -> {error, no_appender_found}; ?LOG2("get apps: ~p~n",[Apps1]), end catch exit:noproc -> {error, no_such_logger} end. try Apps = gen_event:which_h...
-module(log_manager). -author("Ahmed Al-Issaei"). -license("MPL-1.1"). -include("../include/log4erl.hrl"). -export([start_link/1]). -export([change_log_level/2]). -export([change_level/3]). -export([add_logger/1]). -export([add_appender/3]). -export([change_format/3]). -export([log/4]). start_link(Lo...
947bc2b96079da118b5f7f3e183bc851d5ac64036f304b4d8c6c2f79a431f0d3
evertedsphere/silica
Prism.hs
# LANGUAGE CPP # ----------------------------------------------------------------------------- -- | -- Module : Silica.Internal.Prism Copyright : ( C ) 2012 - 2016 -- License : BSD-style (see the file LICENSE) Maintainer : < > -- Stability : experimental -- Portability : non-portable --...
null
https://raw.githubusercontent.com/evertedsphere/silica/346006f7b58142c6479395e93338134f541034cc/src/Silica/Internal/Prism.hs
haskell
--------------------------------------------------------------------------- | Module : Silica.Internal.Prism License : BSD-style (see the file LICENSE) Stability : experimental Portability : non-portable -------------------------------------------------------------------------- --------------------...
# LANGUAGE CPP # Copyright : ( C ) 2012 - 2016 Maintainer : < > module Silica.Internal.Prism ( Market(..) , Market' ) where import Data.Profunctor #ifndef SAFE import Data.Profunctor.Unsafe import Silica.Internal.Coerce #endif | This type is used internally by the ' Silica . Prism . Prism '...
70ba1ff3e5857c3a14c3f87a9165c371f4fc28de6997b7ba771e435cdbcbab0b
anmonteiro/ocaml-quic
qstring.ml
---------------------------------------------------------------------------- * Copyright ( c ) 2020 * * 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...
null
https://raw.githubusercontent.com/anmonteiro/ocaml-quic/7f1a06fbe5380954bf49adc53a8fa7458bdc0024/qpack/src/qstring.ml
ocaml
---------------------------------------------------------------------------- * Copyright ( c ) 2020 * * 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...
f792f3d78029be159086af6054132d78690b7f5217f437bb908ad25a3b9ee4fa
Frechmatz/cl-synthesizer
example-4.lisp
(defpackage :cl-synthesizer-modules-vco-example-4 (:use :cl)) (in-package :cl-synthesizer-modules-vco-example-4) (defun example () "Plots phase and frequency of a frequency sweep." (let ((rack (cl-synthesizer:make-rack :environment (cl-synthesizer:make-environment)))) (cl-synthesizer:add-module rack ...
null
https://raw.githubusercontent.com/Frechmatz/cl-synthesizer/ba2e4003448829078187013f6723eb5c8ce8adbc/src/modules/vco/example-4.lisp
lisp
(run-example)
(defpackage :cl-synthesizer-modules-vco-example-4 (:use :cl)) (in-package :cl-synthesizer-modules-vco-example-4) (defun example () "Plots phase and frequency of a frequency sweep." (let ((rack (cl-synthesizer:make-rack :environment (cl-synthesizer:make-environment)))) (cl-synthesizer:add-module rack ...
7f77a2ede78fe4b2f9a7d1451adbcc5482bf7eb10efe9f39bee8b76d98d9ffb0
tomhanika/conexp-clj
base.clj
;; Copyright ⓒ the conexp-clj developers; all rights reserved. ;; The use and distribution terms for this software are covered by the Eclipse Public License 1.0 ( -1.0.php ) ;; which can be found in the file LICENSE at the root of this distribution. ;; By using this software in any fashion, you are agreeing to be bou...
null
https://raw.githubusercontent.com/tomhanika/conexp-clj/5e4c15697f06446f925f53d1d143528155d7dd3a/src/main/clojure/conexp/gui/base.clj
clojure
Copyright ⓒ the conexp-clj developers; all rights reserved. The use and distribution terms for this software are covered by the which can be found in the file LICENSE at the root of this distribution. By using this software in any fashion, you are agreeing to be bound by the terms of this license. You must not re...
Eclipse Public License 1.0 ( -1.0.php ) (ns conexp.gui.base "Provides basic definitions for the standard conexp-clj GUI." (:require [clojure.java.io :as io] [conexp.base :refer :all] [conexp.gui.editors.code :refer :all] [conexp.gui.editors.contexts :refer :all] [c...
cf229af8f8125fd8c1db69064ade0e025c851f2145679ae42b12ca8e40efa480
ghcjs/jsaddle-dom
PositionCallback.hs
# LANGUAGE PatternSynonyms # -- For HasCallStack compatibility {-# LANGUAGE ImplicitParams, ConstraintKinds, KindSignatures #-} # OPTIONS_GHC -fno - warn - unused - imports # module JSDOM.Generated.PositionCallback (newPositionCallback, newPositionCallbackSync, newPositionCallbackAsync, PositionCallback)...
null
https://raw.githubusercontent.com/ghcjs/jsaddle-dom/5f5094277d4b11f3dc3e2df6bb437b75712d268f/src/JSDOM/Generated/PositionCallback.hs
haskell
For HasCallStack compatibility # LANGUAGE ImplicitParams, ConstraintKinds, KindSignatures # | <-US/docs/Web/API/PositionCallback Mozilla PositionCallback documentation> | <-US/docs/Web/API/PositionCallback Mozilla PositionCallback documentation> | <-US/docs/Web/API/PositionCallback Mozilla PositionCallback docume...
# LANGUAGE PatternSynonyms # # OPTIONS_GHC -fno - warn - unused - imports # module JSDOM.Generated.PositionCallback (newPositionCallback, newPositionCallbackSync, newPositionCallbackAsync, PositionCallback) where import Prelude ((.), (==), (>>=), return, IO, Int, Float, Double, Bool(..), Maybe, ma...
9d8889c6bdfb95ca3efd8079d5019c7259233dafe821a3359e5d5aafaa0450d5
manuel-serrano/bigloo
object.scm
;<font size="-3"><pre> ;*=====================================================================*/ * serrano / prgm / project / bigloo / examples / Object / object.scm * / ;* ------------------------------------------------------------- */ ;* Author : SERRANO Manuel ...
null
https://raw.githubusercontent.com/manuel-serrano/bigloo/eb650ed4429155f795a32465e009706bbf1b8d74/examples/Object/object.scm
scheme
<font size="-3"><pre> *=====================================================================*/ * ------------------------------------------------------------- */ * Author : SERRANO Manuel */ * ------------------------------------------------------------- */ *=====...
* serrano / prgm / project / bigloo / examples / Object / object.scm * / * Creation : Thu Mar 6 10:46:53 1997 * / * Last change : Thu Mar 6 11:00:33 1997 ( serrano ) * / * An example of Bigloo objects *...
33ecd66eedfe785dc7b29e755fcbf39cce0f7e4f9387a5f5a0ef6e425a8d2191
rescript-lang/rescript-compiler
lam_pass_count.ml
(***********************************************************************) (* *) (* OCaml *) (* *) , projet ...
null
https://raw.githubusercontent.com/rescript-lang/rescript-compiler/5da6c88fb9237fbc4d61640187b82627690ccf39/jscomp/core/lam_pass_count.ml
ocaml
********************************************************************* OCaml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et en Automatique . All rights reserved . This file is distributed under the terms of the Q Public License version 1.0 . Adapted for Javascript backend : , ...
ff88df9d3c7e7b44dad1e5255e89717fddf1e879acdf8d4a19ade5170c001f29
jeffshrager/biobike
package.lisp
-*- Package : cl - user ; mode : lisp ; base : 10 ; Syntax : Common - Lisp ; -*- (in-package :cl-user) ;;; +=========================================================================+ | Copyright ( c ) 2002 , 2003 , 2004 JP , , | ;;; | ...
null
https://raw.githubusercontent.com/jeffshrager/biobike/5313ec1fe8e82c21430d645e848ecc0386436f57/BioLisp/Wlisp/package.lisp
lisp
mode : lisp ; base : 10 ; Syntax : Common - Lisp ; -*- +=========================================================================+ | | | Permission is hereby granted, free of charge, to any person obtaining | | a copy of this software and as...
(in-package :cl-user) | Copyright ( c ) 2002 , 2003 , 2004 JP , , | | " Software " ) , to deal in the Software without restriction , including | | distribute , sublicense , and/or sell copies of the Software , and to | | permit persons to whom the Software is furnished to do so , subject t...
f491560742305dff8f64335b54dcddfb91960f5b17e7a8da42e97cdeb9924616
danielsz/certificaat
certificate.clj
(ns certificaat.acme4j.certificate (:require [certificaat.domain :refer [Certificaat]] [certificaat.utils :refer [load-url]] [clojure.tools.logging :as log] [clojure.java.io :as io]) (:import [org.shredzone.acme4j Certificate RevocationReason] [org.shredzone.acme4j.uti...
null
https://raw.githubusercontent.com/danielsz/certificaat/955429f6303da9a687cf636d93437281f43ddb71/src/certificaat/acme4j/certificate.clj
clojure
(ns certificaat.acme4j.certificate (:require [certificaat.domain :refer [Certificaat]] [certificaat.utils :refer [load-url]] [clojure.tools.logging :as log] [clojure.java.io :as io]) (:import [org.shredzone.acme4j Certificate RevocationReason] [org.shredzone.acme4j.uti...
e897cd64a519c65c8beb7a70cac559381f4cd7268e682685678b70640fcc00e1
Shirakumo/kandria
remesh.lisp
(in-package #:org.shirakumo.fraf.kandria) (defclass remesh (tool) ()) (defmethod label ((tool remesh)) "") (defmethod title ((tool remesh)) "Remesh") (defmethod handle ((event mouse-press) (tool remesh)) (let ((loc (mouse-world-pos (pos event)))) (case (button event) (:left (add-vertex (entity ...
null
https://raw.githubusercontent.com/Shirakumo/kandria/58b4c62796f1ebee33755e162d4155ca6590c7a3/editor/remesh.lisp
lisp
(in-package #:org.shirakumo.fraf.kandria) (defclass remesh (tool) ()) (defmethod label ((tool remesh)) "") (defmethod title ((tool remesh)) "Remesh") (defmethod handle ((event mouse-press) (tool remesh)) (let ((loc (mouse-world-pos (pos event)))) (case (button event) (:left (add-vertex (entity ...
bbfe08e3a0be8106dd8502f330440144225a663c2b7424ee7a8034d84ea8d70d
threatgrid/ctia
store_test.clj
(ns ctia.task.migration.store-test (:require [clj-momo.lib.clj-time.coerce :as time-coerce] [clj-momo.lib.clj-time.core :as time] [ductile [index :as ductile.index] [document :as es-doc]] [clojure.java.io :as io] [clojure.string :as str] ...
null
https://raw.githubusercontent.com/threatgrid/ctia/f52f836172f3cee7566f283ad4ff3a12932501c0/test/ctia/task/migration/store_test.clj
clojure
simple way to have a proper store initialization ensure indices refresh ensure indices refresh
(ns ctia.task.migration.store-test (:require [clj-momo.lib.clj-time.coerce :as time-coerce] [clj-momo.lib.clj-time.core :as time] [ductile [index :as ductile.index] [document :as es-doc]] [clojure.java.io :as io] [clojure.string :as str] ...
7fd0d8019bab932b478ada51107b5d39f99a30de0d58c708b59a8ced2fe5e07c
nomasystems/nqueue
nqueue_consumer.erl
Copyright 2022 Nomasystems , S.L. %% 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 %% %% -2.0 %% %% Unless required by applicable law or agreed to in writing, software distri...
null
https://raw.githubusercontent.com/nomasystems/nqueue/54de961fba296592cc39bbe1de8603b1c3d4e168/src/nqueue_consumer.erl
erlang
you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing perm...
Copyright 2022 Nomasystems , S.L. Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(nqueue_consumer). -include_lib("kernel/include/logger.hrl"). START / STOP EXPORTS -export([start_monitor/2]). INTERNAL EXPORT...
0ca6627740bc4e5cbb847303baf5e8683397a3deacaefa2936dd4365926b2edb
clojure/tools.namespace
reload.clj
Copyright ( c ) , 2012 . All rights reserved . The use and distribution terms for this software are covered by the Eclipse ;; Public License 1.0 (-1.0.php) ;; which can be found in the file epl-v10.html at the root of this ;; distribution. By using this software in any fashion, you are ;; agreeing to be bound by ...
null
https://raw.githubusercontent.com/clojure/tools.namespace/de4bbf1302763d2342d1301245329bd8a3460da7/src/main/clojure/clojure/tools/namespace/reload.clj
clojure
Public License 1.0 (-1.0.php) which can be found in the file epl-v10.html at the root of this distribution. By using this software in any fashion, you are agreeing to be bound by the terms of this license. You must not remove this notice, or any other, from this software.
Copyright ( c ) , 2012 . All rights reserved . The use and distribution terms for this software are covered by the Eclipse (ns ^{:author "Stuart Sierra" :doc "Force reloading namespaces on demand or through a dependency tracker"} clojure.tools.namespace.reload (:require [clojure.tools.namespace.t...
491ff8e8dd4a17e5bc6959224ef815800b9dda109a63078af989e92abfc3ad31
ml4tp/tcoq
locality.ml
(************************************************************************) v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2017 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *...
null
https://raw.githubusercontent.com/ml4tp/tcoq/7a78c31df480fba721648f277ab0783229c8bece/toplevel/locality.ml
ocaml
********************************************************************** // * This file is distributed under the terms of the * GNU Lesser General Public License Version 2.1 ********************************************************************** * * Managing locality * Extracting ...
v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2017 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * open Pp let local_of_bool =...
ea311caf350527679f91dbc505b00366fda6e652c64d20b683b54891f9e53397
clojure/clojurescript
b.cljs
(ns code.split.b (:require [cljs.loader :as loader] [code.split.d :as d])) (defn hello [] (println "Hello from code.split.b.") (d/hello)) (loader/set-loaded! :b)
null
https://raw.githubusercontent.com/clojure/clojurescript/a4673b880756531ac5690f7b4721ad76c0810327/src/test/cljs_build/code-split/src/code/split/b.cljs
clojure
(ns code.split.b (:require [cljs.loader :as loader] [code.split.d :as d])) (defn hello [] (println "Hello from code.split.b.") (d/hello)) (loader/set-loaded! :b)
98c7448d71795bb8d4adcbfe4cddc786ea992082203cb7eae3d5381944e5953b
tud-fop/vanda-haskell
CBSM.hs
----------------------------------------------------------------------------- -- | -- Module : VandaCLI.CBSM -- Copyright : (c) Technische Universität Dresden 2014–2017 -- License : BSD-style -- -- Maintainer : -- Stability : unknown -- Portability : portable ---------------------------------------...
null
https://raw.githubusercontent.com/tud-fop/vanda-haskell/3214966361b6dbf178155950c94423eee7f9453e/executable/VandaCLI/CBSM.hs
haskell
--------------------------------------------------------------------------- | Module : VandaCLI.CBSM Copyright : (c) Technische Universität Dresden 2014–2017 License : BSD-style Maintainer : Stability : unknown Portability : portable ---------------------------------------------------------...
module VandaCLI.CBSM ( main , mainArgs , cmdArgs , Args() ) where import Control.Arrow (second) import qualified Codec.Compression.GZip as GZip import Control.Concurrent (getNumCapabilities) import Control.Monad import qualified Data.Binary as B import qualified Data.ByteString.Lazy as...
e24631f52f0c39c08ab02a072d754345804342c065a095e6e26b9115c0309422
melisgl/planet-wars
functions.lisp
(in-package :alexandria) (declaim (inline ensure-function)) ; to propagate return type. (declaim (ftype (function (t) (values function &optional)) ensure-function)) (defun ensure-function (function-designator) "Returns the function designated by FUNCTION-DESIGNATOR: if FUNCTION-DESIGNATOR is a funct...
null
https://raw.githubusercontent.com/melisgl/planet-wars/499742d5fb46edeb114f2996b01b0343cf42b76a/src/alexandria/functions.lisp
lisp
to propagate return type. non-NIL value of the last predicate if all succeed. Using M-V-C we don't need to append the arguments.
(in-package :alexandria) (declaim (ftype (function (t) (values function &optional)) ensure-function)) (defun ensure-function (function-designator) "Returns the function designated by FUNCTION-DESIGNATOR: if FUNCTION-DESIGNATOR is a function, it is returned, otherwise it must be a function name and i...
1f052507b499187d5c495d55e3e30591f8c88e61118adc2e66770801022662ac
tonyg/kali-scheme
vector2.scm
(define-local-syntax (define-primitive id nargs) (let ((args (reverse (list-tail '(z y x) (- '3 nargs))))) `(define (,id . ,args) (call-primitively ,id . ,args)))) (define-primitive + 2) (define-primitive - 2) (define-primitive * 2) (define-primitive < 2) (define-primitive make-vector 2) (define-primiti...
null
https://raw.githubusercontent.com/tonyg/kali-scheme/79bf76b4964729b63fce99c4d2149b32cb067ac0/ps-compiler/prescheme/test/vector2.scm
scheme
(define-local-syntax (define-primitive id nargs) (let ((args (reverse (list-tail '(z y x) (- '3 nargs))))) `(define (,id . ,args) (call-primitively ,id . ,args)))) (define-primitive + 2) (define-primitive - 2) (define-primitive * 2) (define-primitive < 2) (define-primitive make-vector 2) (define-primiti...
9d0f9a02ba229d77e01377600063e317c459bc5b9199fbd07b1fc2303fb2d645
purescript/purescript
Exports.hs
module Language.PureScript.Sugar.Names.Exports ( findExportable , resolveExports ) where import Prelude import Control.Monad import Control.Monad.Writer.Class (MonadWriter(..)) import Control.Monad.Error.Class (MonadError(..)) import Data.Function (on) import Data.Foldable (traverse_) import Data.List (interse...
null
https://raw.githubusercontent.com/purescript/purescript/02bd6ae60bcd18cbfa892f268ef6359d84ed7c9b/src/Language/PureScript/Sugar/Names/Exports.hs
haskell
| Finds all exportable members of a module, disregarding any explicit exports. | exported and elaborating re-exports of other modules. Takes the current module's imports, the accumulated list of exports, and a `DeclarationRef` for an explicit export. When the ref refers to another module, export anything from ...
module Language.PureScript.Sugar.Names.Exports ( findExportable , resolveExports ) where import Prelude import Control.Monad import Control.Monad.Writer.Class (MonadWriter(..)) import Control.Monad.Error.Class (MonadError(..)) import Data.Function (on) import Data.Foldable (traverse_) import Data.List (interse...
009daa018578197ef31fb91f5125fdb09a8c9d176e35dbdbadc758399e98e3b2
vseloved/cl-nlp
wikipedia.lisp
( c ) 2015 - 2017 Vsevolod Dyomkin (in-package #:nlp.contrib.corpora) (named-readtables:in-readtable rutilsx-readtable) (defmethod read-corpus-file ((type (eql :wikipedia)) path &key preserve-markup?) (mv-bind (_ texts all-pars titles) (cxml:parse-file path (make 'wiki-sax :preserve-markup? preserve-markup...
null
https://raw.githubusercontent.com/vseloved/cl-nlp/f180b6c3c0b9a3614ae43f53a11bc500767307d0/contrib/corpora/wikipedia.lisp
lisp
do nothing do nothing
( c ) 2015 - 2017 Vsevolod Dyomkin (in-package #:nlp.contrib.corpora) (named-readtables:in-readtable rutilsx-readtable) (defmethod read-corpus-file ((type (eql :wikipedia)) path &key preserve-markup?) (mv-bind (_ texts all-pars titles) (cxml:parse-file path (make 'wiki-sax :preserve-markup? preserve-markup...
c84c6e42c151ed079b8104f112ba50966c88ebc5e77e344c9306d14f991b3d0e
opencog/pln
simple-consequent-disjunction-elimination.scm
;; Simple KB to test consequent-disjunction-elimination-rule (define P (Predicate "P" (stv 0.02 0.6))) (define Q1 (Predicate "Q1" (stv 0.01 0.7))) (define Q2 (Predicate "Q2" (stv 0.05 0.8))) (Implication (stv 0.3 0.7) P (Or Q1 Q2)) (Implication (stv 0.2 0.6) P Q2)
null
https://raw.githubusercontent.com/opencog/pln/52dc099e21393892cf5529fef687a69682436b2d/tests/pln/rules/simple-consequent-disjunction-elimination.scm
scheme
Simple KB to test consequent-disjunction-elimination-rule
(define P (Predicate "P" (stv 0.02 0.6))) (define Q1 (Predicate "Q1" (stv 0.01 0.7))) (define Q2 (Predicate "Q2" (stv 0.05 0.8))) (Implication (stv 0.3 0.7) P (Or Q1 Q2)) (Implication (stv 0.2 0.6) P Q2)
0b42a320aea069cbc1023d9e364c2af6c4af5f989e238db917439a8a105dfa2a
BitGameEN/bitgamex
luerl_funcall_tests.erl
@author < > ( C ) 2015 , 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 %%% %%% -2.0 %%% %%% Unless required by applicable law or agreed to in writing, software...
null
https://raw.githubusercontent.com/BitGameEN/bitgamex/151ba70a481615379f9648581a5d459b503abe19/src/deps/luerl/test/luerl_funcall_tests.erl
erlang
you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing...
@author < > ( C ) 2015 , Licensed under the Apache License , Version 2.0 ( the " License " ) ; software distributed under the License is distributed on an " AS Created : 11 Jan 2015 by < > -module(luerl_funcall_tests). -include_lib("eunit/include/eunit.hrl"). external_fun_test() -> State...
cd21e27b2676fe8c79703b1f6ac52e8cca9585a3644a70cd71cf50ca149861b2
haskell-works/avro
Main.hs
# LANGUAGE CPP # # LANGUAGE OverloadedLists # # LANGUAGE ScopedTypeVariables # module Main where #if defined(i386_HOST_ARCH) || defined(x86_64_HOST_ARCH) import qualified Bench.Deconflict as Deconflict import qualified Bench.Encoding as Encoding import Gauge #endif main :: IO () main = #if de...
null
https://raw.githubusercontent.com/haskell-works/avro/1eb14601eb8c782f7063ecf9571488d149f9cac1/bench/Main.hs
haskell
# LANGUAGE CPP # # LANGUAGE OverloadedLists # # LANGUAGE ScopedTypeVariables # module Main where #if defined(i386_HOST_ARCH) || defined(x86_64_HOST_ARCH) import qualified Bench.Deconflict as Deconflict import qualified Bench.Encoding as Encoding import Gauge #endif main :: IO () main = #if de...
88fbe16f6676ea9414e72256cddf99e9e61c35177d28a9a3a00e42c4d8ff3f4b
well-typed/cborg
PkgStore.hs
# OPTIONS_GHC -fno - warn - orphans -fsimpl - tick - factor=500 # module Macro.PkgStore where import Macro.Types import Data.Store as Store import Data.ByteString as BS serialise :: [GenericPackageDescription] -> BS.ByteString serialise pkgs = Store.encode pkgs deserialise :: ByteString -> [GenericPackageDescription...
null
https://raw.githubusercontent.com/well-typed/cborg/9be3fd5437f9d2ec1df784d5d939efb9a85fd1fb/serialise/bench/versus/Macro/PkgStore.hs
haskell
# OPTIONS_GHC -fno - warn - orphans -fsimpl - tick - factor=500 # module Macro.PkgStore where import Macro.Types import Data.Store as Store import Data.ByteString as BS serialise :: [GenericPackageDescription] -> BS.ByteString serialise pkgs = Store.encode pkgs deserialise :: ByteString -> [GenericPackageDescription...
b8d4660e07f11b71001577c8dd11ee51eeca8c482dbf9117c119a268af5232e3
Cipherwraith/hblog
Utility.hs
module Utility where import Data.Time import Data.Time.Clock.POSIX import qualified Data.Text.Lazy as T import Data.Char removeWhitespace :: T.Text -> T.Text removeWhitespace = T.pack . filter (not . isSpace) . T.unpack removeNonAlphaNum :: T.Text -> T.Text removeNonAlphaNum = T.pack . filter (isAlphaNum) . T.unpac...
null
https://raw.githubusercontent.com/Cipherwraith/hblog/f92d96a60e301302c8a0e46fd68ee1e1810eb031/Utility.hs
haskell
module Utility where import Data.Time import Data.Time.Clock.POSIX import qualified Data.Text.Lazy as T import Data.Char removeWhitespace :: T.Text -> T.Text removeWhitespace = T.pack . filter (not . isSpace) . T.unpack removeNonAlphaNum :: T.Text -> T.Text removeNonAlphaNum = T.pack . filter (isAlphaNum) . T.unpac...
c7e2467e1bb4f7ea4ad2c8272c9ece687410a921fd8754040499905728e9aa42
AlexeyRaga/azure-functions-haskell-worker
Worker.hs
module Azure.Functions.Worker ( runWorker ) where import Azure.Functions.Commands.Init (initCommand) import Azure.Functions.Commands.Run (runCommand) import Azure.Functions.Registry (Registry) import Control.Monad (join) import Options.Applicative...
null
https://raw.githubusercontent.com/AlexeyRaga/azure-functions-haskell-worker/a2fd35c5c4661e6255016bc004681c451b8beb46/azure-functions-worker/src/Azure/Functions/Worker.hs
haskell
module Azure.Functions.Worker ( runWorker ) where import Azure.Functions.Commands.Init (initCommand) import Azure.Functions.Commands.Run (runCommand) import Azure.Functions.Registry (Registry) import Control.Monad (join) import Options.Applicative...
c0bb8756032021dbf36153ec2bfa3d7985adbe3397c89de14e13cf4d3db0cd3f
AndrasKovacs/ELTE-func-lang
Tut06.hs
{-# OPTIONS -Wincomplete-patterns #-} # LANGUAGE InstanceSigs , DeriveFunctor # module Tut06 where import Prelude hiding (Foldable(..)) import Control.Monad import Data.Monoid The State monad data State s a = State { runState :: s -> (a, s) } deriving (Functor) instance Applicative (State s) where pure = ret...
null
https://raw.githubusercontent.com/AndrasKovacs/ELTE-func-lang/22a5ca472eea135f45592c8c262dc8e73161cb59/2021-22-1/gyak_3/Tut06.hs
haskell
# OPTIONS -Wincomplete-patterns # Basic operations: Examples: forM :: Monad m => [a] -> (a -> m b) -> m [b] forM _ discards the results of forM Example: x := x+1 x := x * i impFibo should be a translation of the imperative program (a, b) := (b, a+b) (a,b) <- get put (b, a+b) impGcd should be a ...
# LANGUAGE InstanceSigs , DeriveFunctor # module Tut06 where import Prelude hiding (Foldable(..)) import Control.Monad import Data.Monoid The State monad data State s a = State { runState :: s -> (a, s) } deriving (Functor) instance Applicative (State s) where pure = return (<*>) = ap instance Monad (Stat...
25e3318d891f217434dfb36e706b80774c0dd0dfeb56b72b9cccd73525193fc9
LastStar/showrum
hooks.cljs
(ns showrum.frontend.hooks (:require ["react" :as react] [hx.react :as hx])) (defn <-derive "Takes an atom and a function that provides derivation of atom value. It returns the derivate and rerenders the component, if derivate changes." ;; If no function is passed in, we assume we want value of the ato...
null
https://raw.githubusercontent.com/LastStar/showrum/fb73e9612e4525e32b6b936179d901be50019fb5/src/showrum/frontend/hooks.cljs
clojure
If no function is passed in, we assume we want value of the atom if no deps are passed in, we assume we only want to run create a react/useState hook to track and trigger renders react/useEffect hook to create and track the subscription to the iref update the react state on each change return a function to tell r...
(ns showrum.frontend.hooks (:require ["react" :as react] [hx.react :as hx])) (defn <-derive "Takes an atom and a function that provides derivation of atom value. It returns the derivate and rerenders the component, if derivate changes." ([a] (<-derive a identity [])) subscrib / unsubscribe on mount /...
a719030b47d7ea99f80051b2681a3416026ba58c7a69002d7ab750d6b7a51884
jepsen-io/voltdb
core_test.clj
(ns replication-model.core-test (:require [clojure.test :refer :all] [clojure.pprint :refer [pprint]] [replication-model.core :refer :all])) (deftest net-nodes-test (is (-> (state 3) :net net-nodes sort (= [0 1 2])))) (deftest broadcast-test (is (-...
null
https://raw.githubusercontent.com/jepsen-io/voltdb/7c29d0d6caa29b85143d6942e078d7c0bdb82e35/replication-model/test/replication_model/core_test.clj
clojure
(ns replication-model.core-test (:require [clojure.test :refer :all] [clojure.pprint :refer [pprint]] [replication-model.core :refer :all])) (deftest net-nodes-test (is (-> (state 3) :net net-nodes sort (= [0 1 2])))) (deftest broadcast-test (is (-...
84b11e55922a6eee2eb9f4f8c21355cfdcfeaf7a1fd4f9f7a1fd20c53e4468b6
bugczw/Introduction-to-Functional-Programming-in-OCaml
W2_S3_1.ml
FINDING THE MINIMUM ( 20/20 points ) Consider a non empty array of integers a. Write a function min : int array - > int that returns the minimal element of a. Write a function min_index : int array - > int that returns the index of the minimal element of a. Do you think these functions work well on large a...
null
https://raw.githubusercontent.com/bugczw/Introduction-to-Functional-Programming-in-OCaml/13c4d1f92e7479f8eb10ea5d4c43a598b6676d0f/OCaml_MOOC_W2_ALL/Exercise/W2_S3_1.ml
ocaml
FINDING THE MINIMUM ( 20/20 points ) Consider a non empty array of integers a. Write a function min : int array - > int that returns the minimal element of a. Write a function min_index : int array - > int that returns the index of the minimal element of a. Do you think these functions work well on large a...
170ec1a83fdccdddad8691aae42468f95909cadb3b8f53fd2f52f0586d2f3ec7
fukamachi/lack
backtrace.lisp
(in-package :cl-user) (defpackage t.lack.middleware.backtrace (:use :cl :lack :lack.test :prove)) (in-package :t.lack.middleware.backtrace) (plan 6) (let ((app (builder (:backtrace :result-on-error `(500 (:content-type "text/plain") ("Internal Server Error"))) ...
null
https://raw.githubusercontent.com/fukamachi/lack/1f155216aeea36291b325c519f041e469262a399/t/middleware/backtrace.lisp
lisp
(in-package :cl-user) (defpackage t.lack.middleware.backtrace (:use :cl :lack :lack.test :prove)) (in-package :t.lack.middleware.backtrace) (plan 6) (let ((app (builder (:backtrace :result-on-error `(500 (:content-type "text/plain") ("Internal Server Error"))) ...
a9ea06912513f542eb508f6aec4245e7df1341728d373f4abf8d984fadd9ae96
orthecreedence/cl-libuv
util.lisp
(in-package :libuv) (defun errval (err) "Get an error constant value by its name keyword. So :etimedout gets the enum UV_ETIMEDOUT" (cffi:foreign-enum-value 'uv:uv-errno-t err)) (defparameter *handle-types* '(async check fs-event fs-poll handle idle named-pipe poll prepare ...
null
https://raw.githubusercontent.com/orthecreedence/cl-libuv/f811e50027e882eae5523c73798fbf6554a15850/util.lisp
lisp
(in-package :libuv) (defun errval (err) "Get an error constant value by its name keyword. So :etimedout gets the enum UV_ETIMEDOUT" (cffi:foreign-enum-value 'uv:uv-errno-t err)) (defparameter *handle-types* '(async check fs-event fs-poll handle idle named-pipe poll prepare ...
71a05459123b7ec8fc5b87632cab9d31af66fd094f18ed623cf61846014915a1
footprintanalytics/footprint-web
common.clj
(ns metabase.pulse.render.common (:require [clojure.pprint :refer [cl-format]] [clojure.string :as str] hiccup.util [metabase.public-settings :as public-settings] [metabase.shared.models.visualization-settings :as mb.viz] [metabase.shared.util.currency :as c...
null
https://raw.githubusercontent.com/footprintanalytics/footprint-web/d3090d943dd9fcea493c236f79e7ef8a36ae17fc/src/metabase/pulse/render/common.clj
clojure
this type is used to do special formatting in other this returns true for bigint only, not normal int or long this returns true for bigdec only, not actual normal decimals not the clearest clojure native function in the world
(ns metabase.pulse.render.common (:require [clojure.pprint :refer [cl-format]] [clojure.string :as str] hiccup.util [metabase.public-settings :as public-settings] [metabase.shared.models.visualization-settings :as mb.viz] [metabase.shared.util.currency :as c...
35b7219fc5c633e0fbbdc4f561a4a0da72554e7f26cbe4ffb67e595207e1a267
copton/ocram
Filter.hs
# LANGUAGE TemplateHaskell , GADTs # module Ocram.Intermediate.Filter exports { { { 1 ( ir_constraints , ErrorCode(..) -- for testing ) where imports { { { 1 import Compiler.Hoopl (foldGraphNodes) import Data.Generics (everything, mkQ) import Language.C.Syntax.AST import Language.C.Data.Node (nodeInfo) impo...
null
https://raw.githubusercontent.com/copton/ocram/c7166eab0187868a52a61017c6d3687e5a1a6162/ocram/src/Ocram/Intermediate/Filter.hs
haskell
for testing
# LANGUAGE TemplateHaskell , GADTs # module Ocram.Intermediate.Filter exports { { { 1 ( ir_constraints ) where imports { { { 1 import Compiler.Hoopl (foldGraphNodes) import Data.Generics (everything, mkQ) import Language.C.Syntax.AST import Language.C.Data.Node (nodeInfo) import Ocram.Debug.Enriched (ENodeInf...
3179d7ec19853fd7a982a3548a5157c5b3e4455926e6e7da588760b41353366b
mgritter/aoc-lh
ExperimentCase.hs
module ExperimentCase where {-@ LIQUID "--max-case-expand=10" @-} {-@ measure depth :: ExprTree -> Nat @-} @ data ExprTree where ConstantE : : Int - > { e : ExprTree | depth e = = 0 } | VariableE : : constantTerm : Int - > { e : ExprTree | depth e = = 0 } | AddE : : left : ExprTree - > right : ExprTree...
null
https://raw.githubusercontent.com/mgritter/aoc-lh/410a1fccbc5d6c2e10cf31aa3275d53de8c57396/2022/day21/ExperimentCase.hs
haskell
@ LIQUID "--max-case-expand=10" @ @ measure depth :: ExprTree -> Nat @ @ simplify :: e:ExprTree -> {se:ExprTree | isSimple se } / [ depth e ] @
module ExperimentCase where @ data ExprTree where ConstantE : : Int - > { e : ExprTree | depth e = = 0 } | VariableE : : constantTerm : Int - > { e : ExprTree | depth e = = 0 } | AddE : : left : ExprTree - > right : ExprTree - > { e : ExprTree | depth e > depth left & & depth e > depth right } | Er...
0caeb2a3b85c687119e506bf6638fbca83fee6194ebdc81a385cf12c3f421d27
ocaml-flambda/flambda-backend
linear_to_cfg.ml
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * MIT License * * ...
null
https://raw.githubusercontent.com/ocaml-flambda/flambda-backend/bed9613a24b4bc5ed377ca20c3b685195c993e21/backend/cfg/linear_to_cfg.ml
ocaml
* Maps labels of blocks to trap handler stacks at the beginning of the block. * Maps labels to trap stacks at each raise point in the corresponding block. CR-someday gyorsh: this won't be needed after block splitting, as it will be uniquely determined by the top of the trap stack. * A...
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * MIT License * * ...
81b661711315fe6e68bf7ee0097ffc75bf15ca8a4f8e0e856e4102a110d249f9
honest-technology/api.unverified.email
Usage.hs
module Action.Usage (usage) where import Protolude import Web.Scotty (ActionM, text) import qualified Env import qualified Model.Usage usage :: ActionM () usage = Model.Usage.plainText <$> Env.apiURL <*> Env.infoPageURL <*> Env.smtpURL >>= text
null
https://raw.githubusercontent.com/honest-technology/api.unverified.email/75234625974d8054f28a5c05cc313c927ffae8d5/src/Action/Usage.hs
haskell
module Action.Usage (usage) where import Protolude import Web.Scotty (ActionM, text) import qualified Env import qualified Model.Usage usage :: ActionM () usage = Model.Usage.plainText <$> Env.apiURL <*> Env.infoPageURL <*> Env.smtpURL >>= text
8e492d38787c6710dd2c3868de21d1593b6da4e500dc785db448eff6935dd276
alanz/ghc-exactprint
Stmts.hs
module Stmts where -- Make sure we get all the semicolons in statements ;;;; ;; import Data.List ; ; ; import Data.Maybe ; ;; foo :: IO () foo = do do { ;;;; a } a ; ;; bar :: IO () bar = do { ; ; a ;; b } ; ;; ; baz :: IO () baz = do { ;; s ; s ; ; s ;; } ; a = undefined b = undefined s = undef...
null
https://raw.githubusercontent.com/alanz/ghc-exactprint/309efa8689e1ce2407523ba2ebe058b97757ba8b/tests/examples/ghc710/Stmts.hs
haskell
Make sure we get all the semicolons in statements
module Stmts where ;;;; ;; import Data.List ; ; ; import Data.Maybe ; ;; foo :: IO () foo = do do { ;;;; a } a ; ;; bar :: IO () bar = do { ; ; a ;; b } ; ;; ; baz :: IO () baz = do { ;; s ; s ; ; s ;; } ; a = undefined b = undefined s = undefined
1307a6d46c433eed39bdcea2bdf82a49e240c491e79cac894c21d2a8a5f1c8ca
coq/coq
genredexpr.ml
(************************************************************************) (* * The Coq Proof Assistant / The Coq Development Team *) v * Copyright INRIA , CNRS and contributors < O _ _ _ , , * ( see version control and CREDITS file for authors & dates ) \VV/ * * *...
null
https://raw.githubusercontent.com/coq/coq/110921a449fcb830ec2a1cd07e3acc32319feae6/tactics/genredexpr.ml
ocaml
********************************************************************** * The Coq Proof Assistant / The Coq Development Team // * This file is distributed under the terms of the * (see LICENSE file for the text of the license) ************************************...
v * Copyright INRIA , CNRS and contributors < O _ _ _ , , * ( see version control and CREDITS file for authors & dates ) \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * GNU Lesser Gener...