_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
f644211af397b98d9c977d97860d735b7d9e2c2a97fd67caffc93349534b955d
maxdore/elfe
Settings-example.hs
module Settings where import Elfe.Language port :: Int port = 8000 -- The maximal amount of time each of the background provers can run atpTimeout :: Int atpTimeout = 10 vampire = Prover "Vampire" "online-atps" ["--atp=vampire", "--only-check"] ["Theorem"] ["No theorem"] ["uns"] eprover = Prover "E Prover" "../prov...
null
https://raw.githubusercontent.com/maxdore/elfe/56ecf5f704594221f30e342b9bb9dbc7874f5656/Settings-example.hs
haskell
The maximal amount of time each of the background provers can run
module Settings where import Elfe.Language port :: Int port = 8000 atpTimeout :: Int atpTimeout = 10 vampire = Prover "Vampire" "online-atps" ["--atp=vampire", "--only-check"] ["Theorem"] ["No theorem"] ["uns"] eprover = Prover "E Prover" "../prover/eprover/PROVER/eprover" ["--cpu-limit=20", "-s", "--auto-schedule"...
12a461d2a40b682bf2b43fd90f1d4ad85d842333fd3e0d5602d1df8c31492ebb
pfeodrippe/orchardia
class_members.clj
(ns compliment.sources.class-members (:require [clojure.string :as str] [compliment.sources :refer [defsource]] [compliment.sources.local-bindings :refer [bindings-from-context]] [compliment.utils :refer [fuzzy-matches-no-skip? resolve-class]] [orchard.introspection :as...
null
https://raw.githubusercontent.com/pfeodrippe/orchardia/42cb2b663f59e3ee314e3e2fe128407162a0183a/src/compliment/sources/class_members.clj
clojure
Form might have an immediate tag... ...or a tag somewhere in local scope. Note how getting an element from a set can return itself but with meta. We have a tag - try to resolve the class from it. Works only with static members for now Static Methos
(ns compliment.sources.class-members (:require [clojure.string :as str] [compliment.sources :refer [defsource]] [compliment.sources.local-bindings :refer [bindings-from-context]] [compliment.utils :refer [fuzzy-matches-no-skip? resolve-class]] [orchard.introspection :as...
3006e7094796250f15448cb57cb20e55da3788d6e9f806a30a2f7505ac8ed224
patperry/hs-linear-algebra
Class.hs
# LANGUAGE TypeFamilies , MultiParamTypeClasses , FlexibleContexts # ----------------------------------------------------------------------------- -- | -- Module : Data.Matrix.Class Copyright : Copyright ( c ) , < > -- License : BSD3 Maintainer : < > -- Stability : experimental -- -- Common function...
null
https://raw.githubusercontent.com/patperry/hs-linear-algebra/887939175e03687b12eabe2fce5904b494242a1a/lib/Data/Matrix/Class.hs
haskell
--------------------------------------------------------------------------- | Module : Data.Matrix.Class License : BSD3 Stability : experimental Common functionality for the types defined in a base class for the mutable and immutable matrix classes defined in the submodules of this one. * Matrix shape...
# LANGUAGE TypeFamilies , MultiParamTypeClasses , FlexibleContexts # Copyright : Copyright ( c ) , < > Maintainer : < > " Data . Matrix . Dense . Class " and " Data . Matrix . Banded . Class " , and module Data.Matrix.Class ( MatrixShaped, numRows, numCols, isSquare, isFat, isTall...
1c68e0e2ffd25522aa367c6f1a42ac25d96aa2cdd8b56bcb59f522a302d1b565
mtgred/netrunner
auth.clj
(ns web.auth (:require [buddy.sign.jwt :as jwt] [cljc.java-time.temporal.chrono-unit :as chrono] [cljc.java-time.instant :as inst] [clojure.string :as str] [crypto.password.bcrypt :as password] [monger.collection :as mc] [monger.operators :refer :all] [monger.result :refer [acknowledged?]] ...
null
https://raw.githubusercontent.com/mtgred/netrunner/0f9d96139177c1ee1603497971220d42867082f8/src/clj/web/auth.clj
clojure
(ns web.auth (:require [buddy.sign.jwt :as jwt] [cljc.java-time.temporal.chrono-unit :as chrono] [cljc.java-time.instant :as inst] [clojure.string :as str] [crypto.password.bcrypt :as password] [monger.collection :as mc] [monger.operators :refer :all] [monger.result :refer [acknowledged?]] ...
d2694e4e439b25a7bbcd6fd5fb54e72254118abf8445950965e5b29673ab1783
kind2-mc/kind2
inputSystem.ml
This file is part of the Kind 2 model checker . Copyright ( c ) 2014 by the Board of Trustees of the University of Iowa Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not use this file except in compliance with the License . You may obtain a copy of the License a...
null
https://raw.githubusercontent.com/kind2-mc/kind2/b08aba99bd4d2233669e194b32a0c9c0ed45356b/src/inputSystem.ml
ocaml
Lustre systems supports multiple entry points (main subsystems) let read_input_horn input_file = assert false * Returns the analysis param for [top] that abstracts all its abstractable subsystems if [top] has a contract. Collects all subsystems, abstracting them if possible. Finds [top] in the subsystems, and...
This file is part of the Kind 2 model checker . Copyright ( c ) 2014 by the Board of Trustees of the University of Iowa Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not use this file except in compliance with the License . You may obtain a copy of the License a...
2688769ba36779ef92eb22df68418368b61eb209f19e5a054925a4d2b0e475f8
input-output-hk/ouroboros-network
Abstract.hs
# LANGUAGE FlexibleContexts # {-# LANGUAGE GADTs #-} {-# LANGUAGE PatternSynonyms #-} # LANGUAGE RankNTypes # # LANGUAGE StandaloneDeriving # {-# LANGUAGE TypeFamilies #-} module Ouroboros.Consensus.Block.Abstract ( -- * Protocol BlockProtocol -- * Configuration , BlockC...
null
https://raw.githubusercontent.com/input-output-hk/ouroboros-network/c82309f403e99d916a76bb4d96d6812fb0a9db81/ouroboros-consensus/src/Ouroboros/Consensus/Block/Abstract.hs
haskell
# LANGUAGE GADTs # # LANGUAGE PatternSynonyms # # LANGUAGE TypeFamilies # * Protocol * Configuration * Previous hash * Working with headers * Raw hash * Re-export basic definitions from @cardano-base@ ---------------------------------------------------------------------------- -------------...
# LANGUAGE FlexibleContexts # # LANGUAGE RankNTypes # # LANGUAGE StandaloneDeriving # module Ouroboros.Consensus.Block.Abstract ( BlockProtocol , BlockConfig , CodecConfig , StorageConfig , GetPrevHash (..) , blockPrevHash , GetHeader (..) , Header , blockIsEBB , blockToIsEBB , getB...
96691c3fd011b104fd57622f4e9944917a867566a6c7d74cb2bf8a9d33c4f5a4
lexml/lexml-linker
Atalhos.hs
module LexML.URN.Atalhos where import LexML.URN.Types import Data.Maybe (fromJust,maybe) import qualified Data.Map as M import Data.List import System.IO.Unsafe (unsafePerformIO) leiFederal :: [Integer] -> Dia -> Mes -> Ano -> URNLexML leiFederal numLei dia mes ano = URNLexML (Local Brasil Nothing) (Documento (A_Conv...
null
https://raw.githubusercontent.com/lexml/lexml-linker/53b8580b1b6c2f72c350f8c098519c3933ab8238/src/main/haskell/LexML/URN/Atalhos.hs
haskell
module LexML.URN.Atalhos where import LexML.URN.Types import Data.Maybe (fromJust,maybe) import qualified Data.Map as M import Data.List import System.IO.Unsafe (unsafePerformIO) leiFederal :: [Integer] -> Dia -> Mes -> Ano -> URNLexML leiFederal numLei dia mes ano = URNLexML (Local Brasil Nothing) (Documento (A_Conv...
0fb52d1f7e5616843e5470b0f809ffed8b41c2af63ca26a437347af5336a879d
staples-sparx/kits
parse.clj
(ns kits.parse "Thin Clojure wrappers for Java parse functions.") (set! *warn-on-reflection* true) (defmacro with-nil-exception "Evaluate body, returning nil in the event of an exception." [& body] `(try ~@body (catch Exception e# nil))) (defn str->byte "Parses a string into a byte." [str-val] ...
null
https://raw.githubusercontent.com/staples-sparx/kits/66ae99bce83e8fd1248cc5c0da1f23673f221073/src/clojure/kits/parse.clj
clojure
(ns kits.parse "Thin Clojure wrappers for Java parse functions.") (set! *warn-on-reflection* true) (defmacro with-nil-exception "Evaluate body, returning nil in the event of an exception." [& body] `(try ~@body (catch Exception e# nil))) (defn str->byte "Parses a string into a byte." [str-val] ...
b742b36fffbc57658bf1054fb3fcba4013a8b4894a1d1ce4991bcc3919d48b76
twashing/edgaru
analytics.clj
(ns edgaru.five.analytics (:require [edgaru.five.core :as core])) ;; Refactor price-list (declare timeseries) (def price-list (core/generate-prices 5 15)) '({:last 13.467930225619813} {:last 10.774344180495852} {:last 12.929213016595023} {:last 15.515055619914026} {:last 18.61806674389683}) (defn extract-p...
null
https://raw.githubusercontent.com/twashing/edgaru/7a6bb30eee5fa2dfdf3baabe8b25e9bcc5019181/src/edgaru/five/analytics.clj
clojure
Refactor price-list Destructuring Refactor simple-moving-average calculate how far back the window can start calculate Simple Moving Average for each slot there's a window sum it up get the average and merge the output key to the map N = number of days get the Moving Average work out the mean Then for each ...
(ns edgaru.five.analytics (:require [edgaru.five.core :as core])) (declare timeseries) (def price-list (core/generate-prices 5 15)) '({:last 13.467930225619813} {:last 10.774344180495852} {:last 12.929213016595023} {:last 15.515055619914026} {:last 18.61806674389683}) (defn extract-price-only [price-list] ...
7f8b643ab0f3f804f878dc46411dea9c3fab4be712f955277529cb107c32d20e
casperschipper/ocaml-cisp
null_loops.ml
let mkBoermanFading2 ( ) = let open Cisp in let memsize = 10.0 in let tabIndex = seq [ 0.0;sec memsize ] in let dura = ch [ | 0.5 ; 2.0/.3.0 ; 3.0/.2.0 ; 2.0 | ] | > Seq.map ( fun x - > x * . ) in let readpos = in let buffer = Array.make ( ) 0.0 in let input = Process.inputSeq 0 ...
null
https://raw.githubusercontent.com/casperschipper/ocaml-cisp/571ffb8e508c5427d01e407ba5e91ff2a4604f40/examples/null_loops.ml
ocaml
let input = in let clock = Seq.map (fun x () -> x) masterClock in let effects = effect_lst [blow_sq;bhigh_sq;clock] in
let mkBoermanFading2 ( ) = let open Cisp in let memsize = 10.0 in let tabIndex = seq [ 0.0;sec memsize ] in let dura = ch [ | 0.5 ; 2.0/.3.0 ; 3.0/.2.0 ; 2.0 | ] | > Seq.map ( fun x - > x * . ) in let readpos = in let buffer = Array.make ( ) 0.0 in let input = Process.inputSeq 0 ...
f139479db47ec2c98133491df4bb0090c345c79178326d07810d5d609c04f046
facebookarchive/duckling_old
time.clj
( ; Context map Thursday Feb 2 , 2017 at 3:55am is now for the test {:reference-time (time/t -2 2017 2 2 3 55 0) :min (time/t -2 1900) :max (time/t -2 2100)} "bây giờ" "ngay bây giờ" "ngay lúc này" (datetime 2017 2 2 3 55 00) "hôm nay" "ngày hôm nay" "bữa nay" (datetime 2017 2 2) "hôm q...
null
https://raw.githubusercontent.com/facebookarchive/duckling_old/bf5bb9758c36313b56e136a28ba401696eeff10b/resources/languages/vi/corpus/time.clj
clojure
Context map Cycles Hours :precision "approximate" Mixing date and time Seasons Part of day (morning, afternoon...) Intervals involving cycles Timezones how should we deal with fb mornings?
( Thursday Feb 2 , 2017 at 3:55am is now for the test {:reference-time (time/t -2 2017 2 2 3 55 0) :min (time/t -2 1900) :max (time/t -2 2100)} "bây giờ" "ngay bây giờ" "ngay lúc này" (datetime 2017 2 2 3 55 00) "hôm nay" "ngày hôm nay" "bữa nay" (datetime 2017 2 2) "hôm qua" "ngày hôm ...
0abe5bc433654e108a56116f5b56bd7a2636cb5a434aa85efb8a9bc9cff2c093
Dale-M/mcron
vixie-specification.scm
vixie-specification.scm -- read - sytle configuration file Copyright © 2003 < > ;;; This file is part of GNU Mcron . ;;; GNU Mcron is free software : you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3...
null
https://raw.githubusercontent.com/Dale-M/mcron/56308568da1c846698a4b2ad593a164133ab19cf/src/mcron/vixie-specification.scm
scheme
(at your option) any later version. but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. Commentary: a real file or an already opened port. It also exposes the method for file. Code: space...
vixie-specification.scm -- read - sytle configuration file Copyright © 2003 < > This file is part of GNU Mcron . GNU Mcron is free software : you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3 of the ...
f7bf64f6e99c067f5efe716991294f304c3fcaf70713df2300c46088f2f08faa
blarney-lang/blarney
Option.hs
import Blarney import Blarney.Option import System.Environment testModule :: Module (Option (Bit 32), Bit 32) testModule = do testReg :: Reg (Bit 32) <- makeReg 0 always do testReg <== testReg.val + 1 let optVal = if testReg.val .%. 5 === 0 then some testReg.val else none return (optVal, testReg.val) top :: M...
null
https://raw.githubusercontent.com/blarney-lang/blarney/e80a547b092462f1beb9378e6c806db679ff62b4/Examples/Option/Option.hs
haskell
Create a testModule Display values update counter Terminate simulation
import Blarney import Blarney.Option import System.Environment testModule :: Module (Option (Bit 32), Bit 32) testModule = do testReg :: Reg (Bit 32) <- makeReg 0 always do testReg <== testReg.val + 1 let optVal = if testReg.val .%. 5 === 0 then some testReg.val else none return (optVal, testReg.val) top :: M...
b08a369730738d10d5f2247cab15e3f311407c639e74709977869e64ee0bae00
lambdaisland/regal
malli.cljc
(ns ^:deprecated lambdaisland.regal.malli "Custom Malli schema that supports regal directly. No longer compatible with latest Malli, see the README for an alternative way to combine the two." (:require [lambdaisland.regal :as regal] [lambdaisland.regal.generator :as generator] [malli.core ...
null
https://raw.githubusercontent.com/lambdaisland/regal/2320764d9e48991fda73900f0802460c5d7edad2/src/lambdaisland/regal/malli.cljc
clojure
=> [:regal [:+ "y"]] => :regal => true => ["Pattern does not match"] => ("y" "yy" "yy" "yyyy" "yyyy" "y" "yyy" "yyyyy" "yyyyyyyyy" "yyyyyyyy")
(ns ^:deprecated lambdaisland.regal.malli "Custom Malli schema that supports regal directly. No longer compatible with latest Malli, see the README for an alternative way to combine the two." (:require [lambdaisland.regal :as regal] [lambdaisland.regal.generator :as generator] [malli.core ...
403c6d3fa0e929f950c8d70125222829a2b3dd15df2fa0ad1c56f98de6c0d477
bhauman/figwheel-main
logging.clj
(ns figwheel.main.logging (:require [clojure.java.io :as io] [clojure.string :as string] [figwheel.core] [figwheel.main.ansi-party :as ap :refer [format-str]] [figwheel.main.util :as util] [figwheel.tools.exceptions :as fig-ex]) (:import [java.util.logging Logger Level LogRecord ...
null
https://raw.githubusercontent.com/bhauman/figwheel-main/ead06b94b1b2747ed37e5d8c37118d6e7ae77193/src/figwheel/main/logging.clj
clojure
this supports rebel-readline better set level ALL here -------------------------------------------------------------------------------- --------------------------------------------------------------------------------
(ns figwheel.main.logging (:require [clojure.java.io :as io] [clojure.string :as string] [figwheel.core] [figwheel.main.ansi-party :as ap :refer [format-str]] [figwheel.main.util :as util] [figwheel.tools.exceptions :as fig-ex]) (:import [java.util.logging Logger Level LogRecord ...
bb49f29b391479d507789263a16c067cf9b7d1173f23c5b6cb78e13d871df3ee
dmitryvk/sbcl-win32-threads
nlx.lisp
the SPARC definitions of VOPs used for non - local exit ( throw , ;;;; lexical exit, etc.) 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 ;;;; ...
null
https://raw.githubusercontent.com/dmitryvk/sbcl-win32-threads/5abfd64b00a0937ba2df2919f177697d1d91bde4/src/compiler/sparc/nlx.lisp
lisp
lexical exit, etc.) 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. entry. save and restore dynamic environment. These VOPs are used in the reentered function to restore the appropriate ...
the SPARC definitions of VOPs used for non - local exit ( throw , 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!VM") Make an environment - live stack ...
d6b4f336c1f803f3784adbb59567090a6e64cfb2c1d16920183a5297cec822a7
day8/re-frame-http-fx
project.clj
(defproject day8.re-frame/http-fx "lein-git-inject/version" :description "A re-frame effects handler for performing Ajax tasks" :url "-frame-http-fx.git" :license {:name "MIT"} :dependencies [[org.clojure/clojure "1.10.2" :scope "provided"] [org.clojure/clojurescript "1....
null
https://raw.githubusercontent.com/day8/re-frame-http-fx/c9724aea5a4600ec5cc6614617912a2c5fd07d3b/project.clj
clojure
(defproject day8.re-frame/http-fx "lein-git-inject/version" :description "A re-frame effects handler for performing Ajax tasks" :url "-frame-http-fx.git" :license {:name "MIT"} :dependencies [[org.clojure/clojure "1.10.2" :scope "provided"] [org.clojure/clojurescript "1....
a043a62d88a57dbeafbf465c15802f07378ae555e5c0d676bdd94367f2a8ee32
dongcarl/guix
compression.scm
;;; GNU Guix --- Functional package management for GNU Copyright © 2012 , 2013 , 2014 , 2015 , 2017 , 2019 , 2020 < > Copyright © 2013 < > Copyright © 2014 , 2015 , 2018 < > Copyright © 2015 < > Copyright © 2015 , 2016 < > Copyright © 2015 , 2016 , 2017 , 2018 , 2020 , 2021 < > Copyr...
null
https://raw.githubusercontent.com/dongcarl/guix/d2b30db788f1743f9f8738cb1de977b77748567f/gnu/packages/compression.scm
scheme
GNU Guix --- Functional package management for GNU Copyright © 2020 Arun Isaac <> This file is part of GNU Guix. you can redistribute it and/or modify it either version 3 of the License , or ( at your option) any later version. GNU Guix is distributed in the hope that it will be useful, but WITHOUT ANY WARRA...
Copyright © 2012 , 2013 , 2014 , 2015 , 2017 , 2019 , 2020 < > Copyright © 2013 < > Copyright © 2014 , 2015 , 2018 < > Copyright © 2015 < > Copyright © 2015 , 2016 < > Copyright © 2015 , 2016 , 2017 , 2018 , 2020 , 2021 < > Copyright © 2015 , 2017 , 2018 < > Copyright © 2015 <...
c32bc89440634945fed985910cd3ed54c16aa1405b413655cff25f78618217e9
skanev/playground
54.scm
SICP exercise 3.54 ; ; Define a procedure mul-streams, analogous to add-streams, that produces the elementwise product of its two input streams . Use this together with the ; stream of integers to complete the following definition of the stream whose ; nth elemen (counting down from 0) is n + 1 factorial: ; ( d...
null
https://raw.githubusercontent.com/skanev/playground/d88e53a7f277b35041c2f709771a0b96f993b310/scheme/sicp/03/54.scm
scheme
Define a procedure mul-streams, analogous to add-streams, that produces the stream of integers to complete the following definition of the stream whose nth elemen (counting down from 0) is n + 1 factorial: (mul-streams <??> <??>)))
SICP exercise 3.54 elementwise product of its two input streams . Use this together with the ( define factorials ( cons - stream 1 (define stream-take '()) (define the-empty-stream empty-stream) (define stream-null? stream-empty?) (define stream-car stream-first) (define stream-cdr stream-rest) (define (add-s...
72a8c55bd0685145eb7293ac82a7e5635acc818a8f84f93d19b5b0ea1041c643
mbutterick/beautiful-racket
tokenizer.rkt
#lang br/quicklang (require brag/support racket/contract) (module+ test (require rackunit)) (define (jsonic-token? x) (or (eof-object? x) (token-struct? x))) (module+ test (check-true (jsonic-token? eof)) (check-true (jsonic-token? (token 'A-TOKEN-STRUCT "hi"))) (check-false (jsonic-token? 42))) (define (...
null
https://raw.githubusercontent.com/mbutterick/beautiful-racket/f0e2cb5b325733b3f9cbd554cc7d2bb236af9ee9/beautiful-racket-demo/jsonic-demo-2/tokenizer.rkt
racket
#lang br/quicklang (require brag/support racket/contract) (module+ test (require rackunit)) (define (jsonic-token? x) (or (eof-object? x) (token-struct? x))) (module+ test (check-true (jsonic-token? eof)) (check-true (jsonic-token? (token 'A-TOKEN-STRUCT "hi"))) (check-false (jsonic-token? 42))) (define (...
eaccbbe64280f02e198cc83f71bead6940c2efa1c1dc28d3795c30c8a20ba141
davisp/couchdb
couch_util.erl
Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not % use this file except in compliance with the License. You may obtain a copy of % the License at % % -2.0 % % Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an " A...
null
https://raw.githubusercontent.com/davisp/couchdb/b0420f9006915149e81607615720f32f21c76725/src/couchdb/couch_util.erl
erlang
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 WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations...
Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not distributed under the License is distributed on an " AS IS " BASIS , WITHOUT -module(couch_util). -export([priv_dir/0, normpath/1]). -export([should_flush/0, should_flush/1, to_existing_atom/1]). -export([rand32/0, implode/2, collat...
955cca6408c81221fd63802e46e41132515526a07462dcd4d4acf6acac7d19f5
CodyReichert/qi
defcfun.lisp
;;;; -*- Mode: lisp; indent-tabs-mode: nil -*- ;;; ;;; defcfun.lisp --- Tests function definition and calling. ;;; Copyright ( C ) 2005 - 2007 , ;;; ;;; Permission is hereby granted, free of charge, to any person ;;; obtaining a copy of this software and associated documentation files ( the " Software " ) , t...
null
https://raw.githubusercontent.com/CodyReichert/qi/9cf6d31f40e19f4a7f60891ef7c8c0381ccac66f/dependencies/cffi-master/tests/defcfun.lisp
lisp
-*- Mode: lisp; indent-tabs-mode: nil -*- defcfun.lisp --- Tests function definition and calling. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation restriction, including without limitation the rights to use, copy, modify, merge, publish,...
Copyright ( C ) 2005 - 2007 , files ( the " Software " ) , to deal in the Software without of the Software , and to permit persons to whom the Software is included in all copies or substantial portions of the Software . THE SOFTWARE IS PROVIDED " AS IS " , WITHOUT WARRANTY OF ANY KIND , (in-package #:c...
1fb408a043d1b104c0ccf9ec27c257481c46e77eeb8393e0edb16bd06dc0a6e5
ocaml-doc/doc-ock-html
url.mli
open DocOck.Paths type t = { page : string list; * [ Foo.Bar.lol ] becomes [ [ " lol " ; " Bar " ; " " ] ] . anchor : string; (** Anchor in {!page} where the element is attached *) kind : string; (** What kind of element the path points to. e.g. "module", "module-type", "exception", ... *) } (** A l...
null
https://raw.githubusercontent.com/ocaml-doc/doc-ock-html/84c2e11889111858b732be1b530cf50eb176dc75/src/url.mli
ocaml
* Anchor in {!page} where the element is attached * What kind of element the path points to. e.g. "module", "module-type", "exception", ... * A low level representation of ocaml paths. These should basicaly never happen
open DocOck.Paths type t = { page : string list; * [ Foo.Bar.lol ] becomes [ [ " lol " ; " Bar " ; " " ] ] . anchor : string; kind : string; } val to_string : t -> string module Error : sig type nonrec t = | Not_linkable of string | Uncaught_exn of string | Unexpected_anchor of t * string ...
667c7314c256bb825453db03a0b4cbf76a88da085519d5dd2412837c3b56e8c2
YoshikuniJujo/funpaala
composable0.hs
class Composable a where compose :: a -> a -> a data Add = Add Integer deriving Show instance Composable Add where compose (Add x) (Add y) = Add $ x + y data Mul = Mul Integer deriving Show instance Composable Mul where compose (Mul x) (Mul y) = Mul $ x * y
null
https://raw.githubusercontent.com/YoshikuniJujo/funpaala/5366130826da0e6b1180992dfff94c4a634cda99/samples/26_type_class/composable0.hs
haskell
class Composable a where compose :: a -> a -> a data Add = Add Integer deriving Show instance Composable Add where compose (Add x) (Add y) = Add $ x + y data Mul = Mul Integer deriving Show instance Composable Mul where compose (Mul x) (Mul y) = Mul $ x * y
0cec1f3f68f4072bf342d7004afaeb67c0d26888fb981b025d00c44063d3c0df
bmeurer/ocaml-experimental
length.ml
$ Id$ A testbed file for private type abbreviation definitions . We define a Length module to implement positive integers . A testbed file for private type abbreviation definitions. We define a Length module to implement positive integers. *) type t = int;; let make x = if x >= 0 then x else failwit...
null
https://raw.githubusercontent.com/bmeurer/ocaml-experimental/fe5c10cdb0499e43af4b08f35a3248e5c1a8b541/testsuite/tests/basic-private/length.ml
ocaml
$ Id$ A testbed file for private type abbreviation definitions . We define a Length module to implement positive integers . A testbed file for private type abbreviation definitions. We define a Length module to implement positive integers. *) type t = int;; let make x = if x >= 0 then x else failwit...
f1a58c575d0fcbbd22ecaf382e8c272fced432715900e06d37dc396f03a31850
aryx/xix
pagetable.ml
open Common open Types open Pagetable_ type t = Pagetable_.t let alloc () = { pagetab = Array.make pagetab_size None; first = pagetab_size; (* take care of access outside bound *) last = 0; } less : pass seg type if want to handle SG_PHYSICAL ( or handle it in caller ) let free pt = if pt.first < pag...
null
https://raw.githubusercontent.com/aryx/xix/60ce1bd9a3f923e0e8bb2192f8938a9aa49c739c/kernel/memory/pagetable.ml
ocaml
take care of access outside bound actually share the pages, but create a fresh pagetable so when fault, * we will be able to allocate a new page (copy on write) and reference * this new page in the pagetab array.
open Common open Types open Pagetable_ type t = Pagetable_.t let alloc () = { pagetab = Array.make pagetab_size None; last = 0; } less : pass seg type if want to handle SG_PHYSICAL ( or handle it in caller ) let free pt = if pt.first < pagetab_size then for i = pt.first to pt.last do pt.page...
6e2e24fe495db387e4161bd7a479087875a2ff526159211ce598b1b6301423f3
k0001/tisch
Compat.hs
# LANGUAGE DataKinds # # LANGUAGE ExistentialQuantification # # LANGUAGE FlexibleInstances # # LANGUAGE KindSignatures # # LANGUAGE MultiParamTypeClasses # # LANGUAGE PolyKinds # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeOperators # # LANGUAGE TypeFamilies # # LANGUAGE UndecidableInstances # # OPTIONS_GHC -fno - ...
null
https://raw.githubusercontent.com/k0001/tisch/4d3fc55f0b64f50dc8a59b371e855a22d22f0a79/src/lib/Tisch/Internal/Compat.hs
haskell
# OPTIONS_GHC -Wno-redundant-constraints # | Miscellaneous compatibility stuff. ------------------------------------------------------------------------------ The return type must correctly be set by the caller. | Conversions to 'Int' are explicitely disabled. # OVERLAPPING # | Conversions to 'Word' are explicitely...
# LANGUAGE DataKinds # # LANGUAGE ExistentialQuantification # # LANGUAGE FlexibleInstances # # LANGUAGE KindSignatures # # LANGUAGE MultiParamTypeClasses # # LANGUAGE PolyKinds # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeOperators # # LANGUAGE TypeFamilies # # LANGUAGE UndecidableInstances # # OPTIONS_GHC -fno - ...
e8420cae75b29e5b7aee09b4f4c66b8f32686939dc4e8e00b6bb8e5a58e8490b
emezeske/lein-cljsbuild
routes.clj
(ns example.routes (:use compojure.core example.views [hiccup.middleware :only (wrap-base-url)]) (:require [compojure.route :as route] [compojure.handler :as handler] [compojure.response :as response])) (defroutes main-routes (GET "/" [] (index-page)) (route/resources "/...
null
https://raw.githubusercontent.com/emezeske/lein-cljsbuild/089193c74e362c143d30dfca21a21e95c7ca112a/example-projects/simple/src-clj/example/routes.clj
clojure
(ns example.routes (:use compojure.core example.views [hiccup.middleware :only (wrap-base-url)]) (:require [compojure.route :as route] [compojure.handler :as handler] [compojure.response :as response])) (defroutes main-routes (GET "/" [] (index-page)) (route/resources "/...
a616a71904430ad5cdbc729bb7fcb3bd2bb4ac2b68c7d4518c8f673ee77cadc8
realworldocaml/book
subdir_set.ml
open Import type t = | All | These of String.Set.t let to_dir_set = function | All -> Dir_set.universal | These s -> String.Set.fold s ~init:Dir_set.empty ~f:(fun path acc -> let path = Path.Local.of_string path in Dir_set.union acc (Dir_set.singleton path)) let of_dir_set d = match Dir...
null
https://raw.githubusercontent.com/realworldocaml/book/d822fd065f19dbb6324bf83e0143bc73fd77dbf9/duniverse/dune_/src/dune_engine/subdir_set.ml
ocaml
open Import type t = | All | These of String.Set.t let to_dir_set = function | All -> Dir_set.universal | These s -> String.Set.fold s ~init:Dir_set.empty ~f:(fun path acc -> let path = Path.Local.of_string path in Dir_set.union acc (Dir_set.singleton path)) let of_dir_set d = match Dir...
76351365b0565a242838e67f692ce6474386156f3bc8e47b2f5bc4c32a764933
weyrick/roadsend-php
php-gtk-overrides.scm
;; ***** BEGIN LICENSE BLOCK ***** Roadsend PHP Compiler Runtime Libraries Copyright ( C ) 2007 Roadsend , Inc. ;; ;; This program is free software; you can redistribute it and/or ;; modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation ; either version 2....
null
https://raw.githubusercontent.com/weyrick/roadsend-php/d6301a897b1a02d7a85bdb915bea91d0991eb158/runtime/ext/gtk2/php-gtk-overrides.scm
scheme
***** BEGIN LICENSE BLOCK ***** This program is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License either version 2.1 This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MER...
Roadsend PHP Compiler Runtime Libraries Copyright ( C ) 2007 Roadsend , Inc. of the License , or ( at your option ) any later version . GNU Lesser General Public License for more details . You should have received a copy of the GNU Lesser General Public License Foundation , Inc. , 51 Franklin Street , Fifth...
d2d1d5b8982b5b9b59df59d15306a5ec065d7b628bd9689cf5760d42d728e237
GregoryTravis/rhythmr
Animate.hs
module Animate ( AVal(..) , Interpolator(..) , readAVal , updateAVal , constAVal , aValSize ) where import qualified Data.Map.Strict as M import qualified Debug.Trace as TR import Util data AVal a = Const a | Blend Float Float (AVal a) (AVal a) (Interpolator a) instance Show a => Show (AVal a) where show (Const a...
null
https://raw.githubusercontent.com/GregoryTravis/rhythmr/55fd5b5af6a52da16b7d730c27fb408aa3c61538/src/Animate.hs
haskell
(oa, _) = readAVal aval t eesp ("gc", old, new) $ readAVal a t | TR.trace (show ("rSA", a, t)) False = undefined | s <= t && t < e = a
module Animate ( AVal(..) , Interpolator(..) , readAVal , updateAVal , constAVal , aValSize ) where import qualified Data.Map.Strict as M import qualified Debug.Trace as TR import Util data AVal a = Const a | Blend Float Float (AVal a) (AVal a) (Interpolator a) instance Show a => Show (AVal a) where show (Const a...
2f7dced848e034733f2ea39fdd55c11f2f3439c1447af2b1d7c7843adad5c786
alexwl/haskell-code-explorer
Main.hs
cabal - helper : Simple interface to Cabal 's configuration state Copyright ( C ) 2015 - 2018 < > -- -- This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3 of the License , ...
null
https://raw.githubusercontent.com/alexwl/haskell-code-explorer/2f1c2a4c87ebd55b8a335bc4670eec875af8b4c4/vendor/cabal-helper-0.8.1.2/src/CabalHelper/Runtime/Main.hs
haskell
This program is free software: you can redistribute it and/or modify (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public...
cabal - helper : Simple interface to Cabal 's configuration state Copyright ( C ) 2015 - 2018 < > it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3 of the License , or You should have received a copy of the GNU General Public License # L...
fb0bb2e405a0db9a7d1f70b8f73743ce8a83dfe964c3854fc2c0b007a0cc4254
ocaml-sf/learn-ocaml-corpus
with_a_hash_table.ml
(* A histogram maps characters to integer frequencies. *) type histogram = (char, int) Hashtbl.t (* Building a histogram out of a string. *) let histogram (s : string) : histogram = let table = Hashtbl.create 256 in String.iter (fun symbol -> let freq = try Hashtbl.find table symbol with Not_found -> 0 in ...
null
https://raw.githubusercontent.com/ocaml-sf/learn-ocaml-corpus/7dcf4d72b49863a3e37e41b3c3097aa4c6101a69/exercises/fpottier/anagrams/right/with_a_hash_table.ml
ocaml
A histogram maps characters to integer frequencies. Building a histogram out of a string. Converting a histogram to a list. Converting a histogram to a sorted list.
type histogram = (char, int) Hashtbl.t let histogram (s : string) : histogram = let table = Hashtbl.create 256 in String.iter (fun symbol -> let freq = try Hashtbl.find table symbol with Not_found -> 0 in Hashtbl.replace table symbol (freq + 1) ) s; table let elements (h : histogram) : (char * in...
2202676c3fa684cd521c605575864e3351f098847cc42046266b70f1c0433afb
cac-t-u-s/om-sharp
window.lisp
;========================================================================= ; OM API Multiplatform API for OpenMusic LispWorks Implementation ;========================================================================= ; ; This program is free software: you can redistribute it and/or modify it under the terms ...
null
https://raw.githubusercontent.com/cac-t-u-s/om-sharp/b7dbcf1975c7d502095153df61f2d0b2654500c4/src/api/om-api-LW/window.lisp
lisp
========================================================================= OM API ========================================================================= This program is free software: you can redistribute it and/or modify (at your option) any later version. This program is distributed; in the hope that...
Multiplatform API for OpenMusic LispWorks Implementation it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3 of the License , or You should have received a copy of the GNU General Public License Authors : , (export '(om-window...
1cba1613bc3910a7641c652b4ed27eb1ad4f69420ad9052bf208440873bb0b58
dstarcev/stepic-haskell
Task11.hs
module Module5.Task11 where -- system code data Board = Board Int deriving Show nextPositions :: Board -> [Board] nextPositions (Board i) = [Board (i * 10 + 1), Board (i * 10 + 2)] -- solution code nextPositionsN :: Board -> Int -> (Board -> Bool) -> [Board] nextPositionsN b n pred | n < 0 = [] | n == 0 = filter...
null
https://raw.githubusercontent.com/dstarcev/stepic-haskell/6a8cf4b3cc17333ac4175e825db57dbe151ebae0/src/Module5/Task11.hs
haskell
system code solution code
module Module5.Task11 where data Board = Board Int deriving Show nextPositions :: Board -> [Board] nextPositions (Board i) = [Board (i * 10 + 1), Board (i * 10 + 2)] nextPositionsN :: Board -> Int -> (Board -> Bool) -> [Board] nextPositionsN b n pred | n < 0 = [] | n == 0 = filter pred [b] | otherwise = do ...
803ecb427c2afded4ea02dfa9aaf6562a32c2e280acdf2586ede6b7ebf4ba069
ocaml/dune
shutdown.ml
open! Stdune open Import module Client = Dune_rpc_client.Client let send_shutdown cli = let open Fiber.O in let* decl = Client.Versioned.prepare_notification cli Dune_rpc_private.Public.Notification.shutdown in match decl with | Ok decl -> Client.notification cli decl () | Error e -> raise (Dune_...
null
https://raw.githubusercontent.com/ocaml/dune/20180d12149343d073cdea5860d01dc181702e6a/bin/shutdown.ml
ocaml
open! Stdune open Import module Client = Dune_rpc_client.Client let send_shutdown cli = let open Fiber.O in let* decl = Client.Versioned.prepare_notification cli Dune_rpc_private.Public.Notification.shutdown in match decl with | Ok decl -> Client.notification cli decl () | Error e -> raise (Dune_...
48135d3f3e3dbb9356f3f0fc2a24155ffd90af2b9a4ebf0f8c107adcdb9a2913
borkdude/jet
query.clj
(ns jet.query {:no-doc true} (:refer-clojure :exclude [comparator]) (:require [clojure.set :as set] [jet.utils :as utils])) (declare query) (defn safe-nth [x n] (try (nth x n) (catch Exception _e nil))) (defn var-lookup [sym] (case sym id identity identity identity c...
null
https://raw.githubusercontent.com/borkdude/jet/9bad90e1d9e0714b5c842cbb1247f716b98d4431/src/jet/query.clj
clojure
special case spy accessor, arg is not a query control flow index last juxt may be preferred over vector vector (into [] (map #(query x %) args)) special cases fallback Scratch
(ns jet.query {:no-doc true} (:refer-clojure :exclude [comparator]) (:require [clojure.set :as set] [jet.utils :as utils])) (declare query) (defn safe-nth [x n] (try (nth x n) (catch Exception _e nil))) (defn var-lookup [sym] (case sym id identity identity identity c...
a14624be7f3d9d456244043bfa8b8097a9570aec6626f9342a734f0d36c34342
wargrey/schema
string.rkt
#lang typed/racket/base (require "../../csv.rkt") (define StateDepartment.csv : Path (build-path (#%dir) 'up "StateDepartment.csv")) (printf "bstr: ") (define vectors : (Listof (Vectorof CSV-Field)) (with-logging-to-port (current-error-port) (λ [] (time (read-csv (bytes->string/utf-8 (file->bytes StateDepartm...
null
https://raw.githubusercontent.com/wargrey/schema/4824a1fecea1dc557941b08f05a457da9f628f78/tamer/csv/reader/performance/bytes/string.rkt
racket
#lang typed/racket/base (require "../../csv.rkt") (define StateDepartment.csv : Path (build-path (#%dir) 'up "StateDepartment.csv")) (printf "bstr: ") (define vectors : (Listof (Vectorof CSV-Field)) (with-logging-to-port (current-error-port) (λ [] (time (read-csv (bytes->string/utf-8 (file->bytes StateDepartm...
d466be4f077873a88e59f96416132f496b8dc88d35a4a566762bebb0cedb69c2
damn/cdq
helper.clj
(ns game.test.helper (:require game.start [game.components.ingame-loop :refer (do-in-game-loop)] [clojure.test :refer (deftest)])) (defn start-game-once-fixture [f] (game.start/start :config "config/test.clj") (f)) (defn do-in-game-loop-await [f] (let [latch (java.util.concurrent.Count...
null
https://raw.githubusercontent.com/damn/cdq/5093dbdba91c445e403f53ce96ead05d5ed8262b/test/game/test/helper.clj
clojure
Need to use bound-fn here assertions & failures in another thread. Alternative approach restarting the whole game: Soundstore.clear ! -> works, but then on restart all images are just white ... maybe image store also need to clear? Images have no context anymore ? they all have to be set to inited=false? all have...
(ns game.test.helper (:require game.start [game.components.ingame-loop :refer (do-in-game-loop)] [clojure.test :refer (deftest)])) (defn start-game-once-fixture [f] (game.start/start :config "config/test.clj") (f)) (defn do-in-game-loop-await [f] (let [latch (java.util.concurrent.Count...
83b4d5ce3b261a994b5ac3b4857e8c3c7f05975323d075959cbd7f8ada244a6d
melange-re/melange
bsb_pkg.ml
Copyright ( C ) 2017- , Authors of ReScript * * This program is free software : you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation , either version 3 of the License , or * ( at your option ) any later vers...
null
https://raw.githubusercontent.com/melange-re/melange/246e6df78fe3b6cc124cb48e5a37fdffd99379ed/mel/bsb_pkg.ml
ocaml
TODO: be more restrict [bsconfig.json] does not always make sense, when resolving [ppx-flags] It makes sense to have this function raise, when [bsb] could not resolve a package, it used to mean a failure TODO: may non-terminating when see symlinks To the end try other possiblilities [NODE_PATH] TODO: ...
Copyright ( C ) 2017- , Authors of ReScript * * This program is free software : you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation , either version 3 of the License , or * ( at your option ) any later vers...
50b31214107dfea99648a72d55c9987b923dd81198c39d9029694015efde3323
michaelzenz/jecci
txn.clj
(ns jecci.utils.dbms.txn "General transaction interface for database systems" (:require [clojure.tools.logging :refer [info]] [jepsen [client :as client] [generator :as gen]] [jecci.utils.dbms.sql :as s :refer :all] )) (defn table-name "Takes an integer and constr...
null
https://raw.githubusercontent.com/michaelzenz/jecci/81ee068601c31a14fe642f93d30223c2a8ced04d/src/jecci/utils/dbms/txn.clj
clojure
use-txn? false]
(ns jecci.utils.dbms.txn "General transaction interface for database systems" (:require [clojure.tools.logging :refer [info]] [jepsen [client :as client] [generator :as gen]] [jecci.utils.dbms.sql :as s :refer :all] )) (defn table-name "Takes an integer and constr...
561a71a0bc97c8be8015c420679fc2f101c3240091193a4c153977eaa0e04fcb
janestreet/noise-wireguard-ocaml
handshake_initiation.ml
type%cstruct t = { msg_type: uint32_t ; sender: uint32_t ; ephemeral: uint8_t [@len 32] ; signed_static: uint8_t [@len 48] ; signed_timestamp: uint8_t [@len 28] ; mac1: uint8_t [@len 32] ; mac2: uint8_t [@len 32] } [@@little_endian] type t_cstruct = Cstruct.t type t = { msg_type: Cstruct.uint32 ; se...
null
https://raw.githubusercontent.com/janestreet/noise-wireguard-ocaml/4ec7a34d1778ab5c8ec16a6129277d4f77406616/messages/handshake_initiation.ml
ocaml
TODO: test get_t_msg_alpha get_t_msg_beta
type%cstruct t = { msg_type: uint32_t ; sender: uint32_t ; ephemeral: uint8_t [@len 32] ; signed_static: uint8_t [@len 48] ; signed_timestamp: uint8_t [@len 28] ; mac1: uint8_t [@len 32] ; mac2: uint8_t [@len 32] } [@@little_endian] type t_cstruct = Cstruct.t type t = { msg_type: Cstruct.uint32 ; se...
729990bf0d175329ac3c67a1cf4cc244e82b2a3214ac63f12a8b0a64330b03be
clojure-interop/aws-api
core.clj
(ns com.amazonaws.services.opsworkscm.core (:refer-clojure :only [require comment defn ->]) (:import )) (require '[com.amazonaws.services.opsworkscm.AWSOpsWorksCM]) (require '[com.amazonaws.services.opsworkscm.AWSOpsWorksCMAsync]) (require '[com.amazonaws.services.opsworkscm.AWSOpsWorksCMAsyncClient]) (require '[c...
null
https://raw.githubusercontent.com/clojure-interop/aws-api/59249b43d3bfaff0a79f5f4f8b7bc22518a3bf14/com.amazonaws.services.opsworkscm/src/com/amazonaws/services/opsworkscm/core.clj
clojure
(ns com.amazonaws.services.opsworkscm.core (:refer-clojure :only [require comment defn ->]) (:import )) (require '[com.amazonaws.services.opsworkscm.AWSOpsWorksCM]) (require '[com.amazonaws.services.opsworkscm.AWSOpsWorksCMAsync]) (require '[com.amazonaws.services.opsworkscm.AWSOpsWorksCMAsyncClient]) (require '[c...
bb81287b0fae54b362180aed1f6fdb5daf7ad012117bf39f6e5f582353c02e3d
kennytilton/cells
defpackage.lisp
;; -*- mode: Lisp; Syntax: Common-Lisp; Package: cl-user; -*- ;;; Copyright ( c ) 2008 by . ;;; ;;; Permission is hereby granted, free of charge, to any person obtaining a copy ;;; of this software and associated documentation files (the "Software"), to deal in the Software without restriction , including with...
null
https://raw.githubusercontent.com/kennytilton/cells/64d05c83e155d5f35b3bd115dcd07f152ef79c39/triple-cells/defpackage.lisp
lisp
-*- mode: Lisp; Syntax: Common-Lisp; Package: cl-user; -*- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal to use, copy, modify, merge, publish, distribute, sublicense, and/or sell to do so, subject to t...
Copyright ( c ) 2008 by . in the Software without restriction , including without limitation the rights copies of the Software , and to permit persons to whom the Software is furnished all copies or substantial portions of the Software . THE SOFTWARE IS PROVIDED " AS IS " , WITHOUT WARRANTY OF ANY KIND , E...
0bce6fc206a342d3ca11bcb3369dfbe0c0eb4ff660ef10e38eb83a4f637d4f6d
ijp/guildhall
dependencies.scm
;;; dependencies.scm --- dependency resolution UI Copyright ( C ) 2010 , 2011 < > Author : < > ;; This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 3 of the License , ...
null
https://raw.githubusercontent.com/ijp/guildhall/2fe2cc539f4b811bbcd69e58738db03eb5a2b778/guildhall/ui/cmdline/dependencies.scm
scheme
dependencies.scm --- dependency resolution UI This program is free software; you can redistribute it and/or either version 3 This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ...
Copyright ( C ) 2010 , 2011 < > Author : < > modify it under the terms of the GNU General Public License of the License , or ( at your option ) any later version . You should have received a copy of the GNU General Public License #!r6rs (library (guildhall ui cmdline dependencies) (export appl...
3ddfab5c242ede2a1a884cb8cab107e1e96d1cf9ca78817cfd1c6904609c288c
project-fifo/vmwebadm
describe.cljs
(ns server.instrumentations.desc (:use [server.utils :only [clj->js prn-js clj->json transform-keys]]) (:require [server.storage :as storage] [dtrace :as dtrace] [server.http :as http])) (def metrics-map {:module "module" :stat "stats" :label "label" :interval "interval" ...
null
https://raw.githubusercontent.com/project-fifo/vmwebadm/55d83bbc0ac6db8ea1d784c73d91bf4f228fa04a/src/server/instrumentations/describe.cljs
clojure
(ns server.instrumentations.desc (:use [server.utils :only [clj->js prn-js clj->json transform-keys]]) (:require [server.storage :as storage] [dtrace :as dtrace] [server.http :as http])) (def metrics-map {:module "module" :stat "stats" :label "label" :interval "interval" ...
e04e99d75619b17b95a7db345b40901dba8ff7873afc3fd232c96ed79150aec5
dvdt/xvsy
scale.cljc
(ns xvsy.scale "Namespace for mapping data onto aesthetic (i.e. x, y, color, etc.) coordinates." (:require [c2.ticks :as ticks] [vomnibus.color-brewer :as color-brewer] [xvsy.conf] [xvsy.utils :as utils])) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;...
null
https://raw.githubusercontent.com/dvdt/xvsy/ff29b96affc6723bb9c66da1011f31900af679dd/src/cljc/xvsy/scale.cljc
clojure
exploits clojure compare to sort int to int, [y1 y2] to [y2 y3] LinMinMaxScalar is for real numbers. It maps the minimum value seen to the bottom of the range, and the maximum value seen to the top of the range. a scale that maps a factor (e.g. a string or keyword) to an interval. scalars). This situation ari...
(ns xvsy.scale "Namespace for mapping data onto aesthetic (i.e. x, y, color, etc.) coordinates." (:require [c2.ticks :as ticks] [vomnibus.color-brewer :as color-brewer] [xvsy.conf] [xvsy.utils :as utils])) Protocols and Multimethods (defprotocol Scalar "Represents trainin...
3a566118b501598dd5356218761a764d68b2f5668baf5764914c8ccc032415a9
kaos/ecapnp
test_capnp.erl
-file("test.capnp", 1). This file was generated 2014 - 05 - 16 10:39:57 UTC by ecapnp 0.2 . %% -module(test_capnp). -vsn(16752831063434032545). -export([schema/1, testAnno/0, testAnno/1, '17364400218949434058'/0, 'Test'/0, 'Test'/1, '18038429679936549741'/0, '12292473172826227401'/0, '9356761420570873088'/0, ...
null
https://raw.githubusercontent.com/kaos/ecapnp/f351c07730ba134b41b137dd6a6b93069a0908fc/test/test_capnp.erl
erlang
testAnno Test Simple PackedListTest
-file("test.capnp", 1). This file was generated 2014 - 05 - 16 10:39:57 UTC by ecapnp 0.2 . -module(test_capnp). -vsn(16752831063434032545). -export([schema/1, testAnno/0, testAnno/1, '17364400218949434058'/0, 'Test'/0, 'Test'/1, '18038429679936549741'/0, '12292473172826227401'/0, '9356761420570873088'/0, '125...
6e1ec6c77700ff634bbde2b0142379ded3180c0d7b0d3f2e890955d065956bc1
neilprosser/mr-maestro
responses_test.clj
(ns maestro.responses-test (:require [maestro.responses :refer :all] [midje.sweet :refer :all])) (fact "that creating an error for request-limit-exceeded turns it into a retry" (def e (doto (com.amazonaws.AmazonServiceException. "Failed") (.setServiceName "AmazonEC2") ...
null
https://raw.githubusercontent.com/neilprosser/mr-maestro/469790fd712262016729c1d83d4b4e11869237a2/test/maestro/responses_test.clj
clojure
(ns maestro.responses-test (:require [maestro.responses :refer :all] [midje.sweet :refer :all])) (fact "that creating an error for request-limit-exceeded turns it into a retry" (def e (doto (com.amazonaws.AmazonServiceException. "Failed") (.setServiceName "AmazonEC2") ...
f6bb7b28c1e63890da303d4189c986fc48754a5028bb83d96aa2df121eae273e
MarcFontaine/stm32hs
TLC5947.hs
---------------------------------------------------------------------------- -- | -- Module : App.TLC5947 Copyright : ( c ) 2019 -- License : BSD3 -- Maintainer : -- Stability : experimental Portability : GHC - only -- -- LED animation using a TLC5947 controller chip (bit-banging base...
null
https://raw.githubusercontent.com/MarcFontaine/stm32hs/d7afeb8f9d83e01c76003f4b199b45044bd4e383/STM32-Zombie/src/App/TLC5947.hs
haskell
-------------------------------------------------------------------------- | Module : App.TLC5947 License : BSD3 Stability : experimental LED animation using a TLC5947 controller chip (bit-banging based) .
Copyright : ( c ) 2019 Maintainer : Portability : GHC - only TODO : Add DMA / SPI based implementation . module App.TLC5947 where import Prelude hiding (sin) import Control.Monad import Data.Bits import Data.List import STM32.API import STM32.GPIO as GPIO main :: IO () main = animateBitBang ...
527fa7abc5208e85e0b00f1b5bb9d6417c795dea57a544cc841a1cda185304f2
rowangithub/DOrder
mergesort.ml
let rec halve xs = match xs with | [] -> ([], []) | x::xs' -> let (ys, zs) = halve xs' in (x::zs, ys) let rec merge xs ys = match xs with | [] -> ys | x::xs' -> ( match ys with | [] -> xs | y::ys' -> if x < y then x :: (merge xs' ys) else y :: (merge xs ys') ) ...
null
https://raw.githubusercontent.com/rowangithub/DOrder/e0d5efeb8853d2a51cc4796d7db0f8be3185d7df/tests/reachability/mergesort.ml
ocaml
let rec halve xs = match xs with | [] -> ([], []) | x::xs' -> let (ys, zs) = halve xs' in (x::zs, ys) let rec merge xs ys = match xs with | [] -> ys | x::xs' -> ( match ys with | [] -> xs | y::ys' -> if x < y then x :: (merge xs' ys) else y :: (merge xs ys') ) ...
f5d3eeee142922ef62a77c87046ac260b3da554d9a75df1bed786e9eede6a5a0
mdedwards/slippery-chicken
tonal-algo-example.lsp
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; File: tonal-algo-example.lsp ;;; Class Hierarchy : None ;;; Version : 1.0 ;;; ;;; Project: slippery chicken (algorithmic composition) ;;; ;;; Purpose: Lisp example code to accompany tonal.ht...
null
https://raw.githubusercontent.com/mdedwards/slippery-chicken/c1c11fadcdb40cd869d5b29091ba5e53c5270e04/doc/examples/tonal-algo-example.lsp
lisp
File: tonal-algo-example.lsp Project: slippery chicken (algorithmic composition) Purpose: Lisp example code to accompany tonal.html $$ Last modified: 16:37:15 Wed Jun 19 2013 BST **** This file is part of slippery-chicken slippery-chic...
Class Hierarchy : None Version : 1.0 Author : Creation date : 1st October 2012 SVN ID : $ I d : tonal-algo-example.lsp 4006 2013 - 06 - 19 15:53:34Z medward2 $ Licence : Copyright ( c ) 2012 Public License as published by the Free Software ...
4e5684d5ffa5c2c4c35189eb6e6650e25c3a4773b8d7a7955adeafd86caeb85e
rudolph-miller/clipper
s3.lisp
(in-package :cl-user) (defpackage clipper-test.s3 (:use :cl :prove :integral :clipper-test.init :clipper :clipper.config :clipper.format :clipper.database)) (in-package :clipper-test.s3) (plan 2) (connect-to-testdb) (defclass picture () ((id :col-type (:int...
null
https://raw.githubusercontent.com/rudolph-miller/clipper/b07a1be210d5504cd67c8e303168cb4bc09f642e/t/s3.lisp
lisp
(in-package :cl-user) (defpackage clipper-test.s3 (:use :cl :prove :integral :clipper-test.init :clipper :clipper.config :clipper.format :clipper.database)) (in-package :clipper-test.s3) (plan 2) (connect-to-testdb) (defclass picture () ((id :col-type (:int...
f5c44afeb959e24b9b860d5fa90444b48f97330e7fcca7ff46362bd697ddcccd
jrh13/hol-light
pa_j_4.xx_7.xx.ml
(* ------------------------------------------------------------------------- *) (* New version. *) (* ------------------------------------------------------------------------- *) (* camlp5r pa_macro.cmo *) $ I d : pa_o.ml , v 6.50 2013 - 07 - 02 16:12:43 d...
null
https://raw.githubusercontent.com/jrh13/hol-light/d125b0ae73e546a63ed458a7891f4e14ae0409e2/pa_j_4.xx_7.xx.ml
ocaml
------------------------------------------------------------------------- New version. ------------------------------------------------------------------------- camlp5r pa_macro.cmo --------------------------------------------------------------------...
$ I d : pa_o.ml , v 6.50 2013 - 07 - 02 16:12:43 deraugla Exp $ Copyright ( c ) INRIA 2007 - 2012 #load "pa_extend.cmo"; #load "q_MLast.cmo"; #load "pa_reloc.cmo"; open Pcaml; Pcaml.syntax_name.val := "OCaml"; Pcaml.no_constructors_arity.val := True; $ I d : reloc.ml , v 6.26 2012 - 03 - 09 14:01:54 deraugl...
cfaaf9581631aea2033f6fa51470ff1f37a9d2ae59c246897a641ea1402b406b
krisajenkins/SuperBomberElf
Render.hs
{-# LANGUAGE OverloadedStrings #-} # LANGUAGE RecordWildCards # module Render where import Control.Lens import Data.Aeson import qualified Data.Map as Map import Data.Maybe import Types displayPosition :: Position -> Value displayPosition Position {..} = object [("x", t...
null
https://raw.githubusercontent.com/krisajenkins/SuperBomberElf/3442095fc53e7bdb0709fc60575324cfb4b948db/server/src/Render.hs
haskell
# LANGUAGE OverloadedStrings #
# LANGUAGE RecordWildCards # module Render where import Control.Lens import Data.Aeson import qualified Data.Map as Map import Data.Maybe import Types displayPosition :: Position -> Value displayPosition Position {..} = object [("x", toJSON _x), ("y", toJSON _y)] displ...
95a2f1bd50e64aa308fb6718b595e7ce7dc3aa2f1d46de582cef2be6b3463c46
mekispeter/haskell2019spring
haskell_may_6_starter.hs
Functional Programming for Logicians 2019 Spring May 6 session To Do : - Instantiating Monad for List - Instantiating Monad for Maybe - Monadic operations vs do notation - Monadizing list comprehension We start with a considerable amount of initial code in each section . Functional P...
null
https://raw.githubusercontent.com/mekispeter/haskell2019spring/18fa81092cdc7a15c8ef92a2eff8274dfe79d00d/src/haskell_may_6_starter.hs
haskell
> lf <*> lx > lstf <*> lstx <1,4,9,16,25,36,49,1,8,27,64,125,216,343,1,16,81,256,625,1296,2401> return :: a -> m a >>= binding (>>=) :: m a -> (a -> m b) -> m b >> sequencing (>>) :: m a -> m b -> m b return :: a -> m a >>= binding (>>=) :: m a -> (a -> m b) -> m b >> sequencing (>>) :: m a -> m b -> m b ...
Functional Programming for Logicians 2019 Spring May 6 session To Do : - Instantiating Monad for List - Instantiating Monad for Maybe - Monadic operations vs do notation - Monadizing list comprehension We start with a considerable amount of initial code in each section . Functional P...
44fd0cc5840af6524c2c720e0931763d3a7bf046df417266cc09e172f99bd00a
igorhvr/bedlam
cring.scm
;;;"cring.scm" Extend Scheme numerics to any commutative ring. Copyright ( C ) 1997 , 1998 , 2001 ; ;Permission to copy this software, to modify it, to redistribute it, ;to distribute modified versions, and to use it for any purpose is ;granted, subject to the following restrictions and understandings. ; 1 . Any co...
null
https://raw.githubusercontent.com/igorhvr/bedlam/b62e0d047105bb0473bdb47c58b23f6ca0f79a4e/iasylum/slib/3b2/cring.scm
scheme
"cring.scm" Extend Scheme numerics to any commutative ring. Permission to copy this software, to modify it, to redistribute it, to distribute modified versions, and to use it for any purpose is granted, subject to the following restrictions and understandings. in full. this software will be error-free, and I am unde...
Copyright ( C ) 1997 , 1998 , 2001 1 . Any copy made of this software must include this copyright notice 2 . I have made no warranty or representation that the operation of 3 . In conjunction with products arising from the use of this (require 'common-list-functions) (require 'relational-database) (require 'da...
417bf9a1e60841a907a2e81b06b41f028489c9fe8944ece1b1b8a788af4dacef
ekmett/haskell
Unsafe.hs
{-# Language Unsafe #-} {-# Language MagicHash #-} -- | Copyright : ( c ) 2020 License : BSD-2 - Clause OR Apache-2.0 Maintainer : < > -- Stability : experimental -- Portability: non-portable module Data.Type.Unsafe ( SingT(..) , FromPtr# , FromWordPtr# , Me# , Z# , S# , makeNice ...
null
https://raw.githubusercontent.com/ekmett/haskell/37ad048531f5a3a13c6dfbf4772ee4325f0e4458/types/src/Data/Type/Unsafe.hs
haskell
# Language Unsafe # # Language MagicHash # | Stability : experimental Portability: non-portable
Copyright : ( c ) 2020 License : BSD-2 - Clause OR Apache-2.0 Maintainer : < > module Data.Type.Unsafe ( SingT(..) , FromPtr# , FromWordPtr# , Me# , Z# , S# , makeNice ) where import Data.Type.Internal import Data.Type.Internal.TH import Data.Type.Internal.Instances ()
86591627897f2868bc8b8290fc34b6aa1216a30954729388ec170756ccdba64c
jvranish/TheExperiment
Type.hs
module Language.TheExperiment.Parser.Type ( aTypeSignature , aType ) where import Control.Applicative hiding ( (<|>), many ) import Control.Monad import Text.Parsec import Language.TheExperiment.Parser.Lexer import Language.TheExperiment.AST.Type aTypeSignature :: EParser TypeSignature aTypeSignature = lif...
null
https://raw.githubusercontent.com/jvranish/TheExperiment/54ca832d2f62a928a992b4c23dadf9653d13a5a7/src/Language/TheExperiment/Parser/Type.hs
haskell
The 'try' is specially positioned to not consume any input if until we match the ':' then we're committed
module Language.TheExperiment.Parser.Type ( aTypeSignature , aType ) where import Control.Applicative hiding ( (<|>), many ) import Control.Monad import Text.Parsec import Language.TheExperiment.Parser.Lexer import Language.TheExperiment.AST.Type aTypeSignature :: EParser TypeSignature aTypeSignature = lif...
5d3bb69b17c91228acad5932d312e8ad817d671bf33972f2640e71d6c2bcb49a
nikomatsakis/a-mir-formality
grammar.rkt
#lang racket (require redex/reduction-semantics racket/set "../logic/grammar.rkt" ) (provide (all-defined-out)) ; Naming convention: ; * Rust keywords use the keyword * Nonterminals and variables use CamelCase , as do random VariantNames not part of Rust syntax , ; like TyAdt (define...
null
https://raw.githubusercontent.com/nikomatsakis/a-mir-formality/bc951e21bff2bae1ccab8cc05b2b39cfb6365bfd/racket-src/ty/grammar.rkt
racket
Naming convention: like TyAdt A *scheme* consists of some term and some variables/implications. FIXME: give a real explanation lifetime, etc) Parameter: value for a generic parameter This is an internal category used in the outlives code -- it represents the kinds of nodes to which we add 'outlives' edges...
#lang racket (require redex/reduction-semantics racket/set "../logic/grammar.rkt" ) (provide (all-defined-out)) * Rust keywords use the keyword * Nonterminals and variables use CamelCase , as do random VariantNames not part of Rust syntax , (define-extended-language formality-ty formal...
c2dcd6f547bb654c596ec63e23402ecca5f0f43f3f7c3184eba96cabc32d24a8
karlhof26/gimp-scheme
JMS-Space_Galaxy.scm
(define (fg/bg-selection image drawable) (gimp-edit-bucket-fill drawable BUCKET-FILL-FG LAYER-MODE-NORMAL 100 0 FALSE 0 0) (gimp-selection-invert image) (gimp-edit-bucket-fill drawable BUCKET-FILL-BG LAYER-MODE-NORMAL 100 0 FALSE 0 0) ) (define (get-blending-mode-galaxy mode) (let* ((modenum...
null
https://raw.githubusercontent.com/karlhof26/gimp-scheme/826abc702902065645f634dc1a657443ef3f231c/JMS-Space_Galaxy.scm
scheme
(gimp-displays-flush) (gimp-message "line320") (gimp-message "line350") (gimp-displays-flush) (gimp-displays-flush) (gimp-displays-flush) (gimp-message "line431") (gimp-displays-flush) (gimp-message "line473") (gimp-message "line492") (gimp-displays-flush) memory cleanup
(define (fg/bg-selection image drawable) (gimp-edit-bucket-fill drawable BUCKET-FILL-FG LAYER-MODE-NORMAL 100 0 FALSE 0 0) (gimp-selection-invert image) (gimp-edit-bucket-fill drawable BUCKET-FILL-BG LAYER-MODE-NORMAL 100 0 FALSE 0 0) ) (define (get-blending-mode-galaxy mode) (let* ((modenum...
b939caabd229a8fed923bb5fcc848bc10bf6cad630275de0a45076f26be90fb5
vodori/chronology
core.clj
(ns chronology.core (:require [clojure.core.async :as async] [chronology.utils :as utils] [clojure.string :as strings] [clojure.set :as set])) (defn new-system [] (let [state (atom {})] (add-watch state :watcher (fn [k r o n] (->> (set/difference ...
null
https://raw.githubusercontent.com/vodori/chronology/81c2f1165d3c91f4eb99a0f6d315d3a97c1cb9d6/src/chronology/core.clj
clojure
(ns chronology.core (:require [clojure.core.async :as async] [chronology.utils :as utils] [clojure.string :as strings] [clojure.set :as set])) (defn new-system [] (let [state (atom {})] (add-watch state :watcher (fn [k r o n] (->> (set/difference ...
9363efe7f69fc9fd3da3e683a7889ecb46058384a2973247f37471e3b74651eb
giorgidze/Hydra
Electronics.hs
{-# LANGUAGE QuasiQuotes, GADTs #-} module Main where import Hydra import Hydra.Solver.Sundials type Pin = (Double,Double) type Time = Double twoPin :: SR ((Pin,Pin),Double) twoPin = [rel| (((p_i,p_v),(n_i,n_v)),u) -> p_v - n_v = u p_i + n_i = 0 |] resistor :: Double -> SR (Pin,Pin) resistor r = [rel| ((p_...
null
https://raw.githubusercontent.com/giorgidze/Hydra/e5b59d0baff27f06368caeb1e9860f1395913ca5/examples/Electronics.hs
haskell
# LANGUAGE QuasiQuotes, GADTs # This is a circuit from our paper simpleCircuit3 :: SR (Double,Double) sigrel (i,u) -> $vSourceAC 1 1$ <> ((acp_i, acp_v), (acn_i, acn_v)) $ground$ <> (gp_i,gp_v) connect acp_v r1p_v lp_v connect r1n_i r2p_i r3p_i u = acp_v - acn_v |] Figure 7.14 in ...
module Main where import Hydra import Hydra.Solver.Sundials type Pin = (Double,Double) type Time = Double twoPin :: SR ((Pin,Pin),Double) twoPin = [rel| (((p_i,p_v),(n_i,n_v)),u) -> p_v - n_v = u p_i + n_i = 0 |] resistor :: Double -> SR (Pin,Pin) resistor r = [rel| ((p_i, p_v),(n_i, n_v)) -> local u ...
106d1cd9b472a7e4a1000d93f90ff802a4c5728360b6a9bfd10b49bec623d716
eatonphil/owebl
template.ml
open Recore.Std module Context = struct include String.Map type f = string list -> c -> Request.t -> string and c = m t and m = | Var of string | Fun of f | Ctx of c | Arr of c list end (* Template marker. *) let tm_start = "{{" let tm_end = "}}" let rec fulfillKey ...
null
https://raw.githubusercontent.com/eatonphil/owebl/deb9794606a36ea831a260bfe3812e23c0a70fce/src/template.ml
ocaml
Template marker.
open Recore.Std module Context = struct include String.Map type f = string list -> c -> Request.t -> string and c = m t and m = | Var of string | Fun of f | Ctx of c | Arr of c list end let tm_start = "{{" let tm_end = "}}" let rec fulfillKey (key: string) (ctx: Con...
4bb36f3fb4c7701eb8ee6629f1f882a7e3ead1c40f50565417c644fbe4c09614
ds-wizard/engine-backend
DocumentTemplateDraftData.hs
module Wizard.Model.DocumentTemplate.DocumentTemplateDraftData where import Data.Time import qualified Data.UUID as U import GHC.Generics data DocumentTemplateDraftData = DocumentTemplateDraftData { documentTemplateId :: String , questionnaireUuid :: Maybe U.UUID , formatUuid :: Maybe U.UUID , appUuid :: U.UU...
null
https://raw.githubusercontent.com/ds-wizard/engine-backend/d392b751192a646064305d3534c57becaa229f28/engine-wizard/src/Wizard/Model/DocumentTemplate/DocumentTemplateDraftData.hs
haskell
module Wizard.Model.DocumentTemplate.DocumentTemplateDraftData where import Data.Time import qualified Data.UUID as U import GHC.Generics data DocumentTemplateDraftData = DocumentTemplateDraftData { documentTemplateId :: String , questionnaireUuid :: Maybe U.UUID , formatUuid :: Maybe U.UUID , appUuid :: U.UU...
acf04536bb8ad179bb00dc62a3776d7ca82103338e054c04bcf6194fd49227f3
oshyshko/adventofcode
D04.hs
module Y21.D04 where -- NOTE: an impure solution using mutable vectors (ugly, but fun) import Data.Bits ((.|.)) import qualified Data.Vector.Generic.Mutable as VM import qualified Data.Vector.Unboxed as VU import Imports import Parser type PrimV m s v a = (Prim...
null
https://raw.githubusercontent.com/oshyshko/adventofcode/5b562efa83720aea64bfc1e6d3182c1ff6d9c2a1/src/Y21/D04.hs
haskell
NOTE: an impure solution using mutable vectors (ugly, but fun) 7,4,9,5,11,17,23,2,0,14,21,24 continue (no winners) stop when all boards are gone continue (no winners) vector utils
module Y21.D04 where import Data.Bits ((.|.)) import qualified Data.Vector.Generic.Mutable as VM import qualified Data.Vector.Unboxed as VU import Imports import Parser type PrimV m s v a = (PrimMonad m, s ~ PrimState m, VM.MVector v a, a ~ Number) type Number...
5b09f8e284b21ac9745e5315070910e150841199cbc8ff5cf0628af0918e9dce
flipstone/haskell-for-beginners
6_recursive_data_structures.hs
-- Define a Carton type that is similar to your -- Box type from earlier, but which is recursive. -- Instead of being able to contain two items , it -- should be able to contain a divider with a Carton -- on each side. Define a version of map for Cartons . Define a version of filter for Cartons Define a v...
null
https://raw.githubusercontent.com/flipstone/haskell-for-beginners/e586a1f3ef08f21d5181171fe7a7b27057391f0b/problems/chapter_08/6_recursive_data_structures.hs
haskell
Define a Carton type that is similar to your Box type from earlier, but which is recursive. should be able to contain a divider with a Carton on each side.
Instead of being able to contain two items , it Define a version of map for Cartons . Define a version of filter for Cartons Define a version of find for Cartons
b4d6882f8c467c09761a79e1a29b49336bf3ac65490e31eb118fac3bcf65d31b
pascal-knodel/haskell-craft
E20.hs
module E20 where list = [] definition = last list == '\n' && list /= [] -- No exception is thrown. {- list = [] definition = list /= [] && last list == '\n' -- No exception is thrown. -}
null
https://raw.githubusercontent.com/pascal-knodel/haskell-craft/c03d6eb857abd8b4785b6de075b094ec3653c968/Examples/%C2%B7%C2%A0Errors/E20.hs
haskell
No exception is thrown. list = [] definition = list /= [] && last list == '\n' -- No exception is thrown.
module E20 where list = []
52a4778dddd1b34d77eec6015b5457d5e2828c5918f2181a079f12b52e80513e
racket/compiler
embed-me11.rkt
#reader(lib "embed-me11-rd.ss" "tests" "compiler" "embed") "It goes to ~a!\n"
null
https://raw.githubusercontent.com/racket/compiler/88acf8a1ec81fec0fbcb6035af1d994d2fec4154/compiler-test/tests/compiler/embed/embed-me11.rkt
racket
#reader(lib "embed-me11-rd.ss" "tests" "compiler" "embed") "It goes to ~a!\n"
26d1c10776532072a3cd5aa888cf775a6f2184e717fd230e0046821b345e9b45
nikomatsakis/a-mir-formality
impl-item.rkt
#lang racket (require redex/reduction-semantics "../grammar.rkt" "../feature-gate.rkt" "../../logic/env.rkt" ) (provide impl-item-decl-rules ) (define-metafunction formality-decl ;; Given the name of a trait and some item within that trait, Return a tuple of: ;; ;; * ...
null
https://raw.githubusercontent.com/nikomatsakis/a-mir-formality/71be4d5c4bd5e91d326277eaedd19a7abe3ac76a/racket-src/decl/decl-to-clause/impl-item.rkt
racket
Given the name of a trait and some item within that trait, Return a tuple of: * The clauses that hold in all crates due to this item * The invariants that hold For a method declared in a trait: currently no logical rules are created. For an associated type declared in a trait, defines * clause for when the alia...
#lang racket (require redex/reduction-semantics "../grammar.rkt" "../feature-gate.rkt" "../../logic/env.rkt" ) (provide impl-item-decl-rules ) (define-metafunction formality-decl impl-item-decl-rules : CrateDecls CrateId (impl KindedVarIds TraitRef where Biformulas) ImplI...
46cb15db35fa23be04cc37626886949f9ab4637406f7316ee1e575d77957c00e
fetburner/Coq2SML
extend.mli
(************************************************************************) v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2014 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *...
null
https://raw.githubusercontent.com/fetburner/Coq2SML/322d613619edbb62edafa999bff24b1993f37612/coq-8.4pl4/parsing/extend.mli
ocaml
********************************************************************** // * This file is distributed under the terms of the * GNU Lesser General Public License Version 2.1 ********************************************************************** * Entry keys for constr notations *...
v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2014 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * open Compat type side = Lef...
297b576309bf45a5586b7304cbca237aeea90168b8cd909fc78dce5b8ffa6a34
s-expressionists/Eclector
labeled-objects.lisp
(cl:in-package #:eclector.reader) ;;; Labeled objects (deftype labeled-object-state () '(member :defined :circular :final :final/circular)) (defstruct (%labeled-object (:constructor %make-labeled-object ()) (:predicate nil) (:copier nil)) (state :defined :t...
null
https://raw.githubusercontent.com/s-expressionists/Eclector/acd141db4efdbd88d57a8fe4f258ffc18cc47baa/code/reader/labeled-objects.lisp
lisp
Labeled objects Allocate hash table lazily. Use final object, if it has already been stored Else, use LABELED-OBJECT as placeholder, fix up later Same but without changing the state In cases like recursive READ call (which produced an object in need of being fixed up) would lead to repeatedly traversing the ...
(cl:in-package #:eclector.reader) (deftype labeled-object-state () '(member :defined :circular :final :final/circular)) (defstruct (%labeled-object (:constructor %make-labeled-object ()) (:predicate nil) (:copier nil)) (state :defined :type labeled-object-s...
aeaef3ce226a5145c8495186c16958516d1ad9c4eace54c259072af1705fe0d3
seereason/atp-haskell
Quantified.hs
| ' ' is a subclass of ' IsPropositional ' of formula -- types that support existential and universal quantification. {-# LANGUAGE DeriveDataTypeable #-} # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # {-# LANGUAGE GADTs #-} {-# LANGUAGE RankNTypes #-} # LANGUAGE Sco...
null
https://raw.githubusercontent.com/seereason/atp-haskell/8b3431236369b9bf5b8723225f65cfac1832a0f9/src/Data/Logic/ATP/Quantified.hs
haskell
types that support existential and universal quantification. # LANGUAGE DeriveDataTypeable # # LANGUAGE GADTs # # LANGUAGE RankNTypes # # LANGUAGE OverloadedStrings # * Concrete instance of a quantified formula type ----------------------- QUANTIFIED FORMULAS -- ----------------------- ^ for_all ^ exists | Class ...
| ' ' is a subclass of ' IsPropositional ' of formula # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE ScopedTypeVariables # # LANGUAGE TemplateHaskell # # LANGUAGE TypeFamilies # # LANGUAGE UndecidableInstances # module Data.Logic.ATP.Quantified ( Qua...
c319932068a0e247188b4da9138b4d4080b1d0dd70e47007cad59ccb1c43051c
Naupio/pigame
common_handler.erl
-module(common_handler). -author("Naupio Z.Y. Huang"). -include("common_pb.hrl"). -export([ handle/2 ]). %% heartbeat for keep user alive. handle(#heartbeatReq{}, #{ws_pid := WsPid} = State) -> UnixTime = game_util:unixtime(), RecordData = #heartbeatResp{unixtime = UnixTime}, game_ws_util:ws...
null
https://raw.githubusercontent.com/Naupio/pigame/2290241bb74e6a3a6c2af815ad69dc2926e14f3e/apps/game_server/src/game_handler/common_handler.erl
erlang
heartbeat for keep user alive.
-module(common_handler). -author("Naupio Z.Y. Huang"). -include("common_pb.hrl"). -export([ handle/2 ]). handle(#heartbeatReq{}, #{ws_pid := WsPid} = State) -> UnixTime = game_util:unixtime(), RecordData = #heartbeatResp{unixtime = UnixTime}, game_ws_util:ws_send(WsPid, RecordData), {nor...
bddcf6807e7c60fafd1d11778d29496a88946fb33c0e274597fdf3c58fe074e2
siftrics/sight-clojure
utils.clj
(ns sight.utils (:require [clojure.string :as s] [clojure.string :as s]) (:import org.apache.commons.codec.binary.Base64 (java.io ByteArrayOutputStream))) (def ^:private extension->mime-type {:pdf "application/pdf" :bmp "image/bmp" :gif "image/gif" :jpeg "image/jpeg" :jpg "ima...
null
https://raw.githubusercontent.com/siftrics/sight-clojure/df23938ad566fb5d25f2bb4d4ab7bb791bb1096b/src/sight/utils.clj
clojure
(ns sight.utils (:require [clojure.string :as s] [clojure.string :as s]) (:import org.apache.commons.codec.binary.Base64 (java.io ByteArrayOutputStream))) (def ^:private extension->mime-type {:pdf "application/pdf" :bmp "image/bmp" :gif "image/gif" :jpeg "image/jpeg" :jpg "ima...
921f53fe966dd23cb5ead0a8c0827c115bd0cddf72aef98215f81f52ea77dc12
paweln1986/assert4hs-core
Maybe.hs
{-# OPTIONS_HADDOCK show-extensions #-} -- | -- Module : Test.Fluent.Assertions.Maybe -- Description : Set of assertions for Maybe type Copyright : ( c ) , 2021 License : MIT -- Maintainer : -- Stability : experimental -- -- This library aims to provide a set of combinators to assert `Maybe` typ...
null
https://raw.githubusercontent.com/paweln1986/assert4hs-core/b92b38ce5415e13d938c4f37fa9819247674851e/src/Test/Fluent/Assertions/Maybe.hs
haskell
# OPTIONS_HADDOCK show-extensions # | Module : Test.Fluent.Assertions.Maybe Description : Set of assertions for Maybe type Maintainer : Stability : experimental This library aims to provide a set of combinators to assert `Maybe` type. | assert if the subject under is empty @ assertThat (Just 10) is...
Copyright : ( c ) , 2021 License : MIT module Test.Fluent.Assertions.Maybe (isNothing, isJust, extracting) where import qualified Data.Maybe as Maybe import GHC.Stack (HasCallStack) import Test.Fluent.Assertions ( focus, forceError, inside, simpleAssertion, ) import Test.Fluent.Internal....
e10e8dcfeac38b906f9b713ca41ef0f9a7e19462c57dd0c7021add3271fd96ba
CRogers/obc
info.ml
* info.ml * * This file is part of the Oxford Oberon-2 compiler * Copyright ( c ) 2006 * All rights reserved * * Redistribution and use in source and binary forms , with or without * modification , are permitted provided that the following conditions are met : * * 1 . Redistributions of...
null
https://raw.githubusercontent.com/CRogers/obc/49064db244e0c9d2ec2a83420c8d0ee917b54196/debugger/info.ml
ocaml
* info.ml * * This file is part of the Oxford Oberon-2 compiler * Copyright ( c ) 2006 * All rights reserved * * Redistribution and use in source and binary forms , with or without * modification , are permitted provided that the following conditions are met : * * 1 . Redistributions of...
fa865ff489f7c898cf9e9283b9a36db1ddfa8db4477816c126c2dee012bf7a97
sigrlami/haskellcosm
Config.hs
{-# LANGUAGE DeriveAnyClass #-} # LANGUAGE DeriveGeneric # {-# LANGUAGE OverloadedStrings #-} module Config ( AppConfig(..) , ConnectConfig(..) , LogConfig(..) , MetaConfig(..) , EmailConfig(..) , OperatorConfig(..) , defaultConnectConfig , readCfg , readEvalCfg , viewCfg ) where import ...
null
https://raw.githubusercontent.com/sigrlami/haskellcosm/4b2dcb89a82cf3f2e6fd191e942c4290c2bb84e1/app/api/src/Config.hs
haskell
# LANGUAGE DeriveAnyClass # # LANGUAGE OverloadedStrings # ----------------------------------------------------------------------------- | Top level structure for storing config ^ differenet logging parameters ^ parameters related to meta information ^ system host link ^ API host link ^ API asset host link ^...
# LANGUAGE DeriveGeneric # module Config ( AppConfig(..) , ConnectConfig(..) , LogConfig(..) , MetaConfig(..) , EmailConfig(..) , OperatorConfig(..) , defaultConnectConfig , readCfg , readEvalCfg , viewCfg ) where import Data.Aeson import qualified Data.ByteString.Char8 as BS impo...
313eac261c217a0ef5bf4c2abbcebcc511ae584a06a3f0a81714590febabec23
pokepay/aws-sdk-lisp
meteringmarketplace.lisp
;; DO NOT EDIT: File is generated by AWS-SDK/GENERATOR. (uiop:define-package #:aws-sdk/services/meteringmarketplace (:use) (:use-reexport #:aws-sdk/services/meteringmarketplace/api))
null
https://raw.githubusercontent.com/pokepay/aws-sdk-lisp/836b87df520391478a19462443342dc56f4b3f2c/services/meteringmarketplace.lisp
lisp
DO NOT EDIT: File is generated by AWS-SDK/GENERATOR.
(uiop:define-package #:aws-sdk/services/meteringmarketplace (:use) (:use-reexport #:aws-sdk/services/meteringmarketplace/api))
010b92d6f9ad68afe651e7935100758bd6ffb8ed4fb74c0fd793a4a8eee7c435
stumpwm/stumpwm
kmap.lisp
(in-package #:stumpwm-tests) (defun expand-key-description (&rest desc) (let ((args (list (car desc) :keysym))) (dolist (mod (cdr desc)) (push mod args) (push t args)) (apply 'stumpwm::make-key (nreverse args)))) (defmacro expect-key (kbd &key to-be) `(is (equalp (stumpwm::parse-key ,kbd) (exp...
null
https://raw.githubusercontent.com/stumpwm/stumpwm/7fe59c00810b35843139194525db444a2c26aa72/tests/kmap.lisp
lisp
(in-package #:stumpwm-tests) (defun expand-key-description (&rest desc) (let ((args (list (car desc) :keysym))) (dolist (mod (cdr desc)) (push mod args) (push t args)) (apply 'stumpwm::make-key (nreverse args)))) (defmacro expect-key (kbd &key to-be) `(is (equalp (stumpwm::parse-key ,kbd) (exp...
1570a350d6ffdb9ec61a68ca8e9136af5cb7d01897ffc4515cecebc83d627b1c
danlarkin/subrosa
fs_logging.clj
(ns subrosa.test.plugins.fs-logging (:require [carica.core :refer [config]] [clojure.test :refer :all] [subrosa.hooks :refer [hooks]] [subrosa.plugins.fs-logging :refer [get-log-name format-date format-time add-hooks]] [su...
null
https://raw.githubusercontent.com/danlarkin/subrosa/b8e554ffc1b83572acbbb8f50704d3db44b3770f/test/subrosa/test/plugins/fs_logging.clj
clojure
(ns subrosa.test.plugins.fs-logging (:require [carica.core :refer [config]] [clojure.test :refer :all] [subrosa.hooks :refer [hooks]] [subrosa.plugins.fs-logging :refer [get-log-name format-date format-time add-hooks]] [su...
e372ec1e0bcbe75a7e0bd981c40fcf1add26cbaef12dfb3110790b93ea2d5b20
number571/Haskell
last.hs
module Main where length' :: [a] -> Int length' [] = 0 length' (x:xs) = 1 + length' xs last' :: [a] -> a last' x = x !! (length' x-1) main = print $ last' [1,2,3,4,5]
null
https://raw.githubusercontent.com/number571/Haskell/7da2676c2604706d43791dc89c0ca8c9842aea48/Templates/last.hs
haskell
module Main where length' :: [a] -> Int length' [] = 0 length' (x:xs) = 1 + length' xs last' :: [a] -> a last' x = x !! (length' x-1) main = print $ last' [1,2,3,4,5]
5dba9dea9eb45583ffa06ce44230a57d804186485ee5c486d3085b3cab9630a9
protz/mezzo
InfiniteArray.ml
(**************************************************************************) (* *) Menhir (* *) , INRIA Ro...
null
https://raw.githubusercontent.com/protz/mezzo/4e9d917558bd96067437116341b7a6ea02ab9c39/lib/InfiniteArray.ml
ocaml
************************************************************************ et en Automatique. All rig...
Menhir , INRIA Rocquencourt , PPS , Université Paris Diderot Copyright 2005 - 2008 Institut National de Recherche en Informatique under the terms of the GNU Library General Pu...
f59aa7e76edfa7ae312f5b5fd217b757482ac0ff466149c4d65e8a122a5dcca7
ocaml/ocaml
closure_conversion_aux.ml
(**************************************************************************) (* *) (* OCaml *) (* *) ...
null
https://raw.githubusercontent.com/ocaml/ocaml/a43299f73c74a8305008f2642bb0a7fcb6847327/middle_end/flambda/closure_conversion_aux.ml
ocaml
************************************************************************ OCaml ...
, OCamlPro and , Copyright 2014 - -2016 Jane Street Group LLC the GNU Lesser General Public License version 2.1 , with the [@@@ocaml.warning "+a-4-9-30-40-41-42-66"] open! Int_replace_polymor...
b05a1da1dd3b61ab9129bbd2db3170cf2b0e5f15f06d486b9f85430dfa838e40
jeromesimeon/Galax
physical_table.ml
(***********************************************************************) (* *) (* GALAX *) (* XQuery Engine *) (* ...
null
https://raw.githubusercontent.com/jeromesimeon/Galax/bc565acf782c140291911d08c1c784c9ac09b432/physicaldm/physical_table.ml
ocaml
********************************************************************* GALAX XQuery Engine ...
Copyright 2001 - 2007 . $ I d : physical_table.ml , v 1.8 2007/02/01 22:08:51 simeon Exp $ open Dm open Error open Physical_value let empty_tuple = () let table_of_singleton t = Cursor.cursor_of_singleton t let table_is_empty ta = Cursor.cursor_is_empty ta...
7ade60a7327d05ae446a9b78fb83edaa94e0aa3a30678d1d42c2558a15e0f304
arohner/spectrum
map_destructure.clj
(ns spectrum.examples.good.map-destructure (:require [clojure.spec.alpha :as s])) (s/def ::message string?) (s/fdef foo :args (s/cat :x (s/keys :req-un [::message])) :ret string?) (defn foo [{:keys [message]}] message)
null
https://raw.githubusercontent.com/arohner/spectrum/72b47a91a5ce4567eed547507d25b2528f48c2d1/test/spectrum/examples/good/map_destructure.clj
clojure
(ns spectrum.examples.good.map-destructure (:require [clojure.spec.alpha :as s])) (s/def ::message string?) (s/fdef foo :args (s/cat :x (s/keys :req-un [::message])) :ret string?) (defn foo [{:keys [message]}] message)
4da089095e05dd940a11aa39da54a5474a744870f1b31daf78fa3f243d656d2a
fulcrologic/fulcro-rad-datomic
thing.cljc
(ns com.fulcrologic.rad.test-schema.thing (:require [com.fulcrologic.rad.attributes :refer [defattr]] [com.fulcrologic.rad.attributes-options :as ao] [com.fulcrologic.rad.database-adapters.datomic-options :as do])) (defattr id ::id :long {ao/identity? true do/native-id? true ao/schema :produ...
null
https://raw.githubusercontent.com/fulcrologic/fulcro-rad-datomic/cc8cc0edd001df97ad439fb589ea6c6a423f1df3/src/test/com/fulcrologic/rad/test_schema/thing.cljc
clojure
(ns com.fulcrologic.rad.test-schema.thing (:require [com.fulcrologic.rad.attributes :refer [defattr]] [com.fulcrologic.rad.attributes-options :as ao] [com.fulcrologic.rad.database-adapters.datomic-options :as do])) (defattr id ::id :long {ao/identity? true do/native-id? true ao/schema :produ...
292332544cfa4c6b0681631a45bac7a0fd610350251460e4565fdfc61ac23765
kit-ty-kate/spdx_licenses
lexer.mli
SPDX - License - Identifier : MIT exception Error val main : Lexing.lexbuf -> Parser.token
null
https://raw.githubusercontent.com/kit-ty-kate/spdx_licenses/22f3100d8196521b9243990261864d255430396c/src/lexer.mli
ocaml
SPDX - License - Identifier : MIT exception Error val main : Lexing.lexbuf -> Parser.token
25cf2de13dff24a580825f6db4e1808bc9d621acd97222c05f890d9f900d5112
OCamlPro/ez_api
ezNodeJS.ml
(**************************************************************************) (* *) Copyright 2018 - 2022 OCamlPro (* *) (* All right...
null
https://raw.githubusercontent.com/OCamlPro/ez_api/5253f7dd8936e923290aa969ee43ebd3dc6fce2d/src/request/js/nodejs/ezNodeJS.ml
ocaml
************************************************************************ All rights reserved. This file is distributed under the terms of the exception on linking descr...
Copyright 2018 - 2022 OCamlPro GNU Lesser General Public License version 2.1 , with the special open Nodejs_common module Interface = struct let get ?meth ?headers ?msg url f = log ?meth url msg; let protocol = get_protocol url in let options = { me...
5b947d611296b685e12e3ae881e7b761b914489efc0570d8e57e440d34e9b01e
AmpersandTarski/Ampersand
Conjuncts.hs
# LANGUAGE DeriveGeneric # # LANGUAGE MultiParamTypeClasses # module Ampersand.Output.ToJSON.Conjuncts (Conjuncts) where import Ampersand.ADL1 import Ampersand.FSpec.ToFSpec.NormalForms (conjNF) import Ampersand.Output.ToJSON.JSONutils import qualified RIO.NonEmpty as NE newtype Conjuncts = Conjuncts [JSONConjunct] ...
null
https://raw.githubusercontent.com/AmpersandTarski/Ampersand/cb2306a09ce79d5609ccf8d3e28c0a1eb45feafe/src/Ampersand/Output/ToJSON/Conjuncts.hs
haskell
# LANGUAGE DeriveGeneric # # LANGUAGE MultiParamTypeClasses # module Ampersand.Output.ToJSON.Conjuncts (Conjuncts) where import Ampersand.ADL1 import Ampersand.FSpec.ToFSpec.NormalForms (conjNF) import Ampersand.Output.ToJSON.JSONutils import qualified RIO.NonEmpty as NE newtype Conjuncts = Conjuncts [JSONConjunct] ...
324271f7ed702075016f1f32d522ba0fa96eacd369b66f3b87a97ec12b9ad125
csabahruska/jhc-components
NodeAnalyze.hs
-- a fast, straightforward points to analysis -- meant to determine nodes that are always in whnf and find out evals or that always -- apply to a known value module Grin.NodeAnalyze(nodeAnalyze) where import Control.Monad.Identity hiding(join) import Control.Monad.RWS hiding(join) import Data.Maybe import Text.Pri...
null
https://raw.githubusercontent.com/csabahruska/jhc-components/a7dace481d017f5a83fbfc062bdd2d099133adf1/jhc-grin/src/Grin/NodeAnalyze.hs
haskell
a fast, straightforward points to analysis meant to determine nodes that are always in whnf apply to a known value putStrLn "----------------------------" putStrLn "----------------------------" putStrLn "----------------------------" putStrLn "----------------------------" putStrLn "----------------------------" s...
and find out evals or that always module Grin.NodeAnalyze(nodeAnalyze) where import Control.Monad.Identity hiding(join) import Control.Monad.RWS hiding(join) import Data.Maybe import Text.Printf import qualified Data.Map as Map import qualified Data.Set as Set import Grin.Grin hiding(V) import Grin.Noodle import ...
03106972ee64566a701c1d27f77a86426e7accd24b1741d686719b366b9cf65e
wireapp/saml2-web-sso
Orphans.hs
# OPTIONS_GHC -fno - warn - orphans # -- FUTUREWORK: disallow orphans. module SAML2.WebSSO.Orphans where import Control.Monad ((<=<)) import Data.Aeson import Data.String.Conversions import qualified Data.Text as Text import Data.X509 as X509 import SAML2.Util (normURI, parseURI', renderURI) import Servant hiding (U...
null
https://raw.githubusercontent.com/wireapp/saml2-web-sso/ac88b934bb4a91d4d4bb90c620277188e4087043/src/SAML2/WebSSO/Orphans.hs
haskell
FUTUREWORK: disallow orphans.
# OPTIONS_GHC -fno - warn - orphans # module SAML2.WebSSO.Orphans where import Control.Monad ((<=<)) import Data.Aeson import Data.String.Conversions import qualified Data.Text as Text import Data.X509 as X509 import SAML2.Util (normURI, parseURI', renderURI) import Servant hiding (URI) import Text.XML.DSig import U...
30b91d2fd30865d86afb74a21939fdf55e38f50a866a96e8c0e871b32becfec0
louispan/ghcjs-base-stub
Marshal.hs
# OPTIONS_GHC -fno - warn - orphans # {-# OPTIONS_GHC -Wno-redundant-constraints #-} # LANGUAGE DefaultSignatures , TypeOperators , ScopedTypeVariables , DefaultSignatures , FlexibleContexts , FlexibleInstances , OverloadedStrings...
null
https://raw.githubusercontent.com/louispan/ghcjs-base-stub/bbf9ac7f585f8862d950cc20a30cb78a2df755b5/src/GHCJS/Marshal.hs
haskell
# OPTIONS_GHC -Wno-redundant-constraints # # INLINE fromJSValUnchecked # # INLINE fromJSValUnchecked # {-# INLINE fromJSVal #-} # INLINE fromJSValUnchecked # # INLINE fromJSValUnchecked # # INLINE fromJSValUnchecked # # INLINE fromJSValUnchecked # # INLINE fromJSValUncheckedListOf # # INLINE fromJSValUnchecked # # ...
# OPTIONS_GHC -fno - warn - orphans # # LANGUAGE DefaultSignatures , TypeOperators , ScopedTypeVariables , DefaultSignatures , FlexibleContexts , FlexibleInstances , OverloadedStrings , TupleSections , ...
c65d3966992e6426488aa4d492ed444998077b2adbd34b72c4a5448e5395d921
nomnom-insights/nomnom.stature
metrics.clj
(ns stature.metrics (:refer-clojure :exclude [count]) (:require [com.stuartsierra.component :as component] [stature.metrics.protocol :as protocol]) (:import (com.timgroup.statsd NonBlockingStatsDClient NonBlockingStatsDClientBuilder))) (def ^:final ^:private empty-tags (make-array String...
null
https://raw.githubusercontent.com/nomnom-insights/nomnom.stature/857111b711d637094e813487acab7e915f78b06d/src/stature/metrics.clj
clojure
(ns stature.metrics (:refer-clojure :exclude [count]) (:require [com.stuartsierra.component :as component] [stature.metrics.protocol :as protocol]) (:import (com.timgroup.statsd NonBlockingStatsDClient NonBlockingStatsDClientBuilder))) (def ^:final ^:private empty-tags (make-array String...
a0c6edd53eacb6d8d20a61218f6e2147c2599e6cf6ff9442e5c0aee85816176a
RedlineResearch/floorplan
Quote.hs
| Module : Language . Rust . Quote Description : Quasiquotes for Rust AST Copyright : ( c ) , 2017 - 2018 License : BSD - style Maintainer : Stability : experimental Portability : GHC Quasiquoters for converting Rust code into the equivalent patterns and expressions . These are...
null
https://raw.githubusercontent.com/RedlineResearch/floorplan/dbaa7e6649eed18707ff8a27ee3c33fa83b47fcf/src/Language/Rust/Quote.hs
haskell
liftData :: Data a => a -> Q Exp | Given a parser, convert it into a quasiquoter. The quasiquoter produced does not support declarations and types. For patterns, it replaces any 'Span' and 'Position' field with a wild pattern. Run the parser | Replace 'Span' and 'Position' with wild patterns >>> void [lit| 1.4e...
| Module : Language . Rust . Quote Description : Quasiquotes for Rust AST Copyright : ( c ) , 2017 - 2018 License : BSD - style Maintainer : Stability : experimental Portability : GHC Quasiquoters for converting Rust code into the equivalent patterns and expressions . These are...
dd1c56b275a21d8db318afc77c585969efc7d56c754da02ce6acdcf886966ef8
michaelklishin/quartzite
querying_test.clj
(ns clojurewerkz.quartzite.test.querying-test (:require [clojurewerkz.quartzite.scheduler :as sched] [clojurewerkz.quartzite.jobs :as j] [clojurewerkz.quartzite.matchers :as matchers] [clojurewerkz.quartzite.triggers :as t] [clojurewerkz.quartzite.schedule.calend...
null
https://raw.githubusercontent.com/michaelklishin/quartzite/de96a2ae95ec232df3e24cf10f4e5ff33af3553b/test/clojurewerkz/quartzite/test/querying_test.clj
clojure
Group Names operations wait for the job to be scheduled and start running before querying
(ns clojurewerkz.quartzite.test.querying-test (:require [clojurewerkz.quartzite.scheduler :as sched] [clojurewerkz.quartzite.jobs :as j] [clojurewerkz.quartzite.matchers :as matchers] [clojurewerkz.quartzite.triggers :as t] [clojurewerkz.quartzite.schedule.calend...
320db6e00f5498344efacce7a985eff2911f7cce7a97c7fc9ed93339cf773685
locusmath/locus
fp_monoid.clj
(ns locus.algebra.semigroup.monoid.fp-monoid (:require [locus.set.logic.core.set :refer :all] [locus.set.logic.limit.product :refer :all] [locus.set.mapping.general.core.object :refer :all] [locus.set.logic.structure.protocols :refer :all] [locus.set.copresheaf.structur...
null
https://raw.githubusercontent.com/locusmath/locus/b232579217be4e39458410893827a84d744168e4/src/clojure/locus/algebra/semigroup/monoid/fp_monoid.clj
clojure
Finitely presented monoids A finitely presented monoid is the combination of a set of generators, and a set of relations of the terms over those generators. In order to retrieve the generating generalized to get the morphic generating set of any category. Get the commutativity relations of a presentation The free...
(ns locus.algebra.semigroup.monoid.fp-monoid (:require [locus.set.logic.core.set :refer :all] [locus.set.logic.limit.product :refer :all] [locus.set.mapping.general.core.object :refer :all] [locus.set.logic.structure.protocols :refer :all] [locus.set.copresheaf.structur...
261041b7427e68facaf06f621327dabddb6ee9b0cd1e2ec5ad2a62810c549b7c
music-suite/music-suite
Pitch.hs
-- |  Standard pitch representation. module Music.Pitch ( module Data.Semigroup, module Data.VectorSpace, module Data.AffineSpace, module Data.AffineSpace.Point, module Music.Pitch.Augmentable, module Music.Pitch.Alterable, module Music.Pitch.Absolute, module Music.Pitch.Common, module...
null
https://raw.githubusercontent.com/music-suite/music-suite/7f01fd62334c66418043b7a2d662af127f98685d/src/Music/Pitch.hs
haskell
|  Standard pitch representation.
module Music.Pitch ( module Data.Semigroup, module Data.VectorSpace, module Data.AffineSpace, module Data.AffineSpace.Point, module Music.Pitch.Augmentable, module Music.Pitch.Alterable, module Music.Pitch.Absolute, module Music.Pitch.Common, module Music.Pitch.Equal, module Music....
2e47f11cdd6718ab356b2aa121c618106b6225d65d289ae011177e203b2126b9
BitGameEN/bitgamex
cowboy_metrics_h.erl
Copyright ( c ) 2017 , < > %% %% Permission to use, copy, modify, and/or distribute this software for any %% purpose with or without fee is hereby granted, provided that the above %% copyright notice and this permission notice appear in all copies. %% THE SOFTWARE IS PROVIDED " AS IS " AND THE AUTHOR DISCLAIMS A...
null
https://raw.githubusercontent.com/BitGameEN/bitgamex/151ba70a481615379f9648581a5d459b503abe19/src/deps/cowboy/src/cowboy_metrics_h.erl
erlang
Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies. WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVE...
Copyright ( c ) 2017 , < > THE SOFTWARE IS PROVIDED " AS IS " AND THE AUTHOR DISCLAIMS ALL WARRANTIES ANY SPECIAL , DIRECT , INDIRECT , OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE , DATA OR PROFITS , WHETHER IN AN -module(cowboy_metrics_h). -behavior(cowboy_stream). -expor...
a403ece3ac23dcd1a4607daf03eedcdc6e51d1484ca9a379b1255713ed7288bb
singleheart/programming-in-haskell
ex5.hs
qsort_uniq :: Ord a => [a] -> [a] qsort_uniq [] = [] qsort_uniq (x:xs) = qsort_uniq smaller ++ [x] ++ qsort_uniq larger where smaller = [a | a <- xs, a < x] larger = [b | b <- xs, b > x]
null
https://raw.githubusercontent.com/singleheart/programming-in-haskell/80c7efc0425babea3cd982e47e121f19bec0aba9/ch01/ex5.hs
haskell
qsort_uniq :: Ord a => [a] -> [a] qsort_uniq [] = [] qsort_uniq (x:xs) = qsort_uniq smaller ++ [x] ++ qsort_uniq larger where smaller = [a | a <- xs, a < x] larger = [b | b <- xs, b > x]