_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
f99e281dbc75381fb0ce3a4de55d71a92c6351ee78cf84cc474d0b162175e9f1
interstar/cardigan-bay
command_line.cljc
(ns clj-ts.command-line (:require [instaparse.core :as insta])) (def parse (insta/parser " <Command> = <'!'> <space> Move | <'!'> Tags Move = <'>>'> PageName Tags = (<space> Tag)* PageName = Name Tag = <'+'> Name <Name> = #'[A-Za-z0-9]+' space = #'\\s+' ")) (defn parser [s] (let [parsed (pars...
null
https://raw.githubusercontent.com/interstar/cardigan-bay/e4767d300dd23ed011aa25403f924d7bfe5cb30c/src/clj_ts/command_line.cljc
clojure
(flatten (map keyword raw-tags))
(ns clj-ts.command-line (:require [instaparse.core :as insta])) (def parse (insta/parser " <Command> = <'!'> <space> Move | <'!'> Tags Move = <'>>'> PageName Tags = (<space> Tag)* PageName = Name Tag = <'+'> Name <Name> = #'[A-Za-z0-9]+' space = #'\\s+' ")) (defn parser [s] (let [parsed (pars...
4c9188267b1eed7bf31f6bd4dc25aef3a7dbbc0e024f92d396a87b5e36c778ad
jonathan-laurent/KaFlow
causal_core.mli
open Causal_core_shared type sigma_event_info = { number_added : int } type causal_core = (step_id * sigma_event_info) list type t = causal_core val core_events : causal_core -> step_id list { 6 Simple interface } val iter_causal_cores : Trace_explorer.t -> step_id list -> (step_id -> causal_core -> unit...
null
https://raw.githubusercontent.com/jonathan-laurent/KaFlow/e81cfbe4f270b9f0c94b7002b02dd5be61041ab8/src/causal_core.mli
ocaml
open Causal_core_shared type sigma_event_info = { number_added : int } type causal_core = (step_id * sigma_event_info) list type t = causal_core val core_events : causal_core -> step_id list { 6 Simple interface } val iter_causal_cores : Trace_explorer.t -> step_id list -> (step_id -> causal_core -> unit...
122b486220aa1e0e281af5ea6dacaa9619080590bff2d85b260375409d51680d
aryx/xix
stack.ml
(***********************************************************************) (* *) (* Objective Caml *) (* *) , projet ...
null
https://raw.githubusercontent.com/aryx/xix/60ce1bd9a3f923e0e8bb2192f8938a9aa49c739c/lib_core/collections/todo/stack.ml
ocaml
********************************************************************* Objective Caml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et Automatique . Distributed only by permission . $ I d : stack.ml , v 1.4 1996/04/30 14:50:37 xleroy Exp $ type 'a t = { mutable c : 'a list } exception Empt...
d1f7237a12d80eb45ac852ff483c733032fa49c3321766df3c77caa88f42f411
fukamachi/cl-cookie
cl-cookie.lisp
(in-package :cl-user) (defpackage cl-cookie-test (:use :cl :cl-cookie :prove) (:import-from :cl-cookie :parse-cookie-date :match-cookie-path :match-cookie)) (in-package :cl-cookie-test) (plan nil) (subtest "parse-cookie-date" (loop for (date . rfc3...
null
https://raw.githubusercontent.com/fukamachi/cl-cookie/e6babbf57c9c6e0b6998a5b5ecaea8fa59f88296/t/cl-cookie.lisp
lisp
(in-package :cl-user) (defpackage cl-cookie-test (:use :cl :cl-cookie :prove) (:import-from :cl-cookie :parse-cookie-date :match-cookie-path :match-cookie)) (in-package :cl-cookie-test) (plan nil) (subtest "parse-cookie-date" (loop for (date . rfc3...
b752eccad642fb7e0d7970d48f17255d989deab60360998d748660128e433219
naoiwata/sicp
ex3.65.scm
;; ;; @author naoiwata SICP Chapter3 Exercise 3.65 . ;; ; ------------------------------------------------------------------------ ; solution ; ------------------------------------------------------------------------ (add-load-path "./pages/" :relative) (load "stream.scm") (load "3.5.2.scm") (define (ln-summands...
null
https://raw.githubusercontent.com/naoiwata/sicp/7314136c5892de402015acfe4b9148a3558b1211/chapter3/ex3.65.scm
scheme
@author naoiwata ------------------------------------------------------------------------ solution ------------------------------------------------------------------------ ------------------------------------------------------------------------ test -------------------------------------------------------------...
SICP Chapter3 Exercise 3.65 . (add-load-path "./pages/" :relative) (load "stream.scm") (load "3.5.2.scm") (define (ln-summands n) (cons-stream (/ 1.0 n) (stream-map - (ln-summands (+ n 1))))) (define ln-stream (partial-sums (ln-summands 1))) (map (lambda (x) (print (stream-ref ln-stream x...
498972cfb4506ad843ce267ccfafd70151d73e347c2626460bcb1ce59ec53cff
wedesoft/aiscm
xorg_scale_list.scm
(use-modules (aiscm magick) (aiscm xorg) (aiscm core)) (define img (read-image "fubk.png")) (show (list (* (rgb 1 0 0) img) (* (rgb 0 1 0) img) (* (rgb 0 0 1) img)) #:shape '(120 160))
null
https://raw.githubusercontent.com/wedesoft/aiscm/2c3db8d00cad6e042150714ada85da19cf4338ad/tests/integration/xorg_scale_list.scm
scheme
(use-modules (aiscm magick) (aiscm xorg) (aiscm core)) (define img (read-image "fubk.png")) (show (list (* (rgb 1 0 0) img) (* (rgb 0 1 0) img) (* (rgb 0 0 1) img)) #:shape '(120 160))
e2d742559ca6f13f8e6f664b4a926961c97beec321f8c4206bf3e05dc45a8ffc
PapenfussLab/bioshake
Samtools.hs
{-# LANGUAGE DataKinds #-} {-# LANGUAGE FlexibleContexts #-} # LANGUAGE FlexibleInstances # # LANGUAGE GADTs # # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE TypeOperators #-} module Bioshake.Cluster.Samtools where import ...
null
https://raw.githubusercontent.com/PapenfussLab/bioshake/afeb7219b171e242b6e9bb9e99e2f80c0a099aff/Bioshake/Cluster/Samtools.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # # LANGUAGE TemplateHaskell # # LANGUAGE TypeOperators #
# LANGUAGE FlexibleInstances # # LANGUAGE GADTs # # LANGUAGE MultiParamTypeClasses # module Bioshake.Cluster.Samtools where import Bioshake import Bioshake.Cluster.Torque import Bioshake.Internal.Samtools import Bioshake.TH import Development.Shak...
d7619a7d9473959da74c1f51f465c4b950654efd33cc9226d6596e0304fa80d9
deadpendency/deadpendency
CanDetermineDependencies.hs
module DD.Effect.DetermineDependencies.Backend.Model.CanDetermineDependencies ( CanDetermineDependencies (..), CDDWrapper (..), ) where import Common.Model.Dependency.Basic.BasicDependency import Common.Model.Git.GitPath import DD.Effect.DetermineDependencies.Model.DetermineDependenciesError import Data.Vector...
null
https://raw.githubusercontent.com/deadpendency/deadpendency/170d6689658f81842168b90aa3d9e235d416c8bd/apps/dependency-determiner/src/DD/Effect/DetermineDependencies/Backend/Model/CanDetermineDependencies.hs
haskell
module DD.Effect.DetermineDependencies.Backend.Model.CanDetermineDependencies ( CanDetermineDependencies (..), CDDWrapper (..), ) where import Common.Model.Dependency.Basic.BasicDependency import Common.Model.Git.GitPath import DD.Effect.DetermineDependencies.Model.DetermineDependenciesError import Data.Vector...
dcffc9d28c9d01cadf422c6c9f77ad33289a07a6579401099cc3052e2278947a
qitab/pyjure
mop.clj
(ns pyjure.mop (:require [clojure.core :as c] [clojure.string :as str]) (:use [clojure.core.match :only [match]] [pyjure.debug] [pyjure.utilities] [pyjure.names])) ;; Meta-Object Protocol for pyjure objects ;; #customization ;; #object.__dict__ ;; TODO: ;; * most everything ;;...
null
https://raw.githubusercontent.com/qitab/pyjure/b9aa49b4f74c85f2b617e924f61eaddb194119bf/src/pyjure/mop.clj
clojure
Meta-Object Protocol for pyjure objects #customization #object.__dict__ TODO: * most everything * somehow use keywords as keys for python object fields, rather than strings, since they are much faster (being interned makes comparison trivial). Yet we must keep implementing python strings as uninterned strin...
(ns pyjure.mop (:require [clojure.core :as c] [clojure.string :as str]) (:use [clojure.core.match :only [match]] [pyjure.debug] [pyjure.utilities] [pyjure.names])) (defprotocol PyObject "Protocol for viewing something as a python-style object" ($get [x key] "get an obje...
5043f834f87f3b1417576b306f72df0d14d31d7b466bd0975e03e3ec8c7c463a
otto-de/tesla-examples
system.clj
(ns de.otto.tesla.zk.example.system (:require [de.otto.tesla.system :as system] [de.otto.tesla.serving-with-jetty :as jetty] [de.otto.tesla.zk.zk-observer :as observer] [de.otto.tesla.zk.example.page :as example-page] [com.stuartsierra.component :as c]) (:gen-class)) ...
null
https://raw.githubusercontent.com/otto-de/tesla-examples/1be46ceae1dac53204a8f655a81285e1ca214f9b/zookeeper-example/src/de/otto/tesla/zk/example/system.clj
clojure
(ns de.otto.tesla.zk.example.system (:require [de.otto.tesla.system :as system] [de.otto.tesla.serving-with-jetty :as jetty] [de.otto.tesla.zk.zk-observer :as observer] [de.otto.tesla.zk.example.page :as example-page] [com.stuartsierra.component :as c]) (:gen-class)) ...
8593ddc205d54bddf6f3f7d67042b356974c3aab9930bc11714afdba9d2f06a8
melange-re/melange
res_scanner.ml
module Diagnostics = Res_diagnostics module Token = Res_token module Comment = Res_comment type mode = Jsx | Diamond (* We hide the implementation detail of the scanner reading character. Our char will also contain the special -1 value to indicate end-of-file. This isn't ideal; we should clean this up *) let hackyEOF...
null
https://raw.githubusercontent.com/melange-re/melange/246e6df78fe3b6cc124cb48e5a37fdffd99379ed/jscomp/napkin/res_scanner.ml
ocaml
We hide the implementation detail of the scanner reading character. Our char will also contain the special -1 value to indicate end-of-file. This isn't ideal; we should clean this up current character character offset current line offset current line number line number offset of the beginning of the line (...
module Diagnostics = Res_diagnostics module Token = Res_token module Comment = Res_comment type mode = Jsx | Diamond let hackyEOFChar = Char.unsafe_chr (-1) type charEncoding = Char.t type t = { filename: string; src: string; mutable err: startPos: Lexing.position -> endPos: Lexing.position -> Diag...
6ad679190f8bc4ee7efd977b0c1506214b788076946b57a91ce8fb17b935f349
kirstin-rhys/nestedmap
ForestSpec.hs
# LANGUAGE NoImplicitPrelude , UnicodeSyntax # module Data.Nested.ForestSpec (spec) where import Test.Hspec import Test.Hspec.QuickCheck import Test.QuickCheck.Modifiers import qualified Data.List as L import qualified Data.List.Ordered as OL import Data.Function.Unicode ((∘)) import Prelude.Unicode ((⊥)) import Data...
null
https://raw.githubusercontent.com/kirstin-rhys/nestedmap/04538d718f308bdeec8d1228cfe205e533b85ec9/test/Data/Nested/ForestSpec.hs
haskell
this is a hack. should be replace by a [[(k,v)]] generator which can guarantee non-overlapping keys
# LANGUAGE NoImplicitPrelude , UnicodeSyntax # module Data.Nested.ForestSpec (spec) where import Test.Hspec import Test.Hspec.QuickCheck import Test.QuickCheck.Modifiers import qualified Data.List as L import qualified Data.List.Ordered as OL import Data.Function.Unicode ((∘)) import Prelude.Unicode ((⊥)) import Data...
fdddc712cf0fb667dc12d5ffc8979a1738b73f1662e42d78281adf489918b6ea
hoplon/brew
simplemde.cljs
(ns hoplon.simplemde (:require [hoplon.core :as hl] [javelin.core :as j] [cljsjs.simplemde])) (defn editor! "Creates a SimpleMDE editor." [& [config]] (if config (js/SimpleMDE. (clj->js config)) (js/SimpleMDE.))) (defelem editor [attr kids] (let [content (:content attr) ...
null
https://raw.githubusercontent.com/hoplon/brew/08d520fc43a14180dd52955af48dae63d0065add/src/hoplon/simplemde.cljs
clojure
(ns hoplon.simplemde (:require [hoplon.core :as hl] [javelin.core :as j] [cljsjs.simplemde])) (defn editor! "Creates a SimpleMDE editor." [& [config]] (if config (js/SimpleMDE. (clj->js config)) (js/SimpleMDE.))) (defelem editor [attr kids] (let [content (:content attr) ...
1d92b907a51b98a5efc31f7168d7e477ac1484772328a1422d65d3d16a1f16c3
talex5/mirage-trace-viewer
mtv_ctf_loader.mli
Copyright ( C ) 2014 , open Bigarray type packet type log_buffer = (char, int8_unsigned_elt, c_layout) Array1.t (** Locate packets in a trace stream and return them (using [Array1.sub]) in the correct order. *) val packets : log_buffer -> packet list val packet_data : packet -> log_buffer val from_bigarray : l...
null
https://raw.githubusercontent.com/talex5/mirage-trace-viewer/8492c53c57778fd55474d37b34833129c5c1d5d3/lib/mtv_ctf_loader.mli
ocaml
* Locate packets in a trace stream and return them (using [Array1.sub]) in the correct order.
Copyright ( C ) 2014 , open Bigarray type packet type log_buffer = (char, int8_unsigned_elt, c_layout) Array1.t val packets : log_buffer -> packet list val packet_data : packet -> log_buffer val from_bigarray : log_buffer -> Mtv_event.t list
84f0793ee16c1591ea660e965ebd42ef5a2b571945350f0a403338ee4210017c
xmonad/xmonad-contrib
WorkspaceCompare.hs
----------------------------------------------------------------------------- -- | Module : XMonad . Util . WorkspaceCompare -- Description : Functions for examining, comparing, and sorting workspaces. Copyright : ( c ) < > -- License : BSD3-style (see LICENSE) -- Maintainer : < > -- ...
null
https://raw.githubusercontent.com/xmonad/xmonad-contrib/e5b5ce74b203085998b9ca6f59f23be387e4aef2/XMonad/Util/WorkspaceCompare.hs
haskell
--------------------------------------------------------------------------- | Description : Functions for examining, comparing, and sorting workspaces. License : BSD3-style (see LICENSE) Stability : unstable Portability : unportable ----------------------------------------------------------------------...
Module : XMonad . Util . WorkspaceCompare Copyright : ( c ) < > Maintainer : < > module XMonad.Util.WorkspaceCompare ( WorkspaceCompare, WorkspaceSort , filterOutWs , getWsIndex , ge...
0e2bde5befc1905759b4931c22b8a7b6b0c1b5a0ed32d1210fe9b95ed2344e0c
fukamachi/clozure-cl
l0-misc.lisp
-*- Mode : Lisp ; Package : CCL -*- ;;; Copyright ( C ) 2009 Clozure Associates Copyright ( C ) 1994 - 2001 Digitool , Inc This file is part of Clozure CL . ;;; Clozure CL is licensed under the terms of the Lisp Lesser GNU Public License , known as the LLGPL and distributed with Clozure CL as the ...
null
https://raw.githubusercontent.com/fukamachi/clozure-cl/4b0c69452386ae57b08984ed815d9b50b4bcc8a2/level-0/l0-misc.lisp
lisp
Package : CCL -*- file "LICENSE". The LLGPL consists of a preamble and the LGPL, conflict, the preamble takes precedence. Clozure CL is referenced in the preamble as the "LIBRARY." The LLGPL is also available online at Bootstrapping for futexes We only need a few constants from <linux/futex.h>...
Copyright ( C ) 2009 Clozure Associates Copyright ( C ) 1994 - 2001 Digitool , Inc This file is part of Clozure CL . Clozure CL is licensed under the terms of the Lisp Lesser GNU Public License , known as the LLGPL and distributed with Clozure CL as the which is distributed with Clozure CL as ...
0532b910e1a55b0647217ca4c02c9b9ec10e4d823d4188c4f88512098faebe10
svenpanne/EOPL3
exercise-3-05.rkt
#lang eopl ; ------------------------------------------------------------------------------ Exercise 3.5 ; A bit incomplete due to space restrictions: ; ( value - of < < x > > ( value - of < < 1 > > [ y=(num - val 2),x=(num - val 7)]rho0 ) = ( 7 ) ...
null
https://raw.githubusercontent.com/svenpanne/EOPL3/3fc14c4dbb1c53a37bd67399eba34cea8f8234cc/chapter3/exercise-3-05.rkt
racket
------------------------------------------------------------------------------ A bit incomplete due to space restrictions: ---------------------------------------------------------------------------------------------------------------------- (value-of <<-(x,1)>> ...
#lang eopl Exercise 3.5 ( value - of < < x > > ( value - of < < 1 > > [ y=(num - val 2),x=(num - val 7)]rho0 ) = ( 7 ) [ y=(num - val 2),x=(num - val 7)]rho0 ) = ( 1 ) [ y=(num - val 2),x=(num - v...
099a0b5595daee59f7cbf14607411428354dc71530feee300d918b9dccd80c35
clj-kafka/franzy
project.clj
(defproject clj-kafka.franzy/json "0.0.0" :description "A Kafka Serializer/Deserializer supporting JSON, and an add-on for Franzy, a Clojure Kafka client." :dependencies [[org.clojure/clojure "1.8.0"] [org.apache.kafka/kafka-clients "0.11.0.0"] [cheshire "5.5.0"]] :monolith/inher...
null
https://raw.githubusercontent.com/clj-kafka/franzy/6c2e2e65ad137d2bcbc04ff6e671f97ea8c0e380/json/project.clj
clojure
(defproject clj-kafka.franzy/json "0.0.0" :description "A Kafka Serializer/Deserializer supporting JSON, and an add-on for Franzy, a Clojure Kafka client." :dependencies [[org.clojure/clojure "1.8.0"] [org.apache.kafka/kafka-clients "0.11.0.0"] [cheshire "5.5.0"]] :monolith/inher...
cc39dd497256a9fc841784e1d72400a8df8a8306a75728bd7f6cd589c287d4d9
staples-sparx/kits
log_consumer.clj
(ns ^{:doc "Internal namespace. This spawns agents that writes log messages to file and rotates them"} kits.logging.log-consumer (:require [kits.runtime :as runtime] [kits.queues :as q] [kits.logging.log-generator :as log]) (:import (java.util Calendar TimeZone) (java.io FileWriter Writer IOExcepti...
null
https://raw.githubusercontent.com/staples-sparx/kits/66ae99bce83e8fd1248cc5c0da1f23673f221073/src/clojure/kits/logging/log_consumer.clj
clojure
Check whether we should rotate the logs Check whether we should flush and get back to business Write log entry, flushing lazily
(ns ^{:doc "Internal namespace. This spawns agents that writes log messages to file and rotates them"} kits.logging.log-consumer (:require [kits.runtime :as runtime] [kits.queues :as q] [kits.logging.log-generator :as log]) (:import (java.util Calendar TimeZone) (java.io FileWriter Writer IOExcepti...
e358dbea18f3dca93c89f9769c00b2f1dcbd1a3489bea70fa59328d2a8d59adb
simplex-chat/simplex-chat
Options.hs
# LANGUAGE ApplicativeDo # # LANGUAGE DuplicateRecordFields # # LANGUAGE NamedFieldPuns # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE ScopedTypeVariables # module Options where import qualified Data.Attoparsec.ByteString.Char8 as A import Data.Int (Int64) import Data.Maybe (fromMaybe) import Data.Text (Text) import...
null
https://raw.githubusercontent.com/simplex-chat/simplex-chat/01acbb970ae7762e1551e352131453e77a601764/apps/simplex-broadcast-bot/Options.hs
haskell
# LANGUAGE OverloadedStrings #
# LANGUAGE ApplicativeDo # # LANGUAGE DuplicateRecordFields # # LANGUAGE NamedFieldPuns # # LANGUAGE ScopedTypeVariables # module Options where import qualified Data.Attoparsec.ByteString.Char8 as A import Data.Int (Int64) import Data.Maybe (fromMaybe) import Data.Text (Text) import qualified Data.Text as T import Da...
f66c36259141fc50fd6dbd6e3f6b1f268a04b42f7ee5a3f04cc59c885ef0f661
manuel-serrano/bigloo
remove.scm
(module saw_remove (import type_type ast_var ast_node saw_lib saw_defs ) (export (remove::block b::block)) (include "SawMill/remove.sch") (static (wide-class defcollect::block) (wide-class rcollect::block) (wide-class ucollect::block) (wide-class removed::rtl_ins) (wide-class vis...
null
https://raw.githubusercontent.com/manuel-serrano/bigloo/1ae5b060fcfd05ad33440765b45add3a26ced5b4/comptime/SawMill/remove.scm
scheme
() () () () () Collect unused regs fixpoint between useless functional call and useless variable () remove the unused functional call remove the affectation of unused variables fixpoint ()
(module saw_remove (import type_type ast_var ast_node saw_lib saw_defs ) (export (remove::block b::block)) (include "SawMill/remove.sch") (static (wide-class defcollect::block) (wide-class rcollect::block) (wide-class ucollect::block) (wide-class removed::rtl_ins) (wide-class vis...
edbf357c6debb5fe435de35de10984d6721b1516cefa0c319790e6565f880d24
AccelerationNet/clsql-helper
date.lisp
(in-package :clsql-helper) (cl-interpol:enable-interpol-syntax) (clsql:file-enable-sql-reader-syntax) (defun current-sql-date () "current date" (clsql-sys:get-date)) (defun current-sql-time () "current date and time" (clsql-sys:get-time)) (defun print-nullable-date (field) "if the date exists, prints m?m/...
null
https://raw.githubusercontent.com/AccelerationNet/clsql-helper/846b67a26906da5ea2cff790a36a4cb2f496a528/date.lisp
lisp
oh yeah, we love recursive format processing as best I can tell these just suck
(in-package :clsql-helper) (cl-interpol:enable-interpol-syntax) (clsql:file-enable-sql-reader-syntax) (defun current-sql-date () "current date" (clsql-sys:get-date)) (defun current-sql-time () "current date and time" (clsql-sys:get-time)) (defun print-nullable-date (field) "if the date exists, prints m?m/...
d9ff15a6161c3fc8e61831f0bf0304ba869830487d2eda1ad906447715ddca3c
cfpb/qu
cache.clj
(ns ^:integration integration.test.cache (:require [clojure.test :refer :all] [clojure.core.cache :as cache] [qu.test-util :refer :all] [qu.data :as data] [qu.query :as q] [qu.cache :as c] [qu.loader :as loader] [monger.core :as mongo...
null
https://raw.githubusercontent.com/cfpb/qu/f460d9ab2f05ac22f6d68a98a9641daf0f7c7ba4/test/integration/test/cache.clj
clojure
(run-tests)
(ns ^:integration integration.test.cache (:require [clojure.test :refer :all] [clojure.core.cache :as cache] [qu.test-util :refer :all] [qu.data :as data] [qu.query :as q] [qu.cache :as c] [qu.loader :as loader] [monger.core :as mongo...
810dd5f0b1ef0befd1b37c43f07d7fe25a5fc61b5d639010b0be0e7d361cc9fc
ekmett/unboxed
FloatRep.hs
{-# Language DataKinds #-} module FloatRep where import GHC.Types type Rep = 'FloatRep
null
https://raw.githubusercontent.com/ekmett/unboxed/e4c6ca80fb8946b1abfe595ba1c36587a33931db/internal/FloatRep.hs
haskell
# Language DataKinds #
module FloatRep where import GHC.Types type Rep = 'FloatRep
fd29974f98fbc31301939abc4ede2cf1ae897bf9ed99b876431d3fce3f0d9b5f
eashanhatti/peridot
Common.hs
module Syntax.Common where import Numeric.Natural import Data.Text import Data.Hashable import GHC.Generics import Data.Map qualified as Map import Data.Sequence data PassMethod = Explicit | Unification | DontCare deriving (Eq, Show) data Universe = Meta | Obj deriving (Eq, Show) newtype Field = Field { unField...
null
https://raw.githubusercontent.com/eashanhatti/peridot/014d6b8e8b792ac80928fc43c8f1d26df8eb7d2d/src/Syntax/Common.hs
haskell
Object level Propositions Other
module Syntax.Common where import Numeric.Natural import Data.Text import Data.Hashable import GHC.Generics import Data.Map qualified as Map import Data.Sequence data PassMethod = Explicit | Unification | DontCare deriving (Eq, Show) data Universe = Meta | Obj deriving (Eq, Show) newtype Field = Field { unField...
fbd7f284e5319c2454ad8d959984756822511bd2ddab9f4d36e9b54b629fc06e
vii/teepeedee2
webapp.lisp
(in-package #:tpd2.webapp) (declaim (inline webapp-default-page-footer webapp-default-page-head-contents)) (defun webapp-default-page-footer () (with-ml-output (output-raw-ml (js-library-footer)))) (defun webapp-default-page-head-contents () (with-ml-output (output-raw-ml (js-library)) (js-html-...
null
https://raw.githubusercontent.com/vii/teepeedee2/a2ed78c51d782993591c3284562daeed3aba3d40/src/webapp/webapp.lisp
lisp
(in-package #:tpd2.webapp) (declaim (inline webapp-default-page-footer webapp-default-page-head-contents)) (defun webapp-default-page-footer () (with-ml-output (output-raw-ml (js-library-footer)))) (defun webapp-default-page-head-contents () (with-ml-output (output-raw-ml (js-library)) (js-html-...
fabced02436be5868ed0411937d0e6d1f35d25fbc8e3e08c16a144f872769a03
stumpwm/stumpwm-contrib
package.lisp
package.lisp (defpackage #:mem (:use #:cl :common-lisp :stumpwm :cl-ppcre))
null
https://raw.githubusercontent.com/stumpwm/stumpwm-contrib/a7dc1c663d04e6c73a4772c8a6ad56a34381096a/modeline/mem/package.lisp
lisp
package.lisp (defpackage #:mem (:use #:cl :common-lisp :stumpwm :cl-ppcre))
eca601c082631e6a23c34b8af3768f84f0d55ae2f26c6045a8110a862fda69ca
eareese/htdp-exercises
091-happy-cat-direction.rkt
#lang htdp/bsl (require 2htdp/image) (require 2htdp/universe) Exercise 91 Extend your structure type definition and data definition from exercise 88 to ;; include a direction field. Adjust your happy-cat program so that the cat ;; moves in the specified direction. The program should move the cat in the ;; current ...
null
https://raw.githubusercontent.com/eareese/htdp-exercises/a85ff3111d459dda0e94d9b463d01a09accbf9bf/part01-fixed-size-data/091-happy-cat-direction.rkt
racket
include a direction field. Adjust your happy-cat program so that the cat moves in the specified direction. The program should move the cat in the current direction, and it should turn the cat around when it reaches either end of the scene. Cat = (make-cat Number Number String) interpretation (make-cat x n) descri...
#lang htdp/bsl (require 2htdp/image) (require 2htdp/universe) Exercise 91 Extend your structure type definition and data definition from exercise 88 to (define-struct cat [x hap dir]) ex : ( make - cat 10 1 " left " ) VCat The world state VCat is represented by a Cat with a Number for x - position and (...
293347ca03bc949fe6b8ea7cf12750640df73de7978fd6b53c46726c92210465
ghc/ghc
deriving-via-compile.hs
# LANGUAGE DerivingStrategies # # LANGUAGE DerivingVia # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE KindSignatures # {-# LANGUAGE RankNTypes #-} # LANGUAGE StandaloneDeriving # # LANGUAGE InstanceSigs # # LANGUAGE PolyKinds # # LANGUAGE DataKinds # {-# LANGUAGE GADTs #-} # LANGUAGE TypeApplications # {-# LANGUA...
null
https://raw.githubusercontent.com/ghc/ghc/aacf616df0b4059e6b177ecb64624ae6fb1d1c87/testsuite/tests/deriving/should_compile/deriving-via-compile.hs
haskell
# LANGUAGE RankNTypes # # LANGUAGE GADTs # # LANGUAGE ConstraintKinds # # LANGUAGE MultiWayIf # --- Simple example --- --- --- --- --- From `constraints' With `-XQuantifiedConstraints' this just becomes --- Using tuples in a `via` type --- --- Abstract data types --- -- Testing parser -- -- -- -- -- -- -- dat...
# LANGUAGE DerivingStrategies # # LANGUAGE DerivingVia # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE KindSignatures # # LANGUAGE StandaloneDeriving # # LANGUAGE InstanceSigs # # LANGUAGE PolyKinds # # LANGUAGE DataKinds # # LANGUAGE TypeApplications # # LANGUAGE MultiParamTypeClasses # # LANGUAGE TypeOperators #...
a9f2398c7d6e5720381bba7df8f5b6d64a54bf5f1920d794a4255f2ca1f1ec20
debug-ito/net-spider
Internal.hs
# LANGUAGE DeriveGeneric # -- | Module : NetSpider . Snapshot . Internal -- Description: Implementation of Snapshot graph types Maintainer : < > -- -- __this module is internal. End-users should not use this.__ -- -- Implementation of Snapshot graph types. This module is for internal -- and testing purposes only...
null
https://raw.githubusercontent.com/debug-ito/net-spider/82dfbdca1add1edfd54ef36cb1ca5129d528b814/net-spider/src/NetSpider/Snapshot/Internal.hs
haskell
| Description: Implementation of Snapshot graph types __this module is internal. End-users should not use this.__ Implementation of Snapshot graph types. This module is for internal and testing purposes only. | The snapshot graph, which is a collection nodes and links. | A link in the snapshot graph. diffe...
# LANGUAGE DeriveGeneric # Module : NetSpider . Snapshot . Internal Maintainer : < > @since 0.3.0.0 module NetSpider.Snapshot.Internal ( SnapshotGraph, SnapshotLink(..), linkNodeTuple, linkNodePair, SnapshotNode(..) ) where import Control.Applicative (many, (*...
516f43d7c383e3542150b1538857bb3bc37df32f7f1c93d122279d4bd12c9f44
generateme/inferme
anglican.clj
(ns anglican.anglican (:require [fastmath.core :as m] [inferme.core :refer :all] [inferme.plot :as plot] [fastmath.stats :as stats])) (set! *warn-on-reflection* true) (set! *unchecked-math* :warn-on-boxed) (m/use-primitive-operators) ;; from presentation (defn generate-observati...
null
https://raw.githubusercontent.com/generateme/inferme/3cee4695bdf2c9c4d79d5257184f5db5e4774bdf/notebooks/anglican/anglican.clj
clojure
from presentation
(ns anglican.anglican (:require [fastmath.core :as m] [inferme.core :refer :all] [inferme.plot :as plot] [fastmath.stats :as stats])) (set! *warn-on-reflection* true) (set! *unchecked-math* :warn-on-boxed) (m/use-primitive-operators) (defn generate-observations [p n] (repeat...
b153a22a00a2cb642b0632a242f382b677ae0c786a15e830334e0b9e14526a6d
kind2-mc/kind2
invs.mli
This file is part of the Kind 2 model checker . Copyright ( c ) 2015 by the Board of Trustees of the University of Iowa 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 a...
null
https://raw.githubusercontent.com/kind2-mc/kind2/c601470eb68af9bd3b88828b04dbcdbd6bd6bbf5/src/terms/invs.mli
ocaml
* Stores invariants. * The empty collection of invariants. * True if no invariants. * Remove all the invariants. * Checks if a term is a known invariant. * Returns [Some cert] if [term] is a known invariant, or [None] otherwise. * {e Temporary.} Flattens some invariants into a list. * Formats some invariants.
This file is part of the Kind 2 model checker . Copyright ( c ) 2015 by the Board of Trustees of the University of Iowa 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 a...
0446207efa005a1142af854c8d5631a0c45a807f19f777135a1bf26fcf637ec5
input-output-hk/offchain-metadata-tools
Types.hs
{-# LANGUAGE OverloadedStrings #-} # LANGUAGE QuasiQuotes # {-# LANGUAGE RankNTypes #-} # LANGUAGE ScopedTypeVariables # module Test.Cardano.Metadata.Types ( tests ) where import Data.Aeson ( FromJSON, ToJSON ) import qualified Data.Aeson as Aeson import qualified Data.Bifunctor as Bifunctor import Data.ByteArray...
null
https://raw.githubusercontent.com/input-output-hk/offchain-metadata-tools/794f08cedbf555e9d207bccc45c08abbcf98add9/metadata-lib/test/Test/Cardano/Metadata/Types.hs
haskell
# LANGUAGE OverloadedStrings # # LANGUAGE RankNTypes # | The from/to JSON instances should simply match the show/read instances. | Attested properties without a signature key are treated as an attested property with no signatures.
# LANGUAGE QuasiQuotes # # LANGUAGE ScopedTypeVariables # module Test.Cardano.Metadata.Types ( tests ) where import Data.Aeson ( FromJSON, ToJSON ) import qualified Data.Aeson as Aeson import qualified Data.Bifunctor as Bifunctor import Data.ByteArray.Encoding ( Base (Base16), convertToBase ) import qualified Dat...
98fab2256acb13cf90ba93250fcd60a342205a40a154c798d17a04bd29c2612c
cracauer/sbcl-ita
ucd.lisp
(in-package "SB-COLD") ;;; Common functions (defparameter *output-directory* (merge-pathnames (make-pathname :directory '(:relative :up "output")) (make-pathname :directory (pathname-directory *load-truename*)))) (defparameter *unicode-character-database* (make-pathname :directory (pathname-directory *load...
null
https://raw.githubusercontent.com/cracauer/sbcl-ita/f85a8cf0d1fb6e8c7b258e898b7af3233713e0b9/tools-for-build/ucd.lisp
lisp
Common functions Output storage globals line) ) ) Mappings of the general categories and bidi classes to integers ) ) ) ) See tests/data/DerivedBidiClass.txt for more information Default-ignorable will be dealt with elsewhere Flood-fil unallocated codepoints class, and age of 0 ("Unknown"), unless some of those...
(in-package "SB-COLD") (defparameter *output-directory* (merge-pathnames (make-pathname :directory '(:relative :up "output")) (make-pathname :directory (pathname-directory *load-truename*)))) (defparameter *unicode-character-database* (make-pathname :directory (pathname-directory *load-truename*))) (defma...
e711e8f2d668b4d49410fe79e83c3983ea96ab9fda9b1c21ab0351f329fcb992
Tclv/HaskellBook
Main.hs
module Main where import Control.Monad (forever) import Data.Char (toLower) import Data.Maybe (isJust) import Data.List (intersperse) import System.Exit (exitSuccess) import System.Random (randomRIO) type WordList = [ String ] newtype WordList = WordList [String] deriving (Eq, Show) allWords ::...
null
https://raw.githubusercontent.com/Tclv/HaskellBook/78eaa5c67579526b0f00f85a10be3156bc304c14/ch13/hangman/src/Main.hs
haskell
module Main where import Control.Monad (forever) import Data.Char (toLower) import Data.Maybe (isJust) import Data.List (intersperse) import System.Exit (exitSuccess) import System.Random (randomRIO) type WordList = [ String ] newtype WordList = WordList [String] deriving (Eq, Show) allWords ::...
d8c3500906f6cb91d83f0af02a4170a39dedbdf3f552de7e3f860eb3cdb6ab0e
racket/redex
delivered-tue-mor.rkt
#lang racket (require redex "common.rkt" (only-in "mon-aft.rkt" fv)) (provide eval-value) -- reductions for LC_v -- standard reductions for LC_v -- semantics for LC_v ;; -- cross-testing Racket with LC_v (define-extended-language Lambda-calculus Lambda (e ::= .... n) (v ::= n (lambda (x ...) e)) (n ::= nu...
null
https://raw.githubusercontent.com/racket/redex/4c2dc96d90cedeb08ec1850575079b952c5ad396/redex-doc/redex/scribblings/long-tut/code/delivered-tue-mor.rkt
racket
-- cross-testing Racket with LC_v a metafunction that acts like a macro in Lambda-calculus let : ((x e) ...) e -> e but e plus hole model the λβv calculus, reductions only transitive closure testing model standard reduction for by-name and by-value calculus -------------------------------------------------...
#lang racket (require redex "common.rkt" (only-in "mon-aft.rkt" fv)) (provide eval-value) -- reductions for LC_v -- standard reductions for LC_v -- semantics for LC_v (define-extended-language Lambda-calculus Lambda (e ::= .... n) (v ::= n (lambda (x ...) e)) (n ::= number) (C ::= hole (e ... C e ...) (...
3d8e4de37d63c6ea92a071059671bc1640e88a966e206a57eed8a822d1db5c67
ocaml/odoc
test.mli
(** Testing some canonical edge cases *) (** This is the simplest case *) module A__ : sig (** @canonical Test.A *) type t end module A = A__ type test = A__.t (** Dune-style wrapped library *) module Wrapped__X : sig type t end module Wrapper : sig (** @canonical Test.Wrapper.X *) module X = Wr...
null
https://raw.githubusercontent.com/ocaml/odoc/bbc00f9c75d4e855bca69124ccc947949da808f7/test/xref2/canonical_alias.t/test.mli
ocaml
* Testing some canonical edge cases * This is the simplest case * @canonical Test.A * Dune-style wrapped library * @canonical Test.Wrapper.X * Dune-style wrapped library with hand-written wrapper module * Dune-style wrapped library with hand-written wrapper module, but wrong * @canonical Test.Wrapper3.X * Non-h...
module A__ : sig type t end module A = A__ type test = A__.t module Wrapped__X : sig type t end module Wrapper : sig module X = Wrapped__X end type test2 = Wrapper.X.t module Wrapped2__X : sig type t end module Wrapper2__ : sig * @canonical Test . Wrapper2.X module X = Wrapped2__X end ...
27afab9ef6e008457f622614cbecc9f1dbba00fff1dae15901410b1064483795
joelburget/lvca
Nonbinding.mli
open Lvca_util (** Lots of interesting domains have no binding. At that point they're not really languages, just data types. This module gives a tighter representation for such types and allows conversion to / from binding types. *) type t = | Operator of Provenance.t * string * t list | Primitive of Primi...
null
https://raw.githubusercontent.com/joelburget/lvca/80f202eae45a9d383104bc750be70216b81d8864/syntax/Nonbinding.mli
ocaml
* Lots of interesting domains have no binding. At that point they're not really languages, just data types. This module gives a tighter representation for such types and allows conversion to / from binding types. * {1 Printing} * {1 Parsing} * {1 Misc} * {1 Serialization}
open Lvca_util type t = | Operator of Provenance.t * string * t list | Primitive of Primitive.All.t val equivalent : ?info_eq:(Provenance.t -> Provenance.t -> bool) -> t -> t -> bool val ( = ) : t -> t -> bool * { 1 info } * { 1 de Bruijn conversion } type de_bruijn_conversion_error = | Scope_encountered of ...
3113eb72839a1c783669ce8acf8590ff27f3c3b6f3e00b2b7ed71e868e4e957a
matlux/game-of-life
project.clj
(defproject game-of-life "0.1.0-SNAPSHOT" :description "FIXME: write description" :url "" :license {:name "Eclipse Public License" :url "-v10.html"} :dependencies [[org.clojure/clojure "1.8.0"] [org.clojure/algo.monads "0.1.4"] [org.clojure/math.numeric-tower "0.0.3...
null
https://raw.githubusercontent.com/matlux/game-of-life/5e95e2fc2de266e784a35415f5b4bcde8ffd6838/project.clj
clojure
(defproject game-of-life "0.1.0-SNAPSHOT" :description "FIXME: write description" :url "" :license {:name "Eclipse Public License" :url "-v10.html"} :dependencies [[org.clojure/clojure "1.8.0"] [org.clojure/algo.monads "0.1.4"] [org.clojure/math.numeric-tower "0.0.3...
1c1cbcf137e41d5499ba94a4427186d851eae08559109fc7247ee9caa04e13ba
orbitz/ocaml-riakc
list_buckets.ml
open Core.Std open Async.Std let option_to_string = function | Some v -> v | None -> "<none>" let fail s = printf "%s\n" s; shutdown 1 let exec () = let host = Sys.argv.(1) in let port = Int.of_string Sys.argv.(2) in Riakc.Conn.with_conn ~host ~port Riakc.Conn.list_buckets let eval () = ...
null
https://raw.githubusercontent.com/orbitz/ocaml-riakc/507241edbdb26d65961e5a90d69c219b2674db9d/src/examples/list_buckets.ml
ocaml
open Core.Std open Async.Std let option_to_string = function | Some v -> v | None -> "<none>" let fail s = printf "%s\n" s; shutdown 1 let exec () = let host = Sys.argv.(1) in let port = Int.of_string Sys.argv.(2) in Riakc.Conn.with_conn ~host ~port Riakc.Conn.list_buckets let eval () = ...
248db047af1fb8896219eb2283ad2d76d8262de243684218520ef4cf63e03c44
conscell/hugs-android
SrcDist.hs
# OPTIONS_GHC -cpp # ----------------------------------------------------------------------------- -- | -- Module : Distribution.Simple.SrcDist Copyright : 2004 -- Maintainer : < > -- Stability : alpha -- Portability : portable -- Copyright ( c ) 2003 - 2004 , All rights reserved . ...
null
https://raw.githubusercontent.com/conscell/hugs-android/31e5861bc1a1dd9931e6b2471a9f45c14e3c6c7e/hugs/lib/hugs/packages/Cabal/Distribution/Simple/SrcDist.hs
haskell
--------------------------------------------------------------------------- | Module : Distribution.Simple.SrcDist Stability : alpha Portability : portable NOTE: FIX: we don't have a great way of testing this module, since we can't easily look inside a tarball once its created. |Create a source dist...
# OPTIONS_GHC -cpp # Copyright : 2004 Maintainer : < > Copyright ( c ) 2003 - 2004 , All rights reserved . Redistribution and use in source and binary forms , with or without modification , are permitted provided that the following conditions are met : * Redistributions of source ...
eb9ae66ea4f560bf2e21c65598d55ef15c1374b23ef0531c6a95cf993d48aca9
binaryage/chromex
webview_tag.cljs
(ns chromex.app.webview-tag (:require-macros [chromex.app.webview-tag :refer [gen-wrap]]) (:require [chromex.core])) ; -- properties ------------------------------------------------------------------------------------------------------------- (defn content-window* [config] (gen-wrap :property ::content-window c...
null
https://raw.githubusercontent.com/binaryage/chromex/33834ba5dd4f4238a3c51f99caa0416f30c308c5/src/apps/chromex/app/webview_tag.cljs
clojure
-- properties -------------------------------------------------------------------------------------------------------------
(ns chromex.app.webview-tag (:require-macros [chromex.app.webview-tag :refer [gen-wrap]]) (:require [chromex.core])) (defn content-window* [config] (gen-wrap :property ::content-window config)) (defn request* [config] (gen-wrap :property ::request config)) (defn context-menus* [config] (gen-wrap :property...
a77e47d97bfb5f36f8ff8459446f0cf92c66a8d19d081c7e13444b063fe7f22f
sjl/temperance
6-optimization.lisp
(in-package :temperance) ;;;; ,,--. . . ;;;; |`, | ,-. |- . ,-,-. . ,_, ,-. |- . ,-. ,-. ;;;; | | | | | | | | | | / ,-| | | | | | | ;;;; `---' |-' `' ' ' ' ' ' '"' `-^ `' ' `-' ' ' ;;;; | ;;;; ' Optimization of the WAM instructions happens between the precompilation ;;; phas...
null
https://raw.githubusercontent.com/sjl/temperance/f7e68f46b7afaeecf643c009eb2e130500556e31/src/compiler/6-optimization.lisp
lisp
,,--. . . |`, | ,-. |- . ,-,-. . ,_, ,-. |- . ,-. ,-. | | | | | | | | | | / ,-| | | | | | | `---' |-' `' ' ' ' ' ' '"' `-^ `' ' `-' ' ' | ' phase and the rendering phase. We perform a number of passes over the ... Search for the corresponding set-value instruction ...
(in-package :temperance) Optimization of the WAM instructions happens between the precompilation circle of instructions , doing one optimization each time . (defun optimize-get-constant (node constant register) 1 . get_structure c/0 , Ai - > get_constant c , Ai (circle-replace node `(:get-constant ,constant...
b321c2963848a692e07608b8e6a64f0fa1cbedabb0e035f51b3fab46ef900ef5
eugeneia/athens
util.lisp
(in-package :cl-user) (defpackage jonathan.util (:use :cl :jonathan.error) (:export :+impl-comma-p+ :my-plist-p :integer-char-p :make-keyword :comma-p :comma-expr :*quasiquote*)) (in-package :jonathan.util) (defparameter +impl-comma-p+ (and ...
null
https://raw.githubusercontent.com/eugeneia/athens/cc9d456edd3891b764b0fbf0202a3e2f58865cbf/quicklisp/dists/quicklisp/software/jonathan-20180430-git/src/util.lisp
lisp
(comma-kind comma => 0: just only comma
(in-package :cl-user) (defpackage jonathan.util (:use :cl :jonathan.error) (:export :+impl-comma-p+ :my-plist-p :integer-char-p :make-keyword :comma-p :comma-expr :*quasiquote*)) (in-package :jonathan.util) (defparameter +impl-comma-p+ (and ...
422223eba6af5696a23ad04c9a2b1a730a0ae8520df27e83405f28edd9739308
nasa/Common-Metadata-Repository
system.clj
(ns cmr.metadata-db.system "Defines functions for creating, starting, and stopping the application. Applications are represented as a map of components. Design based on -composition and related posts." (:require [cmr.acl.core :as acl] [cmr.common-app.api.health :as common-health] [cmr.common-app.servic...
null
https://raw.githubusercontent.com/nasa/Common-Metadata-Repository/7ea1e3700c641b07ad262f3237c539c807380ade/metadata-db-app/src/cmr/metadata_db/system.clj
clojure
Design based on -composition and related posts
(ns cmr.metadata-db.system "Defines functions for creating, starting, and stopping the application. Applications are represented as a map of components. Design based on -composition and related posts." (:require [cmr.acl.core :as acl] [cmr.common-app.api.health :as common-health] [cmr.common-app.servic...
dac3b34e9f67eaf045b2c7c3e259a8bfd9d3e0da2a28fc1368c9b89b661fdca9
bobzhang/fan
test_sig_parser.ml
open Format #camlp4o;; let of_file filename = let chan = open_in filename in Stream.of_channel chan let stream = of_file "_build/camlp4ast_signature.inferred.mli" ;; open Camlp4.PreCast open Fan_camlp4 < : < type .$typ : type$. > > let f = wrap_stream_parser Syntax.parse_interf;; let a = f stream;;...
null
https://raw.githubusercontent.com/bobzhang/fan/7ed527d96c5a006da43d3813f32ad8a5baa31b7f/src/todoml/test/test_sig_parser.ml
ocaml
open Format #camlp4o;; let of_file filename = let chan = open_in filename in Stream.of_channel chan let stream = of_file "_build/camlp4ast_signature.inferred.mli" ;; open Camlp4.PreCast open Fan_camlp4 < : < type .$typ : type$. > > let f = wrap_stream_parser Syntax.parse_interf;; let a = f stream;;...
1507837daff58289868947ac1d6c497a339789b12ef97ba31aa0adc6cbb7359b
jeapostrophe/opencl
oclVectorAdd.rkt
#lang racket (require opencl/c) (require "../utils/utils.rkt") (require ffi/cvector) (require ffi/unsafe/cvector) (require ffi/unsafe) (define (vectorAddHost data1 data2 result numElements) (for ([i (in-range numElements)]) (ptr-set! result _cl_float i (+ (ptr-ref data1 _cl_float i) ...
null
https://raw.githubusercontent.com/jeapostrophe/opencl/f984050b0c02beb6df186d1d531c4a92a98df1a1/tests/opencl/samples/nvidiaSamples/oclVectorAdd/oclVectorAdd.rkt
racket
Length of float arrays to process (odd # for illustration) rounded up to the nearest multiple of the LocalWorkSize get platform create context create command queue Set up program Set up kernal Asynchronous write of data to GPU Launch Kernel Synchronous/blocking read of results, and check accumulated errors Compute and...
#lang racket (require opencl/c) (require "../utils/utils.rkt") (require ffi/cvector) (require ffi/unsafe/cvector) (require ffi/unsafe) (define (vectorAddHost data1 data2 result numElements) (for ([i (in-range numElements)]) (ptr-set! result _cl_float i (+ (ptr-ref data1 _cl_float i) ...
51a2bc28273be497af820c7f577fe6bc33f7c48bc01cf3b12014eb0da5b9429f
orbitz/ocaml-protobuf
parser.ml
open Core.Std type error = [ `Incomplete | `Overflow | `Unknown_type | `Wrong_type ] module State = struct type t = { tags : Protocol.Value.t list Int.Map.t } let tags_of_bits bits = let append field map = let module F = Protocol.Field in match Int.Map.find map (F.tag field) with | Some v ->...
null
https://raw.githubusercontent.com/orbitz/ocaml-protobuf/66228bbde1aba144b5b6b4b016df0d48e8092744/lib/protobuf/parser.ml
ocaml
* The values are put in the tags map in reverse order * that they are seen, this foldl will put it back in the * correct order
open Core.Std type error = [ `Incomplete | `Overflow | `Unknown_type | `Wrong_type ] module State = struct type t = { tags : Protocol.Value.t list Int.Map.t } let tags_of_bits bits = let append field map = let module F = Protocol.Field in match Int.Map.find map (F.tag field) with | Some v ->...
cd9c867c4fd5582ad25b60d583c9f33893f330d1facbfa82b293a5b028aecb55
kmi/irs
common-concepts.lisp
-*- Mode : LISP ; Syntax : Common - lisp ; Base : 10 ; Package : OCML ; -*- (in-package "OCML") (in-ontology common-concepts) (def-relation has-address (?x ?c) :constraint (and (or (organization ?x) (person ?x)) (postal-address ?c)) ) (def-relation HAS-WEB-ADDRESS ...
null
https://raw.githubusercontent.com/kmi/irs/e1b8d696f61c6b6878c0e92d993ed549fee6e7dd/ontologies/domains/common-concepts/common-concepts.lisp
lisp
Syntax : Common - lisp ; Base : 10 ; Package : OCML ; -*-
(in-package "OCML") (in-ontology common-concepts) (def-relation has-address (?x ?c) :constraint (and (or (organization ?x) (person ?x)) (postal-address ?c)) ) (def-relation HAS-WEB-ADDRESS (?x ?C) :constraint (URL ?c)) (def-relation has-author (?x ?C) "?C has been ...
85725b0366e781f0a0901789e6c8ab18d8213be73ace8f52eac8bcab33323081
franks42/clj-ns-browser
web.clj
;; This file was created by copying src/clj/clojure/java/browse.clj from the Clojure source code , then applying the patch file ;; clj-896-browse-url-uses-xdg-open-patch2.txt to it (available at the ;; URL below), and then changing the namespace name. The intent is that if and when Clojure 's ;; clojure.java.b...
null
https://raw.githubusercontent.com/franks42/clj-ns-browser/c5fc570f9c8aeb6dd1cc9383fcf32bdaa9b936e3/src/clj_ns_browser/web.clj
clojure
This file was created by copying src/clj/clojure/java/browse.clj clj-896-browse-url-uses-xdg-open-patch2.txt to it (available at the URL below), and then changing the namespace name. clojure.java.browser/browse-url has been updated appropriately, this file and namespace can be removed completely. browse-url uses ...
from the Clojure source code , then applying the patch file The intent is that if and when Clojure 's Until then , there are platforms , like Lubuntu , where the built - in Copyright ( c ) . All rights reserved . (ns ^{:author "Christophe Grand", :doc "Start a web browser from Clojure"} clj...
329a19a0b8d1407ac4edce740332e8a90264cb1468438fe4b26622d5c781cb3d
exoscale/seql
crud_integration_test.clj
(ns seql.crud-integration-test (:require [seql.mutation :refer [mutate!]] [clojure.spec.alpha :as s] [seql.env :as env] [seql.query :as q] [seql.helpers :refer [make-schema entity-from-spec add-create-mutation add-update-...
null
https://raw.githubusercontent.com/exoscale/seql/7142132a5c364baf201936052095589489320e99/test/seql/crud_integration_test.clj
clojure
(ns seql.crud-integration-test (:require [seql.mutation :refer [mutate!]] [clojure.spec.alpha :as s] [seql.env :as env] [seql.query :as q] [seql.helpers :refer [make-schema entity-from-spec add-create-mutation add-update-...
8d20f8ac4ca9e87b15a1510f74cafd664abf29e885393288c1aa6cea7a4c7d1a
HaskellZhangSong/Introduction_to_Haskell_2ed_source
derive.hs
-- derive.hs # LANGUAGE TemplateHaskell # # OPTIONS_GHC -ddump - splices # import Data.Derive.Class.Arities import Data.Derive.Arities import Data.Derive.Show import Data.Derive.Eq import Data.DeriveTH data Shape = Circle Double | Triangle Double Double Double derive makeEq ''Shape derive makeShow ''Shape...
null
https://raw.githubusercontent.com/HaskellZhangSong/Introduction_to_Haskell_2ed_source/140c50fdccfe608fe499ecf2d8a3732f531173f5/C09/derive.hs
haskell
derive.hs
# LANGUAGE TemplateHaskell # # OPTIONS_GHC -ddump - splices # import Data.Derive.Class.Arities import Data.Derive.Arities import Data.Derive.Show import Data.Derive.Eq import Data.DeriveTH data Shape = Circle Double | Triangle Double Double Double derive makeEq ''Shape derive makeShow ''Shape derive makeA...
4b7d532c561e45d2de8f92338e49e78e120f121df893242b65c9e3561e0ae7b8
yzh44yzh/erma
returning_tests.erl
-module(returning_tests). -include("erma.hrl"). -include_lib("eunit/include/eunit.hrl"). returning_test_() -> test_utils:generate( [{ %% {insert, "users", ["first", "last"], ["Chris", "Granger"], [{returning, id}]}, %% <<"INSERT INTO users (\"first\", \"last\") VALUES ('C...
null
https://raw.githubusercontent.com/yzh44yzh/erma/454f127fcf6df0407de2f357f40a1d57f016d694/test/returning_tests.erl
erlang
-module(returning_tests). -include("erma.hrl"). -include_lib("eunit/include/eunit.hrl"). returning_test_() -> test_utils:generate( [{ {insert, "users", ["first", "last"], ["Chris", "Granger"], [{returning, id}]}, <<"INSERT INTO users (\"first\", \"last\") VALUES ('Chris', 'Granger') RETURN...
a58ad09b54b7cf25ac2b83f00a3bb75dc6d50fe50d9bdb0d072a09bfa11a9513
skanev/playground
45.scm
SICP exercise 5.45 ; ; By comparing the stack operations used by compiled code to the stack ; operations used by the evaluator for the same computation, we can determine ; the extent to which the compiler optimizes use of the stack, both in speed ; (reducing the total number of stack operations) and in space (reducin...
null
https://raw.githubusercontent.com/skanev/playground/d88e53a7f277b35041c2f709771a0b96f993b310/scheme/sicp/05/45.scm
scheme
By comparing the stack operations used by compiled code to the stack operations used by the evaluator for the same computation, we can determine the extent to which the compiler optimizes use of the stack, both in speed (reducing the total number of stack operations) and in space (reducing the maximum stack depth...
SICP exercise 5.45 5.14 asked you to do the same measurements for the special - purpose factorial machine shown in figure 5.11 . Now perform the same analysis using the 1 ! takes ( total - pushes = 7 maximum - depth = 3 ) 2 ! takes ( total - pushes = 13 maximum - depth = 5 ) 3 ! takes ( total - pushe...
b04f694255a9197bb8ef9c96412fffc31a2af41d3ac59bffd2e8bc881aeb78f6
lemmaandrew/CodingBatHaskell
lastChars.hs
From Given 2 strings , a and b , return a new string made of the first char of a and the last char of b , so \"yo\ " and \"java\ " yields \"ya\ " . If either string is length 0 , use ' @ ' for its missing char . Given 2 strings, a and b, return a new string made of the first char of a and the last char of b...
null
https://raw.githubusercontent.com/lemmaandrew/CodingBatHaskell/d839118be02e1867504206657a0664fd79d04736/CodingBat/String-1/lastChars.hs
haskell
From Given 2 strings , a and b , return a new string made of the first char of a and the last char of b , so \"yo\ " and \"java\ " yields \"ya\ " . If either string is length 0 , use ' @ ' for its missing char . Given 2 strings, a and b, return a new string made of the first char of a and the last char of b...
c7565215ab43e78fe43e642ba4a84e1577727f0fd4090f86f3cfe9dff9b55577
open-telemetry/opentelemetry-erlang
opentelemetry_experimental_app.erl
%%%------------------------------------------------------------------- %% @doc opentelemetry_experimental public API %% @end %%%------------------------------------------------------------------- -module(opentelemetry_experimental_app). -behaviour(application). -export([start/2, prep_stop/1, stop/1...
null
https://raw.githubusercontent.com/open-telemetry/opentelemetry-erlang/89c4b00b592050b35a4791f2ddecf7651fc083b0/apps/opentelemetry_experimental/src/opentelemetry_experimental_app.erl
erlang
------------------------------------------------------------------- @doc opentelemetry_experimental public API @end ------------------------------------------------------------------- called before the supervision tree is shutdown. on application stop set meter to the noop implementation. This is to ensure no cras...
-module(opentelemetry_experimental_app). -behaviour(application). -export([start/2, prep_stop/1, stop/1]). -include_lib("opentelemetry_api_experimental/include/otel_meter.hrl"). start(_StartType, _StartArgs) -> Config = otel_configuration:merge_with_os( application:get_all_env(...
ced423ab9a8bb9492016c94634131d7c13c671e838333d0d3cb1d09e1d6edeff
ocaml/ocamlbuild
aa.mli
(***********************************************************************) (* *) (* ocamlbuild *) (* *) , , projet Galliu...
null
https://raw.githubusercontent.com/ocaml/ocamlbuild/792b7c8abdbc712c98ed7e69469ed354b87e125b/test/test4/a/aa.mli
ocaml
********************************************************************* ocamlbuild ...
, , projet Gallium , INRIA Rocquencourt Copyright 2007 Institut National de Recherche en Informatique et en Automatique . All rights reserved . This file is distributed under the terms of the GNU Library General Public License , with val bar : int
f550c509a3f382c9f28a5a084486cc8b5b0c348c1cb9f1e7341371225b50f790
aysylu/loom
alg.cljc
(ns ^{:doc "Graph algorithms. Any graph record/type that satisfies the Graph, Digraph, or WeightedGraph protocols (as appropriate per algorithm) can use these functions." :author "Justin Kramer"} loom.alg (:require [loom.alg-generic :as gen] [loom.flow :as flow] [loom.graph ...
null
https://raw.githubusercontent.com/aysylu/loom/bb9068c5c5f4c3cf66344bf1b966cfd730e92693/src/loom/alg.cljc
clojure
Convenience wrappers for loom.alg-generic functions Graph algorithms remove vertices that are unreachable from source follows the parent pointers to construct path from source to node v TODO: could be better graph is not bipartite mst algorithms store in q => {u [heur+dist parent act est]} queue empty, tar...
(ns ^{:doc "Graph algorithms. Any graph record/type that satisfies the Graph, Digraph, or WeightedGraph protocols (as appropriate per algorithm) can use these functions." :author "Justin Kramer"} loom.alg (:require [loom.alg-generic :as gen] [loom.flow :as flow] [loom.graph ...
fb27be4b4f34aa705b49a9596c3a1664201113731472addc3a5f042d45f91957
expipiplus1/vulkan
VK_GOOGLE_decorate_string.hs
{-# language CPP #-} -- | = Name -- -- VK_GOOGLE_decorate_string - device extension -- -- == VK_GOOGLE_decorate_string -- -- [__Name String__] -- @VK_GOOGLE_decorate_string@ -- -- [__Extension Type__] -- Device extension -- -- [__Registered Extension Number__] 225 -- -- [__Revision__] 1 -- -- [__Ext...
null
https://raw.githubusercontent.com/expipiplus1/vulkan/b1e33d1031779b4740c279c68879d05aee371659/src/Vulkan/Extensions/VK_GOOGLE_decorate_string.hs
haskell
# language CPP # | = Name VK_GOOGLE_decorate_string - device extension == VK_GOOGLE_decorate_string [__Name String__] @VK_GOOGLE_decorate_string@ [__Extension Type__] Device extension [__Registered Extension Number__] [__Revision__] [__Extension and Version Dependencies__] [__Contact__] ...
225 1 - Requires support for Vulkan 1.0 - 2018 - 07 - 09 < > - , Google - , AMD - Revision 1 , 2018 - 07 - 09 ( ) < -extensions/html/vkspec.html#VK_GOOGLE_decorate_string Vulkan Specification > module Vulkan.Extensions.VK_GOOGLE_decorate_s...
e9aa7ed1b3228d8561160826459375e755af5dd53ffb48c2f09f1bc5ff7502c8
milankinen/cuic
todomvc_tests_without_local_server.clj
(ns cuic-examples.todomvc-tests-without-local-server (:require [clojure.test :refer :all] [cuic.core :as c] [cuic.test :refer [deftest* is* browser-test-fixture]])) (use-fixtures :once (browser-test-fixture)) (defn todos [] (->> (c/query ".todo-list li") (map c/text-content))) ...
null
https://raw.githubusercontent.com/milankinen/cuic/94718c0580da2aa127d967207f163c7a546b6fb1/examples/test/cuic_examples/todomvc_tests_without_local_server.clj
clojure
(ns cuic-examples.todomvc-tests-without-local-server (:require [clojure.test :refer :all] [cuic.core :as c] [cuic.test :refer [deftest* is* browser-test-fixture]])) (use-fixtures :once (browser-test-fixture)) (defn todos [] (->> (c/query ".todo-list li") (map c/text-content))) ...
e3d6152dcf98f469b778cf4941985188a3915ab139a048d3aa2ed4b931a4c4ae
google/haskell-trainings
ColorSolution.hs
Copyright 2021 Google LLC -- 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 distributed und...
null
https://raw.githubusercontent.com/google/haskell-trainings/214013fc324fd6c8f63b874a58ead0c1d3e6788c/haskell_102/codelab/01_mastermind/src/ColorSolution.hs
haskell
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 2021 Google LLC Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , # OPTIONS_GHC -fno - warn - unused - imports # # OPTIONS_GHC -fno - warn - unused - matches # # OPTIONS_GHC -fno - warn - unused - binds # # OPTI...
d4ca0a81264b193fda34371bc9d1b7051f4adeae6ee0f1361feb80ac8bf55890
amccausl/Swish
RDFQueryTest.hs
-------------------------------------------------------------------------------- $ I d : RDFQueryTest.hs , v 1.23 2004/01/07 19:49:13 graham Exp $ -- Copyright ( c ) 2003 , . All rights reserved . -- See end of this file for licence information. --------------------------------------------------------...
null
https://raw.githubusercontent.com/amccausl/Swish/9a7356300960c62e3f0468067bda0c34ee3606bd/Swish/HaskellRDF/RDFQueryTest.hs
haskell
------------------------------------------------------------------------------ See end of this file for licence information. ------------------------------------------------------------------------------ | Module : RDFQueryTest Stability : provisional Portability : H98 + multi-parameter cla...
$ I d : RDFQueryTest.hs , v 1.23 2004/01/07 19:49:13 graham Exp $ Copyright ( c ) 2003 , . All rights reserved . Copyright : ( c ) 2003 , License : GPL V2 Maintainer : This module defines test cases for querying an RDF graph to obtain WNH RIP OUT module Swish ....
9cdaa9c6e2ccb2f6a514fbe96271e252375fd8a03adaf2b482bedfd85042a17e
RefactoringTools/HaRe
L.hs
+ Except for one equation , this module provides an implementation of the function L from section 9.3 of the revised Haskell 98 Report . The missing equation is the one that requires interaction with the parser . This means that things like let x=1 in x+x will be correctly translated to ...
null
https://raw.githubusercontent.com/RefactoringTools/HaRe/ef5dee64c38fb104e6e5676095946279fbce381c/old/tools/hsutils/L.hs
haskell
Equations for explicit braces: hmm The equation for ordinary tokens: Equations for end of file: There are the tokens inserted by the layout processor: hmm hmm
+ Except for one equation , this module provides an implementation of the function L from section 9.3 of the revised Haskell 98 Report . The missing equation is the one that requires interaction with the parser . This means that things like let x=1 in x+x will be correctly translated to ...
169f26c598b3bf710c8fce87c73500c17c7d1731dba3b494f049b6d95221f826
snapframework/snap-server
Config.hs
{-# LANGUAGE BangPatterns #-} # LANGUAGE CPP # {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE OverloadedStrings #-} # LANGUAGE ScopedTypeVariables # ------------------------------------------------------------------------------ -- | This module exports the 'Config' datatype, which you can u...
null
https://raw.githubusercontent.com/snapframework/snap-server/f9c6e00630a8a78705aceafa0ac046ae70e1310e/src/Snap/Internal/Http/Server/Config.hs
haskell
# LANGUAGE BangPatterns # # LANGUAGE DeriveDataTypeable # # LANGUAGE OverloadedStrings # ---------------------------------------------------------------------------- | This module exports the 'Config' datatype, which you can use to configure * Private -------------------------------------------------------...
# LANGUAGE CPP # # LANGUAGE ScopedTypeVariables # the Snap HTTP server . module Snap.Internal.Http.Server.Config NOTE : also edit Snap . Http . Server . Config if you change these ( ConfigLog(..) , Config(..) , ProxyType(..) , emptyConfig , defaultConfig , commandLineConfig , extend...
6c4b82c4c5fc6c10e8b0300f3ee58e36f15293426ebd0be49d9bb3746b513dda
flipstone/orville
ErrorDetailLevel.hs
module Orville.PostgreSQL.Internal.ErrorDetailLevel ( ErrorDetailLevel (ErrorDetailLevel, includeErrorMessage, includeSchemaNames, includeRowIdentifierValues, includeNonIdentifierValues), defaultErrorDetailLevel, minimalErrorDetailLevel, maximalErrorDetailLevel, redactErrorMessage, redactSchemaNam...
null
https://raw.githubusercontent.com/flipstone/orville/0c03174967a5ad70c2a5881d1c43b43cac587556/orville-postgresql-libpq/src/Orville/PostgreSQL/Internal/ErrorDetailLevel.hs
haskell
module Orville.PostgreSQL.Internal.ErrorDetailLevel ( ErrorDetailLevel (ErrorDetailLevel, includeErrorMessage, includeSchemaNames, includeRowIdentifierValues, includeNonIdentifierValues), defaultErrorDetailLevel, minimalErrorDetailLevel, maximalErrorDetailLevel, redactErrorMessage, redactSchemaNam...
4af9e4ff8cdf43041ea2373f7f7a53e9949d87d818a7d31966b1b4c9c4440014
GaloisInc/tower
Simple.hs
# LANGUAGE DataKinds # # LANGUAGE ScopedTypeVariables # # LANGUAGE QuasiQuotes # # LANGUAGE RecordWildCards # # LANGUAGE QuasiQuotes # # LANGUAGE FlexibleInstances # {-# LANGUAGE OverloadedStrings #-} # OPTIONS_GHC -fno - warn - orphans # module Main where import Ivory.Tower import Ivory.Language import Tower.AADL i...
null
https://raw.githubusercontent.com/GaloisInc/tower/a43f5e36c6443472ea2dc15bbd49faf8643a6f87/tower-aadl/test/Simple.hs
haskell
# LANGUAGE OverloadedStrings # ------------------------------------------------------------------------------ ------------------------------------------------------------------------------
# LANGUAGE DataKinds # # LANGUAGE ScopedTypeVariables # # LANGUAGE QuasiQuotes # # LANGUAGE RecordWildCards # # LANGUAGE QuasiQuotes # # LANGUAGE FlexibleInstances # # OPTIONS_GHC -fno - warn - orphans # module Main where import Ivory.Tower import Ivory.Language import Tower.AADL import Ivory.Tower.Config simpleTow...
bdcb9ce6ebf5f721ba3e871a419ad0a281ee5d6378557b8b01e294ef92ab6694
rkallos/wrek
wrek_test_handler.erl
-module(wrek_test_handler). -include("wrek_event.hrl"). -export([code_change/3, handle_call/2, handle_event/2, handle_info/2, init/1, terminate/2]). -behaviour(gen_event). -record(state, { caller = undefined :: pid(), count = 0 :: integer(), evts = [] :: [wrek...
null
https://raw.githubusercontent.com/rkallos/wrek/3859e9efdf21227e6e8e0ea81095b229eceb6641/test/wrek_test_handler.erl
erlang
callbacks private
-module(wrek_test_handler). -include("wrek_event.hrl"). -export([code_change/3, handle_call/2, handle_event/2, handle_info/2, init/1, terminate/2]). -behaviour(gen_event). -record(state, { caller = undefined :: pid(), count = 0 :: integer(), evts = [] :: [wrek...
93076462861f725ce4d339021718cd498e9596f7ca3553b812d201f97742333c
juhp/pkgtreediff
PackageTreeDiff.hs
# LANGUAGE CPP # | A library for pkgtreediff for comparing trees of rpm packages module Distribution.RPM.PackageTreeDiff (RPMPkgDiff(..), Ignore(..), diffPkgs, -- * from rpm-nvr NVRA(..), readNVRA ) where #if !MIN_VERSION_base(4,8,0) import Control.Applicative ((<$>)) #endif import Data.RPM.VerRe...
null
https://raw.githubusercontent.com/juhp/pkgtreediff/87412ffee80f54a1372f96f045d952a6e901662e/src/Distribution/RPM/PackageTreeDiff.hs
haskell
* from rpm-nvr | Ignore describes how comparison is done ^ do not ignore version or release ^ ignore differences in release ^ ignore differences in version | RPMPkgDiff type encodes how a particular rpm package differs between trees cmpVR True ignore release
# LANGUAGE CPP # | A library for pkgtreediff for comparing trees of rpm packages module Distribution.RPM.PackageTreeDiff (RPMPkgDiff(..), Ignore(..), diffPkgs, NVRA(..), readNVRA ) where #if !MIN_VERSION_base(4,8,0) import Control.Applicative ((<$>)) #endif import Data.RPM.VerRel import Data.RPM.NVR...
472a6a08bef7d2b74b1630e46bf3adb849a08542434e92cd676b88fdb46932a9
andreypopp/type-systems
infer.ml
open Base open Expr module Instance = struct type t = { instance : qual_pred; witness : String.t } end module Typeclass = struct type t = { typeclass : qual_pred; instances : Instance.t list } end module Env : sig type t (* Construction API. *) val empty : t val add : t -> String.t -> qual_ty -> t ...
null
https://raw.githubusercontent.com/andreypopp/type-systems/9be1fc78b441f5c2ccf0302993a2b9f08bc16fc2/algo_w/infer.ml
ocaml
Construction API. Query API. TODO: add checks TODO: add checks * Instantiation of type schemas into types. This is done by replacing all generic type variables with fresh unbound type variables. * Solve a set of predicates. This raises a [Type_error] in case it cannot find a suitable instance...
open Base open Expr module Instance = struct type t = { instance : qual_pred; witness : String.t } end module Typeclass = struct type t = { typeclass : qual_pred; instances : Instance.t list } end module Env : sig type t val empty : t val add : t -> String.t -> qual_ty -> t val add_typeclass : t -> q...
79791558a9519c42e4273e7b4434f523a09ef80dbf31c0652c9c0f47fda59240
borkdude/edamame
syntax_quote.cljc
(ns edamame.impl.syntax-quote "Taken and adapted from " {:no-doc true} (:require [clojure.string :as str])) (defn unquote? [form] (and (seq? form) (= (first form) 'clojure.core/unquote))) (defn- unquote-splicing? [form] (and (seq? form) (= (first form) 'clojure.core/unquote-splicing))) (dec...
null
https://raw.githubusercontent.com/borkdude/edamame/e609451d5dc38f347a5e0c68453edd76cccac3ff/src/edamame/impl/syntax_quote.cljc
clojure
But because of -1586 we still need to call seq on the form
(ns edamame.impl.syntax-quote "Taken and adapted from " {:no-doc true} (:require [clojure.string :as str])) (defn unquote? [form] (and (seq? form) (= (first form) 'clojure.core/unquote))) (defn- unquote-splicing? [form] (and (seq? form) (= (first form) 'clojure.core/unquote-splicing))) (dec...
e9066ef6e10336141325b55895ba3abca0f630c6e965766c1f95899fd3bc34af
nikita-volkov/rerebase
QSemN.hs
module Control.Concurrent.QSemN ( module Rebase.Control.Concurrent.QSemN ) where import Rebase.Control.Concurrent.QSemN
null
https://raw.githubusercontent.com/nikita-volkov/rerebase/25895e6d8b0c515c912c509ad8dd8868780a74b6/library/Control/Concurrent/QSemN.hs
haskell
module Control.Concurrent.QSemN ( module Rebase.Control.Concurrent.QSemN ) where import Rebase.Control.Concurrent.QSemN
60a5e51b73bef63beea4eeb73eb48e0d344c719ef14fc82d726482da325b2bc8
rafalio/rafalio
Util.hs
{-# LANGUAGE OverloadedStrings #-} module Site.Util where import Site.PandocProcessors import Hakyll import qualified Data.Map as M import qualified Data.Set as S import Data.Maybe import Data.Time.Format import Data.Time.Clock import Data.List import System.FilePath.Posix import Control.Applicative import System...
null
https://raw.githubusercontent.com/rafalio/rafalio/bebef4904f0538a7c40d1b4a88153e8e56aae11e/src/Site/Util.hs
haskell
# LANGUAGE OverloadedStrings # This gets rid of the date string in my .md post, and adds the "posts/" prefix This is unsafe parse failed, no date available, keep filename get rid of the timestamp
module Site.Util where import Site.PandocProcessors import Hakyll import qualified Data.Map as M import qualified Data.Set as S import Data.Maybe import Data.Time.Format import Data.Time.Clock import Data.List import System.FilePath.Posix import Control.Applicative import System.FilePath (takeBaseName, takeDirect...
b81fc8bd64d6b5354373fd42b485cd4c77a6b54161cb83e498d56ca90f8317b2
illiichi/orenolisp
main_ui.clj
(ns orenolisp.view.ui.main-ui (:require [orenolisp.view.ui.fx-util :as fx] [orenolisp.view.ui.component.typed-history :as typed-history] [orenolisp.view.ui.component.context-display :as context-display] [orenolisp.view.ui.component.viewport :as viewport] [orenolisp.view...
null
https://raw.githubusercontent.com/illiichi/orenolisp/7b085fb687dbe16b5cbe8c739238bbaf79156814/src/orenolisp/view/ui/main_ui.clj
clojure
(ns orenolisp.view.ui.main-ui (:require [orenolisp.view.ui.fx-util :as fx] [orenolisp.view.ui.component.typed-history :as typed-history] [orenolisp.view.ui.component.context-display :as context-display] [orenolisp.view.ui.component.viewport :as viewport] [orenolisp.view...
bd4ccaca70bb959e659ff329f00aafcafb9bc96cde2d511fa0dcf9de17bbc7a7
FranklinChen/learn-you-some-erlang
ppool_supersup.erl
-module(ppool_supersup). -behaviour(supervisor). -export([start_link/0, start_pool/3, stop_pool/1]). -export([init/1]). start_link() -> supervisor:start_link({local, ppool}, ?MODULE, []). start_pool(Name, Limit, MFA) -> ChildSpec = {Name, {ppool_sup, start_link, [Name, Limit, MFA]}, ...
null
https://raw.githubusercontent.com/FranklinChen/learn-you-some-erlang/878c8bc2011a12862fe72dd7fdc6c921348c79d6/release/ppool-1.0/src/ppool_supersup.erl
erlang
-module(ppool_supersup). -behaviour(supervisor). -export([start_link/0, start_pool/3, stop_pool/1]). -export([init/1]). start_link() -> supervisor:start_link({local, ppool}, ?MODULE, []). start_pool(Name, Limit, MFA) -> ChildSpec = {Name, {ppool_sup, start_link, [Name, Limit, MFA]}, ...
3ee0e6521852638b229c1b6840914e5d59a5ae0c6e053cc58075f82564e10cce
fgalassi/cs61a-sp11
2.76.scm
; conventional: ; to add a type, go into each generic operation and add a cond to deal with the new type ; to add an operation, create a new function for the operation dealing with every available type ; BEST IF WE FREQUENTLY ADD NEW OPERATIONS ; message-passing: ; to add a type, create a new function for the type dea...
null
https://raw.githubusercontent.com/fgalassi/cs61a-sp11/66df3b54b03ee27f368c716ae314fd7ed85c4dba/homework/2.76.scm
scheme
conventional: to add a type, go into each generic operation and add a cond to deal with the new type to add an operation, create a new function for the operation dealing with every available type BEST IF WE FREQUENTLY ADD NEW OPERATIONS message-passing: to add a type, create a new function for the type dealing wi...
2a6c65f4ce0eba9436edf83f5483f2643dbc6838a91a8d41a38bc177d4439003
Mesabloo/nihil
Lambda.hs
# LANGUAGE BlockArguments # {-# LANGUAGE OverloadedStrings #-} module Nihil.Syntax.Concrete.Parser.Expression.Lambda where import Nihil.Syntax.Common (Parser) import Nihil.Syntax.Concrete.Core import Nihil.Syntax.Concrete.Parser.Identifier import qualified Nihil.Syntax.Concrete.Parser.Pattern.Atom as Pattern import {...
null
https://raw.githubusercontent.com/Mesabloo/nihil/3821052ca5691a6492b23bd8a46bfe70567d374f/src/parser/Nihil/Syntax/Concrete/Parser/Expression/Lambda.hs
haskell
# LANGUAGE OverloadedStrings # # SOURCE #
# LANGUAGE BlockArguments # module Nihil.Syntax.Concrete.Parser.Expression.Lambda where import Nihil.Syntax.Common (Parser) import Nihil.Syntax.Concrete.Core import Nihil.Syntax.Concrete.Parser.Identifier import qualified Nihil.Syntax.Concrete.Parser.Pattern.Atom as Pattern import Nihil.Syntax.Concrete.Debug import C...
b1229c61531c08dbef909acc6fbd829d4ff29d5e11838bb047f4761c9efa8b4d
marcoheisig/Petalisp
lazy-stack.lisp
© 2016 - 2023 - license : GNU AGPLv3 -*- coding : utf-8 -*- (in-package #:petalisp.api) (defun lazy-stack (axis array &rest more-arrays) (let* ((arrays (list* array more-arrays)) (lazy-array (lazy-array array)) (more-lazy-arrays (mapcar #'lazy-array more-arrays)) (lazy-arrays...
null
https://raw.githubusercontent.com/marcoheisig/Petalisp/834e972cc9c10d08b24be033de6772d36fe87960/code/api/lazy-stack.lisp
lisp
Check that the axis is valid. Check that all supplied arrays have the same rank, and the same Determine the step size. Now stack the arrays.
© 2016 - 2023 - license : GNU AGPLv3 -*- coding : utf-8 -*- (in-package #:petalisp.api) (defun lazy-stack (axis array &rest more-arrays) (let* ((arrays (list* array more-arrays)) (lazy-array (lazy-array array)) (more-lazy-arrays (mapcar #'lazy-array more-arrays)) (lazy-arrays...
5ed2e367f94bf17b50ab90cc407f3ac115990ae01ca67b112bc93aab056b004b
AdaCore/why3
eliminate_unused.ml
open Decl open Task open Term let term_lsymbols = (* compute lsymbols of a term *) let rec aux acc (t: term) = match t.t_node with | Tapp (ls, _) -> Term.t_fold aux (Term.Sls.add ls acc) t | _ -> Term.t_fold aux acc t in aux Sls.empty let defn_symbols defn = let _, def = open_ls_defn defn in t...
null
https://raw.githubusercontent.com/AdaCore/why3/a07f5a6a593a545047d0fe4073bf458b935aa10c/src/transform/eliminate_unused.ml
ocaml
compute lsymbols of a term
open Decl open Task open Term let term_lsymbols = let rec aux acc (t: term) = match t.t_node with | Tapp (ls, _) -> Term.t_fold aux (Term.Sls.add ls acc) t | _ -> Term.t_fold aux acc t in aux Sls.empty let defn_symbols defn = let _, def = open_ls_defn defn in term_lsymbols def let compute_neede...
b5f0fa1fb53a88a179e930fa7b99443a4c47087154bb305dbdeb23637f699ca1
input-output-hk/io-sim
Trace.hs
# LANGUAGE DeriveFunctor # module Data.List.Trace ( Trace (..) , ppTrace , toList , fromList , head , tail , filter , length ) where import Prelude hiding (filter, head, length, tail) import Control.Applicative (Alternative (..)) import Control.Monad (MonadPlus (..)) i...
null
https://raw.githubusercontent.com/input-output-hk/io-sim/15a46359d92c2f6a63fcf4671bf5ef4be0c75c35/io-sim/src/Data/List/Trace.hs
haskell
| A 'cons' list with polymorphic 'nil', thus an octopus. * @'Trace' Void a@ is an infinite stream * @'Trace' () a@ is isomorphic to @[a]@ Usually used with @a@ being a non empty sum type. | Pretty print an 'Trace'. # INLINE[0] bifoldl #
# LANGUAGE DeriveFunctor # module Data.List.Trace ( Trace (..) , ppTrace , toList , fromList , head , tail , filter , length ) where import Prelude hiding (filter, head, length, tail) import Control.Applicative (Alternative (..)) import Control.Monad (MonadPlus (..)) i...
6e485c46ddab31c64ed908ecde56579acc32611b77f5f47d5a179a656b4e1761
rbkmoney/fistful-server
ff_transfer_SUITE.erl
-module(ff_transfer_SUITE). -include_lib("fistful_proto/include/ff_proto_fistful_admin_thrift.hrl"). -include_lib("fistful_proto/include/ff_proto_withdrawal_thrift.hrl"). -include_lib("damsel/include/dmsl_domain_thrift.hrl"). -export([all/0]). -export([groups/0]). -export([init_per_suite/1]). -export([end_per_suite/1...
null
https://raw.githubusercontent.com/rbkmoney/fistful-server/f6155acb0475987e47a4fbc911758c595e129c80/apps/ff_transfer/test/ff_transfer_SUITE.erl
erlang
Create source Process deposit Create source Create source Create source
-module(ff_transfer_SUITE). -include_lib("fistful_proto/include/ff_proto_fistful_admin_thrift.hrl"). -include_lib("fistful_proto/include/ff_proto_withdrawal_thrift.hrl"). -include_lib("damsel/include/dmsl_domain_thrift.hrl"). -export([all/0]). -export([groups/0]). -export([init_per_suite/1]). -export([end_per_suite/1...
841144bec5556191b79121ec7ea150aee5ff9e01d20eefb4d515ecef050a64eb
rescript-lang/rescript-compiler
typedecl.ml
(**************************************************************************) (* *) (* OCaml *) (* *) and ,...
null
https://raw.githubusercontent.com/rescript-lang/rescript-compiler/eb07cb50b6e6ba2bf26ce667d4e3c638a24b35c4/jscomp/ml/typedecl.ml
ocaml
************************************************************************ OCaml ...
and , projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et the GNU Lesser General Public License version 2.1 , with the open Misc open Asttypes open Parsetree open Primitive open Types open Typetexp type native_repr_kind = Unboxed | Unta...
5acfdf67611c9af37974c602f8ad1068c888529c9af0ff00dd84237d4fccb1a7
brendanhay/terrafomo
Types.hs
-- This module was auto-generated. If it is modified, it will not be overwritten. -- | Module : . NewRelic . Types Copyright : ( c ) 2017 - 2018 License : Mozilla Public License , v. 2.0 . Maintainer : < brendan.g.hay+ > -- Stability : auto-generated Portability : non - portable ( GHC ...
null
https://raw.githubusercontent.com/brendanhay/terrafomo/387a0e9341fb9cd5543ef8332dea126f50f1070e/provider/terrafomo-newrelic/src/Terrafomo/NewRelic/Types.hs
haskell
This module was auto-generated. If it is modified, it will not be overwritten. | Stability : auto-generated import Formatting (Format, (%))
Module : . NewRelic . Types Copyright : ( c ) 2017 - 2018 License : Mozilla Public License , v. 2.0 . Maintainer : < brendan.g.hay+ > Portability : non - portable ( GHC extensions ) module Terrafomo.NewRelic.Types where import Data . Text ( Text ) import Terrafomo import Terraf...
5329ca050c5453b2b9513933fbb76b2c4155555d0344ea56838c1dfd2994114d
NoRedInk/jetpack
Files.hs
{-| Helpers for working with files/paths/dirs) -} module Utils.Files ( pathToFileName ) where import qualified Data.List as L import qualified Data.Text as T import System.FilePath ((<.>), splitDirectories) | Converts a path into a flat filename . > > > import System . FilePath ( ( < / > ) , ( < . > ) ) ...
null
https://raw.githubusercontent.com/NoRedInk/jetpack/721d12226b593c117cba26ceb7c463c7c3334b8b/src/Utils/Files.hs
haskell
| Helpers for working with files/paths/dirs)
module Utils.Files ( pathToFileName ) where import qualified Data.List as L import qualified Data.Text as T import System.FilePath ((<.>), splitDirectories) | Converts a path into a flat filename . > > > import System . FilePath ( ( < / > ) , ( < . > ) ) > > > pathToFileName ( " . " < / > " foo " < / ...
2d6ae00f59bb0b5f09bb981516903812b15d7eab9d6869ffa27ccfcf11b05281
dfinity-side-projects/dhc
Boost.hs
# LANGUAGE CPP # module Boost ( QuasiWasm , QuasiWasmHelper(..) , tag_const, Tag(..) , Boost(..) #ifdef __HASTE__ , (<>) #endif ) where #ifndef __HASTE__ import Data.Semigroup () #endif import Ast import WasmOp | Data on the heap is 64 - bit aligned . The first 8 bits hold a tag . -- -- The following t...
null
https://raw.githubusercontent.com/dfinity-side-projects/dhc/60ac6c85ca02b53c0fdd1f5852c1eaf35f97d579/src/Boost.hs
haskell
The following tables describe the field at a given offset of an object integer type. Int64s: Ports: 0 TagSum | (arity << 8) Application `f x`: 12 x Global function: Indirection: 0 TagInd String: For example, `Just 42` is represented by: | A few helpers for inline assembly. Find function...
# LANGUAGE CPP # module Boost ( QuasiWasm , QuasiWasmHelper(..) , tag_const, Tag(..) , Boost(..) #ifdef __HASTE__ , (<>) #endif ) where #ifndef __HASTE__ import Data.Semigroup () #endif import Ast import WasmOp | Data on the heap is 64 - bit aligned . The first 8 bits hold a tag . on the heap . All f...
f8194e8af7220f6e0e750f026f067abedf8e2ce017fdd53f3411c877707424e2
CardanoSolutions/ogmios
Util.hs
This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. module Test.Instances.Util ( eqShowJson ) where import Ogmios.Prelude import Data.Aeson ( ToJSON (..) ) import Test.Hspec ...
null
https://raw.githubusercontent.com/CardanoSolutions/ogmios/317c826d9d0388cb7efaf61a34085fc7c1b12b06/server/test/unit/Test/Instances/Util.hs
haskell
instances, as well as record-fields.
This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. module Test.Instances.Util ( eqShowJson ) where import Ogmios.Prelude import Data.Aeson ( ToJSON (..) ) import Test.Hspec ...
64306739174509bc440164fd0f31d8973fb7ff932a0819f2f260993ecf631ac1
cram-code/cram_core
designator-pose.lisp
;;; Copyright ( c ) 2010 , < > ;;; All rights reserved. ;;; ;;; Redistribution and use in source and binary forms, with or without ;;; modification, are permitted provided that the following conditions are met: ;;; ;;; * Redistributions of source code must retain the above copyright ;;; notice, this li...
null
https://raw.githubusercontent.com/cram-code/cram_core/984046abe2ec9e25b63e52007ed3b857c3d9a13c/cram_designators/src/cram-designators/designator-pose.lisp
lisp
All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Re...
Copyright ( c ) 2010 , < > * Neither the name of the Intelligent Autonomous Systems Group/ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS " AS IS " IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED . IN NO EVENT SHALL THE COPYRIGHT OWNER OR ...
65cce28fe09d54f34b8d5d35ed92066a1688a65ea5592daf199bbc2b5031d5fe
puppetlabs/trapperkeeper
project.clj
(defproject puppetlabs/trapperkeeper "3.2.2-SNAPSHOT" :description "A framework for configuring, composing, and running Clojure services." :license {:name "Apache License, Version 2.0" :url "-2.0.html"} :min-lein-version "2.9.0" :parent-project {:coords [puppetlabs/clj-parent "4.6.17"] ...
null
https://raw.githubusercontent.com/puppetlabs/trapperkeeper/5ac89448d149838f19649856b17178c7d943d1da/project.clj
clojure
Abort when version ranges or version conflicts are detected in dependencies. Also supports :warn to simply emit warnings. logback artifacts, specifying the dependency version here ensures that downstream projects don't pick up different versions that would conflict with our version of logback-classic Convenience ...
(defproject puppetlabs/trapperkeeper "3.2.2-SNAPSHOT" :description "A framework for configuring, composing, and running Clojure services." :license {:name "Apache License, Version 2.0" :url "-2.0.html"} :min-lein-version "2.9.0" :parent-project {:coords [puppetlabs/clj-parent "4.6.17"] ...
157f9d758e695781c5df87316b351ab35cc4e64759b3ffb20516d52e257bab96
reflex-frp/reflex
Class.hs
# LANGUAGE CPP # {-# LANGUAGE DeriveDataTypeable #-} # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE TypeFamilies # # LANGUAGE UndecidableInstances # -- | -- Module: Reflex . Query . Class -- Description: -- A clas...
null
https://raw.githubusercontent.com/reflex-frp/reflex/d9a40cd97072869c91479303ee52577b793c11d2/src/Reflex/Query/Class.hs
haskell
# LANGUAGE DeriveDataTypeable # | Module: Description: A class that ties together queries to some data source and their results, providing methods for requesting data from the source and accumulating streamed results. | A 'Query' can be thought of as a declaration of interest in some set of data. A 'Query...
# LANGUAGE CPP # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE TypeFamilies # # LANGUAGE UndecidableInstances # Reflex . Query . Class module Reflex.Query.Class ( Query (..) , QueryMorphism (..) , SelectedCou...
f5c3c73da3b5edcd981a97ce083b93cf9cf7aa59089629f2cee05f5ce88ad3e1
mbutterick/txexpr
container.rkt
#lang racket/base (provide txexpr?/recur txexpr->values/attrs?) (require racket/list) A [ TXcontainer T A E ] is one of : - ( List * T A ( E ) ) - ( Lxst * T ( E ) ) ;; Where A and E are disjoint. ;; txexpr?/recur : ;; Any ;; [Any -> Bool : T] ;; [Any -> Bool : #:+ (and A (! E)) #:- (! A)] ...
null
https://raw.githubusercontent.com/mbutterick/txexpr/435c6e6f36fd39065ae9d8a00285fda0e4e41fa1/txexpr/private/container.rkt
racket
Where A and E are disjoint. txexpr?/recur : Any [Any -> Bool : T] [Any -> Bool : #:+ (and A (! E)) #:- (! A)] [Any -> Bool : #:+ (and E (! A)) #:- (! E)] -> : [TXcontainer T A E] the attrs? predicate and the element? predicate should be disjoint txexpr->values/attrs? : [TXcontainer T A E] [A...
#lang racket/base (provide txexpr?/recur txexpr->values/attrs?) (require racket/list) A [ TXcontainer T A E ] is one of : - ( List * T A ( E ) ) - ( Lxst * T ( E ) ) (define (txexpr?/recur v tag? attrs? element?) (and (list? v) (not (empty? v)) (tag? (first v)) (cond [...
9cf6bb5c2acb391dbed759f5ed6b54f70ffe3b8c09b485f0e6610bc4d46c78a4
district0x/district0x-network-token
main_panel.cljs
(ns contribution.components.main-panel (:require [cljs-react-material-ui.core :refer [get-mui-theme]] [cljs-react-material-ui.reagent :as ui] [cljs-time.core :as t] [clojure.set :as set] [contribution.constants :as constants] [contribution.styles :as styles] [district0x.components.active-a...
null
https://raw.githubusercontent.com/district0x/district0x-network-token/a002f39312989d4099468d155c68feeedd708c16/src/cljs/contribution/components/main_panel.cljs
clojure
(ns contribution.components.main-panel (:require [cljs-react-material-ui.core :refer [get-mui-theme]] [cljs-react-material-ui.reagent :as ui] [cljs-time.core :as t] [clojure.set :as set] [contribution.constants :as constants] [contribution.styles :as styles] [district0x.components.active-a...
39c0b4ea55245464692227d23474389056d6122a874dccde9f4b66ea272d5254
cardmagic/lucash
package.scm
Copyright ( c ) 1993 - 1999 by and . See file COPYING . ; Structures 'n' packages. ; -------------------- ; Structures ; ; A structure is a map from names to binding records, determined by an ; interface (a set of names) and a package (a map from names to binding ; records). ; ; The interface is specified as a...
null
https://raw.githubusercontent.com/cardmagic/lucash/0452d410430d12140c14948f7f583624f819cdad/reference/scsh-0.6.6/scheme/bcomp/package.scm
scheme
Structures 'n' packages. -------------------- Structures A structure is a map from names to binding records, determined by an interface (a set of names) and a package (a map from names to binding records). The interface is specified as a thunk. This removes dependencies on the order in which structures are d...
Copyright ( c ) 1993 - 1999 by and . See file COPYING . (define-record-type structure :structure (really-make-structure package interface-thunk interface clients name) structure? (interface-thunk structure-interface-thunk) (interface structure-interface-really set-structure-interface!) (package st...
a6cee196bf79aa08242d2a60ae8e6093d0b2841ff4bf6bd45c8a3c66fb48f7bb
RedPenguin101/aoc2021
day01.clj
(ns aoc2021.day01 (:require [clojure.string :as str])) (def input (map #(Long/parseLong %) (str/split-lines (slurp "resources/day01input.txt")))) (count (filter #(apply < %) (partition 2 1 input))) = > 1715 (->> input (partition 3 1) (map #(apply + %)) (partition 2 1) (filter #(apply < %)) ...
null
https://raw.githubusercontent.com/RedPenguin101/aoc2021/891eec01684e218879c2ac150b83e62a30fe6ba6/clojure/src/aoc2021/day01.clj
clojure
(ns aoc2021.day01 (:require [clojure.string :as str])) (def input (map #(Long/parseLong %) (str/split-lines (slurp "resources/day01input.txt")))) (count (filter #(apply < %) (partition 2 1 input))) = > 1715 (->> input (partition 3 1) (map #(apply + %)) (partition 2 1) (filter #(apply < %)) ...
2d4350fad305eb67eeb9798c9342bc2db100904bbc619bd6b8a63143ffe6d87f
jaseemabid/mit-scheme
div.scm
(declare (usual-integrations)) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; File: div.sch Description : DIV benchmarks Author : ; Created: 8-Apr-85 Modified : 19 - Jul-85 18:28:01 ( ) 23 - Jul-87 ( ) ; Language: Scheme ; Sta...
null
https://raw.githubusercontent.com/jaseemabid/mit-scheme/d30da6b2c103e34b6e0805bd5cbefeb9501382c1/v8/src/bench/div.scm
scheme
File: div.sch Created: 8-Apr-85 Language: Scheme Status: Public Domain This file contains a recursive as well as an iterative test. for the iterative test call: (test-1 *ll*) for the recursive test call: (test-2 *ll*)
(declare (usual-integrations)) Description : DIV benchmarks Author : Modified : 19 - Jul-85 18:28:01 ( ) 23 - Jul-87 ( ) DIV2 -- Benchmark which divides by 2 using lists of n ( ) 's . (define (create-n n) (do ((n n (- n 1)) (a '() (cons '() a))) ((= n 0) a...
6915cc65532997e49de06af6baaefb90c47414a6b54e86b43ea2782931d30ced
TrustInSoft/tis-kernel
emitter.ml
(**************************************************************************) (* *) This file is part of . (* *) is a fork of Frama - C. Al...
null
https://raw.githubusercontent.com/TrustInSoft/tis-kernel/748d28baba90c03c0f5f4654d2e7bb47dfbe4e7d/src/kernel_services/plugin_entry_points/emitter.ml
ocaml
************************************************************************ ...
This file is part of . is a fork of Frama - C. All the differences are : Copyright ( C ) 2016 - 2017 is released under GPLv2 This file is part of Frama - C. Copyright ( C ) 2007 - 2015 ...
a5c8d3f21a92ad3305c4255b334a6887d09cb3b9e1b933cd03cd0379d32dfa17
jackfirth/rebellion
endpoint-map-range-set.rkt
#lang racket/base (require racket/contract/base) (provide for/range-set for*/range-set (contract-out [range-set (->* () (#:comparator comparator?) #:rest (listof nonempty-range?) immutable-range-set?)] [make-mutable-range-set (->* (#:comparator comparator?) ((sequence/c nonempty-range?)) mutable-range-set...
null
https://raw.githubusercontent.com/jackfirth/rebellion/69dce215e231e62889389bc40be11f5b4387b304/collection/private/endpoint-map-range-set.rkt
racket
@---------------------------------------------------------------------------------------------------- @---------------------------------------------------------------------------------------------------- Construction APIs
#lang racket/base (require racket/contract/base) (provide for/range-set for*/range-set (contract-out [range-set (->* () (#:comparator comparator?) #:rest (listof nonempty-range?) immutable-range-set?)] [make-mutable-range-set (->* (#:comparator comparator?) ((sequence/c nonempty-range?)) mutable-range-set...
d2fd774c6ac56e79872079e5d992a5d058add47374a6b7b0440a7d7e4636afee
ktakashi/sagittarius-scheme
kdfs.scm
-*- mode : scheme ; coding : utf-8 ; -*- ;;; ;;; sagittarius/crypto/kdfs.scm - KDFs ;;; Copyright ( c ) 2022 < > ;;; ;;; Redistribution and use in source and binary forms, with or without ;;; modification, are permitted provided that the following conditions ;;; are met: ;;; ;;; 1. Redistri...
null
https://raw.githubusercontent.com/ktakashi/sagittarius-scheme/791dea707ecd116670691d764b7726cc49f648be/ext/crypto/sagittarius/crypto/kdfs.scm
scheme
coding : utf-8 ; -*- sagittarius/crypto/kdfs.scm - KDFs Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of co...
Copyright ( c ) 2022 < > " AS IS " AND ANY EXPRESS OR IMPLIED WARRANTIES , INCLUDING , BUT NOT SPECIAL , EXEMPLARY , OR CONSEQUENTIAL DAMAGES ( INCLUDING , BUT NOT LIMITED LIABILITY , WHETHER IN CONTRACT , STRICT LIABILITY , OR TORT ( INCLUDING #!nounbound (library (sagittarius crypto kdfs) ...
9f65deabd119927eaf28d2dc25d592b412fc3703baae434d9a707d10dbaf3665
cyverse-archive/DiscoveryEnvironmentBackend
folder.clj
(ns iplant_groups.routes.domain.folder (:use [common-swagger-api.schema :only [describe ->optional-param]]) (:require [iplant_groups.routes.domain.params :as params] [schema.core :as s])) (s/defschema BaseFolder {:name (describe String "The internal folder name.") (s/optional-key :description)...
null
https://raw.githubusercontent.com/cyverse-archive/DiscoveryEnvironmentBackend/7f6177078c1a1cb6d11e62f12cfe2e22d669635b/services/iplant-groups/src/iplant_groups/routes/domain/folder.clj
clojure
(ns iplant_groups.routes.domain.folder (:use [common-swagger-api.schema :only [describe ->optional-param]]) (:require [iplant_groups.routes.domain.params :as params] [schema.core :as s])) (s/defschema BaseFolder {:name (describe String "The internal folder name.") (s/optional-key :description)...
df0d9493704d6a686561401cab757b5270dddd56166d18320c4f5b2fe002144b
BitGameEN/bitgamex
ranch_server.erl
Copyright ( c ) 2012 - 2018 , < > %% %% 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 DISC...
null
https://raw.githubusercontent.com/BitGameEN/bitgamex/151ba70a481615379f9648581a5d459b503abe19/src/deps/ranch/src/ranch_server.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 - 2018 , < > 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(ranch_server). -behaviour(gen_server). -expo...
fc93ad4b90635bf5ef17a1e2db0edfdcaadf948b6717a63c1172ff754482b512
kennknowles/aspcc
tools.ml
(** ASPCC module with the Tools object *) open VbValues open VbClass open VbTypes open Runtime open Printf class tools = object(self) inherit opaque_object method strname = "MSWC.Tools" method m_gets name params = match name with | "fileexists" -> wrap_bool (Sys.fil...
null
https://raw.githubusercontent.com/kennknowles/aspcc/951a91cc21e291b1d3c750bbbca7fa79209edd08/runtime/modules/tools.ml
ocaml
* ASPCC module with the Tools object * {4 Loader Function}
open VbValues open VbClass open VbTypes open Runtime open Printf class tools = object(self) inherit opaque_object method strname = "MSWC.Tools" method m_gets name params = match name with | "fileexists" -> wrap_bool (Sys.file_exists (get_string !(arg1 "Tools.FileExi...
ac0a9bd26ee3554f93cdbd498be995eeeea0d9a3feca7144ca9d68ee696e650b
cram2/cram
atomic-action-designators.lisp
;;; Copyright ( c ) 2016 , < > ;;; All rights reserved. ;;; ;;; Redistribution and use in source and binary forms, with or without ;;; modification, are permitted provided that the following conditions are met: ;;; ;;; * Redistributions of source code must retain the above copyright ;;; notice, this list...
null
https://raw.githubusercontent.com/cram2/cram/dcb73031ee944d04215bbff9e98b9e8c210ef6c5/cram_boxy/cram_boxy_plans/src/atomic-action-designators.lisp
lisp
All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redi...
Copyright ( c ) 2016 , < > * Neither the name of the Institute for Artificial Intelligence/ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS " AS IS " IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED . IN NO EVENT SHALL THE COPYRIGHT OWNER OR ...