_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
7b10a052ab378fa25c724ab085e0c1ea22cfce605b7ae1e84708fe4ef26e0983
3b/3bgl-misc
bench.lisp
(in-package #:3bgl-bench) (defclass im-bench (basecode-glut perspective-projection basecode-clear ;;fps-graph basecode-draw-ground-plane basecode-exit-on-esc freelook-camera) ((count :accessor vertex-count :initform 1)) (:default-initargs :look-at-eye '(5...
null
https://raw.githubusercontent.com/3b/3bgl-misc/e3bf2781d603feb6b44e5c4ec20f06225648ffd9/bench/bench.lisp
lisp
fps-graph basecode-draw-ground-plane cffi enums are slow :/
(in-package #:3bgl-bench) (defclass im-bench (basecode-glut perspective-projection basecode-clear basecode-exit-on-esc freelook-camera) ((count :accessor vertex-count :initform 1)) (:default-initargs :look-at-eye '(5 12 -20))) (defparameter *points* 0) (defparameter *frames...
e9aa9dc6e556d0e2f3c5be0cef9feb02792db327f11365df3ec82d0bac79241a
commonqt/commonqt
microbench.lisp
;;;; ;;;; Evaluate ;;;; (qt::microbench) ;;;; to run these benchmarks on an otherwise idle computer. Results are ;;;; written to the REPL, and in a machine readable format also dribbled ;;;; to files. Files names are, by default, of the form <lisp ;;;; implementation type>.txt. ;;;; Notes : 1 . These are micro...
null
https://raw.githubusercontent.com/commonqt/commonqt/dffff3ee3dbd0686c85c323f579b8bbf4881e60e/test/microbench.lisp
lisp
Evaluate (qt::microbench) to run these benchmarks on an otherwise idle computer. Results are written to the REPL, and in a machine readable format also dribbled to files. Files names are, by default, of the form <lisp implementation type>.txt. implementation. They do not necessarily reflect overall or...
Notes : 1 . These are microbenchmarks meant to aid understanding of the 2 . Since each individual operation is too fast to benchmark , we 3 . Before running benchmarks , we choose a repetition time depending on how fast ( or slow ) a simple test case is , so that slow 4 . Benchmarks are run three t...
5f370f4344dcc86cdfe8d16692670f8cd4ea2751b7466411fa3d12e27851f204
lowasser/TrieMap
OrdMap.hs
# LANGUAGE CPP # {-# OPTIONS -funbox-strict-fields #-} module Data.TrieMap.OrdMap () where import Data.TrieMap.TrieKey import Data.TrieMap.OrdMap.Base import Data.TrieMap.OrdMap.Alternatable () import Data.TrieMap.OrdMap.Searchable () import Data.TrieMap.OrdMap.Indexable () import Data.TrieMap.OrdMap.Traversable () im...
null
https://raw.githubusercontent.com/lowasser/TrieMap/1ab52b8d83469974a629f2aa577a85de3f9e867a/Data/TrieMap/OrdMap.hs
haskell
# OPTIONS -funbox-strict-fields # | @'TrieMap' ('Ordered' k) a@ is based on "Data.Map".
# LANGUAGE CPP # module Data.TrieMap.OrdMap () where import Data.TrieMap.TrieKey import Data.TrieMap.OrdMap.Base import Data.TrieMap.OrdMap.Alternatable () import Data.TrieMap.OrdMap.Searchable () import Data.TrieMap.OrdMap.Indexable () import Data.TrieMap.OrdMap.Traversable () import Data.TrieMap.OrdMap.Subset () imp...
5d084af4183e6efaeb786fee8f8567b0129342b353512732c8f736ea8db61012
WormBase/wormbase_rest
core.clj
(ns rest-api.classes.protein.core (:require [clojure.string :as str] [datomic.api :as d] [clojure.math.numeric-tower :as math] [rest-api.db.main :refer [datomic-homology-conn datomic-conn]] [rest-api.formatters.object :as obj :refer [pack-obj]])) (defn ** [x n] (reduce * (repeat n x))) (defn get-moti...
null
https://raw.githubusercontent.com/WormBase/wormbase_rest/e51026f35b87d96260b62ddb5458a81ee911bf3a/src/rest_api/classes/protein/core.clj
clojure
skip mass-spec results
(ns rest-api.classes.protein.core (:require [clojure.string :as str] [datomic.api :as d] [clojure.math.numeric-tower :as math] [rest-api.db.main :refer [datomic-homology-conn datomic-conn]] [rest-api.formatters.object :as obj :refer [pack-obj]])) (defn ** [x n] (reduce * (repeat n x))) (defn get-moti...
dc00bcee34b993a14c716ab582a3d3c6d6782142740d16bea6699cd60b687952
chaw/r7rs-libs
example-relief.sps
(import (scheme base) (srfi 42) (rebottled pstk)) (let ((tk (tk-start))) (tk/wm 'title tk "PS/Tk Example: Label relief") (tk 'configure 'borderwidth: 10) (do-ec (: relief '("raised" "sunken" "flat" "ridge" "groove" "solid")) (tk/pack (tk 'create-widget 'label 'text: relief 'relief: relief ...
null
https://raw.githubusercontent.com/chaw/r7rs-libs/b8b625c36b040ff3d4b723e4346629a8a0e8d6c2/rebottled-examples/pstk/example-relief.sps
scheme
width of the relief inner padding, between label and its relief hardcode desired size of label 'anchor: "nw" ; indicate position for text of label
(import (scheme base) (srfi 42) (rebottled pstk)) (let ((tk (tk-start))) (tk/wm 'title tk "PS/Tk Example: Label relief") (tk 'configure 'borderwidth: 10) (do-ec (: relief '("raised" "sunken" "flat" "ridge" "groove" "solid")) (tk/pack (tk 'create-widget 'label 'text: relief 'relief: relief ...
69792e275f6a9084c81de921b4949a25db02ffc79e4a623dd6de6eae05450dbb
digikar99/numericals
tests.lisp
(defpackage :sbcl-numericals.test (:use :sbcl-numericals :cl :fiveam :alexandria)) (in-package :sbcl-numericals.test) (def-suite :sbcl-numericals) (in-suite :sbcl-numericals) (defun map-array (function arr-a arr-b arr-c) (unless (and (equalp (array-dimensions arr-a) (array-dimensions arr-b)) (equa...
null
https://raw.githubusercontent.com/digikar99/numericals/4f82b74e32b054f65110ee62ba080603c92ac103/sbcl-numericals/t/tests.lisp
lisp
(defpackage :sbcl-numericals.test (:use :sbcl-numericals :cl :fiveam :alexandria)) (in-package :sbcl-numericals.test) (def-suite :sbcl-numericals) (in-suite :sbcl-numericals) (defun map-array (function arr-a arr-b arr-c) (unless (and (equalp (array-dimensions arr-a) (array-dimensions arr-b)) (equa...
c9b4eb07e20c065a4ad64ef0606819d486241edb76a1b5d571c9480194907764
polymeris/cljs-aws
codebuild.cljs
(ns cljs-aws.codebuild (:require [cljs-aws.base.requests]) (:require-macros [cljs-aws.base.service :refer [defservice]])) (defservice "CodeBuild" "codebuild-2016-10-06.min.json")
null
https://raw.githubusercontent.com/polymeris/cljs-aws/3326e7c4db4dfc36dcb80770610c14c8a7fd0d66/src/cljs_aws/codebuild.cljs
clojure
(ns cljs-aws.codebuild (:require [cljs-aws.base.requests]) (:require-macros [cljs-aws.base.service :refer [defservice]])) (defservice "CodeBuild" "codebuild-2016-10-06.min.json")
dadcb78090dfac4b230a9b5ea55ec337a7df0dad069bf9d0b5de042e9c0e4c95
gmr/privatepaste
privpaste_db.erl
%% ------------------------------------------------------------------ Database Abstraction %% ------------------------------------------------------------------ -module(privpaste_db). -export([create_paste/2, delete_paste/1, get_paste/2, increment_paste_views/2, update_paste/3]). ...
null
https://raw.githubusercontent.com/gmr/privatepaste/4cc53473eb7e3d4d237df4b18fce573e3588ec24/src/privpaste_db.erl
erlang
------------------------------------------------------------------ ------------------------------------------------------------------ ------------------------------------------------------------------ Internal Methods ------------------------------------------------------------------ -----------------------------...
Database Abstraction -module(privpaste_db). -export([create_paste/2, delete_paste/1, get_paste/2, increment_paste_views/2, update_paste/3]). -include("privpaste.hrl"). create_paste(Hostname, Paste) -> try ok = check_hostname(Hostname, Paste), ok = check_id_is...
39df4bc70040885a60b36999e725773660a569ee986c7307530eb02efbb48b73
kunstmusik/pink
processes_test.clj
(ns pink.processes-test (:require [pink.processes :refer [process wait cue countdown-latch] :as p] [pink.config :refer :all] [clojure.test :refer :all])) (deftest test-process (let [counter (atom 0) p (process (reset! counter 1) (wait 1.0) (rese...
null
https://raw.githubusercontent.com/kunstmusik/pink/7d37764b6a036a68a4619c93546fa3887f9951a7/src/test/pink/processes_test.clj
clojure
the last wait from previous loop starts the next wait, than num-wait, due to leftover samples from previous wait time
(ns pink.processes-test (:require [pink.processes :refer [process wait cue countdown-latch] :as p] [pink.config :refer :all] [clojure.test :refer :all])) (deftest test-process (let [counter (atom 0) p (process (reset! counter 1) (wait 1.0) (rese...
651ed18550ca4688efb0051d2318e6acb5f1c64b8d4605e7d069fabc7dd6fd61
nkaretnikov/OOHaskell
Polymorph.hs
( C ) 2004 - 2005 , Oleg Kiselyov & 's overlooked object system module Polymorph where import Shape Weirich 's / 's test case main = do -- Handle the shapes polymorphically let scribble = [ Rectangle 10 20 5 6 , Circle 15 25 8 ] ...
null
https://raw.githubusercontent.com/nkaretnikov/OOHaskell/ddf42cfa62f8bd27643ff6db136dec6c14466232/repository/shapes/Haskell/Shapes1/Polymorph.hs
haskell
Handle the shapes polymorphically Handle rectangle-specific instance
( C ) 2004 - 2005 , Oleg Kiselyov & 's overlooked object system module Polymorph where import Shape Weirich 's / 's test case main = do let scribble = [ Rectangle 10 20 5 6 , Circle 15 25 8 ] mapM_ (\x -> do draw x ...
b1e54b3bbc4e1a55ff9ec298c810b007db697164a4f03213b8f6257715b8ba42
pirapira/coq2rust
universes.mli
(************************************************************************) v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2012 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *...
null
https://raw.githubusercontent.com/pirapira/coq2rust/22e8aaefc723bfb324ca2001b2b8e51fcc923543/library/universes.mli
ocaml
********************************************************************** // * This file is distributed under the terms of the * GNU Lesser General Public License Version 2.1 ********************************************************************** * Universes * The global universe c...
v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2012 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * open Util open Pp open Names ...
4ab7c16f1f51b73eb1371962aa48849c2d0a583b2fb4fdb4bd85fa27e4341b20
spurious/chibi-scheme-mirror
procedural.scm
(define (make-rtd name fields . o) (let ((parent (and (pair? o) (car o)))) (register-simple-type name parent (vector->list fields)))) (define (rtd? x) (type? x)) (define (rtd-constructor rtd . o) (let ((fields (vector->list (if (pair? o) (car o) (rtd-all-field-names rtd)))) (make (make-constructor ...
null
https://raw.githubusercontent.com/spurious/chibi-scheme-mirror/49168ab073f64a95c834b5f584a9aaea3469594d/lib/srfi/99/records/procedural.scm
scheme
(define (make-rtd name fields . o) (let ((parent (and (pair? o) (car o)))) (register-simple-type name parent (vector->list fields)))) (define (rtd? x) (type? x)) (define (rtd-constructor rtd . o) (let ((fields (vector->list (if (pair? o) (car o) (rtd-all-field-names rtd)))) (make (make-constructor ...
1962399238f9cc3f38553f6ea144200c07aab784ce1fd76fc2fda5b129b190e0
camsaul/toucan2
query_test.clj
(ns toucan2.query-test (:require [clojure.test :refer :all] [methodical.core :as m] [toucan2.model :as model] [toucan2.pipeline :as pipeline] [toucan2.query :as query] [toucan2.test :as test])) (deftest ^:parallel default-parse-args-test (are [args expected] (= expected ...
null
https://raw.githubusercontent.com/camsaul/toucan2/6d1e0df579c51a0bb128ca5586028d8b374c59be/test/toucan2/query_test.clj
clojure
(ns toucan2.query-test (:require [clojure.test :refer :all] [methodical.core :as m] [toucan2.model :as model] [toucan2.pipeline :as pipeline] [toucan2.query :as query] [toucan2.test :as test])) (deftest ^:parallel default-parse-args-test (are [args expected] (= expected ...
a2e87d34cf26db35f5a0fef86382fccd0eafd80944b3b42348dc988c64029313
na4zagin3/satyrographos
lint_prim.ml
open Core include Lint_problem module Location = Satyrographos.Location type location = | SatyristesModLoc of (string * string * (int * int) option) | FileLoc of Location.t | OpamLoc of string type level = [`Error | `Warning] [@@deriving equal] type diagnosis = { locs : location list; level : level; ...
null
https://raw.githubusercontent.com/na4zagin3/satyrographos/9dbccf05138510c977a67c859bbbb48755470c7f/src/command/lint_prim.ml
ocaml
open Core include Lint_problem module Location = Satyrographos.Location type location = | SatyristesModLoc of (string * string * (int * int) option) | FileLoc of Location.t | OpamLoc of string type level = [`Error | `Warning] [@@deriving equal] type diagnosis = { locs : location list; level : level; ...
ed2b1f52fcdf3b2a39f91aafe7d83d5e94a412554bd4967227a8c7bd96ff8364
maranget/hevea
version.mli
(***********************************************************************) (* *) (* HEVEA *) (* *) , projet PARA , INR...
null
https://raw.githubusercontent.com/maranget/hevea/226eac8c506f82a600d453492fbc1b9784dd865f/version.mli
ocaml
********************************************************************* HEVEA ...
, projet PARA , INRIA Rocquencourt Copyright 1998 Institut National de Recherche en Informatique et Automatique . Distributed only by permission . val version : string
80801f9a2db2d154c4910346c8c0471d946f09ac59a12a5b72810559962ad63d
sile/logi
logi_sink_set_sup.erl
2014 - 2016 < > %% @doc Supervisor for logi_sink_sup processes @private %% @end -module(logi_sink_set_sup). -behaviour(supervisor). %%---------------------------------------------------------------------------------------------------------------------- %% Exported API %%-------------------------------------...
null
https://raw.githubusercontent.com/sile/logi/1022fbc238a7d18765fe864a7174958142160ee8/src/logi_sink_set_sup.erl
erlang
@end ---------------------------------------------------------------------------------------------------------------------- Exported API ---------------------------------------------------------------------------------------------------------------------- -------------------------------------------------------------...
2014 - 2016 < > @doc Supervisor for logi_sink_sup processes @private -module(logi_sink_set_sup). -behaviour(supervisor). -export([start_link/0]). -export([start_child/3]). -export([stop_child/2]). -export([init/1]). -spec start_link() -> {ok, pid()} | {error, Reason::term()}. start_link() -> superviso...
4a5ba20277d72ef58e3f81149af77fc1ca3de88a6b08a263aef4fb5aa4cbf544
NorfairKing/sydtest
AroundCombinationSpec.hs
# LANGUAGE DataKinds # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # module Test.Syd.AroundCombinationSpec (spec) where import Control.Concurrent.STM import Control.Monad.IO.Class import Test.Syd spec :: Spec spec = sequential $ doNotRandomiseExecutionOrder $ do describe "aroundAll + aroundAllWith...
null
https://raw.githubusercontent.com/NorfairKing/sydtest/0fad471cee677a4018acbe1983385dfc9a1b49d2/sydtest/test/Test/Syd/AroundCombinationSpec.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # module Test.Syd.AroundCombinationSpec (spec) where import Control.Concurrent.STM import Control.Monad.IO.Class import Test.Syd spec :: Spec spec = sequential $ doNotRandomiseExecutionOrder $ do describe "aroundAll + aroundAllWith...
4b718162bca9dfae9362d688eb0b7e21ba4f5eaacba14c30110d987a9d1c3394
Helium4Haskell/helium
Guards7.hs
main :: [Int] -> () main [] = () main (1:xs) | False = ()
null
https://raw.githubusercontent.com/Helium4Haskell/helium/5928bff479e6f151b4ceb6c69bbc15d71e29eb47/test/staticwarnings/Guards7.hs
haskell
main :: [Int] -> () main [] = () main (1:xs) | False = ()
cdbbc049dbef397a07247c8090cfcaa24891666f44a2650817b6dcc9ba55e9c5
ScottBrooks/Erlcraft
mc_util.erl
-module(mc_util). -compile(export_all). write_packet(PacketID, Contents) -> BinaryData = encode_list(Contents), <<PacketID:8, BinaryData/binary>>. or_binaries(BinA, BinB) when size(BinA) =:= size(BinB) -> or_binaries(BinA, BinB, <<>>). or_binaries(<<>>, <<>>, Buffer) -> Buffer; or_binaries(BinA, Bin...
null
https://raw.githubusercontent.com/ScottBrooks/Erlcraft/ed336eb8da4d83e937687ce34feecb76b4128288/src/mc_util.erl
erlang
io:format("Bedrock: [~p, ~p, ~p]~n", [X, Y, Z]), io:format("Grass: [~p, ~p, ~p]~n", [X, Y, Z]), io:format("Air: [~p, ~p, ~p]~n", [X, Y, Z]),
-module(mc_util). -compile(export_all). write_packet(PacketID, Contents) -> BinaryData = encode_list(Contents), <<PacketID:8, BinaryData/binary>>. or_binaries(BinA, BinB) when size(BinA) =:= size(BinB) -> or_binaries(BinA, BinB, <<>>). or_binaries(<<>>, <<>>, Buffer) -> Buffer; or_binaries(BinA, Bin...
8a944d29dba74461f8c4bf11a0a3debc602a61cadbcff2c1ce0edd4a08d3129f
AbstractMachinesLab/caramel
builtin_attributes.ml
open Asttypes open Parsetree let string_of_cst = function | Pconst_string(s, _) -> Some s | _ -> None let string_of_payload = function | PStr[{pstr_desc=Pstr_eval({pexp_desc=Pexp_constant c},_)}] -> string_of_cst c | _ -> None let warning_scope = ref [] let warning_enter_scope () = warning_scope := ...
null
https://raw.githubusercontent.com/AbstractMachinesLab/caramel/7d4e505d6032e22a630d2e3bd7085b77d0efbb0c/vendor/ocaml-lsp-1.4.0/ocaml-lsp-server/vendor/merlin/src/ocaml/parsing/402/builtin_attributes.ml
ocaml
open Asttypes open Parsetree let string_of_cst = function | Pconst_string(s, _) -> Some s | _ -> None let string_of_payload = function | PStr[{pstr_desc=Pstr_eval({pexp_desc=Pexp_constant c},_)}] -> string_of_cst c | _ -> None let warning_scope = ref [] let warning_enter_scope () = warning_scope := ...
fcd672a7d0cd4e8ad438857ce189b732e24c8c7aa1ecda181c15bbf7343e99d2
Quid2/zm
String.hs
{-# LANGUAGE DeriveAnyClass #-} {-# LANGUAGE DeriveGeneric #-} module ZM.Type.String ( String(..) ) where import Control.DeepSeq import Flat import Data.Model import Prelude hiding ( String ) import ZM.Model ( ) data String ...
null
https://raw.githubusercontent.com/Quid2/zm/02c0514777a75ac054bfd6251edd884372faddea/src/ZM/Type/String.hs
haskell
# LANGUAGE DeriveAnyClass # # LANGUAGE DeriveGeneric #
module ZM.Type.String ( String(..) ) where import Control.DeepSeq import Flat import Data.Model import Prelude hiding ( String ) import ZM.Model ( ) data String = String [Char] deriving (Eq, Ord, Show, Generic, Flat, Mode...
19e7e3febef6020103c02eb1e5c62298f2e83ee06226d9d3dfb77f6722dd2104
haskell-tls/hs-certificate
Unix.hs
-- | -- Module : System.X509 -- License : BSD-style Maintainer : < > -- Stability : experimental -- Portability : unix only -- -- this module is portable to unix system where there is usually -- a /etc/ssl/certs with system X509 certificates. -- -- the path can be dynamically override using the enviro...
null
https://raw.githubusercontent.com/haskell-tls/hs-certificate/4a0a2ce292ea46c0c5f72e1d31eca2001079cdd2/x509-system/System/X509/Unix.hs
haskell
| Module : System.X509 License : BSD-style Stability : experimental Portability : unix only this module is portable to unix system where there is usually a /etc/ssl/certs with system X509 certificates. the path can be dynamically override using the environment variable defined by envPathOverride i...
Maintainer : < > module System.X509.Unix ( getSystemCertificateStore ) where import System.Environment (getEnv) import Data.X509.CertificateStore import Control.Applicative ((<$>)) import qualified Control.Exception as E import Data.Maybe (catMaybes) import Data.Monoid (mconcat) defaultSystemPaths ::...
b9afa242c60e83f9d19a224d21dd0fb9cd6a8efb922d6a85a312e69794dc9bc5
AccelerateHS/accelerate-examples
Config.hs
# LANGUAGE TemplateHaskell # module Config where import Data.Label import System.Console.GetOpt -- Configuration options -- data Config = Config deriving Show $(mkLabels [''Config]) defaults :: Config defaults = Config -- The set of available command line options -- options :: [OptDescr (Config -> Config)] op...
null
https://raw.githubusercontent.com/AccelerateHS/accelerate-examples/a973ee423b5eadda6ef2e2504d2383f625e49821/examples/kmeans/Config.hs
haskell
Configuration options The set of available command line options Command line decoration
# LANGUAGE TemplateHaskell # module Config where import Data.Label import System.Console.GetOpt data Config = Config deriving Show $(mkLabels [''Config]) defaults :: Config defaults = Config options :: [OptDescr (Config -> Config)] options = [] header :: [String] header = [ "accelerate-kmeans (c) [2014..2...
333d7ad658ed643f70ee1208e0812b3607924fb6252b741378a1812113650f9b
facebook/infer
cField_decl.ml
* Copyright ( c ) Facebook , Inc. and its affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the ...
null
https://raw.githubusercontent.com/facebook/infer/432243b21f4990c3071ba0b3ee2a472a215be1c6/infer/src/clang/cField_decl.ml
ocaml
* Utility module to retrieve fields of structs of classes Given a list of declarations in an interface returns a list of fields
* Copyright ( c ) Facebook , Inc. and its affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the ...
43d5238888d1394c7a958cb73c2ceb33b96e76d5123c35e61b0774e5fb9f5cc3
rd--/hsc3
oscN.help.hs
-- c.f . osc
null
https://raw.githubusercontent.com/rd--/hsc3/60cb422f0e2049f00b7e15076b2667b85ad8f638/Help/Ugen/oscN.help.hs
haskell
c.f . osc
1f39fe5297be4e7c3256290eb9d37ca2c3e3015598445303238140e6fc25d1b5
hercules-ci/hercules-ci-agent
AttributeEffectEventSpec.hs
module Hercules.API.Agent.Evaluate.EvaluateEvent.AttributeEffectEventSpec where import Data.Aeson (Value, eitherDecode, encode) import qualified Data.ByteString.Lazy as BL import qualified Data.Map as M import Hercules.API.Agent.Evaluate.EvaluateEvent.AttributeEffectEvent (AttributeEffectEvent (AttributeEffectEvent), ...
null
https://raw.githubusercontent.com/hercules-ci/hercules-ci-agent/be8142e7f38eba5e3805f21d5b6423ce7239e0f0/hercules-ci-api-agent/test/Hercules/API/Agent/Evaluate/EvaluateEvent/AttributeEffectEventSpec.hs
haskell
module Hercules.API.Agent.Evaluate.EvaluateEvent.AttributeEffectEventSpec where import Data.Aeson (Value, eitherDecode, encode) import qualified Data.ByteString.Lazy as BL import qualified Data.Map as M import Hercules.API.Agent.Evaluate.EvaluateEvent.AttributeEffectEvent (AttributeEffectEvent (AttributeEffectEvent), ...
549eb46ac38d9d0e7eb0434a255e36e82406a535ed666223e435943a9fd18034
wrengr/bytestring-trie
MatchOne.hs
{-# OPTIONS_GHC -Wall -fwarn-tabs #-} # LANGUAGE CPP , BangPatterns # ---------------------------------------------------------------- ~ 2022.02.12 -- | -- Module : Bench.MatchOne Copyright : 2008 - -2022 wren romano -- License : BSD-3-Clause -- Main...
null
https://raw.githubusercontent.com/wrengr/bytestring-trie/53e3b0e0eca0ef8980b155b4ad110835a78716e6/dev/Bench/MatchOne.hs
haskell
# OPTIONS_GHC -Wall -fwarn-tabs # -------------------------------------------------------------- | Module : Bench.MatchOne License : BSD-3-Clause Maintainer : Stability : provisional Portability : portable Benchmarking definitions for 'TI.match_' -----------------------------------------------...
# LANGUAGE CPP , BangPatterns # ~ 2022.02.12 Copyright : 2008 - -2022 wren romano module Main (main) where import qualified Data.Trie as T import qualified Data.Trie.Internal as TI import qualified Data.ByteString as S import Control....
a2743bfafd6734a9da9204e0994aa202c956d19c65ef123cb031590a1f1aba9e
Soostone/hs-d3
Scope.hs
------------------------------------------------------------------------------ | The ` Cursor ` is an abstraction used to track how D3.hs should render -- D3 parameters that are data dependent. It accomplishes this through left -- and right composition. ---------------------------------------------------------...
null
https://raw.githubusercontent.com/Soostone/hs-d3/fb319ba444e263d7bc9655436db2723115a01c46/src/Graphics/HSD3/D3/Scope.hs
haskell
---------------------------------------------------------------------------- D3 parameters that are data dependent. It accomplishes this through left and right composition. ---------------------------------------------------------------------------- # LANGUAGE QuasiQuotes # ------------------------...
| The ` Cursor ` is an abstraction used to track how D3.hs should render # LANGUAGE ExistentialQuantification # # LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # module Graphics.HSD3.D3.Scope where import Control.Lens import Data.Monoid import Language.Javascript.JMacro import Grap...
34a0a62630fce058eb593b73771cf5a615a966ab5af1ee0d275014d8dc7c0e49
hiratara/Haskell-Nyumon-Sample
chap07-samples-7-6-2.hs
{-# LANGUAGE OverloadedStrings, OverloadedLists #-} module Main(main) where import Data.Aeson import qualified Data.ByteString.Lazy.Char8 as B nameListValue :: Value nameListValue = Array [ object [ "coworkers" .= Array [ object [ "age" .= Number 20 , "name" .= String "Satoshi" ...
null
https://raw.githubusercontent.com/hiratara/Haskell-Nyumon-Sample/ac52b741e3b96722f6fc104cfa84078e39f7a241/chap07-samples/chap07-samples-7-6-2.hs
haskell
# LANGUAGE OverloadedStrings, OverloadedLists #
module Main(main) where import Data.Aeson import qualified Data.ByteString.Lazy.Char8 as B nameListValue :: Value nameListValue = Array [ object [ "coworkers" .= Array [ object [ "age" .= Number 20 , "name" .= String "Satoshi" ] , object [ "age" .= Number 23 ...
924b97aa0efc83cfade4600c7cd07bf18fefa341675037e34c0dd2d0dc0a55dc
aryx/fork-efuns
buffer_menu.mli
val menu: Efuns.action
null
https://raw.githubusercontent.com/aryx/fork-efuns/8f2f8f66879d45e26ecdca0033f9c92aec2b783d/major_modes/buffer_menu.mli
ocaml
val menu: Efuns.action
e1c968612a6ff446c276d10e8ff1f6af269ec3215dc5ba9113027dd8784c1464
typelead/intellij-eta
Project.hs
module FFI.Com.IntelliJ.OpenApi.Project ( Project ) where import FFI.Com.IntelliJ.OpenApi.Project.Project
null
https://raw.githubusercontent.com/typelead/intellij-eta/ee66d621aa0bfdf56d7d287279a9a54e89802cf9/plugin/src/main/eta/FFI/Com/IntelliJ/OpenApi/Project.hs
haskell
module FFI.Com.IntelliJ.OpenApi.Project ( Project ) where import FFI.Com.IntelliJ.OpenApi.Project.Project
954bf434a7aa3784fd0fbbb21921aba7ada0be63de347b142d18357c1899ac38
metabase/hawk
junit.clj
(ns mb.hawk.junit (:require [clojure.test :as t] [mb.hawk.junit.write :as write])) (defmulti ^:private handle-event!* {:arglists '([event])} :type) (defn handle-event! "Write JUnit output for a `clojure.test` event such as success or failure." [{test-var :var, :as event}] (let [test-var (or test-var...
null
https://raw.githubusercontent.com/metabase/hawk/47e3abf80d04d12f229aabffcf496f02cd9fffd5/src/mb/hawk/junit.clj
clojure
for unknown event types (e.g. `:clojure.test.check.clojure-test/trial`) just ignore them. some `:error` events happen because of errors in fixture initialization and don't have associated vars/namespaces
(ns mb.hawk.junit (:require [clojure.test :as t] [mb.hawk.junit.write :as write])) (defmulti ^:private handle-event!* {:arglists '([event])} :type) (defn handle-event! "Write JUnit output for a `clojure.test` event such as success or failure." [{test-var :var, :as event}] (let [test-var (or test-var...
4ea5ba30377fea20593b823472aa967eee923e384caa2603270e1a46c0920439
craigfe/ppx_irmin
unsupported_type_open.ml
type t = .. [@@deriving irmin]
null
https://raw.githubusercontent.com/craigfe/ppx_irmin/06d764c6f1049131f1c4c7a3fbc59ff516c9d679/test/deriver/errors/unsupported_type_open.ml
ocaml
type t = .. [@@deriving irmin]
a7af1652b54493117a50ee08aba1a906e139de2713c251a15687bcc49f844dee
lmj/lparallel
defun.lisp
Copyright ( c ) 2011 - 2012 , . 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/lmj/lparallel/9c11f40018155a472c540b63684049acc9b36e15/src/util/defun.lisp
lisp
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. * Redistributions in binary...
Copyright ( c ) 2011 - 2012 , . All rights reserved . " AS IS " AND ANY EXPRESS OR IMPLIED WARRANTIES , INCLUDING , BUT NOT HOLDER OR FOR ANY DIRECT , INDIRECT , INCIDENTAL , SPECIAL , EXEMPLARY , OR CONSEQUENTIAL DAMAGES ( INCLUDING , BUT NOT THEORY OF LIABILITY , WHETHER IN CONTRACT , STRICT LIABILITY...
7d5e620bcc9c80a561e18f291e25a2e0dd0b8295aaeae915506b8fca73bf3271
ghcjs/ghcjs-boot
hSetBuffering002.hs
import System.IO main = hSetBuffering stdin NoBuffering >> hSetBuffering stdout NoBuffering >> interact id
null
https://raw.githubusercontent.com/ghcjs/ghcjs-boot/8c549931da27ba9e607f77195208ec156c840c8a/boot/base/tests/IO/hSetBuffering002.hs
haskell
import System.IO main = hSetBuffering stdin NoBuffering >> hSetBuffering stdout NoBuffering >> interact id
ab69c67e879b78ac06824f0852b5f60eba2f42857b1f1a0b13d73857cf05ed87
yminer/libml
initVisitor.mli
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * [ LibML - Machine Learning Library ] Copyright ( C ) 2002 - 2003 LAGACHERIE This program is free software ; you can redistribute it and/or modify it under the te...
null
https://raw.githubusercontent.com/yminer/libml/1475dd87c2c16983366fab62124e8bbfbbf2161b/src/nn/init/initVisitor.mli
ocaml
* The generic visit method.
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * [ LibML - Machine Learning Library ] Copyright ( C ) 2002 - 2003 LAGACHERIE This program is free software ; you can redistribute it and/or modify it under the te...
f2d8ac0713c93e7253896d2ddbcd8e662d23147b5c3d683d06bcfdc5650dda70
Ericson2314/lighthouse
Class.hs
----------------------------------------------------------------------------- -- | Module : Control . Monad . State . Class Copyright : ( c ) 2001 , ( c ) Oregon Graduate Institute of Science and Technology , 2001 -- License : BSD-style (see the file libraries/base/LICENSE) -- -...
null
https://raw.githubusercontent.com/Ericson2314/lighthouse/210078b846ebd6c43b89b5f0f735362a01a9af02/ghc-6.8.2/libraries/mtl/Control/Monad/State/Class.hs
haskell
--------------------------------------------------------------------------- | License : BSD-style (see the file libraries/base/LICENSE) Maintainer : Stability : experimental Portability : non-portable (multi-param classes, functional dependencies) This module is inspired by the paper /Fu...
Module : Control . Monad . State . Class Copyright : ( c ) 2001 , ( c ) Oregon Graduate Institute of Science and Technology , 2001 MonadState class . ( < /~mpj/ > ) Advanced School of Functional Programming , 1995 . module Control.Monad.State.Class ( Mo...
3e66b018d4a5be15144840694e213c9d2ba008901eceaeabb84587e3833569a5
metaocaml/ber-metaocaml
unused_types.ml
(* TEST flags = " -w A -strict-sequence " * expect *) module Unused : sig end = struct type unused = int end ;; [%%expect {| Line 3, characters 2-19: 3 | type unused = int ^^^^^^^^^^^^^^^^^ Warning 34: unused type unused. module Unused : sig end |}] module Unused_nonrec : sig end = struct type nonre...
null
https://raw.githubusercontent.com/metaocaml/ber-metaocaml/4992d1f87fc08ccb958817926cf9d1d739caf3a2/testsuite/tests/typing-warnings/unused_types.ml
ocaml
TEST flags = " -w A -strict-sequence " * expect
module Unused : sig end = struct type unused = int end ;; [%%expect {| Line 3, characters 2-19: 3 | type unused = int ^^^^^^^^^^^^^^^^^ Warning 34: unused type unused. module Unused : sig end |}] module Unused_nonrec : sig end = struct type nonrec used = int type nonrec unused = used end ;; [%%expect {|...
1ef11836eadde984e04c6705b849ebcec3eb7ddb00d014098db5ccdd0fb9f336
BorjaEst/enn
nn_sup.erl
%%%------------------------------------------------------------------- %%% @doc %%% %%% @end -module(nn_sup). -behaviour(supervisor). %% API -export([id/1, start_link/1, start_neuron/2]). -export_type([id/0]). %% Supervisor callbacks -export([init/1]). -type id() :: {nn_sup, Ref :: reference()}. -define(SPECS_NEURO...
null
https://raw.githubusercontent.com/BorjaEst/enn/fa6c18913f3fb3e9391234c5e90cbcb432355bc0/src/nn_sup.erl
erlang
------------------------------------------------------------------- @doc @end API Supervisor callbacks =================================================================== API functions =================================================================== -------------------------------------------------------------...
-module(nn_sup). -behaviour(supervisor). -export([id/1, start_link/1, start_neuron/2]). -export_type([id/0]). -export([init/1]). -type id() :: {nn_sup, Ref :: reference()}. -define(SPECS_NEURON(Neuron_id), #{ id => Neuron_id, start => {neuron, start_link, [Neuron_id]}, restart => transient, ...
1443ad852e21c1f84c4aca28535f7fba55286764b5295a47bbd92d1a0cb776b8
Elzair/nazghul
bole.scm
;;---------------------------------------------------------------------------- ;; Map ;;---------------------------------------------------------------------------- (kern-mk-map 'm_bole 48 39 pal_expanded (list "^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ~6 ^a ^^ ^c ~6 ^a ^^ ^^ ~6 || || || || || || || || || ^^ ^^ ^^ ^...
null
https://raw.githubusercontent.com/Elzair/nazghul/8f3a45ed6289cd9f469c4ff618d39366f2fbc1d8/worlds/haxima-1.002/bole.scm
scheme
---------------------------------------------------------------------------- Map ---------------------------------------------------------------------------- ---------------------------------------------------------------------------- Characters ------------------------------------------------------------------------...
(kern-mk-map 'm_bole 48 39 pal_expanded (list "^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ~6 ^a ^^ ^c ~6 ^a ^^ ^^ ~6 || || || || || || || || || ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ " "^^ ^^ ^^ ^^ ^c t7 ^^ ^^ ^^ ^^ ^^ ^^ ^^ ~6 |B || |% ~6 |# |% ^e ~6 || || || || || || || || || ^a ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^...
a1b2881ae8f1e06125a8501b1461b5740ec6c1a5efcdfc8a409a0cb79b4a05f8
theodormoroianu/SecondYearCourses
HaskellChurch_20210415162336.hs
{-# LANGUAGE RankNTypes #-} module HaskellChurch where A boolean is any way to choose between two alternatives newtype CBool = CBool {cIf :: forall t. t -> t -> t} An instance to show as regular Booleans instance Show CBool where show b = show $ cIf b True False The boolean constant true always chooses the ...
null
https://raw.githubusercontent.com/theodormoroianu/SecondYearCourses/5e359e6a7cf588a527d27209bf53b4ce6b8d5e83/FLP/Laboratoare/Lab%209/.history/HaskellChurch_20210415162336.hs
haskell
# LANGUAGE RankNTypes # The boolean negation switches the alternatives The boolean conjunction can be built as a conditional The boolean disjunction can be built as a conditional a pair is a way to compute something based on the values contained within the pair. a function to be applied on the values, it will apply i...
module HaskellChurch where A boolean is any way to choose between two alternatives newtype CBool = CBool {cIf :: forall t. t -> t -> t} An instance to show as regular Booleans instance Show CBool where show b = show $ cIf b True False The boolean constant true always chooses the first alternative cTrue :: C...
9f6aa1405620f1c8b644fe4fcea902cf34ba3db0afadaac95c1fb9340207dcbb
simonmichael/hledger
Import.hs
module Hledger.Web.Import ( module Import ) where import Prelude as Import hiding (head, init, last, readFile, tail, writeFile) import Yesod as Import hiding (Route (..), parseTime) import Control.Monad ...
null
https://raw.githubusercontent.com/simonmichael/hledger/33d15df879b43e69cb3e2f35a0a44c1a88b1f7a7/hledger-web/Hledger/Web/Import.hs
haskell
module Hledger.Web.Import ( module Import ) where import Prelude as Import hiding (head, init, last, readFile, tail, writeFile) import Yesod as Import hiding (Route (..), parseTime) import Control.Monad ...
4b858cf37294774f53438bf6a40c53229a5c38f4eef8d3ebfa5f110cac55074d
rabbitmq/looking_glass
looking_glass_app.erl
%% Copyright (c) 2017-Present Pivotal Software, Inc. All rights reserved. %% This package , Looking , is double - licensed under the Mozilla Public License 1.1 ( " MPL " ) and the Apache License version 2 ( " ASL " ) . For the MPL , please see LICENSE - MPL - RabbitMQ . For the ASL , %% please see LICENSE-APACH...
null
https://raw.githubusercontent.com/rabbitmq/looking_glass/0ae891a8cee16603cdead0caf2d4c0b0800b22c9/src/looking_glass_app.erl
erlang
Copyright (c) 2017-Present Pivotal Software, Inc. All rights reserved. please see LICENSE-APACHE2. either express or implied. See the LICENSE file for specific language governing rights and limitations of this software. If you have any questions regarding licensing, please contact us at .
This package , Looking , is double - licensed under the Mozilla Public License 1.1 ( " MPL " ) and the Apache License version 2 ( " ASL " ) . For the MPL , please see LICENSE - MPL - RabbitMQ . For the ASL , This software is distributed on an " AS IS " basis , WITHOUT WARRANTY OF ANY KIND , -module(looking_gl...
2ed0c2f461539b0e21865a27b3e256619fed43fe2d8be06087365f06febc7dae
rtrusso/scp
badsrlo.scm
(define x (make-string 3 #\a)) (display (string-ref x -1)) (newline)
null
https://raw.githubusercontent.com/rtrusso/scp/2051e76df14bd36aef81aba519ffafa62b260f5c/src/tests/badsrlo.scm
scheme
(define x (make-string 3 #\a)) (display (string-ref x -1)) (newline)
d05dd1e38d1ded472ff3a55c56862ac5606993469e0d8943b10467a00c8e448b
tomhanika/conexp-clj
latex.clj
;; Copyright ⓒ the conexp-clj developers; all rights reserved. ;; The use and distribution terms for this software are covered by the Eclipse Public License 1.0 ( -1.0.php ) ;; which can be found in the file LICENSE at the root of this distribution. ;; By using this software in any fashion, you are agreeing to be bou...
null
https://raw.githubusercontent.com/tomhanika/conexp-clj/cd6b02cb5bb63d813cb9fcc78b1c0ce11992b51e/src/main/clojure/conexp/io/latex.clj
clojure
Copyright ⓒ the conexp-clj developers; all rights reserved. The use and distribution terms for this software are covered by the which can be found in the file LICENSE at the root of this distribution. By using this software in any fashion, you are agreeing to be bound by the terms of this license. You must not re...
Eclipse Public License 1.0 ( -1.0.php ) (ns conexp.io.latex "Provides functionality to represent conexp-clj datastructures as latex code." (:use conexp.base [conexp.fca.contexts :only (objects attributes incidence)] conexp.fca.lattices conexp.fca.many-valued-contexts [conexp.layou...
523b3ea6ccf5be45c95011846af7e5a08bd5ca706d6f6719acc3ee0ad97786d6
exoscale/exopaste
store.clj
(ns exopaste.store (:require [com.stuartsierra.component :as component])) (defn add-new-paste "Insert a new paste in the database, then return its UUID." [store content] (let [uuid (.toString (java.util.UUID/randomUUID))] (swap! (:data store) assoc (keyword uuid) {:content content}) uuid)) (defn get-p...
null
https://raw.githubusercontent.com/exoscale/exopaste/be1ee7a5cc2e87124b6588076ea0946f5f52f560/src/exopaste/store.clj
clojure
(ns exopaste.store (:require [com.stuartsierra.component :as component])) (defn add-new-paste "Insert a new paste in the database, then return its UUID." [store content] (let [uuid (.toString (java.util.UUID/randomUUID))] (swap! (:data store) assoc (keyword uuid) {:content content}) uuid)) (defn get-p...
ef4cb13216516eb93934f47e2299f47142e8ee246191e479700c9df5942d1574
mhallin/graphql_ppx
graphql_ast.ml
open Source_pos type type_ref = | Tr_named of string spanning | Tr_list of type_ref spanning | Tr_non_null_named of string spanning | Tr_non_null_list of type_ref spanning type input_value = | Iv_null | Iv_int of int | Iv_float of float | Iv_string of string | Iv_boolean of bool | Iv_enum of strin...
null
https://raw.githubusercontent.com/mhallin/graphql_ppx/5796b3759bdf0d29112f48e43a2f0623f7466e8a/src/base/graphql_ast.ml
ocaml
open Source_pos type type_ref = | Tr_named of string spanning | Tr_list of type_ref spanning | Tr_non_null_named of string spanning | Tr_non_null_list of type_ref spanning type input_value = | Iv_null | Iv_int of int | Iv_float of float | Iv_string of string | Iv_boolean of bool | Iv_enum of strin...
3ca4ec66f6e5bdbc6b2baf1c213ec59f0bc9a2a1f5b64c705898f7566c4f41c2
iamFIREcracker/adventofcode
day11.lisp
(defpackage :aoc/2019/11 #.cl-user::*aoc-use*) (in-package :aoc/2019/11) (defstruct (robot (:constructor make-robot%)) program in out direction) (defun make-robot (program) (let* ((in (make-queue)) (out (make-queue)) (program (intcode:make-program (copy-hash-table (intcode:program-memory p...
null
https://raw.githubusercontent.com/iamFIREcracker/adventofcode/c395df5e15657f0b9be6ec555e68dc777b0eb7ab/src/2019/day11.lisp
lisp
add a leading new-line, to make testing easier/nicer
(defpackage :aoc/2019/11 #.cl-user::*aoc-use*) (in-package :aoc/2019/11) (defstruct (robot (:constructor make-robot%)) program in out direction) (defun make-robot (program) (let* ((in (make-queue)) (out (make-queue)) (program (intcode:make-program (copy-hash-table (intcode:program-memory p...
c383ff23f38b7877e275de8357fb689297840371d04b1c361ff7405b4954d0d5
mk270/archipelago
digraph.mli
Archipelago , a multi - user dungeon ( MUD ) server , by ( C ) 2009 - 2012 This programme is free software ; you may redistribute and/or modify it under the terms of the GNU Affero General Public Licence as published by the Free Software Foundation , either version 3 of said Licence , or ( ...
null
https://raw.githubusercontent.com/mk270/archipelago/4241bdc994da6d846637bcc079051405ee905c9b/src/model/digraph.mli
ocaml
Archipelago , a multi - user dungeon ( MUD ) server , by ( C ) 2009 - 2012 This programme is free software ; you may redistribute and/or modify it under the terms of the GNU Affero General Public Licence as published by the Free Software Foundation , either version 3 of said Licence , or ( ...
5491e3f5b5c58ef802ec71d27cadcbdfca8e6faa5a498b3348ab5d4cc89a8b3e
jrm-code-project/LISP-Machine
page-fault.lisp
-*- Mode : LISP ; Base:8 ; : ZL -*- * * ( c ) Copyright 1983 Lisp Machine Inc * * Notes for explorer gc - pace Nov 20 , 1985 ;;; ;;; The per page volatility bits for the explorer are in L2-MAP-CONTROL<12.:11.>, ;;; but on the lambda its L2-MAP-CONTROL<1:0>. Therefore, where ever we write ;;; L2-MAP-CONTROL...
null
https://raw.githubusercontent.com/jrm-code-project/LISP-Machine/0a448d27f40761fafabe5775ffc550637be537b2/lambda/pace/page-fault.lisp
lisp
Base:8 ; : ZL -*- The per page volatility bits for the explorer are in L2-MAP-CONTROL<12.:11.>, but on the lambda its L2-MAP-CONTROL<1:0>. Therefore, where ever we write L2-MAP-CONTROL, put in another instruction for the explorer to copy This bit needs to be correctly set when regions are allocated or flipped....
* * ( c ) Copyright 1983 Lisp Machine Inc * * Notes for explorer gc - pace Nov 20 , 1985 the bits to the other field . -done RG 1/20/86 Secondly , the OLD - SPACE bit on the explorer ( and on the lambda AVP ) is in L1 - MAP<10 . > 1 means newspace , 0 means oldspace . There is code at INIMAP1 t...
e89f2c92ca64b0191424ba93ab0f26361644c0663a7625b1fa4b65b585c639b2
rescript-lang/rescript-compiler
ppx_driver.ml
Copyright ( C ) 2019- , Authors of ReScript * * This program is free software : you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation , either version 3 of the License , or * ( at your option ) any later vers...
null
https://raw.githubusercontent.com/rescript-lang/rescript-compiler/bae82e1ddd265e5c8886ce1a6527e031d95416ed/jscomp/frontend/ppx_driver.ml
ocaml
Copyright ( C ) 2019- , Authors of ReScript * * This program is free software : you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation , either version 3 of the License , or * ( at your option ) any later vers...
72370ff96c0088a3420ec6bd9b610f624ecb1dd88ffd26a26c26d2c3b83c661e
oscarh/gen_httpd
http_client.erl
-module(http_client). -export([ connect/2, connect/3, format_request/4, format_request/5, format_headers/1, receive_response/1, receive_response/2, format_chunk/1 ]). connect(Port, Mod) -> connect(Port, Mod, []). connect(Port, Mod, Opts) -> Mod:connect({127,0,0,1}, Port, [{active, false}, bi...
null
https://raw.githubusercontent.com/oscarh/gen_httpd/5b48e33d8fac30c70e2d89d74c56e057d570064e/test/http_client.erl
erlang
-module(http_client). -export([ connect/2, connect/3, format_request/4, format_request/5, format_headers/1, receive_response/1, receive_response/2, format_chunk/1 ]). connect(Port, Mod) -> connect(Port, Mod, []). connect(Port, Mod, Opts) -> Mod:connect({127,0,0,1}, Port, [{active, false}, bi...
4243c954fd04a7cdf5a210992d7b2a6612b9fd92203e5a890cc485c324ed1911
dharrigan/startrek-clip
actuator.clj
(ns startrek.api.general.actuator {:author "David Harrigan"} (:require [startrek.api.general.metrics :as metrics] [startrek.components.database.interface :as db])) (set! *warn-on-reflection* true) (def ok 200) (defn ^:private database-health-check [app-config] (if (db/health-check app-config) {:db ...
null
https://raw.githubusercontent.com/dharrigan/startrek-clip/7383527b88c78ba136911c91b1dfc74e73239c1f/src/startrek/api/general/actuator.clj
clojure
(ns startrek.api.general.actuator {:author "David Harrigan"} (:require [startrek.api.general.metrics :as metrics] [startrek.components.database.interface :as db])) (set! *warn-on-reflection* true) (def ok 200) (defn ^:private database-health-check [app-config] (if (db/health-check app-config) {:db ...
146346aed5562da1d1b1727fbb2d486db0e6c6196b2bfff00672543896bd909d
Stratus3D/programming_erlang_exercises
math_functions.erl
-module(math_functions). -export([even/1, odd/1, filter/2]). even(Number) -> % Use `rem` to check if the remainder is 0 % if it is return true, otherwise false 0 =:= Number rem 2. odd(Number) -> Use ` rem ` to check if the remainder is 1 % if it is return true, otherwise false % (for odd number...
null
https://raw.githubusercontent.com/Stratus3D/programming_erlang_exercises/e4fd01024812059d338facc20f551e7dff4dac7e/chapter_4/exercise_6/math_functions.erl
erlang
Use `rem` to check if the remainder is 0 if it is return true, otherwise false if it is return true, otherwise false (for odd numbers the remainder of then reverse the resulting list, as If there are no more items in the list return the result If another item still exists in the list Apply `Fun` to it and chec...
-module(math_functions). -export([even/1, odd/1, filter/2]). even(Number) -> 0 =:= Number rem 2. odd(Number) -> Use ` rem ` to check if the remainder is 1 division by 2 will always be 1 ) 1 =:= Number rem 2. filter(Fun, List) -> Invoke filter/3 , which does the real work filter/3 returns a list in r...
44798987f6bf4ac493ad3527b5c15ed3d5ade995b98ea32cc2f7c00a786e296a
snmsts/cserial-port
ffi-types-unix.lisp
(in-package :cserial-port) (include "sys/ioctl.h") (include "termios.h") (constant (B0 "B0")) (constant (B50 "B50")) (constant (B75 "B75")) (constant (B110 "B110")) (constant (B134 "B134")) (constant (B150 "B150")) (constant (B200 "B200")) (constant (B300 "B300")) (constant (B600 "B600")) (constant (B1200 "B1200")) (...
null
https://raw.githubusercontent.com/snmsts/cserial-port/2dc21ba4d6650fe766aea4f3d1d9b99a25ae1c24/src/ffi-types-unix.lisp
lisp
c_oflag c_lflag c_cc tcsetattr optional_actions
(in-package :cserial-port) (include "sys/ioctl.h") (include "termios.h") (constant (B0 "B0")) (constant (B50 "B50")) (constant (B75 "B75")) (constant (B110 "B110")) (constant (B134 "B134")) (constant (B150 "B150")) (constant (B200 "B200")) (constant (B300 "B300")) (constant (B600 "B600")) (constant (B1200 "B1200")) (...
87a0c1b61bc3d25542fb00b68a9c733a6e0b19d00c6d7ab12ae761409d9cbb36
haskell/haskell-language-server
PunMany.hs
data Many = Hello { world :: String } | Goodbye { a :: Int, b :: Bool, c :: Many } test :: Many -> Many test x = _
null
https://raw.githubusercontent.com/haskell/haskell-language-server/f3ad27ba1634871b2240b8cd7de9f31b91a2e502/plugins/hls-tactics-plugin/new/test/golden/PunMany.hs
haskell
data Many = Hello { world :: String } | Goodbye { a :: Int, b :: Bool, c :: Many } test :: Many -> Many test x = _
ecc9fd904d6bcc678ff8fa7429d82cec0fef6e05cc31339b56e73224df1272d6
beamparticle/beamparticle
beamparticle_erlparser.erl
%%% %CopyrightBegin% %%% Copyright < > 2017 . All Rights Reserved . %%% Licensed under the Apache License , Version 2.0 ( the " License " ) ; %%% you may not use this file except in compliance with the License. %%% You may obtain a copy of the License at %%% %%% -2.0 %%% %%% Unless required by applicable l...
null
https://raw.githubusercontent.com/beamparticle/beamparticle/65dcea1569d06b331b08cd9f8018ece4b176b690/src/beamparticle_erlparser.erl
erlang
%CopyrightBegin% you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific lang...
Copyright < > 2017 . All Rights Reserved . Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(beamparticle_erlparser). -include("beamparticle_constants.hrl"). -export([ extract_config/1, detect_language...
d60a5fee9d3a0136eb76b256370fe72e2c3420ea9eace6f8dcf633b59ce9561f
wavewave/fficxx
Gen.hs
{-# LANGUAGE OverloadedStrings #-} module Main where import qualified Data.HashMap.Strict as HM -- import qualified Data.HashMap.Strict as HM (fromList) import Data.Monoid (mempty) -- import FFICXX.Generate.Builder import FFICXX.Generate.Builder (simpleBuilder) import FFICXX.Generate.Code.Primitive import FFICXX.Gen...
null
https://raw.githubusercontent.com/wavewave/fficxx/489efb1d8dce9731133725b0adcc945c69944b6e/fficxx-multipkg-test/template-member/Gen.hs
haskell
# LANGUAGE OverloadedStrings # ------------------------------------------------------------------- ------------------------------------------------------------------- ------------------------------------------------------------------- tmf-test -------------------------------------------------------------------
module Main where import qualified Data.HashMap.Strict as HM import qualified Data.HashMap.Strict as HM (fromList) import Data.Monoid (mempty) import FFICXX.Generate.Builder import FFICXX.Generate.Builder (simpleBuilder) import FFICXX.Generate.Code.Primitive import FFICXX.Generate.Code.Primitive ( bool_, charp...
87d684df0d96aed5d94e740c3e031518960268bba868ff314cfdbf5d4b74f80b
haskell-opengl/OpenGLRaw
Interlace.hs
# LANGUAGE PatternSynonyms # -------------------------------------------------------------------------------- -- | -- Module : Graphics.GL.SGIX.Interlace Copyright : ( c ) 2019 -- License : BSD3 -- Maintainer : < > -- Stability : stable -- Portability : portable -- ---------------------...
null
https://raw.githubusercontent.com/haskell-opengl/OpenGLRaw/57e50c9d28dfa62d6a87ae9b561af28f64ce32a0/src/Graphics/GL/SGIX/Interlace.hs
haskell
------------------------------------------------------------------------------ | Module : Graphics.GL.SGIX.Interlace License : BSD3 Stability : stable Portability : portable ------------------------------------------------------------------------------ * Extension Support * Enums
# LANGUAGE PatternSynonyms # Copyright : ( c ) 2019 Maintainer : < > module Graphics.GL.SGIX.Interlace ( glGetSGIXInterlace, gl_SGIX_interlace, pattern GL_INTERLACE_SGIX ) where import Graphics.GL.ExtensionPredicates import Graphics.GL.Tokens
b6089c0edd2162cf4190fc3100af9ed3c3466279c24a69a8725d17a74357e1ed
oliyh/martian
interceptors_test.cljc
(ns martian.interceptors-test (:require [martian.interceptors :as i] [martian.encoders :as encoders] [tripod.context :as tc] [schema.core :as s] [schema-tools.core :as st] #?(:clj [clojure.test :refer [deftest is testing]] :cljs [cljs.test :re...
null
https://raw.githubusercontent.com/oliyh/martian/c20d3fad47709ecfc0493e2fb607d5b56ea3193d/core/test/martian/interceptors_test.cljc
clojure
(ns martian.interceptors-test (:require [martian.interceptors :as i] [martian.encoders :as encoders] [tripod.context :as tc] [schema.core :as s] [schema-tools.core :as st] #?(:clj [clojure.test :refer [deftest is testing]] :cljs [cljs.test :re...
11c7c61f8726d07353116ba2224c43646359fba9ef09ddc8cb829c2f41070124
tanders/cluster-engine
8b.lisp
(in-package cluster-engine) (setf *random-state* (make-random-state t)) (print (cluster-engine::ClusterEngine 35 t nil (append (cluster-engine::R-mel-interval-one-voice '(0 1) :normal :normal := 1/16 :member '(1 2)) (cluster-engine::R-mel-interval-one-voice '(0 1) :normal :normal := 1/4 :member '(1 2 3 4 5 1...
null
https://raw.githubusercontent.com/tanders/cluster-engine/064ad4fd107f8d9a3dfcaf260524c2ab034c6d3f/test_files/8b.lisp
lisp
(in-package cluster-engine) (setf *random-state* (make-random-state t)) (print (cluster-engine::ClusterEngine 35 t nil (append (cluster-engine::R-mel-interval-one-voice '(0 1) :normal :normal := 1/16 :member '(1 2)) (cluster-engine::R-mel-interval-one-voice '(0 1) :normal :normal := 1/4 :member '(1 2 3 4 5 1...
0c9b6cb81188b149dc49f2bf862742d4ce7da80250b424d4ca5c733d57d2d054
heraldry/heraldicon
news.cljs
(ns heraldicon.frontend.news (:require [heraldicon.frontend.title :as title] [heraldicon.static :as static] [re-frame.core :as rf])) (defn- release-image [img-src] (let [src (static/static-url img-src)] [:a {:href src :target "_blank"} [:img {:style {:width "100%"} :src src ...
null
https://raw.githubusercontent.com/heraldry/heraldicon/0e72e14efdc6dc7f1aa059c4b10e49962cdf293c/src/heraldicon/frontend/news.cljs
clojure
(ns heraldicon.frontend.news (:require [heraldicon.frontend.title :as title] [heraldicon.static :as static] [re-frame.core :as rf])) (defn- release-image [img-src] (let [src (static/static-url img-src)] [:a {:href src :target "_blank"} [:img {:style {:width "100%"} :src src ...
12a7fc4af5e480bde2e5f1da87a9dd5126722ea265ee25ac57f2abfb3ccdfd75
MyDataFlow/ttalk-server
ranch_conns_sup.erl
Copyright ( c ) 2011 - 2014 , < > %% %% 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/MyDataFlow/ttalk-server/07a60d5d74cd86aedd1f19c922d9d3abf2ebf28d/deps/ranch/src/ranch_conns_sup.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 ) 2011 - 2014 , < > 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_conns_sup). -export([start_link/6]). -...
330d846e4cc6ed52f305409841c17b6e9c492ad0e2d09b5f8c1d58534908b84c
yakaz/yamerl
dos_newlines.erl
-module('dos_newlines'). -include_lib("eunit/include/eunit.hrl"). -define(FILENAME, "test/parsing/" ?MODULE_STRING ".yaml"). single_test_() -> ?_assertMatch( {yamerl_parser, {file,?FILENAME}, [{io_blocksize, 1}], <<>>, 70, true, [], 0, 71, ...
null
https://raw.githubusercontent.com/yakaz/yamerl/0032607a7b27fa2b548fc9a02d7ae6b53469c0c5/test/parsing/dos_newlines.erl
erlang
-module('dos_newlines'). -include_lib("eunit/include/eunit.hrl"). -define(FILENAME, "test/parsing/" ?MODULE_STRING ".yaml"). single_test_() -> ?_assertMatch( {yamerl_parser, {file,?FILENAME}, [{io_blocksize, 1}], <<>>, 70, true, [], 0, 71, ...
b6bdad584985bb735d32b2578b416d1e262e8ea78c88fa3d4f16a84dd31e3a08
mhkoji/Senn
ex-dict.lisp
(defpackage :hachee.kkc.impl.mirror.ex-dict (:use :cl) (:export :entry-form :entry-cost :make-entry :list-entries :make-ex-dict)) (in-package :hachee.kkc.impl.mirror.ex-dict) (defstruct ex-dict hash) (defstruct entry form cost) (defun list-entries (dict pron) (ge...
null
https://raw.githubusercontent.com/mhkoji/Senn/0701d380f437aa4b48e2fba89bcd3d25587e4d0b/hachee/src/kkc/impl/mirror/ex-dict.lisp
lisp
(defpackage :hachee.kkc.impl.mirror.ex-dict (:use :cl) (:export :entry-form :entry-cost :make-entry :list-entries :make-ex-dict)) (in-package :hachee.kkc.impl.mirror.ex-dict) (defstruct ex-dict hash) (defstruct entry form cost) (defun list-entries (dict pron) (ge...
623defc9015918bb6c8d6f660944166de9f8d510e0b3375e35a51604193966c3
UBTECH-Walker/WalkerSimulationFor2020WAIC
msg_controler_joint.lisp
; Auto-generated. Do not edit! (cl:in-package cruiser_msgs-msg) ;//! \htmlinclude msg_controler_joint.msg.html (cl:defclass <msg_controler_joint> (roslisp-msg-protocol:ros-message) ((header :reader header :initarg :header :type std_msgs-msg:Header :initform (cl:make-instance 'std_msgs-msg:Header)...
null
https://raw.githubusercontent.com/UBTECH-Walker/WalkerSimulationFor2020WAIC/7cdb21dabb8423994ba3f6021bc7934290d5faa9/walker_WAIC_16.04_v1.2_20200616/walker_install/share/common-lisp/ros/cruiser_msgs/msg/msg_controler_joint.lisp
lisp
Auto-generated. Do not edit! //! \htmlinclude msg_controler_joint.msg.html
(cl:in-package cruiser_msgs-msg) (cl:defclass <msg_controler_joint> (roslisp-msg-protocol:ros-message) ((header :reader header :initarg :header :type std_msgs-msg:Header :initform (cl:make-instance 'std_msgs-msg:Header)) (datapacket :reader datapacket :initarg :datapacket :type cl:...
81855ebe1c3f9582e220e1321fc42ae4f9855ab9cf72cb861080bb158e087cdf
old-reliable/steamroller
steamroller_formatter_test.erl
-module(steamroller_formatter_test). -include_lib("eunit/include/eunit.hrl"). -define(FILE_DIR, "./test/steamroller_formatter/"). basic_boilerplate_test_() -> Expect = {ok, <<"-module(test).\n\n-export([init/1]).\n">>}, [ ?_assertEqual( Expect, steamroller_formatter:test_format(<<"-module(test).\...
null
https://raw.githubusercontent.com/old-reliable/steamroller/ebe4b5411a74dfda0a40304107464dba5ff109ae/test/steamroller_formatter_test.erl
erlang
-module(steamroller_formatter_test). -include_lib("eunit/include/eunit.hrl"). -define(FILE_DIR, "./test/steamroller_formatter/"). basic_boilerplate_test_() -> Expect = {ok, <<"-module(test).\n\n-export([init/1]).\n">>}, [ ?_assertEqual( Expect, steamroller_formatter:test_format(<<"-module(test).\...
a1b44969b12396c93f09b284104ee64a34efa3182a5080e427592470975e1c37
armedbear/abcl
customizations-default.lisp
;;; Copy this file to "customizations.lisp" ;;; User customizations for the build. ;;; This file is LOADed by INITIALIZE-BUILD (in build-abcl.lisp). ;;; The variable *PLATFORM-IS-WINDOWS* should be true on Windows platforms. You ;;; can, of course, substitute your own test for this in the code below, or add a sect...
null
https://raw.githubusercontent.com/armedbear/abcl/36a4b5994227d768882ff6458b3df9f79caac664/contrib/abcl-build/build/customizations-default.lisp
lisp
Copy this file to "customizations.lisp" User customizations for the build. This file is LOADed by INITIALIZE-BUILD (in build-abcl.lisp). The variable *PLATFORM-IS-WINDOWS* should be true on Windows platforms. You can, of course, substitute your own test for this in the code below, or add comment out settings that...
a section for OS X , or Solaris , or whatever ... You MUST set * JDK * to the location of the you want to use . Remove or You do n't really need to specify anything but * JDK * . * - COMPILER * and * JAR * default to javac and jar , respectively , from the configured . Directories should be specified...
e6d16869e8cb680f27502138da3126f61b918f4f6694c72bbe446625a0e8ae90
b0-system/b0
b00_fexts.ml
--------------------------------------------------------------------------- Copyright ( c ) 2019 The b0 programmers . All rights reserved . Distributed under the ISC license , see terms at the end of the file . --------------------------------------------------------------------------- Copyright (c) 20...
null
https://raw.githubusercontent.com/b0-system/b0/cbe12b8a55da6b50ab01ed058b339dbed3cfe894/src/b00/kit/b00_fexts.ml
ocaml
Constants
--------------------------------------------------------------------------- Copyright ( c ) 2019 The b0 programmers . All rights reserved . Distributed under the ISC license , see terms at the end of the file . --------------------------------------------------------------------------- Copyright (c) 20...
eec54763032b8ce46ae04f2ee321fe9e9342652310f5eaaadd8646731c3309b7
keera-studios/haskell-game-programming
Main.hs
{-# LANGUAGE Arrows #-} import Data.IORef import FRP.Yampa as Yampa import Graphics.UI.SDL as SDL import Graphics.UI.SDL.Primitives as SDL main = do Initialise SDL SDL.init [InitVideo] setVideoMode width height 32 [SWSurface] timeRef <- newIORef (0 :: Int) reactimate (return ()) ...
null
https://raw.githubusercontent.com/keera-studios/haskell-game-programming/d4998decb4664a978c87199347f53b420d763b1e/tutorials/frp/yampa/tutorial004-fallingball/Main.hs
haskell
# LANGUAGE Arrows # Obtain surface Paint screen green Paint small red square, at an angle 'angle' with respect to the center Double buffering | Updates the time in an IO Ref and returns the time difference Obtain time difference
import Data.IORef import FRP.Yampa as Yampa import Graphics.UI.SDL as SDL import Graphics.UI.SDL.Primitives as SDL main = do Initialise SDL SDL.init [InitVideo] setVideoMode width height 32 [SWSurface] timeRef <- newIORef (0 :: Int) reactimate (return ()) (\_ -> do ...
ebe24410250116225f29193ab2b7043e9ec0b0bf6f3fe160908444acddc6617d
Eduap-com/WordMat
dlaev2.lisp
;;; Compiled by f2cl version: ( " f2cl1.l , v 95098eb54f13 2013/04/01 00:45:16 toy $ " " f2cl2.l , v 95098eb54f13 2013/04/01 00:45:16 toy $ " " f2cl3.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ " " f2cl4.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ " " f2cl5.l , v 95098eb54f13 2013/04/01 00:45:16 toy $...
null
https://raw.githubusercontent.com/Eduap-com/WordMat/83c9336770067f54431cc42c7147dc6ed640a339/Windows/ExternalPrograms/maxima-5.45.1/share/maxima/5.45.1/share/lapack/lapack/dlaev2.lisp
lisp
Compiled by f2cl version: Using Lisp CMU Common Lisp snapshot-2013-11 (20E Unicode) Options: ((:prune-labels nil) (:auto-save t) (:relaxed-array-decls t) (:coerce-assigns :as-needed) (:array-type ':array) (:array-slicing t) (:declare-common nil) (:float-format single-float))
( " f2cl1.l , v 95098eb54f13 2013/04/01 00:45:16 toy $ " " f2cl2.l , v 95098eb54f13 2013/04/01 00:45:16 toy $ " " f2cl3.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ " " f2cl4.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ " " f2cl5.l , v 95098eb54f13 2013/04/01 00:45:16 toy $ " " f2cl6.l , v 1d5cbacbb9...
e06fad9766338a85db3d51778d3bf5cd02824b567182afe6e4645a186c4e87fd
albertoruiz/easyVision
scatters.hs
import Classifier import Classifier.ToyProblems import Util.Stat import Classifier.Regression(msError) import Util.ICA import Util.Statistics(randomPermutation) import Util.Gaussian(mixturePDF,findMixture) import Numeric.LinearAlgebra import Vision.GUI.Simple import Data.Maybe(maybe) import System.Random(randomIO) imp...
null
https://raw.githubusercontent.com/albertoruiz/easyVision/26bb2efaa676c902cecb12047560a09377a969f2/projects/patrec/scatters.hs
haskell
------------------------------------------------------------------------- ------------------------------------------------------------------------- -------------------------------------------------------
import Classifier import Classifier.ToyProblems import Util.Stat import Classifier.Regression(msError) import Util.ICA import Util.Statistics(randomPermutation) import Util.Gaussian(mixturePDF,findMixture) import Numeric.LinearAlgebra import Vision.GUI.Simple import Data.Maybe(maybe) import System.Random(randomIO) imp...
5134e99f9f2b2992e4e4db30501a10f0528ca8d98ee76f9d36c8777abb4f4079
janestreet/ecaml
browse_url.mli
* Pass a URL to a WWW browser . Ecaml bindings for [ browse-url.el ] open! Core open! Import module Url : sig type t = string val type_ : t Value.Type.t val t : t Value.Type.t end (** [(describe-function 'browse-url)] *) val browse_url : Url.t -> unit (** [(describe-function 'browse-url-chrome)] *) val bro...
null
https://raw.githubusercontent.com/janestreet/ecaml/7c16e5720ee1da04e0757cf185a074debf9088df/src/browse_url.mli
ocaml
* [(describe-function 'browse-url)] * [(describe-function 'browse-url-chrome)]
* Pass a URL to a WWW browser . Ecaml bindings for [ browse-url.el ] open! Core open! Import module Url : sig type t = string val type_ : t Value.Type.t val t : t Value.Type.t end val browse_url : Url.t -> unit val browse_url_chrome : Url.t -> unit
7a043004d64eecca1f58deff95164f3d1e7f3743e7ebf975d3317894f8d56613
thoughtstem/game-engine
spawn-once.rkt
#lang racket (require "../game-entities.rkt") ;(require "../components/after-time.rkt") (require "./direction.rkt") (require "./rotation-style.rkt") (require "./animated-sprite.rkt") (require posn threading) ( " LOADING ON START " ) (provide spawn-many-from spawn-once-inc update-what-will...
null
https://raw.githubusercontent.com/thoughtstem/game-engine/98c4b9e9b8c071818e564ef7efb55465cff487a8/components/spawn-once.rkt
racket
(require "../components/after-time.rkt") (get-component e spawn-once?))) get-components? (component-is? s) (and (not (empty? new-es))
#lang racket (require "../game-entities.rkt") (require "./direction.rkt") (require "./rotation-style.rkt") (require "./animated-sprite.rkt") (require posn threading) ( " LOADING ON START " ) (provide spawn-many-from spawn-once-inc update-what-will-spawn spawn-once-ready? ...
7c20fb2ce43504dea1b973e4f954d313bcb53253ce276a4de59804bcd3648507
logseq/mldoc
mldoc.ml
(** Entry point of the org library *) module Document = Document module Block = Type_parser.Block module Inline = Inline module Exporters = Exporter.Exporters module Conf = Conf module Exporter = Exporter module Timestamp = Timestamp module Parser = Mldoc_parser module Type = Type module Property = Property module Ba...
null
https://raw.githubusercontent.com/logseq/mldoc/658cc20d5b79865cf909a644d4e4bd22ed61b477/lib/mldoc.ml
ocaml
* Entry point of the org library
module Document = Document module Block = Type_parser.Block module Inline = Inline module Exporters = Exporter.Exporters module Conf = Conf module Exporter = Exporter module Timestamp = Timestamp module Parser = Mldoc_parser module Type = Type module Property = Property module Backends = struct module Html = Html e...
06ec796a701bb853725f9fb0fbbcad262f9427d17dc9b6075729bf3ee50f2f44
ryanpbrewster/haskell
P119Test.hs
module Problems.P119Test ( case_119_main ) where import Problems.P119 import Test.Tasty.Discover (Assertion, (@?=)) case_119_main :: Assertion case_119_main = solve @?= "248155780267521"
null
https://raw.githubusercontent.com/ryanpbrewster/haskell/6edd0afe234008a48b4871032dedfd143ca6e412/project-euler/tests/Problems/P119Test.hs
haskell
module Problems.P119Test ( case_119_main ) where import Problems.P119 import Test.Tasty.Discover (Assertion, (@?=)) case_119_main :: Assertion case_119_main = solve @?= "248155780267521"
f51072a9ef4d8dc23a3dafe2a7a340b22714a5010fd4142175bca16cd02b904c
camllight/camllight
int_misc.mli
(* Some extra operations on integers *) value gcd_int: int -> int -> int and num_bits_int: int -> int and compare_int: int -> int -> int and sign_int: int -> int and length_of_int: int and biggest_int: int and least_int: int and monster_int: int and sys_string_of_int : int -> string -> int -> string -...
null
https://raw.githubusercontent.com/camllight/camllight/0cc537de0846393322058dbb26449427bfc76786/sources/contrib/libnum/int_misc.mli
ocaml
Some extra operations on integers
value gcd_int: int -> int -> int and num_bits_int: int -> int and compare_int: int -> int -> int and sign_int: int -> int and length_of_int: int and biggest_int: int and least_int: int and monster_int: int and sys_string_of_int : int -> string -> int -> string -> string and sys_int_of_string : int -...
a6147856db02f7dc5ac3652d343ca1a84a001b3221d0e0d566aa265e1fc38da3
haskell-effectful/effectful
Async.hs
# LANGUAGE UndecidableInstances # -- | Lifted "Control.Concurrent.Async". module Effectful.Concurrent.Async ( -- * Effect Concurrent -- ** Handlers , runConcurrent -- * Asynchronous actions , Async -- * High-level API -- ** Spawning with automatic 'cancel'ation , withAsync, withAsyncBoun...
null
https://raw.githubusercontent.com/haskell-effectful/effectful/f7f82c149e7b4e67c3638e854a84d1c9695c0baa/effectful/src/Effectful/Concurrent/Async.hs
haskell
| Lifted "Control.Concurrent.Async". * Effect ** Handlers * Asynchronous actions * High-level API ** Spawning with automatic 'cancel'ation ** Querying 'Async's ** High-level utilities *** Concurrently *** Conc ** Pooled concurrency ** Specialised operations *** Waiting for multiple 'Async's * Low-level AP...
# LANGUAGE UndecidableInstances # module Effectful.Concurrent.Async Concurrent , runConcurrent , Async , withAsync, withAsyncBound, withAsyncOn, withAsyncWithUnmask , withAsyncOnWithUnmask , wait, poll, waitCatch, A.asyncThreadId , cancel, uninterruptibleCancel, cancelWith, A.AsyncCancelled(..) ,...
ad64597e60d0aeaf50c79d564be1f60dddbc97aa1df2655a8dd10311ffa2f35c
blindglobe/clocc
mop.lisp
;;;; Meta-Object Protocol ;;; Copyright ( C ) 2006 - 2007 by ;;; This is open-source software. GNU Lesser General Public License ( LGPL ) is applicable : ;;; No warranty; you may copy/modify/redistribute under the same ;;; conditions with the source code. ;;; See <URL:> ;;; for details and the precise copyright d...
null
https://raw.githubusercontent.com/blindglobe/clocc/a50bb75edb01039b282cf320e4505122a59c59a7/src/port/mop.lisp
lisp
Meta-Object Protocol This is open-source software. No warranty; you may copy/modify/redistribute under the same conditions with the source code. See <URL:> for details and the precise copyright document. $Source: /cvsroot/clocc/clocc/src/port/mop.lisp,v $ + classes: class names functions generic functions ...
Copyright ( C ) 2006 - 2007 by GNU Lesser General Public License ( LGPL ) is applicable : $ I d : mop.lisp , v 1.4 2007/09/21 16:49:37 sds Exp $ (eval-when (:compile-toplevel :load-toplevel :execute) #-(or (and allegro (version>= 6)) (and clisp mop) cmu lucid lispworks sbcl scl) (error 'not...
fdf7aec68add7a5abc7bfe04340786f5e571744149156f1cb5ba79b5efe2b989
cbaggers/rtg-math
docs-non-consing.lisp
(in-package :rtg-math.projection.non-consing) ;;------------------------------------------------------------ (docs:define-docs (defun orthographic " Creates a `mat4` and mutates it to be an orthographic projection matrix ") (defun orthographic-v2 " Creates a `mat4` and mutates it to be an orthographic...
null
https://raw.githubusercontent.com/cbaggers/rtg-math/29fc5b3d0028a4a11a82355ecc8cca62662c69e0/projection/orthographic/docs-non-consing.lisp
lisp
------------------------------------------------------------
(in-package :rtg-math.projection.non-consing) (docs:define-docs (defun orthographic " Creates a `mat4` and mutates it to be an orthographic projection matrix ") (defun orthographic-v2 " Creates a `mat4` and mutates it to be an orthographic projection matrix (with the frame size specified by a `vec2`) ...
8d030953129cfcf924d5056f8926a78c624ca077f363347757f8f09262e3fc76
djblue/portal
node.cljs
(ns portal.client.node (:require [clojure.string :as str] [portal.client.common :refer (->submit)])) (defn fetch [url options] (let [https? (str/starts-with? url "https") http (js/require (str "http" (when https? "s")))] (js/Promise. (fn [resolve reject] (let [req (.request ...
null
https://raw.githubusercontent.com/djblue/portal/3119a24deba91c69dedf25a7048581d6c75ab3f6/src/portal/client/node.cljs
clojure
(ns portal.client.node (:require [clojure.string :as str] [portal.client.common :refer (->submit)])) (defn fetch [url options] (let [https? (str/starts-with? url "https") http (js/require (str "http" (when https? "s")))] (js/Promise. (fn [resolve reject] (let [req (.request ...
1ee5dde22056c1faef09d7035cd5ab13668489138678da145ab946e5b01c5f22
mukul-rathi/bolt
good_comments.ml
open Core open Print_typed_ast let%expect_test "Comments interspersed with code" = print_typed_ast " void main(){ /* This is a comment - it should not be parsed */ let x = 4;// Can occur after a line let y /*Or even midway*/ = 5; /* Or before */ x /* Comments Can Span ...
null
https://raw.githubusercontent.com/mukul-rathi/bolt/1faf19d698852fdb6af2ee005a5f036ee1c76503/tests/frontend/expect/typing/good_comments.ml
ocaml
open Core open Print_typed_ast let%expect_test "Comments interspersed with code" = print_typed_ast " void main(){ /* This is a comment - it should not be parsed */ let x = 4;// Can occur after a line let y /*Or even midway*/ = 5; /* Or before */ x /* Comments Can Span ...
5798e7b056f3a35b97a5b64fb2b3ad960960899e581881b69daae339b733a6bd
den1k/vimsical
db.cljc
(ns vimsical.frontend.vcs.db (:require [clojure.spec.alpha :as s] [vimsical.vcs.core :as vcs] [vimsical.vcs.branch :as branch] [vimsical.vcs.delta :as delta] [vimsical.vcs.state.timeline :as timeline] [vimsical.frontend.util.subgraph :as util.sg])) (s/def ::branch-uid ::branch/uid) (s/def ::delta-u...
null
https://raw.githubusercontent.com/den1k/vimsical/1e4a1f1297849b1121baf24bdb7a0c6ba3558954/src/frontend/vimsical/frontend/vcs/db.cljc
clojure
* VCS Normalization NOTE sg/add will recursively traverse a datastructure looking for entities, gets large. So far the vcs only contains references for branches in
(ns vimsical.frontend.vcs.db (:require [clojure.spec.alpha :as s] [vimsical.vcs.core :as vcs] [vimsical.vcs.branch :as branch] [vimsical.vcs.delta :as delta] [vimsical.vcs.state.timeline :as timeline] [vimsical.frontend.util.subgraph :as util.sg])) (s/def ::branch-uid ::branch/uid) (s/def ::delta-u...
bb224bed6758837d9882c438163cf0f25b077adac73b875ff2037905f6c0382a
aroemers/rmap
project.clj
(defproject functionalbytes/rmap "2.2.0" :description "A Clojure library to define recursive maps." :url "" :license {:name "Eclipse Public License" :url "-v10.html"} :dependencies [[org.clojure/clojure "1.8.0"]])
null
https://raw.githubusercontent.com/aroemers/rmap/017c628f1e393cd73145ae61861706520c053c97/project.clj
clojure
(defproject functionalbytes/rmap "2.2.0" :description "A Clojure library to define recursive maps." :url "" :license {:name "Eclipse Public License" :url "-v10.html"} :dependencies [[org.clojure/clojure "1.8.0"]])
d86e5314fdeab4ff6c241653575d63548d4592e4fe2f74ca26f8d358cba1af31
utkarshkukreti/bs-preact
RouterRaw.ml
module P = Preact module RouterRaw = struct let make = fun [@preact.component "RouterRaw"] () -> let[@hook] url = P.Router.Url.use P.Router.Hash in let push string _ = P.Router.Url.push P.Router.Hash (P.Router.Url.fromString string) in let replace string _ = P.Router.Url.replace P.Rout...
null
https://raw.githubusercontent.com/utkarshkukreti/bs-preact/61d10d40543e1f8fc83b8a82f6353bcb52489c91/examples/RouterRaw.ml
ocaml
module P = Preact module RouterRaw = struct let make = fun [@preact.component "RouterRaw"] () -> let[@hook] url = P.Router.Url.use P.Router.Hash in let push string _ = P.Router.Url.push P.Router.Hash (P.Router.Url.fromString string) in let replace string _ = P.Router.Url.replace P.Rout...
249f118d634a5c7c97511cf32d6aa8aaa4b937ac367632a7076ef4cd7f81a9e4
RaphaelJ/friday
Interpolate.hs
{-# LANGUAGE BangPatterns , FlexibleContexts #-} -- | Provides a way to estimate the value of a pixel at rational coordinates -- using a linear interpolation. module Vision.Image.Interpolate ( Interpolable (..), bilinearInterpol ) where import Data.Int import Data.RatioInt (denominator, numerator...
null
https://raw.githubusercontent.com/RaphaelJ/friday/13c6bb16bb04856e0cb226726017e7a7ad502cb5/src/Vision/Image/Interpolate.hs
haskell
# LANGUAGE BangPatterns , FlexibleContexts # | Provides a way to estimate the value of a pixel at rational coordinates using a linear interpolation. | Provides a way to apply the interpolation to every component of a pixel. | Uses a bilinear interpolation to find the value of the pixel at the rational c...
module Vision.Image.Interpolate ( Interpolable (..), bilinearInterpol ) where import Data.Int import Data.RatioInt (denominator, numerator) import Data.Word import Vision.Image.Class (Pixel (..), Image (..), ImagePixel, ImageChannel) import Vision.Primitive (RPoint (..), ix2) class Interpolable p where ...
bfb1be98caf46a7e812591690cff1a1494af4715c79bc77dd0ba8915e64bb9b6
metabase/metabase
parameters_test.clj
(ns metabase.query-processor.middleware.parameters-test "Testings to make sure the parameter substitution middleware works as expected. Even though the below tests are SQL-specific, they still confirm that the middleware itself is working correctly." (:require [clojure.test :refer :all] [metabase.driver :as...
null
https://raw.githubusercontent.com/metabase/metabase/0c56664819bb84a7a317caf0fc393d2fa1bf3ccd/test/metabase/query_processor/middleware/parameters_test.clj
clojure
tests. (This is dumb. Hopefully no one is creating queries like this. The `:parameters` should go in the source query instead of in the join.)
(ns metabase.query-processor.middleware.parameters-test "Testings to make sure the parameter substitution middleware works as expected. Even though the below tests are SQL-specific, they still confirm that the middleware itself is working correctly." (:require [clojure.test :refer :all] [metabase.driver :as...
1026820b3c1fe6efac8b5143c6b7621074a79685d7702b86ed57dc27feb888ef
korya/efuns
terms.ml
(***********************************************************************) (* *) (* Objective Caml *) (* *) , projet ...
null
https://raw.githubusercontent.com/korya/efuns/78b21d9dff45b7eec764c63132c7a564f5367c30/inliner/perf/KB/terms.ml
ocaml
********************************************************************* Objective Caml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et Automatique . Distributed only by permission . $ I d : terms.ml , v 1.1 1999/11/22 10:35:59 lefessan Exp $ type term = Var of int | Term of string *...
1c21a26caa794ed0cdee38b573623c51af801129f134d4e036aa14c9fe59ebf0
larcenists/larceny
diviter.scm
DIVITER -- 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))) (define *ll* (create-n 200)) (define (iterative-div2 l) (do ((l l (cddr l)) (a '() (cons (car l) a))) ((null? l) a))) (define (main . args)...
null
https://raw.githubusercontent.com/larcenists/larceny/fef550c7d3923deb7a5a1ccd5a628e54cf231c75/test/Stress/src/diviter.scm
scheme
DIVITER -- 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))) (define *ll* (create-n 200)) (define (iterative-div2 l) (do ((l l (cddr l)) (a '() (cons (car l) a))) ((null? l) a))) (define (main . args)...
f87540a0b410b914d625c084d520a3331a4777df32942512cd62cd78c3bfa688
ZeusWPI/contests
parcours.hs
import Control.Applicative (Alternative (..), Applicative (..), (<$>)) import Control.Monad (MonadPlus (..), ap, guard, replicateM, replicateM_) import Data.Char (isDigit, ord) import Data.List (find) import Data.Map (Map) import Data.Maybe (isNothing, maybeToList) import qualified Data.Map as M import qualified Data.S...
null
https://raw.githubusercontent.com/ZeusWPI/contests/d78aec91be3ce32a436d160cd7a13825d36bbf3a/2011-vpw/parcours.hs
haskell
------------------------------------------------------------------------------ ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ ------------------------------------------------------------------------------
import Control.Applicative (Alternative (..), Applicative (..), (<$>)) import Control.Monad (MonadPlus (..), ap, guard, replicateM, replicateM_) import Data.Char (isDigit, ord) import Data.List (find) import Data.Map (Map) import Data.Maybe (isNothing, maybeToList) import qualified Data.Map as M import qualified Data.S...
628e4ce82af43d2b7d50795d8f8a8681d4c73647cea733b9c03492e240c02d7e
adlai/cjhunt
config.lisp
(in-package :cl-user) (defpackage cjhunt.config (:use :cl) (:import-from :envy :config-env-var :defconfig) (:export :config :*application-root* :*static-directory* :*template-directory* :appenv :developmentp :product...
null
https://raw.githubusercontent.com/adlai/cjhunt/fb89d8600e6b42c9d6b67dd3fded59907e91a3be/src/config.lisp
lisp
(in-package :cl-user) (defpackage cjhunt.config (:use :cl) (:import-from :envy :config-env-var :defconfig) (:export :config :*application-root* :*static-directory* :*template-directory* :appenv :developmentp :product...
a1e8e157f8f209212428ec2a9b10db64baab51590bf1f049057c861d2f4bc5c5
dmitryvk/sbcl-win32-threads
early-defbangmethod.lisp
This software is part of the SBCL system . See the README file for ;;;; more information. ;;;; This software is derived from the CMU CL system , which was written at Carnegie Mellon University and released into the ;;;; public domain. The software is in the public domain and is ;;;; provided with absolutely no wa...
null
https://raw.githubusercontent.com/dmitryvk/sbcl-win32-threads/5abfd64b00a0937ba2df2919f177697d1d91bde4/src/code/early-defbangmethod.lisp
lisp
more information. public domain. The software is in the public domain and is provided with absolutely no warranty. See the COPYING and CREDITS files for more information.
This software is part of the SBCL system . See the README file for This software is derived from the CMU CL system , which was written at Carnegie Mellon University and released into the (in-package "SB!IMPL") #+sb-xc-host (defmacro def!method (&rest args) `(defmethod ,@args))
7d5a4a84914e185aa8d26dba2af849e6135a9f0d6dbe5b207a5321d5f1ad9fea
phadej/cabal-fmt
Parser.hs
-- | -- License: GPL-3.0-or-later Copyright : module CabalFmt.Parser where import qualified Data.ByteString as BS import qualified Distribution.Fields as C import qualified Distribution.PackageDescription.Parsec as C import qualified Distribution.Parsec ...
null
https://raw.githubusercontent.com/phadej/cabal-fmt/ead940a3dd955a2c7b32b8817b03885ff550c128/src/CabalFmt/Parser.hs
haskell
| License: GPL-3.0-or-later
Copyright : module CabalFmt.Parser where import qualified Data.ByteString as BS import qualified Distribution.Fields as C import qualified Distribution.PackageDescription.Parsec as C import qualified Distribution.Parsec as C impor...
edff471e43adf456ed2bb071d1df69e4b3691e7ea11bcd7af6a3b49eb680e892
ucsd-progsys/liquidhaskell
Set00.hs
{-@ LIQUID "--expect-any-error" @-} TEST that the name ` member ` is properly resolved to Set_mem . TAG : LOGICMAP module Set00 where import Data.Set as S {-@ add :: x:a -> [a] -> {v:[a] | Set_mem x (listElts v)} @-} add :: a -> [a] -> [a] add x xs = xs
null
https://raw.githubusercontent.com/ucsd-progsys/liquidhaskell/f46dbafd6ce1f61af5b56f31924c21639c982a8a/tests/names/neg/Set00.hs
haskell
@ LIQUID "--expect-any-error" @ @ add :: x:a -> [a] -> {v:[a] | Set_mem x (listElts v)} @
TEST that the name ` member ` is properly resolved to Set_mem . TAG : LOGICMAP module Set00 where import Data.Set as S add :: a -> [a] -> [a] add x xs = xs
0f1d98fad9a17779e07131b82589dba79508cf8b5179e74887350012d8a55127
patoline/patoline
patDefault.ml
let share = try let (ic, _, _) as cs = let env = Unix.environment () in Unix.open_process_full "opam var share" env in let res = input_line ic in ignore (Unix.close_process_full cs); res with _ -> "/usr/local/share" let fonts_dir = Filename.concat share "patoline/fonts" let gramm...
null
https://raw.githubusercontent.com/patoline/patoline/3dcd41fdff64895d795d4a78baa27d572b161081/patconfig/patDefault.ml
ocaml
let share = try let (ic, _, _) as cs = let env = Unix.environment () in Unix.open_process_full "opam var share" env in let res = input_line ic in ignore (Unix.close_process_full cs); res with _ -> "/usr/local/share" let fonts_dir = Filename.concat share "patoline/fonts" let gramm...
00949ae8309b92d8403e8d0691fb2c4bca5d2240b932068ea8678217234aa0c6
lspitzner/brittany
Test369.hs
-- brittany { lconfig_columnAlignMode: { tag: ColumnAlignModeDisabled }, lconfig_indentPolicy: IndentPolicyLeft } func :: ( lkasdlkjalsdjlakjsdlkjasldkjalskdjlkajsd -> lkasdlkjalsdjlakjsdlkjasldkjalskdjlkajsd ) -> lakjsdlkjasldkj
null
https://raw.githubusercontent.com/lspitzner/brittany/a15eed5f3608bf1fa7084fcf008c6ecb79542562/data/Test369.hs
haskell
brittany { lconfig_columnAlignMode: { tag: ColumnAlignModeDisabled }, lconfig_indentPolicy: IndentPolicyLeft }
func :: ( lkasdlkjalsdjlakjsdlkjasldkjalskdjlkajsd -> lkasdlkjalsdjlakjsdlkjasldkjalskdjlkajsd ) -> lakjsdlkjasldkj
df193190c75c73930f0dc4263fac64d7d727aea67425d74eb4c930c001af155d
deobald/jok
slide.cljs
(ns slide (:require [goog.dom :as gdom] goog.dom.query [goog.events :as events] [goog.events.EventType :as event-type] interop)) (defn find-by-classes [classes] (.item (gdom/query classes) 0)) (defn slide-to [color] (set! (.-location js/window) (str "/" color))) ...
null
https://raw.githubusercontent.com/deobald/jok/e1b9373603ad7fcc3dbc7304cb8b88b8163e73bc/src-cljs/slide.cljs
clojure
(ns slide (:require [goog.dom :as gdom] goog.dom.query [goog.events :as events] [goog.events.EventType :as event-type] interop)) (defn find-by-classes [classes] (.item (gdom/query classes) 0)) (defn slide-to [color] (set! (.-location js/window) (str "/" color))) ...
fea1992651893c485ad9dd015627c508e6eb2f2112d88a5d5dd9e06a3fdb6615
ocharles/blog
2013-12-18-square.hs
module Square where | Given an integer , ' square ' returns the same number squared : > > > square 5 25 >>> square 5 25 -} square :: Int -> Int square x = x * x
null
https://raw.githubusercontent.com/ocharles/blog/fa8e911d3c03b134eee891d187a1bb574f23a530/code/2013-12-18-square.hs
haskell
module Square where | Given an integer , ' square ' returns the same number squared : > > > square 5 25 >>> square 5 25 -} square :: Int -> Int square x = x * x
fa5cc0537e4f933d1efb58efb2e4063697a96a54d6886e0db56d9c4b1fb9186a
wooga/locker
basho_bench_driver_locker.erl
-module(basho_bench_driver_locker). -export([new/1, run/4]). new(_Id) -> case mark_setup_completed() of true -> error_logger:info_msg("setting up cluster~n"), net_kernel:start([master, shortnames]), {ok, _LocalLocker} = locker:start_link(2), MasterN...
null
https://raw.githubusercontent.com/wooga/locker/cf92412b95fd429066a8c511c0049447a10d58fa/test/basho_bench_driver_locker.erl
erlang
-module(basho_bench_driver_locker). -export([new/1, run/4]). new(_Id) -> case mark_setup_completed() of true -> error_logger:info_msg("setting up cluster~n"), net_kernel:start([master, shortnames]), {ok, _LocalLocker} = locker:start_link(2), MasterN...
815fa4fcaf22ada9733d3453b43c034fc79c997efcf3885543a40baba4a39467
edbutler/nonograms-rule-synthesis
collection.rkt
#lang racket ; some data structures (e.g., a digraph) (provide digraph? make-digraph dg-identity-node-key? serialize-digraph deserialize-digraph dg-node-ref dg-node-value dg-edge-value dg-edge-source dg-edge-target dg-nodes dg-order dg-size dg-edge-values dg-add-node! dg-outgoing-edges dg-outgoing-ne...
null
https://raw.githubusercontent.com/edbutler/nonograms-rule-synthesis/16f8dacb17bd77c9d927ab9fa0b8c1678dc68088/src/core/collection.rkt
racket
some data structures (e.g., a digraph) #f iff the node key function is the identity maps both node and edge values of the graph then dumps nodes as a list the caller is going to have to remember the key-fn manually, unfortunately. digraph?, any? -> node? node? -> (listof edge?) do a dfs until we find end-node or...
#lang racket (provide digraph? make-digraph dg-identity-node-key? serialize-digraph deserialize-digraph dg-node-ref dg-node-value dg-edge-value dg-edge-source dg-edge-target dg-nodes dg-order dg-size dg-edge-values dg-add-node! dg-outgoing-edges dg-outgoing-neighbors dg-out-degree dg-sink? dg-sour...