_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
9e1f87271d5560844a6493e87adb4876f1524bf41f4f48e8d7afe6641f9abd66
cark/cark.behavior-tree
success_leaf.cljc
(ns cark.behavior-tree.node-defs.success-leaf "The :success-leaf always succeeds" (:require [cark.behavior-tree.context :as ctx] [cark.behavior-tree.db :as db] [cark.behavior-tree.tree :as tree] [cark.behavior-tree.type :as type] [cark.behavior-tree.base-nodes :...
null
https://raw.githubusercontent.com/cark/cark.behavior-tree/4e229fcc2ed3af3c66e74d2c51dda6684927d254/src/main/cark/behavior_tree/node_defs/success_leaf.cljc
clojure
(ns cark.behavior-tree.node-defs.success-leaf "The :success-leaf always succeeds" (:require [cark.behavior-tree.context :as ctx] [cark.behavior-tree.db :as db] [cark.behavior-tree.tree :as tree] [cark.behavior-tree.type :as type] [cark.behavior-tree.base-nodes :...
25b8da6a64c5d22999b657901c38ea0f3e9010b8f361d678e243a6b4147d0311
foretspaisibles/cl-kaputt
utilities.lisp
utilities.lisp — Utilities for ( -kaputt ) This file is part of Kaputt . ;;;; Copyright © 2019–2021 ;;;; All rights reserved. This software is governed by the CeCILL - B license under French law and ;;;; abiding by the rules of distribution of free software. You can use, modify and/ or redistribut...
null
https://raw.githubusercontent.com/foretspaisibles/cl-kaputt/35688aca703c4e0ca26e4cd0daf2ae2fb62bad99/src/utilities.lisp
lisp
All rights reserved. abiding by the rules of distribution of free software. You can use, "-B_V1-en.txt" STRING-MATCH DESCRIPTION End of file `utilities.lisp'
utilities.lisp — Utilities for ( -kaputt ) This file is part of Kaputt . Copyright © 2019–2021 This software is governed by the CeCILL - B license under French law and modify and/ or redistribute the software under the terms of the CeCILL - B license as circulated by CEA , CNRS and INRIA at the fol...
a877d5528aae4dd109e755558a858118f2f48b443e83515a28553723d89f3dda
Kappa-Dev/KappaTools
kasim_args.mli
type directive_unit = Time | Event type t = { mutable alg_var_overwrite : (string * Nbr.t) list; mutable marshalizedInFile : string; mutable initialMix : string option; mutable rescale : float option; mutable seedValue : int option; mutable unit : directive_unit; mutable marshali...
null
https://raw.githubusercontent.com/Kappa-Dev/KappaTools/5e756eb3529db9976cf0a0884a22676925985978/core/cli/kasim_args.mli
ocaml
type directive_unit = Time | Event type t = { mutable alg_var_overwrite : (string * Nbr.t) list; mutable marshalizedInFile : string; mutable initialMix : string option; mutable rescale : float option; mutable seedValue : int option; mutable unit : directive_unit; mutable marshali...
98fe685a9c86a5f95e4d8e34517d9807fd59e7cc7f30b60b439ca9655cd159e6
korya/efuns
accents_mode.ml
(***********************************************************************) (* *) xlib for (* *) Fabrice Le Fessant , projet Para / SOR , INRIA Rocq...
null
https://raw.githubusercontent.com/korya/efuns/78b21d9dff45b7eec764c63132c7a564f5367c30/efuns/accents_mode.ml
ocaml
********************************************************************* ...
xlib for Fabrice Le Fessant , projet Para / SOR , INRIA Rocquencourt Copyright 1998 Institut National de Recherche en Informatique et Automatique . Distributed only by permission . open Text open Simple open Efuns open Top_window let acce...
a345f4c7481c4add702daba7d527fb1ff3a49d364e7fb0641d573f5b07ac48ef
braveclojure/training
project.clj
(defproject character-creator "0.1.0-SNAPSHOT" :description "FIXME: write description" :url "" :license {:name "Eclipse Public License" :url "-v10.html"} :dependencies [[org.clojure/clojure "1.8.0"]] :main ^:skip-aot character-creator.core :target-path "target/%s" :profiles {:uberjar {:aot :al...
null
https://raw.githubusercontent.com/braveclojure/training/5b7fb9059c17b2166c2e66850094f424319e55eb/projects/character-creator/project.clj
clojure
(defproject character-creator "0.1.0-SNAPSHOT" :description "FIXME: write description" :url "" :license {:name "Eclipse Public License" :url "-v10.html"} :dependencies [[org.clojure/clojure "1.8.0"]] :main ^:skip-aot character-creator.core :target-path "target/%s" :profiles {:uberjar {:aot :al...
1453c3e2c9bec6eb989a7f0ffbbb2bc36e942185912b956869a9635a91df35bd
spechub/Hets
Logic_TopHybrid.hs
# LANGUAGE MultiParamTypeClasses , TypeSynonymInstances , FlexibleInstances , UndecidableInstances , ExistentialQuantification # UndecidableInstances, ExistentialQuantification #-} | Module : ./TopHybrid / Logic_TopHybrid.hs License : GPLv2 or higher , see LICENSE.txt ...
null
https://raw.githubusercontent.com/spechub/Hets/fc26b4947bf52be6baf7819a75d7e7f127e290dd/TopHybrid/Logic_TopHybrid.hs
haskell
Import of logics End of import of logics --- The logics supported section ---- Logics supported Tries to get a logic, if it fails, then gives an error saying that the logic in question doesn't exist
# LANGUAGE MultiParamTypeClasses , TypeSynonymInstances , FlexibleInstances , UndecidableInstances , ExistentialQuantification # UndecidableInstances, ExistentialQuantification #-} | Module : ./TopHybrid / Logic_TopHybrid.hs License : GPLv2 or higher , see LICENSE.txt ...
2f9e1ca82382ce06f89f97197704e6e92fd54370c7f51b46863cdca487e9b5e4
clojure-interop/java-jdk
BasicFormattedTextFieldUI.clj
(ns javax.swing.plaf.basic.BasicFormattedTextFieldUI "Provides the look and feel implementation for JFormattedTextField." (:refer-clojure :only [require comment defn ->]) (:import [javax.swing.plaf.basic BasicFormattedTextFieldUI])) (defn ->basic-formatted-text-field-ui "Constructor." (^BasicFormattedTextF...
null
https://raw.githubusercontent.com/clojure-interop/java-jdk/8d7a223e0f9a0965eb0332fad595cf7649d9d96e/javax.swing/src/javax/swing/plaf/basic/BasicFormattedTextFieldUI.clj
clojure
(ns javax.swing.plaf.basic.BasicFormattedTextFieldUI "Provides the look and feel implementation for JFormattedTextField." (:refer-clojure :only [require comment defn ->]) (:import [javax.swing.plaf.basic BasicFormattedTextFieldUI])) (defn ->basic-formatted-text-field-ui "Constructor." (^BasicFormattedTextF...
c54104d78d4638ed58804138f37a37f1a70b95dcf9e1273dbe3d49c70fbb5d11
Zulu-Inuoe/clution
configuration.lisp
;;;; --------------------------------------------------------------------------- Generic support for configuration files (uiop/package:define-package :uiop/configuration necessary to upgrade from 2.27 . (:use :uiop/common-lisp :uiop/utility :uiop/os :uiop/pathname :uiop/filesystem :uiop/stream :uiop/image :ui...
null
https://raw.githubusercontent.com/Zulu-Inuoe/clution/b72f7afe5f770ff68a066184a389c23551863f7f/cl-clution/qlfile-libs/uiop-3.3.1/configuration.lisp
lisp
--------------------------------------------------------------------------- implemented in backward-driver idem we throw away the form and location arguments, hence the ~2* SORT w/o COPY-LIST is OK: DIRECTORY returns a fresh list special magic! we return a relative pathname, but what it means to the output-trans...
Generic support for configuration files (uiop/package:define-package :uiop/configuration necessary to upgrade from 2.27 . (:use :uiop/common-lisp :uiop/utility :uiop/os :uiop/pathname :uiop/filesystem :uiop/stream :uiop/image :uiop/lisp-build) (:export #:get-folder-path #:xdg-data-home #:xdg-config-ho...
69bbadbf518136e6c72fe9bec45a87823824e83ede8119b267e95d2c9e53da49
epiccastle/bbssh
byte_array_input_stream.clj
(ns pod.epiccastle.bbssh.byte-array-input-stream "Creates and calls the various methods of a ByteArrayInputStream that exists on the pod heap." (:refer-clojure :exclude [flush read]) (:require [pod.epiccastle.bbssh.pod.byte-array-input-stream :as byte-array-input-stream] [pod.epiccastle.bbssh.impl.c...
null
https://raw.githubusercontent.com/epiccastle/bbssh/ee15ca308e640c870c9ff3d7c519394e5732ee2b/src/bb/pod/epiccastle/bbssh/byte_array_input_stream.clj
clojure
(ns pod.epiccastle.bbssh.byte-array-input-stream "Creates and calls the various methods of a ByteArrayInputStream that exists on the pod heap." (:refer-clojure :exclude [flush read]) (:require [pod.epiccastle.bbssh.pod.byte-array-input-stream :as byte-array-input-stream] [pod.epiccastle.bbssh.impl.c...
e8c1b95677e623aa947208100a98947d103cd8a7aa5d1b987a8c1c96a839db83
CatalaLang/catala
print.mli
This file is part of the Catala compiler , a specification language for tax and social benefits computation rules . Copyright ( C ) 2020 , contributor : < > Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not use this file except in compliance with the License . ...
null
https://raw.githubusercontent.com/CatalaLang/catala/efdf653ec7af75c6da50a405eaa9c5a9c26402c9/compiler/surface/print.mli
ocaml
This file is part of the Catala compiler , a specification language for tax and social benefits computation rules . Copyright ( C ) 2020 , contributor : < > Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not use this file except in compliance with the License . ...
5e2a6c9615e8418eb967e789f8d4d2fc5695eb1b2b8eadbbe721ecf9f4e9dba5
tonyg/racket-something
broadcast-messages.rkt
#lang something // -*- sth -*- // Demonstrate sending a message to multiple receivers. // Requires the "syndicate" package to be installed. require something/infix "syndicate.rkt" struct envelope (destination message) :prefab run-ground spawn: on message (envelope `alice $message) log-info...
null
https://raw.githubusercontent.com/tonyg/racket-something/4a00a9a6d37777f5aab4f28b03c53555b87e21d7/examples/syndicate/broadcast-messages.rkt
racket
#lang something // -*- sth -*- // Demonstrate sending a message to multiple receivers. // Requires the "syndicate" package to be installed. require something/infix "syndicate.rkt" struct envelope (destination message) :prefab run-ground spawn: on message (envelope `alice $message) log-info...
b61f40c3bbf737bc101429a4565f1c891bcef7bebf8805041259200ce0216543
zxymike93/SICP
275.rkt
#lang racket (define (square x) (* x x)) (define (make-from-real-imag x y) (define (dispatch op) (cond [(eq? op 'real-part) x] [(eq? op 'imag-part) y] [(eq? op 'magnitude) (sqrt (+ (square x) (square y)))] [(eq? op 'angle) (atan y x)] [else (error "Unknown op: MAKE-FROM-R...
null
https://raw.githubusercontent.com/zxymike93/SICP/9d8e84d6a185bf4d7f28c414fc3359741384beb5/chapter2/275.rkt
racket
tests 因为 constructor 返回一个过程,除非显式 apply 一些操作,否则终端只会输出 #procedure
#lang racket (define (square x) (* x x)) (define (make-from-real-imag x y) (define (dispatch op) (cond [(eq? op 'real-part) x] [(eq? op 'imag-part) y] [(eq? op 'magnitude) (sqrt (+ (square x) (square y)))] [(eq? op 'angle) (atan y x)] [else (error "Unknown op: MAKE-FROM-R...
e095f69c2099476e4616969f8cfc0ce29fb6b18bf8a2220da4f292beafafb53c
tensorflow/haskell
Tensor.hs
Copyright 2016 TensorFlow authors . -- 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 distr...
null
https://raw.githubusercontent.com/tensorflow/haskell/d088e30b80f1508281e400975bec9d14b431a22c/tensorflow/src/TensorFlow/Tensor.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 2016 TensorFlow authors . Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , # LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE DeriveF...
e86ae7dce3d9bda515bde9ef6ecaef68d71edd21fe74d4308023dbc4e5d11185
chrovis/cljam
bgzf.clj
(ns cljam.io.util.bgzf (:refer-clojure :exclude [compare]) (:require [clojure.java.io :as cio]) (:import [java.io File] [java.net MalformedURLException URI URL] [bgzf4j BGZFInputStream BGZFOutputStream])) (defprotocol BGZFIOFactory (make-bgzf-input-stream [x]) (make-bgzf-output-stream [...
null
https://raw.githubusercontent.com/chrovis/cljam/2b8e7386765be8efdbbbb4f18dbc52447f4a08af/src/cljam/io/util/bgzf.clj
clojure
When treating as unsigned, negative number is > positive. Either both negative or both non-negative, so regular comparison works. FEXTRA SI1 SI2 LEN
(ns cljam.io.util.bgzf (:refer-clojure :exclude [compare]) (:require [clojure.java.io :as cio]) (:import [java.io File] [java.net MalformedURLException URI URL] [bgzf4j BGZFInputStream BGZFOutputStream])) (defprotocol BGZFIOFactory (make-bgzf-input-stream [x]) (make-bgzf-output-stream [...
dff4a175304116d2c898068729a2632ede14f21de64770d4ec8736c9a7e36d0a
jumarko/clojure-experiments
image.clj
;; # 🏞 Image Viewer (ns image (:import (java.net URL) (javax.imageio ImageIO))) Clerk now comes with a default viewer for ` java.awt.image . BufferedImage ` . It looks at the dimensions of the image , and tries to do the right thing . For an image larger than 900px wide with an aspect ratio larger 2 , ...
null
https://raw.githubusercontent.com/jumarko/clojure-experiments/a87098fe69044ad65813a68cb870d824c2c2d18f/src/clojure_experiments/visualizations/clerk/notebooks/viewers/image.clj
clojure
# 🏞 Image Viewer Smaller images are centered and shown using thier intrinsic dimensions.
(ns image (:import (java.net URL) (javax.imageio ImageIO))) Clerk now comes with a default viewer for ` java.awt.image . BufferedImage ` . It looks at the dimensions of the image , and tries to do the right thing . For an image larger than 900px wide with an aspect ratio larger 2 , it uses full width . ...
bda399cc00e7ddd036901ecca39c814092ce32a5a81790fa928ea7a424c0b060
discus-lang/ddc
Tokens.hs
module DDC.Core.Codec.Text.Lexer.Tokens ( Located (..) , columnOfLocated -- * Tokens , Token (..) , TokenMeta (..) , TokenAtom (..) , TokenNamed (..) , Keyword (..) , Symbol (..) , Builtin (..) ...
null
https://raw.githubusercontent.com/discus-lang/ddc/2baa1b4e2d43b6b02135257677671a83cb7384ac/src/s1/ddc-core/DDC/Core/Codec/Text/Lexer/Tokens.hs
haskell
* Tokens ** Description ** Renaming ** Predicates ** Literal Reading TokenFamily ---------------------------------------------------------------- | The family of a token. This is used to help generate parser error messages, so we can say ''the constructor Cons'' and ''the keyword case'' etc. ...
module DDC.Core.Codec.Text.Lexer.Tokens ( Located (..) , columnOfLocated , Token (..) , TokenMeta (..) , TokenAtom (..) , TokenNamed (..) , Keyword (..) , Symbol (..) , Builtin (..) , Literal (...
0f2e95749a64d2c8176200b2f6c5ade36847f3d610860887986ec647da8d6db0
aiya000/haskell-examples
getEnvironment.hs
import qualified System.Environment as E import qualified System.Posix.Env as PE import Data.Maybe main :: IO () main = do x <- E.getEnv "EDITOR" x <- E.getEnv "EDITOR" y <- PE.getEnv "EDITTTTOR" z <- PE.getEnvDefault "EDITTTTOR" "undefined" putStrLn $ x putStrLn $ fromMaybe "undef...
null
https://raw.githubusercontent.com/aiya000/haskell-examples/a337ba0e86be8bb1333e7eea852ba5fa1d177d8a/System/getEnvironment.hs
haskell
import qualified System.Environment as E import qualified System.Posix.Env as PE import Data.Maybe main :: IO () main = do x <- E.getEnv "EDITOR" x <- E.getEnv "EDITOR" y <- PE.getEnv "EDITTTTOR" z <- PE.getEnvDefault "EDITTTTOR" "undefined" putStrLn $ x putStrLn $ fromMaybe "undef...
4cf36114e63982b26b608df6c6dc3b759bbed02311c2a28f5f5e2e380fc77fdd
racket/htdp
mp.rkt
#lang scheme (require test-engine/racket-tests) (require 2htdp/universe) (require htdp/image) WorldState = Image ;; graphical constants (define mt (empty-scene 100 100)) clack : WorldState Worldstate ;; add a dot at (x,y) to ws (check-expect (clack mt 10 20 "button-down") (place-image (circle 1 "solid...
null
https://raw.githubusercontent.com/racket/htdp/aa78794fa1788358d6abd11dad54b3c9f4f5a80b/htdp-test/2htdp/tests/mp.rkt
racket
graphical constants add a dot at (x,y) to ws show : WorldState -> WorldState just reveal the current world state run program run
#lang scheme (require test-engine/racket-tests) (require 2htdp/universe) (require htdp/image) WorldState = Image (define mt (empty-scene 100 100)) clack : WorldState Worldstate (check-expect (clack mt 10 20 "button-down") (place-image (circle 1 "solid" "red") 10 20 mt)) (check-expect (clack (place-i...
1c4db8948ea63a764fd2c71b36be64f2df7e7c659b21ad8e896f4393d0c38120
fulcrologic/fulcro-rad-tutorial
ui.cljc
(ns com.example.ui (:require #?@(:cljs [[com.fulcrologic.semantic-ui.modules.dropdown.ui-dropdown :refer [ui-dropdown]] [com.fulcrologic.semantic-ui.modules.dropdown.ui-dropdown-menu :refer [ui-dropdown-menu]] [com.fulcrologic.semantic-ui.modules.dropdown.ui-dropdown-item :refer [ui-...
null
https://raw.githubusercontent.com/fulcrologic/fulcro-rad-tutorial/809b8f8833363be7dc0c9a66307b1fa164da4d70/src/main/com/example/ui.cljc
clojure
This will just be a normal router...but there can be many of them. Normal Fulcro code to show a loader on slow route change (assuming Semantic UI here, should TODO: check if we can change routes...
(ns com.example.ui (:require #?@(:cljs [[com.fulcrologic.semantic-ui.modules.dropdown.ui-dropdown :refer [ui-dropdown]] [com.fulcrologic.semantic-ui.modules.dropdown.ui-dropdown-menu :refer [ui-dropdown-menu]] [com.fulcrologic.semantic-ui.modules.dropdown.ui-dropdown-item :refer [ui-...
154694ffe4dfad000016407123809265b238b09bdd644965f87e036d8b45ca4d
arekinath/esaml
esaml_util.erl
esaml - SAML for erlang %% Copyright ( c ) 2013 , and the University of Queensland %% All rights reserved. %% Distributed subject to the terms of the 2 - clause BSD license , see %% the LICENSE file in the root of the distribution. %% @doc Utility functions -module(esaml_util). -include_lib("xmerl/include/xme...
null
https://raw.githubusercontent.com/arekinath/esaml/bf52dcb449184dc94e4fb1ff8820b08cc1ceab09/src/esaml_util.erl
erlang
All rights reserved. the LICENSE file in the root of the distribution. @doc Utility functions @doc Converts various ascii hex/base64 fingerprint formats to binary @doc Converts a calendar:datetime() into SAML time string @doc Converts a SAML time string into a calendar:datetime() Inverse of datetime_to_saml/1...
esaml - SAML for erlang Copyright ( c ) 2013 , and the University of Queensland Distributed subject to the terms of the 2 - clause BSD license , see -module(esaml_util). -include_lib("xmerl/include/xmerl.hrl"). -include_lib("public_key/include/public_key.hrl"). -include("esaml.hrl"). -export([datetime_to_sam...
9ce485e92808191d9d4ebcc880bfe74c83ec508a883d2c6121755c1d642f506e
brendanhay/amazonka
SamplingRule.hs
# LANGUAGE DeriveGeneric # # LANGUAGE DuplicateRecordFields # # LANGUAGE NamedFieldPuns # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE RecordWildCards # {-# LANGUAGE StrictData #-} # LANGUAGE NoImplicitPrelude # # OPTIONS_GHC -fno - warn - unused - imports # # OPTIONS_GHC -fno - warn - unused - matches # Derived fr...
null
https://raw.githubusercontent.com/brendanhay/amazonka/09f52b75d2cfdff221b439280d3279d22690d6a6/lib/services/amazonka-xray/gen/Amazonka/XRay/Types/SamplingRule.hs
haskell
# LANGUAGE OverloadedStrings # # LANGUAGE StrictData # | Stability : auto-generated | A sampling rule that services use to decide whether to instrument a request. Rule fields can match properties of the service, or properties properties. /See:/ 'newSamplingRule' smart constructor. | Matches attributes derived...
# LANGUAGE DeriveGeneric # # LANGUAGE DuplicateRecordFields # # LANGUAGE NamedFieldPuns # # LANGUAGE RecordWildCards # # LANGUAGE NoImplicitPrelude # # OPTIONS_GHC -fno - warn - unused - imports # # OPTIONS_GHC -fno - warn - unused - matches # Derived from AWS service descriptions , licensed under Apache 2.0 . Mo...
8b01d90ff1df8a7e63bbb0e943812c8d996e48852390150d2e8898aced12dfa3
nikodemus/SBCL
eval.lisp
EVAL and friends 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 w...
null
https://raw.githubusercontent.com/nikodemus/SBCL/3c11847d1e12db89b24a7887b18a137c45ed4661/src/code/eval.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. a secondary value of T if we must call the resulting function to evaluate EXPR -- if EXPR is already a lambda form, there's no need. This te...
EVAL and friends 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") (defparameter *eval-calls* 0) (defun !eval-cold-init () (setf *eval-calls* 0 ...
3860afd250fbb5137090a8b242793ddcc023d7fe0c0598878cfe002ce1a2e2ee
AccelerateHS/accelerate-llvm
Backoff.hs
# LANGUAGE RecordWildCards # {-# OPTIONS_HADDOCK hide #-} -- | Module : Control . Parallel . Meta . Resource . Backoff Copyright : [ 2014 .. 2020 ] The Accelerate Team -- License : BSD3 -- Maintainer : < > -- Stability : experimental Portability : non - portable ( GHC extensions ) -- -- Thi...
null
https://raw.githubusercontent.com/AccelerateHS/accelerate-llvm/cf081587fecec23a19f68bfbd31334166868405e/accelerate-llvm/icebox/Control/Parallel/Meta/Resource/Backoff.hs
haskell
# OPTIONS_HADDOCK hide # | License : BSD3 Stability : experimental This module implements exponential backoff so as to prevent spamming of stealing actions. Most scheduler compositions should include this at the bottom of the stack. <-par> | To construct the work search, we need to know the minimum an...
# LANGUAGE RecordWildCards # Module : Control . Parallel . Meta . Resource . Backoff Copyright : [ 2014 .. 2020 ] The Accelerate Team Maintainer : < > Portability : non - portable ( GHC extensions ) Inspired by the meta - par package . This package has a BSD license . module Control.Parallel.M...
6c8565a5538490ddfd5fc0b8817f8fee1e1a8a70be2d7ba812ccffb37478dafa
janestreet/sexp
test.mli
(* Just for testing. Nothing to export. *)
null
https://raw.githubusercontent.com/janestreet/sexp/56e485b3cbf8a43e1a8d7647b0df31b27053febf/sexp_app/src/test.mli
ocaml
Just for testing. Nothing to export.
1185dcf582bf9faeeb974fe1957069ead88321d2bf80b60c25658a49550f62e2
2600hz-archive/whistle
entop_net.erl
%%============================================================================== Copyright 2010 Erlang Solutions Ltd. %% Licensed under the Apache License , Version 2.0 ( the " License " ) ; %% you may not use this file except in compliance with the License. %% You may obtain a copy of the License at %% %% -2.0 %% ...
null
https://raw.githubusercontent.com/2600hz-archive/whistle/1a256604f0d037fac409ad5a55b6b17e545dcbf9/lib/entop-0.0.1/src/entop_net.erl
erlang
============================================================================== you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either ex...
Copyright 2010 Erlang Solutions Ltd. Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(entop_net). -author(''). -include("entop.hrl"). -export([fetch_data/2, reconnect/2]). fetch_data(Node, Module) -> timer:tc...
de19f7db1a5e99fc2e116312234e30c75f2968c69f2e50d6f2eb3598160701d0
pascal-knodel/haskell-craft
AreEqual.hs
-- Are all items in a list equal to each other? module AreEqual where areEqual :: ( Eq t ) => [t] -> Bool areEqual [] = True areEqual [ _ ] = True areEqual ( predecessor : successor : remainingItems ) = predecessor == successor && areEqual ( successor : remainingItems ) GHCi > areEqual [ ] areEqual [ 0...
null
https://raw.githubusercontent.com/pascal-knodel/haskell-craft/c03d6eb857abd8b4785b6de075b094ec3653c968/Examples/%C2%B7%C2%A0Recursion/%C2%B7%20Primitive%20Recursion/Lists/AreEqual.hs
haskell
Are all items in a list equal to each other? True True True False
module AreEqual where areEqual :: ( Eq t ) => [t] -> Bool areEqual [] = True areEqual [ _ ] = True areEqual ( predecessor : successor : remainingItems ) = predecessor == successor && areEqual ( successor : remainingItems ) GHCi > areEqual [ ] areEqual [ 0 ] areEqual [ 0 , 0 ] areEqual [ 0 , 1 ] ...
b537601344fbd1a1a628535a5eac03643e4ca44b3a4dfd36d9d058309e89b71b
startalkIM/ejabberd
ejabberd_regexp.erl
%%%---------------------------------------------------------------------- %%% File : ejabberd_regexp.erl Author : Purpose : Frontend to Re and Regexp OTP modules Created : 8 Dec 2011 by %%% %%% ejabberd , Copyright ( C ) 2002 - 2016 ProcessOne %%% %%% This program is free software; you can redistribut...
null
https://raw.githubusercontent.com/startalkIM/ejabberd/718d86cd2f5681099fad14dab5f2541ddc612c8b/src/ejabberd_regexp.erl
erlang
---------------------------------------------------------------------- File : ejabberd_regexp.erl This program is free software; you can redistribute it and/or License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without ev...
Author : Purpose : Frontend to Re and Regexp OTP modules Created : 8 Dec 2011 by ejabberd , Copyright ( C ) 2002 - 2016 ProcessOne modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the You should have received a copy of th...
0a1419867085b2458062f4d1c4b3150041a99a137531ea9269621b49fa424320
chetmurthy/typpx
no_cand.ml
module Num = struct module Int = struct let (+) = Pervasives.(+) end module Float = struct let (+) = Pervasives.(+.) end end module String = struct let (+) = Pervasives.(^) end module Loaded = struct module Num = Num module String = String external (+) : 'a -> 'a -> 'a = "__OVERLOADED" end ...
null
https://raw.githubusercontent.com/chetmurthy/typpx/a740750b75739e686da49b46ded7db7d6874e108/examples/ppx_overload/tests/no_cand.ml
ocaml
module Num = struct module Int = struct let (+) = Pervasives.(+) end module Float = struct let (+) = Pervasives.(+.) end end module String = struct let (+) = Pervasives.(^) end module Loaded = struct module Num = Num module String = String external (+) : 'a -> 'a -> 'a = "__OVERLOADED" end ...
4c426fdc31217d71cc54ccdf054ce3adfd4adabdbe67697795b8febf0a13c5f3
docker-in-aws/docker-in-aws
info.cljs
(ns swarmpit.component.node.info (:require [material.icon :as icon] [material.component :as comp] [material.component.form :as form] [material.component.panel :as panel] [material.component.list-table-auto :as list] [swarmpit.component.state :as state] ...
null
https://raw.githubusercontent.com/docker-in-aws/docker-in-aws/bfc7e82ac82ea158bfb03445da6aec167b1a14a3/ch16/swarmpit/src/cljs/swarmpit/component/node/info.cljs
clojure
(ns swarmpit.component.node.info (:require [material.icon :as icon] [material.component :as comp] [material.component.form :as form] [material.component.panel :as panel] [material.component.list-table-auto :as list] [swarmpit.component.state :as state] ...
16367c7e47c8928c7d093ff9061c8276b8ff718fe12a84ea9b5fd4ac10b3339f
deadtrickster/cl-events
pooled-executor.lisp
(in-package :cl-events) (defparameter *thread-pool* nil) (defclass pooled-executor () () (:documentation "Executes each event handler in lparallel thread pool")) (defun get-thread-pool () (or *thread-pool* (progn (log:warn "*thread-pool* not set, using default") (setf *thread-pool* (lpara...
null
https://raw.githubusercontent.com/deadtrickster/cl-events/2fdec2dbdef8ba2144139b27a7350d4cedc011a1/src/executors/pooled-executor.lisp
lisp
(in-package :cl-events) (defparameter *thread-pool* nil) (defclass pooled-executor () () (:documentation "Executes each event handler in lparallel thread pool")) (defun get-thread-pool () (or *thread-pool* (progn (log:warn "*thread-pool* not set, using default") (setf *thread-pool* (lpara...
c04e95ce8db10d250c2c8fea6c9bbd3e2ce5fa584bafe9b1ac92f452a4364b21
GaloisInc/pate
TraceTree.hs
| Module : . TraceTree Copyright : ( c ) Galois , Inc 2022 Maintainer : < > Defines the ' TraceTree ' and ' TraceTreeNode ' types used for representing tracing data collected during verification . Tree nodes are labeled with type - level symbols , which are assocated with a...
null
https://raw.githubusercontent.com/GaloisInc/pate/a48c447156d95686c308a6d5ec696464120e0970/src/Pate/TraceTree.hs
haskell
# LANGUAGE GADTs # # LANGUAGE ConstraintKinds # # LANGUAGE RankNTypes # # LANGUAGE OverloadedStrings # TODO: We could expose the error type here with some plumbing | Allowing for lazy evaluation of trace trees importantly, we don't propagate regular status updates to ancestors, otherwise finalizing a child would ca...
| Module : . TraceTree Copyright : ( c ) Galois , Inc 2022 Maintainer : < > Defines the ' TraceTree ' and ' TraceTreeNode ' types used for representing tracing data collected during verification . Tree nodes are labeled with type - level symbols , which are assocated with a...
b75fe5dbd59d7d6aadc306d4dc1bc93f2f5887cf9a389a0f15179157c34ff050
yrashk/erlang
snmpa.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 2004 - 2009 . All Rights Reserved . %% The contents of this file are subject to the Erlang Public License , Version 1.1 , ( the " License " ) ; you may not use this file except in %% compliance with the License. You should have received a copy of the %% Erlang Pub...
null
https://raw.githubusercontent.com/yrashk/erlang/e1282325ed75e52a98d58f5bd9fb0fa27896173f/lib/snmp/src/agent/snmpa.erl
erlang
%CopyrightBegin% compliance with the License. You should have received a copy of the Erlang Public License along with this software. If not, it can be retrieved online at /. basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limita...
Copyright Ericsson AB 2004 - 2009 . All Rights Reserved . The contents of this file are subject to the Erlang Public License , Version 1.1 , ( the " License " ) ; you may not use this file except in Software distributed under the License is distributed on an " AS IS " -module(snmpa). -export([verbosity/2, ...
19330834e156624aa254548b40e0bad1838c9286923facbf0d507edc11d53556
vmware-archive/diegotaskscheduler
diego.clj
(ns diegoscheduler.diego (:require [com.stuartsierra.component :as component] [clojure.core.async :refer [put! <! >! chan alt! go-loop onto-chan]] [clojure.string :as s] [clojure.tools.logging :as log] [cheshire.core :as cheshire] [diegoscheduler.http :as ht...
null
https://raw.githubusercontent.com/vmware-archive/diegotaskscheduler/080fa07815f3e66cdbf1ce804d0944d0561812fc/src/diegoscheduler/diego.clj
clojure
(ns diegoscheduler.diego (:require [com.stuartsierra.component :as component] [clojure.core.async :refer [put! <! >! chan alt! go-loop onto-chan]] [clojure.string :as s] [clojure.tools.logging :as log] [cheshire.core :as cheshire] [diegoscheduler.http :as ht...
305bc15efc974b977e3452a36c648999aa197d73274f20eb7d93a7022a065691
rmarianski/ring-jetty-servlet-adapter
project.clj
(defproject rmarianski/ring-jetty-servlet-adapter "0.0.4" :description "ring jetty adapter that exposes servlet related information in the request map" :url "-jetty-servlet-adapter" :global-vars {*warn-on-reflection* true} :min-lein-version "2.0.0" :dependencies [[ring/ring-servlet "1.2.0"] [...
null
https://raw.githubusercontent.com/rmarianski/ring-jetty-servlet-adapter/bf41e2b6a9924c2e3bc7acc494cb81785ceda9d5/project.clj
clojure
(defproject rmarianski/ring-jetty-servlet-adapter "0.0.4" :description "ring jetty adapter that exposes servlet related information in the request map" :url "-jetty-servlet-adapter" :global-vars {*warn-on-reflection* true} :min-lein-version "2.0.0" :dependencies [[ring/ring-servlet "1.2.0"] [...
93660e048dcf876b96b3ea93725fbefd4b98dcb5c7df653cf4a412bc9570eede
google/ghc-source-gen
pprint_examples.hs
Copyright 2019 Google LLC -- -- Use of this source code is governed by a BSD-style -- license that can be found in the LICENSE file or at -- -source/licenses/bsd -- | Simple example using this package {-# LANGUAGE OverloadedStrings #-} # LANGUAGE NoMonomorphismRestriction # module Main (main) where import GHC.Paths...
null
https://raw.githubusercontent.com/google/ghc-source-gen/74089dd58e55ff6143f54389c517232887baa940/tests/pprint_examples.hs
haskell
Use of this source code is governed by a BSD-style license that can be found in the LICENSE file or at -source/licenses/bsd | Simple example using this package # LANGUAGE OverloadedStrings # var "act" > var "b'" > var "b" > var "c" > a --> tuple [a, a] > a --> a > var "String" > unit > b --> a
Copyright 2019 Google LLC # LANGUAGE NoMonomorphismRestriction # module Main (main) where import GHC.Paths (libdir) import GHC (runGhc) import GHC.Utils.Outputable (Outputable) import GHC.SourceGen main :: IO () main = mapM_ run [test1, test2, test3, test4, test5] where run act = putStrLn "========" >> act ...
b0283b82900e66d853c2bc8605c7360df05b40d49d556c9ea7806642ec5d36ba
inhabitedtype/ocaml-aws
assumeRoleWithSAML.ml
open Types open Aws type input = AssumeRoleWithSAMLRequest.t type output = AssumeRoleWithSAMLResponse.t type error = Errors_internal.t let service = "sts" let signature_version = Request.V4 let to_http service region req = let uri = Uri.add_query_params (Uri.of_string (Aws.Util.of_option_exn (Endpoint...
null
https://raw.githubusercontent.com/inhabitedtype/ocaml-aws/b6d5554c5d201202b5de8d0b0253871f7b66dab6/libraries/sts/lib/assumeRoleWithSAML.ml
ocaml
open Types open Aws type input = AssumeRoleWithSAMLRequest.t type output = AssumeRoleWithSAMLResponse.t type error = Errors_internal.t let service = "sts" let signature_version = Request.V4 let to_http service region req = let uri = Uri.add_query_params (Uri.of_string (Aws.Util.of_option_exn (Endpoint...
0f10f719a97f468d6af940b3d19f962a85e125081a79d07d3881c1acc8c37102
racket/eopl
interp.rkt
#lang eopl ;; interpreter for the CALL-BY-NEED language. (require "lang.rkt") (require "data-structures.rkt") (require "environments.rkt") (require "store.rkt") (require "pairvals.rkt") (provide value-of-program value-of instrument-newref) ;;; exercise: add instrumentation around let and procedure calls, as ;;; i...
null
https://raw.githubusercontent.com/racket/eopl/43575d6e95dc34ca6e49b305180f696565e16e0f/tests/chapter4/call-by-need/interp.rkt
racket
interpreter for the CALL-BY-NEED language. exercise: add instrumentation around let and procedure calls, as in the call-by-reference language. the interpreter ;;;;;;;;;;;;;;;; value-of-operand : Exp * Env -> Ref no deref!
#lang eopl (require "lang.rkt") (require "data-structures.rkt") (require "environments.rkt") (require "store.rkt") (require "pairvals.rkt") (provide value-of-program value-of instrument-newref) value - of - program : Program - > ExpVal (define value-of-program (lambda (pgm) (initialize-store!) ...
2eed05a532c4ea6db2c006643e213286307b97f8cbcbd3e8205e1737fa719eab
Mesabloo/nihil
Record.hs
# LANGUAGE BlockArguments # {-# LANGUAGE OverloadedStrings #-} module Nihil.Syntax.Concrete.Parser.Expression.Record where import Nihil.Syntax.Common (Parser) import Nihil.Syntax.Concrete.Debug import Nihil.Syntax.Concrete.Core import Nihil.Syntax.Concrete.Parser.Enclosed import Nihil.Syntax.Concrete.Parser.Statement...
null
https://raw.githubusercontent.com/Mesabloo/nihil/3821052ca5691a6492b23bd8a46bfe70567d374f/src/parser/Nihil/Syntax/Concrete/Parser/Expression/Record.hs
haskell
# LANGUAGE OverloadedStrings # # SOURCE #
# LANGUAGE BlockArguments # module Nihil.Syntax.Concrete.Parser.Expression.Record where import Nihil.Syntax.Common (Parser) import Nihil.Syntax.Concrete.Debug import Nihil.Syntax.Concrete.Core import Nihil.Syntax.Concrete.Parser.Enclosed import Nihil.Syntax.Concrete.Parser.Statement.FunctionDeclaration import Nihil.S...
f74d4517803d756241a715e9e66f5f049d1f92c4e2c71d7ce02c0f8c84a4cca0
abhay/eunit
fib.erl
-module(fib). -export([fib/1]). -include_lib("eunit/include/eunit.hrl"). fib(0) -> 1; fib(1) -> 1; fib(N) when N > 1 -> fib(N-1) + fib(N-2). fib_test_() -> [?_assert(fib(0) == 1), ?_assert(fib(1) == 1), ?_assert(fib(2) == 2), ?_assert(fib(3) == 3), ?_assert(fib(4) == 5), ?_assert(fib(5) ...
null
https://raw.githubusercontent.com/abhay/eunit/fa9b549955101d6e98d31876e2e44feb96ca4d54/examples/fib.erl
erlang
-module(fib). -export([fib/1]). -include_lib("eunit/include/eunit.hrl"). fib(0) -> 1; fib(1) -> 1; fib(N) when N > 1 -> fib(N-1) + fib(N-2). fib_test_() -> [?_assert(fib(0) == 1), ?_assert(fib(1) == 1), ?_assert(fib(2) == 2), ?_assert(fib(3) == 3), ?_assert(fib(4) == 5), ?_assert(fib(5) ...
ad259a387e545736afd08092b23e1ffc24f66c35f1e6e5e4c394283414cf895a
uxbox/uxbox-backend
users.clj
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 /. ;; Copyright ( c ) 2016 < > (ns uxbox.services.users (:require [clojure.spec :as s] [mount.core :as mount :refer (defstate)]...
null
https://raw.githubusercontent.com/uxbox/uxbox-backend/036c42db8424be3ac34c38be80577ee279141681/src/uxbox/services/users.clj
clojure
--- Retrieve User Profile (own) --- Update User Profile (own) --- Update Password --- Update Photo --- Create User --- Register User --- Password Recover --- Query Helpers --- Attrs Helpers
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 /. Copyright ( c ) 2016 < > (ns uxbox.services.users (:require [clojure.spec :as s] [mount.core :as mount :refer (defstate)] ...
ed689d42b0bf58a935e3682fb115044079c4faed7811fd7d488ac1dab68c9c70
cmr-exchange/cmr-client
search.clj
(ns cmr.client.search "The Clojure implementation of the CMR search client." (:require [cmr.client.base.impl :as base-impl] [cmr.client.base.protocol :as base-api] [cmr.client.common.util :as util] [cmr.client.http.core :as http] [cmr.client.search.impl :as impl] [cmr.client.search.protocol :as ap...
null
https://raw.githubusercontent.com/cmr-exchange/cmr-client/0b4dd4114e3b5ed28fc5b57db0f8dcd8773c1c14/src/clj/cmr/client/search.clj
clojure
Protocols &tc. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Implementation ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ;
(ns cmr.client.search "The Clojure implementation of the CMR search client." (:require [cmr.client.base.impl :as base-impl] [cmr.client.base.protocol :as base-api] [cmr.client.common.util :as util] [cmr.client.http.core :as http] [cmr.client.search.impl :as impl] [cmr.client.search.protocol :as ap...
3c4d0829956dfb33e20983ff339cfcba1d006ed1b43ac088a508f6f2858ca61b
gafiatulin/codewars
WhenGreatestIsLessThanSmallest.hs
-- When greatest is less than smallest -- / module Kata.WhenGreatestIsLessThanSmallest where greatest :: Integer -> Integer -> Integer -> Integer greatest x y n = ((n - 1) `div` (lcm x y)) * lcm x y smallest :: Integer -> Integer -> Integer -> Integer smallest x y n = ((n `div` (lcm x y)) + 1) * lcm x y
null
https://raw.githubusercontent.com/gafiatulin/codewars/535db608333e854be93ecfc165686a2162264fef/src/6%20kyu/WhenGreatestIsLessThanSmallest.hs
haskell
When greatest is less than smallest /
module Kata.WhenGreatestIsLessThanSmallest where greatest :: Integer -> Integer -> Integer -> Integer greatest x y n = ((n - 1) `div` (lcm x y)) * lcm x y smallest :: Integer -> Integer -> Integer -> Integer smallest x y n = ((n `div` (lcm x y)) + 1) * lcm x y
bfa03a67d715cea91a9309539081a5b4c0ff85c023c828d2d18bfeeb452734bc
kowainik/membrain
ValueLevel.hs
-- | All unit tests for runtime values and functions. module Test.Memory.ValueLevel ( unitTests ) where import Data.Ratio ((%)) import Test.Hspec (Spec, describe, it, shouldBe) import qualified Membrain as Mem unitTests :: Spec unitTests = describe "Membrain: Unit tests" $ do unitConversionSpec ...
null
https://raw.githubusercontent.com/kowainik/membrain/c7c3e9ad9b56fbe48677a7a7f5b2e2146cbd8bb1/test/Test/Memory/ValueLevel.hs
haskell
| All unit tests for runtime values and functions.
module Test.Memory.ValueLevel ( unitTests ) where import Data.Ratio ((%)) import Test.Hspec (Spec, describe, it, shouldBe) import qualified Membrain as Mem unitTests :: Spec unitTests = describe "Membrain: Unit tests" $ do unitConversionSpec unwrappingSpec readMemorySpec unitConversionSp...
c845ad443f1761216697ef6dddb9b0c0d5c20dbc8a8c69a1ddbf4c40f1396719
input-output-hk/hydra
UsingRawBytesHex.hs
| Shamelessly stolen from cardan - api ' Cardano . Api . ' module . -- With some minor modifications of also using encodeUtf8 in ' ' instance . module Hydra.Cardano.Api.UsingRawBytesHex where import Hydra.Cardano.Api.Prelude import Data.Aeson (FromJSONKey, ToJSONKey) import qualified Data.Aeson as Aeson import ...
null
https://raw.githubusercontent.com/input-output-hk/hydra/b6371379ffc28994300ff8ba9e7c669a640d759c/hydra-cardano-api/src/Hydra/Cardano/Api/UsingRawBytesHex.hs
haskell
encoding, based on the 'SerialiseAsRawBytes' instance. > deriving (Show, IsString) via (UsingRawBytesHex Blah)
| Shamelessly stolen from cardan - api ' Cardano . Api . ' module . With some minor modifications of also using encodeUtf8 in ' ' instance . module Hydra.Cardano.Api.UsingRawBytesHex where import Hydra.Cardano.Api.Prelude import Data.Aeson (FromJSONKey, ToJSONKey) import qualified Data.Aeson as Aeson import qua...
5ee11f9d8c9b1a5263f0d5d1df5a0b50016b1d737307f24bceedb389a336d307
tommay/pokemon-go
Sort.hs
module Main where import qualified Epic import qualified GameMaster import GameMaster (GameMaster) import qualified MakePokemon import qualified MyPokemon import MyPokemon (MyPokemon) import qualified Pokemon import qualified PokeUtil import qualified Util import qualified Options.Applicative as O...
null
https://raw.githubusercontent.com/tommay/pokemon-go/6b0132f03a1d50ad5513b70fe715e57879dfa597/app/Sort.hs
haskell
module Main where import qualified Epic import qualified GameMaster import GameMaster (GameMaster) import qualified MakePokemon import qualified MyPokemon import MyPokemon (MyPokemon) import qualified Pokemon import qualified PokeUtil import qualified Util import qualified Options.Applicative as O...
92e4566a29465939f24a8a51402c88393661804f115e88aa4a24265d2740e934
kraison/vivace-graph
vivace-graph-client-package.lisp
(in-package #:cl-user) (defpackage #:vivace-graph-client (:use #:cl #:cffi #:bordeaux-threads #:kyoto-persistence #:local-time #:usocket))
null
https://raw.githubusercontent.com/kraison/vivace-graph/6b5b5eca3e2613e48846da326ecf36cd9dcd7ceb/vivace-graph-client-package.lisp
lisp
(in-package #:cl-user) (defpackage #:vivace-graph-client (:use #:cl #:cffi #:bordeaux-threads #:kyoto-persistence #:local-time #:usocket))
0f36e29157e0495a47110610b2eeccb43c3ae3384796d4ddfef7918f6939ecf1
ertugrulcetin/racing-game-cljs
user.cljs
(ns cljs.user "Commonly used symbols for easy access in the ClojureScript REPL during development." (:require [cljs.repl :refer (Error->map apropos dir doc error->str ex-str ex-triage find-doc print-doc pst source)] [clojure.pprint :refer (pprint)] [clojure.string :as...
null
https://raw.githubusercontent.com/ertugrulcetin/racing-game-cljs/490361bd88651d6d03eb3519bed50597e41f98a6/dev/user.cljs
clojure
(ns cljs.user "Commonly used symbols for easy access in the ClojureScript REPL during development." (:require [cljs.repl :refer (Error->map apropos dir doc error->str ex-str ex-triage find-doc print-doc pst source)] [clojure.pprint :refer (pprint)] [clojure.string :as...
e6eedb3dc3fabf68813fe8da6ace59529b8cac327f151dc3e18447a78705bb4c
wadehennessey/wcl
requests2.lisp
-*- Mode : LISP ; Syntax : Common - lisp ; Package : XLIB ; Base : 10 ; Lowercase : Yes -*- ;;; TEXAS INSTRUMENTS INCORPORATED ;;; P.O. BOX 2909 AUSTIN , TEXAS 78769 ;;; Copyright ( C ) 1987 Texas Instruments Incorporated . ;;; ;;; Permission is granted to any individual or institution to use,...
null
https://raw.githubusercontent.com/wadehennessey/wcl/841316ffe06743d4c14b4ed70819bdb39158df6a/src/clx/requests2.lisp
lisp
Syntax : Common - lisp ; Package : XLIB ; Base : 10 ; Lowercase : Yes -*- P.O. BOX 2909 Permission is granted to any individual or institution to use, copy, modify, and distribute this software, provided that this complete copyright and permission notice is maintained, intact, in all copies and supporting ...
TEXAS INSTRUMENTS INCORPORATED AUSTIN , TEXAS 78769 Copyright ( C ) 1987 Texas Instruments Incorporated . Texas Instruments Incorporated provides this software " as is " without (in-package "XLIB") (defun set-input-focus (display focus revert-to &optional time) (declare (type display display) ...
d437c2f58a9f1654fce0dfd483f0ac5a824fc62492527e0f6de88c336a4373da
quil-lang/quilc
cfg.lisp
;;;; cfg.lisp ;;;; Author : (in-package #:cl-quil) (deftype block-name () "The type of object that names blocks." 'symbol) (defclass cfg (transformable) ((entry-point :initarg :entry-point :accessor entry-point :documentation "The program entry point (a BASIC-BLO...
null
https://raw.githubusercontent.com/quil-lang/quilc/6c9d20892cfc71d8814af0526b78b8215365b512/src/cfg.lisp
lisp
cfg.lisp Sanity check. Associate LABEL-NAME -> BLK-NAME. An "outgoing" edge that points nowhere. This is equivalent to a HALT and signals the end of an execution path. An unconditional edge to target block (a BASIC-BLOCK). A conditional edge with a bit condition represented by a a false target (bit = 0) block ...
Author : (in-package #:cl-quil) (deftype block-name () "The type of object that names blocks." 'symbol) (defclass cfg (transformable) ((entry-point :initarg :entry-point :accessor entry-point :documentation "The program entry point (a BASIC-BLOCK).") (blocks :...
a4f0f4ac0ad9afd9b9da1939be94c1e4979ca678fd90babdd1944e7f0e139cfc
shop-planner/shop3
package.lisp
(defpackage :shop3-openstacks (:nicknames #:shop-openstacks #:shop2-openstacks) (:intern #:divergence) (:use #:common-lisp #:shop3))
null
https://raw.githubusercontent.com/shop-planner/shop3/ba429cf91a575e88f28b7f0e89065de7b4d666a6/shop3/examples/openstacks-adl/package.lisp
lisp
(defpackage :shop3-openstacks (:nicknames #:shop-openstacks #:shop2-openstacks) (:intern #:divergence) (:use #:common-lisp #:shop3))
02a90d61b4a43c2490165f04614ca7b9f1812eba54b69fe79f43a674bde7260a
esl/erlang-web
test.erl
#!/usr/bin/env escript The contents of this file are subject to the Erlang Web Public License , Version 1.0 , ( the " License " ) ; you may not use this file except in %% compliance with the License. You should have received a copy of the Erlang Web Public License along with this software . If not , it can be %%...
null
https://raw.githubusercontent.com/esl/erlang-web/2e5c2c9725465fc5b522250c305a9d553b3b8243/bin/test.erl
erlang
compliance with the License. You should have received a copy of the retrieved via the world wide web at -consulting.com/. basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. ---------------------------------...
#!/usr/bin/env escript The contents of this file are subject to the Erlang Web Public License , Version 1.0 , ( the " License " ) ; you may not use this file except in Erlang Web Public License along with this software . If not , it can be Software distributed under the License is distributed on an " AS IS " ...
ff1f35f6b44f964daeb5b85731d12bb03f6a59b6589f6cd847ee0c2d996c721d
ghcjs/ghcjs-examples
Engine.hs
# LANGUAGE CPP # module Engine where import Prelude hiding ((!!)) import GHCJS.DOM.Document (documentCreateElement, documentGetElementById, documentGetBody, documentGetDocumentElement) import GHCJS.DOM.HTMLElement (htmlElementInsertAdjacentElement, htmlElementSetInnerHTML, htmlElementInse...
null
https://raw.githubusercontent.com/ghcjs/ghcjs-examples/217b7fd3816f57634977beac711452704c3ea688/webkit-sodium/src/Engine.hs
haskell
Convert (game) world to/from screen co-ordinates. Y is inverted | Get the mouse position relative to the top-left corner of the specified HTML element. doc.body | Get the top/left position of this element relative to the page. The game logic expects alternating down-up-down-up, but the browser can produce bad s...
# LANGUAGE CPP # module Engine where import Prelude hiding ((!!)) import GHCJS.DOM.Document (documentCreateElement, documentGetElementById, documentGetBody, documentGetDocumentElement) import GHCJS.DOM.HTMLElement (htmlElementInsertAdjacentElement, htmlElementSetInnerHTML, htmlElementInse...
d9c1739ae6799fb7a3d0f9ec25917d15021cd4dba80cbeee405e284ad46ffd1b
binsec/haunted
criteriaAsDefault.mli
(**************************************************************************) This file is part of BINSEC . (* *) Copyright ( C ) 2016 - 2019 (* VERIMAG...
null
https://raw.githubusercontent.com/binsec/haunted/7ffc5f4072950fe138f53fe953ace98fff181c73/src/dynamic/dse/path_exploration/criteriaAsDefault.mli
ocaml
************************************************************************ VERIMAG you can redistribute it an...
This file is part of BINSEC . Copyright ( C ) 2016 - 2019 Lesser General Public License as published by the Free Software Foundation , version 2.1 . See the GNU Le...
c71c0ffdea2c1bd79228abf85ef1d17280cbd96a3a3c271f2949ede099653122
goncalotomas/FMKe
fmke_driver_ets.erl
-module(fmke_driver_ets). -behaviour(gen_fmke_kv_driver). -include("fmke.hrl"). %% gen_fmke_driver exports -export([ start_transaction/1, commit_transaction/2, get/2, put/2 ]). start_transaction(_Opts) -> {ok, []}. commit_transaction(_Context, _Opts) -> ok. get(Keys, Context) -> {ok, DataMode...
null
https://raw.githubusercontent.com/goncalotomas/FMKe/654d3211ef57d841540e58033a397ce0f3dee0f7/src/fmke_driver_ets.erl
erlang
gen_fmke_driver exports
-module(fmke_driver_ets). -behaviour(gen_fmke_kv_driver). -include("fmke.hrl"). -export([ start_transaction/1, commit_transaction/2, get/2, put/2 ]). start_transaction(_Opts) -> {ok, []}. commit_transaction(_Context, _Opts) -> ok. get(Keys, Context) -> {ok, DataModel} = application:get_env(?A...
a0f95e56c4b37635460d3407f305200c0290c8597b0f525b7fa8049b80e6450c
Javran/advent-of-code
Day11.hs
module Javran.AdventOfCode.Y2016.Day11 ( ) where import Control.Applicative import Control.Lens import Control.Monad import Data.Bits import Data.Char import Data.Foldable import qualified Data.IntMap.Strict as IM import Data.List import qualified Data.List.NonEmpty as NE import qualified Data.Map.Strict as M import...
null
https://raw.githubusercontent.com/Javran/advent-of-code/676ef13c2f9d341cf7de0f383335a1cf577bd73d/src/Javran/AdventOfCode/Y2016/Day11.hs
haskell
module Javran.AdventOfCode.Y2016.Day11 ( ) where import Control.Applicative import Control.Lens import Control.Monad import Data.Bits import Data.Char import Data.Foldable import qualified Data.IntMap.Strict as IM import Data.List import qualified Data.List.NonEmpty as NE import qualified Data.Map.Strict as M import...
33e03352ee82165236e4f08225bedbfa36e57a568e0c09e01cbebc894a69edbf
danieljharvey/mimsa
Bind.hs
{-# LANGUAGE OverloadedStrings #-} module Language.Mimsa.Actions.Modules.Bind ( bindModule, addBindingToModule, ) where import Data.Map.Strict (Map) import Data.Text (Text) import qualified Language.Mimsa.Actions.Modules.RunTests as Actions import qualified Language.Mimsa.Actions.Modules.Typecheck as Actions ...
null
https://raw.githubusercontent.com/danieljharvey/mimsa/e6b177dd2c38e8a67d6e27063ca600406b3e6b56/compiler/src/Language/Mimsa/Actions/Modules/Bind.hs
haskell
# LANGUAGE OverloadedStrings # add/update a module typecheck it to make sure it's not silly store the name/hash pair and save the module data in the store display messages depending on whether this is new or update return stuff add our new definition check everything still makes sense run tests output what's h...
module Language.Mimsa.Actions.Modules.Bind ( bindModule, addBindingToModule, ) where import Data.Map.Strict (Map) import Data.Text (Text) import qualified Language.Mimsa.Actions.Modules.RunTests as Actions import qualified Language.Mimsa.Actions.Modules.Typecheck as Actions import qualified Language.Mimsa.Act...
64cae7b408a8eecebbc40ad8c0b09c32fafa821601091ca8bbbc453f522cc993
damn/cdq
impl_generated.clj
maps each layer tiles only from one spritesheet ! else does nt work ! ; :details-sprite-idx from details-sheet and so on rotation destroys order of room tiles when a 2x2 cells form something (defn- addroom [grid roomname] (let [abc (remove false? (map #(is-5x5-walls-entrance? % grid) ...
null
https://raw.githubusercontent.com/damn/cdq/5093dbdba91c445e403f53ce96ead05d5ed8262b/src/game/maps/impl_generated.clj
clojure
:details-sprite-idx from details-sheet and so on _ (print-grid roomgrid) can not access tileIds directly in the next step because tiledmap is not rotated... TODO postprocessing for cellular/cave in a function? -> and use everywhere where postprocessing is used? and there is after scaling (mark undefined cells) ...
maps each layer tiles only from one spritesheet ! else does nt work ! rotation destroys order of room tiles when a 2x2 cells form something (defn- addroom [grid roomname] (let [abc (remove false? (map #(is-5x5-walls-entrance? % grid) (posis grid))) _ ...
998154508804acdb39e220a549c227ad06628c73eb180a309ed72956b1df6f50
s-expressionists/Cleavir
replace.lisp
(cl:in-package #:cleavir-ast-transformations) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; ;;; Replacing a node in an AST. ;;; Given an AST and a FUNCTION , the FUNCTION is applied to each node of the AST . If on some node N , the function returns NIL then N is cloned . Otherwis...
null
https://raw.githubusercontent.com/s-expressionists/Cleavir/e0293780d356a9d563af9abf9317019f608b4e1d/AST-transformations/replace.lisp
lisp
Replacing a node in an AST. should replace N in the copy.
(cl:in-package #:cleavir-ast-transformations) Given an AST and a FUNCTION , the FUNCTION is applied to each node of the AST . If on some node N , the function returns NIL then N is cloned . Otherwise , the return value of FUNCTION is a node that (defun reinitialize (instance keyword replacement) (reinitia...
2243717e90b5345d8a9cf23ba7f741710cc7b23e126757b0f7b52a5f0d000111
Opetushallitus/ataru
client.clj
(ns ataru.valintaperusteet.client (:require [ataru.cache.cache-service :as cache] [ataru.cas.client :as cas] [ataru.config.url-helper :as url] [cheshire.core :as json] [schema.core :as s])) (s/defschema Valintatapajono {:oid s/Str :name s/Str :priority...
null
https://raw.githubusercontent.com/Opetushallitus/ataru/2d8ef1d3f972621e301a3818567d4e11219d2e82/src/clj/ataru/valintaperusteet/client.clj
clojure
(ns ataru.valintaperusteet.client (:require [ataru.cache.cache-service :as cache] [ataru.cas.client :as cas] [ataru.config.url-helper :as url] [cheshire.core :as json] [schema.core :as s])) (s/defschema Valintatapajono {:oid s/Str :name s/Str :priority...
fe462de287f18c61b3e3521232b105782a83418fe49f55f165dda5e60e0562de
jaredly/reason-language-server
matching.ml
(***********************************************************************) (* *) (* OCaml *) (* *) , projet ...
null
https://raw.githubusercontent.com/jaredly/reason-language-server/ce1b3f8ddb554b6498c2a83ea9c53a6bdf0b6081/ocaml_typing/402/matching.ml
ocaml
********************************************************************* OCaml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et en Automatique . All rights reserved . This file is distributed under the terms of the Q Public License version 1.0 . open Misc open Asttypes open Primitive...
89fa5d288f6f9c4ab1539290e4beded4baa922a7da827a49130dc2f2413d6ba0
input-output-hk/project-icarus-importer
BListener.hs
# LANGUAGE AllowAmbiguousTypes # {-# LANGUAGE RankNTypes #-} | Blockchain listener for Explorer . -- Callbacks on application and rollback. module Pos.Explorer.BListener ( runExplorerBListener , ExplorerBListener -- * Instances -- ** MonadBListener (ExplorerBListener m) -...
null
https://raw.githubusercontent.com/input-output-hk/project-icarus-importer/36342f277bcb7f1902e677a02d1ce93e4cf224f0/explorer/src/Pos/Explorer/BListener.hs
haskell
# LANGUAGE RankNTypes # Callbacks on application and rollback. * Instances ** MonadBListener (ExplorerBListener m) * Required for tests * Required for migration * Required for test util -------------------------------------------------------------------------- Declarations ------------------------------...
# LANGUAGE AllowAmbiguousTypes # | Blockchain listener for Explorer . module Pos.Explorer.BListener ( runExplorerBListener , ExplorerBListener , epochPagedBlocksMap , findEpochMaxPages , createPagedHeaderHashesPair ) where import Nub (ordNub) import Uni...
511501985ba18ff5b928b6dce68849d039668f11a446066487116026e9d3c4c6
tibbe/ekg-core
Array.hs
# LANGUAGE BangPatterns , MagicHash , , UnboxedTuples # -- | Zero based arrays. -- -- Note that no bounds checking are performed. module Data.Array ( Array , length , index , fromList , toList ) where import Control.Monad.ST import GHC.Exts (Array#, Int(..), MutableArray#, indexArray#, newArr...
null
https://raw.githubusercontent.com/tibbe/ekg-core/c3d3616a84568cac7ab9c5a8760650ee344a0c05/Data/Array.hs
haskell
| Zero based arrays. Note that no bounds checking are performed. | Smart constructor | Smart constructor # INLINE new #
# LANGUAGE BangPatterns , MagicHash , , UnboxedTuples # module Data.Array ( Array , length , index , fromList , toList ) where import Control.Monad.ST import GHC.Exts (Array#, Int(..), MutableArray#, indexArray#, newArray#, sizeofArray#, sizeofMutableArray#, unsafeFreezeArray...
a7bcce5fa6b06972016487acaf1179bd0e594bea084c4cb607dd81a6287f23d4
vmchale/command-line-tweeter
API.hs
{-# LANGUAGE OverloadedStrings #-} | Module containing the functions directly dealing with twitter 's API . Most functions in this module have two versions - one which takes a path to a TOML file containing api keys / secrets and tokens / secrets , the other takes api keys / secrets and tokens / secrets as an argume...
null
https://raw.githubusercontent.com/vmchale/command-line-tweeter/53314340c5bc7dda4de78072790c2c36e180c0ca/src/Web/Tweet/API.hs
haskell
# LANGUAGE OverloadedStrings # | Get tweets (text only) for some user | Get all tweets by some user | tweet, given a `Tweet` and a `Config` containing necessary data to sign the request. | tweet, given a `Tweet` and path to credentials. Return id of posted tweet. | Gets user profile with max_id set. | Gets user p...
| Module containing the functions directly dealing with twitter 's API . Most functions in this module have two versions - one which takes a path to a TOML file containing api keys / secrets and tokens / secrets , the other takes api keys / secrets and tokens / secrets as an argument . module Web.Tweet.API where im...
935d1ea08e3a0f0281f0d1a3b4f9307b0b7a0bd68e9e64e8c713a42f81fae894
johnyob/dromedary
typedtree.ml
(*****************************************************************************) (* *) Dromedary (* *) ...
null
https://raw.githubusercontent.com/johnyob/dromedary/18391e5d56b3442f4a44af5dd73e5e5e1e15eb6b/src/typing/typedtree.ml
ocaml
*************************************************************************** ...
Dromedary , University of Cambridge Copyright 2021 . All rights reserved . This file is distributed under the terms of the MIT open! Import open Parsing.Ast_types op...
9eb35decfd8acb38b18c527d3ae9396868b370ea281b6664fca9944d929e5f3f
rd--/hsc3
unk-laser-bubble.hs
laser bubble ; -users/msg14775.html let n = 8 laser_bubble _ = let xr = dxrand dinf (mce [0.1,0.2,0.3,0.4,0.5]) lf = dstutter 2 xr du = duty ar lf 0 DoNothing lf tr = abs (hpz1 du) `greater_than` 0 ph = sweep ar tr (1 / du) in linExp ph 0 1 (rand 50 100) (rand 5...
null
https://raw.githubusercontent.com/rd--/hsc3/d1fe39a4f351b426db58517e57e202f5fecaaf2f/Help/Graph/unk-laser-bubble.hs
haskell
laser bubble ; -users/msg14775.html let n = 8 laser_bubble _ = let xr = dxrand dinf (mce [0.1,0.2,0.3,0.4,0.5]) lf = dstutter 2 xr du = duty ar lf 0 DoNothing lf tr = abs (hpz1 du) `greater_than` 0 ph = sweep ar tr (1 / du) in linExp ph 0 1 (rand 50 100) (rand 5...
075b1a2518dcc060bdcb91b870caf99d64b4092fd113ffced27693ff190ddded
scarvalhojr/haskellbook
section26.10.hs
# LANGUAGE InstanceSigs # import Control.Monad.IO.Class (MonadIO, liftIO) import Control.Monad.Trans.Class (MonadTrans, lift) import Control.Monad (liftM) 1 . newtype IdentityT m a = IdentityT { runIdentityT :: m a } deriving (Eq, Show) instance (Functor m) => Functor (IdentityT m) where fmap ...
null
https://raw.githubusercontent.com/scarvalhojr/haskellbook/6016a5a78da3fc4a29f5ea68b239563895c448d5/chapter26/section26.10.hs
haskell
# LANGUAGE InstanceSigs # import Control.Monad.IO.Class (MonadIO, liftIO) import Control.Monad.Trans.Class (MonadTrans, lift) import Control.Monad (liftM) 1 . newtype IdentityT m a = IdentityT { runIdentityT :: m a } deriving (Eq, Show) instance (Functor m) => Functor (IdentityT m) where fmap ...
bdb4de10d83343786b694af534ab2bf56c00e357534e809c57a269e21052ab36
fossas/fossa-cli
AtomicState.hs
# LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE UndecidableInstances # | A carrier for the AtomicState effect that utilizes an ' IORef ' for atomic -- state updates module Control.Carrier.AtomicState ( AtomicStateC (AtomicStateC), runAtomicState, module X, ) where import Control.Algebra import Control.Carr...
null
https://raw.githubusercontent.com/fossas/fossa-cli/efc29b4f9c874e338f0b5a7d1c5b13cb9543156f/src/Control/Carrier/AtomicState.hs
haskell
state updates
# LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE UndecidableInstances # | A carrier for the AtomicState effect that utilizes an ' IORef ' for atomic module Control.Carrier.AtomicState ( AtomicStateC (AtomicStateC), runAtomicState, module X, ) where import Control.Algebra import Control.Carrier.Lift import C...
5b4b69afad772e7e90263f4ce48c6ce8736c9adecb51c1c5810bd8dfe2dcb639
palf/haskell-sdl2-examples
Rendering.hs
module Lesson12.Rendering ( renderWorld ) where import Lesson12.Types import qualified SDL import Control.Monad.IO.Class (MonadIO) import SDL (($=)) renderWorld :: (MonadIO m) => SDL.Renderer -> SDL.Texture -> World -> m () renderWorld r t w = do SDL.clear r modifyTexture t w SDL.copy r t Nothing Nothing...
null
https://raw.githubusercontent.com/palf/haskell-sdl2-examples/3b4af6eea5ed362ec7941331449ac64c8f31009e/examples/lesson12/src/Lesson12/Rendering.hs
haskell
module Lesson12.Rendering ( renderWorld ) where import Lesson12.Types import qualified SDL import Control.Monad.IO.Class (MonadIO) import SDL (($=)) renderWorld :: (MonadIO m) => SDL.Renderer -> SDL.Texture -> World -> m () renderWorld r t w = do SDL.clear r modifyTexture t w SDL.copy r t Nothing Nothing...
f43d68750cb1ebdd926874878ec8743f735bd9b122f11d5c7363ac58afa2874b
Viasat/halite
md_outline.clj
Copyright ( c ) 2022 Viasat , Inc. Licensed under the MIT license (ns com.viasat.halite.doc.md-outline (:require [com.viasat.halite.doc.utils :as utils])) (set! *warn-on-reflection* true) (defn produce-outline [{:keys [tutorials how-tos explanations tag-def-map tutorial-filename ...
null
https://raw.githubusercontent.com/Viasat/halite/5a434fa2276f5f2654c4d91045595ae5bbc6580e/src/com/viasat/halite/doc/md_outline.clj
clojure
Copyright ( c ) 2022 Viasat , Inc. Licensed under the MIT license (ns com.viasat.halite.doc.md-outline (:require [com.viasat.halite.doc.utils :as utils])) (set! *warn-on-reflection* true) (defn produce-outline [{:keys [tutorials how-tos explanations tag-def-map tutorial-filename ...
8138bb02a7dde2a1322393814fb1171819400fbca6259c9da161a31857dad606
DestyNova/advent_of_code_2021
Part2.hs
module Main where main = do txt <- lines <$> readFile "input.txt" let oxygen = fromBinary $ head $ filterValues (>=) 0 txt let scrubber = fromBinary $ head $ filterValues (<) 0 txt let lifeSupport = oxygen * scrubber print lifeSupport filterValues p i xs | i >= length (head xs) = xs | le...
null
https://raw.githubusercontent.com/DestyNova/advent_of_code_2021/a9016bb6a4aacc804b508c5f041b14483b985418/day3/Part2.hs
haskell
module Main where main = do txt <- lines <$> readFile "input.txt" let oxygen = fromBinary $ head $ filterValues (>=) 0 txt let scrubber = fromBinary $ head $ filterValues (<) 0 txt let lifeSupport = oxygen * scrubber print lifeSupport filterValues p i xs | i >= length (head xs) = xs | le...
8ecbd62802a0067e759328d4d7f6ac7f1e49863c000d5a731bec12380e4d10f4
janestreet/async_websocket
connection_close_reason.mli
open! Core type t = | Normal_closure * 1000 indicates a normal closure , meaning that the purpose for which the connection was established has been fulfilled . 1000 indicates a normal closure, meaning that the purpose for which the connection was established has been fulfilled. *) | E...
null
https://raw.githubusercontent.com/janestreet/async_websocket/4300992c15f5cbc7b6eac64a04b74ffec7009593/src/connection_close_reason.mli
ocaml
* Reserved. The specific meaning might be defined in the future.
open! Core type t = | Normal_closure * 1000 indicates a normal closure , meaning that the purpose for which the connection was established has been fulfilled . 1000 indicates a normal closure, meaning that the purpose for which the connection was established has been fulfilled. *) | E...
3cc67d33f05930dba1382ece7c1685e20f887d92486a5bc0e3a2e3613c4b8d0d
vikram/lisplibraries
dataview.lisp
(in-package :weblocks) (export '(data data-view data-view-field data-scaffold text-presentation highlight-regex-matches)) ;;; Data view (defclass data-view (view) () (:documentation "A view designed to present data to the user.")) ;;; Data view field (defclass data-view-field (inline-view-field) ((presenta...
null
https://raw.githubusercontent.com/vikram/lisplibraries/105e3ef2d165275eb78f36f5090c9e2cdd0754dd/site/weblocks-stable/src/views/dataview.lisp
lisp
Data view Data view field Make scaffolding system happy Presentation Custom view caption Implement rendering protocol
(in-package :weblocks) (export '(data data-view data-view-field data-scaffold text-presentation highlight-regex-matches)) (defclass data-view (view) () (:documentation "A view designed to present data to the user.")) (defclass data-view-field (inline-view-field) ((presentation :initform (make-instance 'tex...
d34200d969573d661bafec1c9a49019a316754b55d909aa4a4e1be0c36767b06
bhauman/devcards
utils.cljs
(ns devcards.util.utils (:require [goog.object :as gobj] [cljs.pprint :as pprint] [react]) (:require-macros [devcards.util.utils])) ;; this is a reference (def react-holder react) (defn html-env? [] (if-let [doc js/goog.global.document] (gobj/get doc "write"))) (defn node-env? [] (not (nil? goo...
null
https://raw.githubusercontent.com/bhauman/devcards/65caa84c9438dd8bdf8cd21964e6033b1a22c178/src/devcards/util/utils.cljs
clojure
this is a reference this is currently only to handle the
(ns devcards.util.utils (:require [goog.object :as gobj] [cljs.pprint :as pprint] [react]) (:require-macros [devcards.util.utils])) (def react-holder react) (defn html-env? [] (if-let [doc js/goog.global.document] (gobj/get doc "write"))) (defn node-env? [] (not (nil? goog/nodeGlobalRequire))) ...
558befb8eb13ee4d18b40958b0fcb7487197647cb1b7562ce060897dcb43d223
f-o-a-m/kepler
List.hs
# LANGUAGE NoImplicitPrelude # module Tendermint.SDK.BaseApp.Store.List ( List , makeList , makeFullStoreKey , append , delete , deleteWhen , foldl , toList , length , elemIndex , (!!) ) where import Control.Lens (from, iso, to, view, ...
null
https://raw.githubusercontent.com/f-o-a-m/kepler/6c1ad7f37683f509c2f1660e3561062307d3056b/hs-abci-sdk/src/Tendermint/SDK/BaseApp/Store/List.hs
haskell
the list looks like [] the list looks like (? : as) the list looks like (a : as) the list looks like (b : as) | Delete an element whenever the predicate evaluates to 'True' | View the 'List' as a 'List'. ------------------------------------------------------------------------------ ^ previous index ^ current in...
# LANGUAGE NoImplicitPrelude # module Tendermint.SDK.BaseApp.Store.List ( List , makeList , makeFullStoreKey , append , delete , deleteWhen , foldl , toList , length , elemIndex , (!!) ) where import Control.Lens (from, iso, to, view, ...
bc2800c125d1cf458e07606304a26b739afd3cb6dd1b72466011ee51310e000a
fortytools/holumbus
DaemonInterfaceWithFS.hs
-- ---------------------------------------------------------------------------- | Module : Holumbus . MapReduce . DaemonInterface Copyright : Copyright ( C ) 2009 License : MIT Maintainer : ( ) Stability : experimental Portability : portable Version : 0.1 Modul...
null
https://raw.githubusercontent.com/fortytools/holumbus/4b2f7b832feab2715a4d48be0b07dca018eaa8e8/mapreduce/source/Holumbus/MapReduce/DaemonInterfaceWithFS.hs
haskell
---------------------------------------------------------------------------- ---------------------------------------------------------------------------- * operations ---------------------------------------------------------------------------- -----------------------------------------------------------------------...
| Module : Holumbus . MapReduce . DaemonInterface Copyright : Copyright ( C ) 2009 License : MIT Maintainer : ( ) Stability : experimental Portability : portable Version : 0.1 Module : Holumbus.MapReduce.DaemonInterface Copyright : Copyright (C) 2009 Seb...
04aa84f25b0c48524955bcb5d29f1cff2455820a0176b5a832f1fb2c630e746d
craff/pacomb
prio.ml
(* classical calculator example, with parameters priority level *) The three levels of priorities type p = Atom | Prod | Sum (* for printing, we provide a function to convert priorities to string *) let%parser rec This includes each priority level in the next one expr p = Atom < Prod < Sum (* all...
null
https://raw.githubusercontent.com/craff/pacomb/3e83f56bc483f6b9c495ae91d773aa9b484eb321/benchmarks/calc/prio.ml
ocaml
classical calculator example, with parameters priority level for printing, we provide a function to convert priorities to string all other rule are selected by their priority level
The three levels of priorities type p = Atom | Prod | Sum let%parser rec This includes each priority level in the next one expr p = Atom < Prod < Sum ; (p=Atom) (x::FLOAT) => x ; (p=Atom) '(' (e::expr Sum) ')' => e ; (p=Prod) (x::expr Pro...
a039fbc41b85502b11c40ac4869d0365b675977e3070b9180ea257e0aa94d8f4
ijvcms/chuanqi_dev
drop_lib.erl
%%%------------------------------------------------------------------- @author admin ( C ) 2016 , < COMPANY > %%% @doc %%% %%% @end Created : 01 . 九月 2016 上午11:12 %%%------------------------------------------------------------------- -module(drop_lib). -author("admin"). -include("common.hrl"). -include("record....
null
https://raw.githubusercontent.com/ijvcms/chuanqi_dev/7742184bded15f25be761c4f2d78834249d78097/server/trunk/server/src/business/drop/drop_lib.erl
erlang
------------------------------------------------------------------- @doc @end ------------------------------------------------------------------- API 跨服掉落 物品掉落列表 装备掉落的列表 物品投保检测 跨服检测 发送掉落公告 发送掉落邮件 ************************************************************ 内部函数 *********************************************...
@author admin ( C ) 2016 , < COMPANY > Created : 01 . 九月 2016 上午11:12 -module(drop_lib). -author("admin"). -include("common.hrl"). -include("record.hrl"). -include("db_record.hrl"). -include("proto.hrl"). -include("cache.hrl"). -include("config.hrl"). -include("notice_config.hrl"). -include("language_config.hrl...
276e6d871898e83e0f8d0422e62431f132473fffa43735f9fdaf9765e805924e
UnNetHack/pinobot
Join.hs
{-# LANGUAGE OverloadedStrings #-} import qualified Data.Text as T import IRC.Types import System.Environment main = do [channel] <- getArgs (_, send) <- connectToBot "127.0.0.1" 27315 send $ Join $ T.pack channel
null
https://raw.githubusercontent.com/UnNetHack/pinobot/55cdcb224191d9ac16a486dee6099a5baa04b177/commands/Join.hs
haskell
# LANGUAGE OverloadedStrings #
import qualified Data.Text as T import IRC.Types import System.Environment main = do [channel] <- getArgs (_, send) <- connectToBot "127.0.0.1" 27315 send $ Join $ T.pack channel
29c815b34ce0980a0b6a43011f01ed8ab4835f584a5183b33392f6fb556470b1
flyspeck/flyspeck
vectors.ml
(* ========================================================================= *) Real vectors in Euclidean space , and elementary linear algebra . (* *) ( c ) Copyright , 1998 - 2008 (* ========...
null
https://raw.githubusercontent.com/flyspeck/flyspeck/05bd66666b4b641f49e5131a37830f4881f39db9/azure/hol-light-nat/Multivariate/vectors.ml
ocaml
========================================================================= =========================================================================
Real vectors in Euclidean space , and elementary linear algebra . ( c ) Copyright , 1998 - 2008 include Vector4 print_endline "vectors.ml loaded"
5bfd2dc56452a85a5cbcba625e8c9c3a6496a77937d61b55313c1b41c8c0b7a0
coccinelle/coccinelle
command_line.mli
* This file is part of Coccinelle , licensed under the terms of the GPL v2 . * See copyright.txt in the Coccinelle source code for more information . * The Coccinelle source code can be obtained at * This file is part of Coccinelle, licensed under the terms of the GPL v2. * See copyright.txt in the Cocci...
null
https://raw.githubusercontent.com/coccinelle/coccinelle/57cbff0c5768e22bb2d8c20e8dae74294515c6b3/parsing_cocci/command_line.mli
ocaml
* This file is part of Coccinelle , licensed under the terms of the GPL v2 . * See copyright.txt in the Coccinelle source code for more information . * The Coccinelle source code can be obtained at * This file is part of Coccinelle, licensed under the terms of the GPL v2. * See copyright.txt in the Cocci...
836ed84e33cd890551a6c9f813058767a022de38dac380c58355f1192a9e0459
HaskellForCats/HaskellForCats
ch3Types.hs
module CH3types where import Dada123 mult x y z = x * y * z 1:00 - Types as a collections of values - : : has type - - types are infered - list is a sequence of values of the same type 6:00 - - [ 1,2,3 ] [ Int ] -- > : t [ 1,2,3 ] ...
null
https://raw.githubusercontent.com/HaskellForCats/HaskellForCats/2d7a15c0cdaa262c157bbf37af6e72067bc279bc/MenaBeginning/Ch002-Ch03/ch3Types.hs
haskell
> : t [ 1,2,3 ] > : t [ " 1","2","3 " ] > : t [ " 1","2","3"],["a","b","c " ] > : t [ [ " 1","2","3"],["a","b","c " ] ] > : t ( " a",True,1 ) > :t [1,2,3] > :t ["1","2","3"] > :t ["1","2","3"],["a","b","c"] > :t [["1","2","3"],["a","b","c"]] > :t ("a",True,1)
module CH3types where import Dada123 mult x y z = x * y * z 1:00 - Types as a collections of values - : : has type - - types are infered - list is a sequence of values of the same type 6:00 - - [ 1,2,3 ] [ Int ] [ 1,2,3 ] : : t = > ...
967fc48d18fbc3e7fda1278fabc36c2025d3333d93e254eaa6a75730025f1da5
mhuebert/re-db
local.cljc
(ns re-db.notebooks.local) ;; demonstration of using re-db with local persistence
null
https://raw.githubusercontent.com/mhuebert/re-db/0a1d0ad4557451c8943954b3b92e0cbc1e2fedab/src/notebooks/re_db/notebooks/local.cljc
clojure
demonstration of using re-db with local persistence
(ns re-db.notebooks.local)
214bd1f65a0aa6f1bfb537bd12bbb5e7b83c1309cdae1709870ca50208fbb1ae
lispbuilder/lispbuilder
cocoahelper.lisp
;;(require 'cffi) (defpackage :lispbuilder-sdl-cocoahelper (:use :common-lisp :cffi)) (in-package :lispbuilder-sdl-cocoahelper) (pushnew (merge-pathnames (pathname "cocoahelper/") (asdf:component-pathname (asdf:find-system :cocoahelper))) *foreign-library-directories*) (pushnew (merge-pathnames ...
null
https://raw.githubusercontent.com/lispbuilder/lispbuilder/589b3c6d552bbec4b520f61388117d6c7b3de5ab/lispbuilder-sdl/cocoahelper/cocoahelper.lisp
lisp
(require 'cffi)
(defpackage :lispbuilder-sdl-cocoahelper (:use :common-lisp :cffi)) (in-package :lispbuilder-sdl-cocoahelper) (pushnew (merge-pathnames (pathname "cocoahelper/") (asdf:component-pathname (asdf:find-system :cocoahelper))) *foreign-library-directories*) (pushnew (merge-pathnames (pathname "cocoahe...
d9f4701e6c3c4b0780a49e84099b80f504166487e7f607641bada5cda47a86be
jobjo/popper
log.mli
type t val empty : t val add : t -> t -> t val pp : Format.formatter -> t -> unit val of_pp : (Format.formatter -> unit) -> t
null
https://raw.githubusercontent.com/jobjo/popper/33da372946d1d842f75994e086fa81c8cf62986e/src/lib/log.mli
ocaml
type t val empty : t val add : t -> t -> t val pp : Format.formatter -> t -> unit val of_pp : (Format.formatter -> unit) -> t
bb5d038b983f2925ce9e11ce94301b777b9e159afe1d6822db6bfd01635c2f57
kayceesrk/ocaml5-tutorial
fib.ml
let n = try int_of_string Sys.argv.(1) with _ -> 10 let rec fib n = if n < 2 then 1 else fib (n - 1) + fib (n - 2) let main () = let r = fib n in Printf.printf "fib(%d) = %d\n%!" n r let _ = main ()
null
https://raw.githubusercontent.com/kayceesrk/ocaml5-tutorial/36989cd5ffe42d7fc0b2710443b612f27bc9af5d/src/fib.ml
ocaml
let n = try int_of_string Sys.argv.(1) with _ -> 10 let rec fib n = if n < 2 then 1 else fib (n - 1) + fib (n - 2) let main () = let r = fib n in Printf.printf "fib(%d) = %d\n%!" n r let _ = main ()
7bf737b10a9fdeaffca9e0500412fcb88a0c769421626ddcbf4f9522c121fe28
40ants/ci
ci.lisp
(defpackage #:40ants-ci/ci (:use #:cl) (:import-from #:40ants-ci/jobs/linter) (:import-from #:40ants-ci/jobs/critic) (:import-from #:40ants-ci/jobs/run-tests #:run-tests) (:import-from #:40ants-ci/jobs/docs #:build-docs) (:import-from #:40ants-ci/workflow #:de...
null
https://raw.githubusercontent.com/40ants/ci/f8de02181e78a610d928187c7fd642dac352560d/src/ci.lisp
lisp
Version was fixed because of this bug:
(defpackage #:40ants-ci/ci (:use #:cl) (:import-from #:40ants-ci/jobs/linter) (:import-from #:40ants-ci/jobs/critic) (:import-from #:40ants-ci/jobs/run-tests #:run-tests) (:import-from #:40ants-ci/jobs/docs #:build-docs) (:import-from #:40ants-ci/workflow #:de...
0909d35e3981f85ec72a97196baf2ef33e020478513143bc761a14dc5b71ec4b
atgreen/lisp-openshift
modes.lisp
modes.lisp -- using encryption modes with block ciphers (in-package :crypto) ;;; internal entry points to assure speed (defgeneric encrypt-with-mode (cipher mode plaintext ciphertext plaintext-start plaintext-end ciphertext-start handle-fin...
null
https://raw.githubusercontent.com/atgreen/lisp-openshift/40235286bd3c6a61cab9f5af883d9ed9befba849/quicklisp/dists/quicklisp/software/ironclad_0.30/src/ciphers/modes.lisp
lisp
internal entry points to assure speed Only really works on big-endian processors... This way is kind of ugly, but I don't know a better way. Just count the number of full blocks. CFB mode We can encrypt the whole thing. We can encrypt the whole thing. We can encrypt the whole thing. CTR mode We can encrypt th...
modes.lisp -- using encryption modes with block ciphers (in-package :crypto) (defgeneric encrypt-with-mode (cipher mode plaintext ciphertext plaintext-start plaintext-end ciphertext-start handle-final-block) (:documentation "Encrypt PLAIN...
84a47008a72b1a9f074d99fb36e1390a4d936042dde806c8f7da6cd2874487e6
oakes/play-clj
project.clj
(defproject play-clj/lein-template "1.2.0-SNAPSHOT" :description "A template for making play-clj projects" :url "-clj" :license {:name "Public Domain" :url ""} :dependencies [[lein-droid "0.4.3"]] :resource-paths ["resources"] :eval-in-leiningen true)
null
https://raw.githubusercontent.com/oakes/play-clj/aea03800071e13a6cbf1a925906e408b26138edd/template/project.clj
clojure
(defproject play-clj/lein-template "1.2.0-SNAPSHOT" :description "A template for making play-clj projects" :url "-clj" :license {:name "Public Domain" :url ""} :dependencies [[lein-droid "0.4.3"]] :resource-paths ["resources"] :eval-in-leiningen true)
ee41a4d243a310a2e4dece263b188abdd86fd62bba74956e4802d6d8156d4f8c
xldenis/ill
Infer.hs
module Thrill.Infer ( module Thrill.Infer , runCheck , defaultCheckEnv , Environment(..) , ConstructorEntry(..) , TraitEntry(..) , CheckState(..) , module Thrill.Error ) where Entrypoint for type checker This module handles the portions of typechecking related to top level declarations . All declarations...
null
https://raw.githubusercontent.com/xldenis/ill/46bb41bf5c82cd6fc4ad6d0d8d33cda9e87a671c/src/Thrill/Infer.hs
haskell
unncessary since all traits are bound already
module Thrill.Infer ( module Thrill.Infer , runCheck , defaultCheckEnv , Environment(..) , ConstructorEntry(..) , TraitEntry(..) , CheckState(..) , module Thrill.Error ) where Entrypoint for type checker This module handles the portions of typechecking related to top level declarations . All declarations...
e007a1dd3ea9783292903d83b681caee5bc5840d94a0a95b12e1ffc7023a5415
dharmatech/abstracting
source.scm
(import (rnrs records syntactic)) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (define (srfi-4-functor size _make unbox ref set) (define (tag-length hv) (/ (bytevector-length (unbox hv)) size)) (define (tag-ref hv i) (ref (unbox hv) (* i size))) (define (tag-set! hv i val) ...
null
https://raw.githubusercontent.com/dharmatech/abstracting/9dc5d9f45a9de03c6ee379f1928ebb393dfafc52/src/srfi/4/r6rs/source.scm
scheme
(import (rnrs records syntactic)) (define (srfi-4-functor size _make unbox ref set) (define (tag-length hv) (/ (bytevector-length (unbox hv)) size)) (define (tag-ref hv i) (ref (unbox hv) (* i size))) (define (tag-set! hv i val) (set (unbox hv) (* i size) val)) (define (tag-map! proc hv) ...
7673580ac79915020a2c17abd1d1d29a5398989413a8a9581401209acc1af65d
sklassen/erlang-linalg-native
linalg_qr.erl
-module(linalg_qr). -vsn('1.0'). -author('simon.klassen'). -export([qr/1]). -define(EPSILON, 1.0e-12). -type scalar() :: number(). -type vector() :: list(scalar()). -type matrix() :: list(vector()). % wikipedia % linalg_qr:householder([[12,-51,4],[6,167,-68],[-4,24,-41]]). % np.linalg.qr([[12,-51,4],[6,167,-68],[-4,...
null
https://raw.githubusercontent.com/sklassen/erlang-linalg-native/b31eef532b9fe2be7ecbff52a060ccdc833b4dca/src/linalg_qr.erl
erlang
wikipedia linalg_qr:householder([[12,-51,4],[6,167,-68],[-4,24,-41]]). np.linalg.qr([[12,-51,4],[6,167,-68],[-4,24,-41]]) [-0.42857143, -0.90285714, -0.03428571], [ 0., 0., -35.]]))
-module(linalg_qr). -vsn('1.0'). -author('simon.klassen'). -export([qr/1]). -define(EPSILON, 1.0e-12). -type scalar() :: number(). -type vector() :: list(scalar()). -type matrix() :: list(vector()). ( array([[-0.85714286 , 0.39428571 , 0.33142857 ] , [ 0.28571429 , -0.17142857 , 0.94285714 ] ] ) , a...
5daf6b65aaa84ae8519bc7e85a898b3dab23ec6295928012eff043cad89a9139
sjl/temperance
99.lisp
(in-package :temperance.test.99) 99 Prolog Problems ;;; /~meidanis/courses/mc336/2009s2/prolog/problemas/ ;;; ;;; Solutions to at least a few of these, for testing purposes. (define-test p1 ;; Find the last element of a list. (with-fresh-database (push-logic-frame-with t (fact t (last ?x (list ?x))) ...
null
https://raw.githubusercontent.com/sjl/temperance/f7e68f46b7afaeecf643c009eb2e130500556e31/test/99.lisp
lisp
/~meidanis/courses/mc336/2009s2/prolog/problemas/ Solutions to at least a few of these, for testing purposes. Find the last element of a list. TODO: p3/p4 when we have maths Reverse a list. Find out whether a list is a palindrome. Flatten a nested list structure. (define-test p9 (with-fresh-database (%...
(in-package :temperance.test.99) 99 Prolog Problems (define-test p1 (with-fresh-database (push-logic-frame-with t (fact t (last ?x (list ?x))) (rule t (last ?x (list* ? ?tail)) (last ?x ?tail))) (should-return ((last a (list a b c)) fail) ((last b (list a b c)) fail) ...
611fe60912ff5caa4a221a8f36ac8865863fa4a886392c008a4450b5c5fca006
rfindler/lindenmayer
main.rkt
#lang racket/base (module reader racket/base (require (only-in syntax/module-reader make-meta-reader lang-reader-module-paths) racket/list racket/port syntax/readerr racket/match racket/syntax racket/format ...
null
https://raw.githubusercontent.com/rfindler/lindenmayer/2ef7b4535d8ae1eb7cc2e16e2b630c30a4b9a34d/main.rkt
racket
we expect this to be an error found the end of our double hyphens found a non-hyphen and not at the end of a sequence of hyphens this doesn't work (yet) for refactorings using syntax-properties [('drracket:keystrokes default) this is a new rule continuation of a pending rule TODO: better error checking if there...
#lang racket/base (module reader racket/base (require (only-in syntax/module-reader make-meta-reader lang-reader-module-paths) racket/list racket/port syntax/readerr racket/match racket/syntax racket/format ...
2cd24d952732f86084ad63be703100ef6ed152ed624b177c9ce1f77c77d0423d
potatosalad/erlang-jose
jose_jws_alg_hmac_props.erl
-*- mode : erlang ; tab - width : 4 ; indent - tabs - mode : 1 ; st - rulers : [ 70 ] -*- %% vim: ts=4 sw=4 ft=erlang noet -module(jose_jws_alg_hmac_props). -include_lib("proper/include/proper.hrl"). % -compile(export_all). base64url_binary() -> ?LET(Binary, binary(), jose_jwa_base64url:encode(Binary)). bina...
null
https://raw.githubusercontent.com/potatosalad/erlang-jose/43d3db467f909bbc932bd663ddcb1af93180dfd3/test/property_test/jose_jws_alg_hmac_props.erl
erlang
vim: ts=4 sw=4 ft=erlang noet -compile(export_all).
-*- mode : erlang ; tab - width : 4 ; indent - tabs - mode : 1 ; st - rulers : [ 70 ] -*- -module(jose_jws_alg_hmac_props). -include_lib("proper/include/proper.hrl"). base64url_binary() -> ?LET(Binary, binary(), jose_jwa_base64url:encode(Binary)). binary_map() -> ?LET(List, list({base64url_binary(), base6...
a1259f2f35cd1ba36af2dde990c92c8f677414d3e837ac63dcea262348ab4abc
crategus/cl-cffi-gtk
rtest-gdk-display-manager.lisp
(def-suite gdk-display-manager :in gdk-suite) (in-suite gdk-display-manager) ;;; --- Types and Values ------------------------------------------------------- (test gdk-display-manager-class ;; Type check (is (g-type-is-object "GdkDisplayManager")) ;; Check the registered name (is (eq 'gdk-display-mana...
null
https://raw.githubusercontent.com/crategus/cl-cffi-gtk/74a78a6912a96f982644f3ee5ab7b8396cc2235f/test/rtest-gdk-display-manager.lisp
lisp
--- Types and Values ------------------------------------------------------- Type check Check the registered name Check the type initializer Check the parent Check the children Check the interfaces Check the class properties Check the class definition --- Properties -------------------------------------------...
(def-suite gdk-display-manager :in gdk-suite) (in-suite gdk-display-manager) (test gdk-display-manager-class (is (g-type-is-object "GdkDisplayManager")) (is (eq 'gdk-display-manager (registered-object-type-by-name "GdkDisplayManager"))) (is (eq (gtype "GdkDisplayManager") (gtype (for...
7b13c218c1b1c5462799d2e60404db631021fd23bee43993721d72601937e844
chenyukang/eopl
top.scm
(module top (lib "eopl.ss" "eopl") ;; top level module. Loads all required pieces. ;; Run the test suite with (run-all). (require "drscheme-init.scm") (require "data-structures.scm") ; for expval constructors (require "lang.scm") ; for scan&parse (require "interp.scm") ...
null
https://raw.githubusercontent.com/chenyukang/eopl/0406ff23b993bfe020294fa70d2597b1ce4f9b78/base/chapter5/exceptions/top.scm
scheme
top level module. Loads all required pieces. Run the test suite with (run-all). for expval constructors for scan&parse for test-list interface to test harness ;;;;;;;;;;;;;;;; run-all : () -> Unspecified runs all the tests in test-list, comparing the results with equal-answer? make sure this is in...
(module top (lib "eopl.ss" "eopl") (require "drscheme-init.scm") (require "interp.scm") run : String - > ExpVal (define run (lambda (string) (value-of-program (scan&parse string)))) (define run-all (lambda () (run-tests! run equal-answ...
d8a70517ad17d211083cc338e3d47d4f53c8218c5f3f119a2f12cf0bb51b7bfd
fluentpython/lispy
chap6d.scm
$ I d : v 4.4 2006/11/27 14:04:24 queinnec Exp $ ;;;(((((((((((((((((((((((((((((((( L i S P )))))))))))))))))))))))))))))))) ;;; This file is part of the files that accompany the book: LISP Implantation Semantique Programmation ( InterEditions , France ) By Christian Queinnec < > ;;; Newest version may b...
null
https://raw.githubusercontent.com/fluentpython/lispy/6b995c398e2d100fc3fc292e34ba1a00c0ae9b5a/references/LiSP-2ndEdition-2006Dec11/src/chap6d.scm
scheme
(((((((((((((((((((((((((((((((( L i S P )))))))))))))))))))))))))))))))) This file is part of the files that accompany the book: Newest version may be retrieved from: Check the README file before using this file. (((((((((((((((((((((((((((((((( L i S P )))))))))))))))))))))))))))))))) Threade...
$ I d : v 4.4 2006/11/27 14:04:24 queinnec Exp $ LISP Implantation Semantique Programmation ( InterEditions , France ) By Christian Queinnec < > ( IP 128.93.2.54 ) ftp.inria.fr : INRIA / Projects / icsla / Books / LiSP*.tar.gz (define *env* '()) Three different answers . Or the variable is local...
2680ab1ad4c49cbcdd130837830e6ebae1d55db80f025213bf763d774e3bb416
ndmitchell/tagsoup
Desugar.hs
# LANGUAGE ViewPatterns , PatternGuards # # OPTIONS_GHC -fno - warn - overlapping - patterns # module Desugar( records, untyped, irrefutable, core, core2, singleCase ) where import HSE import Data.Generics.PlateData import Data.Maybe import Data.List hiding (find) import Control.Monad.State find x xs = from...
null
https://raw.githubusercontent.com/ndmitchell/tagsoup/e116d3b965e4f149581bd55e45a05661b1113536/test/TagSoup/Generate/Desugar.hs
haskell
afterwards , no where afterwards , no multiple equations for one function afterwards no PatBind or Lambda , only FunBind convert a PatBind in to several FunBind 's include all variables at lambdas introduce a root introduce lambdas afterwards, no where afterwards, no multiple equations for one function ...
# LANGUAGE ViewPatterns , PatternGuards # # OPTIONS_GHC -fno - warn - overlapping - patterns # module Desugar( records, untyped, irrefutable, core, core2, singleCase ) where import HSE import Data.Generics.PlateData import Data.Maybe import Data.List hiding (find) import Control.Monad.State find x xs = from...
949c146d5d4aa81627174ecf981eeaf430f3a95f2e03d23d3cd2529730d0f440
soegaard/urlang
for.rkt
#lang racket (require urlang) (require syntax/parse syntax/stx) (provide add-clause-handler!) (provide in-array in-naturals in-range in-string in-value) (define-syntax in-array (λ (stx) (raise-syntax-error 'in-array "used out of context" stx))) (define-syntax in-naturals (λ (stx) (raise-syntax-error 'in-natural...
null
https://raw.githubusercontent.com/soegaard/urlang/086622e2306e72731016c7108aca3328e5082aee/urlang/for.rkt
racket
Tests See tests/test-for.rkt for tests. as the Racket counterpart. This module implement Racket style Parallel loops: (for (clause ...) <statement-or-break> ...) (for/array (clause ...) <statement-or-break> ... <expression>) (for/or (clause ...) <statement-or-break> ... <expression>) (f...
#lang racket (require urlang) (require syntax/parse syntax/stx) (provide add-clause-handler!) (provide in-array in-naturals in-range in-string in-value) (define-syntax in-array (λ (stx) (raise-syntax-error 'in-array "used out of context" stx))) (define-syntax in-naturals (λ (stx) (raise-syntax-error 'in-natural...
06fded7ca3f7da4f4875edf8a7cfed906cb600abf5aa005193b8bdfd3db38003
emillon/ocaml-noise
test_all.ml
open OUnit2 let equal_cstruct = Cstruct.equal let pp_cstruct = Cstruct.hexdump_pp let test_poly1305 = let test ~key ~msg expected ctxt = let got = match Tweetnacl.poly1305 ~key msg with | x -> Some x | exception Tweetnacl.Wrong_key_size -> None in assert_equal ~ctxt ~cmp:[%...
null
https://raw.githubusercontent.com/emillon/ocaml-noise/d5a3e0f634fba1f8d948a91c70a1dad6470722b0/tweetnacl/test/test_all.ml
ocaml
open OUnit2 let equal_cstruct = Cstruct.equal let pp_cstruct = Cstruct.hexdump_pp let test_poly1305 = let test ~key ~msg expected ctxt = let got = match Tweetnacl.poly1305 ~key msg with | x -> Some x | exception Tweetnacl.Wrong_key_size -> None in assert_equal ~ctxt ~cmp:[%...