_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
7b2aea08832ce24cd6ad16aad6787822d07772979864c7b3197b75499cb4e483
arttuka/reagent-material-ui
filled_input.cljs
(ns reagent-mui.material.filled-input "Imports @mui/material/FilledInput as a Reagent component. Original documentation is at -ui/api/filled-input/ ." (:require [reagent.core :as r] ["@mui/material/FilledInput" :as MuiFilledInput])) (def filled-input (r/adapt-react-class (.-default MuiFilledInput)))...
null
https://raw.githubusercontent.com/arttuka/reagent-material-ui/14103a696c41c0eb67fc07fc67cd8799efd88cb9/src/core/reagent_mui/material/filled_input.cljs
clojure
(ns reagent-mui.material.filled-input "Imports @mui/material/FilledInput as a Reagent component. Original documentation is at -ui/api/filled-input/ ." (:require [reagent.core :as r] ["@mui/material/FilledInput" :as MuiFilledInput])) (def filled-input (r/adapt-react-class (.-default MuiFilledInput)))...
c41bdfe2e725a284bec407d43eba369935e41ffe2fb2e87a5cc3e2490e551903
malcolmreynolds/GSLL
spherical-vector.lisp
Regression test SPHERICAL - VECTOR for GSLL , automatically generated (in-package :gsl) (LISP-UNIT:DEFINE-TEST SPHERICAL-VECTOR (LISP-UNIT::ASSERT-NUMERICAL-EQUAL (LIST (LIST -0.617745613497854d0 -0.7863779988047479d0 0.993748310886084d0 0.1116436053298841d0 -0.9458104280982743d0 0.3247193158722761d0...
null
https://raw.githubusercontent.com/malcolmreynolds/GSLL/2f722f12f1d08e1b9550a46e2a22adba8e1e52c4/tests/spherical-vector.lisp
lisp
Regression test SPHERICAL - VECTOR for GSLL , automatically generated (in-package :gsl) (LISP-UNIT:DEFINE-TEST SPHERICAL-VECTOR (LISP-UNIT::ASSERT-NUMERICAL-EQUAL (LIST (LIST -0.617745613497854d0 -0.7863779988047479d0 0.993748310886084d0 0.1116436053298841d0 -0.9458104280982743d0 0.3247193158722761d0...
0a93a0e6c5a5128ab5a73cae8fe479daa840c995a2286106978903d7609a0ad9
tweag/ormolu
proc-ifs-out.hs
{-# LANGUAGE Arrows #-} foo f = proc a -> if a then f -< 0 else f -< 1 bar f g = proc a -> if f a then f . g -< a else g -< b
null
https://raw.githubusercontent.com/tweag/ormolu/34bdf62429768f24b70d0f8ba7730fc4d8ae73ba/data/examples/declaration/value/function/arrow/proc-ifs-out.hs
haskell
# LANGUAGE Arrows #
foo f = proc a -> if a then f -< 0 else f -< 1 bar f g = proc a -> if f a then f . g -< a else g -< b
1c096f5b7d8b3972d5c636a31525f086238a9636c7d4ef1b8555463bb97b9496
panicz/grasp
for.scm
(define-syntax for (syntax-rules (in from to below by ::) ((_ var :: type in collection . actions) (for-each (lambda (var :: type) . actions) collection)) ((_ var in collection . actions) (for-each (lambda (var) . actions) collection)) ((_ var from start to end by increment actions ...) ...
null
https://raw.githubusercontent.com/panicz/grasp/dcd0f92d58734efdd10191a31f8e80f47f98c3a7/src/for.scm
scheme
(define-syntax for (syntax-rules (in from to below by ::) ((_ var :: type in collection . actions) (for-each (lambda (var :: type) . actions) collection)) ((_ var in collection . actions) (for-each (lambda (var) . actions) collection)) ((_ var from start to end by increment actions ...) ...
cf95b7c44ba17e4c01d356092aaf5af3527e073027ecd8cea49cfb4551bbb6d3
ndmitchell/catch
ShowInt.hs
module ShowInt where main x = print (x :: Int)
null
https://raw.githubusercontent.com/ndmitchell/catch/5d834416a27b4df3f7ce7830c4757d4505aaf96e/examples/Example/ShowInt.hs
haskell
module ShowInt where main x = print (x :: Int)
742c7ab01ca298878e0da7b82a7014f2e78350b2a42eceec13d52de71b5cfd5f
2600hz-archive/whistle
ecallmgr_amqp_pool_worker_sup.erl
%%%------------------------------------------------------------------- @author < > ( C ) 2011 , VoIP INC %%% @doc %%% Start and stop worker processes %%% @end Created : 19 Sep 2011 by < > %%%------------------------------------------------------------------- -module(ecallmgr_amqp_pool_worker_sup). -behavi...
null
https://raw.githubusercontent.com/2600hz-archive/whistle/1a256604f0d037fac409ad5a55b6b17e545dcbf9/ecallmgr/src/ecallmgr_amqp_pool_worker_sup.erl
erlang
------------------------------------------------------------------- @doc Start and stop worker processes @end ------------------------------------------------------------------- API Supervisor callbacks =================================================================== API functions =============================...
@author < > ( C ) 2011 , VoIP INC Created : 19 Sep 2011 by < > -module(ecallmgr_amqp_pool_worker_sup). -behaviour(supervisor). -export([start_link/0, start_child/0, worker_count/0, release_all/0]). -export([init/1]). -define(SERVER, ?MODULE). ( ) - > { ok , Pid } | ignore | { error , Error } star...
c3a3cac2e2d445b033cb3e1b6c156e6cc93bb4aa915503668b584baa69448889
nuvla/api-server
event.clj
(ns sixsq.nuvla.server.resources.event " The `event` resources provide a timestamp and other information when some event occurs. These are used, for example, to mark changes in the lifecycle of an application. " (:require [sixsq.nuvla.auth.acl-resource :as a] [sixsq.nuvla.auth.utils :as auth] [sixsq.nuv...
null
https://raw.githubusercontent.com/nuvla/api-server/2b027d7493606bb7233321e8ceaa1645a0f09e69/code/src/sixsq/nuvla/server/resources/event.clj
clojure
use default ACL method available operations collection initialization
(ns sixsq.nuvla.server.resources.event " The `event` resources provide a timestamp and other information when some event occurs. These are used, for example, to mark changes in the lifecycle of an application. " (:require [sixsq.nuvla.auth.acl-resource :as a] [sixsq.nuvla.auth.utils :as auth] [sixsq.nuv...
ea0a95022b17d11d91f794e7c52168818e89481fed36fdf08cf6a760c28b489b
travisbrown/haskell-cpython
Types.hs
Copyright ( C ) 2009 < > -- -- 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 3 of the License , or -- any later version. -- -- This program is distributed in the hope that...
null
https://raw.githubusercontent.com/travisbrown/haskell-cpython/6c27e9412c17aa932177a293b39ed06c767654a2/lib/CPython/Types.hs
haskell
This program is free software: you can redistribute it and/or modify any later version. This program 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 GNU General Public License for mo...
Copyright ( C ) 2009 < > 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 CPython.Types ( ByteArray , Bytes , Capsule , Cell , Code , Compl...
b871d6323da858d9a9c1772f6a24e0c4bbb288a361fe3ec2003a842bcbc55ebe
donaldsonjw/bigloo
occur.scm
;*=====================================================================*/ * serrano / prgm / project / bigloo / comptime / Ast / occur.scm * / ;* ------------------------------------------------------------- */ * Author : * / * Creation ...
null
https://raw.githubusercontent.com/donaldsonjw/bigloo/a4d06e409d0004e159ce92b9908719510a18aed5/comptime/Ast/occur.scm
scheme
*=====================================================================*/ * ------------------------------------------------------------- */ * ------------------------------------------------------------- */ * Compute the occurrences number and compute the read/write */ * property of local varia...
* serrano / prgm / project / bigloo / comptime / Ast / occur.scm * / * Author : * / * Creation : Fri Jan 6 11:09:14 1995 * / * Last change : Mon Nov 11 17:17:35 2013 ( serrano ) * / (module ...
4a76e5b8c9f497befb3de0d0127c309aa3b39ea7bb3fc4e99412797f82fa160d
cbaggers/cepl
early.lisp
(in-package :cepl-utils) ;;---------------------------------------------------------------------- (defconstant +gl-enum-size+ #.(* 8 (cffi:foreign-type-size '%gl::enum))) ;;----------------------------------------------------------------------
null
https://raw.githubusercontent.com/cbaggers/cepl/d1a10b6c8f4cedc07493bf06aef3a56c7b6f8d5b/core/early.lisp
lisp
---------------------------------------------------------------------- ----------------------------------------------------------------------
(in-package :cepl-utils) (defconstant +gl-enum-size+ #.(* 8 (cffi:foreign-type-size '%gl::enum)))
8f55d6d0286afac5095db308e36259923209bf98cbfe16bad45b47edec99cc44
larcenists/larceny
sorting.sps
(import (tests r6rs sorting) (tests scheme test) (scheme write)) (display "Running tests for (rnrs sorting)\n") (run-sorting-tests) (report-test-results)
null
https://raw.githubusercontent.com/larcenists/larceny/fef550c7d3923deb7a5a1ccd5a628e54cf231c75/test/R7RS/Lib/tests/r6rs/run/sorting.sps
scheme
(import (tests r6rs sorting) (tests scheme test) (scheme write)) (display "Running tests for (rnrs sorting)\n") (run-sorting-tests) (report-test-results)
062254984801a4a6e9d3aa4117b5eac62a8423f19dae332bc81d81a2f055e1cb
LaurentRDC/pandoc-plot
PlantUML.hs
{-# LANGUAGE OverloadedStrings #-} # LANGUAGE QuasiQuotes # # LANGUAGE RecordWildCards # # LANGUAGE NoImplicitPrelude # -- | -- Module : $header$ Copyright : ( c ) , 2019 - present License : GNU GPL , version 2 or above -- Maintainer : -- Stability : internal -- Portability : portable -- -- R...
null
https://raw.githubusercontent.com/LaurentRDC/pandoc-plot/933daba593196bf3b1ae1f2022d17389552f275c/src/Text/Pandoc/Filter/Plot/Renderers/PlantUML.hs
haskell
# LANGUAGE OverloadedStrings # | Module : $header$ Maintainer : Stability : internal Portability : portable Rendering PlantUML markup the command below works as long as the script name is the same basename as the target figure path. E.g.: script basename of pandocplot123456789.txt will result in pand...
# LANGUAGE QuasiQuotes # # LANGUAGE RecordWildCards # # LANGUAGE NoImplicitPrelude # Copyright : ( c ) , 2019 - present License : GNU GPL , version 2 or above module Text.Pandoc.Filter.Plot.Renderers.PlantUML ( plantuml, plantumlSupportedSaveFormats, ) where import Data.Char import System.Fil...
536d38093585685f752825a4c80cc4d0d812ddc50d5747701b916f122c535b65
gwathlobal/CotD
window-character.lisp
(in-package :cotd) (defconstant +character-win-weapon&armor+ 0) (defconstant +character-win-abilities+ 1) (defconstant +character-win-effects+ 2) (defclass character-window (window) ((cur-tab :initform 0 :accessor cur-tab) (cur-sel :initform 0 :accessor cur-sel))) (defun get-mob-stats-line (mob) (l...
null
https://raw.githubusercontent.com/gwathlobal/CotD/d01ef486cc1d3b21d2ad670ebdb443e957290aa2/src/windows/window-character.lisp
lisp
(if (and (not (mob-is-ability-mutation *player* b)) (mob-is-ability-mutation *player* a)) t ...
(in-package :cotd) (defconstant +character-win-weapon&armor+ 0) (defconstant +character-win-abilities+ 1) (defconstant +character-win-effects+ 2) (defclass character-window (window) ((cur-tab :initform 0 :accessor cur-tab) (cur-sel :initform 0 :accessor cur-sel))) (defun get-mob-stats-line (mob) (l...
ffbd4b5a183d528df8bc7897d80b14ac6376dba26bc8b20d12a2ec3e31bfe157
janestreet/learn-ocaml-workshop
scaffold.ml
open Base module Position = struct type t = { x : int ; y : int } [@@deriving fields, sexp] let create = Fields.create end module Image = struct type t = | Frog_up | Frog_down | Frog_left | Frog_right | Car1_left | Car1_right | Car2_left | Car2_right | Car3_lef...
null
https://raw.githubusercontent.com/janestreet/learn-ocaml-workshop/1ba9576b48b48a892644eb20c201c2c4aa643c32/03-frogger/scaffold.ml
ocaml
open Base module Position = struct type t = { x : int ; y : int } [@@deriving fields, sexp] let create = Fields.create end module Image = struct type t = | Frog_up | Frog_down | Frog_left | Frog_right | Car1_left | Car1_right | Car2_left | Car2_right | Car3_lef...
88a6953421b437b42eff57586674a3e0bcbbfbfca095357a52da29f66e5e3ea3
UU-ComputerScience/uhc
t1.hs
module Main where choose :: a -> a -> a choose x y = x v2 = choose id v3 = (choose :: (forall a . a -> a) -> (forall b . b -> b) -> (forall c . c -> c)) id v4 :: (forall a . a -> a) -> (forall b . b -> b) v4 = choose id v5 = choose ~id f :: (forall a . a->a) -> (Int,Char) f i = ...
null
https://raw.githubusercontent.com/UU-ComputerScience/uhc/f2b94a90d26e2093d84044b3832a9a3e3c36b129/EHC/test/lucilia/t1.hs
haskell
module Main where choose :: a -> a -> a choose x y = x v2 = choose id v3 = (choose :: (forall a . a -> a) -> (forall b . b -> b) -> (forall c . c -> c)) id v4 :: (forall a . a -> a) -> (forall b . b -> b) v4 = choose id v5 = choose ~id f :: (forall a . a->a) -> (Int,Char) f i = ...
d1d30d8cb76bdedce7cfb95327cded326af3f08467ccb242e0e707992dabcb38
tcsprojects/ocaml-sat-solvers
satsolverregistry.ml
open Satwrapper;; module String_for_set = struct type t = string let compare = compare end ;; module StringMap = Map.Make(String_for_set) ;; let solvermap = ref StringMap.empty;; let default = ref None;; let register_solver solver_factory = let identifier = solver_factory#identifier in if StringMap.mem identi...
null
https://raw.githubusercontent.com/tcsprojects/ocaml-sat-solvers/2c36605fb3e38a1bee41e079031ab5b173794910/src/satsolverregistry.ml
ocaml
open Satwrapper;; module String_for_set = struct type t = string let compare = compare end ;; module StringMap = Map.Make(String_for_set) ;; let solvermap = ref StringMap.empty;; let default = ref None;; let register_solver solver_factory = let identifier = solver_factory#identifier in if StringMap.mem identi...
b4661a65ba40b79ce3cfcd9990653baf16149841c9c18cbaeba2b9fa58b37ccf
MyDataFlow/ttalk-server
riak_pb_msgcodegen.erl
%% @doc Generates a codec-mapping module from a CSV mapping of message %% codes to messages in .proto files. -module(riak_pb_msgcodegen). -export([pre_compile/2, pre_clean/2]). %% -include_lib("rebar/include/rebar.hrl"). -define(FAIL, rebar_utils:abort()). -define(ABORT(Str, Args), rebar_utils:abort(Str, Args...
null
https://raw.githubusercontent.com/MyDataFlow/ttalk-server/07a60d5d74cd86aedd1f19c922d9d3abf2ebf28d/deps/riak_pb/plugins/riak_pb_msgcodegen.erl
erlang
@doc Generates a codec-mapping module from a CSV mapping of message codes to messages in .proto files. -include_lib("rebar/include/rebar.hrl"). =================================================================== Public API =================================================================== ======================...
-module(riak_pb_msgcodegen). -export([pre_compile/2, pre_clean/2]). -define(FAIL, rebar_utils:abort()). -define(ABORT(Str, Args), rebar_utils:abort(Str, Args)). -define(CONSOLE(Str, Args), io:format(Str, Args)). -define(DEBUG(Str, Args), rebar_log:log(debug, Str, Args)). -define(INFO(Str, Args), rebar_log:l...
c39c938b7557d739673e473c3c1c564880c0ec32b1684123e4d92ee87ab3465a
BioHaskell/hPDB
Iterable.hs
-- | Iterable instances and convenience functions. module Bio.PDB.Iterable(Iterable(..), firstModel, numAtoms, numResidues, numChains, numModels) where import Bio.PDB.Iterable.Instances import Bio.PD...
null
https://raw.githubusercontent.com/BioHaskell/hPDB/5be747e2f2c57370b498f4c11f9f1887fdab0418/Bio/PDB/Iterable.hs
haskell
| Iterable instances and convenience functions.
module Bio.PDB.Iterable(Iterable(..), firstModel, numAtoms, numResidues, numChains, numModels) where import Bio.PDB.Iterable.Instances import Bio.PDB.Iterable.Utils
b1b2cb12ebb0d1a26354533350387b6069b09a3f7178bdcc6006c2fa0b5d48bf
facebook/flow
scoped_tvar_finder.ml
* Copyright ( c ) Meta Platforms , Inc. and affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in t...
null
https://raw.githubusercontent.com/facebook/flow/2422f3f1a00f5a3ea50bb25a22ec9108aca8c70e/src/typing/generics/scoped_tvar_finder.ml
ocaml
The context passed in here needs to be the file-local context for the module, not the leader context, because this process is concerned with munged underscores which is a file-local setting. Mark the tvars in a type as being in the current scope, *and* record where an annotation needs to be added if an out...
* Copyright ( c ) Meta Platforms , Inc. and affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in t...
cf48252037e7d23dabcef8d6fd1465c0dd3be1d74cd5f5e0304e91ec7020a516
tact-lang/tact-obsolete
syntax.ml
open Core module Config = struct include Tact.Located.Disabled end module Syntax = Tact.Syntax.Make (Config) module Parser = Tact.Parser.Make (Config) let parse_program s = Parser.parse s let print_sexp p = Sexplib.Sexp.pp_hum Format.std_formatter (Syntax.sexp_of_program p) let pp s = parse_program s |> print_...
null
https://raw.githubusercontent.com/tact-lang/tact-obsolete/660eb36add0831f9787afd25983bfd6dbf90a0d3/test/syntax.ml
ocaml
open Core module Config = struct include Tact.Located.Disabled end module Syntax = Tact.Syntax.Make (Config) module Parser = Tact.Parser.Make (Config) let parse_program s = Parser.parse s let print_sexp p = Sexplib.Sexp.pp_hum Format.std_formatter (Syntax.sexp_of_program p) let pp s = parse_program s |> print_...
611f55b8ba87a7ef507639f685682e7f7763c08944459aeb0ee20655ced1b7d8
jepsen-io/local-fs
project.clj
(defproject jepsen.local-fs "0.1.0-SNAPSHOT" :description "Jepsen tests for a local filesystem" :url "-io/local-fs" :license {:name "EPL-2.0 OR GPL-2.0-or-later WITH Classpath-exception-2.0" :url "-2.0/"} :dependencies [[org.clojure/clojure "1.11.1"] [jepsen "0.2.7"] ...
null
https://raw.githubusercontent.com/jepsen-io/local-fs/0acfe1716bec6869cee017f762062b23310ef922/project.clj
clojure
(defproject jepsen.local-fs "0.1.0-SNAPSHOT" :description "Jepsen tests for a local filesystem" :url "-io/local-fs" :license {:name "EPL-2.0 OR GPL-2.0-or-later WITH Classpath-exception-2.0" :url "-2.0/"} :dependencies [[org.clojure/clojure "1.11.1"] [jepsen "0.2.7"] ...
f40777bb0cea49ebc0432ff7decff4cda593fd82648e6d3422db1e14dacaa491
ghcjs/ghcjs-dom
SVGFEDiffuseLightingElement.hs
# LANGUAGE PatternSynonyms # # LANGUAGE ForeignFunctionInterface # # LANGUAGE JavaScriptFFI # -- For HasCallStack compatibility {-# LANGUAGE ImplicitParams, ConstraintKinds, KindSignatures #-} module GHCJS.DOM.JSFFI.Generated.SVGFEDiffuseLightingElement (js_getIn1, getIn1, js_getSurfaceScale, getSurfaceScale, ...
null
https://raw.githubusercontent.com/ghcjs/ghcjs-dom/749963557d878d866be2d0184079836f367dd0ea/ghcjs-dom-jsffi/src/GHCJS/DOM/JSFFI/Generated/SVGFEDiffuseLightingElement.hs
haskell
For HasCallStack compatibility # LANGUAGE ImplicitParams, ConstraintKinds, KindSignatures #
# LANGUAGE PatternSynonyms # # LANGUAGE ForeignFunctionInterface # # LANGUAGE JavaScriptFFI # module GHCJS.DOM.JSFFI.Generated.SVGFEDiffuseLightingElement (js_getIn1, getIn1, js_getSurfaceScale, getSurfaceScale, js_getDiffuseConstant, getDiffuseConstant, js_getKernelUnitLengthX, getKernelUnitLeng...
e154f7e1a9e8bbfd4cebb201924986c0ba9f4527fefd90fdb9e6b11dbb27d4c0
unclebob/spacewar
shots_test.clj
(ns spacewar.game-logic.shots-test (:require [midje.sweet :refer [facts fact tabular roughly =>]] [spacewar.game-logic.config :refer [phaser-velocity kinetic-velocity phaser-range ...
null
https://raw.githubusercontent.com/unclebob/spacewar/45741b33d8a9e097129a168b1ddb6d7de1ec7264/test/spacewar/game_logic/shots_test.clj
clojure
(ns spacewar.game-logic.shots-test (:require [midje.sweet :refer [facts fact tabular roughly =>]] [spacewar.game-logic.config :refer [phaser-velocity kinetic-velocity phaser-range ...
4092f2000e3ea96a26dfeda08d880b75aa20661eb47154df306cf0fe70def88f
dterei/GhcLlvmCodegen
Llvm.hs
-- ---------------------------------------------------------------------------- | This module supplies bindings to generate from Haskell -- (<>). -- -- Note: this module is developed in a demand driven way. It is no complete LLVM binding library in Haskell , but enough to generate code for GHC . -- -- This code i...
null
https://raw.githubusercontent.com/dterei/GhcLlvmCodegen/bbc6eb024e9c027162c060a5a6ce02b7e1b036d6/Llvm.hs
haskell
---------------------------------------------------------------------------- (<>). Note: this module is developed in a demand driven way. It is no complete This code is derived from code taken from the Essential Haskell Compiler * Modules, Functions and Blocks * Call Handling * Operations and Comparisons * V...
| This module supplies bindings to generate from Haskell LLVM binding library in Haskell , but enough to generate code for GHC . ( EHC ) project ( < > ) . module Llvm ( LlvmModule(..), LlvmFunction(..), LlvmFunctionDecl(..), LlvmFunctions, LlvmFunctionDecls, LlvmStatement(..)...
998a3e0096604a78da281d4c7622cf172359142344b43712f56eb0f797c098c6
3b/cl-opengl
examples.lisp
;;;; -*- Mode: lisp; indent-tabs-mode: nil -*- (defpackage #:cl-glut-examples (:use #:cl) (:export #:list-examples #:run-examples #:gl-info)) (in-package #:cl-glut-examples) (defparameter +examples+ '(("Redbook Examples" rb-double rb-hello #|rb-varray|# rb-lines rb-polys rb-cube rb-model r...
null
https://raw.githubusercontent.com/3b/cl-opengl/e2d83e0977b7e7ac3f3d348d8ccc7ccd04e74d59/examples/examples.lisp
lisp
-*- Mode: lisp; indent-tabs-mode: nil -*- rb-varray export symbols
(defpackage #:cl-glut-examples (:use #:cl) (:export #:list-examples #:run-examples #:gl-info)) (in-package #:cl-glut-examples) (defparameter +examples+ '(("Redbook Examples" rb-clip rb-planet rb-robot rb-list rb-stroke rb-smooth rb-movelight rb-tess rb-tess-wind rb-quadric rb-bezcurve) ("Me...
2f074511860f071b03c02d0016ec4379c58aeb1f8627a7a1d597e3e40869d73c
emlyn/tortilla
main_test.clj
(ns tortilla.main-test (:require [clojure.test :refer [deftest is testing use-fixtures]] [tortilla.main :as m])) (use-fixtures :once (fn [test-fn] ;; Ensure calling exit won't quit, but cause a test failure instead (with-redefs [m/exit (fn [code message] (throw (Exc...
null
https://raw.githubusercontent.com/emlyn/tortilla/825b736b63a43fa0f86731e571329d08948af0b6/src/test/tortilla/main_test.clj
clojure
Ensure calling exit won't quit, but cause a test failure instead
(ns tortilla.main-test (:require [clojure.test :refer [deftest is testing use-fixtures]] [tortilla.main :as m])) (use-fixtures :once (fn [test-fn] (with-redefs [m/exit (fn [code message] (throw (Exception. (str "exit " code " " message))))] (test-fn)))) (deftest ...
7045c5a544bcc78b2d2661eac2905c3b194d5496f1ac09a4c3ef2cb4f2bdc824
synduce/Synduce
Predicates.ml
open Base open Env open Elim open Lang open ProblemDefs open Term open Utils let cond_lemma_to_term ~(ctx : env) ~(p : PsiDef.t) ~(t : term) (ti : term_info) (cl : cond_lemma) = (* Term adjustment substituions *) match ctx >- Matching.matches ~pattern:ti.ti_term t with | Some subst1 -> ...
null
https://raw.githubusercontent.com/synduce/Synduce/42d970faa863365f10531b19945cbb5cfb70f134/src/common/Predicates.ml
ocaml
Term adjustment substituions Recursion elimination substitutions
open Base open Env open Elim open Lang open ProblemDefs open Term open Utils let cond_lemma_to_term ~(ctx : env) ~(p : PsiDef.t) ~(t : term) (ti : term_info) (cl : cond_lemma) = match ctx >- Matching.matches ~pattern:ti.ti_term t with | Some subst1 -> let subst = List.concat_map ...
11c867d97a21af5c45b3ed52c42266bc171b0422e1b8147c999c482e1582d999
AccelerateHS/accelerate
Monad.hs
{-# LANGUAGE OverloadedStrings #-} # LANGUAGE RecordWildCards # -- | Module : Data . Array . Accelerate . Pretty . Graphviz . Monad Copyright : [ 2015 .. 2020 ] The Accelerate Team -- License : BSD3 -- Maintainer : < > -- Stability : experimental Portability : non - portable ( GHC extens...
null
https://raw.githubusercontent.com/AccelerateHS/accelerate/a88c1daa23cb8ade051ef3207575f33bd9c5e6bd/src/Data/Array/Accelerate/Pretty/Graphviz/Monad.hs
haskell
# LANGUAGE OverloadedStrings # | License : BSD3 Stability : experimental -------------------------------------------------- keep internal node ids in a separate counter from the user-visible node labels -----------------------------------------------------------------
# LANGUAGE RecordWildCards # Module : Data . Array . Accelerate . Pretty . Graphviz . Monad Copyright : [ 2015 .. 2020 ] The Accelerate Team Maintainer : < > Portability : non - portable ( GHC extensions ) module Data.Array.Accelerate.Pretty.Graphviz.Monad where import Control.Monad.State i...
65efd8e7bb8de4dc82c8d25864647d750538028d7cfc818c57d5176d9f3d0199
UU-ComputerScience/uhc
Test.hs
module Main where data MyData = One Int | Two Int Int | Three Int Int Int | Four Int Int Int Int first :: MyData -> Int first (One i) = i first (Two i _) = i first (Three i _ _) = i first (Four i _ _ _) = i main = first (Two 7 3)
null
https://raw.githubusercontent.com/UU-ComputerScience/uhc/f2b94a90d26e2093d84044b3832a9a3e3c36b129/EHC/test/clr/2-datatypes/Test.hs
haskell
module Main where data MyData = One Int | Two Int Int | Three Int Int Int | Four Int Int Int Int first :: MyData -> Int first (One i) = i first (Two i _) = i first (Three i _ _) = i first (Four i _ _ _) = i main = first (Two 7 3)
30bcd1935d7447aa97cef0cb9c7c2316bc37fdfe426f7aa7f8a232d2ae0ee2d7
khotyn/4clojure-answer
84-transitive-clojure.clj
(fn [s] (letfn [(step [ele s] (let [n (filter #(= (second ele) (first %)) s)] (if (seq n) (let [t (map #(vec [(first ele) (second %)]) n)] (cons ele (mapcat #(step % s) t))) [ele])))] (set (mapcat #(step % s) s))))
null
https://raw.githubusercontent.com/khotyn/4clojure-answer/3de82d732faedceafac4f1585a72d0712fe5d3c6/84-transitive-clojure.clj
clojure
(fn [s] (letfn [(step [ele s] (let [n (filter #(= (second ele) (first %)) s)] (if (seq n) (let [t (map #(vec [(first ele) (second %)]) n)] (cons ele (mapcat #(step % s) t))) [ele])))] (set (mapcat #(step % s) s))))
59588e002d4bc6c11bda7883cdc8ce5c1206eb530e360a561af2e7c42f73b06c
roburio/builder-web
authorization.ml
let src = Logs.Src.create "authorization" ~doc:"Builder_web authorization" module Log = (val Logs.src_log src : Logs.LOG) open Lwt.Syntax let realm = "builder-web" let user_info_field = Dream.new_field ~name:"user_info" () let authenticate handler = fun req -> let unauthorized () = let headers = ["WWW-Authen...
null
https://raw.githubusercontent.com/roburio/builder-web/a85be8730cece0bd78df580fb7d48aff94e060d2/lib/authorization.ml
ocaml
let src = Logs.Src.create "authorization" ~doc:"Builder_web authorization" module Log = (val Logs.src_log src : Logs.LOG) open Lwt.Syntax let realm = "builder-web" let user_info_field = Dream.new_field ~name:"user_info" () let authenticate handler = fun req -> let unauthorized () = let headers = ["WWW-Authen...
5d2f5ddb628911de3433d0221b28bc9aa9197741132e9055267849d82e5151b4
deeglaze/macro-models
set-of-scopes.rkt
#lang typed/racket (require "common.rkt") (define-type Scope Name) (define-type Addr Name) (define-type Ctx (Setof Scope)) (: ∅ : (Setof Scope)) (define ∅ (seteq)) (mk-Types [Stx stxs? S-Identifier s-identifier? s-identifiers? Ctx] [Var App Ast ast? Fun Val val?] δ) (define-type Sigma (U Addr #f)...
null
https://raw.githubusercontent.com/deeglaze/macro-models/f49097f4c2cbf3a261e0a0dd94bebc275768e4bc/set-of-scopes.rkt
racket
m^{a,b} -> m8 translates to (hash 'm (hash (seteq 'a 'b) 'm8)) so other scope sets are possible for 'm. Model in paper has this after ast_op, but catch-all...? TODO SoS unmark current mark(s)...? Pun σ as the basis for the generated name TODO SoS Defining id freshens it. bind expand-time value in definitio...
#lang typed/racket (require "common.rkt") (define-type Scope Name) (define-type Addr Name) (define-type Ctx (Setof Scope)) (: ∅ : (Setof Scope)) (define ∅ (seteq)) (mk-Types [Stx stxs? S-Identifier s-identifier? s-identifiers? Ctx] [Var App Ast ast? Fun Val val?] δ) (define-type Sigma (U Addr #f)...
7816b86962279126d83bc6a323841fbef6c4a1e973748a144f18233257d09e8a
dajac/react
queue_test.clj
(ns react.queue-test (:use clojure.test) (:require [react.future :as future] [react.queue :as queue])) (deftest async-queue-test (testing "Idle" (let [q (queue/async-queue)] (is (= (-> q .state deref :type) :idle)) (is (= (-> q .state deref :pollers count) 0)) (is (= (-> q .s...
null
https://raw.githubusercontent.com/dajac/react/b45d549d0f8be0167c8c814418358ae82afe4ce8/test/react/queue_test.clj
clojure
(ns react.queue-test (:use clojure.test) (:require [react.future :as future] [react.queue :as queue])) (deftest async-queue-test (testing "Idle" (let [q (queue/async-queue)] (is (= (-> q .state deref :type) :idle)) (is (= (-> q .state deref :pollers count) 0)) (is (= (-> q .s...
66bfd67fe7cad99a23db9e7436ea31e7185a1dba6682d76929e3517e58934f71
unison-code/unison
Parser.hs
| Copyright : Copyright ( c ) 2016 , RISE SICS AB License : BSD3 ( see the LICENSE file ) Maintainer : Support to parse Unison functions . Copyright : Copyright (c) 2016, RISE SICS AB License : BSD3 (see the LICENSE file) Maintainer : Support to parse Unison functions. -} Mai...
null
https://raw.githubusercontent.com/unison-code/unison/9f8caf78230f956a57b50a327f8d1dca5839bf64/src/unison/src/Unison/Parser.hs
haskell
| Copyright : Copyright ( c ) 2016 , RISE SICS AB License : BSD3 ( see the LICENSE file ) Maintainer : Support to parse Unison functions . Copyright : Copyright (c) 2016, RISE SICS AB License : BSD3 (see the LICENSE file) Maintainer : Support to parse Unison functions. -} Mai...
6aa608a8d9f2558c9597b8accad019bfe73d8c99485ad52cf1c01bd26d5d1c29
rametta/retros
Edit.hs
module Web.View.Teams.Edit where import Web.View.Prelude data EditView = EditView { team :: Team, users :: [User], owner :: User } instance View EditView where html EditView { .. } = renderModal Modal { modalTitle = "Edit Team" , modalCloseUrl = pathTo $ ShowTeamAction $ get #id team , mod...
null
https://raw.githubusercontent.com/rametta/retros/8f3ca23bcf8ee30476ff3e68a5969af021956f8b/Web/View/Teams/Edit.hs
haskell
module Web.View.Teams.Edit where import Web.View.Prelude data EditView = EditView { team :: Team, users :: [User], owner :: User } instance View EditView where html EditView { .. } = renderModal Modal { modalTitle = "Edit Team" , modalCloseUrl = pathTo $ ShowTeamAction $ get #id team , mod...
daed66c4f662d79db02851924453e3d0ee53d672915d3cb3d700e003ec6269ff
smeruelo/mooc-ocaml
w5_5.1_rotating_array.ml
let rotate a = let n = Array.length a in match n with | 0 -> () | _ -> let v = a.(0) in for i = 0 to n-2 do a.(i) <- a.(i+1) done; a.(n-1)<-v ;; let rotate_by a k = let n = Array.length a in match n with | 0 -> () | n -> for i = 1 to (n + k) mod n do rotate a done
null
https://raw.githubusercontent.com/smeruelo/mooc-ocaml/8e2efb1632ec9dd381489a08465d5341a6c727c9/week5/w5_5.1_rotating_array.ml
ocaml
let rotate a = let n = Array.length a in match n with | 0 -> () | _ -> let v = a.(0) in for i = 0 to n-2 do a.(i) <- a.(i+1) done; a.(n-1)<-v ;; let rotate_by a k = let n = Array.length a in match n with | 0 -> () | n -> for i = 1 to (n + k) mod n do rotate a done
e5a3527d80bc83dab6bda7f9c0ffbd5562d1718c34ef3374046c351a96290cb3
yuriy-chumak/ol
math-rand.scm
;;; ;;; Math library unit tests ;;; (define-syntax lets (syntax-rules () ((lets . stuff) (let* . stuff)))) ; TEMP ;; todo: factor this to smaller tests (import (owl math)) (import (owl math-extra)) (import (owl random)) ; fixme, put abs to math (define (abs x) (if (< x 0) (- 0 x) x)) ;; take a random seed (defin...
null
https://raw.githubusercontent.com/yuriy-chumak/ol/6100663adce2799f47d5fb0ed64fa40664a83bd9/tests/math-rand.scm
scheme
Math library unit tests TEMP todo: factor this to smaller tests fixme, put abs to math take a random seed the rest is deterministic Test subject creation and the same will probably hold for faster versions of other algorithms later nonzero nonzero nonzero all numbers are funny and some more than other...
(import (owl math)) (import (owl math-extra)) (import (owl random)) (define (abs x) (if (< x 0) (- 0 x) x)) (define seed (expt (time-ms) 3)) note , karatsuba kicks in when numbers are around 100 digits , ( define max - bits 2048 ) (define max-bits 128) (define (rand-bits rst bits) (rand rst (<< 1 bits)))...
8952fd4b7999168ac900b0041310097165189e872678c279b99c87fe9e94fa59
gbgar/Wordlint
Wordpairs.hs
Copyright © 2014 - 2016 github.com/gbgar This file is part of Wordlint . Wordlint 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 option) any later v...
null
https://raw.githubusercontent.com/gbgar/Wordlint/f85dd361db8946f2dc450678a8094978919dba38/src/Text/Wordlint/Wordpairs.hs
haskell
(at your option) any later version. but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. This module contains types and functions for working with pairs of matching words and the distances between...
Copyright © 2014 - 2016 github.com/gbgar This file is part of Wordlint . Wordlint 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 Wordlint is distributed in t...
8c834b48d5a3e533b35651e81d92151e11cfe36e65ec1eec0c4150ddce49c929
roehst/tapl-implementations
syntax.mli
module Syntax : syntax trees and associated support functions open Support.Pervasive open Support.Error (* Data type definitions *) type ty = TyTop | TyBot | TyRecord of (string * ty) list | TyArr of ty * ty type term = TmVar of info * int * int | TmAbs of info * string * ty * term | TmApp of inf...
null
https://raw.githubusercontent.com/roehst/tapl-implementations/23c0dc505a8c0b0a797201a7e4e3e5b939dd8fdb/rcdsubbot/syntax.mli
ocaml
Data type definitions Contexts Shifting and substitution Printing Misc
module Syntax : syntax trees and associated support functions open Support.Pervasive open Support.Error type ty = TyTop | TyBot | TyRecord of (string * ty) list | TyArr of ty * ty type term = TmVar of info * int * int | TmAbs of info * string * ty * term | TmApp of info * term * term | TmRecord...
5881edf01bfdc883d1f8a95114337b390c38f2b68ff11f818022f366a867a87e
clj-commons/seesaw
pi.clj
Copyright ( c ) , 2011 . 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 ...
null
https://raw.githubusercontent.com/clj-commons/seesaw/4ca89d0dcdf0557d99d5fa84202b7cc6e2e92263/test/seesaw/test/examples/pi.clj
clojure
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 the terms of this license. You must not rem...
Copyright ( c ) , 2011 . All rights reserved . (ns seesaw.test.examples.pi (:use seesaw.core seesaw.test.examples.example) (:require seesaw.invoke) (:import [java.util.concurrent LinkedBlockingQueue TimeUnit])) (defn calculate-pi-for "Calculate a sliver of pi" [start step-size] (reduce ...
98f53c231ca762183ba9616e39230c8111f37885e13e88693201da206c00dd8c
f-o-a-m/kepler
Types.hs
# LANGUAGE UndecidableInstances # module Tendermint.SDK.BaseApp.Transaction.Types ( module Tendermint.SDK.BaseApp.Transaction.Types -- * Re-Exports , Tx(..) ) where import Control.Lens (lens) import Data.ByteString (ByteString) import ...
null
https://raw.githubusercontent.com/f-o-a-m/kepler/6c1ad7f37683f509c2f1660e3561062307d3056b/hs-abci-sdk/src/Tendermint/SDK/BaseApp/Transaction/Types.hs
haskell
* Re-Exports ------------------------------------------------------------------------------ Router Types and Combinators ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ ---------------------------------------...
# LANGUAGE UndecidableInstances # module Tendermint.SDK.BaseApp.Transaction.Types ( module Tendermint.SDK.BaseApp.Transaction.Types , Tx(..) ) where import Control.Lens (lens) import Data.ByteString (ByteString) import Data.IORef...
ae5729ddee508a14524a2e0ddc99f15df550417aed0364de66e156cd42aa63fd
zadean/xqerl
fn_innermost_SUITE.erl
-module('fn_innermost_SUITE'). -include_lib("common_test/include/ct.hrl"). -export([ all/0, groups/0, suite/0 ]). -export([ init_per_suite/1, init_per_group/2, end_per_group/2, end_per_suite/1 ]). -export(['fn-innermost-001'/1]). -export(['fn-innermost-002'/1]). -export(['fn-innermost-00...
null
https://raw.githubusercontent.com/zadean/xqerl/1a94833e996435495922346010ce918b4b0717f2/test/fn/fn_innermost_SUITE.erl
erlang
-module('fn_innermost_SUITE'). -include_lib("common_test/include/ct.hrl"). -export([ all/0, groups/0, suite/0 ]). -export([ init_per_suite/1, init_per_group/2, end_per_group/2, end_per_suite/1 ]). -export(['fn-innermost-001'/1]). -export(['fn-innermost-002'/1]). -export(['fn-innermost-00...
825010547a08f175c25dadb3e10c92adaf7016ae7e27d72cfde3e45d6accbff1
bvaugon/ocapic
display.ml
(*************************************************************************) (* *) (* OCaPIC *) (* *) ...
null
https://raw.githubusercontent.com/bvaugon/ocapic/a14cd9ec3f5022aeb5fe2264d595d7e8f1ddf58a/tests/lazies/display.ml
ocaml
*********************************************************************** OCaPIC ...
This file is distributed under the terms of the CeCILL license . open Pic;; set_bit IRCF1;; set_bit IRCF0;; set_bit PLLEN;; module Disp = Lcd.Connect ( struct let bus_size = Lcd.Eight let e = LATD0 let rs = LATD2 let rw = LATD1 ...
4bce932c3c7a4bacf49482f4227e652ec3b6e47b686ed25538687740a76d0a37
chaitanyagupta/chronicity
repeater-weekend.lisp
-*- Mode : LISP ; Syntax : COMMON - LISP ; Package : CL - USER ; Base : 10 -*- ;;; repeater-weekend.lisp ;;; See the LICENSE file for licensing information. (cl:in-package #:chronicity-test) (define-test repeater-weekend-next-future (let* ((now (make-datetime 2006 8 16 14)) (weekend (create-tag 'repeate...
null
https://raw.githubusercontent.com/chaitanyagupta/chronicity/5841d1548cad0ca6917d8e68933124a5af68f5ec/test/repeater-weekend.lisp
lisp
Syntax : COMMON - LISP ; Package : CL - USER ; Base : 10 -*- repeater-weekend.lisp See the LICENSE file for licensing information.
(cl:in-package #:chronicity-test) (define-test repeater-weekend-next-future (let* ((now (make-datetime 2006 8 16 14)) (weekend (create-tag 'repeater-weekend :weekend :now now)) (next-weekend (r-next weekend :future))) (assert-datetime= (make-datetime 2006 8 19) (span-start next-weekend)) ...
732d014d5384040ae9e54bd4a4080ee2e52368b627a817ec207f3efa56c24d76
helium/erlang-dkg
dkg_ct_utils.erl
-module(dkg_ct_utils). -export([pmap/2, wait_until/1, wait_until/3, wait_until_disconnected/2, start_node/3, partition_cluster/2, heal_cluster/2, connect/1, random_n/2 ]). pmap(F, L) -> Parent = self(), lists:foldl( fun(X, N...
null
https://raw.githubusercontent.com/helium/erlang-dkg/a22b841ae6cb31b17e547a6f208e93fa35f04b7f/test/dkg_ct_utils.erl
erlang
have the slave nodes monitor the runner node, so they can't outlive it
-module(dkg_ct_utils). -export([pmap/2, wait_until/1, wait_until/3, wait_until_disconnected/2, start_node/3, partition_cluster/2, heal_cluster/2, connect/1, random_n/2 ]). pmap(F, L) -> Parent = self(), lists:foldl( fun(X, N...
8ebce09c9d01adea30a63af3c0eb4534ba1bf949e8e383b2bc8682f72d68873a
m2ym/ocaml-pythonlib
pretty.ml
open Format open Ast open Utils let mk_sep sep = let first = ref true in fun fmt -> if !first then first := false else fprintf fmt sep let pp_char = pp_print_char let pp_string = pp_print_string let pp_int = pp_print_int let pp_float = pp_print_float let pp_empty fmt _ = () let pp_...
null
https://raw.githubusercontent.com/m2ym/ocaml-pythonlib/99b17b91ce227d90a36c261cf1eb8a4a826e0533/src/pretty.ml
ocaml
open Format open Ast open Utils let mk_sep sep = let first = ref true in fun fmt -> if !first then first := false else fprintf fmt sep let pp_char = pp_print_char let pp_string = pp_print_string let pp_int = pp_print_int let pp_float = pp_print_float let pp_empty fmt _ = () let pp_...
8d00b17b4c67bc60a0e8f73112a497cef0244544fd4a84014685b7261f558275
brycecovert/clojure-event-sourcing
core.clj
(ns event-sourcing.core (:import [org.apache.kafka.streams StreamsConfig KafkaStreams StreamsBuilder KeyValue] [org.apache.kafka.streams.state QueryableStoreTypes] [org.apache.kafka.streams.kstream ValueMapper Reducer JoinWindows ValueTransformer Transformer] [org.apache.kafka.client...
null
https://raw.githubusercontent.com/brycecovert/clojure-event-sourcing/8dd6974eb050c41bf8f5600bc2ed9e213ff2f71e/src/event_sourcing/core.clj
clojure
Example events EXAMPLE 1: Finds delayed flights from flight-events, writes to flight-status delayed departure on-time departure EXAMPLE 7: Fixing a bug
(ns event-sourcing.core (:import [org.apache.kafka.streams StreamsConfig KafkaStreams StreamsBuilder KeyValue] [org.apache.kafka.streams.state QueryableStoreTypes] [org.apache.kafka.streams.kstream ValueMapper Reducer JoinWindows ValueTransformer Transformer] [org.apache.kafka.client...
4676d027e6c1c3fffcff3163d8a344fd132597095485505a22e661088ba4f6ce
jiangpengnju/htdp2e
ex26.rkt
The first three lines of this file were inserted by . They record metadata ;; about the language level of this file in a form that our tools can easily process. #reader(lib "htdp-beginner-reader.ss" "lang")((modname ex26) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #f #...
null
https://raw.githubusercontent.com/jiangpengnju/htdp2e/d41555519fbb378330f75c88141f72b00a9ab1d3/fixed-size-data/functions-and-programs/ex26.rkt
racket
about the language level of this file in a form that our tools can easily process. Here is the definition of bool-imply: Use the stepper to determine the value of:
The first three lines of this file were inserted by . They record metadata #reader(lib "htdp-beginner-reader.ss" "lang")((modname ex26) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #f #t none #f () #f))) (define (bool-imply x y) (or (not x) y)) (bool-imply #true #fals...
c431b7e6f2aa7fc98ee10aa387a6ff8fc0ddfd29d4ed6f601999e04e0fb869a1
ghc/nofib
Main.hs
Return - Path : Return - Path : < > Received : from minster.york.ac.uk by goggins.dcs.gla.ac.uk with SMTP ( PP ) i d < > ; Thu , 24 Jun 1993 15:10:40 +0100 From : Date : Thu , 24 Jun 93 14:00:31 To : Message - ID : < > Return-Path: Return-Path: <> Received: from minster.york.ac.uk by ...
null
https://raw.githubusercontent.com/ghc/nofib/f34b90b5a6ce46284693119a06d1133908b11856/parallel/OLD/soda/Main.hs
haskell
---------------------------------------------------------------- Searching in a grid of words for hidden words oriented in any of search parallel lines in parallel ----------------------------------------------------------------
Return - Path : Return - Path : < > Received : from minster.york.ac.uk by goggins.dcs.gla.ac.uk with SMTP ( PP ) i d < > ; Thu , 24 Jun 1993 15:10:40 +0100 From : Date : Thu , 24 Jun 93 14:00:31 To : Message - ID : < > Return-Path: Return-Path: <> Received: from minster.york.ac.uk by ...
fd5d4cdb992555c33c7f71fa5cd94c118dc7933d51953adef42c1003f0d76dec
r0man/inflections-clj
test.cljs
(ns inflections.test (:require [inflections.core-test] [doo.runner :refer-macros [doo-tests]])) (doo-tests 'inflections.core-test)
null
https://raw.githubusercontent.com/r0man/inflections-clj/af3aa93ed360507c357734b5a664987248a93aee/test/inflections/test.cljs
clojure
(ns inflections.test (:require [inflections.core-test] [doo.runner :refer-macros [doo-tests]])) (doo-tests 'inflections.core-test)
a55de28e3f3b3028112266d9b4204eec934d3666a162a737d78622c16c592918
jfaure/Irie-lang
BitSetMap.hs
# LANGUAGE DeriveDataTypeable , , , , InstanceSigs # -- product | sumtype keys are static lists usually consisting of many neighboring bounded integers insertion is O(n ) , but all other operations are more space efficient and faster than IntMap -- fromList O(n) -- (!?) O(1) -- union , intersection , mergeWithKey ...
null
https://raw.githubusercontent.com/jfaure/Irie-lang/186640a095d14560ff102ef613648e558e5b3f1e/compiler/BitSetMap.hs
haskell
product | sumtype keys are static lists usually consisting of many neighboring bounded integers fromList O(n) (!?) O(1) union , intersection , mergeWithKey O(n) For oneshot built ordered lists, dichotomy lookup on a (Vector (Int , a)) is a clear improvement vs Data.IntMap fromVec l = BSM (V.sortOn fst l) dichoto...
# LANGUAGE DeriveDataTypeable , , , , InstanceSigs # insertion is O(n ) , but all other operations are more space efficient and faster than IntMap module BitSetMap (BitSetMap , size , fromList , fromListWith , BitSetMap.toList , foldrWithKey , singleton , (!?) , BitSetMap.elems , BitSetMap.keys , unionWith , int...
696fd8e82f54ad0f9dbb4afbeac18c8d34927ab3c9195345e9d2b9e8c9b1c267
yetanalytics/re-thread
codec.cljs
(ns re-thread.codec (:require [cognitect.transit :as t])) (def ^:dynamic writer (t/writer :json)) (def ^:dynamic reader (t/reader :json)) (defn encode-data [data] (t/write writer data)) (defn decode-data [s] (t/read reader s))
null
https://raw.githubusercontent.com/yetanalytics/re-thread/5fb40224d809d82ba5011fefee34b95f22d72454/src/re_thread/codec.cljs
clojure
(ns re-thread.codec (:require [cognitect.transit :as t])) (def ^:dynamic writer (t/writer :json)) (def ^:dynamic reader (t/reader :json)) (defn encode-data [data] (t/write writer data)) (defn decode-data [s] (t/read reader s))
e6c3e8a13984bdf8c43df3cc43e51ebc57bc949bdffbfad92c39e66db789eebe
elizabethsiegle/reddit-slack-bot
ConnectApp.hs
# LANGUAGE MultiParamTypeClasses # {-#LANGUAGE OverloadedStrings #-} # LANGUAGE ViewPatterns # module Twilio.ConnectApp ( -- * Resource ConnectApp(..) , ConnectAppSID , Twilio.ConnectApp.get ) where import Control.Applicative import Control.Monad import Control.Monad.Catch import Data.Aeson import Data.Mo...
null
https://raw.githubusercontent.com/elizabethsiegle/reddit-slack-bot/a52ab60dcaae8e16bee8cdba22fce627157a42d8/twilio-haskell-move-to-stack/src/Twilio/ConnectApp.hs
haskell
#LANGUAGE OverloadedStrings # * Resource , permissions :: ! , deauthorizeCallbackMethod :: !Text <*> v .: "permissions" <*> v .: "deauthorize_callback_method"
# LANGUAGE MultiParamTypeClasses # # LANGUAGE ViewPatterns # module Twilio.ConnectApp ConnectApp(..) , ConnectAppSID , Twilio.ConnectApp.get ) where import Control.Applicative import Control.Monad import Control.Monad.Catch import Data.Aeson import Data.Monoid import Data.Text (Text) import qualified Data.T...
4aab8d1338d644811df7bf720f2a0af0202adfe1c41b7b8912ea644789e606f1
jetseven/sicp
ps2tw1-ans.scm
(define (stop-at n) (lambda (my-hand opponent-up-card) (if (>= (hand-total my-hand) n) #f #t))) (define (test-strategy player-strategy house-strategy reps) (define (iter count result) (if (= count 0) result (iter (- count 1) (+ result (twenty-one player-strategy house-strategy))))) (iter reps 0...
null
https://raw.githubusercontent.com/jetseven/sicp/0998f4ec0967dde950dab11741d5433f8ea69ea6/assignments/twenty-one/ps2tw1-ans.scm
scheme
(define (stop-at n) (lambda (my-hand opponent-up-card) (if (>= (hand-total my-hand) n) #f #t))) (define (test-strategy player-strategy house-strategy reps) (define (iter count result) (if (= count 0) result (iter (- count 1) (+ result (twenty-one player-strategy house-strategy))))) (iter reps 0...
0cbe4a6662ad0a302a40b2aa90cd7c434907c86f32b75e88c84890819ca3a8de
passy/android-lint-summary
Main.hs
# LANGUAGE ExistentialQuantification # # LANGUAGE NoImplicitPrelude # {-# LANGUAGE OverloadedStrings #-} module Main where import BasicPrelude hiding (fromString) import Test.Hspec import Test.QuickCheck hiding (verbose) import Test.Q...
null
https://raw.githubusercontent.com/passy/android-lint-summary/8aaf7884f542176e43a6f6b4e51e6391fafd61e0/Tests/Main.hs
haskell
# LANGUAGE OverloadedStrings #
# LANGUAGE ExistentialQuantification # # LANGUAGE NoImplicitPrelude # module Main where import BasicPrelude hiding (fromString) import Test.Hspec import Test.QuickCheck hiding (verbose) import Test.QuickCheck.Monadic import Test.Qui...
a79ccc1a1710798d38ed13a55889b1955ebec020436ad6f389a6d3af21c22e6a
ciderpunx/57-exercises-for-programmers
P48Weather.hs
{-# LANGUAGE OverloadedStrings #-} module P48Weather where import Control.Applicative (Const) import Control.Lens ((^.),(^?)) import Data.Aeson.Lens (_String, _Number, _Integer, key, nth, AsValue) import Data.Aeson.Types (Value) import Data.ByteString.Lazy (ByteString) import Data.Monoid (First) import Data.Scientific...
null
https://raw.githubusercontent.com/ciderpunx/57-exercises-for-programmers/25958ab80cc3edc29756d3bddd2d89815fd390bf/src/P48Weather.hs
haskell
# LANGUAGE OverloadedStrings # Might as well use our code from earlier for temp conversions (though the API can do this for us if required) Given a Response, a lens focus, a conversion function and the item name we're extracting return the item in some useful format or throw an error (with the unretrievable item na...
module P48Weather where import Control.Applicative (Const) import Control.Lens ((^.),(^?)) import Data.Aeson.Lens (_String, _Number, _Integer, key, nth, AsValue) import Data.Aeson.Types (Value) import Data.ByteString.Lazy (ByteString) import Data.Monoid (First) import Data.Scientific (toRealFloat, Scientific) import D...
3b8f12b0f3c2a86bb764427b89fea677d88e224c235625abbe3b10ac3d39e507
fyquah/hardcaml_zprize
verilog.ml
open Core open Hardcaml open Twisted_edwards_lib module Num_bits = struct let num_bits = 377 end let flag_filename = Command.Param.( flag "output-filename" (optional_with_default "/dev/stdout" string) ~doc:" Output filename (Defaults to stdout)") ;; let command_synth (module Adder : Adder_i...
null
https://raw.githubusercontent.com/fyquah/hardcaml_zprize/553b1be10ae9b977decbca850df6ee2d0595e7ff/libs/twisted_edwards/bin/generate/verilog.ml
ocaml
open Core open Hardcaml open Twisted_edwards_lib module Num_bits = struct let num_bits = 377 end let flag_filename = Command.Param.( flag "output-filename" (optional_with_default "/dev/stdout" string) ~doc:" Output filename (Defaults to stdout)") ;; let command_synth (module Adder : Adder_i...
a85975cd22cb7f6171bd1a0f06d01ea57322226f6ea66424945ca374fea47124
tree-sitter/haskell-tree-sitter
Go.hs
module TreeSitter.Go ( tree_sitter_go , getNodeTypesPath , getTestCorpusDir ) where import Foreign.Ptr import TreeSitter.Language import Paths_tree_sitter_go foreign import ccall unsafe "vendor/tree-sitter-go/src/parser.c tree_sitter_go" tree_sitter_go :: Ptr Language getNodeTypesPath :: IO FilePath getNodeTypesPath...
null
https://raw.githubusercontent.com/tree-sitter/haskell-tree-sitter/8a5a2b12a3c36a8ca7e117fff04023f1595e04e7/tree-sitter-go/TreeSitter/Go.hs
haskell
module TreeSitter.Go ( tree_sitter_go , getNodeTypesPath , getTestCorpusDir ) where import Foreign.Ptr import TreeSitter.Language import Paths_tree_sitter_go foreign import ccall unsafe "vendor/tree-sitter-go/src/parser.c tree_sitter_go" tree_sitter_go :: Ptr Language getNodeTypesPath :: IO FilePath getNodeTypesPath...
3a22f2ac423826c325959be5c3e6cd1a901304b52690f598ac05f498469edc39
ptaoussanis/tengen
reagent.cljc
(ns taoensso.tengen.reagent "Public API for use with Reagent, Ref. -project/reagent." {:author "Peter Taoussanis (@ptaoussanis)"} (:require [taoensso.encore :as enc :refer [have have?]] [taoensso.tengen.common :as common] #?(:cljs [reagent.core]) #?(:cljs [reagent.dom]))) (comment (enc/de...
null
https://raw.githubusercontent.com/ptaoussanis/tengen/d9a19988d31522fa285bdba531d2566c13422f28/src/taoensso/tengen/reagent.cljc
clojure
For debugging, error reporting, etc. (fn [cmpt argv]) (fn [cmpt argv mounting? mount-rvals]), ideally pure (fn [cmpt argv mounting? mount-rvals render-rvals]) (fn [cmpt argv mounting? mount-rvals render-rvals]) (fn [cmpt argv mount-rvals render-rvals]) Equivalent to (old, deprecated) :component-will-mo...
(ns taoensso.tengen.reagent "Public API for use with Reagent, Ref. -project/reagent." {:author "Peter Taoussanis (@ptaoussanis)"} (:require [taoensso.encore :as enc :refer [have have?]] [taoensso.tengen.common :as common] #?(:cljs [reagent.core]) #?(:cljs [reagent.dom]))) (comment (enc/de...
a212bc0ca2e58f0ef917f3e98f82ce87a79e30eb9614b7e3f2685f29ccfa6899
plum-umd/fundamentals
defns.rkt
#lang racket (provide (all-defined-out)) (require scribble/core scribble/html-properties) (define semester "summer") (define year "2019") (define courseno "CMSC 198Q") (define m1-date "July 17, 10-11am") (define final-date "July 26, 10am-noon") (define elms-url "")
null
https://raw.githubusercontent.com/plum-umd/fundamentals/eb01ac528d42855be53649991a17d19c025a97ad/0/www/defns.rkt
racket
#lang racket (provide (all-defined-out)) (require scribble/core scribble/html-properties) (define semester "summer") (define year "2019") (define courseno "CMSC 198Q") (define m1-date "July 17, 10-11am") (define final-date "July 26, 10am-noon") (define elms-url "")
5703935fe266589df8a4b9848d6db2f4178fb5f7f755a7a19cad3b100256e759
reanimate/reanimate
Reanimate.hs
| Module : Reanimate Description : SVG - base animation library . Copyright : Written by License : Unlicense Maintainer : Stability : experimental Portability : POSIX Reanimate is an animation library based on SVGs . It is designed to act like glue between external components su...
null
https://raw.githubusercontent.com/reanimate/reanimate/ed1c0ba6c198b7f14a2d512ca77470cc41f3bfa4/src/Reanimate.hs
haskell
* Animations ** Composition ** Easing functions ** Scenes :: (forall s. Scene s a) -> Animation :: Animation -> Scene s () :: Scene s a -> Scene s a :: Scene s Time :: Duration -> Scene s () :: Time -> Scene s () :: Scene s a -> Scene s a :: (ZIndex -> ZIndex) -> Scene s a -> Scene s a :: Scene s () -> Sce...
| Module : Reanimate Description : SVG - base animation library . Copyright : Written by License : Unlicense Maintainer : Stability : experimental Portability : POSIX Reanimate is an animation library based on SVGs . It is designed to act like glue between external components su...
58df4b066f996d0027473c6ff7ba7676e03e61657095cd69caf18ad433d6364b
SimulaVR/godot-haskell
VehicleBody.hs
# LANGUAGE DerivingStrategies , GeneralizedNewtypeDeriving , TypeFamilies , TypeOperators , FlexibleContexts , DataKinds , MultiParamTypeClasses # TypeFamilies, TypeOperators, FlexibleContexts, DataKinds, MultiParamTypeClasses #-} module Godot.Core.VehicleBody (Godot.Core.VehicleBody.get_brake, ...
null
https://raw.githubusercontent.com/SimulaVR/godot-haskell/e8f2c45f1b9cc2f0586ebdc9ec6002c8c2d384ae/src/Godot/Core/VehicleBody.hs
haskell
# NOINLINE bindVehicleBody_get_engine_force # __Note:__ The simulation does not take the effect of gears into account, you will need to add logic for this if you wish to simulate gears. A negative value will result in the vehicle reversing. __Note:__ The simulation does not take the effect of gears in...
# LANGUAGE DerivingStrategies , GeneralizedNewtypeDeriving , TypeFamilies , TypeOperators , FlexibleContexts , DataKinds , MultiParamTypeClasses # TypeFamilies, TypeOperators, FlexibleContexts, DataKinds, MultiParamTypeClasses #-} module Godot.Core.VehicleBody (Godot.Core.VehicleBody.get_brake, ...
f677756299c955c9f6cd8e0c66b5fdc3aac48221ca0591ac96d3596b3073e916
lambdaclass/throttle
profile.erl
-module(profile). -export([stress/4, profile/1]). TODO shorter arity with sane defaults stress(Driver, Scopes, Limit, Processes) -> init(Driver, Scopes, Limit, Processes), timer:sleep(500), %% start profiler {ok, _} = eprof:profile(fun() -> throttle:check(1, self()) ...
null
https://raw.githubusercontent.com/lambdaclass/throttle/4f5fb17c9d4a86ba016e7011648ae5dfe539ac01/test/profile.erl
erlang
start profiler test the standalone reset_counters function which is what changes between ets implementation setup some counters time reset counters cleanup ets internal spawn process that constantly queries throttle does this make sense?
-module(profile). -export([stress/4, profile/1]). TODO shorter arity with sane defaults stress(Driver, Scopes, Limit, Processes) -> init(Driver, Scopes, Limit, Processes), timer:sleep(500), {ok, _} = eprof:profile(fun() -> throttle:check(1, self()) ...
d65b3af9c8d8e4becd67b201523c6898da3b1fb60cc2597056f5a908907264ed
skeeto/euler-cl
euler-21.lisp
Project Euler - Problem 21 ;; Let d(n) be defined as the sum of proper divisors of n (numbers ;; less than n which divide evenly into n). ;; If d(a) = b and d(b) = a, where a ≠ b, then a and b are an amicable ;; pair and each of a and b are called amicable numbers. For example , the proper divisors of 220 are 1 ...
null
https://raw.githubusercontent.com/skeeto/euler-cl/82000252703070274e09bd13f9effdca68705404/euler-21.lisp
lisp
Let d(n) be defined as the sum of proper divisors of n (numbers less than n which divide evenly into n). If d(a) = b and d(b) = a, where a ≠ b, then a and b are an amicable pair and each of a and b are called amicable numbers. therefore d(220 ) = 284 . The proper divisors of so d(284 ) = 220 .
Project Euler - Problem 21 For example , the proper divisors of 220 are 1 , 2 , 4 , 5 , 10 , 11 , 20 , Evaluate the sum of all the amicable numbers under 10000 . (defun euler-21 () (labels ((d (n) (- (apply #'+ (divisors n)) n))) (loop for a from 1 to 10000 when (and (= a (d (d a))) (not (= a (d...
32019780362610a64a7674d01ea562dac19501923a34e7e1e03a76707cd5f2b3
roburio/albatross
vmm_lwt.ml
( c ) 2017 , all rights reserved open Lwt.Infix let pp_sockaddr ppf = function | Lwt_unix.ADDR_UNIX str -> Fmt.pf ppf "unix domain socket %s" str | Lwt_unix.ADDR_INET (addr, port) -> Fmt.pf ppf "TCP %s:%d" (Unix.string_of_inet_addr addr) port let safe_close fd = Lwt...
null
https://raw.githubusercontent.com/roburio/albatross/b8d1c18116ddce703b72bf2b8b7cf8555de80f22/src/vmm_lwt.ml
ocaml
( c ) 2017 , all rights reserved open Lwt.Infix let pp_sockaddr ppf = function | Lwt_unix.ADDR_UNIX str -> Fmt.pf ppf "unix domain socket %s" str | Lwt_unix.ADDR_INET (addr, port) -> Fmt.pf ppf "TCP %s:%d" (Unix.string_of_inet_addr addr) port let safe_close fd = Lwt...
57cd79e8b62ea9b7720d80da8d3afb2c39ddc1b0c643fa2bcf3d66c801dccd76
easyuc/EasyUC
ucTypesExprsErrorMessages.mli
(* UcTypesExprsErrorMessages module interface *) (* Formatting error messages issued when translating types and expressions *) adapted from ecUserMessages.mli of EasyCrypt distribution open EcEnv open UcTransTypesExprs val pp_tyerror : env -> Format.formatter -> tyerror -> unit
null
https://raw.githubusercontent.com/easyuc/EasyUC/0ee14ef8b024a8e7acde1035d06afecbdcaec990/uc-dsl/ucdsl-proj/src/ucTypesExprsErrorMessages.mli
ocaml
UcTypesExprsErrorMessages module interface Formatting error messages issued when translating types and expressions
adapted from ecUserMessages.mli of EasyCrypt distribution open EcEnv open UcTransTypesExprs val pp_tyerror : env -> Format.formatter -> tyerror -> unit
1abcfd4b673b27364041abdfad3f3f6c27e73ae7e9484e446dc92a367cec0910
yesodweb/persistent
SharedPrimaryKeyImportedSpec.hs
# LANGUAGE TypeApplications , DeriveGeneric # {-# LANGUAGE DataKinds, ExistentialQuantification #-} # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE QuasiQuotes # # LANGUAGE TemplateHaskell # # LANGUAGE TypeFamilies #...
null
https://raw.githubusercontent.com/yesodweb/persistent/6de3ffe570911fdbf66c2a760c4c5dab084166c4/persistent/test/Database/Persist/TH/SharedPrimaryKeyImportedSpec.hs
haskell
# LANGUAGE DataKinds, ExistentialQuantification # # LANGUAGE OverloadedStrings # able to use 'UserId' directly, since the type is imported from another module.
# LANGUAGE TypeApplications , DeriveGeneric # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # # LANGUAGE QuasiQuotes # # LANGUAGE TemplateHaskell # # LANGUAGE TypeFamilies # # LANGUAGE UndecidableInstances # # LANGUAGE DerivingStrategies # # LANGUAGE StandaloneD...
8ea35ffacf0e7721df1a2d622dd4d6e6b3429d324d89a2087201ec584c73e4d3
lemonidas/Alan-Compiler
OptimizationSupport.ml
open QuadTypes open Quads open Error open Symbol open Identifier (* Type Definitions *) (* Flowgraph *) type flowgraph_node_t = { code_block : quad_t array; mutable parents : int list; mutable children : int list } type flowgraph_t = flowgraph_node_t array UD Chain Node type chain_node_t = { entry ...
null
https://raw.githubusercontent.com/lemonidas/Alan-Compiler/bbedcbf91028d45a2e26839790df2a1347e8bc52/OptimizationSupport.ml
ocaml
Type Definitions Flowgraph The entry it holds Block no Instruction offset For Constant Prop List of Linked Nodes Pair module and Set A simple Set of Integers for use throughout Set of quad_elem_t First Mark a Node as Visited Then parse the children of the node while adding node...
open QuadTypes open Quads open Error open Symbol open Identifier type flowgraph_node_t = { code_block : quad_t array; mutable parents : int list; mutable children : int list } type flowgraph_t = flowgraph_node_t array UD Chain Node type chain_node_t = { } module Pair = struct type t = int * int let com...
a2161faf48f64322ec51d267dad5df1ef0719ef1a0183ae2371e7599198df2a2
ormf/cm-incudine
package.lisp
package.lisp ;;; ;;; ********************************************************************** Copyright ( c ) 2017 < > ;;; ;;; This program is free software; you can redistribute it and/or modify it under the terms of the Gnu Public License , version 2 or ;;; later. See -2.0.html for the text ;;; of this agreeme...
null
https://raw.githubusercontent.com/ormf/cm-incudine/1be490608ce25e8562aafb299ec1178c9c068ba3/src/package.lisp
lisp
********************************************************************** This program is free software; you can redistribute it and/or later. See -2.0.html for the text of this agreement. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty ...
package.lisp Copyright ( c ) 2017 < > modify it under the terms of the Gnu Public License , version 2 or (defpackage #:cm-incudine (:use #:cl #:cm))
d1af1c4b16287ae42bad3aee5a62351e01f3fe42ab80dd80497ae3c7dcd2884c
fujita-y/digamma
write.scm
Copyright ( c ) 2004 - 2022 Yoshikatsu Fujita / LittleWing Company Limited . ;;; See LICENSE file for terms and conditions of use. (define-library (scheme write) (import (core primitives)) (export display write-shared write write-simple) (begin (define write-shared write-with-shared-structure) (define ...
null
https://raw.githubusercontent.com/fujita-y/digamma/58cccd77bd2c208ec58d3cd634cbe65e32b3c7ec/stdlib/scheme/write.scm
scheme
See LICENSE file for terms and conditions of use.
Copyright ( c ) 2004 - 2022 Yoshikatsu Fujita / LittleWing Company Limited . (define-library (scheme write) (import (core primitives)) (export display write-shared write write-simple) (begin (define write-shared write-with-shared-structure) (define write-simple write)))
b0331956110a74adb43c2cd11da4a33de26ec6f2b5095f6d9c1594173d8c2817
clojurians-org/haskell-example
HttpServer.hs
# LANGUAGE NoImplicitPrelude # # LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # module Backend.HttpServer (serveHTTP) where import Common.Api import Common.WebSocketMessage import Prelude import GHC.Int (Int64) import GHC.Generics (Generic) import Data.Proxy (Proxy(..)) import Control.Monad.IO.Class (MonadIO, liftI...
null
https://raw.githubusercontent.com/clojurians-org/haskell-example/c96b021bdef52a121e04ea203c8c3e458770a25a/conduit-ui/backend/src/Backend/HttpServer.hs
haskell
# LANGUAGE NoImplicitPrelude # # LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # module Backend.HttpServer (serveHTTP) where import Common.Api import Common.WebSocketMessage import Prelude import GHC.Int (Int64) import GHC.Generics (Generic) import Data.Proxy (Proxy(..)) import Control.Monad.IO.Class (MonadIO, liftI...
d132ae51fdd825349fa749ae7b4a1d15babc918207c373b1d263c93bf94e7586
mankyKitty/cautious-sniffle
Chrome.hs
# LANGUAGE FlexibleInstances # # LANGUAGE GADTs # {-# LANGUAGE LambdaCase #-} # LANGUAGE MultiParamTypeClasses # # LANGUAGE OverloadedStrings # {-# LANGUAGE StandaloneDeriving #-} {-# LANGUAGE TemplateHaskell #-} # LANGUAGE TupleSections # # LANGUAGE TypeFamilies ...
null
https://raw.githubusercontent.com/mankyKitty/cautious-sniffle/8916ef6e2d310158a76f8f573841e09ce3a0d7da/lib/Protocol/Webdriver/ClientAPI/Types/Capabilities/Chrome.hs
haskell
# LANGUAGE LambdaCase # # LANGUAGE StandaloneDeriving # # LANGUAGE TemplateHaskell # | Chrome/Chromium specific capabilities * Types * Helpers * Encoders/Decoders Capabilities from Refer to the [chromedriver]() for more info.
# LANGUAGE FlexibleInstances # # LANGUAGE GADTs # # LANGUAGE MultiParamTypeClasses # # LANGUAGE OverloadedStrings # # LANGUAGE TupleSections # # LANGUAGE TypeFamilies # module Protocol.Webdriver.ClientAPI.Types.Capabilities.Chrome ChromeCap (..) , ChromeCaps , Chrom...
1e9b28db166cb394ec259bba0c9cd22a195606d61548104f721b26260c038326
blockfrost/blockfrost-haskell
Tag.hs
| Tag instance for HasClient # LANGUAGE DataKinds # # LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeApplications # # LANGUAGE TypeFamilies # # LANGUAGE TypeOperators # module Blockfrost.Client.Tag where import Data.Proxy (Proxy (..)) import Servan...
null
https://raw.githubusercontent.com/blockfrost/blockfrost-haskell/d9b9537b4e74f9eb0e94a061deec82638152d377/blockfrost-client-core/src/Blockfrost/Client/Tag.hs
haskell
| Tag instance for HasClient # LANGUAGE DataKinds # # LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeApplications # # LANGUAGE TypeFamilies # # LANGUAGE TypeOperators # module Blockfrost.Client.Tag where import Data.Proxy (Proxy (..)) import Servan...
e218a99628ce5e2f5028475566f6f62a3af40a313720c0549e5f191188b4b983
snoyberg/http-client
MultipartFormData.hs
{-# LANGUAGE OverloadedStrings #-} -- | This module handles building multipart/form-data. Example usage: -- -- > {-# LANGUAGE OverloadedStrings #-} > import Network > import Network . HTTP.Client > import Network . HTTP.Client . MultipartFormData -- > -- > import Data.Text.Encoding as TE -- > > import Control ....
null
https://raw.githubusercontent.com/snoyberg/http-client/106951809b3e1c796ffd6cccefc4c1fad16df7c9/http-client/Network/HTTP/Client/MultipartFormData.hs
haskell
# LANGUAGE OverloadedStrings # | This module handles building multipart/form-data. Example usage: > {-# LANGUAGE OverloadedStrings #-} > > import Data.Text.Encoding as TE > > > req1 <- parseRequest "-cat-photo.net/cat.jpg" > req2 <- parseRequest "/~friedrich/blog/addPost.hs" > flip httpLbs m =<< ...
> import Network > import Network . HTTP.Client > import Network . HTTP.Client . MultipartFormData > import Control . Monad > main = void $ withManager defaultManagerSettings $ \m - > do > req1 m > ( formDataBody [ partBS " title " " Bleaurgh " > , partBS " text ...
00997880579f482e11460f0ed44243e2ad9ab283d34b69f5f1a490cf7af6545f
wooga/erlang_prelude
ep_deploy.erl
-module(ep_deploy). %% ================================================================== %% ep_deploy Behaviour Specification %% ================================================================== -callback reload([atom()]) -> ok. %% ================================================================== %% API Function...
null
https://raw.githubusercontent.com/wooga/erlang_prelude/ce7e96ef58dee98e8f67232b21cd5aabc7963f2f/src/ep_deploy.erl
erlang
================================================================== ep_deploy Behaviour Specification ================================================================== ================================================================== API Function Exports ==========================================================...
-module(ep_deploy). -callback reload([atom()]) -> ok. -export([ reload_app/1 , reload_apps/1 , load_app/1 , modules_for_app/1 , reload_module/1 , reload_module/2 , add_paths/1 , module_modified/1 , find_module_file/1 , modified_deps/0 ...
c89d60a3fb80e72bf66b903941fa6e8c0d53d92a6a513a9a54db1005e4567503
k0001/exinst
Product.hs
# LANGUAGE DeriveGeneric # # LANGUAGE PolyKinds # module Exinst.Internal.Product ( P1(P1) , P2(P2) , P3(P3) , P4(P4) ) where import GHC.Generics (Generic) -------------------------------------------------------------------------------- -- Products | Like ' Data . Functor . Product . Product ' from " Data . F...
null
https://raw.githubusercontent.com/k0001/exinst/556035943d2a76d3cf796672313a948a0fe13787/exinst/lib/Exinst/Internal/Product.hs
haskell
------------------------------------------------------------------------------ Products only intended to be used with kinds other than 'Type'. This type is particularly useful when used in combination with 'Exinst.Some1' @quickcheck@ out of the box, so you can benefit from them as well.
# LANGUAGE DeriveGeneric # # LANGUAGE PolyKinds # module Exinst.Internal.Product ( P1(P1) , P2(P2) , P3(P3) , P4(P4) ) where import GHC.Generics (Generic) | Like ' Data . Functor . Product . Product ' from " Data . Functor . Product " , but as @'Exinst . Some1 ' ( ' P1 ' l , so as to ensure that @l@ and @...
c311acfcd04b1ae35bc2268f857911381221b6745060740c52af3df36bf52087
TrustInSoft/tis-interpreter
escape.mli
(****************************************************************************) (* *) Copyright ( C ) 2001 - 2003 < > (* Scott McPeak <> ...
null
https://raw.githubusercontent.com/TrustInSoft/tis-interpreter/33132ce4a825494ea48bf2dd6fd03a56b62cc5c3/src/libraries/utils/escape.mli
ocaml
************************************************************************** Scott McPeak <> All rights reserved. ...
Copyright ( C ) 2001 - 2003 < > < > < > 1 . Redistributions of source code must retain the above copyright 2 . Redistributions i...
02101dc2dc88141ca1e4b1633607ee7a19eca727adb3080d5bc747e5c15cf015
2600hz/kazoo
kz_base64url.erl
%%%----------------------------------------------------------------------------- ( C ) 2012 - 2020 , 2600Hz %%% @doc This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. %%% %%% @end %%%--------...
null
https://raw.githubusercontent.com/2600hz/kazoo/24519b9af9792caa67f7c09bbb9d27e2418f7ad6/core/kazoo_stdlib/src/kz_base64url.erl
erlang
----------------------------------------------------------------------------- @doc @end -----------------------------------------------------------------------------
( C ) 2012 - 2020 , 2600Hz This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. -module(kz_base64url). -export([decode/1 ,encode/1 ]). -spec encode(binary() | iolist()) -> bina...
7e24eb64e9c195ee2385a5acbacf86e6e62f9372b716efd411618ee9bbcf2e63
plum-umd/c-strider
cil.mli
* * Copyright ( c ) 2001 - 2002 , * < > * < > * < > * 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...
null
https://raw.githubusercontent.com/plum-umd/c-strider/3d3a3743bc28456eb6d50e01805ce484ab3c04e6/tools/cil-1.3.7/src/cil.mli
ocaml
* {b CIL API Documentation.} An html version of this document * can be found at * Call this function to perform some initialization. Call if after you have * set {!Cil.msvcMode}. * This are the CIL version numbers. A CIL version is a number of the form * M.m.r (major, minor and release) * {b The Abstract S...
* * Copyright ( c ) 2001 - 2002 , * < > * < > * < > * 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...
dcea1be2c8fd45a672aa87544149fa8510bdea929b756136eec81aa19089128e
mcgizzle/CS4012-Functional-Programming
EitherT.hs
# LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE MultiParamTypeClasses # module EitherT where import Control.Monad newtype MyEitherT l m r = MyEitherT { runMyEitherT :: m (Either l r) } class MonadTrans t where lift :: Monad m => m a -> t m a class (Show e, Mona...
null
https://raw.githubusercontent.com/mcgizzle/CS4012-Functional-Programming/31d73663f982020b2890c1605964a696685f2410/EitherT.hs
haskell
# LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE MultiParamTypeClasses # module EitherT where import Control.Monad newtype MyEitherT l m r = MyEitherT { runMyEitherT :: m (Either l r) } class MonadTrans t where lift :: Monad m => m a -> t m a class (Show e, Mona...
1ed47cabcf0e4a91380db99a9a8c711ede2a9866fcbb75b54b1cfa6d0822f059
fulcro-legacy/semantic-ui-wrapper
ui_grid_column.cljs
(ns fulcrologic.semantic-ui.collections.grid.ui-grid-column (:require [fulcrologic.semantic-ui.factory-helpers :as h] ["semantic-ui-react/dist/commonjs/collections/Grid/GridColumn" :default GridColumn])) (def ui-grid-column "A column sub-component for Grid. Props: - as (custom): An element type to...
null
https://raw.githubusercontent.com/fulcro-legacy/semantic-ui-wrapper/b0473480ddfff18496df086bf506099ac897f18f/semantic-ui-wrappers-shadow/src/main/fulcrologic/semantic_ui/collections/grid/ui_grid_column.cljs
clojure
(ns fulcrologic.semantic-ui.collections.grid.ui-grid-column (:require [fulcrologic.semantic-ui.factory-helpers :as h] ["semantic-ui-react/dist/commonjs/collections/Grid/GridColumn" :default GridColumn])) (def ui-grid-column "A column sub-component for Grid. Props: - as (custom): An element type to...
f83baf3ec310252288ad461e905ebd8b922a7a3c4063f7af2852ecf59fd967f4
JacquesCarette/Drasil
Domains.hs
| Defines domains of knowledge for use in . module Data.Drasil.Domains where import Language.Drasil (IdeaDict, mkIdea, cn') | Various domains that are used in . May have an abbreviation . compScience, softEng, mathematics, progLanguage, physics, civilEng, materialEng, documentc, knowledgemng :: IdeaDict -----...
null
https://raw.githubusercontent.com/JacquesCarette/Drasil/92dddf7a545ba5029f99ad5c5eddcd8dad56a2d8/code/drasil-metadata/lib/Data/Drasil/Domains.hs
haskell
----------------------------------------------------------------------------- IdeaDict | | id | term | abbreviation ----------------------------------------------------------------------------- | For ideas, concepts, or terms related to Documents.
| Defines domains of knowledge for use in . module Data.Drasil.Domains where import Language.Drasil (IdeaDict, mkIdea, cn') | Various domains that are used in . May have an abbreviation . compScience, softEng, mathematics, progLanguage, physics, civilEng, materialEng, documentc, knowledgemng :: IdeaDict | F...
4275d4b738fd73a19885ae8c92650c5693ef37fefb3a12db1a25b537eb1a1364
codinuum/cca
const.ml
Copyright 2012 - 2020 Codinuum Software Lab < > 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 wri...
null
https://raw.githubusercontent.com/codinuum/cca/88ea07f3fe3671b78518769d804fdebabcd28e90/src/ast/analyzing/common/const.ml
ocaml
diffviewer
Copyright 2012 - 2020 Codinuum Software Lab < > 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 wri...
b6ce8bcda4767250dba53109e85515012afa33aaee637c1b41547b8cc3b764a8
solarbit/pool
sbt_pool_srv.erl
Copyright 2016 < > See MIT LICENSE -module(sbt_pool_srv). -include("solarbit.hrl"). -include_lib("bitcoin/include/bitcoin.hrl"). -export([start_link/1]). -behaviour(gen_server). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, code_change/3, terminate/2]). -compile(export_all). start_link([])...
null
https://raw.githubusercontent.com/solarbit/pool/5576f1b71a469dfa2fcb6b5766667402eacc3860/lib/solarbit/src/sbt_pool_srv.erl
erlang
?TTY({pool, Host, Port}), ignore messages from self TODO: Check versioning, block reward, and do correct calculation of difficulty bits TODO: correct this TODO: correct calculation TODO: proper mempool selection and fee values questionable
Copyright 2016 < > See MIT LICENSE -module(sbt_pool_srv). -include("solarbit.hrl"). -include_lib("bitcoin/include/bitcoin.hrl"). -export([start_link/1]). -behaviour(gen_server). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, code_change/3, terminate/2]). -compile(export_all). start_link([])...
23c40e1e48629e848b1503de608423b61d8d681b46dc298472a77cb89dec22d7
bakul/s9fes
t-sort.scm
Scheme 9 from Empty Space , Function Library By , ; Placed in the Public Domain ; ( t - sort object procedure2 < option > ... ) = = > list ; (t-sort-net procedure^2 list <option> ...) ==> list ; Sort the directed acyclic graph ( DAG ) LIST topologically in such a way that all dependencies o...
null
https://raw.githubusercontent.com/bakul/s9fes/74c14c0db5f07f5bc6d94131e9e4ee15a29275aa/lib/t-sort.scm
scheme
Placed in the Public Domain (t-sort-net procedure^2 list <option> ...) ==> list (called the "goal") are resolved. PROCEDURE^2 is used to identify ((<name-1> <ref> ...) ... (<name-N> <ref> ...)) names a child of the node. Node <name-I> is said to depend on leaf node. When the...
Scheme 9 from Empty Space , Function Library By , ( t - sort object procedure2 < option > ... ) = = > list Sort the directed acyclic graph ( DAG ) LIST topologically in such a way that all dependencies of the first node in the DAG nodes in the DAG . A DAG is represented by a list of lists of the ...
443b4d05b085011134b9f18ce5769dc271f4b6ee6e5dcbbd7743d5ffbb5d1dbd
lehins/primal
Primal.hs
# LANGUAGE CPP # {-# LANGUAGE GADTs #-} # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # # LANGUAGE PolyKinds # {-# LANGUAGE RankNTypes #-} # LANGUAGE ScopedTypeVariables # # LANGUAGE StandaloneDeriving # # LANGUAGE TypeFamilies # # LANGUAGE TypeOperators # module Test.Primal ( module Test.Primal , ...
null
https://raw.githubusercontent.com/lehins/primal/c620bfd4f2a6475f1c12183fbe8138cf29ab1dad/primal-test/src/Test/Primal.hs
haskell
# LANGUAGE GADTs # # LANGUAGE RankNTypes # -- Orphans Foreign.C.Error System.IO GHC.IO.Device GHC.Conc Data.Monoid Data.Semigroup Defined in `primal` restricted recursive polymorphic (built-in) recursive polymorphic
# LANGUAGE CPP # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # # LANGUAGE PolyKinds # # LANGUAGE ScopedTypeVariables # # LANGUAGE StandaloneDeriving # # LANGUAGE TypeFamilies # # LANGUAGE TypeOperators # module Test.Primal ( module Test.Primal , module Test.Primal.Common , module Primal.Element...
f51b154617b1296b53cd27b19e2ba8668df98fc859433187fadb71473e9e3731
mejgun/haskell-tdlib
UnpinAllMessageThreadMessages.hs
{-# LANGUAGE OverloadedStrings #-} -- | module TD.Query.UnpinAllMessageThreadMessages where import qualified Data.Aeson as A import qualified Data.Aeson.Types as T import qualified Utils as U -- | -- Removes all pinned messages from a forum topic; requires can_pin_messages rights in the supergroup data UnpinAllMessa...
null
https://raw.githubusercontent.com/mejgun/haskell-tdlib/dc380d18d49eaadc386a81dc98af2ce00f8797c2/src/TD/Query/UnpinAllMessageThreadMessages.hs
haskell
# LANGUAGE OverloadedStrings # | | Removes all pinned messages from a forum topic; requires can_pin_messages rights in the supergroup | Message thread identifier in which messages will be unpinned | Identifier of the chat
module TD.Query.UnpinAllMessageThreadMessages where import qualified Data.Aeson as A import qualified Data.Aeson.Types as T import qualified Utils as U data UnpinAllMessageThreadMessages = UnpinAllMessageThreadMessages message_thread_id :: Maybe Int, chat_id :: Maybe Int } deriving (Eq) instance Show Un...
9cf9899dfdcfcbf614cf22db205f4fa8382748f01b27f102e60698faaae5a0d2
incoherentsoftware/defect-process
AttackSpecks.hs
module Particle.All.AttackSpecks ( module Particle.All.AttackSpecks.Types , mkAttackSpecksParticle , mkAttackSpecksParticleEx ) where import Control.Monad.IO.Class (MonadIO) import Data.Foldable (for_) import Data.Maybe (fromMaybe) import System.Random (randomRIO) import q...
null
https://raw.githubusercontent.com/incoherentsoftware/defect-process/8797aad1d93bff5aadd7226c39a48f45cf76746e/src/Particle/All/AttackSpecks.hs
haskell
module Particle.All.AttackSpecks ( module Particle.All.AttackSpecks.Types , mkAttackSpecksParticle , mkAttackSpecksParticleEx ) where import Control.Monad.IO.Class (MonadIO) import Data.Foldable (for_) import Data.Maybe (fromMaybe) import System.Random (randomRIO) import q...
82d1e496a5634787d9eaae50a9521ace9462a5a94886dc41db5ee9aa50abe936
phaul/chess
SearchResult.hs
# LANGUAGE TemplateHaskell # module Chess.Search.SearchResult ( SearchResult(..) , (<@>) , (<++>) , first , second , eval , moves ) where import Control.Lens import Control.Monad import Data.Maybe import qualified Chess.Move as M ...
null
https://raw.githubusercontent.com/phaul/chess/b9c71a0389ed44360caed4b830208ce346211cb8/Chess/Search/SearchResult.hs
haskell
# LANGUAGE TemplateHaskell # module Chess.Search.SearchResult ( SearchResult(..) , (<@>) , (<++>) , first , second , eval , moves ) where import Control.Lens import Control.Monad import Data.Maybe import qualified Chess.Move as M ...
d2728d1f135bdb67eea738f9ca1e997d154c13d53e87fb1b53be76cd41859160
thma/HasBigDecimal
TestUtils.hs
module Data.TestUtils where import Test.Hspec hiding (it) import qualified Test.Hspec as HS (it) import Test.Hspec.QuickCheck (modifyMaxSize, modifyMaxSuccess) import Test.QuickCheck hiding (shrink) import Data.BigDecimal import Numeric.Natural ...
null
https://raw.githubusercontent.com/thma/HasBigDecimal/d5b4f28368cdb061b117e83862435a9e96d27351/test/Data/TestUtils.hs
haskell
module Data.TestUtils where import Test.Hspec hiding (it) import qualified Test.Hspec as HS (it) import Test.Hspec.QuickCheck (modifyMaxSize, modifyMaxSuccess) import Test.QuickCheck hiding (shrink) import Data.BigDecimal import Numeric.Natural ...
73e1882c2549874849351c50450ec63927e2da72fab6d2df828162c83bdf9a2c
erszcz/learning
elixir_libs.erl
-module(elixir_libs). -export([test/0]). -define(Date, 'Elixir.Timex.Date'). -define(DateF, 'Elixir.Timex.DateFormat'). test() -> Now = ?Date:from(calendar:local_time(), <<"Europe/Warsaw">>), print("~p~n", [Now]), print("~p~n", [?Date:universal()]), print("~p~n", [?Date:local()]), print("ISO : ~s...
null
https://raw.githubusercontent.com/erszcz/learning/b21c58a09598e2aa5fa8a6909a80c81dc6be1601/erlang-elixir-libs/src/elixir_libs.erl
erlang
-module(elixir_libs). -export([test/0]). -define(Date, 'Elixir.Timex.Date'). -define(DateF, 'Elixir.Timex.DateFormat'). test() -> Now = ?Date:from(calendar:local_time(), <<"Europe/Warsaw">>), print("~p~n", [Now]), print("~p~n", [?Date:universal()]), print("~p~n", [?Date:local()]), print("ISO : ~s...
7d675529b3c9df1519102bad5cad7758303ae071fd2cdfac7877efd91a23a359
deepfire/cl-org-mode
middle.lisp
(defpackage :cl-org-mode-middle-tests (:use :cl :alexandria :iterate :cl-org-mode)) (in-package :cl-org-mode-middle-tests) (rtest:deftest :middle/org-dress (length (mapcar #'org-parse cl-org-mode-raw-tests::*org-files*)) 3) (rtest:deftest :middle/org-present (org-present :flat (org-parse (lastcar c...
null
https://raw.githubusercontent.com/deepfire/cl-org-mode/a45eadade90d64ec0d543b6a2befcb302d63fdbb/t/middle.lisp
lisp
(defpackage :cl-org-mode-middle-tests (:use :cl :alexandria :iterate :cl-org-mode)) (in-package :cl-org-mode-middle-tests) (rtest:deftest :middle/org-dress (length (mapcar #'org-parse cl-org-mode-raw-tests::*org-files*)) 3) (rtest:deftest :middle/org-present (org-present :flat (org-parse (lastcar c...
f8009640f59f1776c8aaf8df528a1397ff24d59e42d38e39efe55210858805ef
kadena-io/chainweaver
Receive.hs
# LANGUAGE PatternGuards # # LANGUAGE RecursiveDo # # LANGUAGE ScopedTypeVariables # # LANGUAGE TupleSections # -- | Dialog for displaying account information required for receiving transfers Copyright : ( C ) 2020 - 2022 Kadena -- License : BSD-style (see the file LICENSE) module Frontend.UI.Dialogs.Receiv...
null
https://raw.githubusercontent.com/kadena-io/chainweaver/5d40e91411995e0a9a7e782d6bb2d89ac1c65d52/frontend/src/Frontend/UI/Dialogs/Receive.hs
haskell
| Dialog for displaying account information required for receiving transfers License : BSD-style (see the file LICENSE)
# LANGUAGE PatternGuards # # LANGUAGE RecursiveDo # # LANGUAGE ScopedTypeVariables # # LANGUAGE TupleSections # Copyright : ( C ) 2020 - 2022 Kadena module Frontend.UI.Dialogs.Receive ( uiReceiveModal ) where import Control.Applicative (liftA2) import Control.Lens ((^.), (<>~), (^?), to) import Control.Mona...
710b550416862fd16521e750ca1faca28be8c9e55eb0c3839231da5c665af1ad
PseudoPower/AFSM
SF.hs
----------------------------------------------------------------------------- -- | -- Module : Data.AFSM.SF Copyright : ( c ) , 2016 , License : MIT License -- -- Maintainer : -- Stability : experimental -- Portability : portable -- -- Stateful functions It is the same with SMH , an...
null
https://raw.githubusercontent.com/PseudoPower/AFSM/9d6ace9d279992a18f44856058040a0ef391abd6/src/Data/AFSM/SF.hs
haskell
--------------------------------------------------------------------------- | Module : Data.AFSM.SF Maintainer : Stability : experimental Portability : portable Stateful functions --------------------------------------------------------------------------- module Data.AFSM.SF.FunctorSF,
Copyright : ( c ) , 2016 , License : MIT License It is the same with SMH , and it just removes the empty storage . module Data.AFSM.SF ( SF(..), newSF, simpleSF, STF(..), transSTF2SF, transSF2STF, buildSrc, simpleSrc, idSF, arrSF, constSF, delaySF, foldlSF,...
3691c98a2b24e9c277f0b00fc2518a1e884c2363fc7f90a0432baefadd3c1126
avsm/mirage-duniverse
zed_lines.mli
* zed_lines.mli * ------------- * Copyright : ( c ) 2011 , < > * Licence : BSD3 * * This file is a part of , an editor engine . * zed_lines.mli * ------------- * Copyright : (c) 2011, Jeremie Dimino <> * Licence : BSD3 * * This file is a part of Zed, an editor engine. *) (** Sets o...
null
https://raw.githubusercontent.com/avsm/mirage-duniverse/983e115ff5a9fb37e3176c373e227e9379f0d777/ocaml_modules/zed/src/zed_lines.mli
ocaml
* Sets of line positions. * This module implement sets of line positions. They allow to efficiently find the beginning of a line and to convert offset to line and column number. * Exception raised when trying to access a position outside the bounds of a set. * Type of sets of line positions. * Returns...
* zed_lines.mli * ------------- * Copyright : ( c ) 2011 , < > * Licence : BSD3 * * This file is a part of , an editor engine . * zed_lines.mli * ------------- * Copyright : (c) 2011, Jeremie Dimino <> * Licence : BSD3 * * This file is a part of Zed, an editor engine. *) exceptio...
dd21f09e4e7530946f3695560ddbc359b85815f7de417baba7cb907fb56369e0
AlexCharlton/site-generator
publish.lisp
(in-package :site-generator) # # Site publishing (export '(publish-site)) (defun publish-site (dir) "Pathspec -> nil Generate the site, then copy its contents to the server specified by :SERVER in *ENVIRONMENT*, via Rsync." (generate-site dir) (print-message "Publishing ~a" dir) (let* ((config-content (parse...
null
https://raw.githubusercontent.com/AlexCharlton/site-generator/a827cfeccc72527de44ec048f1b9dd703eb6fe8f/src/publish.lisp
lisp
(in-package :site-generator) # # Site publishing (export '(publish-site)) (defun publish-site (dir) "Pathspec -> nil Generate the site, then copy its contents to the server specified by :SERVER in *ENVIRONMENT*, via Rsync." (generate-site dir) (print-message "Publishing ~a" dir) (let* ((config-content (parse...
b41dfda971c456f7d8aff488eeecaade074e7f4617dffbe889d40ace6752e4d2
tommaisey/aeon
pv-local-max.help.scm
;; (pv-local-max buffer threshold) ;; Pass bins which are a local maximum ;; Passes only bins whose magnitude is above a threshold and above ;; their nearest neighbors. ;; buffer - fft buffer. ;; threshold - magnitude threshold. (with-sc3 (lambda (fd) (async fd (b-alloc 10 2048 1)) (async fd (b-alloc-read 12...
null
https://raw.githubusercontent.com/tommaisey/aeon/80744a7235425c47a061ec8324d923c53ebedf15/libs/third-party/sc3/rsc3/help/ugen/fft/pv-local-max.help.scm
scheme
(pv-local-max buffer threshold) Pass bins which are a local maximum Passes only bins whose magnitude is above a threshold and above their nearest neighbors. buffer - fft buffer. threshold - magnitude threshold.
(with-sc3 (lambda (fd) (async fd (b-alloc 10 2048 1)) (async fd (b-alloc-read 12 "/home/rohan/audio/metal.wav" 0 0)))) (let* ((a (play-buf 1 12 (buf-rate-scale kr 12) 0 0 1)) (f (fft* 10 a)) (h (pv-local-max f (mouse-x kr 0 100 0 0.1)))) (audition (out 0 (mul (ifft* h) 0.5))))
9c56b4f3c052a34e324e34646ae1ac11c74289e739dfbad9552513db6cb038a4
marcoheisig/Petalisp
documentation.lisp
© 2016 - 2023 - license : GNU AGPLv3 -*- coding : utf-8 -*- (in-package #:petalisp.utilities) (defun ensure-documentation (name new-value kind) (check-type new-value string) (symbol-macrolet ((documentation (documentation name kind))) (cond ((null documentation) (setf documentation new...
null
https://raw.githubusercontent.com/marcoheisig/Petalisp/0e8716ddc5d1a29c04e83d189fc6fb33c1b76e7e/code/utilities/documentation.lisp
lisp
© 2016 - 2023 - license : GNU AGPLv3 -*- coding : utf-8 -*- (in-package #:petalisp.utilities) (defun ensure-documentation (name new-value kind) (check-type new-value string) (symbol-macrolet ((documentation (documentation name kind))) (cond ((null documentation) (setf documentation new...
dcc192e31e172ed6aa375eebc5400526d8f9ee9e3152163c8e221f2c2ef4e8f3
reach-sh/reach-lang
EraseLogic.hs
module Reach.EraseLogic (erase_logic) where import Control.Monad.Reader import Data.IORef import qualified Data.Map as M import qualified Data.Set as S import Reach.AST.DLBase import Reach.AST.LL import Reach.CollectCounts data Env = Env {e_vs :: IORef (S.Set DLVar)} type App = ReaderT Env IO isUsed :: DLLetVar -...
null
https://raw.githubusercontent.com/reach-sh/reach-lang/f79282c49705c66fc10489045d502d17621d60c5/hs/src/Reach/EraseLogic.hs
haskell
# OVERLAPS # # OVERLAPS # # OVERLAPS # # OVERLAPS # # OVERLAPS # # OVERLAPS #
module Reach.EraseLogic (erase_logic) where import Control.Monad.Reader import Data.IORef import qualified Data.Map as M import qualified Data.Set as S import Reach.AST.DLBase import Reach.AST.LL import Reach.CollectCounts data Env = Env {e_vs :: IORef (S.Set DLVar)} type App = ReaderT Env IO isUsed :: DLLetVar -...
d4a15616bf73227691ce6c24c01b85d691958c7a5d744c576a863949fa308023
kadena-io/pact
HistoryServiceSpec.hs
{-# LANGUAGE OverloadedStrings #-} module HistoryServiceSpec (spec) where import Control.Concurrent.MVar import Control.Monad.IO.Class import Control.Monad.Trans.RWS.Strict import Data.ByteString (ByteString) import qualified Data.HashMap.Strict as HashMap import qualified Data.HashSet as HashSet import Test.Hspec i...
null
https://raw.githubusercontent.com/kadena-io/pact/9c1fb4ae365d6d8311b2a1b5db7a7641961917ae/tests/HistoryServiceSpec.hs
haskell
# LANGUAGE OverloadedStrings # dbg = putStrLn -- <- USE THIS TO DEBUG HISTORY STUFF
module HistoryServiceSpec (spec) where import Control.Concurrent.MVar import Control.Monad.IO.Class import Control.Monad.Trans.RWS.Strict import Data.ByteString (ByteString) import qualified Data.HashMap.Strict as HashMap import qualified Data.HashSet as HashSet import Test.Hspec import Test.Hspec.Core.Spec import D...