_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
4b31e46fd79ffad71546712d1982225719b34aa66918626e02106ea81b6c0964
Deducteam/Dedukti
confluence.mli
(** Confluence checker *) open Basic open Rule val d_confluence : Debug.flag type confluence_error = | NotConfluent of string | MaybeConfluent of string | CCFailure of string exception Confluence_error of confluence_error val set_cmd : string -> unit val initialize : unit -> unit val add_constant : name ->...
null
https://raw.githubusercontent.com/Deducteam/Dedukti/af7dfba10b4858354524ed798b8b58dd2cf2b923/kernel/confluence.mli
ocaml
* Confluence checker
open Basic open Rule val d_confluence : Debug.flag type confluence_error = | NotConfluent of string | MaybeConfluent of string | CCFailure of string exception Confluence_error of confluence_error val set_cmd : string -> unit val initialize : unit -> unit val add_constant : name -> unit val add_rules : rul...
d46d8af0a9f30d7957acd48f3878d478368ead7efedb3ab50595ec06806073ba
athos/kitchen-async
utils.cljc
(ns kitchen-async.utils (:require [cljs.env :as env])) (defn fixup-alias [sym] (or (when-let [prefix (some-> (namespace sym) symbol)] (let [ns-name (ns-name *ns*) ns (get (:cljs.analyzer/namespaces @env/*compiler*) ns-name)] (when-let [full-name (or (get-in ns ...
null
https://raw.githubusercontent.com/athos/kitchen-async/1f28eab4ef7126e0b8b6fd8d8887beeab7430fea/src/kitchen_async/utils.cljc
clojure
(ns kitchen-async.utils (:require [cljs.env :as env])) (defn fixup-alias [sym] (or (when-let [prefix (some-> (namespace sym) symbol)] (let [ns-name (ns-name *ns*) ns (get (:cljs.analyzer/namespaces @env/*compiler*) ns-name)] (when-let [full-name (or (get-in ns ...
d49a5363e2ec6096cec072fb57ecd9735da370cdfcbb903dc4c1112acd8af6f4
kupl/LearnML
original.ml
type aexp = | Const of int | Var of string | Power of (string * int) | Times of aexp list | Sum of aexp list let rec diff ((e : aexp), (x : string)) : aexp = match e with | Const c -> Const 0 | Var v -> if v = x then Const 1 else Var v | Power (str, po) -> ( match str with x -> Times [ Const po...
null
https://raw.githubusercontent.com/kupl/LearnML/c98ef2b95ef67e657b8158a2c504330e9cfb7700/result/cafe2/diff/sub145/original.ml
ocaml
type aexp = | Const of int | Var of string | Power of (string * int) | Times of aexp list | Sum of aexp list let rec diff ((e : aexp), (x : string)) : aexp = match e with | Const c -> Const 0 | Var v -> if v = x then Const 1 else Var v | Power (str, po) -> ( match str with x -> Times [ Const po...
f5960955f584473cd72f4888d37048fac775078d80b6a264bbe6e4339d4e7794
CloudI/CloudI
rebar_erlc_compiler.erl
-*- erlang - indent - level : 4;indent - tabs - mode : nil -*- %% ex: ts=4 sw=4 et %% ------------------------------------------------------------------- %% rebar : Erlang Build Tools %% Copyright ( c ) 2009 , 2010 ( ) %% %% Permission is hereby granted, free of charge, to any person obtaining a copy %% of thi...
null
https://raw.githubusercontent.com/CloudI/CloudI/3e45031c7ee3e974ead2612ea7dd06c9edf973c9/src/external/rebar/src/rebar_erlc_compiler.erl
erlang
ex: ts=4 sw=4 et ------------------------------------------------------------------- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal to use, copy, modify, merge, publish, distribute, sublicense, and/or sel...
-*- erlang - indent - level : 4;indent - tabs - mode : nil -*- rebar : Erlang Build Tools Copyright ( c ) 2009 , 2010 ( ) in the Software without restriction , including without limitation the rights copies of the Software , and to permit persons to whom the Software is all copies or substantial portions...
d17f15c73e582368cef7e490b1b8525bbf5395f8ec467c279fb453342982b720
mdunnio/coinbase-pro
Headers.hs
{-# LANGUAGE DataKinds #-} # LANGUAGE GeneralizedNewtypeDeriving # {-# LANGUAGE OverloadedStrings #-} module CoinbasePro.Headers ( RequiredHeader , UserAgent , UserAgentHeader , userAgent ) where import Data.Text (Text) import Servant.API (H...
null
https://raw.githubusercontent.com/mdunnio/coinbase-pro/5d5fa95e66481a974786ef362a4ea55ba94c63a9/src/lib/CoinbasePro/Headers.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE OverloadedStrings #
# LANGUAGE GeneralizedNewtypeDeriving # module CoinbasePro.Headers ( RequiredHeader , UserAgent , UserAgentHeader , userAgent ) where import Data.Text (Text) import Servant.API (Header', Required) import Web.HttpApiData (ToHttpApiData (..)) type RequiredH...
1ba43665027d15607d3f14981e63284ba355fb89b7132b0818214a9cc16140dc
Sword-Smith/Sword
EvmCompilerHelper.hs
MIT License -- Copyright ( c ) 2019 and -- -- Permission is hereby granted, free of charge, to any person obtaining a copy -- of this software and associated documentation files (the "Software"), to deal in the Software without restriction , including without limitation the rights -- to use, copy, modify, mer...
null
https://raw.githubusercontent.com/Sword-Smith/Sword/214da8011eec75fb949bdc52418b269ab329b2c6/src/EvmCompilerHelper.hs
haskell
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal to use, copy, modify, merge, publish, distribute, sublicense, and/or sell furnished to do so, subject to the following conditions: The above copyright notice...
MIT License Copyright ( c ) 2019 and in the Software without restriction , including without limitation the rights copies of the Software , and to permit persons to whom the Software is copies or substantial portions of the Software . THE SOFTWARE IS PROVIDED " AS IS " , WITHOUT WARRANTY OF ANY KIND , E...
6c8cc86fcd436c3a827b76b77c04a4bb681aa8bd6a44f86d31d40abaaa90cb7b
wireapp/wire-server
PasswordResetCode_user.hs
-- This file is part of the Wire Server implementation. -- Copyright ( C ) 2022 Wire Swiss GmbH < > -- -- This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License...
null
https://raw.githubusercontent.com/wireapp/wire-server/c428355b7683b7b7722ea544eba314fc843ad8fa/libs/wire-api/test/golden/Test/Wire/API/Golden/Generated/PasswordResetCode_user.hs
haskell
This file is part of the Wire Server implementation. This program is free software: you can redistribute it and/or modify it under 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 PARTI...
Copyright ( C ) 2022 Wire Swiss GmbH < > the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or ( at your option ) any You should have received a copy of the GNU Affero General Public License along module Test.Wire.API.Golden.Gene...
c8768022dc75c6bb4532c3dd219c5a8d2329c88adb20afa60f80cf82dd44c741
borkdude/edamame
utils.cljc
(ns edamame.test-utils.utils) (defn submap? "Is m1 a submap of m2? Adapted from -alpha2, clojure.test-clojure.spec" [m1 m2] (cond (and (map? m1) (map? m2)) (every? (fn [[k v]] (and (contains? m2 k) (submap? v (get m2 k)))) m1) #?(:clj (instance? java.util.re...
null
https://raw.githubusercontent.com/borkdude/edamame/e609451d5dc38f347a5e0c68453edd76cccac3ff/test/edamame/test_utils/utils.cljc
clojure
(ns edamame.test-utils.utils) (defn submap? "Is m1 a submap of m2? Adapted from -alpha2, clojure.test-clojure.spec" [m1 m2] (cond (and (map? m1) (map? m2)) (every? (fn [[k v]] (and (contains? m2 k) (submap? v (get m2 k)))) m1) #?(:clj (instance? java.util.re...
0d4d1c0217a1b1f8d95d6e14c9544d4795cbb57a7d0b2059f5108f59b29c6537
newque/newque
connector.mli
open Core type 'a t val create : float -> 'a t (* Returns a thunk. The timer starts after the thunk is executed. *) val submit : 'a t -> string -> string -> (unit -> 'a Lwt.t) val resolve : 'a t -> string -> 'a -> unit Lwt.t
null
https://raw.githubusercontent.com/newque/newque/dee73e2cb7be8700847f9e5cf900731cc20b1b8c/src/persistence/fifo/connector.mli
ocaml
Returns a thunk. The timer starts after the thunk is executed.
open Core type 'a t val create : float -> 'a t val submit : 'a t -> string -> string -> (unit -> 'a Lwt.t) val resolve : 'a t -> string -> 'a -> unit Lwt.t
ee550c89cae2cfec642641e806fba95a95104ed4d9216489d50ffd3ed127de44
tschady/advent-of-code
d14_test.clj
(ns aoc.2022.d14-test (:require [aoc.2022.d14 :as sut] [clojure.test :refer :all])) (deftest challenges (is (= 885 (sut/part-1 sut/input))) (is (= 28691 (sut/part-2 sut/input))))
null
https://raw.githubusercontent.com/tschady/advent-of-code/8d1915c743820f6b38c04c52f653d67eea72aad2/test/aoc/2022/d14_test.clj
clojure
(ns aoc.2022.d14-test (:require [aoc.2022.d14 :as sut] [clojure.test :refer :all])) (deftest challenges (is (= 885 (sut/part-1 sut/input))) (is (= 28691 (sut/part-2 sut/input))))
5c3751a01e776f575921618dac5667a47188b31a1c34518fb1880275086007c8
bitonic/anapo
Anapo.hs
module Anapo (module X) where import Anapo.Component as X hiding (el) import Anapo.Loop as X
null
https://raw.githubusercontent.com/bitonic/anapo/8f3c020973d16cecb5ee83a03d91fb00294d34c7/anapo/src/Anapo.hs
haskell
module Anapo (module X) where import Anapo.Component as X hiding (el) import Anapo.Loop as X
43a909ce9ec9ba20b51a44ff770fb883963beddf768a3dd76db9719baf67d41f
input-output-hk/project-icarus-importer
Trans.hs
# LANGUAGE TypeFamilies # -- | PollT monad transformer. Single-threaded. module Pos.Update.Poll.Trans ( PollT , runPollT , evalPollT , execPollT ) where import Universum import Control.Lens (uses, (%=), (.=)) import Control.Monad.State (MonadState (.....
null
https://raw.githubusercontent.com/input-output-hk/project-icarus-importer/36342f277bcb7f1902e677a02d1ce93e4cf224f0/update/Pos/Update/Poll/Trans.hs
haskell
| PollT monad transformer. Single-threaded. -------------------------------------------------------------------------- -------------------------------------------------------------------------- single-threaded usage only. -------------------------------------------------------------------------- Runners -----------...
# LANGUAGE TypeFamilies # module Pos.Update.Poll.Trans ( PollT , runPollT , evalPollT , execPollT ) where import Universum import Control.Lens (uses, (%=), (.=)) import Control.Monad.State (MonadState (..)) import qualified Data.HashMap.Strict as HM i...
5bd017c6aaf68cd84a1fe4a83c8e8a44a69099c0777cdb33e65c843e856e56a5
sadraskol/olympus
project.clj
(defproject olympus-analysis "0.1.0-SNAPSHOT" :description "FIXME: write description" :url "" :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"] [elle "0.1.2"] [spootnik/unilog "0.7....
null
https://raw.githubusercontent.com/sadraskol/olympus/bd907b4b610610053813211e99d516e1db78ac0b/olympus-analysis/project.clj
clojure
(defproject olympus-analysis "0.1.0-SNAPSHOT" :description "FIXME: write description" :url "" :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"] [elle "0.1.2"] [spootnik/unilog "0.7....
6f14f9dc8e41fc67e91fb7901d05203261dd5c9d0cd9f41741f3b39c21cf9d3b
pixlsus/registry.gimp.org_static
line-nova_20101016.scm
line-nova.scm for -*-scheme-*- Time - stamp : < 1998/11/25 13:26:44 > Author < > Version 0.7 2010 Oct 16 - 1 ) Modified to allow an offset from the center 2 ) Changed " Number of lines " lower limit from 40 to 3 (define (script-fu-line-nova img drw num-of-lines corn-deg offset variation xoffset yoff...
null
https://raw.githubusercontent.com/pixlsus/registry.gimp.org_static/ffcde7400f402728373ff6579947c6ffe87d1a5e/registry.gimp.org/files/line-nova_20101016.scm
scheme
antialias feather feather radius
line-nova.scm for -*-scheme-*- Time - stamp : < 1998/11/25 13:26:44 > Author < > Version 0.7 2010 Oct 16 - 1 ) Modified to allow an offset from the center 2 ) Changed " Number of lines " lower limit from 40 to 3 (define (script-fu-line-nova img drw num-of-lines corn-deg offset variation xoffset yoff...
0c040f4b33593e2ef5a2a8e73eec5c464d167313349277144e2d3578200bd9f3
epm/eper
sherk_tree.erl
%%%------------------------------------------------------------------- %%% File : sherk_tree.erl Author : Mats < locmacr@mwlx084 > %%% Description : %%% Created : 21 Aug 2006 by Mats < locmacr@mwlx084 > %%%------------------------------------------------------------------- -module(sherk_tree). -export([go/...
null
https://raw.githubusercontent.com/epm/eper/c152d6dfea58d5ea7bdf99fc9217d8444ac6b327/src/sherk_tree.erl
erlang
------------------------------------------------------------------- File : sherk_tree.erl Description : ------------------------------------------------------------------- node() := {Key,Data,[nodes()]}
Author : Mats < locmacr@mwlx084 > Created : 21 Aug 2006 by Mats < locmacr@mwlx084 > -module(sherk_tree). -export([go/1]). -import(lists,[foldl/3,reverse/1,sort/1,sort/2]). -import(sherk,[to_str/1]). -import(sherk_ets,[lup/2]). -define(LOG(T), sherk:log(process_info(self()),T)). go(procs) -> Tot = lup(she...
b2c52a68813ab56e772b0c171704f0921bb93c690988ffdd2914d8f7063359e5
emina/rosette
clean.rkt
#lang racket (define (strip xs) (printf "'(") (for ([x xs]) (printf "~a " x)) (printf ")"))
null
https://raw.githubusercontent.com/emina/rosette/a64e2bccfe5876c5daaf4a17c5a28a49e2fbd501/rosette/guide/scribble/util/clean.rkt
racket
#lang racket (define (strip xs) (printf "'(") (for ([x xs]) (printf "~a " x)) (printf ")"))
3b21f20d7080f2f931100b75d4111005d49774ea9cbc23629472f2473d6e064f
LeventErkok/sbv
IntSqrt.hs
----------------------------------------------------------------------------- -- | Module : Documentation . SBV.Examples . . IntSqrt Copyright : ( c ) -- License : BSD3 -- Maintainer: -- Stability : experimental -- -- Proof of correctness of an imperative integer square-root algorithm, using -- weakest pr...
null
https://raw.githubusercontent.com/LeventErkok/sbv/9cd3662cb6ae31a95b99570f91ae4639807dc1ab/Documentation/SBV/Examples/WeakestPreconditions/IntSqrt.hs
haskell
--------------------------------------------------------------------------- | License : BSD3 Maintainer: Stability : experimental Proof of correctness of an imperative integer square-root algorithm, using weakest preconditions. The algorithm computes the floor of the square-root of a given non-negative integ...
Module : Documentation . SBV.Examples . . IntSqrt Copyright : ( c ) starting from 1 . Recall that @1 + 3 + 5+ ... +(2n+1 ) = ( n+1)^2@ , thus we can # LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE NamedFieldPuns # module Documentation.SBV.Examples.WeakestPrecond...
7be1460191a28e189767c6d0fd5bfe7c5fc0c341d0f74ba8131f021f7839427c
contivero/hasmin
BorderRadius.hs
----------------------------------------------------------------------------- -- | Module : Hasmin . . BorderRadius Copyright : ( c ) 2017 -- License : BSD3 -- Stability : experimental -- Portability : unknown -- Parsers for CSS values . -- ------------------------------------------------------...
null
https://raw.githubusercontent.com/contivero/hasmin/2a7604159b51e69c5e9c564dce53cb3ab09ae22b/src/Hasmin/Parser/BorderRadius.hs
haskell
--------------------------------------------------------------------------- | License : BSD3 Stability : experimental Portability : unknown --------------------------------------------------------------------------- <length-percentage>{1,4} [ / <length-percentage>{1,4} ]?
Module : Hasmin . . BorderRadius Copyright : ( c ) 2017 Parsers for CSS values . module Hasmin.Parser.BorderRadius ( borderRadius ) where import Data.Attoparsec.Text (Parser) import qualified Data.Attoparsec.Text as A import Data.List.NonEmpty (NonEmpty((:|))) import Hasmin.Parser.Utils imp...
437e8ab3fa7d6d8a4a8bd95ac0559d68c40479ae7e9f650cfe0a3e20153f704f
mejgun/haskell-tdlib
SearchChatMessages.hs
{-# LANGUAGE OverloadedStrings #-} -- | module TD.Query.SearchChatMessages where import qualified Data.Aeson as A import qualified Data.Aeson.Types as T import qualified TD.Data.MessageSender as MessageSender import qualified TD.Data.SearchMessagesFilter as SearchMessagesFilter import qualified Utils as U -- | -- Se...
null
https://raw.githubusercontent.com/mejgun/haskell-tdlib/dc380d18d49eaadc386a81dc98af2ce00f8797c2/src/TD/Query/SearchChatMessages.hs
haskell
# LANGUAGE OverloadedStrings # | | Searches for messages with given words in the chat. Returns the results in reverse chronological order, i.e. in order of decreasing message_id. Cannot be used in secret chats with a non-empty query | If not 0, only messages in the specified thread will be returned; supergroups onl...
module TD.Query.SearchChatMessages where import qualified Data.Aeson as A import qualified Data.Aeson.Types as T import qualified TD.Data.MessageSender as MessageSender import qualified TD.Data.SearchMessagesFilter as SearchMessagesFilter import qualified Utils as U ( searchSecretMessages must be used instead ) , ...
907cd8d2183d11741eb910562eef4e8e651953fb78818a749917a93702d7b4a1
basho/riak_test
repl_rt_pending.erl
%% ------------------------------------------------------------------- %% Copyright ( c ) 2013 Basho Technologies , Inc. %% %% ------------------------------------------------------------------- -module(repl_rt_pending). -behaviour(riak_test). -export([confirm/0]). -include_lib("eunit/include/eunit.hrl"). -define(RP...
null
https://raw.githubusercontent.com/basho/riak_test/8170137b283061ba94bc85bf42575021e26c929d/tests/repl_rt_pending.erl
erlang
------------------------------------------------------------------- ------------------------------------------------------------------- a response is not received in {riak_repl, rt_heartbeat_timeout}, also by the supervisor. Test: ----- Write some objects to the source cluster (A), Verify they got to the s...
Copyright ( c ) 2013 Basho Technologies , Inc. -module(repl_rt_pending). -behaviour(riak_test). -export([confirm/0]). -include_lib("eunit/include/eunit.hrl"). -define(RPC_TIMEOUT, 5000). -define(HB_TIMEOUT, 2000). Replication Realtime Heartbeat test Valid for EE version 1.3.2 and up If both sides of an RT re...
1601e9a0c6a62f95424a8314d736508ddf23c2ad79394fb042706698eedf7823
s-expressionists/Cleavir
packages.lisp
(cl:in-package #:common-lisp-user) (defpackage #:cleavir-io (:use #:common-lisp) (:export #:*io-readtable* #:save-info #:define-save-info #:read-model-object #:read-model #:write-model))
null
https://raw.githubusercontent.com/s-expressionists/Cleavir/e0293780d356a9d563af9abf9317019f608b4e1d/Input-output/packages.lisp
lisp
(cl:in-package #:common-lisp-user) (defpackage #:cleavir-io (:use #:common-lisp) (:export #:*io-readtable* #:save-info #:define-save-info #:read-model-object #:read-model #:write-model))
870c2183d60ac7ecfda8270934eb51ab26f099939f03be09e365b11c31a35d60
yogthos/markdown-clj
lists.cljc
(ns markdown.lists (:require [clojure.string :as string] [markdown.common :refer [*substring* make-heading]])) (defn close-lists [lists] (string/join (for [[list-type] lists] (str "</li></" (name list-type) ">")))) (defn add-row [row-type list-type num-indents indents content state] (if li...
null
https://raw.githubusercontent.com/yogthos/markdown-clj/1943178d4980632215f74561b90d7d1371edf094/src/cljc/markdown/lists.cljc
clojure
(ns markdown.lists (:require [clojure.string :as string] [markdown.common :refer [*substring* make-heading]])) (defn close-lists [lists] (string/join (for [[list-type] lists] (str "</li></" (name list-type) ">")))) (defn add-row [row-type list-type num-indents indents content state] (if li...
2fa4ec68633ce767412a7acb7bc9e4e426a2d0310fe43604bc7d46a2ccbc4952
tweag/asterius
TH.hs
{-# LANGUAGE PackageImports #-} # LANGUAGE TemplateHaskell # # LANGUAGE ViewPatterns # module Asterius.Binary.TH ( genBinary, ) where import qualified Binary as GHC import Data.Foldable import Data.Word import "template-haskell" Language.Haskell.TH genBinary :: Name -> Q [Dec] genBinary ty = do TyConI dec <- r...
null
https://raw.githubusercontent.com/tweag/asterius/506fa3b3b79d973db064a3ef1dd6de5d29a3bf78/asterius/src-types/Asterius/Binary/TH.hs
haskell
# LANGUAGE PackageImports #
# LANGUAGE TemplateHaskell # # LANGUAGE ViewPatterns # module Asterius.Binary.TH ( genBinary, ) where import qualified Binary as GHC import Data.Foldable import Data.Word import "template-haskell" Language.Haskell.TH genBinary :: Name -> Q [Dec] genBinary ty = do TyConI dec <- reify ty case dec of DataD ...
6cbdd0d3d78ac8af134cbda49735583ab68f7a40614a7f45225bc76fdac66628
s-expressionists/Incless
conditions.lisp
(in-package #:incless) (define-condition print-not-readable-unimplementable (print-not-readable) () (:report (lambda (condition stream) (format stream "A readable printer for ~S cannot be implemented ~ portably by Incless." (print-not-readable-object condition)))))
null
https://raw.githubusercontent.com/s-expressionists/Incless/0f4a2b591f621753d691706ae43db5b78bddc9f6/src/implementation/conditions.lisp
lisp
(in-package #:incless) (define-condition print-not-readable-unimplementable (print-not-readable) () (:report (lambda (condition stream) (format stream "A readable printer for ~S cannot be implemented ~ portably by Incless." (print-not-readable-object condition)))))
d2c0558a329b720e063295e539bfee3253ba3781f32f0fd0bded841a3dfac359
exercism/racket
perfect-numbers.rkt
#lang racket (provide classify) (define (classify number) (error "Not implemented yet"))
null
https://raw.githubusercontent.com/exercism/racket/ce7b72cfde0695588771031d6b69d8d1cb199038/exercises/practice/perfect-numbers/perfect-numbers.rkt
racket
#lang racket (provide classify) (define (classify number) (error "Not implemented yet"))
e53e22a030c3eabe80ca9f0024b2796e2163c2e49772e6bda23bc9d637e3f7d2
echeran/clj-thamil
project.clj
(defproject clj-thamil "0.2.0" :description "A project encompassing various Thamil language-specific computing ideas" :url "-thamil" :license {:name "Eclipse Public License" :url "-v10.html"} :scm {:name "git" :url "-thamil"} :repositories [["releases" {:url "/"}]] :deploy-repositories [...
null
https://raw.githubusercontent.com/echeran/clj-thamil/692a6d94329bb14cb58fb39b875792e5d774d2c4/project.clj
clojure
:builds [{:source-paths ["target/classes" "target/test-classes"] :compiler {:output-to "target/testable.js" :optimizations :advanced :pretty-print true}}]} no cljs test configured yet
(defproject clj-thamil "0.2.0" :description "A project encompassing various Thamil language-specific computing ideas" :url "-thamil" :license {:name "Eclipse Public License" :url "-v10.html"} :scm {:name "git" :url "-thamil"} :repositories [["releases" {:url "/"}]] :deploy-repositories [...
3217304e55cca87209506b371be5acdd8e25a6e9f71ed1384cf78a735da14e1e
sicmutils/sicmutils
ch3_test.cljc
#_"SPDX-License-Identifier: GPL-3.0" (ns sicmutils.sicm.ch3-test (:refer-clojure :exclude [+ - * / zero? partial]) (:require [clojure.test :refer [is deftest testing use-fixtures]] [sicmutils.env :as e :refer [+ zero? up down literal-function]] [sicmutils.examples.driven-pendul...
null
https://raw.githubusercontent.com/sicmutils/sicmutils/f427fd073937faf62741fcdda6362f910ecda71f/test/sicmutils/sicm/ch3_test.cljc
clojure
sine (of that. So our algorithm is a little on the naive side o_o
#_"SPDX-License-Identifier: GPL-3.0" (ns sicmutils.sicm.ch3-test (:refer-clojure :exclude [+ - * / zero? partial]) (:require [clojure.test :refer [is deftest testing use-fixtures]] [sicmutils.env :as e :refer [+ zero? up down literal-function]] [sicmutils.examples.driven-pendul...
46abbbebbb858d5ca63f2f80a875d2294730014ff03f63fa8e56a07ac11009a9
frictionlessdata/tableschema-clj
yearmonth_test.clj
(ns tableschema-clj.types.yearmonth-test (:require [tableschema-clj.types.yearmonth :refer :all] [clojure.test :refer :all])) (defonce INVALID :clojure.spec.alpha/invalid) (deftest test-cast-yearmonth (are [format value result] (= (cast-yearmonth format value) result) "default" [2000 10] [2000 10]...
null
https://raw.githubusercontent.com/frictionlessdata/tableschema-clj/c907da7eabe752eb47a0b18064c0de23937474d1/test/tableschema_clj/types/yearmonth_test.clj
clojure
(ns tableschema-clj.types.yearmonth-test (:require [tableschema-clj.types.yearmonth :refer :all] [clojure.test :refer :all])) (defonce INVALID :clojure.spec.alpha/invalid) (deftest test-cast-yearmonth (are [format value result] (= (cast-yearmonth format value) result) "default" [2000 10] [2000 10]...
0cab18936adb668f19ac61edf5bc058841253a9b05f7e66cea03c11cb851e44d
clash-lang/clash-prelude
Mealy.hs
| Copyright : ( C ) 2013 - 2016 , University of Twente , 2017 , Google Inc. License : BSD2 ( see the file LICENSE ) Maintainer : < > Whereas the output of a machine depends on the /previous state/ , the output of a Mealy machine depends on /current transit...
null
https://raw.githubusercontent.com/clash-lang/clash-prelude/5645d8417ab495696cf4e0293796133c7fe2a9a7/src/Clash/Explicit/Mealy.hs
haskell
# LANGUAGE Safe # * Mealy machines with explicit clock and reset ports | Create a synchronous function from a combinational function describing a mealy machine @ import qualified Data.List as L macT :: Int -- Current state -> (Int,Int) -- Input -> (Int,Int) -- (Updated state, output) macT s (...
| Copyright : ( C ) 2013 - 2016 , University of Twente , 2017 , Google Inc. License : BSD2 ( see the file LICENSE ) Maintainer : < > Whereas the output of a machine depends on the /previous state/ , the output of a Mealy machine depends on /current transit...
ce94bc579886a07c446e7a9d3d339250856b2c6951edab9d6cf316e813b930b7
danieljharvey/mimsa
NestingMonadSpec.hs
{-# LANGUAGE OverloadedStrings #-} module Test.Typecheck.NestingMonadSpec (spec) where import Control.Monad.Writer.CPS import Test.Hspec spec :: Spec spec = do describe "Nesting" $ do it "Writes some stuff" $ do let action = tell [1 :: Int, 2, 3] runWriter action `shouldBe` ((), [1, 2, 3]) ...
null
https://raw.githubusercontent.com/danieljharvey/mimsa/97421f00f4487dc7d4988eb1dcddd65c4e379538/smol-core/test/Test/Typecheck/NestingMonadSpec.hs
haskell
# LANGUAGE OverloadedStrings #
module Test.Typecheck.NestingMonadSpec (spec) where import Control.Monad.Writer.CPS import Test.Hspec spec :: Spec spec = do describe "Nesting" $ do it "Writes some stuff" $ do let action = tell [1 :: Int, 2, 3] runWriter action `shouldBe` ((), [1, 2, 3]) it "Writes some stuff in a sub...
1e61b6bd9c7ad434437c3bb60bfd5f308f0abb8bac08c4fc57161598d2e6b12c
factisresearch/mq-demo
Preview.hs
module Mgw.Util.Preview (Preview(..), preview, previewNamedSet, previewNamedList, PreviewList(..), previewList ,previewRec ,previewRec', previewKv, showKv ,previewElems, previewsElems, pprMapping, previewList' ,Ppr(..), Ppr'(..), Doc, pretty, docFromStr, shortPreviewStr ) where --------------------...
null
https://raw.githubusercontent.com/factisresearch/mq-demo/0efa1991ca647a86a8c22e516a7a1fb392ab4596/server/src/lib/Mgw/Util/Preview.hs
haskell
-------------------------------------- LOCAL -------------------------------------- -------------------------------------- SITE-PACKAGES -------------------------------------- -------------------------------------- STDLIB --------------------------------------
module Mgw.Util.Preview (Preview(..), preview, previewNamedSet, previewNamedList, PreviewList(..), previewList ,previewRec ,previewRec', previewKv, showKv ,previewElems, previewsElems, pprMapping, previewList' ,Ppr(..), Ppr'(..), Doc, pretty, docFromStr, shortPreviewStr ) where import Mgw.Util.List...
863ad760de7a91e01829c1e5ce04f13e6dc5186fb6bd98d993bc691b28d4ea79
nkaretnikov/OOHaskell
ObjConstructionS.hs
( C ) 2004 - 2005 , Oleg Kiselyov & 's overlooked object system -- Staging problems with object conctrsution module ObjConstructionS where import Data.IORef import Shape hiding (shape) import Circle hiding (circle) import SMFix -- Constructor for shapes -- Hardly any changes shape x y concreteDraw tail se...
null
https://raw.githubusercontent.com/nkaretnikov/OOHaskell/ddf42cfa62f8bd27643ff6db136dec6c14466232/repository/shapes/Haskell/Shapes4/ObjConstructionS.hs
haskell
Staging problems with object conctrsution Constructor for shapes Hardly any changes z <- getX self Again, the type error Closed constructor for circles What can go wrong x' <- getX self -- the object isn't constructed yet Now, that gives a type error! safe safe
( C ) 2004 - 2005 , Oleg Kiselyov & 's overlooked object system module ObjConstructionS where import Data.IORef import Shape hiding (shape) import Circle hiding (circle) import SMFix shape x y concreteDraw tail self = do xRef <- newIORef x yRef <- newIORef y tail' <- tail sr...
1c784070a07c71810901d882e8cb3080dea286e00dc645f67d3e238c4d576b79
shayne-fletcher/ghc-lib-parser-ex
Pat.hs
Copyright ( c ) 2020 , . All rights reserved . SPDX - License - Identifier : BSD-3 - Clause . # LANGUAGE CPP # # LANGUAGE ViewPatterns # #include "ghclib_api.h" module Language.Haskell.GhclibParserEx.GHC.Hs.Pat( patToStr, strToPat , fromPChar , hasPFieldsDotDot , isPFieldWildcard, isPWildcard, isPField...
null
https://raw.githubusercontent.com/shayne-fletcher/ghc-lib-parser-ex/e7e6af7a687dff6b57fe8938610ca2e752901134/src/Language/Haskell/GhclibParserEx/GHC/Hs/Pat.hs
haskell
Contains a '..' as in 'Foo{..}'
Copyright ( c ) 2020 , . All rights reserved . SPDX - License - Identifier : BSD-3 - Clause . # LANGUAGE CPP # # LANGUAGE ViewPatterns # #include "ghclib_api.h" module Language.Haskell.GhclibParserEx.GHC.Hs.Pat( patToStr, strToPat , fromPChar , hasPFieldsDotDot , isPFieldWildcard, isPWildcard, isPField...
77992c5d0437bb257c31e3b919bf3e32bc4f72404118d30555fd914deb726646
drlivingston/kabob
refseq_id_typing_rules.clj
RefSeq Ids can represent Genomic , RNA , mRNA , or Protein sequences ;; RefSeq genomic identifiers are of type kiao/DNASequenceIdentifier ;; `{:name "refseq-genomic-id-type-assertion" : head ( ( ? /ice rdf / type kiao / DNAIdentifier ) ) ;; :body ((_/record kiao/hasTemplate ;; iaorefseq/refseqRe...
null
https://raw.githubusercontent.com/drlivingston/kabob/7038076849744c959da9c8507e8a8ab7215410aa/kabob-build/src/main/resources/edu/ucdenver/ccp/kabob/build/rules/id_typing/refseq_id_typing_rules.clj
clojure
RefSeq genomic identifiers are of type kiao/DNASequenceIdentifier `{:name "refseq-genomic-id-type-assertion" :body ((_/record kiao/hasTemplate iaorefseq/refseqRefSeqReleaseCatalogFileDataSchema1) (_/f2 ro/part_of _/record) (_/f2 iao/IAO_0000219 "Genomic") (_/f ro/par...
RefSeq Ids can represent Genomic , RNA , mRNA , or Protein sequences : head ( ( ? /ice rdf / type kiao / DNAIdentifier ) ) ( _ /f2 / / refseqmoleculeTypeDataField1 ) ( _ /f kiao / ) : head ( ( ? /ice rdf / type kiao / DNAIdentifier ) ) / refseqmoleculeType...
fb42ae45db839ab48bb354e78c61a9d14c1ae47b732a3ea84372a3e9867da809
alpacaaa/quad-ci
JobHandler.hs
module JobHandler where import qualified Agent import Core import qualified Data.Aeson as Aeson import RIO data Service = Service { queueJob :: CommitInfo -> Pipeline -> IO BuildNumber, dispatchCmd :: IO (Maybe Agent.Cmd), processMsg :: Agent.Msg -> IO (), findJob :: BuildNumber -> IO (Maybe Job), f...
null
https://raw.githubusercontent.com/alpacaaa/quad-ci/99175d3d0da5c03de22e3b20ae3b6ded79e40b57/src/JobHandler.hs
haskell
module JobHandler where import qualified Agent import Core import qualified Data.Aeson as Aeson import RIO data Service = Service { queueJob :: CommitInfo -> Pipeline -> IO BuildNumber, dispatchCmd :: IO (Maybe Agent.Cmd), processMsg :: Agent.Msg -> IO (), findJob :: BuildNumber -> IO (Maybe Job), f...
67b619581df72b75aa3a174c74cea9f615cb981cdcab556e56dfe0a77c36681a
deadpendency/deadpendency
GHAppInstallationId.hs
module Common.Model.GitHub.GHAppInstallationId ( GHAppInstallationId (..), ) where import Common.Aeson.Aeson import Data.Aeson newtype GHAppInstallationId = GHAppInstallationId { _ntInt :: Int } deriving stock (Eq, Show, Generic) instance ToJSON GHAppInstallationId where toJSON = genericToJSON cleanJSONO...
null
https://raw.githubusercontent.com/deadpendency/deadpendency/170d6689658f81842168b90aa3d9e235d416c8bd/apps/common/src/Common/Model/GitHub/GHAppInstallationId.hs
haskell
module Common.Model.GitHub.GHAppInstallationId ( GHAppInstallationId (..), ) where import Common.Aeson.Aeson import Data.Aeson newtype GHAppInstallationId = GHAppInstallationId { _ntInt :: Int } deriving stock (Eq, Show, Generic) instance ToJSON GHAppInstallationId where toJSON = genericToJSON cleanJSONO...
bc08c226e865093facf4a9c704869a283e2bb017b1417643f70be0b255e0d339
SamB/coq
equality.ml
(************************************************************************) v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * CNRS - Ecole Polytechnique - INRIA Futurs - Universite Paris Sud \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *...
null
https://raw.githubusercontent.com/SamB/coq/8f84aba9ae83a4dc43ea6e804227ae8cae8086b1/tactics/equality.ml
ocaml
********************************************************************** // * This file is distributed under the terms of the * GNU Lesser General Public License Version 2.1 ********************************************************************** Rewriting tactics Ad hoc asymmetr...
v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * CNRS - Ecole Polytechnique - INRIA Futurs - Universite Paris Sud \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * $ Id$ open Pp open Util ...
0f4667f202e1aacc7e35307861a277310e2e57d15b4d1fc02b8c01751eb57f62
ocaml-sf/learn-ocaml-corpus
decompress_offset_zero.ml
(* -------------------------------------------------------------------------- *) (* Building an alphabet out of a piece of text. *) let build_alphabet (text : text) : alphabet = let table = Hashtbl.create 256 in String.iter (fun symbol -> let freq = try Hashtbl.find table symbol with Not_f...
null
https://raw.githubusercontent.com/ocaml-sf/learn-ocaml-corpus/7dcf4d72b49863a3e37e41b3c3097aa4c6101a69/exercises/fpottier/huffman/wrong/decompress_offset_zero.ml
ocaml
-------------------------------------------------------------------------- Building an alphabet out of a piece of text. -------------------------------------------------------------------------- Building encoding and decoding dictionaries out of an alphabet. The priority queue contains pairs of a tree and a fr...
let build_alphabet (text : text) : alphabet = let table = Hashtbl.create 256 in String.iter (fun symbol -> let freq = try Hashtbl.find table symbol with Not_found -> 0 in Hashtbl.replace table symbol (freq + 1) ) text; table module Q = BinomialQueue(struct type...
54ae58db7a2fd002ec90c1db6009e95554e39a4d20aae21ca7a5b8a683149c68
joelburget/Cologne
Smallpaint.hs
# LANGUAGE FlexibleContexts # -- This is a rewrite of smallpaint: / module Cologne.Shaders.Smallpaint ( smallpaint , Halton(Halton) , halton , next , hGet ) where import System.Random hiding (next) import Control.Monad.State import Control.Applicative ((<$>)) import Cologne.Vec import Cologne.Primitiv...
null
https://raw.githubusercontent.com/joelburget/Cologne/60b22f44fc8c983c6a0c322fd9885d8f7e469840/Cologne/Shaders/Smallpaint.hs
haskell
This is a rewrite of smallpaint: / We use this data structure to generate a halton sequence, the same way as in the original smallpaint. for the time being assume i == 0 To compute the radiance of a ray shot into the scene we check to see if the ray intersects an object. If it misses all objects we return black, ...
# LANGUAGE FlexibleContexts # module Cologne.Shaders.Smallpaint ( smallpaint , Halton(Halton) , halton , next , hGet ) where import System.Random hiding (next) import Control.Monad.State import Control.Applicative ((<$>)) import Cologne.Vec import Cologne.Primitives hiding (intersect) data Halton = H...
b6bca37e76da6167e1e9a3ecb0c14cd52b8ab131befb6812ef29cb69a228d458
samrocketman/home
csepia_en.scm
cSepia v0.2 by ( Cakper ) This is a simple script for GIMP which allowing us do add a sepia effect to active layer . Script was written with using this tutorial : and working with GIMP 2.4 and erlier . Contact with autor : - email ; - Jabber Author is administrator of Polish GIMP Users Forum - www.gimpuj...
null
https://raw.githubusercontent.com/samrocketman/home/63a8668a71dc594ea9ed76ec56bf8ca43b2a86ca/dotfiles/.gimp/scripts/csepia_en.scm
scheme
- Jabber
cSepia v0.2 by ( Cakper ) This is a simple script for GIMP which allowing us do add a sepia effect to active layer . Script was written with using this tutorial : and working with GIMP 2.4 and erlier . Author is administrator of Polish GIMP Users Forum - www.gimpuj.info Come Us ! If have you any problems w...
c88d4f789cda90b06fcdd44f18cc2d56eade746cb877164521d63cbdcec1c49f
fumieval/webauthn
Common.hs
module WebAuthn.Common where import Control.Monad (unless) import Crypto.Random ( MonadRandom(..) ) import qualified Crypto.Random as Random import qualified Data.Aeson as AE import Data.Bifunctor (first) import Data.Text (Text) import Data.ByteString (ByteString) import qualified Data.ByteString.Lazy as BL import Dat...
null
https://raw.githubusercontent.com/fumieval/webauthn/46343b0afc0b57bd78546765139265f5b3142b5d/webauthn/src/WebAuthn/Common.hs
haskell
In order to prevent replay attacks, the challenges MUST contain enough entropy to make guessing them infeasible.
module WebAuthn.Common where import Control.Monad (unless) import Crypto.Random ( MonadRandom(..) ) import qualified Crypto.Random as Random import qualified Data.Aeson as AE import Data.Bifunctor (first) import Data.Text (Text) import Data.ByteString (ByteString) import qualified Data.ByteString.Lazy as BL import Dat...
5ee8e23159856a4c835578f111da4de8db75db8b0bccec7a47fcc40395b11194
BitGameEN/bitgamex
erlcloud_redshift.erl
-module(erlcloud_redshift). -include("erlcloud.hrl"). -include("erlcloud_aws.hrl"). -define(API_VERSION, "2012-12-01"). -export([configure/2, configure/3, new/2, new/3]). -export([describe_clusters/0, describe_clusters/1, describe_clusters/2]). -export([describe_clusters_all/0, describe_clusters_all/1, des...
null
https://raw.githubusercontent.com/BitGameEN/bitgamex/151ba70a481615379f9648581a5d459b503abe19/src/deps/erlcloud/src/erlcloud_redshift.erl
erlang
{cluster_security_groups, "ClusterSecurityGroups", }, Not supported as only EC2 classic
-module(erlcloud_redshift). -include("erlcloud.hrl"). -include("erlcloud_aws.hrl"). -define(API_VERSION, "2012-12-01"). -export([configure/2, configure/3, new/2, new/3]). -export([describe_clusters/0, describe_clusters/1, describe_clusters/2]). -export([describe_clusters_all/0, describe_clusters_all/1, des...
b5cd597dd8aa39a50cfc4c622f81a369435af8f823760cb52501edd010c809fd
GaloisInc/daedalus
Haskell.hs
# Language TemplateHaskell , ConstraintKinds , ImplicitParams # # Language RankNTypes , BlockArguments # module Daedalus.VM.Backend.Haskell ( compileModule , Config(..) , defaultConfig ) where import Data.Map(Map) import qualified Data.Map as Map import qualified Data.Text as Text import Data.Maybe(catMaybes) ...
null
https://raw.githubusercontent.com/GaloisInc/daedalus/0debe10b54da47379b4ee4d31076a1c60a6583f6/daedalus-vm/src/Daedalus/VM/Backend/Haskell.hs
haskell
| Make a function with the given list of arguments and result. ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ block arguments "...
# Language TemplateHaskell , ConstraintKinds , ImplicitParams # # Language RankNTypes , BlockArguments # module Daedalus.VM.Backend.Haskell ( compileModule , Config(..) , defaultConfig ) where import Data.Map(Map) import qualified Data.Map as Map import qualified Data.Text as Text import Data.Maybe(catMaybes) ...
da932ae887198c358e1334b89dabeb664f590f967309770c72ad7dbb6cdfba58
heroku/logplex
syslog_parser.erl
Heroku 2011 @author nt < > %% @version {@vsn}, {@date} {@time} @doc Re - entrant stream parser . %% @end -module(syslog_parser). -export([new/0, push/2]). -export([parse/1]). 10Kb max in a single log message . -record(buf, {bytes = <<>> :: binary(), waiting_for = unknown :: 'unknown' | ...
null
https://raw.githubusercontent.com/heroku/logplex/fc520c44cf4687726d5d51464d3264ddc6abb0ba/src/syslog_parser.erl
erlang
@version {@vsn}, {@date} {@time} @end a) <Length as ascii integer><space><msg:Length>" b) <msg>\n. randomly? #killmaimdestroy Haven't accumulated enough bytes to complete a parse yet. Can only be used at the beginning of a message. Will give bogus results otherwise. Finds the ascii encoded integer terminated b...
Heroku 2011 @author nt < > @doc Re - entrant stream parser . -module(syslog_parser). -export([new/0, push/2]). -export([parse/1]). 10Kb max in a single log message . -record(buf, {bytes = <<>> :: binary(), waiting_for = unknown :: 'unknown' | non_neg_integer()}). -opaque parse_buffer()...
f53a700a2d919976ab390bc1701ba780db90c9fceca1991087c2f5c4eea02359
ocaml-multicore/lockfree
backoff.mli
val bench_artificial : with_backoff:bool -> unit -> Benchmark_result.t val bench_basic : with_backoff:bool -> unit -> Benchmark_result.t
null
https://raw.githubusercontent.com/ocaml-multicore/lockfree/bf8f5000a6e802b4a21a6cfbf8ec8aa5208a8612/bench/backoff.mli
ocaml
val bench_artificial : with_backoff:bool -> unit -> Benchmark_result.t val bench_basic : with_backoff:bool -> unit -> Benchmark_result.t
4fbf2cfcc1519b1507dd3869999c7f389a692551fabd058db69ccc034f46fd91
WhatsApp/eqwalizer
type_trace_tests.erl
Copyright ( c ) Meta Platforms , Inc. and affiliates . All rights reserved . %%% This source code is licensed under the Apache 2.0 license found in %%% the LICENSE file in the root directory of this source tree. -module(type_trace_tests). -export([run/0]). -record(rec, {id :: integer(), name :: atom()}). run() -...
null
https://raw.githubusercontent.com/WhatsApp/eqwalizer/98437925c95e092eb6bc4522153f46582cad5ef0/eqwalizer/test_projects/dbg_trace/src/type_trace_tests.erl
erlang
the LICENSE file in the root directory of this source tree.
Copyright ( c ) Meta Platforms , Inc. and affiliates . All rights reserved . This source code is licensed under the Apache 2.0 license found in -module(type_trace_tests). -export([run/0]). -record(rec, {id :: integer(), name :: atom()}). run() -> none_err(), term_ok(), atom_lit_err1(), atom_lit_err2(), ...
acb954c7e5e67fbf092de9829d15c074747e57d20f586bc04381ea98bbe4cbb5
csabahruska/jhc-grin
IntBag.hs
# LANGUAGE CPP , NoBangPatterns , MagicHash # ----------------------------------------------------------------------------- -- | -- Module : Data.IntBag Copyright : ( c ) 2002 Copyright : ( c ) 2007 -- License : BSD-style -- Maintainer : -- Stability : provisional -- Portability : po...
null
https://raw.githubusercontent.com/csabahruska/jhc-grin/30210f659167e357c1ccc52284cf719cfa90d306/src/Util/IntBag.hs
haskell
--------------------------------------------------------------------------- | Module : Data.IntBag License : BSD-style Maintainer : Stability : provisional Portability : portable An efficient implementation of maps from integer keys to integers. * Map type * Operators , (\\) * Query ...
# LANGUAGE CPP , NoBangPatterns , MagicHash # Copyright : ( c ) 2002 Copyright : ( c ) 2007 modified from Data . IntMap module Util.IntBag ( instance Eq , Show , (!) , null , size , , empty , singleton , ms...
3d1beaa2cf955f18fddfc24976418e33438496c415113261e9d726b159b1e880
wardle/dmd
store_test.clj
(ns com.eldrix.dmd.store-test (:require [clojure.core.async :as a] [clojure.test :refer :all] [com.eldrix.dmd.core :as dmd] [clojure.java.io :as io] [com.eldrix.dmd.import :as dim] [datalevin.core :as d] [com.eldrix.dmd.store2 :as st2]) (:impor...
null
https://raw.githubusercontent.com/wardle/dmd/8ba2f9d1a0c4a363016be5034523b1f4b1239d94/test/src/com/eldrix/dmd/store_test.clj
clojure
ensure that importing an unknown ingredient throws an exception test basic import, store and fetch across products. are we getting linked relationships right? test from VTM ; test from AMPP
(ns com.eldrix.dmd.store-test (:require [clojure.core.async :as a] [clojure.test :refer :all] [com.eldrix.dmd.core :as dmd] [clojure.java.io :as io] [com.eldrix.dmd.import :as dim] [datalevin.core :as d] [com.eldrix.dmd.store2 :as st2]) (:impor...
bdbfc35b0f2862eb6064b70a1778d02a02d8f924f7a4376e566455b35518de75
Engelberg/instaparse
specs.cljc
(ns instaparse.specs) (def cfg1 "S = 'a'") (def cfg2 "S = X X = Y Y = Z") (def cfg3 "S = X | Y Y = A Z Z = 'a'") (def cfg4 "S := A B | C C := (A | B) C") (def cfg5 "S=A?") (def cfg6 "S =(A | B)?") (def cfg7 "S = A, B?, (C C)*, D+, E") (def cfg8 "<S> = <A B?> (C | D)") (def cfg9 "S = A, ...
null
https://raw.githubusercontent.com/Engelberg/instaparse/4d1903b059e77dc0049dfbc75af9dce995756148/test/instaparse/specs.cljc
clojure
(ns instaparse.specs) (def cfg1 "S = 'a'") (def cfg2 "S = X X = Y Y = Z") (def cfg3 "S = X | Y Y = A Z Z = 'a'") (def cfg4 "S := A B | C C := (A | B) C") (def cfg5 "S=A?") (def cfg6 "S =(A | B)?") (def cfg7 "S = A, B?, (C C)*, D+, E") (def cfg8 "<S> = <A B?> (C | D)") (def cfg9 "S = A, ...
5805f3825376d247cfdb8c5bac9151f43e09d4efe63f16db54c5250dc7077b2f
callum-oakley/advent-of-code
14.clj
(ns aoc.2019.14 (:require [clojure.math :as math] [clojure.string :as str] [clojure.test :refer [deftest are]])) (defn parse [s] (->> s str/split-lines (map #(map read-string (reverse (re-seq #"[0-9A-Z]+" %)))) (reduce (fn [reactions [product quantity & reactants]] (assoc re...
null
https://raw.githubusercontent.com/callum-oakley/advent-of-code/16a98d33fd8158a1b4f00776e74ead3242519833/src/aoc/2019/14.clj
clojure
able to make ~2M FUEL. Our cost function tells us that in fact 2M FUEL only for a binary search.
(ns aoc.2019.14 (:require [clojure.math :as math] [clojure.string :as str] [clojure.test :refer [deftest are]])) (defn parse [s] (->> s str/split-lines (map #(map read-string (reverse (re-seq #"[0-9A-Z]+" %)))) (reduce (fn [reactions [product quantity & reactants]] (assoc re...
d6812574ba271350131951639f7036472e086b5bf299ad5ce1ae42d080773d75
erlyvideo/publisher
rtsp_reader.erl
-module(rtsp_reader). -author('Max Lapshin <>'). -include("log.hrl"). -include_lib("erlmedia/include/video_frame.hrl"). -include_lib("erlmedia/include/media_info.hrl"). -include_lib("erlmedia/include/sdp.hrl"). -export([start_link/2, media_info/1]). -export([init/1, handle_info/2, handle_call/3, terminate/2]). sta...
null
https://raw.githubusercontent.com/erlyvideo/publisher/5bb2dfa6477c46160dc5fafcc030fc3f5340ec80/apps/rtsp/src/rtsp_reader.erl
erlang
{_HostPort, Path} = http_uri2:extract_path_with_query(URL), erlang:send_after(5000, self(), teardown), Here we must handle important case when Content-Base is given with local network
-module(rtsp_reader). -author('Max Lapshin <>'). -include("log.hrl"). -include_lib("erlmedia/include/video_frame.hrl"). -include_lib("erlmedia/include/media_info.hrl"). -include_lib("erlmedia/include/sdp.hrl"). -export([start_link/2, media_info/1]). -export([init/1, handle_info/2, handle_call/3, terminate/2]). sta...
6fca32fb37df78716c2092150358867ca92e2238b57f596535f58829251bd79f
district0x/re-frame-spec-interceptors
spec_interceptors.cljs
(ns district0x.re-frame.spec-interceptors (:require [cljs.spec.alpha :as s] [re-frame.core :as re-frame :refer [console]])) (defn throw-event-error [event untrimmed-event spec] (throw (js/Error. (str "Invalid input into event" (or untrimmed-event event) "\n" (s/explain-str spec event))))) (defn validate-...
null
https://raw.githubusercontent.com/district0x/re-frame-spec-interceptors/4f906a6563956dc6cb419c8ccb7751c78f896931/src/district0x/re_frame/spec_interceptors.cljs
clojure
(ns district0x.re-frame.spec-interceptors (:require [cljs.spec.alpha :as s] [re-frame.core :as re-frame :refer [console]])) (defn throw-event-error [event untrimmed-event spec] (throw (js/Error. (str "Invalid input into event" (or untrimmed-event event) "\n" (s/explain-str spec event))))) (defn validate-...
cddcc91b9c02d9ee75b0d607ac89e211791b1fbdb11b3b8e184d5ce02dee1594
commercialhaskell/stack
Main.hs
import Control.Concurrent import StackTest import System.Directory (createDirectoryIfMissing, getCurrentDirectory) import System.Environment (getEnv, setEnv) import System.FilePath ((</>)) import System.Process main...
null
https://raw.githubusercontent.com/commercialhaskell/stack/255cd830627870cdef34b5e54d670ef07882523e/test/integration/tests/upload/Main.hs
haskell
Ensure there are credentials available for uploading | Start a fake Hackage server to test the upload Build the dependencies for the fake server Start the fake server Wait for the fake server to start accepting requests
import Control.Concurrent import StackTest import System.Directory (createDirectoryIfMissing, getCurrentDirectory) import System.Environment (getEnv, setEnv) import System.FilePath ((</>)) import System.Process main...
80de86ddbe93e24d6599add8c35ea7be8b646d88f7040225bb9ef2eacda4913d
inaka/lsl
lsl_test_utils.erl
%% @doc General Test Utils -module(lsl_test_utils). -type config() :: proplists:proplist(). -type response() :: shotgun:response(). -export_type([config/0]). -export([ all/1 , init_per_suite/1 , end_per_suite/1 ]). -export([ api_call/2 , api_call/3 , api_call/4 ]). -e...
null
https://raw.githubusercontent.com/inaka/lsl/fdb5690fa51bc2f7fe8b50a22caca78fd9d8a7a5/test/lsl_test_utils.erl
erlang
@doc General Test Utils
-module(lsl_test_utils). -type config() :: proplists:proplist(). -type response() :: shotgun:response(). -export_type([config/0]). -export([ all/1 , init_per_suite/1 , end_per_suite/1 ]). -export([ api_call/2 , api_call/3 , api_call/4 ]). -export([ register_player/1 ...
24883d6f55b627b7f5b34af2c7305259770bc8d7f539be65ebb3b8ef91f28645
UnixJunkie/consent
node.ml
open Printf module IntSet = BatSet.Int atom 's MOL2 type succs: IntSet.t } (* indexes of its direct successors (it is bonded to them) *) let create typ succs = { typ; succs } let dummy = create "" IntSet.empty let add_succ (n: t) (succ: int): t = create n.typ (IntSet.add succ n.succs) let to_stri...
null
https://raw.githubusercontent.com/UnixJunkie/consent/f065ee7ba5a1ae014b5c3a28d0985ba5ad1abda5/src/node.ml
ocaml
indexes of its direct successors (it is bonded to them)
open Printf module IntSet = BatSet.Int atom 's MOL2 type let create typ succs = { typ; succs } let dummy = create "" IntSet.empty let add_succ (n: t) (succ: int): t = create n.typ (IntSet.add succ n.succs) let to_string (n: t): string = sprintf "%s %s" n.typ (MyList.to_string string_of_int (IntSet.to_list...
bfec5bdb72890155c3ce053319ac1b70b99e3b4467ffa342b76f8379e7d9b851
mbutterick/brag
test-simple-line-drawing.rkt
#lang racket/base (require brag/examples/simple-line-drawing brag/support racket/list br-parser-tools/lex (prefix-in : br-parser-tools/lex-sre) rackunit) (define (make-tokenizer ip) (port-count-lines! ip) (define lex (lexer-src-pos [(:+ numeric) ...
null
https://raw.githubusercontent.com/mbutterick/brag/6c161ae31df9b4ae7f55a14f754c0b216b60c9a6/brag-lib/brag/test/test-simple-line-drawing.rkt
racket
Does the rule name "drawing" also have the proper "original?" property set? FIXME: add tests to make sure location is as we expect. token.
#lang racket/base (require brag/examples/simple-line-drawing brag/support racket/list br-parser-tools/lex (prefix-in : br-parser-tools/lex-sre) rackunit) (define (make-tokenizer ip) (port-count-lines! ip) (define lex (lexer-src-pos [(:+ numeric) ...
b0702b5fa6e64fb01ce31abe645baa95fedadc381f9de2517ce21744674d6a46
janegca/htdp2e
Exercise-224-AbstractingListSortFns.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-intermediate-reader.ss" "lang")((modname Exercise-224-AbstractingFnSigs) (read-case-sensitive #t) (teachpacks ((lib "image.rkt" "teachpack...
null
https://raw.githubusercontent.com/janegca/htdp2e/2d50378135edc2b8b1816204021f8763f8b2707b/03-Abstractions/Exercise-224-AbstractingListSortFns.rkt
racket
about the language level of this file in a form that our tools can easily process. sort-n, which consumes a list of numbers and a function that consumes sort - n produces a sorted list of numbers. sort-s, which consumes a list of strings and a function that consumes sort - s produces a sorted li...
The first three lines of this file were inserted by . They record metadata #reader(lib "htdp-intermediate-reader.ss" "lang")((modname Exercise-224-AbstractingFnSigs) (read-case-sensitive #t) (teachpacks ((lib "image.rkt" "teachpack" "2htdp"))) (htdp-settings #(#t constructor repeating-decimal #f #t none #f ((lib "im...
5c0bd98731ab1920702b58381f650370070212a51ef87b18dcc6fdb77b5829bb
ftomassetti/civs
history.clj
(ns ^{:author ftomassetti} civs.model.history) # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # ; Turns # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # (defn n-turns [history] (.size (keys (:facts history)))) (defn turns ([history] (sort (key...
null
https://raw.githubusercontent.com/ftomassetti/civs/dc76bfff4241f67d4bc1081de3947a725ea75c39/src/civs/model/history.clj
clojure
Turns
(ns ^{:author ftomassetti} civs.model.history) # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # (defn n-turns [history] (.size (keys (:facts history)))) (defn turns ([history] (sort (keys (:game...
0d3e73aa60c19a19ea3449554494b67329b679b5fd9f6e46a8b2c4bb0b1e8c5e
coq/coq
cList.mli
(************************************************************************) (* * The Coq Proof Assistant / The Coq Development Team *) v * Copyright INRIA , CNRS and contributors < O _ _ _ , , * ( see version control and CREDITS file for authors & dates ) \VV/ * * *...
null
https://raw.githubusercontent.com/coq/coq/284b7133ff792dab82c658a274db0c5e0a04d2d5/clib/cList.mli
ocaml
********************************************************************** * The Coq Proof Assistant / The Coq Development Team // * This file is distributed under the terms of the * (see LICENSE file for the text of the license) ************************************...
v * Copyright INRIA , CNRS and contributors < O _ _ _ , , * ( see version control and CREDITS file for authors & dates ) \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * GNU Lesser Gener...
5238a1bc7d25ace3155f8d8f5892d91b6fe93007c24b50852b8504535f1a8bd6
arohner/spectrum
multi_method_bad_return.clj
(ns spectrum.examples.bad.multi-method-bad-return (:require [clojure.spec.alpha :as s])) (s/fdef foo :args (s/cat :x any?) :ret string?) (defmulti foo class) (defmethod foo Number [x] "correct") (defmethod foo String [x] :bogus)
null
https://raw.githubusercontent.com/arohner/spectrum/72b47a91a5ce4567eed547507d25b2528f48c2d1/test/spectrum/examples/bad/multi_method_bad_return.clj
clojure
(ns spectrum.examples.bad.multi-method-bad-return (:require [clojure.spec.alpha :as s])) (s/fdef foo :args (s/cat :x any?) :ret string?) (defmulti foo class) (defmethod foo Number [x] "correct") (defmethod foo String [x] :bogus)
30c00ab25847414511d00dba69744470da024b3cc237ec72b3cd11820eecb34d
pixlsus/registry.gimp.org_static
index-palette-area.scm
; index-palette-area.scm ; ; A trio of palette and colormap tools designed for pixelart use. - Convert an indexed colormap to a GIMP palette ; - Create a GIMP palette based on a selected area - Convert to indexed colors using a selected area as the colormap Copyright ( C ) 2008 " Stratadrake ...
null
https://raw.githubusercontent.com/pixlsus/registry.gimp.org_static/ffcde7400f402728373ff6579947c6ffe87d1a5e/registry.gimp.org/files/index-palette-area.scm
scheme
A trio of palette and colormap tools designed for pixelart use. - Create a GIMP palette based on a selected area This program is free software; you can redistribute it and/or modify either version 2 of the License , or (at your option) any later version. This program is distributed in th...
index-palette-area.scm - Convert an indexed colormap to a GIMP palette - Convert to indexed colors using a selected area as the colormap Copyright ( C ) 2008 " Stratadrake " , Version 0.0 07 - 21 - 2008 Written in GIMP 2.4.4 it under the terms of the GNU General Public License as publi...
9294e1e7e5462966149d38eeace59b5d32230761fd2aefd3d48769c1b6c0f6ca
emqx/emqx
emqx_sn_broadcast.erl
%%-------------------------------------------------------------------- Copyright ( c ) 2020 - 2023 EMQ Technologies Co. , Ltd. All Rights Reserved . %% 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 o...
null
https://raw.githubusercontent.com/emqx/emqx/dbc10c2eed3df314586c7b9ac6292083204f1f68/apps/emqx_gateway/src/mqttsn/emqx_sn_broadcast.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 ...
Copyright ( c ) 2020 - 2023 EMQ Technologies Co. , Ltd. All Rights Reserved . Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(emqx_sn_broadcast). -behaviour(gen_server). -ifdef(TEST). -include_lib("emqx_gateway/s...
52e6887225283a28f34dc02806824ac7d8f54770e670e328fabea25b2da162dd
varjagg/cl-video
cl-video.lisp
Generic definitions for video / audio decoding ( c ) 2017 < > (in-package #:cl-video) (setf *print-circle* t) (defvar *debug* nil) (defun debug-log (string) (when *debug* (format t "~A~%" string) (finish-output))) (define-condition media-decoder-error (error) ()) (define-condition unrecognized-...
null
https://raw.githubusercontent.com/varjagg/cl-video/eb5fbea3592b74cdb0458b7bcdeb70f0423a8183/cl-video.lisp
lisp
called once all headers are processed
Generic definitions for video / audio decoding ( c ) 2017 < > (in-package #:cl-video) (setf *print-circle* t) (defvar *debug* nil) (defun debug-log (string) (when *debug* (format t "~A~%" string) (finish-output))) (define-condition media-decoder-error (error) ()) (define-condition unrecognized-...
69d026fe73c99b69dbff49b0f879709f25345bb6cc984875adee2a409fccca3b
huangz1990/SICP-answers
38-fold-right.scm
38-fold-right.scm (load "p78-accumulate.scm") (define fold-right accumulate)
null
https://raw.githubusercontent.com/huangz1990/SICP-answers/15e3475003ef10eb738cf93c1932277bc56bacbe/chp2/code/38-fold-right.scm
scheme
38-fold-right.scm (load "p78-accumulate.scm") (define fold-right accumulate)
9cbb3bfaa57b617d4917dc0c5251a307d35b29e777cc3e4e4b16a862f09425f1
athensresearch/athens
coeffects.cljs
(ns athens.coeffects (:require [athens.util :as util] [re-frame.core :as rf])) (rf/reg-cofx :local-storage (fn [coeffects k] (assoc coeffects :local-storage (util/local-storage-get (str k)))))
null
https://raw.githubusercontent.com/athensresearch/athens/35a6e086b017d38e30f0023330174baa0b8b784e/src/cljs/athens/coeffects.cljs
clojure
(ns athens.coeffects (:require [athens.util :as util] [re-frame.core :as rf])) (rf/reg-cofx :local-storage (fn [coeffects k] (assoc coeffects :local-storage (util/local-storage-get (str k)))))
8dfc8cb305bf5baf3ae4b8d5958cc6cace8989ac780e5fd6e29fa6dd73c8f703
profmaad/bitcaml
bitcoin_blockchain_blockstorage.ml
open! Core.Std open Bitcoin_protocol;; let folder_levels = 2;; type t = { root_path : string; folder_levels : int; };; let check_random_folder storage = let path = String.concat ~sep:"/" (storage.root_path :: (List.map ~f:(Printf.sprintf "%02x") (Utils.random_list 255 storage.folder_levels))) in try let...
null
https://raw.githubusercontent.com/profmaad/bitcaml/18cfbca46c989f43dfb1bcfd50ee2ff500f9ab8d/src/bitcoin_blockchain_blockstorage.ml
ocaml
open! Core.Std open Bitcoin_protocol;; let folder_levels = 2;; type t = { root_path : string; folder_levels : int; };; let check_random_folder storage = let path = String.concat ~sep:"/" (storage.root_path :: (List.map ~f:(Printf.sprintf "%02x") (Utils.random_list 255 storage.folder_levels))) in try let...
68d807bb8195ef89269271d3920314640e5b748e2b27b90696189db1734e533f
haskell-game/tiny-games-hs
Import.hs
module Import ( module Graphics.Gloss.Interface.Pure.Game , module Data.Bits , module Control.Monad , module Data.Bool ) where import Graphics.Gloss.Interface.Pure.Game import Data.Bits (xor) import Control.Monad(join) import Data.Bool
null
https://raw.githubusercontent.com/haskell-game/tiny-games-hs/6910b6fe4a5c88ac0cd2a32f5faba5b655a70ab0/hackage/subpar-hexagon/Import.hs
haskell
module Import ( module Graphics.Gloss.Interface.Pure.Game , module Data.Bits , module Control.Monad , module Data.Bool ) where import Graphics.Gloss.Interface.Pure.Game import Data.Bits (xor) import Control.Monad(join) import Data.Bool
5523ab3fb8b8373d64e498f39f31c7d653a276e44cc60d881f02563a1f8f4dc6
spawnfest/eep49ers
xref_utils.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 2000 - 2017 . All Rights Reserved . %% 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 applicab...
null
https://raw.githubusercontent.com/spawnfest/eep49ers/d1020fd625a0bbda8ab01caf0e1738eb1cf74886/lib/tools/src/xref_utils.erl
erlang
%CopyrightBegin% 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 lan...
Copyright Ericsson AB 2000 - 2017 . All Rights Reserved . Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(xref_utils). Avoid warning for local function error/1 clashing with autoimported BIF . -compile({no_auto_i...
8d65e345984279d86514567c0eaaf7b95f52e86202a8128f99c80f85ade3aff2
clojure-interop/aws-api
AmazonWorkMailClientBuilder.clj
(ns com.amazonaws.services.workmail.AmazonWorkMailClientBuilder "Fluent builder for AmazonWorkMail. Use of the builder is preferred over using constructors of the client class." (:refer-clojure :only [require comment defn ->]) (:import [com.amazonaws.services.workmail AmazonWorkMailClientBuilder])) (defn *stan...
null
https://raw.githubusercontent.com/clojure-interop/aws-api/59249b43d3bfaff0a79f5f4f8b7bc22518a3bf14/com.amazonaws.services.workmail/src/com/amazonaws/services/workmail/AmazonWorkMailClientBuilder.clj
clojure
(ns com.amazonaws.services.workmail.AmazonWorkMailClientBuilder "Fluent builder for AmazonWorkMail. Use of the builder is preferred over using constructors of the client class." (:refer-clojure :only [require comment defn ->]) (:import [com.amazonaws.services.workmail AmazonWorkMailClientBuilder])) (defn *stan...
e4d934fc56526f538a0595bad2e6b5345a74a77a7928b389b4b423a5ff0083a1
bitnomial/prometheus
Histogram.hs
{-# LANGUAGE OverloadedStrings #-} module System.Metrics.Prometheus.Encode.Text.Histogram ( encodeHistogram, ) where import Data.ByteString.Builder (Builder) import Data.List (intersperse) import qualified Data.Map as Map import Data.Monoid ((<>)) import System.Metrics.Prometheus.Encode.Text.MetricId ( encod...
null
https://raw.githubusercontent.com/bitnomial/prometheus/b7d3160e2a4d971fe03bef6b43fe8bf15a9c9349/src/System/Metrics/Prometheus/Encode/Text/Histogram.hs
haskell
# LANGUAGE OverloadedStrings #
module System.Metrics.Prometheus.Encode.Text.Histogram ( encodeHistogram, ) where import Data.ByteString.Builder (Builder) import Data.List (intersperse) import qualified Data.Map as Map import Data.Monoid ((<>)) import System.Metrics.Prometheus.Encode.Text.MetricId ( encodeDouble, encodeInt, encodeL...
84a01305509ddd82b4733f8c1e304ec05e33d28cfc7b571bb9fad7eb6abc7c78
tisnik/clojure-examples
core.clj
; ( C ) Copyright 2015 , 2020 ; ; All rights reserved. This program and the accompanying materials ; are made available under the terms of the Eclipse Public License v1.0 ; which accompanies this distribution, and is available at -v10.html ; ; Contributors: ; (ns seesaw2.core (:gen-class)) ...
null
https://raw.githubusercontent.com/tisnik/clojure-examples/984af4a3e20d994b4f4989678ee1330e409fdae3/seesaw2/src/seesaw2/core.clj
clojure
All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at Contributors:
( C ) Copyright 2015 , 2020 -v10.html (ns seesaw2.core (:gen-class)) (use 'seesaw.core) (defn -main [& args] (let [main-frame (frame :title "Hello world!") btn (button :text "Click Me")] (-> main-frame (config! :content btn) (pack!...
724911583d9c24abca56ef43fef93b7f537489bec47057f477b0f75181539471
Commonfare-net/macao-social-wallet
tag.clj
Freecoin - digital social currency toolkit part of Decentralized Citizen Engagement Technologies ( D - CENT ) R&D funded by the European Commission ( FP7 / CAPS 610349 ) Copyright ( C ) 2016 Dyne.org foundation designed , written and maintained by < > < > ;; This program is free software: you c...
null
https://raw.githubusercontent.com/Commonfare-net/macao-social-wallet/d3724d6c706cdaa669c59da439fe48b0373e17b7/src/freecoin/views/tag.clj
clojure
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 Affero General P...
Freecoin - digital social currency toolkit part of Decentralized Citizen Engagement Technologies ( D - CENT ) R&D funded by the European Commission ( FP7 / CAPS 610349 ) Copyright ( C ) 2016 Dyne.org foundation designed , written and maintained by < > < > it under the terms of the GNU Affero ...
3cdeb828627eac35d2148cd0be823dba8f4e3f0589bc5f7173814490612208e5
danr/hipspec
InsertionSort.hs
module InsertionSort where import Hip.Prelude import Prelude (Eq,Ord,Show,iterate,(!!),fmap,Bool(..)) data Nat = Z | S Nat deriving (Eq,Ord,Show) instance Arbitrary Nat where arbitrary = let nats = iterate S Z in (nats !!) `fmap` choose (0,25) -- Insertion sort for natural numbers ---------------------...
null
https://raw.githubusercontent.com/danr/hipspec/a114db84abd5fee8ce0b026abc5380da11147aa9/examples/old-examples/hip/InsertionSort.hs
haskell
Insertion sort for natural numbers ----------------------------------------- ---------------------------------------------- Tests ----------------------------------------------------------------------
module InsertionSort where import Hip.Prelude import Prelude (Eq,Ord,Show,iterate,(!!),fmap,Bool(..)) data Nat = Z | S Nat deriving (Eq,Ord,Show) instance Arbitrary Nat where arbitrary = let nats = iterate S Z in (nats !!) `fmap` choose (0,25) Z == Z = True Z == _ = False (S _) == Z ...
793cb0d4119c5b68d34ceba3b8aaac9454e9a6b8290b18fb38fa2737f1694130
mpickering/apply-refact
Default89.hs
test = map (not . not) xs
null
https://raw.githubusercontent.com/mpickering/apply-refact/a4343ea0f4f9d8c2e16d6b16b9068f321ba4f272/tests/examples/Default89.hs
haskell
test = map (not . not) xs
02a769f99da08e5fc5f54118b394a2c93f394a9eeac979a8172ab87e5a454ffe
fccm/glMLite
genimg_loader.ml
(** Generic image loader *) * This module uses the ImageMagick library , which can read a lot of different images file formats . The complete list of these is available on { { : }this web - page } . If the image to load is known to be a jpeg or a png , you should use the specialised modules [ ...
null
https://raw.githubusercontent.com/fccm/glMLite/c52cd806909581e49d9b660195576c8a932f6d33/SRC/genimg_loader.ml
ocaml
* Generic image loader type image_type = | Undefined_image_type | Bilevel (** Monochrome image * Grayscale image with an alpha channel * Indexed colors * Indexed colors + Alpha * RGB * RGBA * Cyan/Yellow/Magenta/Black (CYMK) * CYMK + Alpha
* This module uses the ImageMagick library , which can read a lot of different images file formats . The complete list of these is available on { { : }this web - page } . If the image to load is known to be a jpeg or a png , you should use the specialised modules [ Jpeg_loader ] , [ Png_loader...
24ecf94bd9ff62bfa26839234d09f218a8757d805e5e94116c9232e41a136353
weblocks-framework/weblocks
image.lisp
(in-package :weblocks-test) ;;; Test image-presentation render-view-field-value (deftest-html image-presentation-1 (render-view-field-value "www.hello.com" (make-instance 'image-presentation) (make-instance 'data-view-field ...
null
https://raw.githubusercontent.com/weblocks-framework/weblocks/fe96152458c8eb54d74751b3201db42dafe1708b/test/views/types/presentations/image.lisp
lisp
Test image-presentation render-view-field-value
(in-package :weblocks-test) (deftest-html image-presentation-1 (render-view-field-value "www.hello.com" (make-instance 'image-presentation) (make-instance 'data-view-field :slot-name 'foo) ...
8c2c37816046e2a53818598354ae903783e6254aaf8d5f6053773f09c631d274
vraid/earthgen
humidity.rkt
#lang typed/racket (provide (all-defined-out)) (require math/flonum "temperature.rkt") (: saturation-humidity (Float -> Float)) (define (saturation-humidity temperature) (* 4.6e-9 (flexp (* 0.05174 temperature)))) (: relative-humidity (Float Float -> Float)) (define (relative-humidity temperature hu...
null
https://raw.githubusercontent.com/vraid/earthgen/208ac834c02208ddc16a31aa9e7ff7f91c18e046/planet/climate/humidity.rkt
racket
#lang typed/racket (provide (all-defined-out)) (require math/flonum "temperature.rkt") (: saturation-humidity (Float -> Float)) (define (saturation-humidity temperature) (* 4.6e-9 (flexp (* 0.05174 temperature)))) (: relative-humidity (Float Float -> Float)) (define (relative-humidity temperature hu...
094fd72b672d1830619621d616eadb5c6b022538f45bd917b7aeb1e1b96fb503
matterhorn-chat/matterhorn
ManageAttachments.hs
# LANGUAGE LambdaCase # # LANGUAGE ScopedTypeVariables # {-# LANGUAGE RankNTypes #-} module Matterhorn.Events.ManageAttachments ( onEventAttachmentList , onEventBrowseFile , attachmentListKeybindings , attachmentBrowseKeyHandlers , attachmentBrowseKeybindings , attachmentListKeyHandlers ) where import ...
null
https://raw.githubusercontent.com/matterhorn-chat/matterhorn/19a73ce833a8a8de3616cf884c03e9f08a4db0a7/src/Matterhorn/Events/ManageAttachments.hs
haskell
# LANGUAGE RankNTypes # The widget has not been created yet. This should This could therefore be implemented as an `error "BUG: ..."` handler, but the more benign approach is to TODO: Check file browser exception state
# LANGUAGE LambdaCase # # LANGUAGE ScopedTypeVariables # module Matterhorn.Events.ManageAttachments ( onEventAttachmentList , onEventBrowseFile , attachmentListKeybindings , attachmentBrowseKeyHandlers , attachmentBrowseKeybindings , attachmentListKeyHandlers ) where import Prelude () import ...
4b73dba8477b232a81bd68f334b7d96e696d0c55cd4b9381680bd52eed35140e
shaneutt/erlang_notebook
erlang_notebook_api_app.erl
-module('erlang_notebook_api_app'). -behaviour(application). -export([start/2, stop/1]). %%==================================================================== %% API %%==================================================================== start(_StartType, _StartArgs) -> {ok, Pid} = erlang_notebook_api_sup:start_lin...
null
https://raw.githubusercontent.com/shaneutt/erlang_notebook/b4f291db2d1b2711569e275fed09446fcc1ffb66/apps/erlang_notebook_api/src/erlang_notebook_api_app.erl
erlang
==================================================================== API ==================================================================== {ok, _} = erlang_notebook_api_cache:init(), ==================================================================== ==============================================================...
-module('erlang_notebook_api_app'). -behaviour(application). -export([start/2, stop/1]). start(_StartType, _StartArgs) -> {ok, Pid} = erlang_notebook_api_sup:start_link(), {ok, Pid}. stop(_State) -> ok. Internal functions cowboy_start() -> Dispatch = cowboy_router:compile([ {'_', [ {"/", ...
20ca2f6810e802cbe84d674a4922ab77af9de036a18df82b5e71ae856804603f
ekoontz/menard
server.clj
(ns server (:require [clojure.tools.logging :as log] [clojure.data.json :as json :refer [write-str]] [clojure.java.io :as io :refer [resource]] [config.core :refer [env]] [menard.exception :refer [exception]] [menard.handlers :as handlers] [menard.english.complete :as en-complete] [menard.engl...
null
https://raw.githubusercontent.com/ekoontz/menard/f980507dc7808938c1bff5de0e0e12afeb5f1661/server/src/server.clj
clojure
TODO: check model config files rather than <path> <filename-pattern>:
(ns server (:require [clojure.tools.logging :as log] [clojure.data.json :as json :refer [write-str]] [clojure.java.io :as io :refer [resource]] [config.core :refer [env]] [menard.exception :refer [exception]] [menard.handlers :as handlers] [menard.english.complete :as en-complete] [menard.engl...
ba546f341f6e676b4670e264281fef2b75d44bfa64c5333fe06471d42468883f
kazu-yamamoto/http2
Encode.hs
# LANGUAGE RecordWildCards # {-# LANGUAGE OverloadedStrings #-} module Network.HPACK.HeaderBlock.Encode ( encodeHeader , encodeTokenHeader , encodeString , encodeS ) where import Control.Exception (bracket, throwIO) import qualified Control.Exception as E import qualified Data.ByteString as BS import Data...
null
https://raw.githubusercontent.com/kazu-yamamoto/http2/3c29763be147a3d482eff28f427ad80f1d4df706/Network/HPACK/HeaderBlock/Encode.hs
haskell
# LANGUAGE OverloadedStrings # -------------------------------------------------------------- -------------------------------------------------------------- This function has overhead of allocating/freeing a temporary buffer. 'BufferOverrun' will be thrown if the temporary buffer is too small. ^ The size of a te...
# LANGUAGE RecordWildCards # module Network.HPACK.HeaderBlock.Encode ( encodeHeader , encodeTokenHeader , encodeString , encodeS ) where import Control.Exception (bracket, throwIO) import qualified Control.Exception as E import qualified Data.ByteString as BS import Data.ByteString.Internal (create, memcp...
5f7f30b517740d24b1d46caf02047d4706a2fbfcc32738cf3715a5da6ead8677
ksrky/Plato
Eval.hs
module Plato.Test.Core.Eval where import Plato.Core.Context import Plato.Core.Eval import Plato.Syntax.Core import Plato.Transl.PsToTyp import Plato.Transl.SrcToPs import Plato.Transl.TypToCore import Plato.Types.Location import Plato.Types.Monad import Plato.Types.Name.Global import Control.Exception.Safe import Con...
null
https://raw.githubusercontent.com/ksrky/Plato/02b1a043efa92cf2093ff7d721a607d8abe9d876/test/Plato/Test/Core/Eval.hs
haskell
module Plato.Test.Core.Eval where import Plato.Core.Context import Plato.Core.Eval import Plato.Syntax.Core import Plato.Transl.PsToTyp import Plato.Transl.SrcToPs import Plato.Transl.TypToCore import Plato.Types.Location import Plato.Types.Monad import Plato.Types.Name.Global import Control.Exception.Safe import Con...
8ce6f146c0b248d407906f4556126a69cc09bd481609af29bef11613b921760a
pavankumarbn/DroneGUIROS
_package_navdata_trims.lisp
(cl:in-package ardrone_autonomy-msg) (cl:export '(HEADER-VAL HEADER DRONE_TIME-VAL DRONE_TIME TAG-VAL TAG SIZE-VAL SIZE ANGULAR_RATES_TRIM_R-VAL ANGULAR_RATES_TRIM_R EULER_ANGLES_TRIM_THETA-VAL EULER_ANGLES_TRI...
null
https://raw.githubusercontent.com/pavankumarbn/DroneGUIROS/745320d73035bc50ac4fea2699e22586e10be800/devel/share/common-lisp/ros/ardrone_autonomy/msg/_package_navdata_trims.lisp
lisp
(cl:in-package ardrone_autonomy-msg) (cl:export '(HEADER-VAL HEADER DRONE_TIME-VAL DRONE_TIME TAG-VAL TAG SIZE-VAL SIZE ANGULAR_RATES_TRIM_R-VAL ANGULAR_RATES_TRIM_R EULER_ANGLES_TRIM_THETA-VAL EULER_ANGLES_TRI...
67ad44e25d5b7d88dc8854c98b805259a1b7c9f174a2082277e72ad2c1b035bc
e-bigmoon/haskell-blog
Sample2.hs
#!/usr/bin/env stack stack script --resolver lts-12.7 data Person = Person { personName :: String , personAge :: Int } deriving Show f :: Person f = Person { personName = "bigmoon" }
null
https://raw.githubusercontent.com/e-bigmoon/haskell-blog/5c9e7c25f31ea6856c5d333e8e991dbceab21c56/sample-code/2018/08-26/Sample2.hs
haskell
resolver lts-12.7
#!/usr/bin/env stack data Person = Person { personName :: String , personAge :: Int } deriving Show f :: Person f = Person { personName = "bigmoon" }
1856d819c0d3fec368c74a6490acecf766321bb72ce32730c1098500fdbeaffc
mstksg/servant-validate
Validate.hs
# LANGUAGE AllowAmbiguousTypes # # LANGUAGE BangPatterns # {-# LANGUAGE DataKinds #-} {-# LANGUAGE FlexibleContexts #-} # LANGUAGE FlexibleInstances # # LANGUAGE GADTs # {-# LANGUAGE LambdaCase #-} # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE PatternSyno...
null
https://raw.githubusercontent.com/mstksg/servant-validate/2e24ec7ed8ffa469fc1fd753beb15532256f7ecf/src/Servant/Validate.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # # LANGUAGE LambdaCase # # LANGUAGE PatternSynonyms # # LANGUAGE RankNTypes # # LANGUAGE ScopedTypeVariables # # LANGUAGE StandaloneDeriving # # LANGUAGE TypeOperators # | Module : Servant.Validate Lice...
# LANGUAGE AllowAmbiguousTypes # # LANGUAGE BangPatterns # # LANGUAGE FlexibleInstances # # LANGUAGE GADTs # # LANGUAGE MultiParamTypeClasses # # LANGUAGE PolyKinds # # LANGUAGE QuantifiedConstraints # # LANGUAGE TypeApplications # # LANGUAGE TypeFamilies ...
8b3257ac9eb3de6980273d488a14aad8648c5b047fae0979925dc5fa5ebdb646
GillianPlatform/Gillian
ppx_sat_expander.mli
open Ppxlib module Extension_name : sig type t = Sat | Ent val to_string : t -> string end val expand : ext:Extension_name.t -> expression -> expression
null
https://raw.githubusercontent.com/GillianPlatform/Gillian/12f0d50bb3c407bfbce34cc5c08f5d60c71466be/ppx_sat/expander/ppx_sat_expander.mli
ocaml
open Ppxlib module Extension_name : sig type t = Sat | Ent val to_string : t -> string end val expand : ext:Extension_name.t -> expression -> expression
9fe73c1bdd388a89cae9b8728603b094c1fab41d347b20633bfe2841788df16d
tlipski/clojure-webapps
db.clj
(ns project1.db (:require [korma.db :as korma-db] [korma.core :as korma])) (def postgresql-db {:classname "org.postgresql.Driver" :subprotocol "postgresql" :subname "//localhost:5432/clojure_blog" :user "clojure_blog" :password "clojure"}) (korma-db/defdb korma-pool postgresql-db) (korma/...
null
https://raw.githubusercontent.com/tlipski/clojure-webapps/6b02ec80048d2cc4c42328592047fd9a71ec58c4/src/project1/db.clj
clojure
(ns project1.db (:require [korma.db :as korma-db] [korma.core :as korma])) (def postgresql-db {:classname "org.postgresql.Driver" :subprotocol "postgresql" :subname "//localhost:5432/clojure_blog" :user "clojure_blog" :password "clojure"}) (korma-db/defdb korma-pool postgresql-db) (korma/...
49bf4739c5ea57e4f509910c29ddcacf5c430e5716ea2a4ea893be20e7f4610f
LexiFi/dead_code_analyzer
val.ml
let x = 0 let y = 0
null
https://raw.githubusercontent.com/LexiFi/dead_code_analyzer/c44dc2ea5ccb13df2145e9316e21c39f09dad506/examples/advanced/val.ml
ocaml
let x = 0 let y = 0
a26a1dd7554f45b90b749a47bfc4e84c1ca18020025d55f90fbed10127ce416c
davisp/couchdb
mochiweb_cookies.erl
@author < > 2007 Mochi Media , Inc. @doc HTTP Cookie parsing and generating ( RFC 2109 , RFC 2965 ) . -module(mochiweb_cookies). -export([parse_cookie/1, cookie/3, cookie/2]). -define(QUOTE, $\"). -define(IS_WHITESPACE(C), (C =:= $\s orelse C =:= $\t orelse C =:= $\r orelse C =:= $\n)). RFC 2...
null
https://raw.githubusercontent.com/davisp/couchdb/b0420f9006915149e81607615720f32f21c76725/src/mochiweb/mochiweb_cookies.erl
erlang
@type proplist() = [{Key::string(), Value::string()}]. @type header() = {Name::string(), Value::string()}. @doc Short-hand for <code>cookie(Key, Value, [])</code>. where Option = {max_age, integer()} | {local_time, {date(), time()}} | {domain, string()} | {path, string()} | {secure, ...
@author < > 2007 Mochi Media , Inc. @doc HTTP Cookie parsing and generating ( RFC 2109 , RFC 2965 ) . -module(mochiweb_cookies). -export([parse_cookie/1, cookie/3, cookie/2]). -define(QUOTE, $\"). -define(IS_WHITESPACE(C), (C =:= $\s orelse C =:= $\t orelse C =:= $\r orelse C =:= $\n)). RFC 2...
38e693c7dd93302c2a06f5bdce7af0457aec48a34d62840f7b4eb79bfb1f9cbd
aryx/ocamltarzan
pa_iter_env.ml
pp camlp4orf File : pa_iter_env.ml , by . Heavily based on pa_sexp_conv.ml . Removed the Generate of_sexp ( need only 1 direction when generate visitor ) Copyright ( C ) 2005- Jane Street Holding , LLC Author : email : mmottl\@janestcapital.com WWW : This...
null
https://raw.githubusercontent.com/aryx/ocamltarzan/4140f5102cee83a2ca7be996ca2d92e9cb035f9c/pa/pa_iter_env.ml
ocaml
Pa_sexp_conv: Preprocessing Module for Automated S-expression Conversions *************************************************************************** Utility functions *************************************************************************** impossible ***********************************************************...
pp camlp4orf File : pa_iter_env.ml , by . Heavily based on pa_sexp_conv.ml . Removed the Generate of_sexp ( need only 1 direction when generate visitor ) Copyright ( C ) 2005- Jane Street Holding , LLC Author : email : mmottl\@janestcapital.com WWW : This...
7f3cf7fbe615c3104c117181ab77c9a74325de8f6a6d31d19cf1f6dbaeb8d557
LexiFi/menhir
PrintSExp.ml
(* An S-expression printer. *) type sexp = | A of string | L of sexp list | Lnewline of sexp list let atom sexp = A sexp let atoms = List.map atom let rec print ppf = function | A s -> Format.pp_print_string ppf s | L es -> Format.fprintf ppf "@[<2>(%a)@]" print_list es | Lnewline es -> ...
null
https://raw.githubusercontent.com/LexiFi/menhir/794e64e7997d4d3f91d36dd49aaecc942ea858b7/test/static/src/PrintSExp.ml
ocaml
An S-expression printer.
type sexp = | A of string | L of sexp list | Lnewline of sexp list let atom sexp = A sexp let atoms = List.map atom let rec print ppf = function | A s -> Format.pp_print_string ppf s | L es -> Format.fprintf ppf "@[<2>(%a)@]" print_list es | Lnewline es -> Format.fprintf ppf "@[<v ...
c912ec39cdbe5ad4cbf0a1580a6d8f074d3da886dc21ccee20771a311e83b10d
nikita-volkov/rebase
Signal.hs
module Rebase.GHC.Conc.Signal ( module GHC.Conc.Signal ) where import GHC.Conc.Signal
null
https://raw.githubusercontent.com/nikita-volkov/rebase/7c77a0443e80bdffd4488a4239628177cac0761b/library/Rebase/GHC/Conc/Signal.hs
haskell
module Rebase.GHC.Conc.Signal ( module GHC.Conc.Signal ) where import GHC.Conc.Signal
95dfc383c32737e1346aefc2cdab1cf9702b06aa7368d0d5d0411dc3961c740b
thriqon/pandoc-plantuml-diagrams
OutputBlock.hs
{-# LANGUAGE OverloadedStrings #-} | Module : Text . Pandoc . PlantUML.Filter . Renders an image file name and some attributes into a Pandoc -- block, like so: -- -- @ Para -- Image src=picture.jpg -- "{#fig:id}" -- @ module Text.Pandoc.PlantUML.Filter.OutputBlock(resultBlock) where import Text.Pandoc.JSON ...
null
https://raw.githubusercontent.com/thriqon/pandoc-plantuml-diagrams/a3f4e30fb14a38ba53b6937db869a7cbf2f6cabf/src/Text/Pandoc/PlantUML/Filter/OutputBlock.hs
haskell
# LANGUAGE OverloadedStrings # block, like so: @ Image src=picture.jpg "{#fig:id}" @ | The result block, as specified in the module header.
| Module : Text . Pandoc . PlantUML.Filter . Renders an image file name and some attributes into a Pandoc Para module Text.Pandoc.PlantUML.Filter.OutputBlock(resultBlock) where import Text.Pandoc.JSON import Text.Pandoc.PlantUML.Filter.Types import Data.Maybe import qualified Data.Text as T resultBlock :: Imag...
b73e9c3571381c7287bcbe6d1ddcd82b1a5c3e8e05a6e79bf620ef9b03147fbf
akabe/ocaml-jupyter
lwt_async_rewrite.cppo.ml
This module defines some rewrite rules to automatically transform top - level values of type [ Lwt.t ] or [ Async.t ] into some corresponding blocking calls . This way , a top - level evaluation of [ ' a Lwt.t ] blocks and eventually returns a [ ' a ] . top-level values of type [Lwt.t] or [As...
null
https://raw.githubusercontent.com/akabe/ocaml-jupyter/7ea00fde81a915ee9d86c979f295f4c5dac28db8/src/repl/lwt_async_rewrite.cppo.ml
ocaml
A rule for rewriting a toplevel expression. Values that must exist and be persistent for the rule to apply. The rewrite function. Whether the rule is enabled or not. Returns whether the given path is persistent. Check that the given long identifier is present in the environment and is persistent. Return...
This module defines some rewrite rules to automatically transform top - level values of type [ Lwt.t ] or [ Async.t ] into some corresponding blocking calls . This way , a top - level evaluation of [ ' a Lwt.t ] blocks and eventually returns a [ ' a ] . top-level values of type [Lwt.t] or [As...
85b3c5761c8ee93eb76f7607f675bf5edafd606d19d388f65dae0f0f3e675a46
mirage/io-page
portable.ml
open OUnit let test_alignment () = for _ = 0 to 1000 do let page = Io_page.get 1 in let addr = Io_page.get_addr page in assert_equal ~printer:Nativeint.to_string 0n Nativeint.(rem addr 4096n) done let _ = let verbose = ref false in Arg.parse [ "-verbose", Arg.Unit (fun _ -> verbose := true), "...
null
https://raw.githubusercontent.com/mirage/io-page/cc82c9cbd1e1caf7c40e12891b9e668d94b06b88/lib_test/portable.ml
ocaml
open OUnit let test_alignment () = for _ = 0 to 1000 do let page = Io_page.get 1 in let addr = Io_page.get_addr page in assert_equal ~printer:Nativeint.to_string 0n Nativeint.(rem addr 4096n) done let _ = let verbose = ref false in Arg.parse [ "-verbose", Arg.Unit (fun _ -> verbose := true), "...
efd142256c63812bfb25ca20aac295371f57fda6949c396baf43b579efba7daf
gedge-platform/gedge-platform
gr_app.erl
Copyright ( c ) 2012 , < > %% %% Permission to use, copy, modify, and/or distribute this software for any %% purpose with or without fee is hereby granted, provided that the above %% copyright notice and this permission notice appear in all copies. %% THE SOFTWARE IS PROVIDED " AS IS " AND THE AUTHOR DISCLAIMS A...
null
https://raw.githubusercontent.com/gedge-platform/gedge-platform/97c1e87faf28ba2942a77196b6be0a952bff1c3e/gs-broker/broker-server/deps/goldrush/src/gr_app.erl
erlang
Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies. WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVE...
Copyright ( c ) 2012 , < > THE SOFTWARE IS PROVIDED " AS IS " AND THE AUTHOR DISCLAIMS ALL WARRANTIES ANY SPECIAL , DIRECT , INDIRECT , OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE , DATA OR PROFITS , WHETHER IN AN -module(gr_app). -behaviour(application). -export([ sta...
1ae08d357f431c2b4b88f00c18dd363d9c78ccb169a092d5ba46c4f1951025fc
philoskim/debux
macro_specs.cljc
(ns debux.common.macro-specs "clojure.core macro specs which are minified, simplified and modified." (:require [clojure.spec.alpha :as s] #?@(:bb [] :default [[clojure.future :refer :all]]) )) (declare skip o-skip a-skip) ; skip => full skip ; o-skip => outermost skip ; a-skip => all ar...
null
https://raw.githubusercontent.com/philoskim/debux/26771cb65534f6f80f521b44c38f14e274f2332f/src/debux/common/macro_specs.cljc
clojure
skip => full skip o-skip => outermost skip a-skip => all args skip def defn, defn-, fn => #'debux.common.macro-specs/f1 :docstring "add1 docstring", :bs [:arity-1 {:args {:args [x y]}, :body [:body [(+ x y)]]}]} :docstring "add1 docstring", :bs [:arity-1 {:args {...
(ns debux.common.macro-specs "clojure.core macro specs which are minified, simplified and modified." (:require [clojure.spec.alpha :as s] #?@(:bb [] :default [[clojure.future :refer :all]]) )) (declare skip o-skip a-skip) (defn name-unformer [name] `(skip ~name)) (s/def ::name (s...
72c4dc7f697f03e02005e7f8ebb723136da6c145dc8acd382add31efc1d8f255
markus-git/co-feldspar
Vector.hs
# language GADTs # # language TypeFamilies # {-# language FlexibleInstances #-} # language FlexibleContexts # # language UndecidableInstances # # language MultiParamTypeClasses # # language FunctionalDependencies # {-# language DefaultSignatures #-} {-# language Scope...
null
https://raw.githubusercontent.com/markus-git/co-feldspar/bf598c803d41e03ed894bbcb490da855cce9250e/src/Feldspar/Array/Vector.hs
haskell
# language FlexibleInstances # # language DefaultSignatures # # language ScopedTypeVariables # ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ This library has been inspired by the vector library...
# language GADTs # # language TypeFamilies # # language FlexibleContexts # # language UndecidableInstances # # language MultiParamTypeClasses # # language FunctionalDependencies # # language ConstraintKinds # module Feldspar.Array.Vector where import Feldspar import F...
b203cfeff4b77c01d291b9fcd316fba675974d611e6888747bb6d1c90343d670
bmeurer/ocaml-experimental
tkthread.mli
(***********************************************************************) (* *) (* LablTk, Tcl/Tk interface of Objective Caml *) (* *) , Nagoya Uni...
null
https://raw.githubusercontent.com/bmeurer/ocaml-experimental/fe5c10cdb0499e43af4b08f35a3248e5c1a8b541/otherlibs/labltk/support/tkthread.mli
ocaml
********************************************************************* LablTk, Tcl/Tk interface of Objective Caml ...
, Nagoya University Mathematics Dept . Copyright 2004 Institut National de Recherche en Informatique et en Automatique and Kyoto University . All rights reserved . This file is distributed under the terms of the GNU Library General Public License , with the special e...
1234f7ec98ee85997fb4ed8176310a7684fce0b9bbdd243b3af93138e8cc738f
EduardoRFS/ml-lc
ml_lc.ml
open Ltree let parse_expr expr = Lexer.from_string Parser.expr_opt expr |> Option.get let print_expr expr = let expr = parse_expr expr in Format.printf "%a\n%!" Ltree.pp_expr expr let () = print_expr "x" let () = print_expr "(lambda [(x: int)] x)" let () = print_expr "(id id)" module Interp = struct type env ...
null
https://raw.githubusercontent.com/EduardoRFS/ml-lc/c5c2099275ad8e37bc50b69e6058a57126a24879/src/ml_lc.ml
ocaml
open Ltree let parse_expr expr = Lexer.from_string Parser.expr_opt expr |> Option.get let print_expr expr = let expr = parse_expr expr in Format.printf "%a\n%!" Ltree.pp_expr expr let () = print_expr "x" let () = print_expr "(lambda [(x: int)] x)" let () = print_expr "(id id)" module Interp = struct type env ...