_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
7c5fcc2a06b726039a97bb6a326b75fd294128ae32fe3760cc06707506fc0f56
disco-framework/disco
barkeeper_tests.erl
%% @hidden to edoc -module(barkeeper_tests). -ifdef(TEST). -include_lib("eunit/include/eunit.hrl"). %% %% tests ask_test() -> MockedMods = [port_utils, json], meck:new(MockedMods, [passthrough]), meck:new(application, [passthrough, unstick]), meck:expect(port_utils, easy_open_killer_port, fun(_) -...
null
https://raw.githubusercontent.com/disco-framework/disco/f55f35d46d43ef5f4fa1466bdf8d662f5f01f30f/src/test/barkeeper_tests.erl
erlang
@hidden to edoc tests
-module(barkeeper_tests). -ifdef(TEST). -include_lib("eunit/include/eunit.hrl"). ask_test() -> MockedMods = [port_utils, json], meck:new(MockedMods, [passthrough]), meck:new(application, [passthrough, unstick]), meck:expect(port_utils, easy_open_killer_port, fun(_) -> foo_port end), PortCmdDou...
9a4229d7a184c8e7901118405da20826a0e732199b91d60143427779eacea645
hansroland/CoreLang
Heap.hs
-- ---------------------------------------------------------------------------- -- Utils.Heap.hs - An implementation of a heap structure -- Should be replaced later by a Hackage library -- ---------------------------------------------------------------------------- module Utils.Heap (Heap , Addr...
null
https://raw.githubusercontent.com/hansroland/CoreLang/a740b5d5158842a1ce05cc614ad10f0c676d3690/src/Utils/Heap.hs
haskell
---------------------------------------------------------------------------- Utils.Heap.hs - An implementation of a heap structure Should be replaced later by a Hackage library ---------------------------------------------------------------------------- | Data type Heap Note: Do not automatically ...
module Utils.Heap (Heap , Addr , hInitial , hAlloc , hUpdate , hSize , hFree , hAddresses , hLookup) where import Utils.Assoc type Addr = Int data Heap a = Heap Addr [Addr] [(Addr, a)] hInitial :: Heap a hInitial = Heap 0 [1..] [] hAlloc :: Heap a -> a -> (Heap a, Addr) hAlloc (...
620aff1e495093ff9e60391691863a93d7cd60c820bc91e358dd04bbe9437403
LennMars/algorithms_in_OCaml
main.ml
open Util open IntSet let eratosthenes n = let rec eratosthenes_aux primes remains = let minimum = min_elt remains in if minimum * minimum > (max_elt remains) then union primes remains else eratosthenes_aux (add minimum primes) (filter (fun m -> m mod minimum <> 0) remains) in List.range ...
null
https://raw.githubusercontent.com/LennMars/algorithms_in_OCaml/f7fb8ca9f497883d86be3167bfc98a4a28ac73c9/eratosthenes/main.ml
ocaml
more fast
open Util open IntSet let eratosthenes n = let rec eratosthenes_aux primes remains = let minimum = min_elt remains in if minimum * minimum > (max_elt remains) then union primes remains else eratosthenes_aux (add minimum primes) (filter (fun m -> m mod minimum <> 0) remains) in List.range ...
2cbc09407528d297ff918dc439c59644442722d05ce54b933044d69b1a1e25b4
Mayvenn/storefront
graphql.clj
(ns storefront.system.contentful.graphql (:require [clojure.java.io :as io] [clojure.string :as string] [environ.core :refer [env]] [tugboat.core :as tugboat] [cheshire.core :as json])) (defn- request "Please use [[query]] when possible" [{:keys [graphql-endpoint p...
null
https://raw.githubusercontent.com/Mayvenn/storefront/ffca6d1b8c6ecd672e77fb739b3e7c5684df2dac/src/storefront/system/contentful/graphql.clj
clojure
(ns storefront.system.contentful.graphql (:require [clojure.java.io :as io] [clojure.string :as string] [environ.core :refer [env]] [tugboat.core :as tugboat] [cheshire.core :as json])) (defn- request "Please use [[query]] when possible" [{:keys [graphql-endpoint p...
48e145e7e48a1bc858380935995cee3ee1df13e111da3dde25fefba0d28105f1
maxhbr/LDBcollector
Base.hs
module Model.LicenseProperties.Base where type LicenseName = String type URL = String
null
https://raw.githubusercontent.com/maxhbr/LDBcollector/51d940f0af00b2acdd7de246b2be16fa30fc8a6b/src/Model/LicenseProperties/Base.hs
haskell
module Model.LicenseProperties.Base where type LicenseName = String type URL = String
48ed98007c03409fbd2cce609703629c735eb2d490a9c58f1d800f1524dc9b2d
kit-clj/kit
core.clj
(ns myapp.core (:require [clojure.tools.logging :as log] [integrant.core :as ig] [wake.guestbook.config :as config] [wake.guestbook.env :refer [defaults]] ;; Edges [kit.edge.utils.repl] [kit.edge.server.undertow] [wake.guestbook.web.handler] ;; Routes [wake.guestbook.web.rout...
null
https://raw.githubusercontent.com/kit-clj/kit/320b920dcf25c33130f33b0e1cd55ff13f3157f6/libs/kit-generator/test/resources/core.clj
clojure
Edges Routes log uncaught exceptions in threads
(ns myapp.core (:require [clojure.tools.logging :as log] [integrant.core :as ig] [wake.guestbook.config :as config] [wake.guestbook.env :refer [defaults]] [kit.edge.utils.repl] [kit.edge.server.undertow] [wake.guestbook.web.handler] [wake.guestbook.web.routes.api] [wake.guestbook...
7bd662fffcf87270ab6d51aaa5ceb5c49337cc3b6bb90b8cc1a43400cac790e1
Clozure/ccl-tests
plus.lsp
;-*- Mode: Lisp -*- Author : Created : Sun Aug 31 04:34:17 2003 ;;;; Contains: Tests of the function + (in-package :cl-test) (compile-and-load "numbers-aux.lsp") ;;; (compile-and-load "plus-aux.lsp") (deftest plus.1 (+) 0) (deftest plus.2 (loop for x in *numbers* unless (eql x (+ x)) collect ...
null
https://raw.githubusercontent.com/Clozure/ccl-tests/0478abddb34dbc16487a1975560d8d073a988060/ansi-tests/plus.lsp
lisp
-*- Mode: Lisp -*- Contains: Tests of the function + (compile-and-load "plus-aux.lsp") Test that explicit calls to macroexpand in subforms are done in the correct environment Must test combinations of reals and complex arguments. Order of evaluation tests Test that compilation does not reassociate float addi...
Author : Created : Sun Aug 31 04:34:17 2003 (in-package :cl-test) (compile-and-load "numbers-aux.lsp") (deftest plus.1 (+) 0) (deftest plus.2 (loop for x in *numbers* unless (eql x (+ x)) collect x) nil) (deftest plus.3 (loop for x in *numbers* for x1 = (+ x 0) for x2 = (+ 0 x) unless (an...
f2bce10f73081415decd4e6f3408b2cf0560b7b1b4530c1a07ac289ad61405af
KestrelInstitute/Specware
Tests.lisp
(test-directories ".") (test ("Bug 0015 : Substitute and Translate fail to update the localTypes and localOps" :show "subsExample#BB" :output '(";;; Elaborating spec-substitution at $TESTDIR/subsExample#BB" ";;; Elaborating spec at $TESTDIR/subsExample#AA" ";;; Elaborating spec at $TESTDIR/subsExample#...
null
https://raw.githubusercontent.com/KestrelInstitute/Specware/2be6411c55f26432bf5c9e2f7778128898220c24/TestSuite/Bugs/Bug_0015/Tests.lisp
lisp
(test-directories ".") (test ("Bug 0015 : Substitute and Translate fail to update the localTypes and localOps" :show "subsExample#BB" :output '(";;; Elaborating spec-substitution at $TESTDIR/subsExample#BB" ";;; Elaborating spec at $TESTDIR/subsExample#AA" ";;; Elaborating spec at $TESTDIR/subsExample#...
23294c05ac2458ef698f14e04b338f0c4f941ebc095a294429ff68df1cd60e9f
peak6/mmd_core
cpu_load.erl
Copyright 2011 PEAK6 Investments , L.P. %% 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 d...
null
https://raw.githubusercontent.com/peak6/mmd_core/f90469ea9eac8cd607aa6ec5b9ad6ff003a35572/src/cpu_load.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 2011 PEAK6 Investments , L.P. Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(cpu_load). -behaviour(gen_server). -export([start_link/0]). -export([util/0,util/1]). -export([init/1, handle_call/3, handl...
391e0503d0880b78a7c4bf7cfb1d464da594a8dfa756da74a99ad0ac892ae8f9
zorkow/MaxTract
matcher.ml
open MatcherUtility;; open Jsonfio.JsonfIO;; open Contentparser;; type symb = { glList: bBox list; elList: elem list; } let test = ref false let glyphLst = ref [] let elemLst = ref [] let btLn = ref (Ln {stx=0.; sty=99999.; enx=0.; eny=99999.; lnw=0.}) let rtCh = ref (Chr {chname=""; chfont=""; chsize=0.; chx=99...
null
https://raw.githubusercontent.com/zorkow/MaxTract/cb0b46792bb22d9d30996ae8c9e54a9819d740f9/src/pdfExtract/matcher.ml
ocaml
print_string "found"; printSymbols symbols;
open MatcherUtility;; open Jsonfio.JsonfIO;; open Contentparser;; type symb = { glList: bBox list; elList: elem list; } let test = ref false let glyphLst = ref [] let elemLst = ref [] let btLn = ref (Ln {stx=0.; sty=99999.; enx=0.; eny=99999.; lnw=0.}) let rtCh = ref (Chr {chname=""; chfont=""; chsize=0.; chx=99...
668139bb90eb1d6c31f4abf08febb30f8275dbc4710be29f9e3b2960b7e56399
karimarttila/clojure
reset_azure_table_storage_sessions.clj
(ns simpleserver.testutils.reset-azure-table-storage-sessions (:require [clojure.tools.logging :as log] [environ.core :as environ] [simpleserver.sessiondb.session-factory :as ss-session-factory] [simpleserver.sessiondb.session-service-interface :as ss-session-interface] ...
null
https://raw.githubusercontent.com/karimarttila/clojure/ee1261b9a8e6be92cb47aeb325f82a278f2c1ed3/clj-ring-cljs-reagent-demo/simple-server/test/simpleserver/testutils/reset_azure_table_storage_sessions.clj
clojure
Calling function directly since it is not part of the actual session interface. In real production code we should check the result values, of course. Note: we have to embed the map call with dorun since the function remove-token is just run for the side effect.
(ns simpleserver.testutils.reset-azure-table-storage-sessions (:require [clojure.tools.logging :as log] [environ.core :as environ] [simpleserver.sessiondb.session-factory :as ss-session-factory] [simpleserver.sessiondb.session-service-interface :as ss-session-interface] ...
e0a08b7a4f5fd2ae51e82aafa7e66aa9e1ee588e1c41558b02ab9f627d92b927
fluree/db
schema.cljc
(ns fluree.db.query.schema (:require [fluree.db.flake :as flake] [fluree.db.dbproto :as dbproto] [fluree.db.constants :as const] [fluree.db.util.async :refer [<? go-try]] [fluree.db.query.range :as query-range] [clojure.core.async :refer [go <!] :as async] ...
null
https://raw.githubusercontent.com/fluree/db/27999d15dcd90053119b06c6eb19c24fff137a56/src/fluree/db/query/schema.cljc
clojure
take everything after the '/' TODO - refactor! check for explicitly false, not nil :unique cannot be set to true if type is boolean, cannot change from anything to boolean, so only need to check new predicates :component cannot be set to true for an existing subject (it can be set to false). :unique cannot be se...
(ns fluree.db.query.schema (:require [fluree.db.flake :as flake] [fluree.db.dbproto :as dbproto] [fluree.db.constants :as const] [fluree.db.util.async :refer [<? go-try]] [fluree.db.query.range :as query-range] [clojure.core.async :refer [go <!] :as async] ...
a48f93a6339e2d6282ce479dc2534d14587ad2492ea659c2517d79bff4261752
acieroid/scala-am
incdec5.scm
(letrec ((counter 0) (lock (new-lock)) (inc (lambda () (acquire lock) (set! counter (+ counter 1)) (release lock))) (dec (lambda () (acquire lock) (set! counter (- counter 1)) (release lock))) ...
null
https://raw.githubusercontent.com/acieroid/scala-am/13ef3befbfc664b77f31f56847c30d60f4ee7dfe/test/concurrentScheme/threads/variations/incdec5.scm
scheme
(letrec ((counter 0) (lock (new-lock)) (inc (lambda () (acquire lock) (set! counter (+ counter 1)) (release lock))) (dec (lambda () (acquire lock) (set! counter (- counter 1)) (release lock))) ...
1bcbd0ffe83c91ac2f90c5648f73006282eb68f997bdcb50de1289400f824a9f
facebookarchive/duckling_old
time.clj
( ; Context map Tuesday Feb 12 , 2013 at 4:30am is the " now " for the tests {:reference-time (time/t -2 2013 2 12 4 30 0) :min (time/t -2 1900) :max (time/t -2 2100)} "nu" "just nu" (datetime 2013 2 12 4 30 00) "idag" (datetime 2013 2 12) "igår" (datetime 2013 2 11) "imorgon" (datetim...
null
https://raw.githubusercontent.com/facebookarchive/duckling_old/bf5bb9758c36313b56e136a28ba401696eeff10b/resources/languages/sv/corpus/time.clj
clojure
Context map ;; Cycles nth of Hours FIXME pm overrides precision :precision "approximate" :precision "exact" Mixing date and time ;; Involving periods :precision "approximate" resolves as after last Xmas ... Seasons Part of day (morning, afternoon...) Intervals involving cycles Explicit intervals go tr...
( Tuesday Feb 12 , 2013 at 4:30am is the " now " for the tests {:reference-time (time/t -2 2013 2 12 4 30 0) :min (time/t -2 1900) :max (time/t -2 2100)} "nu" "just nu" (datetime 2013 2 12 4 30 00) "idag" (datetime 2013 2 12) "igår" (datetime 2013 2 11) "imorgon" (datetime 2013 2 13) ...
61dc9b35c0605c86669d7eb52d2275f173e3fc09341c8caaf3b98684b094732d
yzh44yzh/practical_erlang
test.erl
-module(test). -export([run/0]). run() -> case mcache_tests:test() of ok -> init:stop(0); error -> init:stop(1) end.
null
https://raw.githubusercontent.com/yzh44yzh/practical_erlang/c9eec8cf44e152bf50d9bc6d5cb87fee4764f609/16_sockets/solution/test/test.erl
erlang
-module(test). -export([run/0]). run() -> case mcache_tests:test() of ok -> init:stop(0); error -> init:stop(1) end.
973b1de08741321d8ddcc219b5e1d8baf5df252cc4e667dd1f76dbc844154c66
hanshuebner/vlm
compile-Minima-for-VLM.lisp
-*- Mode : LISP ; Syntax : Common - Lisp ; Package : USER ; Base : 10 ; Patch - File : T -*- Patch file for Private version 0.0 ;;; Reason: Function MINIMA-COMPILER::COMPILE-ENVIRONMENT-FILE: . ;;; Function MINIMA-COMPILER::LOAD-ENVIRONMENT-FILE: . ;;; Function MINIMA-COMPILER::COMPILE-A-FILE: . ;;; Function MIN...
null
https://raw.githubusercontent.com/hanshuebner/vlm/20510ddc98b52252a406012a50a4d3bbd1b75dd0/support/compile-Minima-for-VLM.lisp
lisp
Syntax : Common - Lisp ; Package : USER ; Base : 10 ; Patch - File : T -*- Reason: Function MINIMA-COMPILER::COMPILE-ENVIRONMENT-FILE: . Function MINIMA-COMPILER::LOAD-ENVIRONMENT-FILE: . Function MINIMA-COMPILER::COMPILE-A-FILE: . Function MINIMA-COMPILER::COMPILE-FORM-TO-STREAM: . Add a control register vie...
Patch file for Private version 0.0 Written by , 2/04/93 10:59:22 while running on Sour Cream from FEP0:>dMinima-49 - E.ilod.1 with Experimental System 447.30 , Experimental CLOS 433.1 , Experimental RPC 437.0 , Experimental Embedding Support 429.1 , Experimental MacIvory Support 443.1 , Experimental UX Sup...
ba1d379805f0faa84d366ac81de86d8334967b3d88f963530f24f97488e65601
BranchTaken/Hemlock
test_of_real_to_real.ml
open! Basis.Rudiments open! Basis open U64 let test () = let rec test_rs rs = begin match rs with | [] -> () | r :: rs' -> begin let x = of_real r in File.Fmt.stdout |> Fmt.fmt "of_real " |> Real.fmt ~alt:true ~radix:Radix.Hex r |> Fmt.fmt " -> " |> fmt ~al...
null
https://raw.githubusercontent.com/BranchTaken/Hemlock/a07e362d66319108c1478a4cbebab765c1808b1a/bootstrap/test/basis/u64/test_of_real_to_real.ml
ocaml
open! Basis.Rudiments open! Basis open U64 let test () = let rec test_rs rs = begin match rs with | [] -> () | r :: rs' -> begin let x = of_real r in File.Fmt.stdout |> Fmt.fmt "of_real " |> Real.fmt ~alt:true ~radix:Radix.Hex r |> Fmt.fmt " -> " |> fmt ~al...
b2bb0bf933c611aa895d16d3d19a30d4535ba3d9e3cbaf5758f3c563b62a441c
aarkerio/ZentaurLMS
tests_view.clj
(ns zentaur.hiccup.tests-view (:require [hiccup.form :as f] [hiccup.core :as c] [clojure.tools.logging :as log] [hiccup.element :refer [link-to]] [hiccup.page :refer [include-css include-js]] [zentaur.hiccup.helpers-view :as hv])) (defn formatted-test [{:ke...
null
https://raw.githubusercontent.com/aarkerio/ZentaurLMS/adb43fb879b88d6a35f7f556cb225f7930d524f9/src/clj/zentaur/hiccup/tests_view.clj
clojure
(ns zentaur.hiccup.tests-view (:require [hiccup.form :as f] [hiccup.core :as c] [clojure.tools.logging :as log] [hiccup.element :refer [link-to]] [hiccup.page :refer [include-css include-js]] [zentaur.hiccup.helpers-view :as hv])) (defn formatted-test [{:ke...
16da804f58d8da05687c70cae2bd69ed755ded1d65d7a2f15972c9a2a27ac436
magicant/flesh
Warning.hs
Copyright ( C ) 2017 WATANABE > This program is free software ; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the License , or ( at your option ) any later version . This program is distribut...
null
https://raw.githubusercontent.com/magicant/flesh/0e76312d291aae8f890ba55d8131ade78600d7e8/src/Flesh/Language/Parser/Warning.hs
haskell
# LANGUAGE Safe # * Warning * Monad for recording warnings | Warning produced during source code parsing. | Writer monad specialized for recording warnings. vim: set et sw=2 sts=2 tw=78:
Copyright ( C ) 2017 WATANABE > This program is free software ; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the License , or ( at your option ) any later version . This program is distribut...
0cbeeabccc87813e11cd8f3dbd60660d7d27654780255d84ffdc3da56d75757f
naproche/naproche
Main.hs
-- | Authors : ( 2001 - 2008 ) , ( 2017 - 2018 ) , ( 2018 ) -- Main application entry point : console or server mode . # LANGUAGE TupleSections # {-# LANGUAGE OverloadedStrings #-} module SAD.Main where import Control.Monad (unless, when) import Data.Char (toLower) import Data.Time (...
null
https://raw.githubusercontent.com/naproche/naproche/6284a64b4b84eaa53dd0eb7ecb39737fb9135a0d/src/SAD/Main.hs
haskell
| # LANGUAGE OverloadedStrings # command line and init file main body with explicit error handling, notably for PIDE parse input text if -T / --onlytranslate is passed as an option, only print the translated text print statistics initialize reasoner state print statistics Command line parsing
Authors : ( 2001 - 2008 ) , ( 2017 - 2018 ) , ( 2018 ) Main application entry point : console or server mode . # LANGUAGE TupleSections # module SAD.Main where import Control.Monad (unless, when) import Data.Char (toLower) import Data.Time (UTCTime, addUTCTime, getCurrentTime, diffUT...
3925dc2f92934796d76b4dc7cb06f8bb94fe9ba551ea23f470c97043ec48ad37
mveety/lispmake
plugin.lisp
(in-package :lispmake) lispmake , written by , et al . ( c ) 2012 - 2021 . Under BSD License . (defun load-plugin (name file toplevel init-toplevel) (setf toplevel (car toplevel)) (setf init-toplevel (car init-toplevel)) (lm-debug "load-plugin" "loading a plugin") (format t "debug: toplevel=~A init-to...
null
https://raw.githubusercontent.com/mveety/lispmake/3eb4e8ac280de3c31b4826424093b11c7dbbf289/plugin.lisp
lisp
(in-package :lispmake) lispmake , written by , et al . ( c ) 2012 - 2021 . Under BSD License . (defun load-plugin (name file toplevel init-toplevel) (setf toplevel (car toplevel)) (setf init-toplevel (car init-toplevel)) (lm-debug "load-plugin" "loading a plugin") (format t "debug: toplevel=~A init-to...
cd96816063bb0c0b037ace382e8e4f4e19d220c32565af050840d8a200052465
leftaroundabout/manifolds
PseudoAffine.hs
-- | -- Module : Math.Manifold.Core.PseudoAffine Copyright : ( c ) 2016 -- License : GPL v3 -- -- Maintainer : (@) jsag $ hvl.no -- Stability : experimental -- Portability : portable -- # LANGUAGE FlexibleInstances # # LANGUAGE UndecidableInstances # {-# LANGUAGE TypeFamilies ...
null
https://raw.githubusercontent.com/leftaroundabout/manifolds/55330e7760fa8ea8948988a10a06bbf19e69b5f5/manifolds-core/Math/Manifold/Core/PseudoAffine.hs
haskell
| Module : Math.Manifold.Core.PseudoAffine License : GPL v3 Maintainer : (@) jsag $ hvl.no Stability : experimental Portability : portable # LANGUAGE TypeFamilies # # LANGUAGE GADTs # # LANGUAGE DeriveGeneric # # LANGUAGE StandaloneDeriving # # LANGU...
Copyright : ( c ) 2016 # LANGUAGE FlexibleInstances # # LANGUAGE UndecidableInstances # # LANGUAGE FlexibleContexts # # LANGUAGE DefaultSignatures # # LANGUAGE UnicodeSyntax # module Math.Manifold.Core.PseudoAffine where import Data.VectorSpace import Data.AffineSpac...
23418110addb0bacccfcfb542b14d64467815eda88b5dc0876c7e4e4bece8843
facebookarchive/pfff
visitor_php.mli
(*s: visitor_php.mli *) open Ast_php s : type visitor_in (* the hooks *) type visitor_in = { kexpr: (expr -> unit) * visitor_out -> expr -> unit; kstmt: (stmt -> unit) * visitor_out -> stmt -> unit; ktop: (toplevel -> unit) * visitor_out -> toplevel -> unit; kconstant: (constant -> unit) * visitor_out -> ...
null
https://raw.githubusercontent.com/facebookarchive/pfff/ec21095ab7d445559576513a63314e794378c367/lang_php/parsing/visitor_php.mli
ocaml
s: visitor_php.mli the hooks Helps intercepting all the new blocks that in a real language should * defined a new scope s: type visitor_out e: type visitor_out s: visitor functions x: visitor functions x: visitor functions e: visitor functions e: visitor_php.mli
open Ast_php s : type visitor_in type visitor_in = { kexpr: (expr -> unit) * visitor_out -> expr -> unit; kstmt: (stmt -> unit) * visitor_out -> stmt -> unit; ktop: (toplevel -> unit) * visitor_out -> toplevel -> unit; kconstant: (constant -> unit) * visitor_out -> constant -> unit; kscalar: (scalar ->...
b4a5f9b7ff9cd8c4b2f99c9f8f93eedf53a19f7ff886cfa298e37bd802195dad
HuwCampbell/grenade
Relu.hs
{-# LANGUAGE DataKinds #-} {-# LANGUAGE TypeOperators #-} # LANGUAGE TypeFamilies # # LANGUAGE MultiParamTypeClasses # | Module : Grenade . Layers . Relu Description : Rectifying linear unit layer Copyright : ( c ) , 2016 - 2017 License : BSD2 Stability : exper...
null
https://raw.githubusercontent.com/HuwCampbell/grenade/5206c95c423d9755e620f41576470a281ba59c89/src/Grenade/Layers/Relu.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE TypeOperators # A layer which can act between any shape of the same dimension, acting as a diode on every neuron individually.
# LANGUAGE TypeFamilies # # LANGUAGE MultiParamTypeClasses # | Module : Grenade . Layers . Relu Description : Rectifying linear unit layer Copyright : ( c ) , 2016 - 2017 License : BSD2 Stability : experimental Module : Grenade.Layers.Relu Description : Rectifying linear un...
e86995788b9f6339647945798baf4dee38e592da1312ae9cf3ad88803cbd67bb
ghc/packages-dph
Tuple.hs
-- | Closure converted tuple data constructors used by the vectoriser. module Data.Array.Parallel.Prelude.Tuple (tup2, tup3, tup4, tup5) where import Data.Array.Parallel.Lifted.Closure import Data.Array.Parallel.PArray.PRepr import qualified Data.Array.Parallel.PArray as PA tup2 :: (PA a, PA b) ...
null
https://raw.githubusercontent.com/ghc/packages-dph/64eca669f13f4d216af9024474a3fc73ce101793/dph-lifted-vseg/Data/Array/Parallel/Prelude/Tuple.hs
haskell
| Closure converted tuple data constructors used by the vectoriser.
module Data.Array.Parallel.Prelude.Tuple (tup2, tup3, tup4, tup5) where import Data.Array.Parallel.Lifted.Closure import Data.Array.Parallel.PArray.PRepr import qualified Data.Array.Parallel.PArray as PA tup2 :: (PA a, PA b) => a :-> b :-> (a, b) tup2 = closure2' (,) PA.zip # INLINE tup2...
0a3014a2ca7acd9dbb2c97e40dd2d514aff81eb5bbf3cbfa9f249559100d706f
vito/atomo
Method.hs
module Atomo.Method ( addMethod , elemsMap , emptyMap , insertMethod , insertMap , lookupMap , memberMap , noMethods , nullMap , toMethods ) where import Data.List (elemIndices) import Data.Maybe (isJust) import qualified Data.IntMap as M import Atomo.Types -- referring t...
null
https://raw.githubusercontent.com/vito/atomo/df22fcb3fbe80abb30b9ab3c6f5d50d3b8477f90/src/Atomo/Method.hs
haskell
referring to the left side: LT = is higher-precision equivalent patterns are replaced. | Like ==, but ignore optionals. methods. | An empty MethodMap. | Find methods in a MethodMap by the pattern ID. | Is a MethodMap empty?. | Is a key set in a map? same ID.
module Atomo.Method ( addMethod , elemsMap , emptyMap , insertMethod , insertMap , lookupMap , memberMap , noMethods , nullMap , toMethods ) where import Data.List (elemIndices) import Data.Maybe (isJust) import qualified Data.IntMap as M import Atomo.Types GT = is lo...
e8f10ff5e400d686570be6f2e21c9fbf31cb4e266933688adae3bd51702b097a
svenssonjoel/Obsidian
CompileIM.hs
# LANGUAGE QuasiQuotes # {-# LANGUAGE PackageImports #-} # LANGUAGE GeneralizedNewtypeDeriving # Joel Svensson 2013 .. 2017 Joel Svensson 2013..2017 -} module Obsidian.CodeGen.CompileIM where import Language.C.Quote.CUDA hiding (Block) import qualified Language.C.Quote.OpenCL as CL import qualified...
null
https://raw.githubusercontent.com/svenssonjoel/Obsidian/90886a0ef513cdaa58bb63765c230fa193d1ef10/Obsidian/CodeGen/CompileIM.hs
haskell
# LANGUAGE PackageImports # ------------------------------------------------------------------------- Config ------------------------------------------------------------------------- ------------------------------------------------------------------------- compileExp (maybe a bad name) -------------------------------...
# LANGUAGE QuasiQuotes # # LANGUAGE GeneralizedNewtypeDeriving # Joel Svensson 2013 .. 2017 Joel Svensson 2013..2017 -} module Obsidian.CodeGen.CompileIM where import Language.C.Quote.CUDA hiding (Block) import qualified Language.C.Quote.OpenCL as CL import qualified "language-c-quote" Language.C.S...
7a8f8d48c0d493d8e3e52db099d5c7864fc83aaeb2adfa7c825cd8eb24a80104
racket/typed-racket
predicate.rkt
#; (exn-pred #rx"could not be converted") #lang typed/racket/optional (define-predicate p? (All (A) (Listof A)))
null
https://raw.githubusercontent.com/racket/typed-racket/1dde78d165472d67ae682b68622d2b7ee3e15e1e/typed-racket-test/fail/optional/predicate.rkt
racket
(exn-pred #rx"could not be converted") #lang typed/racket/optional (define-predicate p? (All (A) (Listof A)))
3dd046deddd8672312f418dc768735b1b9b6704e2ab86fd3ba3bd0ff36c2d022
TyOverby/mono
private_ssl.real.ml
open Core open Async open Async_ssl let verify_certificate connection = match Ssl.Connection.peer_certificate connection with | None -> return false | Some (Error _) -> return false | Some (Ok _) -> return true let teardown_connection r w = Writer.close ~force_close:(Clock.after (sec 30.)) w >>= fun () -> ...
null
https://raw.githubusercontent.com/TyOverby/mono/8d6b3484d5db63f2f5472c7367986ea30290764d/vendor/mirage-ocaml-conduit/src/conduit-async/private_ssl.real.ml
ocaml
[Reader.of_pipe] will not close the pipe when the returned [Reader] is closed, so we manually do that ourselves. [Writer.of_pipe] will create a writer that will raise once the pipe is closed, so we set [raise_when_consumer_leaves] to false.
open Core open Async open Async_ssl let verify_certificate connection = match Ssl.Connection.peer_certificate connection with | None -> return false | Some (Error _) -> return false | Some (Ok _) -> return true let teardown_connection r w = Writer.close ~force_close:(Clock.after (sec 30.)) w >>= fun () -> ...
f59dce790c970573e2a02c13956bbf0abfc250281ba64df2ed4f0ac137d74c56
spurious/sagittarius-scheme-mirror
all-tests.scm
;; all tests for extensions (add-load-path ".") (add-load-path "../lib") (add-load-path "../sitelib") (cond-expand (sagittarius.os.windows (add-dynamic-load-path "../build/modules")) (else (add-dynamic-load-path "../build"))) (import (rnrs) (util file) (core errors) (srfi :39 parameters) (srfi :64 testing)) (...
null
https://raw.githubusercontent.com/spurious/sagittarius-scheme-mirror/53f104188934109227c01b1e9a9af5312f9ce997/ext/all-tests.scm
scheme
all tests for extensions Write out properties not written out by on-test-begin.
(add-load-path ".") (add-load-path "../lib") (add-load-path "../sitelib") (cond-expand (sagittarius.os.windows (add-dynamic-load-path "../build/modules")) (else (add-dynamic-load-path "../build"))) (import (rnrs) (util file) (core errors) (srfi :39 parameters) (srfi :64 testing)) (define-constant resource-fil...
8344ebb45863d3cf71f0f1dbac4c4c25b7812e390a50fe113fa7f94e784cbc79
Viasat/halite
data_err_maps.clj
Copyright ( c ) 2022 Viasat , Inc. Licensed under the MIT license (ns com.viasat.halite.doc.data-err-maps) (set! *warn-on-reflection* true) (def err-maps {'h-err/abs-failure {:doc "The way the number space is divided the value of zero comes out of the positive number space. This means there is one more negativ...
null
https://raw.githubusercontent.com/Viasat/halite/1145fdf49b5148acb389dd5100059b0d2ef959e1/src/com/viasat/halite/doc/data_err_maps.clj
clojure
Copyright ( c ) 2022 Viasat , Inc. Licensed under the MIT license (ns com.viasat.halite.doc.data-err-maps) (set! *warn-on-reflection* true) (def err-maps {'h-err/abs-failure {:doc "The way the number space is divided the value of zero comes out of the positive number space. This means there is one more negativ...
29b75af9836473089cc88d77fa441cfd7789039b7bcb42b7ffc76dbfaec98dcc
fukamachi/integral
connection.lisp
(in-package :cl-user) (defpackage integral-test.connection (:use :cl :integral :integral-test.init :prove) (:import-from :integral.connection :connection-handle)) (in-package :integral-test.connection) (plan 2) (let ((*db* (make-connection :mysql ...
null
https://raw.githubusercontent.com/fukamachi/integral/5fdf506233e9f6aa814a2da529bed0a551183110/t/connection.lisp
lisp
(in-package :cl-user) (defpackage integral-test.connection (:use :cl :integral :integral-test.init :prove) (:import-from :integral.connection :connection-handle)) (in-package :integral-test.connection) (plan 2) (let ((*db* (make-connection :mysql ...
9f3f06619a18a674a86c4644864bb4dbe38ae93bc8e0fbcc57256360dda46bb6
techascent/tvm-clj
project.clj
(defproject tvm-clj "6.00-beta-1-SNAPSHOT" :description "Clojure bindings and exploration of the tvm library" :url "-clj" :license {:name "Eclipse Public License" :url "-v10.html"} :dependencies [[org.clojure/clojure "1.10.2-alpha1"] [cnuernber/dtype-next "6.00-beta-5"] ...
null
https://raw.githubusercontent.com/techascent/tvm-clj/1088845bd613b4ba14b00381ffe3cdbd3d8b639e/project.clj
clojure
(defproject tvm-clj "6.00-beta-1-SNAPSHOT" :description "Clojure bindings and exploration of the tvm library" :url "-clj" :license {:name "Eclipse Public License" :url "-v10.html"} :dependencies [[org.clojure/clojure "1.10.2-alpha1"] [cnuernber/dtype-next "6.00-beta-5"] ...
6d8fa97a5cce75d9c2802e5cc2eb386961ad3aafe00cb7c556d00ced4096fbea
ghc/nofib
TG_iter.hs
Taylor - Galerkin / Pressure - correction algorithm . Solving four increamental matrix equations iteratively : const1*M(U'-U ) = rh1(U , P ) const2*M(U''-U ) = rh1(U',P ) const3*K(P'-P ) = rh2(U ' ) const4*M(U'''-U '' ) = rh3(P'-P ) The 3rd equation is solved by using the Cholesk...
null
https://raw.githubusercontent.com/ghc/nofib/f34b90b5a6ce46284693119a06d1133908b11856/real/fluid/TG_iter.hs
haskell
not needed w/ proper module handling ditto --------------------------------------------------------- Iterative TG algorithm. -- Functions called : -- for equation solving: "chl_method" and "jcb_method" -- for RHS assembling : "get_rh1", "get_rh2" and ...
Taylor - Galerkin / Pressure - correction algorithm . Solving four increamental matrix equations iteratively : const1*M(U'-U ) = rh1(U , P ) const2*M(U''-U ) = rh1(U',P ) const3*K(P'-P ) = rh2(U ' ) const4*M(U'''-U '' ) = rh3(P'-P ) The 3rd equation is solved by using the Cholesk...
4805051e6a139918aa321dd414a70dc56edd814e42f74a75a803e9d2daf45084
tlikonen/gpg-utilities
string-io.lisp
Author : < > ;; ;; License: Creative Commons CC0 (public domain dedication) ;; (defpackage #:string-io (:use #:cl) (:export #:parse-quoted-word #:current-string #:new-string #:closing-quote-missing #:parsed-string #:escape-characters #:quote-string ...
null
https://raw.githubusercontent.com/tlikonen/gpg-utilities/8971c814dbcbced3ed05f2024b29fd9e5096e96d/src/string-io.lisp
lisp
License: Creative Commons CC0 (public domain dedication)
Author : < > (defpackage #:string-io (:use #:cl) (:export #:parse-quoted-word #:current-string #:new-string #:closing-quote-missing #:parsed-string #:escape-characters #:quote-string #:sql-string #:sql-escape-like #:unesca...
0f080e415efed98a332994b68fe0294b24df427f4a9bf09ac448e741ff620caa
solita/mnt-teet
log.clj
(ns teet.log (:require [taoensso.timbre :as timbre])) ;; ;; Re-export selected timbre functions ;; (intern 'teet.log (with-meta 'debug {:macro true}) @#'timbre/debug) (intern 'teet.log (with-meta 'info {:macro true}) @#'timbre/info) (intern 'teet.log (with-meta 'warn {:macro t...
null
https://raw.githubusercontent.com/solita/mnt-teet/7a5124975ce1c7f3e7a7c55fe23257ca3f7b6411/app/frontend/src/cljs/teet/log.clj
clojure
Re-export selected timbre functions
(ns teet.log (:require [taoensso.timbre :as timbre])) (intern 'teet.log (with-meta 'debug {:macro true}) @#'timbre/debug) (intern 'teet.log (with-meta 'info {:macro true}) @#'timbre/info) (intern 'teet.log (with-meta 'warn {:macro true}) @#'timbre/warn) (intern 'teet.l...
9b9dc60805ba475017c4d6642fe197d99c7df046b1d889e86ad90bbc5c67e82a
esl/MongooseIM
mongoose_graphql_stanza_admin_subscription.erl
-module(mongoose_graphql_stanza_admin_subscription). -behaviour(mongoose_graphql). -import(mongoose_graphql_helper, [format_result/2]). -export([execute/4]). -ignore_xref([execute/4]). -include("../mongoose_graphql_types.hrl"). execute(Ctx, _Obj, <<"subscribeForMessages">>, Args) -> subscribe_for_messages(Ctx,...
null
https://raw.githubusercontent.com/esl/MongooseIM/7c7419889d3babba1a842903fe515c8f61752e7d/src/graphql/admin/mongoose_graphql_stanza_admin_subscription.erl
erlang
-module(mongoose_graphql_stanza_admin_subscription). -behaviour(mongoose_graphql). -import(mongoose_graphql_helper, [format_result/2]). -export([execute/4]). -ignore_xref([execute/4]). -include("../mongoose_graphql_types.hrl"). execute(Ctx, _Obj, <<"subscribeForMessages">>, Args) -> subscribe_for_messages(Ctx,...
4936f0776297ba6630b63132ac5b2ae6b4f9b6bae341ccd9cebc6216383c0022
tarleb/jira-wiki-markup
Printer.hs
# LANGUAGE CPP # # LANGUAGE LambdaCase # | Module : Text . Jira . Parser Copyright : © 2019–2023 : MIT Maintainer : Stability : alpha Portability : portable wiki markup text from an abstract syntax tree . Module : Text.Jira.Parser Copyright : © 2019–2023 Albert Krewi...
null
https://raw.githubusercontent.com/tarleb/jira-wiki-markup/553d525355f75314d0c439cc77e11118e8736a73/src/Text/Jira/Printer.hs
haskell
| Render a list of Jira blocks as Jira wiki formatted text. | Renders a list of Jira inline markup elements. Most special chars don't need escaping when surrounded by spaces or within a word. Braces are the exception, they should always be escaped. Colon and semicolon only need escaping if they could otherwise be...
# LANGUAGE CPP # # LANGUAGE LambdaCase # | Module : Text . Jira . Parser Copyright : © 2019–2023 : MIT Maintainer : Stability : alpha Portability : portable wiki markup text from an abstract syntax tree . Module : Text.Jira.Parser Copyright : © 2019–2023 Albert Krewi...
d52fffedd25e939dbae99411c0bf809025fb78f3d13b5a9e7e6f148c84228f21
avsm/melange
spl_cfg.mli
* Copyright ( c ) 2005 < > * * Permission to use , copy , modify , and 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 AU...
null
https://raw.githubusercontent.com/avsm/melange/e92240e6dc8a440cafa91488a1fc367e2ba57de1/tools/spl/spl_cfg.mli
ocaml
* Copyright ( c ) 2005 < > * * Permission to use , copy , modify , and 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 AU...
427492c76487e6362c9d639ef87e98f34f59d6782e221e12f2dd70f648f50818
DanielG/ghc-mod
ShellParse.hs
ghc - mod : Happy Haskell Hacking Copyright ( C ) 2015 < > -- -- 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 , or -- (at your option) any later...
null
https://raw.githubusercontent.com/DanielG/ghc-mod/391e187a5dfef4421aab2508fa6ff7875cc8259d/src/GhcMod/Exe/Options/ShellParse.hs
haskell
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...
ghc - mod : Happy Haskell Hacking Copyright ( C ) 2015 < > it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or You should have received a copy of the GNU Affero General Public License module GhcMod.Exe.Options.She...
ee4350ea9c21aa7c940a6969563fb1b532aa8ffb4e3147d577d064267859910c
chef/chef-server
chef_wm_depsolver.erl
-*- erlang - indent - level : 4;indent - tabs - mode : nil ; fill - column : 92 -*- %% ex: ts=4 sw=4 et @author < > @author < > @doc Resource module for Chef Depsolver endpoint Copyright 2012 - 2014 Chef Software , Inc. All Rights Reserved . %% This file is provided to you under the Apache License , %...
null
https://raw.githubusercontent.com/chef/chef-server/7cdc962f8c4fb77a3d59cb02c8beb4339ba218b1/src/oc_erchef/apps/oc_chef_wm/src/chef_wm_depsolver.erl
erlang
ex: ts=4 sw=4 et 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 License for the specific language governing permissions and limitations under the License. chef_wm beh...
-*- erlang - indent - level : 4;indent - tabs - mode : nil ; fill - column : 92 -*- @author < > @author < > @doc Resource module for Chef Depsolver endpoint Copyright 2012 - 2014 Chef Software , Inc. All Rights Reserved . This file is provided to you under the Apache License , except in compliance w...
d2aff7491e0f97acca2e86cb28e083f8d7d5097d1db3a84bae57ab1a53c9f83f
azimut/shiny
8bitmusictheory.lisp
(in-package :shiny) ;; ;; Gbmaj13 - Fm9 ;; Dm9 - Abm6
null
https://raw.githubusercontent.com/azimut/shiny/774381a9bde21c4ec7e7092c7516dd13a5a50780/compositions/drafts/8bitmusictheory.lisp
lisp
Gbmaj13 - Fm9 Dm9 - Abm6
(in-package :shiny)
873986541985f4a170eb140e80afc3981b52478724bf73810341ec185c76ab12
haskell-mafia/projector
ModuleGraph.hs
# LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE NoImplicitPrelude # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE TupleSections # module Projector.Html.ModuleGraph ( ModuleGraph (..) , buildModuleGraph , DependencyGraph (..) , buildDependencyGraph , deriveImports , deriveImportsIncremental , dependen...
null
https://raw.githubusercontent.com/haskell-mafia/projector/6af7c7f1e8a428b14c2c5a508f7d4a3ac2decd52/projector-html/src/Projector/Html/ModuleGraph.hs
haskell
# LANGUAGE OverloadedStrings # | The call graph. | An inverted ModuleGraph. | Figure out the complete set of imports for a set of modules. Since we have globally-unique names (i.e. our modules are a compilation detail), we can figure these out automatically. | Construct the module graph for some set of modules. ...
# LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE NoImplicitPrelude # # LANGUAGE TupleSections # module Projector.Html.ModuleGraph ( ModuleGraph (..) , buildModuleGraph , DependencyGraph (..) , buildDependencyGraph , deriveImports , deriveImportsIncremental , dependencyOrder , rebuildOrder , detect...
f0d1f90bb3e07be755547ad882055a45ee57d546b7cf258c2fabe969c7af048f
Limvot/kraken
fib_let.scm
(pretty-print ((letrec ((fib (lambda (n) (cond ((equal? n 0) 1) ((equal? n 1) 1) (#t (let ( (r1 (fib (- n 1))) (r2...
null
https://raw.githubusercontent.com/Limvot/kraken/ca68826fbcc6abd11e2845c44092d7125ea92d04/fib_test/fib_let.scm
scheme
(pretty-print ((letrec ((fib (lambda (n) (cond ((equal? n 0) 1) ((equal? n 1) 1) (#t (let ( (r1 (fib (- n 1))) (r2...
49b3e26ced703ae379f385b7d55fc211f46c0eff13c26f9e207b4bebb48ff3a5
camfort/camfort
InferenceBackend.hs
Copyright 2016 , , , , 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 distribute...
null
https://raw.githubusercontent.com/camfort/camfort/3421e85f6fbbcaa6503a266b3fae029a09d2ff24/src/Camfort/Specification/Units/InferenceBackend.hs
haskell
mainly for debugging and testing: | Returns list of formerly-undetermined variables and their units. Find the rows corresponding to the distilled "unit :: var" information for ordinary (non-polymorphic) variables. Detect inconsistency if concrete units are assigned an implicit abstract unit variable with coeffici...
Copyright 2016 , , , , 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 distribute...
33e962513cab1d0a698c5ed302388ed9f0fdd7805b51ef0b881f8fb9338760cf
UU-ComputerScience/uhc
Ratio.hs
# LANGUAGE CPP # ----------------------------------------------------------------------------- -- | -- Module : Data.Ratio Copyright : ( c ) The University of Glasgow 2001 -- License : BSD-style (see the file libraries/base/LICENSE) -- -- Maintainer : -- Stability : stable -- Portability : po...
null
https://raw.githubusercontent.com/UU-ComputerScience/uhc/f2b94a90d26e2093d84044b3832a9a3e3c36b129/EHC/ehclib/base/Data/Ratio.hs
haskell
--------------------------------------------------------------------------- | Module : Data.Ratio License : BSD-style (see the file libraries/base/LICENSE) Maintainer : Stability : stable Portability : portable Standard functions on rational numbers -----------------------------------------...
# LANGUAGE CPP # Copyright : ( c ) The University of Glasgow 2001 module Data.Ratio ( Ratio , Rational : : ( RealFrac a ) = > a - > a - > Rational ( Integral a ) = > ( Ratio a ) ( Integral a ) = > ( Ratio a ) ) where import Prelude #ifdef __GLASGOW_HASKELL__ #endif #ifdef __HU...
c15f5ae5641e9352bc1e9838677a0ed41d41491f9870f1e06425ce87872e55a1
ashinn/alschemist
mzscheme-301.scm
For mzscheme-301 (require (lib "1.ss" "srfi")) (require (lib "9.ss" "srfi")) (require (lib "23.ss" "srfi")) (require (lib "60.ss" "srfi")) (require (lib "69.ss" "srfi")) (load "other/srfi-60-pieces.scm")
null
https://raw.githubusercontent.com/ashinn/alschemist/13d7105c1291a881b8d8d69c8e60e045428c04b1/jkode/sassy/inits/mzscheme-301.scm
scheme
For mzscheme-301 (require (lib "1.ss" "srfi")) (require (lib "9.ss" "srfi")) (require (lib "23.ss" "srfi")) (require (lib "60.ss" "srfi")) (require (lib "69.ss" "srfi")) (load "other/srfi-60-pieces.scm")
3077c459ce4c266dd6b2aeaeea09894d204847824c349e0e4293d854f93fa5a0
alvatar/spheres
c-define-struct#.scm
;; Helper for define-c-struct and define-c-union (define^ (%%c-define-struct-or-union struct-or-union type fields) (let* ((type-str (symbol->string type)) (struct-type-str (string-append (case struct-or-union ((struct) "struct ") ...
null
https://raw.githubusercontent.com/alvatar/spheres/568836f234a469ef70c69f4a2d9b56d41c3fc5bd/spheres/gambit/ffi/c-define-struct%23.scm
scheme
Helper for define-c-struct and define-c-union Struct Array of fundamental type generate a getter and a setter Array of structs only generate a getter returning struct address Define the release function which is called when the object is no longer accessible from the Scheme world. Define type allocator procedu...
(define^ (%%c-define-struct-or-union struct-or-union type fields) (let* ((type-str (symbol->string type)) (struct-type-str (string-append (case struct-or-union ((struct) "struct ") ((union) "union ") ...
12822357cefeeac6db61b8ddaaa544537b07e35f77b6e7ec9fe8348323025156
jguhlin/ODG
project.clj
(defproject odg "1.1.1" :main odg.core :aot [odg.core] :profiles { :uberjar { :aot :all}} :description "FIXME: write description" :url "" :jvm-opts ^:replace [ "-Xms6G" "-Xmx6G" " -XX : " ; May have caused a huge slowdown ? At ...
null
https://raw.githubusercontent.com/jguhlin/ODG/c8a09f273c278ba7b3acbd37155477979f8b4851/project.clj
clojure
May have caused a huge slowdown ? At least in eclipse ... "-XX:+UseParallelGC" "-Dco.paralleluniverse.fibers.verifyInstrumentation" :exclusions [org.clojure/tools.reader]]
(defproject odg "1.1.1" :main odg.core :aot [odg.core] :profiles { :uberjar { :aot :all}} :description "FIXME: write description" :url "" :jvm-opts ^:replace [ "-Xms6G" "-Xmx6G" "-XX:+UseConcMarkSweepGC" ...
116c910dda19a8379d96d7ad531fa8aeb241a84b1ec5392ce126d77871ebcf63
namanmansukhani/ocaml-coreutils
yes.ml
let program_name = "yes" let usage_msg = "usage: yes [args ...]" let args = ref [] let anon_fun arg = args := arg :: !args let speclist = [] let exit_code = ref 0 let yes args = let word = (match args with | [] -> "y" | (x::_) -> x) in while true do try Printf.printf "%s\n" word with ...
null
https://raw.githubusercontent.com/namanmansukhani/ocaml-coreutils/4e19d842818c7513291b652dcf3dd913110a6de9/bin/yes.ml
ocaml
let program_name = "yes" let usage_msg = "usage: yes [args ...]" let args = ref [] let anon_fun arg = args := arg :: !args let speclist = [] let exit_code = ref 0 let yes args = let word = (match args with | [] -> "y" | (x::_) -> x) in while true do try Printf.printf "%s\n" word with ...
3b816401014377e7967f827f70169a69e31154271f05a1aa13b6ccf45e76a2b1
rbkmoney/fistful-server
ff_deposit_revert_utils.erl
%% %% Index reverts management helpers %% -module(ff_deposit_revert_utils). -opaque index() :: #{ reverts := #{id() => revert()}, Стек идентифкаторов возвратов . Голова списка точно является незавершенным ревертом . Остальные реверты могут быть как завершенными , нет . Элементы На практике , если машин...
null
https://raw.githubusercontent.com/rbkmoney/fistful-server/60b964d0e07f911c841903bc61d8d9fb20a32658/apps/ff_transfer/src/ff_deposit_revert_utils.erl
erlang
Index reverts management helpers API Internal types API Internals
-module(ff_deposit_revert_utils). -opaque index() :: #{ reverts := #{id() => revert()}, Стек идентифкаторов возвратов . Голова списка точно является незавершенным ревертом . Остальные реверты могут быть как завершенными , нет . Элементы На практике , если машина не подвергалась починке , в стеке будут ...
85ecd45ad153c2f17b97ee8dc7517bbf9a6beb106791dcc15bdbb25e20141559
NorfairKing/validity
CerealSpec.hs
# LANGUAGE TypeApplications # module Test.Validity.CerealSpec where import Data.GenValidity import Test.Hspec import Test.Validity.Cereal spec :: Spec spec = do serializeSpecOnGen (genListOf $ pure 'a') "sequence of 'a's" (const []) serializeSpec @Double DOES NOT HOLD serializeSpec @Rational serializeSpec @I...
null
https://raw.githubusercontent.com/NorfairKing/validity/35bc8d45b27e6c21429e4b681b16e46ccd541b3b/genvalidity-hspec-cereal/test/Test/Validity/CerealSpec.hs
haskell
# LANGUAGE TypeApplications # module Test.Validity.CerealSpec where import Data.GenValidity import Test.Hspec import Test.Validity.Cereal spec :: Spec spec = do serializeSpecOnGen (genListOf $ pure 'a') "sequence of 'a's" (const []) serializeSpec @Double DOES NOT HOLD serializeSpec @Rational serializeSpec @I...
6bba21369b03a82df7b312564509e4b65f7cfae2f21b4f4c8b6dcbe2e86573d8
mahsu/MariOCaml
sprite.mli
open Actors (* Represents an xy vector *) type xy = float * float (* x, y *) (* Inherent sprite parameters from which to create the sprite *) type sprite_params = { max_frames: int; max_ticks: int; img_src: string; frame_size: xy; src_offset: xy; bbox_offset: xy; bbox_size: xy; loop:...
null
https://raw.githubusercontent.com/mahsu/MariOCaml/d2359260895b77390648ca5ad126a897e639e7e4/sprite.mli
ocaml
Represents an xy vector x, y Inherent sprite parameters from which to create the sprite Concrete sprite created to visually represent an object Sets up a sprite to create Creates a sprite given the actor type Make a background Make a particle corresponding to the given type Transform an enemy sprite ba...
open Actors type sprite_params = { max_frames: int; max_ticks: int; img_src: string; frame_size: xy; src_offset: xy; bbox_offset: xy; bbox_size: xy; loop: bool; } type sprite = { mutable params: sprite_params; context: Dom_html.canvasRenderingContext2D Js.t; frame:...
d90bbcf8ac33e3aede50c7591a52e25dc5b46f139308da0c713fbfad5621e885
kadena-io/pact
API.hs
# LANGUAGE DeriveGeneric # # LANGUAGE FlexibleContexts # # LANGUAGE GeneralizedNewtypeDeriving # {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RankNTypes #-} # LANGUAGE RecordWildCards # # LANGUAGE ScopedTypeVariables # # LANGUAGE TemplateHaskell # -- | -- Module : Pact.Types.API Copyright : ( C ) 2016 ...
null
https://raw.githubusercontent.com/kadena-io/pact/4971ab6078b75eb612d83d56f1e7cd139a5a2ba8/src/Pact/Types/API.hs
haskell
# LANGUAGE OverloadedStrings # # LANGUAGE RankNTypes # | Module : Pact.Types.API License : BSD-style (see the file LICENSE) Pact REST API types. | Submit new commands for execution | What you get back from a Poll
# LANGUAGE DeriveGeneric # # LANGUAGE FlexibleContexts # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE RecordWildCards # # LANGUAGE ScopedTypeVariables # # LANGUAGE TemplateHaskell # Copyright : ( C ) 2016 Maintainer : < > module Pact.Types.API ( RequestKeys(..), rkRequestKeys , SubmitBatch...
f4d0d32178a949ad0169bb4d0fd07ec6a52b37683f6ca6579684adc7bd48e752
PuercoPop/Movitz
movitz.lisp
;;;;------------------------------------------------------------------ ;;;; Copyright ( C ) 20012000 , 2002 - 2004 , Department of Computer Science , University of Tromso , Norway ;;;; ;;;; Filename: movitz.lisp ;;;; Description: Author : < > ;;;; Created at: Mon Oct 9 20:52:58 200...
null
https://raw.githubusercontent.com/PuercoPop/Movitz/7ffc41896c1e054aa43f44d64bbe9eaf3fcfa777/movitz.lisp
lisp
------------------------------------------------------------------ Filename: movitz.lisp Description: Created at: Mon Oct 9 20:52:58 2000 Distribution: See the accompanying file COPYING. ------------------------------------------------------------------ These hold...
Copyright ( C ) 20012000 , 2002 - 2004 , Department of Computer Science , University of Tromso , Norway Author : < > $ I d : movitz.lisp , v 1.12 2007/03/13 20:40:10 ffjeld Exp $ (in-package movitz) (defvar *image* nil) (define-symbol-macro *movitz-nil* (image-nil-object *image*)) (de...
8680e7a94ba92993b62939650063adca3d413ab9fd886a644de32284861df2ba
zadean/xqerl
fn_contains_token_SUITE.erl
-module('fn_contains_token_SUITE'). -include_lib("common_test/include/ct.hrl"). -export([ all/0, groups/0, suite/0 ]). -export([ init_per_suite/1, init_per_group/2, end_per_group/2, end_per_suite/1 ]). -export(['fn-contains-token-09'/1]). -export(['fn-contains-token-10'/1]). -export(['fn...
null
https://raw.githubusercontent.com/zadean/xqerl/1a94833e996435495922346010ce918b4b0717f2/test/fn/fn_contains_token_SUITE.erl
erlang
-module('fn_contains_token_SUITE'). -include_lib("common_test/include/ct.hrl"). -export([ all/0, groups/0, suite/0 ]). -export([ init_per_suite/1, init_per_group/2, end_per_group/2, end_per_suite/1 ]). -export(['fn-contains-token-09'/1]). -export(['fn-contains-token-10'/1]). -export(['fn...
ada74993739b629ce993f2174c84e89ce4984ebccea21ccc238aaf3358ca758a
VincentToups/racket-lib
command-respond-window.rkt
#lang racket (require racket/gui functional/better-monads) (define command-input% (class text% (init-field [command-callback (lambda (command) #t)]) (field (command #f)) (define/public (get-command) (if command (let ((c command)) (set! command #f) c) ...
null
https://raw.githubusercontent.com/VincentToups/racket-lib/d8aed0959fd148615b000ceecd7b8a6128cfcfa8/command-respond-window/command-respond-window.rkt
racket
(define interaction (make-command-respond-window "test" (lambda (x) x) )) interaction)
#lang racket (require racket/gui functional/better-monads) (define command-input% (class text% (init-field [command-callback (lambda (command) #t)]) (field (command #f)) (define/public (get-command) (if command (let ((c command)) (set! command #f) c) ...
9357d5780dbdb898b4273d7cde9703eeb5dadfb7bfb6a31f4c172ff80e3e143d
PEZ/clerk
project.clj
(defproject routing-example "0.1.0-SNAPSHOT" :description "Client side routing with bidi, accountant and clerk" :url "-example" :min-lein-version "2.5.3" :dependencies [[org.clojure/clojure "1.9.0"] [org.clojure/clojurescript "1.10.339"] #_[org.clojure/core.async "0.3.443" ...
null
https://raw.githubusercontent.com/PEZ/clerk/2ba48a73b8eda388979cad2ff7aa25f958005095/demo/reagent/project.clj
clojure
this demo uses :source-paths instead since it lives in the clerk repo This next build is an compressed minified build for production. You can build this with:
(defproject routing-example "0.1.0-SNAPSHOT" :description "Client side routing with bidi, accountant and clerk" :url "-example" :min-lein-version "2.5.3" :dependencies [[org.clojure/clojure "1.9.0"] [org.clojure/clojurescript "1.10.339"] #_[org.clojure/core.async "0.3.443" ...
e5e46bc6d0ab4c1330f4f3f919eb2a53bcd677fdf53859c0829d97e2fdee98b0
janestreet/core_unix
bench_zone.ml
open! Core module Time = Time_float_unix let epoch = Time.epoch let winter = Time.of_string "2000-01-01 06:00:00Z" let summer = Time.of_string "2020-08-20 18:00:00Z" let hkg = Time.Zone.find_exn "Asia/Hong_Kong" let ldn = Time.Zone.find_exn "Europe/London" let nyc = Time.Zone.find_exn "America/New_York" let utc = Time...
null
https://raw.githubusercontent.com/janestreet/core_unix/59d04e163b49c7eeef9d96fccb2403fd49c44505/time_float_unix/bench/bench_zone.ml
ocaml
open! Core module Time = Time_float_unix let epoch = Time.epoch let winter = Time.of_string "2000-01-01 06:00:00Z" let summer = Time.of_string "2020-08-20 18:00:00Z" let hkg = Time.Zone.find_exn "Asia/Hong_Kong" let ldn = Time.Zone.find_exn "Europe/London" let nyc = Time.Zone.find_exn "America/New_York" let utc = Time...
94e4da5050179b0c2d1d75e6bfab337c4a55e3c4105d963b46eef124624bdb93
softwarelanguageslab/maf
R5RS_scp1_slide-in-1.scm
; Changes: * removed : 0 * added : 0 * swaps : 1 ; * negated predicates: 0 ; * swapped branches: 0 * calls to i d fun : 1 (letrec ((schuif-in! (lambda (l1 l2) (if (null? (cdr l1)) (begin (<change> (set-...
null
https://raw.githubusercontent.com/softwarelanguageslab/maf/11acedf56b9bf0c8e55ddb6aea754b6766d8bb40/test/changes/scheme/generated/R5RS_scp1_slide-in-1.scm
scheme
Changes: * negated predicates: 0 * swapped branches: 0
* removed : 0 * added : 0 * swaps : 1 * calls to i d fun : 1 (letrec ((schuif-in! (lambda (l1 l2) (if (null? (cdr l1)) (begin (<change> (set-cdr! l1 l2) ((lambda (x) x) (...
be97548a4f8f830aed391cb32a1e522eaba86e0673910fb86465abd3a80aa630
immutant/immutant
utils.clj
Copied and modified from potemkin , v0.4.3 ( ) , MIT licnensed , Copyright ;; Changes: - removed fast - memoize and friends to remove need for clj - tuple (ns ^:no-doc from.potemkin.utils (:require [from.potemkin.macros :refer [unify-gensyms]]) (:import [java.util.concurrent ConcurrentHashMap])...
null
https://raw.githubusercontent.com/immutant/immutant/6ff8fa03acf73929f61f2ca75446cb559ddfc1ef/web/src/from/potemkin/utils.clj
clojure
Changes:
Copied and modified from potemkin , v0.4.3 ( ) , MIT licnensed , Copyright - removed fast - memoize and friends to remove need for clj - tuple (ns ^:no-doc from.potemkin.utils (:require [from.potemkin.macros :refer [unify-gensyms]]) (:import [java.util.concurrent ConcurrentHashMap])) (defmacro...
0a65071968df2d0381009ce41627ca5049fb62a3a5bf0f5409ff904dc52d37bc
ghc/testsuite
tcfail088.hs
{-# LANGUAGE RankNTypes, FlexibleInstances #-} -- !!! Check that forall types can't be arguments module ShouldFail where data T s a = MkT s a instance Ord a => Ord (forall s. T s a) A for - all should not appear as an argument to g :: T s (forall b.b) g = error "urk"
null
https://raw.githubusercontent.com/ghc/testsuite/998a816ae89c4fd573f4abd7c6abb346cf7ee9af/tests/typecheck/should_fail/tcfail088.hs
haskell
# LANGUAGE RankNTypes, FlexibleInstances # !!! Check that forall types can't be arguments
module ShouldFail where data T s a = MkT s a instance Ord a => Ord (forall s. T s a) A for - all should not appear as an argument to g :: T s (forall b.b) g = error "urk"
f2d524a7ef71a00a78137229632c6c6c19f39edeb885e282e3f845a269266c42
qiao/sicp-solutions
1.39.scm
(define (cont-frac-iter n d k) (define (iter k acc) (if (= 0 k) acc (iter (- k 1) (/ (n k) (+ (d k) acc))))) (iter k 0)) (define (tan-cf x k) (define (n i) (if (= 1 i) x (- (square x)))) (define (d i) (- (* 2 i) 1)) (cont-frac-iter n d k))
null
https://raw.githubusercontent.com/qiao/sicp-solutions/a2fe069ba6909710a0867bdb705b2e58b2a281af/chapter1/1.39.scm
scheme
(define (cont-frac-iter n d k) (define (iter k acc) (if (= 0 k) acc (iter (- k 1) (/ (n k) (+ (d k) acc))))) (iter k 0)) (define (tan-cf x k) (define (n i) (if (= 1 i) x (- (square x)))) (define (d i) (- (* 2 i) 1)) (cont-frac-iter n d k))
539ce42f5a21b9093796653e492e14a7f55cf0265c96ea32f93fcb9913fcc322
OCamlPro/alt-ergo
models.ml
(******************************************************************************) (* *) Alt - Ergo : The SMT Solver For Software Verification Copyright ( C ) 2020 - 2020 (* ...
null
https://raw.githubusercontent.com/OCamlPro/alt-ergo/695466427b5c3d48e92e90485b12c130c2bce2c1/src/lib/frontend/models.ml
ocaml
**************************************************************************** This file is distributed under the terms of the license indicated in the ...
Alt - Ergo : The SMT Solver For Software Verification Copyright ( C ) 2020 - 2020 open Format open Options module X = Shostak.Combine module Ac = Shostak.Ac module Ex = Explanation module Sy = Symbols module E = Expr module ME = Expr.Map module SE =...
36a421caefc95a219377ab57c73a46aa18b038ca4701b56127f3b0247dc45c41
AndrewMagerman/wizard-book-study
ch4-leval.rkt
;;;;LAZY EVALUATOR FROM SECTION 4.2 OF ;;;; STRUCTURE AND INTERPRETATION OF COMPUTER PROGRAMS ;;;;Matches code in ch4.scm ;;;; Also includes enlarged primitive-procedures list ;;;;This file can be loaded into Scheme as a whole. ;;;;**NOTE**This file loads the metacircular evaluator of sections 4.1.1 - 4.1.4 , sinc...
null
https://raw.githubusercontent.com/AndrewMagerman/wizard-book-study/77bf59e606df71281b321c5a6d1e6a400916c04d/missing_files/week_14/ch4-leval.rkt
racket
LAZY EVALUATOR FROM SECTION 4.2 OF STRUCTURE AND INTERPRETATION OF COMPUTER PROGRAMS Matches code in ch4.scm Also includes enlarged primitive-procedures list This file can be loaded into Scheme as a whole. **NOTE**This file loads the metacircular evaluator of environment representation, etc. You may need to chang...
sections 4.1.1 - 4.1.4 , since it uses the expression representation , the two lines at the end of the file ch4-mceval.scm To run without memoization , reload the first version of force - it below Note : It is loaded first so that the section 4.2 definition of eval overrides the definition from 4.1.1 (...
f443614df7873294a45be961d2a5ba20fca1e5a988201a15fc4659f532c8af33
webnf/webnf
project.clj
(defproject webnf.deps/logback "0.1.19-SNAPSHOT" :plugins [[lein-modules "0.3.11"]] :description "Basic slf4j logging config in form of a default logback.xml" :dependencies [[ch.qos.logback/logback-classic "1.1.6"] [org.slf4j/slf4j-api "LOGBACK" :upgrade false] [org.slf4j/log4j-o...
null
https://raw.githubusercontent.com/webnf/webnf/6a2ccaa755e6e40528eb13a5c36bae16ba4947e7/deps.logback/project.clj
clojure
(defproject webnf.deps/logback "0.1.19-SNAPSHOT" :plugins [[lein-modules "0.3.11"]] :description "Basic slf4j logging config in form of a default logback.xml" :dependencies [[ch.qos.logback/logback-classic "1.1.6"] [org.slf4j/slf4j-api "LOGBACK" :upgrade false] [org.slf4j/log4j-o...
250f2872174af7941fd137294aef18d03ff25ba0706223d556bd34339e151447
mirage/wodan
wodan_irmin_cli.ml
(********************************************************************************) Copyright 2017 - 2019 Gabriel de Perthuis < > (* *) (* Permission to use, copy, modify, and/or distribute this software for any *) (* p...
null
https://raw.githubusercontent.com/mirage/wodan/fd70abdb45fa176557178435217e0ab114e4e4d0/src/wodan-irmin/bin/wodan_irmin_cli.ml
ocaml
****************************************************************************** Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above co...
Copyright 2017 - 2019 Gabriel de Perthuis < > THE SOFTWARE IS PROVIDED " AS IS " AND THE AUTHOR DISCLAIMS ALL WARRANTIES WHATSOEVER RESULTING FROM LOSS OF USE , DATA OR PROFITS , WHETHER IN AN open Irmin_unix module RamBlockCon = struct include Ramdisk let connect name = Ramd...
76ca4e5c7e48154d979ed573a05ef1573fe204f07ce8ffa01529344faef288ee
bmourad01/ocamlchess
uci.ml
module M = Mutex module T = Thread open Core_kernel [@@warning "-D"] open Chess open Bap_future.Std open Monads.Std module Child = Position.Child module Histogram = Position.Histogram module Line = Search.Result.Line module State = struct module T = struct type t = { pos : Position.t; histogr...
null
https://raw.githubusercontent.com/bmourad01/ocamlchess/0496db8ad7dddd5a048fb4868aacff221a706238/chess/bin/uci.ml
ocaml
Artificial type to resolve ambiguity between the Combo and String constructors. The main search routine, should be run in a separate thread. Output the result. Thread completed. Abort if there's already a thread running. As a hack, ponder mode will initially be set up as an infinite search. Then,...
module M = Mutex module T = Thread open Core_kernel [@@warning "-D"] open Chess open Bap_future.Std open Monads.Std module Child = Position.Child module Histogram = Position.Histogram module Line = Search.Result.Line module State = struct module T = struct type t = { pos : Position.t; histogr...
69cf62f9ab93a93118b786efcb6d75171c4e784869855e1fb5666ecc05f4849d
janestreet/async_smtp
simplemail.mli
open! Core open! Async open Async_smtp_types module Envelope_status = Client.Envelope_status module Expert : sig val send_envelope : ?log:Log.t -> ?credentials:Credentials.t -> ?server:Host_and_port.t -> Smtp_envelope.t -> Envelope_status.t Deferred.Or_error.t val send' : ?log:Mail_log.t...
null
https://raw.githubusercontent.com/janestreet/async_smtp/72c538d76f5c7453bbc89af44d93931cd499a912/src/simplemail.mli
ocaml
defaults to <user@host> defaults to [from] defaults to <user@host> defaults to [from]
open! Core open! Async open Async_smtp_types module Envelope_status = Client.Envelope_status module Expert : sig val send_envelope : ?log:Log.t -> ?credentials:Credentials.t -> ?server:Host_and_port.t -> Smtp_envelope.t -> Envelope_status.t Deferred.Or_error.t val send' : ?log:Mail_log.t...
ba3c6d37ae75a55c9872b3b90a72fe52de441ecdaa1f774f611b7ce651eec9b0
ocamllabs/ocaml-modular-implicits
t140-switch-2.ml
open Lib;; match 1 with | 0 -> raise Not_found | 1 -> () | _ -> raise Not_found ;; * 0 CONSTINT 42 2 PUSHACC0 3 MAKEBLOCK1 0 5 POP 1 7 9 CONST1 10 11 SWITCH int 0 - > 17 int 1 - > 22 15 BRANCH 25 17 GETGLOBAL N...
null
https://raw.githubusercontent.com/ocamllabs/ocaml-modular-implicits/92e45da5c8a4c2db8b2cd5be28a5bec2ac2181f1/testsuite/tests/tool-ocaml/t140-switch-2.ml
ocaml
open Lib;; match 1 with | 0 -> raise Not_found | 1 -> () | _ -> raise Not_found ;; * 0 CONSTINT 42 2 PUSHACC0 3 MAKEBLOCK1 0 5 POP 1 7 9 CONST1 10 11 SWITCH int 0 - > 17 int 1 - > 22 15 BRANCH 25 17 GETGLOBAL N...
c4c8e3cbe0b110c0dbfc70859eda036be84a9600cfc773c6e8f32d2d8bf5de3d
ucsd-progsys/dsolve
bad-checklist.ml
let rec check l = match l with | [] -> () | x :: [] -> () | x :: y :: ys -> assert (x <= y); check (y :: ys) let _ = check [5; 2; 3]
null
https://raw.githubusercontent.com/ucsd-progsys/dsolve/bfbbb8ed9bbf352d74561e9f9127ab07b7882c0c/negtests/bad-checklist.ml
ocaml
let rec check l = match l with | [] -> () | x :: [] -> () | x :: y :: ys -> assert (x <= y); check (y :: ys) let _ = check [5; 2; 3]
c1144c0d0b322721a303f477b8fd1b294a3ebc9a1f1785cde6d799d8ebc216be
ocaml-multicore/ocaml-tsan
domain.ml
(**************************************************************************) (* *) (* OCaml *) (* *) , I...
null
https://raw.githubusercontent.com/ocaml-multicore/ocaml-tsan/ae9c1502103845550162a49fcd3f76276cdfa866/stdlib/domain.ml
ocaml
************************************************************************ OCaml ...
, Indian Institute of Technology , Madras , University of Cambridge , OCaml Labs Consultancy Copyright 2019 Indian Institute of Technology , Madras Copyright 2014 University of Cambridge ...
b5a56abd287ed45524cb74359c864004c30adf7c51d146804788002aeda5096c
jwiegley/notes
snippets.hs
splitString :: String -> String -> [String] splitString = split' [] where split' acc s str@(x:xs) | s `isPrefixOf` str = acc : split' [] s (drop (length s) str) | otherwise = split' (acc ++ [x]) s xs split' acc _ [] = [acc]
null
https://raw.githubusercontent.com/jwiegley/notes/24574b02bfd869845faa1521854f90e4e8bf5e9a/gists/f719a3d41696d48f6005/gists/83337/snippets.hs
haskell
splitString :: String -> String -> [String] splitString = split' [] where split' acc s str@(x:xs) | s `isPrefixOf` str = acc : split' [] s (drop (length s) str) | otherwise = split' (acc ++ [x]) s xs split' acc _ [] = [acc]
187d017d874273926a41ebe7a62b503a6cbb3fa500862a358b8c6061a4f7f35f
froggey/Mezzano
complex.lisp
;;;; Complex numbers (in-package :mezzano.internals.numbers.complex) (declaim (inline complexp)) (defun complexp (object) (int::%object-of-type-range-p object int::+first-complex-object-tag+ int::+last-complex-object-tag+)) (defun complex (realpart &optional imagpart) (check-type realpart real) (check...
null
https://raw.githubusercontent.com/froggey/Mezzano/d506e0c3b9efcddd39155bfdd77d9f025c60930b/system/numbers/complex.lisp
lisp
Complex numbers
(in-package :mezzano.internals.numbers.complex) (declaim (inline complexp)) (defun complexp (object) (int::%object-of-type-range-p object int::+first-complex-object-tag+ int::+last-complex-object-tag+)) (defun complex (realpart &optional imagpart) (check-type realpart real) (check-type imagpart (or re...
33789ec476ee5f256f5b2f04da696cf48eb822e12269ea21f7351f5979e854f4
pedrovgs/HaskellKatas
Main.hs
module PrimeFactors.Main where import PrimeFactors.PrimeFactors main = do print "Prime factors:" let factorsOf1 = primeFactors 1 let factorsOf11 = primeFactors 11 let factorsOf66 = primeFactors 66 let factorsOfNegatie = primeFactors (-1) print ("Prime factor...
null
https://raw.githubusercontent.com/pedrovgs/HaskellKatas/79ecaeecf80e71c44cfa06692f56dd3a6d1c7308/app/PrimeFactors/Main.hs
haskell
module PrimeFactors.Main where import PrimeFactors.PrimeFactors main = do print "Prime factors:" let factorsOf1 = primeFactors 1 let factorsOf11 = primeFactors 11 let factorsOf66 = primeFactors 66 let factorsOfNegatie = primeFactors (-1) print ("Prime factor...
485b38d994b0fca024da358f6f7805c166ceace7e9344255145cbb9a2e8c38c9
birthevdb/Latent-Effect-and-Handlers
CallByValue.hs
# LANGUAGE TypeOperators # # LANGUAGE FlexibleContexts # {-# LANGUAGE RankNTypes #-} module Features.CallByValue where import General import Effects.Abstraction import Prelude hiding (abs) data LamExpr e = VarExpr Int | AbsExpr e | AppExpr e e lamAlg :: (Abstracting v :<<: σ) => LamExpr (Tree σ Id v) -> Tree σ Id ...
null
https://raw.githubusercontent.com/birthevdb/Latent-Effect-and-Handlers/398167aa3a18572afa1ecc9ecdd6b37c97495f90/Features/CallByValue.hs
haskell
# LANGUAGE RankNTypes #
# LANGUAGE TypeOperators # # LANGUAGE FlexibleContexts # module Features.CallByValue where import General import Effects.Abstraction import Prelude hiding (abs) data LamExpr e = VarExpr Int | AbsExpr e | AppExpr e e lamAlg :: (Abstracting v :<<: σ) => LamExpr (Tree σ Id v) -> Tree σ Id v lamAlg (VarExpr n) = ...
9fcc4790aa713675e4e6f08b4c5328e98fd082babb8922fb2a08dc365c4af2bd
JonathanLorimer/weft
Resolve.hs
module Weft.Generics.Resolve ( HasResolve , resolve ) where import qualified Data.Map as M import Data.Text (Text) import GHC.Generics import Weft.Internal.Types hiding (query) ------------------------------------------------------------------------------ -- | type HasResolve reco...
null
https://raw.githubusercontent.com/JonathanLorimer/weft/fc0396240905ab0202c5896019cf1e482d216f8d/src/Weft/Generics/Resolve.hs
haskell
---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | | Q, RV1, RP3 -----------------------------------------------------------------...
module Weft.Generics.Resolve ( HasResolve , resolve ) where import qualified Data.Map as M import Data.Text (Text) import GHC.Generics import Weft.Internal.Types hiding (query) type HasResolve record = ( GResolve (J record 'Resolver) (J record 'Query) (...
fc81cf4b9a4e77af88ae1109cecb0478c091d944d6d9234d65419ba7cd9229cb
duelinmarkers/insfactor
zip_test.clj
(ns duelinmarkers.insfactor.zip-test (:use clojure.test duelinmarkers.insfactor.zip)) (deftest of-zipper-seq (is (= [[1 [2 3] 4] 1 [2 3] 2 3 4] (zipper-seq (clojure.zip/vector-zip [1 [2 3] 4])))) (is (= [[]] (zipper-seq (clojure.zip/vector-zip [])))))
null
https://raw.githubusercontent.com/duelinmarkers/insfactor/8085c4e582735f928752cbed9f5957cf95321e57/test/duelinmarkers/insfactor/zip_test.clj
clojure
(ns duelinmarkers.insfactor.zip-test (:use clojure.test duelinmarkers.insfactor.zip)) (deftest of-zipper-seq (is (= [[1 [2 3] 4] 1 [2 3] 2 3 4] (zipper-seq (clojure.zip/vector-zip [1 [2 3] 4])))) (is (= [[]] (zipper-seq (clojure.zip/vector-zip [])))))
9de5df3b789e3c4b539796d6cb43be43a8eb3da2dee1c0119cd906c92300b13f
JacquesCarette/Drasil
ClassInterface.hs
# LANGUAGE TypeFamilies # | Defines a package extension for GOOL , with functions for pairing a GOOL -- program with auxiliary, non-source-code files. module Language.Drasil.Code.Imperative.GOOL.ClassInterface ( ReadMeInfo(..), Typeclasses PackageSym(..), AuxiliarySym(..) ) where import Language.Drasil (Expr)...
null
https://raw.githubusercontent.com/JacquesCarette/Drasil/84272acccc09574dec70d8d96c6ea994f15f8b22/code/drasil-code/lib/Language/Drasil/Code/Imperative/GOOL/ClassInterface.hs
haskell
program with auxiliary, non-source-code files. | Members of this class must have all the information necessary for auxiliary helper documents, and auxiliary from data documents. | Language name. | Programming language version. | Case name. | Purpose of example | Description of example | File contributors | Ho...
# LANGUAGE TypeFamilies # | Defines a package extension for GOOL , with functions for pairing a GOOL module Language.Drasil.Code.Imperative.GOOL.ClassInterface ( ReadMeInfo(..), Typeclasses PackageSym(..), AuxiliarySym(..) ) where import Language.Drasil (Expr) import Database.Drasil (ChunkDB) import Language....
ea0f8c773c70a72fde24ff0e650fa04e7013bf4cf3df4ff22d3a3dccdb74f1ba
shayne-fletcher/zen
flows.ml
type flow = { flow_start : Dates.t ; flow_end : Dates.t ; flow_pay : Dates.t ; flow_accrual : float ; } ;; let rec parse_flow = parser [< 'Genlex.Kwd "{" ; s = Dates.parse_date ; 'Genlex.Kwd ";" ; e = Dates.parse_date ; 'Genlex.Kwd ";" ; p = Dates.parse_date ; 'Genlex.Kwd ";" ...
null
https://raw.githubusercontent.com/shayne-fletcher/zen/10a1d0b9bf261bb133918dd62fb1593c3d4d21cb/ocaml/curve/flows.ml
ocaml
type flow = { flow_start : Dates.t ; flow_end : Dates.t ; flow_pay : Dates.t ; flow_accrual : float ; } ;; let rec parse_flow = parser [< 'Genlex.Kwd "{" ; s = Dates.parse_date ; 'Genlex.Kwd ";" ; e = Dates.parse_date ; 'Genlex.Kwd ";" ; p = Dates.parse_date ; 'Genlex.Kwd ";" ...
b006f6ce9ef862284f164007be61d483ee04c0cc0e008b9c5bf3267944daeb86
antoniogarrote/levanzo
validation.clj
(ns levanzo.validation)
null
https://raw.githubusercontent.com/antoniogarrote/levanzo/53a8fa134099b3ad6310bfc3493cc1fb9eb38f2f/src/levanzo/validation.clj
clojure
(ns levanzo.validation)
69ea70eb538df625d9ecc48f037cecd734cd699fb13517dffe92abd791ee3a4c
turtlesoupy/haskakafka
Haskakafka.hs
module Haskakafka ( fetchBrokerMetadata , withKafkaConsumer , consumeMessage , consumeMessageBatch , withKafkaProducer , produceMessage , produceKeyedMessage , produceMessageBatch , storeOffset , seekToOffset , getAllMetadata , getTopicMetadata , handleProduceErr , producePartitionInteger , pollEvents , pollEventsSafe ...
null
https://raw.githubusercontent.com/turtlesoupy/haskakafka/cae3348be1a3934629cf58d433c224d87ff59608/src/Haskakafka.hs
haskell
Internal objects Type re-exports Pseudo-internal | Adds a broker string to a given kafka instance. You probably shouldn't use this directly (see 'withKafkaConsumer' and 'withKafkaProducer') | Starts consuming for a given topic. You probably do not need to call this directly (it is called automatically by 'withK...
module Haskakafka ( fetchBrokerMetadata , withKafkaConsumer , consumeMessage , consumeMessageBatch , withKafkaProducer , produceMessage , produceKeyedMessage , produceMessageBatch , storeOffset , seekToOffset , getAllMetadata , getTopicMetadata , handleProduceErr , producePartitionInteger , pollEvents , pollEventsSafe ...
d691a3086a82cba6af209a0b0e2847d3a6e34b43f7cbb6b0a0e62a9842c4d9bf
jlouis/combinatorrent
RateCalc.hs
-- | Rate calculation. {-# LANGUAGE BangPatterns #-} module RateCalc ( -- * Types Rate -- * Interface , new , update , extractCount , extractRate ) where import Control.DeepSeq import Data.Time.Clock -- | A Rate is a record of information used for calculating the rate data Rate = Ra...
null
https://raw.githubusercontent.com/jlouis/combinatorrent/a8660bc29507f3774d79bd364b8b509cf5146282/src/RateCalc.hs
haskell
| Rate calculation. # LANGUAGE BangPatterns # * Types * Interface | A Rate is a record of information used for calculating the rate ^ The current rate ^ The amount of bytes transferred since last rate extraction ^ The amount of bytes transferred since last count extraction ^ When was the last rate update ^ Fro...
module RateCalc ( Rate , new , update , extractCount , extractRate ) where import Control.DeepSeq import Data.Time.Clock data Rate = Rate } instance NFData Rate where rnf (Rate r b c _ _) = rnf r `seq` rnf b `seq` rnf c fudge :: NominalDiffTime maxRatePeriod :: NominalDif...
18971eaed33612c03fb6a40eb87eac117c1b6f6d21f3921d6ab3252102ae0174
jrh13/hol-light
mccarthy.ml
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * mp.ml * * An HOL mechanization of the compiler correctness proof of and * Painter from 1967 . * * From a HOL-4 original by and * * ...
null
https://raw.githubusercontent.com/jrh13/hol-light/ea44a4cacd238d7fa5a397f043f3e3321eb66543/Examples/mccarthy.ml
ocaml
------------------------------------------------------------------------- We don't use any particular properties of the type in the proof below. ------------------------------------------------------------------------- ------------------------------------------------------------------------- ---------------...
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * mp.ml * * An HOL mechanization of the compiler correctness proof of and * Painter from 1967 . * * From a HOL-4 original by and * * ...
d98e4ef1d69e4f4a014ef726671d48c02eb2067d98ae1e29879209029f8f6261
takikawa/racket-ppa
mutated.rkt
#lang racket/base (require "wrap.rkt" "match.rkt" "known.rkt" "import.rkt" "simple.rkt" "find-definition.rkt" "struct-type-info.rkt" "mutated-state.rkt" "find-known.rkt" "infer-known.rkt" "letrec.rkt" "id-to-var.rkt" ...
null
https://raw.githubusercontent.com/takikawa/racket-ppa/5f2031309f6359c61a8dfd1fec0b77bbf9fb78df/src/schemify/mutated.rkt
racket
See "mutated-state.rkt" for information on the content of the `mutated` table. We don't have to worry about errors or escapes that prevent the definition of an identifier, because that will abort the enclosing linklet. This pass is also responsible for recording when a letrec binding must be mutated implicitly v...
#lang racket/base (require "wrap.rkt" "match.rkt" "known.rkt" "import.rkt" "simple.rkt" "find-definition.rkt" "struct-type-info.rkt" "mutated-state.rkt" "find-known.rkt" "infer-known.rkt" "letrec.rkt" "id-to-var.rkt" ...
172833a47ba32e34b70e5aa5e1f408834af5302352391ac68422e378fce61b76
ocaml-sf/learn-ocaml-corpus
conn_other_sense.ml
let var x = FVar x let falsity = FConst false let truth = FConst true let const sense = if sense then truth else falsity (* [FConst sense] would work too, but would allocate memory *) let neg f = match f with | FConst sense -> const (not sense) | FNeg f -> f | _ -> FNeg f let ...
null
https://raw.githubusercontent.com/ocaml-sf/learn-ocaml-corpus/7dcf4d72b49863a3e37e41b3c3097aa4c6101a69/exercises/fpottier/sat/wrong/conn_other_sense.ml
ocaml
[FConst sense] would work too, but would allocate memory wrong: failure to treat the case where [sense = sense']
let var x = FVar x let falsity = FConst false let truth = FConst true let const sense = if sense then truth else falsity let neg f = match f with | FConst sense -> const (not sense) | FNeg f -> f | _ -> FNeg f let conn sense f1 f2 = match f1, f2 with | FConst sense', f | f, ...
2848322185ab3e5c374fc57baf84d971b798933f02be262c95370cd1e6af87e3
orionsbelt-battlegrounds/obb-rules
worm.cljc
(ns obb-rules.units.worm) (def metadata {:name "worm" :code "w" :attack 1200 :defense 1200 :range 3 :value 25 :type :organic :category :medium :displacement :ground :movement-type :all :movement-cost 2})
null
https://raw.githubusercontent.com/orionsbelt-battlegrounds/obb-rules/97fad6506eb81142f74f4722aca58b80d618bf45/src/obb_rules/units/worm.cljc
clojure
(ns obb-rules.units.worm) (def metadata {:name "worm" :code "w" :attack 1200 :defense 1200 :range 3 :value 25 :type :organic :category :medium :displacement :ground :movement-type :all :movement-cost 2})
b1add667f04e069b5c3b8bee18e1351deab15bcb77bd06c410c5ac3a10f895cf
threatgrid/ctia
graphql_schemas.clj
(ns ctia.entity.tool.graphql-schemas (:require [ctia.entity.feedback.graphql-schemas :as feedback] [ctia.entity.relationship.graphql-schemas :as relationship] [ctia.schemas.graphql [flanders :as flanders] [helpers :as g] [pagination :as pagination] ...
null
https://raw.githubusercontent.com/threatgrid/ctia/32857663cdd7ac385161103dbafa8dc4f98febf0/src/ctia/entity/tool/graphql_schemas.clj
clojure
(ns ctia.entity.tool.graphql-schemas (:require [ctia.entity.feedback.graphql-schemas :as feedback] [ctia.entity.relationship.graphql-schemas :as relationship] [ctia.schemas.graphql [flanders :as flanders] [helpers :as g] [pagination :as pagination] ...
68b5610cf0371e1355c17d786b069f0909482bfc76cfdea9bb35f9f703ad6dcd
Soostone/instrument
Utils.hs
{-# LANGUAGE OverloadedStrings #-} # LANGUAGE NoMonomorphismRestriction # module Instrument.Utils ( formatDecimal, formatInt, showT, showBS, collect, noDots, encodeCompress, decodeCompress, indefinitely, seconds, milliseconds, for, ) where ------------------------------...
null
https://raw.githubusercontent.com/Soostone/instrument/a82d1764aad18881c6815c2ee2a55f3f5381c8f5/instrument/src/Instrument/Utils.hs
haskell
# LANGUAGE OverloadedStrings # ----------------------------------------------------------------------------- ----------------------------------------------------------------------------- ----------------------------------------------------------------------------- -------------------------------------------------------...
# LANGUAGE NoMonomorphismRestriction # module Instrument.Utils ( formatDecimal, formatInt, showT, showBS, collect, noDots, encodeCompress, decodeCompress, indefinitely, seconds, milliseconds, for, ) where import Codec.Compression.GZip import Control.Applicative ((<|>)) ...
6d0af2da3251a5da1c0bba8deced0f06e5da36d4d8408a68fddf84bdf2bb83b6
uim/uim
test-uim-test-utils.scm
#!/usr/bin/env gosh Copyright ( c ) 2003 - 2013 uim Project ;;; ;;; 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...
null
https://raw.githubusercontent.com/uim/uim/d1ac9d9315ff8c57c713b502544fef9b3a83b3e5/test/test-uim-test-utils.scm
scheme
All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: notice, this list of conditions and the following disclaimer. notice, this list of conditions and the following disclaimer in the document...
#!/usr/bin/env gosh Copyright ( c ) 2003 - 2013 uim Project 1 . Redistributions of source code must retain the above copyright 2 . Redistributions in binary form must reproduce the above copyright 3 . Neither the name of authors nor the names of its contributors THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HO...
379e8622d028b64d722e62b1b119a3721bb487327556ca6ff2e12edccdda8052
facebook/duckling
ZH_MO.hs
Copyright ( c ) 2016 - present , Facebook , Inc. -- All rights reserved. -- -- This source code is licensed under the BSD-style license found in the -- LICENSE file in the root directory of this source tree. An additional grant of patent rights can be found in the PATENTS file in the same directory . -------------...
null
https://raw.githubusercontent.com/facebook/duckling/72f45e8e2c7385f41f2f8b1f063e7b5daa6dca94/Duckling/Ranking/Classifiers/ZH_MO.hs
haskell
All rights reserved. This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree. An additional grant --------------------------------------------------------------- Auto-generated by regenClassifiers DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW W...
Copyright ( c ) 2016 - present , Facebook , Inc. of patent rights can be found in the PATENTS file in the same directory . @generated module Duckling.Ranking.Classifiers.ZH_MO (classifiers) where import Data.String import Prelude import qualified Data.HashMap.Strict as HashMap import Duckling.Ranking.Types cla...
9f6e5338222f129972701972b80d54a2bc195c45953c6a8c481352b0e4a25cae
Errorific/haskell-script-examples
tee.hs
module Main where import Control.Monad (liftM) import Data.Foldable (forM_) import Options.Applicative (Parser, ParserInfo, argument, execParser, fullDesc, header, help, helper, info, long, metavar, progDesc, short, some, str, switch, (<*>), (<>)) imp...
null
https://raw.githubusercontent.com/Errorific/haskell-script-examples/0704e801183487427231e04a99e64b616beeba85/src/tee.hs
haskell
tee run the parser over the cli argumentts Pick file mode based on option Open all the mentioned output files start reading lines from std in for each line, run hsPutStrLn for stdout and all output files close all the open output files so they flush print a line to all file handles structure to hold cli argume...
module Main where import Control.Monad (liftM) import Data.Foldable (forM_) import Options.Applicative (Parser, ParserInfo, argument, execParser, fullDesc, header, help, helper, info, long, metavar, progDesc, short, some, str, switch, (<*>), (<>)) imp...
fa2ab796a614d076ce7f097a2b671ddac57a66bbb6511a1dd4f763e526927513
bmeurer/ocaml-experimental
builtini_GetCursor.ml
##ifdef CAMLTK let cCAMLtoTKcolor = function NamedColor x -> TkToken x | Black -> TkToken "black" | White -> TkToken "white" | Red -> TkToken "red" | Green -> TkToken "green" | Blue -> TkToken "blue" | Yellow -> TkToken "yellow" ;; let cTKtoCAMLcolor = function ...
null
https://raw.githubusercontent.com/bmeurer/ocaml-experimental/fe5c10cdb0499e43af4b08f35a3248e5c1a8b541/otherlibs/labltk/builtin/builtini_GetCursor.ml
ocaml
##ifdef CAMLTK let cCAMLtoTKcolor = function NamedColor x -> TkToken x | Black -> TkToken "black" | White -> TkToken "white" | Red -> TkToken "red" | Green -> TkToken "green" | Blue -> TkToken "blue" | Yellow -> TkToken "yellow" ;; let cTKtoCAMLcolor = function ...
ca9c95cc9f8c745751740c73241d69e80edf7b4c2a18b99f561f030508207aab
ertugrulcetin/procedure.async
common.cljc
(ns favorite-songs.common (:require #?@(:cljs [[re-frame.core :refer [subscribe]] [favorite-songs.network :refer [dispatch-pro]] [favorite-songs.subs]] :clj [[procedure.async :refer [reg-pro register-validation-fn!]] [malli.core :as...
null
https://raw.githubusercontent.com/ertugrulcetin/procedure.async/6c3c42342252934224e471344b8e118f64306b84/examples/favorite-songs/src/cljc/favorite_songs/common.cljc
clojure
(ns favorite-songs.common (:require #?@(:cljs [[re-frame.core :refer [subscribe]] [favorite-songs.network :refer [dispatch-pro]] [favorite-songs.subs]] :clj [[procedure.async :refer [reg-pro register-validation-fn!]] [malli.core :as...
9e0741f7c36326149e27e26f3caf025d404f4981ea1412cfe14d152a6fc68fb9
brendanhay/gogol
Getsupportedholidays.hs
# LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # # LANGUAGE DerivingStrategies # # LANGUAGE DuplicateRecordFields # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE PatternSynonyms # # LANGUAGE RecordWildCards # {-# LANGUAGE St...
null
https://raw.githubusercontent.com/brendanhay/gogol/fffd4d98a1996d0ffd4cf64545c5e8af9c976cda/lib/services/gogol-shopping-content/gen/Gogol/ShoppingContent/Content/Shippingsettings/Getsupportedholidays.hs
haskell
# LANGUAGE OverloadedStrings # # LANGUAGE StrictData # | Stability : auto-generated Retrieves supported holidays for an account. * Resource ** Constructing a Request 'ContentShippingsettingsGetsupportedholidays' request conforms to. | Retrieves supported holidays for an account. /See:/ 'newContentShippings...
# LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # # LANGUAGE DerivingStrategies # # LANGUAGE DuplicateRecordFields # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # # LANGUAGE PatternSynonyms # # LANGUAGE RecordWildCards # # LANGUAGE TypeFamilies # # LANGUAGE TypeOperators...
7aef190cceda830eafcf568e88ca7d85849421c522ef29ac172351dc875781dc
namin/biohacker
mlang.lisp
;; -*- Mode: Lisp; -*- Modeling language for TGizmo Last Edited : 11/7/91 , by KDF Copyright ( c ) 1991 , , Northwestern University , and , the Xerox Corporation . All Rights Reserved . ;;; See the file legal.txt for a paragraph stating scope of permission ;;; and disclaimer of warranty. The above ...
null
https://raw.githubusercontent.com/namin/biohacker/6b5da4c51c9caa6b5e1a68b046af171708d1af64/BPS/tgizmo/mlang.lisp
lisp
-*- Mode: Lisp; -*- See the file legal.txt for a paragraph stating scope of permission and disclaimer of warranty. The above copyright notice and that paragraph must be included in any separate copy of this file. Working with views and processes Does some extra syntactic checks Make sure no dangling variables ...
Modeling language for TGizmo Last Edited : 11/7/91 , by KDF Copyright ( c ) 1991 , , Northwestern University , and , the Xerox Corporation . All Rights Reserved . (in-package :COMMON-LISP-USER) (defun keywordize (stuff) (cond ((null stuff) (error "Can't keywordize nothing.")) ((listp stuff) (ke...
c0d5096363e96f365ee3a95d3a62d6be072a446c7eb2c6c2d61aa8631ad5d8d2
janestreet/core
gc.ml
open! Import module Stable = struct module Allocation_policy = struct module V1 = struct type t = | Next_fit | First_fit | Best_fit [@@deriving bin_io, compare, equal, hash, sexp, stable_witness] end end module Stat = struct [%%if ocaml_version < (4, 12, 0)] ...
null
https://raw.githubusercontent.com/janestreet/core/f382131ccdcb4a8cd21ebf9a49fa42dcf8183de6/core/src/gc.ml
ocaml
The compiler won't optimize int_of_string away so it won't perform constant folding below. We wrap [f ()] with [Sys.opaque_identity] to prevent the return value from being optimized away. Instead of using [Allocation_report.measure], and matching on the result, we use this construction, in order t...
open! Import module Stable = struct module Allocation_policy = struct module V1 = struct type t = | Next_fit | First_fit | Best_fit [@@deriving bin_io, compare, equal, hash, sexp, stable_witness] end end module Stat = struct [%%if ocaml_version < (4, 12, 0)] ...
a78a3a977c9e31f215f397ea58aede05d7a8f4794a48374aadc0dab4f169df57
Ericson2314/lighthouse
Cutil_12.hs
# OPTIONS_GHC -cpp # -- #hide ----------------------------------------------------------------------------- -- Module : OS.Cutil_12 Copyright : ( c ) 2002 -- License : BSD-style -- -- Maintainer : -- Stability : provisional -- Portability : portable -- -- This module contains some additiona...
null
https://raw.githubusercontent.com/Ericson2314/lighthouse/210078b846ebd6c43b89b5f0f735362a01a9af02/ghc-6.8.2/libraries/ObjectIO/Graphics/UI/ObjectIO/OS/Cutil_12.hs
haskell
#hide --------------------------------------------------------------------------- Module : OS.Cutil_12 License : BSD-style Maintainer : Stability : provisional Portability : portable This module contains some additional routines required for marshalling ------------------------------------...
# OPTIONS_GHC -cpp # Copyright : ( c ) 2002 arguments to OS C calling routines . module Graphics.UI.ObjectIO.OS.Cutil_12 ( addr2int, int2addr, fpeek, Storable(..), free, malloc , module Data.Int , module Data.Bits , module Foreign.Ptr , module Foreign.C.String ) where import Foreign.Ptr impo...
dccf2d4452acd886fe21b21d0a1a6d055418adb292edb4d05c2dc7086e8d02ed
pixlsus/registry.gimp.org_static
clairs-obscurs.scm
(define (script-fu-shadows-highlights image drawable) ; create a highlights layer (let ((highlights-layer (car (gimp-layer-copy drawable 1)))) (gimp-drawable-set-name highlights-layer "Assombrir les lumières") (gimp-image-add-layer image highlights-layer -1) ;process shadows/highlights layer (gimp-desaturate highligh...
null
https://raw.githubusercontent.com/pixlsus/registry.gimp.org_static/ffcde7400f402728373ff6579947c6ffe87d1a5e/registry.gimp.org/files/clairs-obscurs.scm
scheme
create a highlights layer process shadows/highlights layer copy highlights layer to create shadows layer process highlights layer process shadows layer update image window
(define (script-fu-shadows-highlights image drawable) (let ((highlights-layer (car (gimp-layer-copy drawable 1)))) (gimp-drawable-set-name highlights-layer "Assombrir les lumières") (gimp-image-add-layer image highlights-layer -1) (gimp-desaturate highlights-layer) (gimp-invert highlights-layer) (gimp-layer-set-mode ...
ec54658ee279f66e0bf73ead6a180d01d3b0e0c853d427dfba657775dbdb7ae9
8c6794b6/guile-tjit
transform.scm
( sxml transform ) -- pre- and post - order sxml transformation ;;;; Copyright ( C ) 2009 Free Software Foundation , Inc. Modified 2004 by < wingo at pobox dot com > . Written 2003 by < oleg at pobox dot com > as SXML-tree-trans.scm . ;;;; ;;;; This library is free software; you can redistribute i...
null
https://raw.githubusercontent.com/8c6794b6/guile-tjit/9566e480af2ff695e524984992626426f393414f/module/sxml/transform.scm
scheme
This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public either This library 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. ...
( sxml transform ) -- pre- and post - order sxml transformation Copyright ( C ) 2009 Free Software Foundation , Inc. Modified 2004 by < wingo at pobox dot com > . Written 2003 by < oleg at pobox dot com > as SXML-tree-trans.scm . version 3 of the License , or ( at your option ) any later version ...