_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
d062bba070a30caed90e838ed81915ac4745695f73ee8a82454d0b58b85bf868
chenyukang/eopl
drscheme-init-cps.scm
drscheme-init-cps.scm - compatibility file for DrScheme ;; usage: (require "drscheme-init-cps.scm") ;;; like drscheme-init, but also provides a logged-print functionality ;;; that can be used to check the correctness of printed output. ;;; makes structs printable, and provides basic functionality for ;;; testing. ...
null
https://raw.githubusercontent.com/chenyukang/eopl/0406ff23b993bfe020294fa70d2597b1ce4f9b78/base/chapter5/letrec-lang/drscheme-init-cps.scm
scheme
usage: (require "drscheme-init-cps.scm") like drscheme-init, but also provides a logged-print functionality that can be used to check the correctness of printed output. makes structs printable, and provides basic functionality for testing. This includes pretty-printing and tracing. show the contents of define-da...
drscheme-init-cps.scm - compatibility file for DrScheme (module drscheme-init-cps.scm mzscheme (let ((version "plt360 2/25/07") (filename "drscheme-mp5-init.scm")) (printf "~a ~a~%" filename version)) (print-struct #t) (require (lib "pretty.ss")) (provide (all-from (lib "pretty.ss"))) ...
3f7225f53bbe84a19169323fd20ede83ba626320707f3af5848b161146eba28d
let-def/grenier
trope.ml
module O = Order_managed type cursor = O.t include (struct type +'a cell = {offset: int; cursor: cursor; value: 'a} let make_cell offset cursor value = assert (offset >= 0); {offset; cursor; value} let shift_cell n c = if n = 0 then c else make_cell (c.offset + n) c.cursor c.valu...
null
https://raw.githubusercontent.com/let-def/grenier/3391e5e31db88e587100436e9407881fb8ef7873/trope/trope.ml
ocaml
Splitting case c1 = 0 c1 < 0 && c2 > 0
module O = Order_managed type cursor = O.t include (struct type +'a cell = {offset: int; cursor: cursor; value: 'a} let make_cell offset cursor value = assert (offset >= 0); {offset; cursor; value} let shift_cell n c = if n = 0 then c else make_cell (c.offset + n) c.cursor c.valu...
512709f62516b84446f6c2c04c4ad5ff42a48541de7c5880bd40e11689811478
xh4/web-toolkit
element.lisp
(in-package :html-test) (in-suite :html-test) (test element (is-true (typep (html) 'html)) (is-true (typep (head) 'head)) (is-true (typep (body) 'body)) (is-true (typep (a) 'a)) (is-true (typep (p) 'p)) (is-true (typep (h1) 'h1))) (test attribute (let ((el (p :class "foo"))) (is (equal "foo" (dom:g...
null
https://raw.githubusercontent.com/xh4/web-toolkit/e510d44a25b36ca8acd66734ed1ee9f5fe6ecd09/test/html/element.lisp
lisp
(in-package :html-test) (in-suite :html-test) (test element (is-true (typep (html) 'html)) (is-true (typep (head) 'head)) (is-true (typep (body) 'body)) (is-true (typep (a) 'a)) (is-true (typep (p) 'p)) (is-true (typep (h1) 'h1))) (test attribute (let ((el (p :class "foo"))) (is (equal "foo" (dom:g...
d06932a0fab81449ff11f10e0501a96be17fd946eba90cc92211f57add585152
elaforge/karya
Control_test.hs
Copyright 2017 -- This program is distributed under the terms of the GNU General Public -- License 3.0, see COPYING or -3.0.txt module Perform.Midi.Control_test where import Util.Test import qualified Perform.Midi.Control as Control test_pitch_to_midi :: Test test_pitch_to_midi = do let f = Control.pitch_to_...
null
https://raw.githubusercontent.com/elaforge/karya/8ea15e6a5fb57e2f15f8c19836751e315f9c09f2/Perform/Midi/Control_test.hs
haskell
This program is distributed under the terms of the GNU General Public License 3.0, see COPYING or -3.0.txt Don't emit a pitch bend if it's close enough.
Copyright 2017 module Perform.Midi.Control_test where import Util.Test import qualified Perform.Midi.Control as Control test_pitch_to_midi :: Test test_pitch_to_midi = do let f = Control.pitch_to_midi (-1, 1) equal (f 10) (Just (10, 0)) equal (f 10.001) (Just (10, 0)) equal (f 9.999) (Just (10, 0...
4c91480411cadf3e16ee8f08735148d477a2d982ff113addfffea32dc9fb7d4f
clojure-grimoire/grimoire
service.clj
(ns grimoire.web.service (:require [compojure.handler :as handler] [environ.core :refer [env]] [grimoire.web [config :as cfg] [routes :refer [app]]] [ring.adapter.jetty :as jetty] [ring.middleware.session :as session] [simpledb.core...
null
https://raw.githubusercontent.com/clojure-grimoire/grimoire/1dfb4c1d82fe97d0b15f7f5fec626ac2178a5f05/src/main/grimoire/web/service.clj
clojure
boot the webapp itself Return nil b/c side-effects Return nil b/c side-effects Return nil b/c side-effects Boot the webserver Return nil b/c side-effects
(ns grimoire.web.service (:require [compojure.handler :as handler] [environ.core :refer [env]] [grimoire.web [config :as cfg] [routes :refer [app]]] [ring.adapter.jetty :as jetty] [ring.middleware.session :as session] [simpledb.core...
173d8fdae95b911583d9f72d78124e9282372f8337d372b312118cabbdf04952
stepcut/plugins
Main.hs
import System.Plugins import API -- an example where we just want to load an object and run it main = do m_v <- load "../Null.o" ["../api"] [] "resource" (m,v) <- case m_v of LoadSuccess m v -> return (m,v) _ -> error "load failed" putStrLn ( show (a v) ) m_v <- reload...
null
https://raw.githubusercontent.com/stepcut/plugins/52c660b5bc71182627d14c1d333d0234050cac01/testsuite/reload/null/prog/Main.hs
haskell
an example where we just want to load an object and run it get a new version
import System.Plugins import API main = do m_v <- load "../Null.o" ["../api"] [] "resource" (m,v) <- case m_v of LoadSuccess m v -> return (m,v) _ -> error "load failed" putStrLn ( show (a v) ) v' <- case m_v of LoadSuccess _ v -> return v _ ...
45a3bbebbb6c099f01ec067d6da365221eb8b724987cd11ef2c5551821e1a90e
lab-79/dspec
helpers_test.clj
(ns dspec.helpers-test (:require [clojure.test :refer :all] [clojure.spec.test :as stest] [lab79.dspec.helpers :refer :all] [clojure.spec :as s] [clojure.spec.gen :as gen] [datomic.api :as d] [dspec.util :refer [db-id?]])) ; Instrument all our f...
null
https://raw.githubusercontent.com/lab-79/dspec/26f88e74066e381c8569d175c1bd5948a8005bd0/test/dspec/helpers_test.clj
clojure
Instrument all our functions in dspec should not throw should not throw
(ns dspec.helpers-test (:require [clojure.test :refer :all] [clojure.spec.test :as stest] [lab79.dspec.helpers :refer :all] [clojure.spec :as s] [clojure.spec.gen :as gen] [datomic.api :as d] [dspec.util :refer [db-id?]])) (doseq [nspace ['lab79...
123cd44eed62986acad762a0dd62e98e248bf8ecfc32ba612ca95d3036f4b9d5
AdRoll/rebar3_format
hrl.erl
-module(hrl). -include("header.hrl").
null
https://raw.githubusercontent.com/AdRoll/rebar3_format/5ffb11341796173317ae094d4e165b85fad6aa19/test_app/after/src/hrl.erl
erlang
-module(hrl). -include("header.hrl").
7aa08c71dd7005738d07ab1f184f2c6bd0d06335cceca03dcd81c667c5eb593d
yesodweb/yesod
app.hs
{-# LANGUAGE OverloadedStrings #-} import Network.Wai import qualified Data.ByteString.Char8 as S8 import Network.Wai.Handler.Warp (run) import Network.Wai.Middleware.Debug (debug) import Network.Wai.Application.Static import Web.Routes main = run 3000 $ debug app app req = case decodePathInfo $ S8.unpack $ pathI...
null
https://raw.githubusercontent.com/yesodweb/yesod/c59993ff287b880abbf768f1e3f56ae9b19df51e/yesod-static/test/unicode/app.hs
haskell
# LANGUAGE OverloadedStrings #
import Network.Wai import qualified Data.ByteString.Char8 as S8 import Network.Wai.Handler.Warp (run) import Network.Wai.Middleware.Debug (debug) import Network.Wai.Application.Static import Web.Routes main = run 3000 $ debug app app req = case decodePathInfo $ S8.unpack $ pathInfo req of "static":"foo":r...
b22295ba6852e29412ff9e9e6dde1446a08044f68aa7e65b8c738b7df4855cda
herbertjones/my-stumpwm-config
mouse.lisp
(in-package :cl-user) (defpackage mouse-follow (:use :cl :stumpwm :hfj :alexandria) (:export *mouse-follow-banish-x-offset* *mouse-follow-banish-y-offset* disable enable)) (in-package :mouse-follow) (setf *mouse-focus-policy* :click) (defvar *mouse-follow-banish-x-offset* -15 "Negative values mean p...
null
https://raw.githubusercontent.com/herbertjones/my-stumpwm-config/e2f259895835e9f39250ea3546b24ec13fbd093c/mouse.lisp
lisp
Check Handlers Configuration
(in-package :cl-user) (defpackage mouse-follow (:use :cl :stumpwm :hfj :alexandria) (:export *mouse-follow-banish-x-offset* *mouse-follow-banish-y-offset* disable enable)) (in-package :mouse-follow) (setf *mouse-focus-policy* :click) (defvar *mouse-follow-banish-x-offset* -15 "Negative values mean p...
9dacc4c8ae3e87388de493a80d3b0cb5fa38a12ba24672a82ef807a50b4ee9c1
Haskell-OpenAPI-Code-Generator/Stripe-Haskell-Library
InvoicePaymentMethodOptionsUsBankAccountLinkedAccountOptions.hs
{-# LANGUAGE MultiWayIf #-} CHANGE WITH CAUTION : This is a generated code file generated by -OpenAPI-Code-Generator/Haskell-OpenAPI-Client-Code-Generator . {-# LANGUAGE OverloadedStrings #-} -- | Contains the types generated from the schema InvoicePaymentMethodOptionsUsBankAccountLinkedAccountOptions module StripeA...
null
https://raw.githubusercontent.com/Haskell-OpenAPI-Code-Generator/Stripe-Haskell-Library/ba4401f083ff054f8da68c741f762407919de42f/src/StripeAPI/Types/InvoicePaymentMethodOptionsUsBankAccountLinkedAccountOptions.hs
haskell
# LANGUAGE MultiWayIf # # LANGUAGE OverloadedStrings # | Contains the types generated from the schema InvoicePaymentMethodOptionsUsBankAccountLinkedAccountOptions | permissions: The list of permissions to request. The \`payment_method\` permission must be included. | Create a new 'InvoicePaymentMethodOptionsUsBankAc...
CHANGE WITH CAUTION : This is a generated code file generated by -OpenAPI-Code-Generator/Haskell-OpenAPI-Client-Code-Generator . module StripeAPI.Types.InvoicePaymentMethodOptionsUsBankAccountLinkedAccountOptions where import qualified Control.Monad.Fail import qualified Data.Aeson import qualified Data.Aeson as Da...
a8f1bd5ce4c38f307cc5369356a6640a21d563d1b79fb3c09456b5557568c7fc
rtrusso/scp
graph.scm
(define (graph-predecessors graph node) (filter-map (lambda (adj) (and (member node (cdr adj)) (car adj))) graph)) (define (graph-successors graph node) (let ((entry (assoc node graph))) (if (not entry) (error "Invalid graph node -- graph-succ...
null
https://raw.githubusercontent.com/rtrusso/scp/2051e76df14bd36aef81aba519ffafa62b260f5c/src/algo/graph.scm
scheme
(define (graph-predecessors graph node) (filter-map (lambda (adj) (and (member node (cdr adj)) (car adj))) graph)) (define (graph-successors graph node) (let ((entry (assoc node graph))) (if (not entry) (error "Invalid graph node -- graph-succ...
04f59bbc0b7fce07cc2d3a205faaf77e6b0474d1c58b40f69755fb1668bac243
vmchale/atspkg
Type.hs
{-# LANGUAGE DeriveAnyClass #-} # LANGUAGE DeriveFoldable # {-# LANGUAGE DeriveFunctor #-} {-# LANGUAGE DeriveGeneric #-} module Data.Dependency.Type ( Dependency (..) , Version (..) , Constraint (..) , PackageSet (..) ...
null
https://raw.githubusercontent.com/vmchale/atspkg/45be7ece6b9e9b09a7151efe53ff7e278112e84d/dependency/src/Data/Dependency/Type.hs
haskell
# LANGUAGE DeriveAnyClass # # LANGUAGE DeriveFunctor # # LANGUAGE DeriveGeneric # * Helper functions | A package set is simply a map between package names and a set of packages. | Monoid/functor for representing constraints. | A generic dependency, consisting of a package name and version, as well as dependency ...
# LANGUAGE DeriveFoldable # module Data.Dependency.Type ( Dependency (..) , Version (..) , Constraint (..) , PackageSet (..) , check ) where import Control.DeepSeq (NFD...
f2315c54bb94e4c6c2c778eb01ec4c4fc092da2984826edd43473ec48c4a8fbb
ftovagliari/ocamleditor
entry_combo_search.mli
OCamlEditor Copyright ( C ) 2010 - 2012 This file is part of OCamlEditor . OCamlEditor 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 y...
null
https://raw.githubusercontent.com/ftovagliari/ocamleditor/79669e14163420170e3e2ebb8da54ebe4e5a3dce/src/gmisclib/entry_combo_search.mli
ocaml
OCamlEditor Copyright ( C ) 2010 - 2012 This file is part of OCamlEditor . OCamlEditor 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 y...
735c5f5fb8fc65bf9bde7207191efa3d588b5433aad07804d4289d741ff22407
silviucpp/erltls
erltls_options.erl
-module(erltls_options). -include("erltls.hrl"). -export([ get_inet_names/1, get_inet_options/1, get_options/1, emulated_for_socket/1, default_inet_options/0, emulated_list2record/1, emulated_list2record/2, emulated_record2list/1, emulated_by_names/2, use_session_ticket/1, ...
null
https://raw.githubusercontent.com/silviucpp/erltls/da527e75a5792ecfa9379d499628e0c2fe611f52/src/erltls_options.erl
erlang
options available in both ssl and erltls options available only in erltls todo: implement the following options:
-module(erltls_options). -include("erltls.hrl"). -export([ get_inet_names/1, get_inet_options/1, get_options/1, emulated_for_socket/1, default_inet_options/0, emulated_list2record/1, emulated_list2record/2, emulated_record2list/1, emulated_by_names/2, use_session_ticket/1, ...
41340c210596162549344d1fe5824156d76e99170626d1e3aa5153f17cbf4be2
TheLortex/mirage-monorepo
migrate_412_411.ml
open Stdlib0 module From = Ast_412 module To = Ast_411 let rec copy_toplevel_phrase : Ast_412.Parsetree.toplevel_phrase -> Ast_411.Parsetree.toplevel_phrase = function | Ast_412.Parsetree.Ptop_def x0 -> Ast_411.Parsetree.Ptop_def (copy_structure x0) | Ast_412.Parsetree.Ptop_dir x0 -> Ast_411.Pars...
null
https://raw.githubusercontent.com/TheLortex/mirage-monorepo/b557005dfe5a51fc50f0597d82c450291cfe8a2a/duniverse/ppxlib/astlib/migrate_412_411.ml
ocaml
open Stdlib0 module From = Ast_412 module To = Ast_411 let rec copy_toplevel_phrase : Ast_412.Parsetree.toplevel_phrase -> Ast_411.Parsetree.toplevel_phrase = function | Ast_412.Parsetree.Ptop_def x0 -> Ast_411.Parsetree.Ptop_def (copy_structure x0) | Ast_412.Parsetree.Ptop_dir x0 -> Ast_411.Pars...
24743c0f2cf510a4c7c51355c4e2b1e1dc8f2fe132b64f3a3f2fa9e75878b43a
renanroberto/whatsyourquestion-bot
Question.hs
module Question ( Question , isQuestion , question , getQuestion , defaultQuestion , chooseAnswer ) where import Data.Function ((&)) import SafeName (SafeName, getName) questionMarks :: [Char] questionMarks = ['?', '?', '¿', '⸮', '‽', '⸘', ';', '՞', '؟', '፧', '⁇', '⁈', '⁉'] de...
null
https://raw.githubusercontent.com/renanroberto/whatsyourquestion-bot/4443c095e4a36be6fc94baf7886c181e06b030cc/src/Question.hs
haskell
module Question ( Question , isQuestion , question , getQuestion , defaultQuestion , chooseAnswer ) where import Data.Function ((&)) import SafeName (SafeName, getName) questionMarks :: [Char] questionMarks = ['?', '?', '¿', '⸮', '‽', '⸘', ';', '՞', '؟', '፧', '⁇', '⁈', '⁉'] de...
b20c47446a9fa2f0fa85a15b602c98838703a1dd46714b16b66aa436340ada7a
kappelmann/engaging-large-scale-functional-programming
Exercise06.hs
module Exercise06 where data Colour = Gold | RustyBrown | TurtleGreen type Number = Int data Card = Card Colour Number tweedledumTweedledee :: [Either Colour Number] -> Integer tweedledumTweedledee xs = helpTLT xs 0 helpTLT :: [Either Colour Number] -> Integer -> Integer helpTLT [] acc = acc helpTLT ((Left Gold) :...
null
https://raw.githubusercontent.com/kappelmann/engaging-large-scale-functional-programming/8ed2c056fbd611f1531230648497cb5436d489e4/resources/contest/example_data/06/uploads/functional0programators/Exercise06.hs
haskell
module Exercise06 where data Colour = Gold | RustyBrown | TurtleGreen type Number = Int data Card = Card Colour Number tweedledumTweedledee :: [Either Colour Number] -> Integer tweedledumTweedledee xs = helpTLT xs 0 helpTLT :: [Either Colour Number] -> Integer -> Integer helpTLT [] acc = acc helpTLT ((Left Gold) :...
bd0c2d5b3c10df1cb1fb138bd9b475af23f5072216f4061bfe1aa26d1c6745f1
nackjicholson/haskellbook-solutions
area.hs
-- area.hs module Area where area :: Floating t => t -> t area d = pi * (r * r) where r = d / 2
null
https://raw.githubusercontent.com/nackjicholson/haskellbook-solutions/c21bd87773734ba2ae1559553a6a4d10891c61c8/chapter3/area.hs
haskell
area.hs
module Area where area :: Floating t => t -> t area d = pi * (r * r) where r = d / 2
02604372ea05ac839823ed465fc0a9e231cbd92a05077415864f41e6aa16be44
tonsky/advent2018
day13.clj
(ns advent2018.day13 (:require [clojure.string :as str] [clojure.set :as set] [clojure.walk :as walk] [advent2018.core :refer :all]) (:import [clojure.lang ExceptionInfo])) (set! *warn-on-reflection* true) (def input (slurp "inputs/day13")) ; (def input (slurp "inputs/day13_example")) ; (def ...
null
https://raw.githubusercontent.com/tonsky/advent2018/6f8d15bf37a150a288e3447df7766c362f7086e9/src/advent2018/day13.clj
clojure
(def input (slurp "inputs/day13_example")) (def input (slurp "inputs/day13_test")) (def input (slurp "inputs/day13_example2")) clear screen
(ns advent2018.day13 (:require [clojure.string :as str] [clojure.set :as set] [clojure.walk :as walk] [advent2018.core :refer :all]) (:import [clojure.lang ExceptionInfo])) (set! *warn-on-reflection* true) (def input (slurp "inputs/day13")) (def tracks (-> input (str/replace ...
ac712f291131e14485b843169c9574812a510734433f70a1888acd3c7c9b5599
lisp-korea/sicp2014
ex-2-35.scm
ex 2.35 (define (accumulate op initial sequence) (if (null? sequence) initial (op (car sequence) (accumulate op initial (cdr sequence))))) ; fill <??> (define (horner-eval x coefficient-sequence) (accumulate (lambda (this-coeff higher-terms) (+ (* higher-terms x) this-coef...
null
https://raw.githubusercontent.com/lisp-korea/sicp2014/9e60f70cb84ad2ad5987a71aebe1069db288b680/vvalkyrie/2.2/ex-2-35.scm
scheme
fill <??> <??>
ex 2.35 (define (accumulate op initial sequence) (if (null? sequence) initial (op (car sequence) (accumulate op initial (cdr sequence))))) (define (horner-eval x coefficient-sequence) (accumulate (lambda (this-coeff higher-terms) 0 coefficient-sequence)) (horn...
8e2d0117867d77bf33bb7499c0db60a62e6ee909fa847502bdee846e95cf2c50
utdemir/distributed-dataset
Aggr.hs
{-# LANGUAGE RankNTypes #-} # LANGUAGE ScopedTypeVariables # # LANGUAGE StaticPointers # # LANGUAGE TypeApplications # module Control.Distributed.Dataset.Aggr ( Aggr, aggrConst, aggrCount, aggrSum, aggrMean, aggrMax, aggrMin, aggrCollect, aggrDistinct, aggrTopK, aggrBottomK, ...
null
https://raw.githubusercontent.com/utdemir/distributed-dataset/a582a96e541884580e66bc5d87b4d498c8d58182/distributed-dataset/src/Control/Distributed/Dataset/Aggr.hs
haskell
# LANGUAGE RankNTypes # | Returns the sum of the inputs. | Returns the number of inputs. | Calculates the mean of the inputs. | Return the maximum of the inputs. | Return the minimum of the inputs. | discarding others. | Collects the inputs as a list. Warning: Ordering of the resulting list is non-determ...
# LANGUAGE ScopedTypeVariables # # LANGUAGE StaticPointers # # LANGUAGE TypeApplications # module Control.Distributed.Dataset.Aggr ( Aggr, aggrConst, aggrCount, aggrSum, aggrMean, aggrMax, aggrMin, aggrCollect, aggrDistinct, aggrTopK, aggrBottomK, aggrFiltered, * Creati...
e83863b61672d4f6a9da383bef536e670e49ab043d482511661aab2a3d53f6aa
ekmett/free
Church.hs
{-# LANGUAGE BangPatterns #-} {-# LANGUAGE Rank2Types #-} # LANGUAGE FlexibleInstances # # LANGUAGE UndecidableInstances # # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE Safe #-} ----------------------------------------------------------------------------- -- | Module : Control . . Free . Church Copyrigh...
null
https://raw.githubusercontent.com/ekmett/free/29b5d2c2811f74f6566835b5cfbdc7f745e57557/src/Control/Monad/Free/Church.hs
haskell
# LANGUAGE BangPatterns # # LANGUAGE Rank2Types # # LANGUAGE Safe # --------------------------------------------------------------------------- | License : BSD-style (see the file LICENSE) Stability : provisional Portability : non-portable (rank-2 polymorphism) The most straightforward way of implement...
# LANGUAGE FlexibleInstances # # LANGUAGE UndecidableInstances # # LANGUAGE MultiParamTypeClasses # Module : Control . . Free . Church Copyright : ( C ) 2011 - 2015 Maintainer : < > \"Free Monads for Less\ " the old ones are garbage collected . Even if the runtime On the other hand ...
6f1a526e1824e7b48d5302772b79c33b992d06856776a05b9fe8909c153a16c2
richhickey/clojure-contrib
examples.clj
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; ;; Accumulator application examples ;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;...
null
https://raw.githubusercontent.com/richhickey/clojure-contrib/40b960bba41ba02811ef0e2c632d721eb199649f/src/examples/clojure/clojure/contrib/accumulators/examples.clj
clojure
Accumulator application examples Queue accumulator Counter accumulator Counter-with-total accumulator Sum accumulator: combine is addition Product accumulator: combine is multiplication Minimum accumulator: combine is min Mean-variance accumulator: sample mean and sample variance String accumulator: comb...
(ns #^{:author "Konrad Hinsen" :skip-wiki true :doc "Examples for using accumulators"} clojure.contrib.accumulators.examples (:use [clojure.contrib.accumulators :only (combine add add-items empty-vector empty-list empty-queue empty-set empty-map empty-counter empty-counter-with-total empty-sum ...
5367dfa82943e45b79eaad79f945e5dc77e0915bcd30ceec93ffb9568533fd94
racket/eopl
equal-up-to-gensyms.rkt
#lang eopl (provide equal-types?) (define equal-types? (lambda (ty1 ty2) (equal-up-to-gensyms? ty1 ty2))) ;; S-exp = Sym | Listof(S-exp) A - list = Listof(Pair(TvarTypeSym , TvarTypesym ) ) ;; a tvar-type-sym is a symbol ending with a digit. ;; equal-up-to-gensyms? : S-exp * S-exp -> Bool Page : 271 (defi...
null
https://raw.githubusercontent.com/racket/eopl/43575d6e95dc34ca6e49b305180f696565e16e0f/tests/chapter7/inferred/equal-up-to-gensyms.rkt
racket
S-exp = Sym | Listof(S-exp) a tvar-type-sym is a symbol ending with a digit. equal-up-to-gensyms? : S-exp * S-exp -> Bool canonicalize : S-exp -> A-list loop : sexp * alist -> alist sexp is already bound, no more to do the length of the table serves as a counter! tvar-type-sym? : Sym -> Bool symbol->list : S...
#lang eopl (provide equal-types?) (define equal-types? (lambda (ty1 ty2) (equal-up-to-gensyms? ty1 ty2))) A - list = Listof(Pair(TvarTypeSym , TvarTypesym ) ) Page : 271 (define equal-up-to-gensyms? (lambda (sexp1 sexp2) (equal? (apply-subst-to-sexp (canonical-subst sexp1) sexp1) (apply-su...
f68557a59a5ff092980c2a5dbd68fd37cd19bc84cafdb99d8de6c0fdb839357a
akazukin5151/kpxhs
Fork.hs
-- | Functions that run a shell command in the background ("Fork") -- (After trying the cache first) -- The output of the shell command will be handled later, asynchronously , by functions in ViewEvents . BrowserEvents . Event {-# LANGUAGE OverloadedStrings #-} module ViewEvents.BrowserEvents.Fork (handleEnter) wher...
null
https://raw.githubusercontent.com/akazukin5151/kpxhs/1103014d46eb99463c0110b463d655ced23c0089/src/kpxhs/ViewEvents/BrowserEvents/Fork.hs
haskell
| Functions that run a shell command in the background ("Fork") (After trying the cache first) The output of the shell command will be handled later, # LANGUAGE OverloadedStrings #
asynchronously , by functions in ViewEvents . BrowserEvents . Event module ViewEvents.BrowserEvents.Fork (handleEnter) where import Brick.BChan (writeBChan) import qualified Brick.Types as T import Brick.Widgets.Core (str, txt) import Control.Concurrent (forkIO) import ...
3fd8209c3bd0d1bf37027770162c8be51ac823efb8a2da48a95d6a91a24127b0
NetworkVerification/nv
SrpRemapping.ml
open Batteries open Nv_datastructures.AdjGraph open Nv_lang open Nv_lang.Syntax open Nv_datastructures open Nv_utils.OCamlUtils (* A record for managing the input node information *) type input_exp = { (* the associated original edge *) edge : E.t ; (* the variables associated with the input node *) var_na...
null
https://raw.githubusercontent.com/NetworkVerification/nv/31a72ff3f7bce3d6cb7f5f97f0df20bd3d729ea1/src/lib/kirigami/SrpRemapping.ml
ocaml
A record for managing the input node information the associated original edge the variables associated with the input node the partition rank of the associated output the associated predicate expressions: functions over attributes the rank of the fragment the nodes in the network the edges in the network...
open Batteries open Nv_datastructures.AdjGraph open Nv_lang open Nv_lang.Syntax open Nv_datastructures open Nv_utils.OCamlUtils type input_exp = edge : E.t var_names : Var.t list rank : int preds : exp list } the symbolic variable will have the form hyp_delim ^ ^ [ edge ] ^ hyp_delim let hyp_pref...
c9d86423f16dcf9d40b67e2399d160944d5890f197096bf647f617bdf893cc9d
fulcro-legacy/fulcro-lein-template
root.cljs
(ns {{name}}.ui.root (:require [fulcro.client.dom :as dom :refer [div ul li p h3]] [fulcro.client.primitives :as prim :refer [defsc]] [{{name}}.model.user :as user] [{{name}}.ui.components :as comp] [taoensso.timbre :as log])) (defsc User [this {:user/keys [name] :address/ke...
null
https://raw.githubusercontent.com/fulcro-legacy/fulcro-lein-template/41195fc3b5e4054ee8b0cfff379bbadb006be046/resources/leiningen/new/fulcro/src/main/app/ui/root.cljs
clojure
NOTE: The lack of quoting works because we're using declare-mutation from incubator. see model.cljs returns the user. This allows the server to tack on an address without us specifying it, and also have the local database/ui update with it.
(ns {{name}}.ui.root (:require [fulcro.client.dom :as dom :refer [div ul li p h3]] [fulcro.client.primitives :as prim :refer [defsc]] [{{name}}.model.user :as user] [{{name}}.ui.components :as comp] [taoensso.timbre :as log])) (defsc User [this {:user/keys [name] :address/ke...
36d7ff2c9923731b9f8e945e0b7017882448a9494b130a7f06a43e87eb36425a
travelping/ppp
ppp_hdlc.erl
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(ppp_hdlc). -export([decapsulate/1, encapsulate/1, crc16/1]). decapsulate(Data) -> decapsulate_frames(binary:split(Data, <<16#7e>>...
null
https://raw.githubusercontent.com/travelping/ppp/c1e03ee93ef333b5eb8aadd14b1290cfc1001089/src/ppp_hdlc.erl
erlang
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(ppp_hdlc). -export([decapsulate/1, encapsulate/1, crc16/1]). decapsulate(Data) -> decapsulate_frames(binary:split(Data, <<16#7e>>...
1ba335cdb244fa70b272a598e9803ec3e763ed46061da247421f74f160235910
mbj/stratosphere
ModelQualityJobDefinition.hs
module Stratosphere.SageMaker.ModelQualityJobDefinition ( module Exports, ModelQualityJobDefinition(..), mkModelQualityJobDefinition ) where import qualified Data.Aeson as JSON import qualified Stratosphere.Prelude as Prelude import Stratosphere.Property import {-# SOURCE #-} Stratosphere.SageMaker....
null
https://raw.githubusercontent.com/mbj/stratosphere/c70f301715425247efcda29af4f3fcf7ec04aa2f/services/sagemaker/gen/Stratosphere/SageMaker/ModelQualityJobDefinition.hs
haskell
# SOURCE # # SOURCE # # SOURCE # # SOURCE # # SOURCE # # SOURCE # # SOURCE #
module Stratosphere.SageMaker.ModelQualityJobDefinition ( module Exports, ModelQualityJobDefinition(..), mkModelQualityJobDefinition ) where import qualified Data.Aeson as JSON import qualified Stratosphere.Prelude as Prelude import Stratosphere.Property import Stratosphere.ResourceProperties import...
d80a6d583daad0df07080d00bcccd1b7cc376a023143110504cb8771a8320213
nomasystems/nmaglev
nmaglev.erl
Copyright 2022 Nomasystems , S.L. %% Licensed under the Apache License , Version 2.0 ( the " License " ) ; %% you may not use this file except in compliance with the License. %% You may obtain a copy of the License at %% %% -2.0 %% %% Unless required by applicable law or agreed to in writing, software distri...
null
https://raw.githubusercontent.com/nomasystems/nmaglev/bb86e31952e1d8f904a253c73b32e99c7f3a1114/src/nmaglev.erl
erlang
you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing perm...
Copyright 2022 Nomasystems , S.L. Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(nmaglev). -export([create/1, create/2, get/2]). -define(DEFAULT_LOOKUP_SIZE, 65537). TYPES -type maglev_table() :: term(). -...
3123d7fb615659fefce980ad0da78aaeeec8145e95dc9516a9f28dafd5070219
theronic/datascript-fulltext
project.clj
(defproject datascript-fulltext "0.1" :description "Fulltext Index Search Adapter for DataScript in ClojureScript" :url "-fulltext" :license {:name "EPL-2.0 OR GPL-2.0-or-later WITH Classpath-exception-2.0" :url "-2.0/"} :dependencies [[org.clojure/clojure "1.10.1"] [org.clojure/clojurescript "...
null
https://raw.githubusercontent.com/theronic/datascript-fulltext/e1dce5f9ed951b19f41725b99d4facf1ac7503af/project.clj
clojure
(defproject datascript-fulltext "0.1" :description "Fulltext Index Search Adapter for DataScript in ClojureScript" :url "-fulltext" :license {:name "EPL-2.0 OR GPL-2.0-or-later WITH Classpath-exception-2.0" :url "-2.0/"} :dependencies [[org.clojure/clojure "1.10.1"] [org.clojure/clojurescript "...
285a937728bd02203aa95c7f0324a5d648c85649c138d63a9e2259a05ce90cef
aziem/binaryninja-ocaml
iterfuncnames.ml
open Binaryninja let write_breakpoint bn_view = let functions = BinaryView.functions bn_view in List.iter (fun f -> Log.log_info (Printf.sprintf "Function name: %s\n" (Function.get_name f))) functions let is_valid = fun _ -> true module IterFunctionsPlugin: Plugin.BinaryNinjaPlugin = struct let name = "Iter F...
null
https://raw.githubusercontent.com/aziem/binaryninja-ocaml/5773d791ebb717816b8c47863bce8122f39764b4/examples/iterfuncnames/iterfuncnames.ml
ocaml
open Binaryninja let write_breakpoint bn_view = let functions = BinaryView.functions bn_view in List.iter (fun f -> Log.log_info (Printf.sprintf "Function name: %s\n" (Function.get_name f))) functions let is_valid = fun _ -> true module IterFunctionsPlugin: Plugin.BinaryNinjaPlugin = struct let name = "Iter F...
c6f7ccd97b8c8b6b5d64b9f48ab8fd51ce442608ec16cb0299a59362c06da807
minad/writer-cps-transformers
Internal.hs
# LANGUAGE CPP # #if __GLASGOW_HASKELL__ >= 702 {-# LANGUAGE Safe #-} #endif #if __GLASGOW_HASKELL__ >= 710 # LANGUAGE AutoDeriveTypeable # #endif ----------------------------------------------------------------------------- -- | Module : Control . . Trans . Writer . CPS.Internal Copyright : ( c ) 2...
null
https://raw.githubusercontent.com/minad/writer-cps-transformers/07e5b1b01da643baaceef341466e8c122cd980c3/src/Control/Monad/Trans/Writer/CPS/Internal.hs
haskell
# LANGUAGE Safe # --------------------------------------------------------------------------- | License : BSD-style (see the file LICENSE) Maintainer : Stability : experimental Portability : portable The strict 'WriterT' monad transformer, which adds collection of outputs (such as a count or string...
# LANGUAGE CPP # #if __GLASGOW_HASKELL__ >= 702 #endif #if __GLASGOW_HASKELL__ >= 710 # LANGUAGE AutoDeriveTypeable # #endif Module : Control . . Trans . Writer . CPS.Internal Copyright : ( c ) 2016 , ( c ) 2001 , ( c ) Oregon Graduate Institute of Science and Tec...
ff8250c7d45347a5a184d38b43db80bec58f3725cf4557a564d70996da529967
Decentralized-Pictures/T4L3NT
init_storage.ml
(*****************************************************************************) (* *) (* Open Source License *) Copyright ( c ) 2018 Dynamic Ledger Solutions , Inc. < > Copyright ( c...
null
https://raw.githubusercontent.com/Decentralized-Pictures/T4L3NT/6d4d3edb2d73575384282ad5a633518cba3d29e3/src/proto_012_Psithaca/lib_protocol/init_storage.ml
ocaml
*************************************************************************** Open Source License Permission is h...
Copyright ( c ) 2018 Dynamic Ledger Solutions , Inc. < > Copyright ( c ) 2019 - 2020 Nomadic Labs < > Copyright ( c ) 2021 DaiLambda , Inc. < > to deal in the Software without restriction , including without limitation and/or sell copies of the Software , and to permit pers...
6976e289d07c202481002d2e3f0a10072d1592eb4a4c010f1766b5efdfaa3a9a
may-liu/qtalk
subscription.erl
-module(subscription). -include("ejabberd.hrl"). -include("logger.hrl"). -include("jlib.hrl"). -export([subscription_message/3,create_rbt_ets/0,get_subscription_url/2,update_subscription_info/1]). -export([update_user_robots/1,get_subscription_cn_name/1]). -record(rbt_info,{name,cn_name,url,body,version}). -record(u...
null
https://raw.githubusercontent.com/may-liu/qtalk/f5431e5a7123975e9656e7ab239e674ce33713cd/qtalk_opensource/src/subscription.erl
erlang
case catch xml:get_tag_attr_s(<<"id">>,xml:get_subtag(El,<<"body">>)) of
-module(subscription). -include("ejabberd.hrl"). -include("logger.hrl"). -include("jlib.hrl"). -export([subscription_message/3,create_rbt_ets/0,get_subscription_url/2,update_subscription_info/1]). -export([update_user_robots/1,get_subscription_cn_name/1]). -record(rbt_info,{name,cn_name,url,body,version}). -record(u...
786337a17feaed7a8c7ad8cdf35f3a1d4dcdbf5b04bc489716b37385322e155e
input-output-hk/ouroboros-network
Validated.hs
{-# LANGUAGE DeriveFunctor #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE PatternSynonyms #-} {-# LANGUAGE RecordWildCards #-} # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeApplications # # LANGUAGE TypeFamilies # -- | Intended for qualified import -- > import Ouroboros . Consensus...
null
https://raw.githubusercontent.com/input-output-hk/ouroboros-network/358880057f1d6d86cc385e8475813ace3b9ebef6/ouroboros-consensus/src/Ouroboros/Consensus/Fragment/Validated.hs
haskell
# LANGUAGE DeriveFunctor # # LANGUAGE FlexibleContexts # # LANGUAGE PatternSynonyms # # LANGUAGE RecordWildCards # | Intended for qualified import | Validated chain fragment along with the ledger state after validation | Chain fragment | Ledger after after validation | Constructor for 'Validate...
# LANGUAGE ScopedTypeVariables # # LANGUAGE TypeApplications # # LANGUAGE TypeFamilies # > import Ouroboros . Consensus . Fragment . Validated ( ValidatedFragment ) > import qualified Ouroboros . Consensus . Fragment . Validated as VF module Ouroboros.Consensus.Fragment.Validated ( ValidatedFragmen...
021e9ca4279d2e4314b54ed6b1a47b48e283f49d616751a6bb9412827163da6a
gebi/jungerl
erl_tidy.erl
%% ===================================================================== Tidies Erlang source code , removing unused functions , updating %% obsolete constructs and function calls, etc. %% Copyright ( C ) 1999 - 2002 %% %% This library is free software; you can redistribute it and/or %% modify it under the terms ...
null
https://raw.githubusercontent.com/gebi/jungerl/8f5c102295dbe903f47d79fd64714b7de17026ec/lib/syntax_tools/src/erl_tidy.erl
erlang
===================================================================== obsolete constructs and function calls, etc. This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License This library is distributed in the hope that it will be useful, but ...
Tidies Erlang source code , removing unused functions , updating Copyright ( C ) 1999 - 2002 as published by the Free Software Foundation ; either version 2 of the License , or ( at your option ) any later version . You should have received a copy of the GNU Lesser General Public Foundation , Inc. , 59 Te...
f446face1dc08b9e39b20b4ac9c641dea82c7eed01e3b5e15f95e59cf3e7e581
kuberlog/holon
obs.lisp
(ql:quickload :cepl) (in-package :holon) (defun rename (video name) ;; to be implemented, placeholder list rv `(,video ,name)) (defun ask-for-name () (format t "what should the name be ~%")) (defun record () (let ((video (obs))) (rename video (ask-for-name)))) (defun obs () ;; to be implemented ;; do ...
null
https://raw.githubusercontent.com/kuberlog/holon/6c2ba24e7440c770be7c6e97e21e9d631562b6a7/lisp/obs.lisp
lisp
to be implemented, placeholder list rv to be implemented do something to start obs
(ql:quickload :cepl) (in-package :holon) (defun rename (video name) `(,video ,name)) (defun ask-for-name () (format t "what should the name be ~%")) (defun record () (let ((video (obs))) (rename video (ask-for-name)))) (defun obs () nil)
7e78cad90d54f3054ad896015e9567b38aae0640a4eecd03bc2c0a7707e2d2cf
evdubs/iex-stocks
list-partition.rkt
#lang racket/base (require racket/list) (provide list-partition) (define (list-partition l period step) (if (>= period (length l)) (list l) (append (list (take l period)) (list-partition (drop l step) period step))))
null
https://raw.githubusercontent.com/evdubs/iex-stocks/e1a596b88e9fb87ec3839f3ae9b461a19bc38a1e/list-partition.rkt
racket
#lang racket/base (require racket/list) (provide list-partition) (define (list-partition l period step) (if (>= period (length l)) (list l) (append (list (take l period)) (list-partition (drop l step) period step))))
f84bf1e96577e48daaf0dfc7e922107480487ffe0947318f5b6a159e245afd58
thoughtstem/game-engine
fake-rsound.rkt
#lang racket (provide sound? rsound? sound make-sound-stream play stop-sound-streams) (define (sound? s) #t) (define rsound? sound?) (define (sound path-to-sound) #t) (define (make-sound-stream) #t) (define (play stream sound) (display (~a "Not playing sound: "...
null
https://raw.githubusercontent.com/thoughtstem/game-engine/98c4b9e9b8c071818e564ef7efb55465cff487a8/engine/extensions/sound/fake-rsound.rkt
racket
#lang racket (provide sound? rsound? sound make-sound-stream play stop-sound-streams) (define (sound? s) #t) (define rsound? sound?) (define (sound path-to-sound) #t) (define (make-sound-stream) #t) (define (play stream sound) (display (~a "Not playing sound: "...
09f3bcd721c6163e41ec398959b7944641aafeaec5dbff6f6c8a8ff858bed8b4
alanz/ghc-exactprint
Expr.hs
{-# LANGUAGE DeriveDataTypeable #-} module Expr where import Data.Generics import Language.Haskell.TH as TH import Language.Haskell.TH.Quote import Text . ParserCombinators . Parsec import Text . ParserCombinators . Parsec . data Expr = IntExpr Integer | AntiIntExpr String | BinopExpr ...
null
https://raw.githubusercontent.com/alanz/ghc-exactprint/b6b75027811fa4c336b34122a7a7b1a8df462563/tests/examples/ghc710/Expr.hs
haskell
# LANGUAGE DeriveDataTypeable # between (symbol "(") (symbol ")") p keep parser happy
module Expr where import Data.Generics import Language.Haskell.TH as TH import Language.Haskell.TH.Quote import Text . ParserCombinators . Parsec import Text . ParserCombinators . Parsec . data Expr = IntExpr Integer | AntiIntExpr String | BinopExpr BinOp Expr Expr | AntiEx...
b3ce5f421f77b19f3e5e8f7f3290469184ec38f7fdc946629a960a027f5337ff
senapk/funcional
splitRec.hs
splitAtRec [] pos = ([], 0, []) splitAtRec (x:xs) pos | pos > 0 = (x:antes, elem, depois) | pos == 0 = (antes, x, depois) | otherwise = (antes, elem, x:depois) where (antes, elem, depois) = splitAtRec xs (pos - 1)
null
https://raw.githubusercontent.com/senapk/funcional/83568d2797028efff5933f9d2ef9b215be001368/06_prova/splitRec.hs
haskell
splitAtRec [] pos = ([], 0, []) splitAtRec (x:xs) pos | pos > 0 = (x:antes, elem, depois) | pos == 0 = (antes, x, depois) | otherwise = (antes, elem, x:depois) where (antes, elem, depois) = splitAtRec xs (pos - 1)
fa69e88a9d76e2f14bc9e16495efd10e9429f6e40f7208e72f7fb2372072658b
janestreet/universe
sexp_string.ml
open! Core_kernel open! Import type t = string [@@deriving sexp_of] let does_parse s = Parsexp.Many.parse_string s |> Result.is_ok let quickcheck_generator = Quickcheck.Generator.recursive_union [ [%quickcheck.generator: Atom_string.t] ] ~f:(fun self -> [ (match%bind.Quickcheck.Generator [%quickcheck...
null
https://raw.githubusercontent.com/janestreet/universe/b6cb56fdae83f5d55f9c809f1c2a2b50ea213126/sexp_string_quickcheck/src/sexp_string.ml
ocaml
open! Core_kernel open! Import type t = string [@@deriving sexp_of] let does_parse s = Parsexp.Many.parse_string s |> Result.is_ok let quickcheck_generator = Quickcheck.Generator.recursive_union [ [%quickcheck.generator: Atom_string.t] ] ~f:(fun self -> [ (match%bind.Quickcheck.Generator [%quickcheck...
bf7849dc4c7538ace5a16eae4772e69289bdba60c73a72decd2d4d0d7e9fa8d8
hammerlab/secotrec
make_dockerfiles.ml
open Secotrec open Common let in_dir dir f = let original_dir = Sys.getcwd () in Sys.chdir dir; begin try f (); Sys.chdir original_dir; with e -> Sys.chdir original_dir; raise e end module Dockerfiles = struct let seb_maintains = Dockerfile.maintainer "Sebastien Mondet <>" let bas...
null
https://raw.githubusercontent.com/hammerlab/secotrec/c801a43fdb0feea98da6d3636145f948aed4e7be/src/app/make_dockerfiles.ml
ocaml
Dockerfile_linux.Apt.update; -> does it! run AWS containers need to mount EFS targets by themselves: biokepi user Needed for bcftools Needed for bcftools AWS nodes need to mount EFSs coclobas --version gives: "0.0.2-dev+<commit-hash-prefix>": coclobas --version gives: "0.0.2-dev+<commit-hash-prefix>": ...
open Secotrec open Common let in_dir dir f = let original_dir = Sys.getcwd () in Sys.chdir dir; begin try f (); Sys.chdir original_dir; with e -> Sys.chdir original_dir; raise e end module Dockerfiles = struct let seb_maintains = Dockerfile.maintainer "Sebastien Mondet <>" let bas...
7409651ef173701a43b15d1f68b469631bbe54519562c15298bf73b1279df09c
tek/polysemy-hasql
QueryTest.hs
# options_ghc -Wno - redundant - constraints # module Polysemy.Hasql.Test.QueryTest where import Data.Time (UTCTime) import Data.UUID (UUID) import Hasql.Encoders (Params) import Polysemy.Db.Data.Cond (LessOrEq) import Polysemy.Db.Data.CreationTime (CreationTime (CreationTime)) import Polysemy.Db.Data.DbError (DbErro...
null
https://raw.githubusercontent.com/tek/polysemy-hasql/e1ed71cacf6f329ee1428c3012d582c9eb6cf497/packages/hasql/integration/Polysemy/Hasql/Test/QueryTest.hs
haskell
# options_ghc -Wno - redundant - constraints # module Polysemy.Hasql.Test.QueryTest where import Data.Time (UTCTime) import Data.UUID (UUID) import Hasql.Encoders (Params) import Polysemy.Db.Data.Cond (LessOrEq) import Polysemy.Db.Data.CreationTime (CreationTime (CreationTime)) import Polysemy.Db.Data.DbError (DbErro...
3fbb1f0d62fade01ce2fa802cbc006e89311dd8051f2646a25e0cb36915a4b51
fons/cl-mongo
bson-code.lisp
(in-package :cl-mongo) (defclass bson-code () ((code :reader code :initarg :code))) (defun make-bson-code (js) (make-instance 'bson-code :code js)) (defmethod print-object ((bson-code bson-code) stream) (format stream "~S [~A] ~%" (type-of bson-code) (if (slot-boundp bson-code 'code) (code bso...
null
https://raw.githubusercontent.com/fons/cl-mongo/141518d34fddc9ba42d3813362abae12b368f059/src/bson-code.lisp
lisp
(in-package :cl-mongo) (defclass bson-code () ((code :reader code :initarg :code))) (defun make-bson-code (js) (make-instance 'bson-code :code js)) (defmethod print-object ((bson-code bson-code) stream) (format stream "~S [~A] ~%" (type-of bson-code) (if (slot-boundp bson-code 'code) (code bso...
9c157adbf2cda0492d301cda1747ec168d897ee69e4cfadadcdd23042d7c4710
factisresearch/mq-demo
Main.hs
import Logging import Types import Rules import BuildConfig import Development.Shake hiding (getDirectoryContents) import System.Console.GetOpt import Safe import qualified Data.Map as Map import qualified Data.List as List import Data.Maybe import System.Environment import System.Exit import System.IO import Syst...
null
https://raw.githubusercontent.com/factisresearch/mq-demo/0efa1991ca647a86a8c22e516a7a1fb392ab4596/server/src/build/Main.hs
haskell
The version number of your build rules. Increment the version number to force a complete rebuild, such as when making significant changes to the rules that require a wipe. The version number should be set in the source code, and not passed on the command line.
import Logging import Types import Rules import BuildConfig import Development.Shake hiding (getDirectoryContents) import System.Console.GetOpt import Safe import qualified Data.Map as Map import qualified Data.List as List import Data.Maybe import System.Environment import System.Exit import System.IO import Syst...
bb2d134db56d2e61625e208b6e44eb264b23c919d3faf083fe50d0b1143a8e8d
michalkonecny/aern2
Type.hs
module AERN2.BoxFun.Type where import MixedTypesNumPrelude import AERN2.Linear.Vector.Type (Vector, (!)) import qualified AERN2.Linear.Vector.Type as V import AERN2.MP.Ball import AERN2.AD.Differential import qualified AERN2.Linear.Matrix.Type as M import AERN2.Util.Util import AERN2.BoxFun.Box import Numeric.Collect...
null
https://raw.githubusercontent.com/michalkonecny/aern2/025005773f075280b89d8467b78cd74cb4e40cd5/aern2-mfun/src/AERN2/BoxFun/Type.hs
haskell
diff_dx $ e (tangent k)
module AERN2.BoxFun.Type where import MixedTypesNumPrelude import AERN2.Linear.Vector.Type (Vector, (!)) import qualified AERN2.Linear.Vector.Type as V import AERN2.MP.Ball import AERN2.AD.Differential import qualified AERN2.Linear.Matrix.Type as M import AERN2.Util.Util import AERN2.BoxFun.Box import Numeric.Collect...
d659abf7c1ad4a58064aefa1026c99d356e254cbc5444e277e47b995995076db
philnguyen/soft-contract
fold.rkt
#lang racket/base (require soft-contract/fake-contract) (define (foldr op a xs) (if (null? xs) a (op (car xs) (foldr op a (cdr xs))))) (define (foldl op a xs) (if (null? xs) a (foldl op (op (car xs) a) (cdr xs)))) (define (reverse xs) (foldl (λ (ys x) (cons x ys)) '() xs)) (define (@ xs ys) (foldr cons xs ys)) (defin...
null
https://raw.githubusercontent.com/philnguyen/soft-contract/5e07dc2d622ee80b961f4e8aebd04ce950720239/soft-contract/test/programs/safe/termination/ho-sc/fold.rkt
racket
#lang racket/base (require soft-contract/fake-contract) (define (foldr op a xs) (if (null? xs) a (op (car xs) (foldr op a (cdr xs))))) (define (foldl op a xs) (if (null? xs) a (foldl op (op (car xs) a) (cdr xs)))) (define (reverse xs) (foldl (λ (ys x) (cons x ys)) '() xs)) (define (@ xs ys) (foldr cons xs ys)) (defin...
2e8c9283d605815ff05ff0312d02a5a8d88ee448fe9005ac438766d6dd99a48a
michaelballantyne/syntax-spec
peg.rkt
#lang racket/base (require "../../testing.rkt") (begin-for-syntax (define-syntax-class string (pattern val #:when (string? (syntax-e #'val))))) (syntax-spec (binding-class var #:description "PEG variable") (binding-class nonterm #:description "PEG nonterminal") (extension-class peg-macro #:description "P...
null
https://raw.githubusercontent.com/michaelballantyne/syntax-spec/87c308e1ea48a8ca02cc89552d15ecb71704482c/test/dsls/peg.rkt
racket
confusing! Probably shouldn't use pegs as the paper example... can't just be `eps` yet. * ! : right now these are referring to the expr syntax class. Need escape to Racket...
#lang racket/base (require "../../testing.rkt") (begin-for-syntax (define-syntax-class string (pattern val #:when (string? (syntax-e #'val))))) (syntax-spec (binding-class var #:description "PEG variable") (binding-class nonterm #:description "PEG nonterminal") (extension-class peg-macro #:description "P...
0aca8d770384ebd7e1337153fbf4e6e1188ab3e04f62ded20293261c259a1c6b
sondresl/AdventOfCode
Day16State.hs
# LANGUAGE DeriveDataTypeable , StandaloneDeriving , DeriveAnyClass # # LANGUAGE FlexibleInstances , TypeFamilies # module Day16State where import Lib (hexToBin) import Control.Lens (sumOf, makePrisms, Plated, _1, cosmos, (<&>)) import Control.Monad (replicateM, guard) import qualified Text.Parsec as P import Data.Di...
null
https://raw.githubusercontent.com/sondresl/AdventOfCode/ff5a883fc40d9f43f6df36b4912d99d8693c1c6f/2021/Haskell/src/Day16State.hs
haskell
981
# LANGUAGE DeriveDataTypeable , StandaloneDeriving , DeriveAnyClass # # LANGUAGE FlexibleInstances , TypeFamilies # module Day16State where import Lib (hexToBin) import Control.Lens (sumOf, makePrisms, Plated, _1, cosmos, (<&>)) import Control.Monad (replicateM, guard) import qualified Text.Parsec as P import Data.Di...
5790c063ac61a7e79a9bc9e7fe20ad110d01184904afff575751fa0f1954382c
mpickering/apply-refact
Default31.hs
no = do iter <- textBufferGetTextIter tb ; textBufferSelectRange tb iter iter
null
https://raw.githubusercontent.com/mpickering/apply-refact/a4343ea0f4f9d8c2e16d6b16b9068f321ba4f272/tests/examples/Default31.hs
haskell
no = do iter <- textBufferGetTextIter tb ; textBufferSelectRange tb iter iter
ca60217cecbbfe80862b451142e768c227f69f339a941f3ed9fe8cc868db30ac
c-cube/ocaml-containers
CCFQueue.ml
(* This file is free software, part of containers. See file "license" for more details. *) * { 1 Functional queues ( fifo ) } type 'a iter = ('a -> unit) -> unit type 'a equal = 'a -> 'a -> bool type 'a printer = Format.formatter -> 'a -> unit * { 2 Basics } [@@@warning "-37"] type zero = Zero type 'x succ = Succ ...
null
https://raw.githubusercontent.com/c-cube/ocaml-containers/69f2805f1073c4ebd1063bbd58380d17e62f6324/src/data/CCFQueue.ml
ocaml
This file is free software, part of containers. See file "license" for more details. store the size in deep version reversed seq reversed seq
* { 1 Functional queues ( fifo ) } type 'a iter = ('a -> unit) -> unit type 'a equal = 'a -> 'a -> bool type 'a printer = Format.formatter -> 'a -> unit * { 2 Basics } [@@@warning "-37"] type zero = Zero type 'x succ = Succ type one = zero succ type two = zero succ succ type three = zero succ succ succ type (+'a,...
63eddb79f6404ae5988fe06c663a1b8dd70a84f4ed7dc51a1f3ba0c41865ecdc
OCamlPro/liquidity
liquidEmit.ml
(****************************************************************************) (* Liquidity *) (* *) Copyright ( C ) 2017 - 2020 OCamlPro SAS (* ...
null
https://raw.githubusercontent.com/OCamlPro/liquidity/3578de34cf751f54b9e4c001a95625d2041b2962/tools/liquidity/liquidEmit.ml
ocaml
************************************************************************** Liquidity ...
Copyright ( C ) 2017 - 2020 OCamlPro SAS it under the terms of the GNU General Public License as published by ...
01523906264ca9f23b3b148102601204112d11b50ed733712dfadb8dcab0bfb6
lpeterse/haskell-utc
Type.hs
module Data.UTC.Type ( module Data.UTC.Type.Date , module Data.UTC.Type.Time , module Data.UTC.Type.DateTime , module Data.UTC.Type.Local , module Data.UTC.Type.Exception ) where import Data.UTC.Type.Date import Data.UTC.Type.Time import Data.UTC.Type.DateTime import Data.UTC.Type.Local import Data.UTC.Ty...
null
https://raw.githubusercontent.com/lpeterse/haskell-utc/e4502c08591e80d411129bb7c0414539f6302aaf/Data/UTC/Type.hs
haskell
module Data.UTC.Type ( module Data.UTC.Type.Date , module Data.UTC.Type.Time , module Data.UTC.Type.DateTime , module Data.UTC.Type.Local , module Data.UTC.Type.Exception ) where import Data.UTC.Type.Date import Data.UTC.Type.Time import Data.UTC.Type.DateTime import Data.UTC.Type.Local import Data.UTC.Ty...
9f2fca4f2af593a2198f349e88c37859f5a17cbeb3b57e2da3310090406d929b
tallaproject/talla
talla_core_bandwidth.erl
%%% Copyright ( c ) 2016 The Talla Authors . All rights reserved . %%% Use of this source code is governed by a BSD-style %%% license that can be found in the LICENSE file. %%% %%% ---------------------------------------------------------------------------- @author < > %%% @doc Bandwidth statistics. %%% @end %%%...
null
https://raw.githubusercontent.com/tallaproject/talla/72cfbd8f48705a7a390cac2b8310ab7550c21c15/apps/talla_core/src/talla_core_bandwidth.erl
erlang
Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. ---------------------------------------------------------------------------- @doc Bandwidth statistics. @end ---------------------------------------------------------------------------- API. How long is a period?...
Copyright ( c ) 2016 The Talla Authors . All rights reserved . @author < > -module(talla_core_bandwidth). -export([start_link/0, bytes_read/1, bytes_written/1, current_bandwidth/0 ]). Generic Server Callbacks . -export([init/1, handle_call/3, handle_cast...
5cb6f9ed022978d49071978687cbb5282ca251a1b3ad31e4111d9c7ef7d4ccfe
cornell-netlab/yates
Yates_Fabric.mli
open Core open Frenetic_kernel.OpenFlow0x01 open Yates_types.Types val create : topology -> (switchId, flowMod list) Hashtbl.t * (edge, int) Hashtbl.t
null
https://raw.githubusercontent.com/cornell-netlab/yates/fc30922933fae3184923f7b138d24454a9537536/lib/controller/Yates_Fabric.mli
ocaml
open Core open Frenetic_kernel.OpenFlow0x01 open Yates_types.Types val create : topology -> (switchId, flowMod list) Hashtbl.t * (edge, int) Hashtbl.t
6467bb9bc546b9b90c14cea2c3461da61328a294dae3ca6b973da80f0f177178
mikewin/cspbox-trading
spec.clj
(ns cspbox.trading.ind.spec (:require [cspbox.trading.ind.roll-ind :refer [make-roll-indicator make-lookback-indicator]] [cspbox.runtime.store.buf.roll :refer [make-lookback-buffer]] [cspbox.trading.ind.base :refer [p-max p-min avg make-ema-ind]] [cspbox.runtime.sys.utils.macro :re...
null
https://raw.githubusercontent.com/mikewin/cspbox-trading/76f9cfb780d5f36e5fbd6d8cec7c978a0e51cb94/src/cspbox/trading/ind/spec.clj
clojure
reverse or not? optimize start-factor update indicator h l o c
(ns cspbox.trading.ind.spec (:require [cspbox.trading.ind.roll-ind :refer [make-roll-indicator make-lookback-indicator]] [cspbox.runtime.store.buf.roll :refer [make-lookback-buffer]] [cspbox.trading.ind.base :refer [p-max p-min avg make-ema-ind]] [cspbox.runtime.sys.utils.macro :re...
17b8e215ab079aa1d50a87dbb48dac2dfcb1ae3a9c76b216a205c65076acb034
babashka/nbb
error.cljs
(ns error) (def x {}) (assoc :x :y 1)
null
https://raw.githubusercontent.com/babashka/nbb/4d06aa142a5fb5baac48a8ad8e611d672f779b5f/test-scripts/error.cljs
clojure
(ns error) (def x {}) (assoc :x :y 1)
e750c899a18d812a9e4ee63c3e0d659d2a0a3c06d7799465e9b01fa004731ed1
iamFIREcracker/adventofcode
day13.lisp
(defpackage :aoc/2017/13 #.cl-user::*aoc-use*) (in-package :aoc/2017/13) (defstruct layer depth range curr dir) (defun parse-layers (x) (flet ((parse-layer (s) (let* ((splits (split-sequence:split-sequence #\Space s)) (depth (parse-integer (first splits) :junk-allowed T)) ...
null
https://raw.githubusercontent.com/iamFIREcracker/adventofcode/c395df5e15657f0b9be6ec555e68dc777b0eb7ab/src/2017/day13.lisp
lisp
(defpackage :aoc/2017/13 #.cl-user::*aoc-use*) (in-package :aoc/2017/13) (defstruct layer depth range curr dir) (defun parse-layers (x) (flet ((parse-layer (s) (let* ((splits (split-sequence:split-sequence #\Space s)) (depth (parse-integer (first splits) :junk-allowed T)) ...
8a87f3e2ae9319d49e687c920c3c4afe219f3b43748a4a2cf4745626324cf85c
tmattio/js-bindings
es2017_sharedmemory.mli
[@@@ocaml.warning "-7-11-32-33-39"] [@@@js.implem [@@@ocaml.warning "-7-11-32-33-39"]] open Es2016 module SharedArrayBuffer : sig type t val t_to_js : t -> Ojs.t val t_of_js : Ojs.t -> t val get_byte_length : t -> int [@@js.get "byteLength"] val slice : t -> begin_:int -> ?end_:int -> unit -> t [@@js.c...
null
https://raw.githubusercontent.com/tmattio/js-bindings/f1d36bba378e4ecd5310542a0244dce9258b6496/lib/es2017/es2017_sharedmemory.mli
ocaml
[@@@ocaml.warning "-7-11-32-33-39"] [@@@js.implem [@@@ocaml.warning "-7-11-32-33-39"]] open Es2016 module SharedArrayBuffer : sig type t val t_to_js : t -> Ojs.t val t_of_js : Ojs.t -> t val get_byte_length : t -> int [@@js.get "byteLength"] val slice : t -> begin_:int -> ?end_:int -> unit -> t [@@js.c...
a0033a9b6a918f7b13ea2063a787df2c4e5a05781a074d4940ac09e4cc2a1437
cachix/cachix
NixConf.hs
# LANGUAGE DeriveFunctor # # LANGUAGE GeneralizedNewtypeDeriving # ( Very limited ) parser , rendered and modifier of nix.conf Supports subset of nix.conf given Nix 2.0 or Nix 1.0 When reading config files , it normalizes Nix 1.0/2.0 names to unified naming , then when it writes the config back , it uses nam...
null
https://raw.githubusercontent.com/cachix/cachix/4e5c4973223e2b4606e86b1f99de548b833fcf63/cachix/src/Cachix/Client/NixConf.hs
haskell
| Pure version of addIO TODO: handle comments
# LANGUAGE DeriveFunctor # # LANGUAGE GeneralizedNewtypeDeriving # ( Very limited ) parser , rendered and modifier of nix.conf Supports subset of nix.conf given Nix 2.0 or Nix 1.0 When reading config files , it normalizes Nix 1.0/2.0 names to unified naming , then when it writes the config back , it uses nam...
26d0bbc16444660ef142265063976ce0e9a64445da4e5ac3cdb2cbf12bab6ed5
jasonkuhrt-archive/hpfp-answers
Main.hs
module Main where import Test.QuickCheck import Data.Char import Data.List main :: IO () main = do quickCheck capitalizeWordPropIdempotent quickCheck sortPropIdempotent 1 ~ capitalizeWord is idempotent capitalizeWordPropIdempotent :: Property capitalizeWordPropIdempotent = forAll generator test where ...
null
https://raw.githubusercontent.com/jasonkuhrt-archive/hpfp-answers/c03ae936f208cfa3ca1eb0e720a5527cebe4c034/chapter-14/idempotence/Main.hs
haskell
module Main where import Test.QuickCheck import Data.Char import Data.List main :: IO () main = do quickCheck capitalizeWordPropIdempotent quickCheck sortPropIdempotent 1 ~ capitalizeWord is idempotent capitalizeWordPropIdempotent :: Property capitalizeWordPropIdempotent = forAll generator test where ...
6521fa916efb6a2412511bb01800a49a54838ab65fb1b5b1b9cb94b4dcaf822d
Feldspar/feldspar-language
Twids.hs
module Feldspar.Algorithm.FFT.Twids where import qualified Prelude import Feldspar import Feldspar.Vector twid :: Data Index -> Data Length -> Data Index -> Data (Complex Double) twid scale n k = share (1 / i2f n) $ \d -> cis (i2f scale * 2 * pi * i2f k * d) twids :: Data Length -> Pull1 (Complex Double) twids n = ...
null
https://raw.githubusercontent.com/Feldspar/feldspar-language/499e4e42d462f436a5267ddf0c2f73d5741a8248/src/Feldspar/Algorithm/FFT/Twids.hs
haskell
module Feldspar.Algorithm.FFT.Twids where import qualified Prelude import Feldspar import Feldspar.Vector twid :: Data Index -> Data Length -> Data Index -> Data (Complex Double) twid scale n k = share (1 / i2f n) $ \d -> cis (i2f scale * 2 * pi * i2f k * d) twids :: Data Length -> Pull1 (Complex Double) twids n = ...
2c848ce0aa307f77e343f3f2e6f452db55407da5e23c534d255341e7b5c17413
lispgames/perfectstorm
game.lisp
(in-package :storm) (defclass game () ((terrain :initarg :terrain :initform (error "game without terrain") :reader terrain)))
null
https://raw.githubusercontent.com/lispgames/perfectstorm/a21e0420deb3ec83e9d776241ab37e78c5f29b94/perfectstorm/game.lisp
lisp
(in-package :storm) (defclass game () ((terrain :initarg :terrain :initform (error "game without terrain") :reader terrain)))
b2031511d5859e1cc1ce882281235cb8ac875b74449ccab454bf40185cc059f8
jordwalke/rehp
tyxml_cast_sigs.mli
Js_of_ocaml library * / * Copyright ( C ) 2014 Hugo Heuzard * * This program is free software ; you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation , with linking exception ; * either version 2.1 of the...
null
https://raw.githubusercontent.com/jordwalke/rehp/f122b94f0a3f06410ddba59e3c9c603b33aadabf/lib/tyxml/tyxml_cast_sigs.mli
ocaml
Dom_html.headingElement Dom_html.element
Js_of_ocaml library * / * Copyright ( C ) 2014 Hugo Heuzard * * This program is free software ; you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation , with linking exception ; * either version 2.1 of the...
3a5fded4e4ff49595c9552655d37176f796d93c30ef10fc3de4c95f5848826d5
mtolly/rail
Base.hs
{-# LANGUAGE DeriveDataTypeable #-} -- | The core datatypes for the Rail language. module Language.Rail.Base ( Command(..) , Val(..) , Result(..) , systemVars , Value(..) ) where import Control.Applicative (liftA2) import Data.Char (isSpace) import Data.Data (Data, Typeable) import Data.List (nub) import qualified Da...
null
https://raw.githubusercontent.com/mtolly/rail/0fdd7fc1061d3b5ee18766aff0e71dbba20843b1/src/Language/Rail/Base.hs
haskell
# LANGUAGE DeriveDataTypeable # | The core datatypes for the Rail language. ^ read a var, push to stack ^ pop from stack, store in var ^ function call ^ push a constant value ^ a normal function return ^ pop a string value off the stack, which is an error message ^ the result of a parse error or other static er...
module Language.Rail.Base ( Command(..) , Val(..) , Result(..) , systemVars , Value(..) ) where import Control.Applicative (liftA2) import Data.Char (isSpace) import Data.Data (Data, Typeable) import Data.List (nub) import qualified Data.Map as Map import Data.ControlFlow | An instruction in a Rail program . data...
65f2463be1fa293e354dcc7d296d5cf04c72b7caf2d6fbaf7cf66995a3f6686e
evrim/core-server
addressbook.lisp
;; Address Book Example ;; ------------------------------------ ;; Sample Database Server Demonstration (defpackage :addressbook (:use :cl :core-server :arnesi)) (in-package :addressbook) (defclass+ person () ((fullname :index t) (fields) (ctime :initform (get-universal-time)))) (defcrud person) (defpara...
null
https://raw.githubusercontent.com/evrim/core-server/200ea8151d2f8d81b593d605b183a9cddae1e82d/examples/addressbook.lisp
lisp
Address Book Example ------------------------------------ Sample Database Server Demonstration Test
(defpackage :addressbook (:use :cl :core-server :arnesi)) (in-package :addressbook) (defclass+ person () ((fullname :index t) (fields) (ctime :initform (get-universal-time)))) (defcrud person) (defparameter *addressbook* (make-instance 'database-server :database-directory #P"/tmp/addressbook/" :a...
4e68d59f6f92cac9c56368efab1e8a0ed0e3a7c46631e4469039963f47a85284
graninas/Functional-Design-and-Architecture
Main.hs
module Main where import Control.Concurrent.MVar import Control.Concurrent import Control.Monad import MVarRequestResponsePattern main :: IO () main = do pipe <- createPipe _ <- forkIO (fizzBuzzProcessor pipe) _ <- forkIO (generator pipe 0) pure ()
null
https://raw.githubusercontent.com/graninas/Functional-Design-and-Architecture/b6a78f80a2a2e0b913bcab1d2279fc137a90db4c/Second-Edition-Manning-Publications/BookSamples/CH08/Section8p1p3/src/Main.hs
haskell
module Main where import Control.Concurrent.MVar import Control.Concurrent import Control.Monad import MVarRequestResponsePattern main :: IO () main = do pipe <- createPipe _ <- forkIO (fizzBuzzProcessor pipe) _ <- forkIO (generator pipe 0) pure ()
cbd8eec009db789aa1848bac36548bf74b19700778a89f851816dd15506552fd
gusbicalho/effects-toy
Main.hs
module Main where import qualified Eff.EffectsToy main :: IO () main = Eff.EffectsToy.start
null
https://raw.githubusercontent.com/gusbicalho/effects-toy/e1905ced0f56b13448c1880285f77b957726f50d/toy-eff/app/Main.hs
haskell
module Main where import qualified Eff.EffectsToy main :: IO () main = Eff.EffectsToy.start
697756fe71f0911278e6ec5d660a34a95c767d5ada836ca2306ec4d43d169cf8
juhp/cabal-rpm
Install.hs
# LANGUAGE CPP # -- | -- Module : Commands.Install Copyright : ( C ) 2012 - 2020 -- Maintainer : < > -- Stability : alpha -- Portability : portable -- -- Explanation: installs rpms of package and dependencies -- This program is free software: you can redistribute it and/or modify it unde...
null
https://raw.githubusercontent.com/juhp/cabal-rpm/092e34d6088baa27da457755dd42996be206c91f/src/Commands/Install.hs
haskell
| Module : Commands.Install Stability : alpha Portability : portable Explanation: installs rpms of package and dependencies This program is free software: you can redistribute it and/or modify (at your option) any later version.
# LANGUAGE CPP # Copyright : ( C ) 2012 - 2020 Maintainer : < > it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3 of the License , or module Commands.Install ( install ) where import Commands.RpmBuild (rpmBuild, rpmBuil...
9e86be503d1c8a2ac0df83ef1412aacd10fdeb876bb88e975c84b8e635cfd08c
basho/merge_index
merge_index.erl
%% ------------------------------------------------------------------- %% %% merge_index: main interface to merge_index library. %% Copyright ( c ) 2007 - 2011 Basho Technologies , Inc. All Rights Reserved . %% This file is provided to you under the Apache License , %% Version 2.0 (the "License"); you may not use...
null
https://raw.githubusercontent.com/basho/merge_index/b701dde5c28956c3b629411e5ff7e50cbb5cb4b3/src/merge_index.erl
erlang
------------------------------------------------------------------- merge_index: main interface to merge_index library. Version 2.0 (the "License"); you may not use this file a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, KIND, either express or implied. See the ...
Copyright ( c ) 2007 - 2011 Basho Technologies , Inc. All Rights Reserved . This file is provided to you under the Apache License , except in compliance with the License . You may obtain software distributed under the License is distributed on an " AS IS " BASIS , WITHOUT WARRANTIES OR CONDITIONS OF ANY ...
dfffed38af86bf8ff55dd563c37be8c12772ced791e272f56fbae8afb0819683
yesodweb/persistent
Dummy.hs
module Dummy where
null
https://raw.githubusercontent.com/yesodweb/persistent/bf4c3ae430d7e7ec0351a768783d73e6bd265890/persistent-test/src/Dummy.hs
haskell
module Dummy where
e3f96b67b7a1811e8dfc579734ab1a30e4cced88915fbce91d0dece1c00c045c
zgbjgg/dasherl
dasherl_worker.erl
-module(dasherl_worker). -behaviour(gen_server). %% API -export([start_link/0, stop/0, compile_layout/1, compile_dependency/1]). %% gen_server callbacks -export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). -include("dasherl.hrl"). % the values ...
null
https://raw.githubusercontent.com/zgbjgg/dasherl/78c0345bded3ef263d276774fcb308976056d227/src/dasherl_worker.erl
erlang
API gen_server callbacks the values can be override during initialization start the py process and initializes its importing modules initialize decoder for erl dash components process py pid is down, which one is the process to restart? when finish process just stop py_pid =================================== =...
-module(dasherl_worker). -behaviour(gen_server). -export([start_link/0, stop/0, compile_layout/1, compile_dependency/1]). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). -include("dasherl.hrl"). -record(state, {py_pid = undefined :: pid(),...
d692191c6f4b13a35c47580c16009757b8e0eaab92506eb90ae73d25cf88d8da
ntoronto/drbayes
pre-mapping.rkt
#lang typed/racket/base (require racket/match "set.rkt") (provide (all-defined-out)) ;; =================================================================================================== Preimage mappings (struct: pre-mapping ([range : Set] [fun : (Set -> Set)]) #:transparent) (define pre-range pre-map...
null
https://raw.githubusercontent.com/ntoronto/drbayes/e59eb7c7867118bf4c77ca903e133c7530e612a3/drbayes/direct/racket-impl/pre-mapping.rkt
racket
===================================================================================================
#lang typed/racket/base (require racket/match "set.rkt") (provide (all-defined-out)) Preimage mappings (struct: pre-mapping ([range : Set] [fun : (Set -> Set)]) #:transparent) (define pre-range pre-mapping-range) (define empty-pre-mapping (pre-mapping empty-set (λ (_) empty-set))) (: pre-ap (pre-map...
cfb256d7d90899f71b663e27cf5956335b4d8c72fcbae9b9a8fdc6b84ed1f682
WhatsApp/erlfmt
pragma.erl
% @format -module(pragma).
null
https://raw.githubusercontent.com/WhatsApp/erlfmt/8efa327491aef58f149c032b24588e211975862d/test/erlfmt_cli_SUITE_data/pragma.erl
erlang
@format
-module(pragma).
f2e5574d98e97858dfebd932c7f1e8680e1e5cf03f6a3296d89e892dadc589da
binaryage/chromex
feedback_private.clj
(ns chromex.app.feedback-private "Use the chrome.feedbackPrivate API to provide Chrome [OS] feedback to the Google Feedback servers. * available since Chrome 36" (:refer-clojure :only [defmacro defn apply declare meta let partial]) (:require [chromex.wrapgen :refer [gen-wrap-helper]] [chrome...
null
https://raw.githubusercontent.com/binaryage/chromex/33834ba5dd4f4238a3c51f99caa0416f30c308c5/src/apps_private/chromex/app/feedback_private.clj
clojure
-- events ----------------------------------------------------------------------------------------------------------------- docs: /#tapping-events -- convenience ------------------------------------------------------------------------------------------------------------ --------------------------------------------...
(ns chromex.app.feedback-private "Use the chrome.feedbackPrivate API to provide Chrome [OS] feedback to the Google Feedback servers. * available since Chrome 36" (:refer-clojure :only [defmacro defn apply declare meta let partial]) (:require [chromex.wrapgen :refer [gen-wrap-helper]] [chrome...
f4c517c7248348bba1925d22c12e61f7299bfa3a78b55ec0aabe464ae6a8adc1
juspay/atlas
FarePolicy.hs
| Copyright 2022 Juspay Technologies Pvt Ltd Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not use this file except in compliance with the License . You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing , software dis...
null
https://raw.githubusercontent.com/juspay/atlas/e64b227dc17887fb01c2554db21c08284d18a806/app/atlas-transport/src/Storage/Queries/FarePolicy.hs
haskell
| Copyright 2022 Juspay Technologies Pvt Ltd Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not use this file except in compliance with the License . You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing , software dis...
dc3ffe1860ff89788d385e213933daa65aff0f3abd5cb1af0838dd2190bbb0f0
rtoy/ansi-cl-tests
notes.lsp
;-*- Mode: Lisp -*- Author : Created : Mon Jun 30 21:43:23 2003 Contains : Notes concerning various parts of the ANSI spec . (in-package :cl-test) (defnote :allow-nil-arrays "Allow specialized arrays of type (array nil).") (defnote :allow-nonzero-nil-vectors "Allow specialized vectors of type (v...
null
https://raw.githubusercontent.com/rtoy/ansi-cl-tests/9708f3977220c46def29f43bb237e97d62033c1d/notes.lsp
lisp
-*- Mode: Lisp -*-
Author : Created : Mon Jun 30 21:43:23 2003 Contains : Notes concerning various parts of the ANSI spec . (in-package :cl-test) (defnote :allow-nil-arrays "Allow specialized arrays of type (array nil).") (defnote :allow-nonzero-nil-vectors "Allow specialized vectors of type (vector nil) of nonzero si...
69cfdb6cd0e4e0e71ea317b84200ebe27a94a97e8ce2b4631178d410f88b7937
trifork/deltazip-erlang
deltazip_cli.erl
-module(deltazip_cli). -export([main/1]). -export([interpret_command/1]). main(L) -> put(exit_code, 0), Before = now(), interpret_command(L), After = now(), io:format(standard_error, "(Duration: ~.3fs)\n", [timer:now_diff(After, Before) * 1.0e-6]), init:stop(get(exit_code)). interpret_command...
null
https://raw.githubusercontent.com/trifork/deltazip-erlang/e6db37316f00b0f62392fcbbdf49f02c642e36ad/src/deltazip_cli.erl
erlang
====================================================================== ---------- ---------- Write the new tail: ---------- Get version Nr counted from the most recent. TODO: Is non-ascii data handled correctly? ---------- ---------- ---------- ---------- =============================================================...
-module(deltazip_cli). -export([main/1]). -export([interpret_command/1]). main(L) -> put(exit_code, 0), Before = now(), interpret_command(L), After = now(), io:format(standard_error, "(Duration: ~.3fs)\n", [timer:now_diff(After, Before) * 1.0e-6]), init:stop(get(exit_code)). interpret_command...
0373358ea1e2e7a620ffaa9a758e0e6888441f49f864da1aa8b7edef3c54dc4f
xmonad/xmonad-contrib
WindowState.hs
# LANGUAGE ScopedTypeVariables , , FlexibleInstances , MultiParamTypeClasses , FlexibleContexts # FlexibleInstances, MultiParamTypeClasses, FlexibleContexts #-} ----------------------------------------------------------------------------- -- | Module : XMonad . Util . WindowState -- Description : Func...
null
https://raw.githubusercontent.com/xmonad/xmonad-contrib/e0d1f177ea6c620b7612e431ff01b3ca1a62c829/XMonad/Util/WindowState.hs
haskell
--------------------------------------------------------------------------- | Description : Functions for saving per-window data. License : BSD Stability : unstable Portability : unportable Functions for saving per-window data. -------------------------------------------------------------------------...
# LANGUAGE ScopedTypeVariables , , FlexibleInstances , MultiParamTypeClasses , FlexibleContexts # FlexibleInstances, MultiParamTypeClasses, FlexibleContexts #-} Module : XMonad . Util . WindowState Copyright : ( c ) > Maintainer : > get, ...
ce4b97370424a6499c1201208b5012b0727412bce2ab34ff5e9e814f1c912f62
silkapp/rest
User.hs
# LANGUAGE NoImplicitPrelude # module Api.User (resource) where import Prelude.Compat import Control.Concurrent.STM (atomically, modifyTVar, readTVar) import Control.Monad.Error.Class (throwError) import Control.Monad.Reader (ReaderT, asks) import Control.Monad.Trans (liftIO) import Control.Monad.Trans.Except (Except...
null
https://raw.githubusercontent.com/silkapp/rest/f0462fc36709407f236f57064d8e37c77bdf8a79/rest-example/example-api/Api/User.hs
haskell
| User extends the root of the API with a reader containing the ways to identify a user in our URLs. Currently only by the user name. | Defines the /user api end-point. Name of the HTTP path segment. | Convert a User into a representation that is safe to show to the public.
# LANGUAGE NoImplicitPrelude # module Api.User (resource) where import Prelude.Compat import Control.Concurrent.STM (atomically, modifyTVar, readTVar) import Control.Monad.Error.Class (throwError) import Control.Monad.Reader (ReaderT, asks) import Control.Monad.Trans (liftIO) import Control.Monad.Trans.Except (Except...
10f2eee027633e7c7d13eb5d60c088059686c77a4645be6f945049ba91a8d528
padsproj/pads-haskell
TH.hs
# LANGUAGE TemplateHaskell , MagicHash # # OPTIONS_GHC -Wall # {-# OPTIONS_HADDOCK prune #-} | Module : Language . Pads . TH Description : Template Haskell utilities Copyright : ( c ) 2011 < > < > License : MIT Maintainer : < > Stabili...
null
https://raw.githubusercontent.com/padsproj/pads-haskell/8dce6b2b28bf7d98028e67f6faa2be753a6ad691/src/Language/Pads/TH.hs
haskell
# OPTIONS_HADDOCK prune # for tuples encoded as AppT (,) (AppT a b) for tuples encoded as AppT (AppT (,) a) b XXX: need to add location information so can report location of error messages. I think this is the correct represtentation of a line type. I think this is the correct represtentation of a line type. ...
# LANGUAGE TemplateHaskell , MagicHash # # OPTIONS_GHC -Wall # | Module : Language . Pads . TH Description : Template Haskell utilities Copyright : ( c ) 2011 < > < > License : MIT Maintainer : < > Stability : experimental Modu...
77d7f96ce99f73e8a334eb88d8e95ca3ef528de9f4a032a7a9c156e6180728e1
unclebob/AdventOfCode2021
core_spec.clj
(ns day9.core-spec (:require [speclj.core :refer :all] [day9.core :refer :all])) (describe "parsing input" (it "can parse a line" (should= [1 2 3 4 5] (parse-line "12345"))) (it "can parse many lines" (should= [[1 2 3 4] [5 6 7 8]] (parse-input "1234\n5678\n"))) ) (def sample...
null
https://raw.githubusercontent.com/unclebob/AdventOfCode2021/0f1648a98d0550a95c53ed9bc4cf1d478165aefe/day9/spec/day9/core_spec.clj
clojure
(ns day9.core-spec (:require [speclj.core :refer :all] [day9.core :refer :all])) (describe "parsing input" (it "can parse a line" (should= [1 2 3 4 5] (parse-line "12345"))) (it "can parse many lines" (should= [[1 2 3 4] [5 6 7 8]] (parse-input "1234\n5678\n"))) ) (def sample...
a1aa956da24bef506fb0e5cf545dea14572fd762844977f4d74dd4f252d21158
fractalide/fractalide
license.rkt
#lang typed/racket (provide license-template) (define license-template #<<EOM Mozilla Public License, version 2.0 1. Definitions 1.1. "Contributor" means each individual or legal entity that creates, contributes to the creation of, or owns Covered Software. 1.2. "Contributor Version" means the com...
null
https://raw.githubusercontent.com/fractalide/fractalide/9c54ec2615fcc2a1f3363292d4eed2a0fcb9c3a5/pkgs/hyperflow/fractal-management/generic/license.rkt
racket
or or and or or and and (b) describe the
#lang typed/racket (provide license-template) (define license-template #<<EOM Mozilla Public License, version 2.0 1. Definitions 1.1. "Contributor" means each individual or legal entity that creates, contributes to the creation of, or owns Covered Software. 1.2. "Contributor Version" means the com...
b4bfbee31e1fc01ddc43bea39bed4b15b70b361f37fb163aa13d7c44cb6062a9
tezos/tezos-mirror
get_contracts_alpha.ml
(*****************************************************************************) (* *) (* Open Source License *) Copyright ( c ) 2022 Nomadic Labs < > (* ...
null
https://raw.githubusercontent.com/tezos/tezos-mirror/32c9ef7c4ad3c6ec14e16ab3d75e353266925fb1/devtools/get_contracts/get_contracts_alpha.ml
ocaml
*************************************************************************** Open Source License Permission is h...
Copyright ( c ) 2022 Nomadic Labs < > to deal in the Software without restriction , including without limitation and/or sell copies of the Software , and to permit persons to whom the THE SOFTWARE IS PROVIDED " AS IS " , WITHOUT WARRANTY OF ANY KIND , EXPRESS OR LIABILITY , WHETHER IN AN...
6b2acdbe545d986e5419ccd2e0e64af33dbbaf4ce78dd9bae300e39abee222e6
etorreborre/registry
RegistrySpec.hs
# LANGUAGE ScopedTypeVariables # # LANGUAGE TypeApplications # # OPTIONS_GHC -fno - warn - deprecations # # OPTIONS_GHC -fno - warn - incomplete - uni - patterns # # OPTIONS_GHC -fno - warn - missing - signatures # module Test.Data.Registry.Internal.RegistrySpec where import Data.Dynamic import Data.Registry.Internal...
null
https://raw.githubusercontent.com/etorreborre/registry/b92968dc30173a371d26c847c53f9627bd95cca1/test/Test/Data/Registry/Internal/RegistrySpec.hs
haskell
when trying to build a [Int] *
# LANGUAGE ScopedTypeVariables # # LANGUAGE TypeApplications # # OPTIONS_GHC -fno - warn - deprecations # # OPTIONS_GHC -fno - warn - incomplete - uni - patterns # # OPTIONS_GHC -fno - warn - missing - signatures # module Test.Data.Registry.Internal.RegistrySpec where import Data.Dynamic import Data.Registry.Internal...
ab99f1e3348a13d52eb8eefdf3869a94c18a81d5cfb025098728db0b041b78cd
jepsen-io/jepsen
project.clj
(defproject jepsen.zookeeper "0.1.0-SNAPSHOT" :description "A Jepsen test for Zookeeper" :url "" :license {:name "Eclipse Public License" :url "-v10.html"} :main jepsen.zookeeper :dependencies [[org.clojure/clojure "1.10.0"] [jepsen "0.2.6-SNAPSHOT"] [avout "0.5.4...
null
https://raw.githubusercontent.com/jepsen-io/jepsen/d94ee92eb87ca527b5586f81d1878f9475e67613/zookeeper/project.clj
clojure
(defproject jepsen.zookeeper "0.1.0-SNAPSHOT" :description "A Jepsen test for Zookeeper" :url "" :license {:name "Eclipse Public License" :url "-v10.html"} :main jepsen.zookeeper :dependencies [[org.clojure/clojure "1.10.0"] [jepsen "0.2.6-SNAPSHOT"] [avout "0.5.4...
26c318860cd32ae304f68ff2452e709b7f9fe7e6b43fae77cc8da0087c1e5e82
binghe/cl-net-snmp
snmp-walk.lisp
;;;; -*- Mode: Lisp -*- $ Id$ (in-package :snmp) (defgeneric snmp-walk (object vars &key &allow-other-keys) (:documentation "SNMP Walk, only useful for debug")) (defmethod snmp-walk ((host string) (vars list) &key context) (with-open-session (s host) (snmp-walk s vars :context context))) (defun walk-termi...
null
https://raw.githubusercontent.com/binghe/cl-net-snmp/3cf053bce75734097f0d7e2245a53fa0c45f5e05/snmp-walk.lisp
lisp
-*- Mode: Lisp -*-
$ Id$ (in-package :snmp) (defgeneric snmp-walk (object vars &key &allow-other-keys) (:documentation "SNMP Walk, only useful for debug")) (defmethod snmp-walk ((host string) (vars list) &key context) (with-open-session (s host) (snmp-walk s vars :context context))) (defun walk-terminate-p (new-vars current...
3be3c6cb243f10c5c85bac26bb4e43e5121c058c68e8bc812af8651922cc6bc4
OCamlPro/typerex-lldb
callgrindTypes.ml
(**************************************************************************) (* *) (* OCamlPro TypeRex *) (* *) Copyrigh...
null
https://raw.githubusercontent.com/OCamlPro/typerex-lldb/3be12b69f30127bbf8a5dd483a6bfbbd6045ba0e/libs/ocplib-valgrind/callgrindTypes.ml
ocaml
************************************************************************ OCamlPro TypeRex This file is distributed ...
Copyright OCamlPro 2011 - 2016 . All rights reserved . ( GNU Public Licence version 3.0 ) . THE SOFTWARE IS PROVIDED " AS IS " , WITHOUT WARRANTY OF ANY KIND , NONINFRINGEMENT . IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE...
9a17d7cc8e7cdfde7bd2d6b12c1fcd1c378490c77634e1b91a1d88765dcb310b
shamazmazum/easy-audio
package.lisp
Copyright ( c ) 2012 - 2014 , ;; All rights reserved. ;; Redistribution and use in source and binary forms, with or without ;; modification, are permitted provided that the following conditions are met: 1 . Redistributions of source code must retain the above copyright notice , this ;; list of conditions and...
null
https://raw.githubusercontent.com/shamazmazum/easy-audio/4944f4ac12ffbe96f2d6bb7b116deae8203080e8/tests/package.lisp
lisp
All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: list of conditions and the following disclaimer. this list of conditions and the following disclaimer in the documentation and/or other materi...
Copyright ( c ) 2012 - 2014 , 1 . Redistributions of source code must retain the above copyright notice , this 2 . Redistributions in binary form must reproduce the above copyright notice , THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS " AS IS " AND DISCLAIMED . IN NO EVENT SHALL TH...
e7d1bc1b95bdb78136fb3bcb9eec912f4c9232c138674ef90e1d910501379de6
elm-lang/elm-reactor
Build.hs
# OPTIONS_GHC -Wall # module StaticFiles.Build ( compile ) where import qualified Data.ByteString as BS import System.Directory (removeFile) import System.Exit (ExitCode(..), exitFailure) import System.FilePath ((<.>), takeBaseName) import System.IO (hPutStrLn, stderr) import System.Process (readProcessWit...
null
https://raw.githubusercontent.com/elm-lang/elm-reactor/6f15395aa307aaaf287919a326f4ffb31bb5eb4a/src/backend/StaticFiles/Build.hs
haskell
COMPILE TO JS
# OPTIONS_GHC -Wall # module StaticFiles.Build ( compile ) where import qualified Data.ByteString as BS import System.Directory (removeFile) import System.Exit (ExitCode(..), exitFailure) import System.FilePath ((<.>), takeBaseName) import System.IO (hPutStrLn, stderr) import System.Process (readProcessWit...
89162286f912688d0bebed887fff088d6b8c2fb7e2225d61c3171e8e61f73d96
databrary/databrary
DocumentTest.hs
module Solr.DocumentTest where import Data.Aeson import Data . Text import Test.Tasty.HUnit import Model.Id import Model.Metric import Model.Segment import Model.Tag import Solr.Document Session demonstrating how to use Document 's functions unit_Document_examples :: Assertion unit_Document_examples = do met...
null
https://raw.githubusercontent.com/databrary/databrary/685f3c625b960268f5d9b04e3d7c6146bea5afda/test/Solr/DocumentTest.hs
haskell
module Solr.DocumentTest where import Data.Aeson import Data . Text import Test.Tasty.HUnit import Model.Id import Model.Metric import Model.Segment import Model.Tag import Solr.Document Session demonstrating how to use Document 's functions unit_Document_examples :: Assertion unit_Document_examples = do met...
afdc6b22ae5f68795aad56ea6bfba8c5aa761f5d6559e06fa50d0224e6c28509
donaldsonjw/bigloo
stepper_simple.scm
;*=====================================================================*/ ;* .../bigloo/api/phidget/examples/advancedservo_simple.scm */ ;* ------------------------------------------------------------- */ * Author : * / * Creation : Tue Mar 27...
null
https://raw.githubusercontent.com/donaldsonjw/bigloo/a4d06e409d0004e159ce92b9908719510a18aed5/api/phidget/examples/stepper_simple.scm
scheme
*=====================================================================*/ * .../bigloo/api/phidget/examples/advancedservo_simple.scm */ * ------------------------------------------------------------- */ * ------------------------------------------------------------- */ * Spatial simple ...
* Author : * / * Creation : Tue Mar 27 09:08:28 2012 * / * Last change : We d Apr 4 13:07:57 2012 ( serrano ) * / * Copyright : 2012 * / * ( eg . 200 ) in order to ...
0cf0f76ab2c86ce1ff5a1cf1317c9d4c2c9b451b22e2cde4c72c543ad8a15f2c
mhjort/clj-gatling
simulation_util_test.clj
(ns clj-gatling.simulation-util-test (:require [clojure.test :refer :all] [clj-gatling.test-helpers :refer :all] [clojure.test.check.properties :as prop] [clj-containment-matchers.clojure-test :refer :all] [clojure.test.check.clojure-test :refer [defspec]] [...
null
https://raw.githubusercontent.com/mhjort/clj-gatling/7f54a0779d43474463b13e03ae54f7e2eb278659/test/clj_gatling/simulation_util_test.clj
clojure
(ns clj-gatling.simulation-util-test (:require [clojure.test :refer :all] [clj-gatling.test-helpers :refer :all] [clojure.test.check.properties :as prop] [clj-containment-matchers.clojure-test :refer :all] [clojure.test.check.clojure-test :refer [defspec]] [...
969dd252692218ca3825f827be37bfb235577a6345ea0f1401746c3ab12c4f64
Hexstream/cartesian-product-switch
package.lisp
(cl:defpackage #:cartesian-product-switch (:nicknames #:cp-switch) (:use #:cl) (:import-from #:map-bind #:map-bind) (:import-from #:definitions-systems #:define) (:import-from #:trivial-jumptables #:ejumpcase) (:export #:cartesian-product-switch ; import this single symbol for normal usage. #:te...
null
https://raw.githubusercontent.com/Hexstream/cartesian-product-switch/26d590eba02166a7812e0ad5f42589b085cc94c6/package.lisp
lisp
import this single symbol for normal usage.
(cl:defpackage #:cartesian-product-switch (:nicknames #:cp-switch) (:use #:cl) (:import-from #:map-bind #:map-bind) (:import-from #:definitions-systems #:define) (:import-from #:trivial-jumptables #:ejumpcase) #:testclause))
a4acd1a2fc5773808fdd573f85b249a86cfea358e5ca57e3a7d8d00e852c86a3
jcclinton/wow-emulator
movement.erl
This is a World of Warcraft emulator written in erlang , supporting client 1.12.x %% Copyright ( C ) 2014 < jamieclinton.com > %% %% 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 Found...
null
https://raw.githubusercontent.com/jcclinton/wow-emulator/21bc67bfc9eea131c447c67f7f889ba040dcdd79/src/handlers/movement.erl
erlang
This program is free software; you can redistribute it and/or modify (at your option) 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 G...
This is a World of Warcraft emulator written in erlang , supporting client 1.12.x Copyright ( C ) 2014 < jamieclinton.com > it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the License , or You should have received a copy...
c7c26411abd0d432d9c3dd81e85a0864b0fe84d34174f4427f36c67f73bb4ede
andersfugmann/amqp-client
rpc.ml
open Thread open Amqp_client_lib open Types open Spec.Basic module Client = struct type t = { queue: Queue.t; channel: [ `Ok ] Channel.t; id: string; outstanding: (string, Message.message option Ivar.t) Hashtbl.t; mutable counter: int; consumer: [ `Ok...
null
https://raw.githubusercontent.com/andersfugmann/amqp-client/e6e92225b91742fa8777a02ad9b59a1dde45e752/async/src/rpc.ml
ocaml
maybe such a id never existed, maybe it arrived too late so * it was deleted in the meantime Register handler for the reply before sending the query Set headers so we can get timedout messages * Release resources The server needs a queue name and a handler Start consuming.
open Thread open Amqp_client_lib open Types open Spec.Basic module Client = struct type t = { queue: Queue.t; channel: [ `Ok ] Channel.t; id: string; outstanding: (string, Message.message option Ivar.t) Hashtbl.t; mutable counter: int; consumer: [ `Ok...
c75bfcd8dfdfac2d5bfd7fbc55aaf39675a250104a75401df5c04bdd4c10de63
csg-tokyo/typelevelLR
TestValid2.hs
import HelloDSL main :: IO () main = print $ begin |> hello |> name "name" |> end
null
https://raw.githubusercontent.com/csg-tokyo/typelevelLR/ca5853890fac7fb819a026f0fd15d8b43f7c8470/examples/haskell/hello/TestValid2.hs
haskell
import HelloDSL main :: IO () main = print $ begin |> hello |> name "name" |> end