_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
f129159a0284f039b9059d9add87c20ef1f69f3b8960ea53da31af624b996e77
ChrisPenner/catalyst
Numeric.hs
module Control.Category.Numeric where -- class Numeric k where -- num :: Int -> k a Int add : : k ( Int , Int ) Int -- negate' :: k Int Int mult : : k ( Int , Int ) Int div ' : : k ( Int , Int ) Int mod ' : : k ( Int , Int ) Int -- instance Numeric (->) where -- num = const -- add = uncurry (...
null
https://raw.githubusercontent.com/ChrisPenner/catalyst/6b25a3b810737a335fe3ac9a532161b92f7f4e9f/src/Control/Category/Numeric.hs
haskell
class Numeric k where num :: Int -> k a Int negate' :: k Int Int instance Numeric (->) where num = const add = uncurry (+) negate' = negate mult = uncurry (*) div' = uncurry div mod' = uncurry mod
module Control.Category.Numeric where add : : k ( Int , Int ) Int mult : : k ( Int , Int ) Int div ' : : k ( Int , Int ) Int mod ' : : k ( Int , Int ) Int
fbacb090236f207186a71d33e847af1bcff168b158f351bf68a981281742c7e0
damn/cdq
movement.clj
(ns game.components.movement (:use utils.core (game [settings :only (tile-width)]) (game.components core body position [update :only (max-delta)]) (game.maps cell-grid) (game.utils geom raycast))) (defn- create-new-position [delta [vx vy] [old-x old-y] speed] [(+ old-x (* vx speed delta)) ...
null
https://raw.githubusercontent.com/damn/cdq/5093dbdba91c445e403f53ce96ead05d5ed8262b/src/game/components/movement.clj
clojure
checks if colliding with other solid bodies -> rename? rename new-tiles, new-cells ? manual :posi-changed of solid body because of performance issues (calc-touched-cells) == all-previously-touched-tiles? == all that remain to be checked? to-check-cells not nil because not blocked remaining not nil because not mo...
(ns game.components.movement (:use utils.core (game [settings :only (tile-width)]) (game.components core body position [update :only (max-delta)]) (game.maps cell-grid) (game.utils geom raycast))) (defn- create-new-position [delta [vx vy] [old-x old-y] speed] [(+ old-x (* vx speed delta)) ...
fa3a439d39fbbe518956325e377c8011cf7b0bb81f0918521a42122d7b9f5d4d
richhickey/clojure-contrib
test_load_all.clj
;;; test_load_all.clj - loads all contrib libraries for testing purposes by , Copyright ( c ) , 2009 . All rights reserved . The use and distribution terms for this software are covered by the Eclipse ;; Public License 1.0 (-1.0.php) ;; which can be found in the file epl-v10.html at the root of this ;; d...
null
https://raw.githubusercontent.com/richhickey/clojure-contrib/40b960bba41ba02811ef0e2c632d721eb199649f/src/test/clojure/clojure/contrib/test_load_all.clj
clojure
test_load_all.clj - loads all contrib libraries for testing purposes Public License 1.0 (-1.0.php) which can be found in the file epl-v10.html at the root of this distribution. By using this software in any fashion, you are agreeing to be bound by the terms of this license. You must not remove this notice, or a...
by , Copyright ( c ) , 2009 . All rights reserved . The use and distribution terms for this software are covered by the Eclipse (ns clojure.contrib.test-load-all (:use clojure.test clojure.contrib.find-namespaces)) (def deprecated-contrib-namespaces '[clojure.contrib.javadoc]) (defn loadable-con...
98c960991ea2bdd9499adc69b65b9c1e8ad9e6ce106744dfdffad5ffe28ce0df
mourjo/procrustes
client.clj
(ns procrustes.client (:require [cheshire.core :as cc] [procrustes.env :as env] [clj-http.client :as http] [clj-statsd :as statsd] [clojure.tools.logging :as ctl] [com.climate.claypoole :as cp] [procrustes.utils :as utils] [clojure.ja...
null
https://raw.githubusercontent.com/mourjo/procrustes/a739aaaaa8c6c842fdbf1a958b0000a6e7160de3/src/procrustes/client.clj
clojure
(ns procrustes.client (:require [cheshire.core :as cc] [procrustes.env :as env] [clj-http.client :as http] [clj-statsd :as statsd] [clojure.tools.logging :as ctl] [com.climate.claypoole :as cp] [procrustes.utils :as utils] [clojure.ja...
030ca4487eac4b3ecab001fa8a6fc2ab993b12c3c991e8fd585eba872067c07c
dradtke/Lisp-Text-Editor
package.lisp
(defpackage :cl-colors (:use :common-lisp :cl-utilities) (:export rgb red green blue rgba alpha add-alpha hsv hue saturation value rgb->hsv hsv->rgb ->hsv ->rgb convex-combination hue-combination rgb-combination rgba-combination hsv-combination))
null
https://raw.githubusercontent.com/dradtke/Lisp-Text-Editor/b0947828eda82d7edd0df8ec2595e7491a633580/quicklisp/dists/quicklisp/software/cl-colors-20101006-git/package.lisp
lisp
(defpackage :cl-colors (:use :common-lisp :cl-utilities) (:export rgb red green blue rgba alpha add-alpha hsv hue saturation value rgb->hsv hsv->rgb ->hsv ->rgb convex-combination hue-combination rgb-combination rgba-combination hsv-combination))
4944fe7211a78b0f94af4b542ffb32ab74adb846aa835b184cbee075dc63a2e0
haskell/hackage-server
CmdLine.hs
module Distribution.Client.Mirror.CmdLine ( MirrorOpts(..) , validateOpts ) where -- stdlib import Control.Monad import Data.Maybe (fromMaybe) import System.Exit (exitSuccess) import System.Console.GetOpt Cabal import Distribution.Package import Distribution.Verbosity import Distribution.Simple.Utils hiding...
null
https://raw.githubusercontent.com/haskell/hackage-server/6c8689a779b688b3e6b927614c90318936d5bb3f/src/Distribution/Client/Mirror/CmdLine.hs
haskell
stdlib hackage
module Distribution.Client.Mirror.CmdLine ( MirrorOpts(..) , validateOpts ) where import Control.Monad import Data.Maybe (fromMaybe) import System.Exit (exitSuccess) import System.Console.GetOpt Cabal import Distribution.Package import Distribution.Verbosity import Distribution.Simple.Utils hiding (warn) i...
512e0fc5a1dd2d436ca247756db362ae3aaedc4c42cdd540f3dfc9381e10fc2b
alexandergunnarson/quantum
nondeterministic.cljc
(ns ^{:doc "Functions centered around non-determinism (randomness)." :attribution "alexandergunnarson"} quantum.core.nondeterministic (:refer-clojure :exclude [reduce next for last nth int double conj! contains? shuffle count map get partition byte char long bytes chars longs]) (:r...
null
https://raw.githubusercontent.com/alexandergunnarson/quantum/0c655af439734709566110949f9f2f482e468509/src/quantum/core/nondeterministic.cljc
clojure
for now TO EXPLORE - java.util.Random sometimes one wants generators with a particular distribution ========================= -performance.com circumstances - it is backwards compatible with existing code, but uses cheaper operations internally. -1 means auto-optimiing entropy on demand from the main thread ...
(ns ^{:doc "Functions centered around non-determinism (randomness)." :attribution "alexandergunnarson"} quantum.core.nondeterministic (:refer-clojure :exclude [reduce next for last nth int double conj! contains? shuffle count map get partition byte char long bytes chars longs]) (:r...
9bc9930bbf18e2f48b57f8f08125dcee003f2ceb4392a5b8f13aa0190db7b7ba
cardmagic/lucash
srfi-14.scm
SRFI-14 character - sets library -*- Scheme -*- ;;; - Ported from MIT Scheme runtime by . - Massively rehacked & extended by 6/98 . - Massively redesigned and rehacked 5/2000 during SRFI process . ;;; At this point, the code bears the following relationship to the MIT Scheme code : " This is my gran...
null
https://raw.githubusercontent.com/cardmagic/lucash/0452d410430d12140c14948f7f583624f819cdad/reference/scsh-0.6.6/scheme/srfi/srfi-14.scm
scheme
At this point, the code bears the following relationship to the the head, and I have replaced the handle." Nonetheless, we preserve this file for the tedious details. examination will show, the implementation of the common API is *quite* different -- I don't even mean at the in-the-small level, but at the ...
SRFI-14 character - sets library -*- Scheme -*- - Ported from MIT Scheme runtime by . - Massively rehacked & extended by 6/98 . - Massively redesigned and rehacked 5/2000 during SRFI process . MIT Scheme code : " This is my grandfather 's axe . My father replaced the MIT Scheme copyright : C...
6238a4f609a5793e9e09cc8c0f87c9b24c714030044ded28a276e93af467825d
BrunoBonacci/mulog
console_json_test.clj
(ns com.brunobonacci.mulog.publishers.advanced-console.console-json-test (:require [midje.sweet :refer :all] [com.brunobonacci.mulog :as u] [com.brunobonacci.mulog.common.json :as json])) (defmacro with-console-publisher [config & body] `(let [pub# (u/start-publisher! ~config) ...
null
https://raw.githubusercontent.com/BrunoBonacci/mulog/40a10ce3a5953ee922288aaca9fae3e8231f6f6c/mulog-adv-console/test/com/brunobonacci/mulog/publishers/advanced_console/console_json_test.clj
clojure
with-out-str wouldn't work because publisher runs on a different thread datetimes are formatted to the millis
(ns com.brunobonacci.mulog.publishers.advanced-console.console-json-test (:require [midje.sweet :refer :all] [com.brunobonacci.mulog :as u] [com.brunobonacci.mulog.common.json :as json])) (defmacro with-console-publisher [config & body] `(let [pub# (u/start-publisher! ~config) ...
7fa73fc11c0b9350f1cc6dbbbde9d9211a486971c94504f0e4666276a84c07b9
csabahruska/jhc-components
FFI.hs
Generated by DrIFT ( Automatic class derivations for ) # LINE 1 " src / C / FFI.hs " # module C.FFI( CallConv(..), Safety(..), FfiType(..), FfiExport(..), FfiSpec(..), Requires(..) ) where import C.Prims import Data.Binary import Data.Typeable type CName = String data FfiType = Import ...
null
https://raw.githubusercontent.com/csabahruska/jhc-components/a7dace481d017f5a83fbfc062bdd2d099133adf1/jhc-common/src/C/FFI.hs
haskell
! derive: Binary ! * Generated by DrIFT : Look, but Don't Touch. * Imported from other files :-
Generated by DrIFT ( Automatic class derivations for ) # LINE 1 " src / C / FFI.hs " # module C.FFI( CallConv(..), Safety(..), FfiType(..), FfiExport(..), FfiSpec(..), Requires(..) ) where import C.Prims import Data.Binary import Data.Typeable type CName = String data FfiType = Import ...
f54b69d07f6bc26375ed736df4dba9229f026ddb328216d8c1ea7cdf3f3289b0
ethereum/act
HEVM.hs
# Language RecordWildCards # {-# Language TypeApplications #-} {-# Language OverloadedStrings #-} {-# Language DataKinds #-} {-# Language GADTs #-} {-# Language MonadComprehensions #-} {-# Language ViewPatterns #-} module HEVM where import Prelude hiding (lookup, GT, LT) import Syntax import Syntax.Annotated as Anno...
null
https://raw.githubusercontent.com/ethereum/act/36b65b71eea22ebe4287f066190ecf47f4394fa3/src/HEVM.hs
haskell
# Language TypeApplications # # Language OverloadedStrings # # Language DataKinds # # Language GADTs # # Language MonadComprehensions # # Language ViewPatterns # todo: deal with ambiguities in contract name create new addresses for each contract involved in the future addresses could be passed through the cli todo;...
# Language RecordWildCards # module HEVM where import Prelude hiding (lookup, GT, LT) import Syntax import Syntax.Annotated as Annotated hiding (S) import Data.ByteString.UTF8 (toString) import Data.Text (Text, pack, splitOn) import Data.Maybe import Data.List hiding (lookup) import Data.Map hiding (drop, null, fin...
59564e7b3276c2e0d6a396a3e17b852e1f73e4be68979036f645c297af92ef2a
joyofclojure/book-source
udp.clj
(ns joy.udp "The Universal Design Pattern (UDP) example from section 9.2." (:refer-clojure :exclude [get])) (defn beget [o p] (assoc o ::prototype p)) (def put assoc) (defn get [m k] (when m (if-let [[_ v] (find m k)] v (recur (::prototype m) k)))) (def clone (partial beget {}))
null
https://raw.githubusercontent.com/joyofclojure/book-source/b76ef15248dac88c7b1c77c2d461f3aa522a1461/first-edition/src/joy/udp.clj
clojure
(ns joy.udp "The Universal Design Pattern (UDP) example from section 9.2." (:refer-clojure :exclude [get])) (defn beget [o p] (assoc o ::prototype p)) (def put assoc) (defn get [m k] (when m (if-let [[_ v] (find m k)] v (recur (::prototype m) k)))) (def clone (partial beget {}))
6af1687e7d14eb53179830ac65107a68a3201ef55a0ddf9985361e90158f9ef7
racket/drracket
info.rkt
#lang info (define collection 'multi) (define deps '(["base" #:version "6.2.900.10"] "scribble-lib" ["string-constants-lib" #:version "1.12"] "racket-index")) (define build-deps '("at-exp-lib" "rackunit-lib")) (define pkg-desc "Non-GUI code implementi...
null
https://raw.githubusercontent.com/racket/drracket/d3018004ef45767b5c66f308eb851a4891488d85/drracket-tool-text-lib/info.rkt
racket
#lang info (define collection 'multi) (define deps '(["base" #:version "6.2.900.10"] "scribble-lib" ["string-constants-lib" #:version "1.12"] "racket-index")) (define build-deps '("at-exp-lib" "rackunit-lib")) (define pkg-desc "Non-GUI code implementi...
5df60c801b5e4698751eb3aca0a8123855b6b921ac4e7a62c69a7d7df11d9447
ocsigen/js_of_ocaml
js_lexer.mli
Js_of_ocaml compiler * Copyright ( C ) 2013 Hugo Heuzard * Copyright (C) 2013 Hugo Heuzard *) * * Copyright ( C ) 2010 Facebook * * This library is free software ; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public License * version 2.1 as publis...
null
https://raw.githubusercontent.com/ocsigen/js_of_ocaml/38bdb922c5db61f8657a25e78fb3fc5243c2bc11/compiler/lib/js_lexer.mli
ocaml
Js_of_ocaml compiler * Copyright ( C ) 2013 Hugo Heuzard * Copyright (C) 2013 Hugo Heuzard *) * * Copyright ( C ) 2010 Facebook * * This library is free software ; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public License * version 2.1 as publis...
22eb6ca9b1be70a0e061c52b60315906ebd883aae9c41476bea129e400700cfb
effectfully-ou/sketches
Main.hs
module Main where import Control.Exception import Data.IORef import System.IO.Unsafe lastIsFalse :: [Bool] lastIsFalse = unsafePerformIO $ do next <- newIORef False let go = do b <- unsafeInterleaveIO $ readIORef next bs <- unsafeInterleaveIO $ do ...
null
https://raw.githubusercontent.com/effectfully-ou/sketches/7b512a529292e8c4bce80526b3f2b938f8cc8e60/a-law-breaking-hack/src/Main.hs
haskell
[] (1,False) [(1,True)] [(1,True),(2,True),(3,True),(4,True)] (5,False) [(1,False),(2,False),(3,False),(4,False),(5,False)] [(1,True),(2,True),(3,True),(4,True),(5,False)] [(1,True),(2,True),(3,True),(4,True),(5,False)] [(1,False),(2,False),(3,False),(4,False),(5,False)]
module Main where import Control.Exception import Data.IORef import System.IO.Unsafe lastIsFalse :: [Bool] lastIsFalse = unsafePerformIO $ do next <- newIORef False let go = do b <- unsafeInterleaveIO $ readIORef next bs <- unsafeInterleaveIO $ do ...
7ec86587b5820faa82720a1e9d438101cac13e3182fa87149c346b3308980b9e
ad-si/TaskLite
Helpers.hs
# LANGUAGE TypeFamilies # module Helpers where import Protolude as P hiding (get, put) import Crypto.JOSE.JWS (CompactJWS) import Crypto.JWT as Crypto hiding (param) import Crypto.BCrypt import Control.Lens import Data.Aeson as Aeson (Value(..), toJSON, decode, object) import Data.Text.Encoding as T import qualified...
null
https://raw.githubusercontent.com/ad-si/TaskLite/32d010642b5785f63b20cdd65ec5d4b9f34f3b2b/tasklite-server/source-old/Helpers.hs
haskell
TODO: Use EitherT stack to avoid pyramid of doom TODO: Remove duplications with `validateAndAddIdea`
# LANGUAGE TypeFamilies # module Helpers where import Protolude as P hiding (get, put) import Crypto.JOSE.JWS (CompactJWS) import Crypto.JWT as Crypto hiding (param) import Crypto.BCrypt import Control.Lens import Data.Aeson as Aeson (Value(..), toJSON, decode, object) import Data.Text.Encoding as T import qualified...
04861c6edd44beae7e2f46fe20ad9b4d3638fcba70114b26f8be8afd0c912f92
draperlaboratory/VIBES
compile.mli
(***************************************************************************) (* *) Copyright ( C ) 2022/2023 The Charles Stark Draper Laboratory , Inc. (* *) (* This...
null
https://raw.githubusercontent.com/draperlaboratory/VIBES/7f978d66d0b022d1a9262fdfc608b7a2b7c95dff/tools/vibes-parse/lib/compile.mli
ocaml
************************************************************************* This file is provided under the license found in the LICENSE file in the top-level director...
Copyright ( C ) 2022/2023 The Charles Stark Draper Laboratory , Inc. This research was developed with funding from the Defense Advanced Research Projects Agency ( DARPA ) . open Bap_core_theory open Vibes_higher_vars * [ to_core ast target ] compiles the pars...
e6a9ce0e659aab3b90184191a4c9ad76af56ba4c190ca353a60a59affb71f422
oakes/mistakes-were-made
project.clj
(defproject mistakes-were-made "1.8.1-SNAPSHOT" :description "An undo/redo system for Clojure and ClojureScript" :url "-were-made" :license {:name "Public Domain" :url ""} :repositories [["clojars" {:url "" :sign-releases false}]] :profiles {:dev {:main mistakes-were-m...
null
https://raw.githubusercontent.com/oakes/mistakes-were-made/a8fe21e54101b4a43066d37d90f245f42ff88d83/project.clj
clojure
(defproject mistakes-were-made "1.8.1-SNAPSHOT" :description "An undo/redo system for Clojure and ClojureScript" :url "-were-made" :license {:name "Public Domain" :url ""} :repositories [["clojars" {:url "" :sign-releases false}]] :profiles {:dev {:main mistakes-were-m...
d49671486f053b2affc90ab0532bfc1454295727682559a89d315f59ac41dac5
janestreet/universe
sexp_macro.ml
module Blocking = Blocking_reader include Macro include Async_reader
null
https://raw.githubusercontent.com/janestreet/universe/b6cb56fdae83f5d55f9c809f1c2a2b50ea213126/sexp_macro/src/sexp_macro.ml
ocaml
module Blocking = Blocking_reader include Macro include Async_reader
d5c0a0c3734c058ac1dd067e3f2fc30dcb8a82fc34780b1bc43675d0a17d346c
nibbula/yew
groups.lisp
;;; ;;; groups.lisp - Print a list of groups that the current user is in. ;;; (defpackage :groups (:documentation "Print a list of groups that the current user is in.") (:use :cl :opsys :lish) (:export #:!groups )) (in-package :groups) (defcommand groups () "Print a list of groups that the current user ...
null
https://raw.githubusercontent.com/nibbula/yew/43f8df012da277e643e000aeb25adf96fd90d4d0/los/groups.lisp
lisp
groups.lisp - Print a list of groups that the current user is in. End
(defpackage :groups (:documentation "Print a list of groups that the current user is in.") (:use :cl :opsys :lish) (:export #:!groups )) (in-package :groups) (defcommand groups () "Print a list of groups that the current user is in." #+unix (let ((result (map 'list #'uos:group-name (uos:get-groups))...
bc370e709cd8798c48f4fbcd9e82c8e1320aef796c28fc33750e71e50abbeb26
mbutterick/aoc-racket
19.rkt
#lang br (require racket/file rackunit racket/set) (define (string->ints str) (map string->number (string-split str #px",\\s*"))) (define (string->regs str) (list->vector (string->ints str))) (define ((binarize proc) x y) (if (proc x y) 1 0)) (define (make-runner program [calling-thd (current-thread)]) (thread (λ ...
null
https://raw.githubusercontent.com/mbutterick/aoc-racket/2c6cb2f3ad876a91a82f33ce12844f7758b969d6/2019/19.rkt
racket
position immediate relative discovered by trial & error: 2100 too low
#lang br (require racket/file rackunit racket/set) (define (string->ints str) (map string->number (string-split str #px",\\s*"))) (define (string->regs str) (list->vector (string->ints str))) (define ((binarize proc) x y) (if (proc x y) 1 0)) (define (make-runner program [calling-thd (current-thread)]) (thread (λ ...
af5cdb8448906abeb5f382de93551217f9e07bc9160575325809562b4d7aba33
rwilcox/my-learnings-docs
book_notes_unicorn_project.md.rkt
#lang scribble/text @(require "scribble-utils.rkt") --- path: "/book_notes/book_notes_unicorn_project" title: "Book Notes: Unicorn Project" --- # On Developer Experience @quote-highlight[ #:title "The Unicorn Project" #:author "Gene Kim" #:page-number 15]{"We don't have a standard Dev environment that...
null
https://raw.githubusercontent.com/rwilcox/my-learnings-docs/08472a8152a33006b4849eb4fea861e6725d2756/book_notes_unicorn_project.md.rkt
racket
#lang scribble/text @(require "scribble-utils.rkt") --- path: "/book_notes/book_notes_unicorn_project" title: "Book Notes: Unicorn Project" --- # On Developer Experience @quote-highlight[ #:title "The Unicorn Project" #:author "Gene Kim" #:page-number 15]{"We don't have a standard Dev environment that...
91ecd0d3bb34d6991705b74184a2fe666df937fa6584cee5b01312609ab05218
Viasat/halite
data_basic_bnf.clj
Copyright ( c ) 2022 Viasat , Inc. Licensed under the MIT license (ns com.viasat.halite.doc.data-basic-bnf) (set! *warn-on-reflection* true) (def basic-bnf-vector ['non-numeric-character {:bnf "'A-Z' | 'a-z' | '*' | '!' | '$' | '=' | '<' | '>' | '_' | '.' | '?'"} 'plus-minus-character {:bnf "'+' | '-'"} ...
null
https://raw.githubusercontent.com/Viasat/halite/0960db0950835d6e699e4b871f326361eede29f9/src/com/viasat/halite/doc/data_basic_bnf.clj
clojure
is this right?
Copyright ( c ) 2022 Viasat , Inc. Licensed under the MIT license (ns com.viasat.halite.doc.data-basic-bnf) (set! *warn-on-reflection* true) (def basic-bnf-vector ['non-numeric-character {:bnf "'A-Z' | 'a-z' | '*' | '!' | '$' | '=' | '<' | '>' | '_' | '.' | '?'"} 'plus-minus-character {:bnf "'+' | '-'"} ...
ee950c2ac7dcf1a3e2b2efd6c3f2b679d95242a59e9afdec23c825867440e3e9
kmi/irs
web.lisp
Copyright © 2009 The Open University (in-package #:soa4all) (defun start-web-interface () (web:register-plugin :soa4all :application "SOA4All" (nconc (mapcar (lambda (args) (apply #'hunchentoot:create-regex-dispatcher args)) `(("/soa4all$" draw-top-page) ("/soa4all/assets" ...
null
https://raw.githubusercontent.com/kmi/irs/e1b8d696f61c6b6878c0e92d993ed549fee6e7dd/apps/soa4all/lisp/web.lisp
lisp
Copyright © 2009 The Open University (in-package #:soa4all) (defun start-web-interface () (web:register-plugin :soa4all :application "SOA4All" (nconc (mapcar (lambda (args) (apply #'hunchentoot:create-regex-dispatcher args)) `(("/soa4all$" draw-top-page) ("/soa4all/assets" ...
4f66403fa20fdab4ef91410c3e0889ace9ff7ee8568bd170dcb80f96b11ac1db
cstar/ejabberd-old
jlib.erl
%%%---------------------------------------------------------------------- %%% File : jlib.erl Author : < > %%% Purpose : General XMPP library. Created : 23 Nov 2002 by < > %%% %%% ejabberd , Copyright ( C ) 2002 - 2010 ProcessOne %%% %%% This program is free software; you can redistribute it and/or ...
null
https://raw.githubusercontent.com/cstar/ejabberd-old/559f8b6b0a935710fe93e9afacb4270d6d6ea00f/src/jlib.erl
erlang
---------------------------------------------------------------------- File : jlib.erl Purpose : General XMPP library. This program is free software; you can redistribute it and/or License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT AN...
Author : < > Created : 23 Nov 2002 by < > ejabberd , Copyright ( C ) 2002 - 2010 ProcessOne modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the You should have received a copy of the GNU General Public License Founda...
f211675ed82710a38642b1600410bb51da1c41ee5177c53c156d62b80de978a2
johnwhitington/camlpdf
pdfpaper.ml
(* Type for paper sizes --- unit, width, height. *) type t = Paper of (Pdfunits.t * float * float) let make u w h = Paper (u, w, h) let unit (Paper (u, _, _)) = u let width (Paper (_, w, _)) = w let height (Paper (_, _, h)) = h (* Make a paper size landscape *) let landscape (Paper (u, w, h)) = Paper (u, h, w) Eu...
null
https://raw.githubusercontent.com/johnwhitington/camlpdf/dc7cfafaf9671bed1503a5c4143632922226b02d/pdfpaper.ml
ocaml
Type for paper sizes --- unit, width, height. Make a paper size landscape
type t = Paper of (Pdfunits.t * float * float) let make u w h = Paper (u, w, h) let unit (Paper (u, _, _)) = u let width (Paper (_, w, _)) = w let height (Paper (_, _, h)) = h let landscape (Paper (u, w, h)) = Paper (u, h, w) European ` A ' sizes . let a0 = Paper (Pdfunits.Millimetre, 841., 1189.) let a1 = Paper ...
e5bca186b5d73295d19063bf023dac65acf5fcfb1a545b00e37576791352b101
EwenG/badigeon
deploy.clj
(ns badigeon-build.deploy (:require [badigeon.clean :as clean] [badigeon.jar :as jar] [badigeon.install :as install] [badigeon.utils :as utils] [badigeon.sign :as sign] [badigeon.deploy :as deploy] [badigeon.prompt :as prompt])) (defn -main [] ...
null
https://raw.githubusercontent.com/EwenG/badigeon/5b020cbd2f0867ccdc98d6394c512337d927bd9e/src-build/badigeon_build/deploy.clj
clojure
(ns badigeon-build.deploy (:require [badigeon.clean :as clean] [badigeon.jar :as jar] [badigeon.install :as install] [badigeon.utils :as utils] [badigeon.sign :as sign] [badigeon.deploy :as deploy] [badigeon.prompt :as prompt])) (defn -main [] ...
033021e17ee5e34c9c5a34bad1248a70f575513201996e7c378c445df0630c63
PDP-10/panda
subseq.lsp
SUBSEQ -*-Mode : Lisp;Package : SI;Lowercase : T-*- ;;; ************************************************************************ * * * NIL * * * * * * * SUBSEQuencing and coercion functions * * * * * * * * * * * * * * * * * * * ;;; ****************************************************************...
null
https://raw.githubusercontent.com/PDP-10/panda/522301975c062914ea3d630a1daefde261ddf590/files/maclisp/subseq.lsp
lisp
Package : SI;Lowercase : T-*- ************************************************************************ ************************************************************************ ************************************************************************ functions. General coercion routines TO-<mumble>, wh...
* * * NIL * * * * * * * SUBSEQuencing and coercion functions * * * * * * * * * * * * * * * * * * * * * ( c ) Copyright 1981 Massachusetts Institute of Technology * * * * * * * * * * * * SUBSEQ and REPLACE are seen as a specific usage of the " coercion " (herald SUBSEQ /39) #+(or LISPM (and NI...
b8b79fa63026e481f7048d06f532f10df12fc304d4582c9e784d9c7e14a0ab89
chenyukang/eopl
store.scm
(module store (lib "eopl.ss" "eopl") (require "drscheme-init.scm") (provide initialize-store! reference? newref deref setref! instrument-newref get-store-as-list) (define instrument-newref (make-parameter #f)) ;;;;;;;;;;;;;;;; references and the store ;;;;;;;;;;;;;;;; ;;; world's...
null
https://raw.githubusercontent.com/chenyukang/eopl/0406ff23b993bfe020294fa70d2597b1ce4f9b78/base/chapter5/thread-lang/store.scm
scheme
references and the store ;;;;;;;;;;;;;;;; world's dumbest model of the store: the store is a list and a reference is number which denotes a position in the list. the-store: a Scheme variable containing the current state of the store. Initially set to a dummy variable. empty-store : () -> Sto initialize-s...
(module store (lib "eopl.ss" "eopl") (require "drscheme-init.scm") (provide initialize-store! reference? newref deref setref! instrument-newref get-store-as-list) (define instrument-newref (make-parameter #f)) (define the-store 'uninitialized) Page : 111 (define empty-sto...
efa5054705fbb8c71425ea8647ae4611ec0c9458492d59030d4047dd62f238bb
psilord/option-9
pdquat.lisp
(in-package :option-9) #+(or (not option-9-optimize-pvec) option-9-debug) (declaim (optimize (safety 3) (space 0) (speed 0) (debug 3))) ;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; An implementation of dual quaternions. The reason I chose not to use two quaternions in a structure and instead ;;; reimplem...
null
https://raw.githubusercontent.com/psilord/option-9/44d96cbc5543ee2acbdcf45d300207ef175462bc/pdquat.lisp
lisp
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; An implementation of dual quaternions. reimplement this stuff as a new structure with new math operations is that I can more reliably believe how much space this stuff takes while making it easier to pass to opengl shaders. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;...
(in-package :option-9) #+(or (not option-9-optimize-pvec) option-9-debug) (declaim (optimize (safety 3) (space 0) (speed 0) (debug 3))) The reason I chose not to use two quaternions in a structure and instead (eval-when (:compile-toplevel :load-toplevel :execute) (deftype pdquat () `(simple-array double-float (...
a875fa02309955a48cffcd863609b89fdc11f180e66fe08fd9ea0245cecb9926
Eventuria/demonstration-gsd
NotifyGoalAccomplishment.hs
# LANGUAGE NamedFieldPuns # # LANGUAGE DuplicateRecordFields # module Eventuria.GSD.Write.CommandConsumer.Handling.Commands.NotifyGoalAccomplishment where import Data.List (find) import qualified Data.UUID.V4 as Uuid import qualified Data.Time as Time import Eventuria.Libraries.CQRS.Write.Command...
null
https://raw.githubusercontent.com/Eventuria/demonstration-gsd/5c7692b310086bc172d3fd4e1eaf09ae51ea468f/src/Eventuria/GSD/Write/CommandConsumer/Handling/Commands/NotifyGoalAccomplishment.hs
haskell
# LANGUAGE NamedFieldPuns # # LANGUAGE DuplicateRecordFields # module Eventuria.GSD.Write.CommandConsumer.Handling.Commands.NotifyGoalAccomplishment where import Data.List (find) import qualified Data.UUID.V4 as Uuid import qualified Data.Time as Time import Eventuria.Libraries.CQRS.Write.Command...
44ce3124a74d352032a0f0ace33351a0188eb027d58f02006d8203d94803fe55
aerosol/signerl
map_sup.erl
$ I d : map_sup.erl , v 1.1 2005/02/13 00:42:12 vances Exp $ %%%--------------------------------------------------------------------- 2005 Motivity Telecom @author < > [ ] %%% @end %%% Copyright ( c ) 2005 , Motivity Telecom %%% %%% All rights reserved. %%% %%% Redistribution and use in source and binary...
null
https://raw.githubusercontent.com/aerosol/signerl/b85bdc8e2a740afd80c64006e777269496aaa5dc/MAP/src/map_sup.erl
erlang
--------------------------------------------------------------------- @end All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - Redistributions of source code must retain the above copyright ...
$ I d : map_sup.erl , v 1.1 2005/02/13 00:42:12 vances Exp $ 2005 Motivity Telecom @author < > [ ] Copyright ( c ) 2005 , Motivity Telecom - Neither the name of Motivity Telecom nor the names of its " AS IS " AND ANY EXPRESS OR IMPLIED WARRANTIES , INCLUDING , BUT NOT OWNER OR ANY DIRECT , IND...
b0a673627df0d9b9d7cdf3d42740ec9eb508d4ab1c2406d7a0c9d4f438243985
tjammer/raylib-ocaml
text_font_filters.ml
let width = 800 let height = 450 let msg = "Loaded Font" let setup () = let open Raylib in init_window 800 450 "raylib [text] example - font filters"; let font = load_font_ex "resources/KAISG.ttf" 96 None in gen_texture_mipmaps (addr (Font.texture font)); let font_size = Font.base_size font in let font_pos...
null
https://raw.githubusercontent.com/tjammer/raylib-ocaml/bf632bac260b263e9e783a5fc36b6a6b1f5df0d5/examples/text/text_font_filters.ml
ocaml
NOTE: We only support first ttf file dropped
let width = 800 let height = 450 let msg = "Loaded Font" let setup () = let open Raylib in init_window 800 450 "raylib [text] example - font filters"; let font = load_font_ex "resources/KAISG.ttf" 96 None in gen_texture_mipmaps (addr (Font.texture font)); let font_size = Font.base_size font in let font_pos...
cf7afb0fe9c9ab8ebaf38c46fa42e986aff86b4bbc3911678247b8f73f7318c5
well-typed/large-records
Generics.hs
# LANGUAGE DataKinds # # LANGUAGE OverloadedLabels # # LANGUAGE TypeApplications # {-# LANGUAGE TypeOperators #-} {-# OPTIONS_GHC -fplugin=Data.Record.Anon.Plugin #-} for the ToJSON / FromJSON instances module Test.Sanity.Generics (tests) where import Data.Aeson import Data.Record.Generic import Data.R...
null
https://raw.githubusercontent.com/well-typed/large-records/07a01f23b85a2930a6fa252bfe62645acca96f79/large-anon/test/Test/Sanity/Generics.hs
haskell
# LANGUAGE TypeOperators # # OPTIONS_GHC -fplugin=Data.Record.Anon.Plugin # add test with non-I functor ------------------------------------------------------------------------------ Example values ------------------------------------------------------------------------------ | Example where the fields do not ap...
# LANGUAGE DataKinds # # LANGUAGE OverloadedLabels # # LANGUAGE TypeApplications # for the ToJSON / FromJSON instances module Test.Sanity.Generics (tests) where import Data.Aeson import Data.Record.Generic import Data.Record.Anon import Data.Record.Anon.Advanced (Record) import qualified Data.Record.Anon....
ef71850341d49eaa2fe5050f5f0de81d0c4c82ff28c94790fc62c153e680964f
yesodweb/shakespeare
IndentToBrace.hs
{-# LANGUAGE OverloadedStrings #-} module Text.IndentToBrace ( i2b ) where import Control.Monad.Trans.Writer (execWriter, tell, Writer) import Data.List (isInfixOf) import qualified Data.Text as T i2b :: String -> String i2b = ($ []) . execWriter . mapM_ unnest . map addClosingCount . nest ...
null
https://raw.githubusercontent.com/yesodweb/shakespeare/edf4f194a1b89d4654f719ae221aded675899b0d/Text/IndentToBrace.hs
haskell
# LANGUAGE OverloadedStrings #
module Text.IndentToBrace ( i2b ) where import Control.Monad.Trans.Writer (execWriter, tell, Writer) import Data.List (isInfixOf) import qualified Data.Text as T i2b :: String -> String i2b = ($ []) . execWriter . mapM_ unnest . map addClosingCount . nest . map toL . stripComments ...
d73670425f22a9625e0e70bd418dc9e829d4d3161d3d6b23de16cab86d88514c
LambdaHack/LambdaHack
Defs.hs
# LANGUAGE DeriveGeneric # -- | Basic types for content definitions. module Game.LambdaHack.Definition.Defs ( GroupName, displayGroupName , ContentId, contentIdIndex , ContentSymbol, displayContentSymbol , X, Y , Freqs, renameFreqs , Rarity, linearInterpolation , CStore(..), ppCStore, ppCStoreIn, verbCSto...
null
https://raw.githubusercontent.com/LambdaHack/LambdaHack/824351574a4e7cd68aa4eec4d7ec406ec6b22486/definition-src/Game/LambdaHack/Definition/Defs.hs
haskell
| Basic types for content definitions. | X spacial dimension for points and vectors. | Y xpacial dimension for points and vectors. | For each group that the kind belongs to, denoted by a @GroupName@ how common the kind is within the group. meaning appearance in the dungeon is not possible under normal circumstanc...
# LANGUAGE DeriveGeneric # module Game.LambdaHack.Definition.Defs ( GroupName, displayGroupName , ContentId, contentIdIndex , ContentSymbol, displayContentSymbol , X, Y , Freqs, renameFreqs , Rarity, linearInterpolation , CStore(..), ppCStore, ppCStoreIn, verbCStore , SLore(..), ItemDialogMode(..), ppSL...
303c700db0d6a60b6ca222e0deef41cb1e7adb7a19b0a11e825dc539d60b2588
hackwaly/ocamlearlybird
controller.mli
* * Copyright ( C ) 2021 * * This program is free software : you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as * published by the Free Software Foundation , either version 3 of the * License , or ( at your option ) any later version . * * Th...
null
https://raw.githubusercontent.com/hackwaly/ocamlearlybird/165174e3cc749ba416ec7ebfb4b521e5fac744db/src/debugger/core/controller.mli
ocaml
* * Copyright ( C ) 2021 * * This program is free software : you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as * published by the Free Software Foundation , either version 3 of the * License , or ( at your option ) any later version . * * Th...
549a7e995a3e965eb3f3e5f5f85c48c4b3e507a2b08124a641e3a17711af77b4
clojure-interop/google-cloud-clients
VideoIntelligenceServiceStub.clj
(ns com.google.cloud.videointelligence.v1.stub.VideoIntelligenceServiceStub "Base stub class for Cloud Video Intelligence API. This class is for advanced usage and reflects the underlying API directly." (:refer-clojure :only [require comment defn ->]) (:import [com.google.cloud.videointelligence.v1.stub VideoI...
null
https://raw.githubusercontent.com/clojure-interop/google-cloud-clients/80852d0496057c22f9cdc86d6f9ffc0fa3cd7904/com.google.cloud.videointelligence/src/com/google/cloud/videointelligence/v1/stub/VideoIntelligenceServiceStub.clj
clojure
(ns com.google.cloud.videointelligence.v1.stub.VideoIntelligenceServiceStub "Base stub class for Cloud Video Intelligence API. This class is for advanced usage and reflects the underlying API directly." (:refer-clojure :only [require comment defn ->]) (:import [com.google.cloud.videointelligence.v1.stub VideoI...
e6d88f19ece12afec675610e95631143f03d5cf608d0654c6bbc49cf9381028d
hcarty/ocaml-gdal
feature.ml
open Ctypes module Defn = struct type t = T.Defn.t let t = T.Defn.t let get_field_count = Lib.c "OGR_FD_GetFieldCount" (t @-> returning int) let get_field_defn = Lib.c "OGR_FD_GetFieldDefn" (t @-> int @-> returning Field.Defn.t) end type t = T.t let t = T.t let t_opt = T.t_opt let get_a...
null
https://raw.githubusercontent.com/hcarty/ocaml-gdal/9c225c1e3f8002ec7614b3c1657e5f05e4e0e821/src/feature.ml
ocaml
open Ctypes module Defn = struct type t = T.Defn.t let t = T.Defn.t let get_field_count = Lib.c "OGR_FD_GetFieldCount" (t @-> returning int) let get_field_defn = Lib.c "OGR_FD_GetFieldDefn" (t @-> int @-> returning Field.Defn.t) end type t = T.t let t = T.t let t_opt = T.t_opt let get_a...
f0e3575f661378c1f45c965f7370966037e8deab4dc995d19d512c1d74807ba8
jbclements/molis-hai
log-analysis.rkt
#lang racket (require racket/runtime-path sha net/base64 threading math/statistics levenshtein "string-editing.rkt" "table.rkt" plot rackbot/tai64n srfi/19 racket/block racket/struct) (define-runtime-path her...
null
https://raw.githubusercontent.com/jbclements/molis-hai/6a335ec73c144f9d8ac538752ca8e6fd0b3b3cce/molis-hai/user-study-2016/log-analysis.rkt
racket
column names in the sessions.tsv file column names in the keystroke.tsv file given a list of converter symbols (currently only 'num and 'str) and a list of strings, apply the appropriate conversions to obtain the values for the table: this table holds the session start information add an index for userids to thi...
#lang racket (require racket/runtime-path sha net/base64 threading math/statistics levenshtein "string-editing.rkt" "table.rkt" plot rackbot/tai64n srfi/19 racket/block racket/struct) (define-runtime-path her...
297885059dee8f0ed22a527d3bbf48e5e7f594fc82a872a740cfc4bcc39d67eb
squirrel-prover/squirrel-prover
system.ml
type t = Symbols.system (*------------------------------------------------------------------*) let of_lsymb table s = Symbols.System.of_lsymb s table (*------------------------------------------------------------------*) type error = | Shape_error | Invalid_projection let pp_error fmt = function | Shape_error...
null
https://raw.githubusercontent.com/squirrel-prover/squirrel-prover/d25b6dab570ea0e99915059a67599fd3a38caa8b/src/system.ml
ocaml
------------------------------------------------------------------ ------------------------------------------------------------------ ------------------------------------------------------------------ * For each system we store the list of projections (which defines the system's arity) and a map from action shapes ...
type t = Symbols.system let of_lsymb table s = Symbols.System.of_lsymb s table type error = | Shape_error | Invalid_projection let pp_error fmt = function | Shape_error -> Format.fprintf fmt "cannot register a shape twice with distinct indices" | Invalid_projection -> Format.fprintf fmt "invalid pro...
3afbe9a538898bbc7ebaf23b30b0e60f9be1af00d846ad1f2654ef9cd83d8bb8
jeffa5/mirage-xmpp
handler.mli
(* This will contain the parser type, roster type and connections type *) (** The type of an XMPP handler. *) type t (* The idea is that this will be called when the on_connect triggers in the unikernel so this will then handle *) (* When called this has a few jobs: - create the parser with the given stream - i...
null
https://raw.githubusercontent.com/jeffa5/mirage-xmpp/df3dafecba9081880809d8649ed0727b9f6a9dc7/src/handler.mli
ocaml
This will contain the parser type, roster type and connections type * The type of an XMPP handler. The idea is that this will be called when the on_connect triggers in the unikernel so this will then handle When called this has a few jobs: - create the parser with the given stream - initialise the new handl...
type t val create : stream:char Lwt_stream.t -> callback:(string option -> unit) -> hostname:string -> t * [ handle t ] takes the handler and starts handling the XMPP connection with the client . This controls the main operation of the server : - call parse_stanza on the parser which will return a ne...
65a4355447e6d843d8120ca7085d1ed5f74949239a6a81a3fb22c465fa897c6d
int-index/kalium
Name.hs
# LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # module Kalium.Nucleus.Vector.Name where import Kalium.Prelude import Kalium.Util import Control.Monad.Reader import Control.Monad.Writer import qualified Data.Set as S import Kalium.Nucleus.Vector.Program class Mentionable a where mentionable :: a -> Set...
null
https://raw.githubusercontent.com/int-index/kalium/0653b4229001880322acf3016de595360de726ec/src/Kalium/Nucleus/Vector/Name.hs
haskell
no user-defined types yet
# LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # module Kalium.Nucleus.Vector.Name where import Kalium.Prelude import Kalium.Util import Control.Monad.Reader import Control.Monad.Writer import qualified Data.Set as S import Kalium.Nucleus.Vector.Program class Mentionable a where mentionable :: a -> Set...
1f701f5628910a066c7b74a7099a0ed86e9e50d5a8297ffc35c6945d359e2f62
input-output-hk/cardano-wallet
Goldens.hs
# LANGUAGE LambdaCase # # LANGUAGE ScopedTypeVariables # # LANGUAGE TupleSections # -- | Small module for writing text-based golden tests. -- -- In contrast to `hspec-golden-aeson` this module works with manually provided values instead of QuickCheck , and with text instead of JSON . -- -- If the tests are run with ...
null
https://raw.githubusercontent.com/input-output-hk/cardano-wallet/bd8a530e46e3ffa74cd293f128d231abb7073aca/lib/test-utils/src/Test/Hspec/Goldens.hs
haskell
| Small module for writing text-based golden tests. In contrast to `hspec-golden-aeson` this module works with manually provided If the tests are run with the OVERWRITE_GOLDENS environment variable set, they will all fail, and write the current values to disk. If some goldens are os-dependent (like some optpars...
# LANGUAGE LambdaCase # # LANGUAGE ScopedTypeVariables # # LANGUAGE TupleSections # values instead of QuickCheck , and with text instead of JSON . This seems to work for now with just two windows specific goldens , but if module Test.Hspec.Goldens ( Settings (..) , textGolden ) where import Prelud...
af214c0d9a455ed91a9b7a0a4a0ad6a49d9e8a108d05a190eb457480d80e7a08
dhleong/wish
db.cljs
(ns wish.db) (def default-db {:page [:splash] :device-type :default :updates {:latest nil :ignored :unknown} :worker-ready? false ; map of provider id to their current state. Acceptable states: ; - :ready The provider is ready to be used. Setting this ; state...
null
https://raw.githubusercontent.com/dhleong/wish/9036f9da3706bfcc1e4b4736558b6f7309f53b7b/src/cljs/wish/db.cljs
clojure
map of provider id to their current state. Acceptable states: - :ready The provider is ready to be used. Setting this state will trigger a call to `(query-sheets)` - :cache-only The provider could not be initialized, but a cache is available to perform operations - :s...
(ns wish.db) (def default-db {:page [:splash] :device-type :default :updates {:latest nil :ignored :unknown} :worker-ready? false :provider-states {} :providers-listing #{} :online? true :data-sources {} :sheets {} :my-sheets #{} :sheets-filters {:mine? true ...
9b5c4df624c2bfb751aa7f0e66b745b69effa347f72a32ade4fe35da5bde8ec9
xapi-project/xen-api-libs
http_svr.ml
* Copyright ( C ) 2006 - 2009 Citrix Systems 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 ; version 2.1 only . with the special * exception on linking describe...
null
https://raw.githubusercontent.com/xapi-project/xen-api-libs/d603ee2b8456bc2aac99b0a4955f083e22f4f314/http-svr/http_svr.ml
ocaml
A very very simple HTTP server! * Record of statistics per-handler * successful requests * closed connections * using the more efficient framed protocol * Type of a function which can handle a Request.t try and do f (unit -> unit), ignore exceptions If http/1.0 was requested, return that, else return http/1.1...
* Copyright ( C ) 2006 - 2009 Citrix Systems 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 ; version 2.1 only . with the special * exception on linking describe...
ac5169352fcf585728cf5bdfedcd6e9d674e2cb0b318d9e05936a223c0452291
nathell/soupscraper
core.clj
(ns soupscraper.core (:require [cheshire.core :as json] [clojure.core.async :as async] [clojure.java.io :as io] [clojure.string :as string] [clojure.tools.cli :as cli] [java-time] [skyscraper.cache :as cache] [skyscraper.core :as core...
null
https://raw.githubusercontent.com/nathell/soupscraper/56b4927bb6c56dd541dc167c4d8f5db0cbdd9476/src/soupscraper/core.clj
clojure
logic c/o tomash, cf some touching of Skyscraper internals here; you're not supposed to understand this
(ns soupscraper.core (:require [cheshire.core :as json] [clojure.core.async :as async] [clojure.java.io :as io] [clojure.string :as string] [clojure.tools.cli :as cli] [java-time] [skyscraper.cache :as cache] [skyscraper.core :as core...
1b1fab6f9025a20d6206cee500830928d3a305e9c224dbbc0c4e8a7ccf139bf8
racket/htdp
stepper-tool.rkt
#lang racket/unit (require racket/class drracket/tool mred (prefix-in frame: framework) mrlib/switchable-button mzlib/pconvert racket/pretty racket/match string-constants lang/stepper-language-interface (only-in racket/list last)...
null
https://raw.githubusercontent.com/racket/htdp/2af893a0e14e2ea883c0bcbbacfdbc829c0f16e9/htdp-lib/stepper/stepper-tool.rkt
racket
get the stepper-button-callback private-member-name tool magic here: experiment with extending the language... parameter-like fields for stepper parameters the language definition to match the way that the language wants these values printed. this should be a preference: the stepper's frame: PRINTING-PROC I fr...
#lang racket/unit (require racket/class drracket/tool mred (prefix-in frame: framework) mrlib/switchable-button mzlib/pconvert racket/pretty racket/match string-constants lang/stepper-language-interface (only-in racket/list last)...
af66fd0419517eab10cf6e23d5160a79023904409f08cbe82e5adc03936f9791
uhc/uhc
MarshalArray.hs
# EXCLUDE_IF_TARGET js # module MarshalArray (module Foreign.Marshal.Array) where import Foreign.Marshal.Array
null
https://raw.githubusercontent.com/uhc/uhc/8eb6914df3ba2ba43916a1a4956c6f25aa0e07c5/EHC/ehclib/haskell98/MarshalArray.hs
haskell
# EXCLUDE_IF_TARGET js # module MarshalArray (module Foreign.Marshal.Array) where import Foreign.Marshal.Array
dce0b490004404e8346aed775050c5eb8f27edba5c55b5c5f7483d3b47b02fb4
cbaggers/nineveh
remap.lisp
(in-package #:nineveh.math-primitives) ;;------------------------------------------------------------ ;; Remap (defun-g remap ((val :float) (original-min :float) (original-max :float) (new-min :float) (new-max :float)) (+ new-min (* (- val original-min) (/ (- new-max new...
null
https://raw.githubusercontent.com/cbaggers/nineveh/0a10a84669cd9d1c584f54b9eab062986a5f1c47/math-primitives/remap.lisp
lisp
------------------------------------------------------------ Remap ------------------------------------------------------------
(in-package #:nineveh.math-primitives) (defun-g remap ((val :float) (original-min :float) (original-max :float) (new-min :float) (new-max :float)) (+ new-min (* (- val original-min) (/ (- new-max new-min) (- original-max original-min))))) (defun-g remap ((val...
bcfad4ffe000ac0a8b5cdc27a5078c920e8a6684032ea0a3fa6b9e953f5c70ab
fadbadml-dev/FADBADml
op.mli
(**************************************************************************) (* *) (* FADBADml *) (* *) ...
null
https://raw.githubusercontent.com/fadbadml-dev/FADBADml/bd5668433b8ad297aa70e91a032953d55923b533/src/op.mli
ocaml
************************************************************************ FADBADml ...
OCaml port by and Based on FADBAD++ , written by and Copyright 2019 - 2020 This file is distributed under the terms of the CeCILL - C license . module Float : Types.OpS with type elt = float and type scalar = float ...
b23c468d67995b852e9b80a2cf965ab0224f855189715e47149eb7d4f5a3fa52
Octachron/olivine
rename.ml
module L = Info.Linguistic module Cty = Info.Refined_types.Ty module Full_name = struct type name = L.name let pp ppf x = L.pp_var ppf x end module Ty = Info.Refined_types.Typexpr(Full_name) let may f = function | None -> None | Some x -> Some (f x) let elt dict = L.make dict let rec typ (!) x = let typ ...
null
https://raw.githubusercontent.com/Octachron/olivine/e93df595ad1e8bad5a8af689bac7d150753ab9fb/aster/rename.ml
ocaml
module L = Info.Linguistic module Cty = Info.Refined_types.Ty module Full_name = struct type name = L.name let pp ppf x = L.pp_var ppf x end module Ty = Info.Refined_types.Typexpr(Full_name) let may f = function | None -> None | Some x -> Some (f x) let elt dict = L.make dict let rec typ (!) x = let typ ...
86f96feeb720a6ebe7172816ffa417c3d3fb7f3969f1a1c113be85925a928dc6
neongreen/haskell-ex
solve.hs
import Data.List import Data.Bits import Data.Char bin :: Int -> String bin 0 = "0" bin n = reverse $ unfoldr (\x -> if x == 0 then Nothing else Just ( intToDigit ( x .&. 1 ), shift x (-1) ) ) n dec :: String -> Int dec = foldl' ( \acc char -> ( shift acc 1 ) + digitToInt char ) 0
null
https://raw.githubusercontent.com/neongreen/haskell-ex/345115444fdf370a43390fd942e2851b9b1963ad/week3/binary/balac/solve.hs
haskell
import Data.List import Data.Bits import Data.Char bin :: Int -> String bin 0 = "0" bin n = reverse $ unfoldr (\x -> if x == 0 then Nothing else Just ( intToDigit ( x .&. 1 ), shift x (-1) ) ) n dec :: String -> Int dec = foldl' ( \acc char -> ( shift acc 1 ) + digitToInt char ) 0
8659ae4452c959081883dd6e68c2ba5e98d3203cea4e7b9561abdcc10f168708
Kappa-Dev/KappaTools
lKappa_compiler.mli
(******************************************************************************) (* _ __ * The Kappa Language *) | |/ / * Copyright 2010 - 2020 CNRS - Harvard Medical School - INRIA - IRIF (* | ' / ********************************************************************...
null
https://raw.githubusercontent.com/Kappa-Dev/KappaTools/eef2337e8688018eda47ccc838aea809cae68de7/core/grammar/lKappa_compiler.mli
ocaml
**************************************************************************** _ __ * The Kappa Language | ' / ******************************************************************** | . \ * This file is distributed under the terms of the |_|\_\ * GN...
| |/ / * Copyright 2010 - 2020 CNRS - Harvard Medical School - INRIA - IRIF val bool_expr_of_ast : warning:(pos:Locality.t -> (Format.formatter -> unit) -> unit) -> syntax_version:Ast.syntax_version -> Signature.s -> int Mods.StringMap.t -> int Mods.StringMap.t -> ?max_allowed_var: int -> (Ast.mixture, st...
428f1128987af70e8363327bd6ca536e05c07b97a9cb31241141067708e40e2d
malcolmreynolds/GSLL
logarithmic.lisp
Regression test LOGARITHMIC for GSLL , automatically generated (in-package :gsl) (LISP-UNIT:DEFINE-TEST LOGARITHMIC (LISP-UNIT::ASSERT-NUMERICAL-EQUAL (LIST (LIST 1 3 1 4 1 1 2 1 1 5 2)) (MULTIPLE-VALUE-LIST (LET ((RNG (MAKE-RANDOM-NUMBER-GENERATOR +MT19937+ 0))) (LOOP FOR I FROM 0 TO 10 COLLECT ...
null
https://raw.githubusercontent.com/malcolmreynolds/GSLL/2f722f12f1d08e1b9550a46e2a22adba8e1e52c4/tests/logarithmic.lisp
lisp
Regression test LOGARITHMIC for GSLL , automatically generated (in-package :gsl) (LISP-UNIT:DEFINE-TEST LOGARITHMIC (LISP-UNIT::ASSERT-NUMERICAL-EQUAL (LIST (LIST 1 3 1 4 1 1 2 1 1 5 2)) (MULTIPLE-VALUE-LIST (LET ((RNG (MAKE-RANDOM-NUMBER-GENERATOR +MT19937+ 0))) (LOOP FOR I FROM 0 TO 10 COLLECT ...
9b65f44d42f8958d8e4b27c2e65cbbafbe0b566af7771d5decfba3eb17bfcb8c
aantron/markup.ml
common.ml
This file is part of Markup.ml , released under the MIT license . See LICENSE.md for details , or visit . LICENSE.md for details, or visit . *) type 'a cont = 'a -> unit type 'a cps = exn cont -> 'a cont -> unit type location = int * int let compare_locations (line, column) (line', column') = match line...
null
https://raw.githubusercontent.com/aantron/markup.ml/9afbf57ac7ef10a03bece6cae677a151fa164666/src/common.ml
ocaml
Type constraints are necessary to avoid polymorphic comparison, which would greatly reduce performance: . Specialization of List.mem at string list, to avoid polymorphic comparison.
This file is part of Markup.ml , released under the MIT license . See LICENSE.md for details , or visit . LICENSE.md for details, or visit . *) type 'a cont = 'a -> unit type 'a cps = exn cont -> 'a cont -> unit type location = int * int let compare_locations (line, column) (line', column') = match line...
7404f1efe0505109dedd9c89911f9dad27390ff49672ed9a14d03acd50c81d8e
takikawa/racket-ppa
info.rkt
(module info setup/infotab (#%module-begin (define collection (quote multi)) (define deps (quote ("scheme-lib" "base" "compatibility-lib" "scribble-text-lib" "scribble-html-lib" "planet-lib" "net-lib" "at-exp-lib" "draw-lib" "syntax-color-lib" "sandbox-lib" "typed-racket-lib"))) (define build-deps (quote ("rackunit-lib...
null
https://raw.githubusercontent.com/takikawa/racket-ppa/5f2031309f6359c61a8dfd1fec0b77bbf9fb78df/share/pkgs/scribble-lib/info.rkt
racket
(module info setup/infotab (#%module-begin (define collection (quote multi)) (define deps (quote ("scheme-lib" "base" "compatibility-lib" "scribble-text-lib" "scribble-html-lib" "planet-lib" "net-lib" "at-exp-lib" "draw-lib" "syntax-color-lib" "sandbox-lib" "typed-racket-lib"))) (define build-deps (quote ("rackunit-lib...
c3afb06feac27737a8d751a6ef1a824dfc4dd2970167fdeea565bf3698f834b6
chbrown/fancy-clojure
string.cljc
(ns fancy.string (:require [clojure.string :as str] [clojure.spec.alpha :as s])) (defn repeat-to-length "Repeat the string or character `x` as needed to fill out a string of `target-length` characters, truncating from the end if the final repeat of `x` extends past `target-length`." [x target-lengt...
null
https://raw.githubusercontent.com/chbrown/fancy-clojure/64265dec728b4f7b546f476f4f05b3a4eed09661/src/fancy/string.cljc
clojure
TODO: fail if (empty? x) append a substring of x if there's underflow TODO: in the string? case, check that it's not empty TODO: check that string is not already longer than target-length (and decide what to do in that case) TODO: check that string is not already longer than target-length (and decide...
(ns fancy.string (:require [clojure.string :as str] [clojure.spec.alpha :as s])) (defn repeat-to-length "Repeat the string or character `x` as needed to fill out a string of `target-length` characters, truncating from the end if the final repeat of `x` extends past `target-length`." [x target-lengt...
d4eedc5c937b35922190e88a342d0229622954c74d7a60a34f6f3589e4996cba
OlivierSohn/hamazed
Server.hs
# LANGUAGE NoImplicitPrelude # # LANGUAGE LambdaCase # # LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RankNTypes #-} # LANGUAGE ScopedTypeVariables # # LANGUAGE Ty...
null
https://raw.githubusercontent.com/OlivierSohn/hamazed/c0df1bb60a8538ac75e413d2f5bf0bf050e5bc37/imj-serve-highscores/src/Imj/Game/HighScores/Server.hs
haskell
# LANGUAGE OverloadedStrings # # LANGUAGE RankNTypes # in a transaction, removes entries for that key and adds one. returns the number of bytes written (errors are handled inside hence the returned value is always >= 0) | Reads the environment variable 'DB_CONN_STR' to. stripes
# LANGUAGE NoImplicitPrelude # # LANGUAGE LambdaCase # # LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeOperators # module Imj.Game.HighScores.Server ( serveHighS...
421d6aa92abb33f6e78559dcc32e853b764118dd9c36f2fb0f78f9166826187a
CloudI/CloudI
folsom_sample_slide_server.erl
%% ------------------------------------------------------------------- %% Copyright ( c ) 2011 Basho Technologies , Inc. %% This file is provided to you 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 Li...
null
https://raw.githubusercontent.com/CloudI/CloudI/3e45031c7ee3e974ead2612ea7dd06c9edf973c9/src/external/cloudi_x_folsom/src/folsom_sample_slide_server.erl
erlang
------------------------------------------------------------------- Version 2.0 (the "License"); you may not use this file a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, KIND, either express or implied. See the License for the specific language governing permissio...
Copyright ( c ) 2011 Basho Technologies , Inc. This file is provided to you under the Apache License , except in compliance with the License . You may obtain software distributed under the License is distributed on an " AS IS " BASIS , WITHOUT WARRANTIES OR CONDITIONS OF ANY File : @author ...
41963fdd5bfb9a2e0988db9c42dc0865b9fb7414be559f1d8e53b072f5050889
haskell-waargonaut/waargonaut
Internal.hs
# LANGUAGE CPP # {-# LANGUAGE DeriveFunctor #-} # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE RankNTypes #-} # LANGUAGE TupleSections ...
null
https://raw.githubusercontent.com/haskell-waargonaut/waargonaut/4671958c7d8557c72bf881fabed5612ace1ec936/src/Waargonaut/Decode/Internal.hs
haskell
# LANGUAGE DeriveFunctor # # LANGUAGE RankNTypes # | Internal types and functions for building Decoder infrastructure. * Generalised Decoder Functions * JSON Object to Map Functions * Re-exports Track the history of the cursor as we move around the zipper. It is indexed over the type...
# LANGUAGE CPP # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # # LANGUAGE TupleSections # # LANGUAGE TypeFamilies # module Waargonaut.Decode.Internal ...
7113df24ceb2f58d29eb84caf4390a44a0276eef50185605f3de362b97e51545
fourmolu/fourmolu
explicit-imports-four-out.hs
import qualified MegaModule as M ( Either, Maybe (Just, Nothing), MaybeT (..), Monad (return, (>>), (>>=)), MonadBaseControl, join, liftIO, void, (<<<), (>>>), )
null
https://raw.githubusercontent.com/fourmolu/fourmolu/1f8903a92c8d5001dc1ec8ecfd4a04a3b61c3283/data/examples/import/explicit-imports-four-out.hs
haskell
import qualified MegaModule as M ( Either, Maybe (Just, Nothing), MaybeT (..), Monad (return, (>>), (>>=)), MonadBaseControl, join, liftIO, void, (<<<), (>>>), )
26154110bffe958eed12f2f86017cc0fe04df361d66f9fd62abdf03db75ad17b
EDToaster/CSC324-A2-TestingSuite
testIfSimple.rkt
(define x (cps:+ 1 2)) (if x #t #f)
null
https://raw.githubusercontent.com/EDToaster/CSC324-A2-TestingSuite/f07cbd01587a46c61aac29c52a6804864a4eb77b/tests/testIfSimple.rkt
racket
(define x (cps:+ 1 2)) (if x #t #f)
e45ae5565db6614215a7f61bdf66e19f5e0c2f8dca437b21b62bf268b5efc2ae
reuk/rayverb
Scene.hs
# LANGUAGE DeriveGeneric # module Scene where import Prelude hiding (all, any, concat, concatMap, maximum, foldr, mapM_) import Numerical import Vec3 hiding (normalize) import Positionable import Directionable import Ray import qualified Primitive as P import Material import qualified Reflection as R import Impulse ...
null
https://raw.githubusercontent.com/reuk/rayverb/e9aa02a422446728625d5c4f88ac6b11ce393005/src/Scene.hs
haskell
# LANGUAGE DeriveGeneric # module Scene where import Prelude hiding (all, any, concat, concatMap, maximum, foldr, mapM_) import Numerical import Vec3 hiding (normalize) import Positionable import Directionable import Ray import qualified Primitive as P import Material import qualified Reflection as R import Impulse ...
30281bf927ec4cd424955a73dcce0a8d93a881eae00767b30560b80cc904206e
unifydb/unifydb
statistics.clj
(ns unifydb.statistics "Simple statistics functions.") ;; Shamelessly stolen from ;; -cookbook/clojure-cookbook/blob/master/01_primitive-data/1-20_simple-statistics.asciidoc (defn mean [coll] (let [sum (apply + coll) count (count coll)] (if (pos? count) (/ sum count) 0))) (defn median [co...
null
https://raw.githubusercontent.com/unifydb/unifydb/10dd5a5663e0d4db94cd71ee3c8e1784f86ff052/src/unifydb/statistics.clj
clojure
Shamelessly stolen from -cookbook/clojure-cookbook/blob/master/01_primitive-data/1-20_simple-statistics.asciidoc
(ns unifydb.statistics "Simple statistics functions.") (defn mean [coll] (let [sum (apply + coll) count (count coll)] (if (pos? count) (/ sum count) 0))) (defn median [coll] (let [sorted (sort coll) cnt (count sorted) halfway (quot cnt 2)] (if (odd? cnt) (nth s...
930cf46ed54c51470f95552771b468c668ab8937c0daf0c023e3b9864522658e
lspitzner/brittany
Test523.hs
-- brittany { lconfig_columnAlignMode: { tag: ColumnAlignModeDisabled }, lconfig_indentPolicy: IndentPolicyLeft } func = [ (abc, (1111, 1111)) , (def, (2, 2)) , foo -- comment ]
null
https://raw.githubusercontent.com/lspitzner/brittany/a15eed5f3608bf1fa7084fcf008c6ecb79542562/data/Test523.hs
haskell
brittany { lconfig_columnAlignMode: { tag: ColumnAlignModeDisabled }, lconfig_indentPolicy: IndentPolicyLeft } comment
func = [ (abc, (1111, 1111)) , (def, (2, 2)) ]
694c71148e381218cfe82a37857c63f341b8e52223bc70dca9fa1c32e92961af
gfngfn/apbuf
range.ml
type real = { file_name : string; start_line : int; start_column : int; last_line : int; last_column : int; } type t = | Dummy of string | Real of real let pp ppf rng = match rng with | Dummy(s) -> Format.printf "(%s)" s | Real(r) -> if r.start_line = r.last_line then ...
null
https://raw.githubusercontent.com/gfngfn/apbuf/8f5cfb009d6e07236d3ac5aacfd4247017f20cc1/src/range.ml
ocaml
type real = { file_name : string; start_line : int; start_column : int; last_line : int; last_column : int; } type t = | Dummy of string | Real of real let pp ppf rng = match rng with | Dummy(s) -> Format.printf "(%s)" s | Real(r) -> if r.start_line = r.last_line then ...
36b9e4f63868bc438703241a61b9ec7bb71908ae144d9ea56a1275d02a5f503b
nathell/solitaire
deps.cljs
{:npm-dev-deps {"shadow-cljs" "2.11.7"}}
null
https://raw.githubusercontent.com/nathell/solitaire/02c951d7886aa391b2cea6b49fc6d892dd9c0fa4/src/cljs/deps.cljs
clojure
{:npm-dev-deps {"shadow-cljs" "2.11.7"}}
ed1f7f3ae7c3a566852a11a1bf4b17a53d8f004332438785ed238cf48c567066
monadbobo/ocaml-core
typehash.ml
type 'a t = int external to_int : _ t -> int = "%identity" type +'a internal
null
https://raw.githubusercontent.com/monadbobo/ocaml-core/9c1c06e7a1af7e15b6019a325d7dbdbd4cdb4020/base/typehash/lib/typehash.ml
ocaml
type 'a t = int external to_int : _ t -> int = "%identity" type +'a internal
a8a0fffb784e83cc85193cc82d357b2ac57f24a4ed4b4b8ed5c0de1a8d4bc33a
joinr/clclojure
common-utils.lisp
;;A package for useful library utilities that come up during the course ;;of implementing clclojure. (defpackage :common-utils (:use :common-lisp) (:export :comment :make-keyword :to-string :str :symb :with-gensyms :flatten :map-tree :filter-tree :reduce-tree :filter :i...
null
https://raw.githubusercontent.com/joinr/clclojure/8b51214891c4da6dfbec393dffac70846ee1d0c5/dustbin/common-utils.lisp
lisp
A package for useful library utilities that come up during the course of implementing clclojure. I'm going to rewrite these around a little lazy cons cell data structure, probably... This is exactly the same as lazy-seq in clojure, or fairly similar. Should probably take a look at this guy... same as clojure's comme...
(defpackage :common-utils (:use :common-lisp) (:export :comment :make-keyword :to-string :str :symb :with-gensyms :flatten :map-tree :filter-tree :reduce-tree :filter :if-let :when-let :when-not :zip :->> :-> :delay :force :promise? :realized...
092231ef99cadb33ac78d00c3dc7eed06325d15c701fdf28ad66d41e92e9dcc4
datalogisk-fagraad/DIKUNotes
a_day_at_diku.erl
Example contributed by and -module(a_day_at_diku). -export([run_world/0]). make_drunker({CreateRef, Stats}) -> #{sobriety := CurSobriety} = Stats, {CreateRef, Stats#{sobriety := CurSobriety - 1}}. make_sober({CreateRef, Stats}) -> #{sobriety := CurSobriety} = Stats, {CreateRef, Stats#{sobriety := ...
null
https://raw.githubusercontent.com/datalogisk-fagraad/DIKUNotes/fb0487d62599e37bf94da4dab3f63728e0c4c4c8/Advanced%20Programming%20(AP)/2018%20Exam%20and%20Solution/handin/ravnica/a_day_at_diku.erl
erlang
This is misbehaving, thus the trigger has no effect Andrzej sometimes skips his coffee Places to spawn or place advanced triggers Spawn the creatures but he was already too late
Example contributed by and -module(a_day_at_diku). -export([run_world/0]). make_drunker({CreateRef, Stats}) -> #{sobriety := CurSobriety} = Stats, {CreateRef, Stats#{sobriety := CurSobriety - 1}}. make_sober({CreateRef, Stats}) -> #{sobriety := CurSobriety} = Stats, {CreateRef, Stats#{sobriety := ...
bc0cee3b174d7e8c7d0ce7c2c8aa5fbaea69daf3ea8f061a94cd8d2edad2851d
mirage/irmin-rpc
irmin_rpc_unix.ml
open Lwt.Infix module Remote = struct module Git = struct type t = Mimic.ctx * Smart_git.Endpoint.t let encode (_, endpoint) = Fmt.to_to_string Smart_git.Endpoint.pp endpoint let decode str = Result.map (fun x -> (Mimic.empty, x)) @@ Smart_git.Endpoint.of_string str end end module Make (St...
null
https://raw.githubusercontent.com/mirage/irmin-rpc/e85663194efa049a44238522f1310387b4525249/src/irmin-rpc-unix/irmin_rpc_unix.ml
ocaml
open Lwt.Infix module Remote = struct module Git = struct type t = Mimic.ctx * Smart_git.Endpoint.t let encode (_, endpoint) = Fmt.to_to_string Smart_git.Endpoint.pp endpoint let decode str = Result.map (fun x -> (Mimic.empty, x)) @@ Smart_git.Endpoint.of_string str end end module Make (St...
0da078145b74491edd075c1396ad05a9a9b188d9e55ec7af264f800c63d8118b
hasktorch/ffi-experimental
Scalar.hs
# LANGUAGE DataKinds # # LANGUAGE PolyKinds # # LANGUAGE TemplateHaskell # # LANGUAGE QuasiQuotes # # LANGUAGE ScopedTypeVariables # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE TypeFamilies # # LANGUAGE FlexibleInstances # module ATen.Managed.Type.Scalar where import Foreign.C.String import Foreign.C.Types import...
null
https://raw.githubusercontent.com/hasktorch/ffi-experimental/54192297742221c4d50398586ba8d187451f9ee0/ffi/src/ATen/Managed/Type/Scalar.hs
haskell
# LANGUAGE OverloadedStrings #
# LANGUAGE DataKinds # # LANGUAGE PolyKinds # # LANGUAGE TemplateHaskell # # LANGUAGE QuasiQuotes # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # # LANGUAGE FlexibleInstances # module ATen.Managed.Type.Scalar where import Foreign.C.String import Foreign.C.Types import Foreign hiding (newForeignPtr) imp...
63cbb6bed118127b644c669add9337e42fd172cab88c57aee3ec126ee59cc5fb
haskell/cabal
UnitTests.hs
module Main (main) where import Test.Tasty import qualified UnitTests.Distribution.Client.BuildReport import qualified UnitTests.Distribution.Client.Configure import qualified UnitTests.Distribution.Client.FetchUtils import qualified UnitTests.Distribution.Client.Get import qualified UnitTests.Distribution.Client.Gl...
null
https://raw.githubusercontent.com/haskell/cabal/001e3cc810b0f735007ef8cbfef002d7bf4756e8/cabal-install/tests/UnitTests.hs
haskell
module Main (main) where import Test.Tasty import qualified UnitTests.Distribution.Client.BuildReport import qualified UnitTests.Distribution.Client.Configure import qualified UnitTests.Distribution.Client.FetchUtils import qualified UnitTests.Distribution.Client.Get import qualified UnitTests.Distribution.Client.Gl...
b424f23022331c5424041cba47e6dcf31505f0cae3a5f012a7bc35e4ab44706b
ocharles/opaleye-tf
Lit.hs
# LANGUAGE DataKinds # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # {-# LANGUAGE GADTs #-} # LANGUAGE PolyKinds # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeOperators # # LANGUAGE UndecidableInstances # module Opaleye.TF.Lit where import Opaleye.TF.Col import Opaleye.TF.Expr import Opaleye....
null
https://raw.githubusercontent.com/ocharles/opaleye-tf/b4b27f51e6f6137e5eb037b3bf36e00091cd1b8a/src/Opaleye/TF/Lit.hs
haskell
# LANGUAGE GADTs #
# LANGUAGE DataKinds # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE PolyKinds # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeOperators # # LANGUAGE UndecidableInstances # module Opaleye.TF.Lit where import Opaleye.TF.Col import Opaleye.TF.Expr import Opaleye.TF.Interpretation impor...
3ecd2a71da3e68a3b6bf54b2b1e08c0d6122066b7368835f7b4ddf3366f71969
VisionsGlobalEmpowerment/webchange
views.cljs
(ns webchange.lesson-builder.tools.template-options.select-book.views (:require [reagent.core :as r] [re-frame.core :as re-frame] [webchange.lesson-builder.tools.template-options.select-book.state :as state] [webchange.ui.index :as ui])) (defn field [props] (re-frame/dispatch [::state/init props]...
null
https://raw.githubusercontent.com/VisionsGlobalEmpowerment/webchange/118ba5ee407ba1261bac40a6ba5729ccda6e8150/src/cljs/webchange/lesson_builder/tools/template_options/select_book/views.cljs
clojure
(ns webchange.lesson-builder.tools.template-options.select-book.views (:require [reagent.core :as r] [re-frame.core :as re-frame] [webchange.lesson-builder.tools.template-options.select-book.state :as state] [webchange.ui.index :as ui])) (defn field [props] (re-frame/dispatch [::state/init props]...
ed2cff42f493856e649684a82677ff8ea9ff2769bb54ba367b8e53e507d4275f
gelisam/category-syntax
InterList.hs
# LANGUAGE DeriveFunctor # module Data.InterList where import Control.Monad import Data.List import Text.Printf import Data.List.Scan type NonEmptyList a = (a,[a]) prettyNonEmptyList :: Show a => NonEmptyList a -> String prettyNonEmptyList (x,xs) = show (x:xs) -- A non-empty list of values of type @a@, separated...
null
https://raw.githubusercontent.com/gelisam/category-syntax/5f13d8c47c904070888c4c3a68270cebaf6be803/src/Data/InterList.hs
haskell
A non-empty list of values of type @a@, separated by values of type @s@. >>> inBetweenElements f [x0 x1 x2 x3] [ x0 x1 {x1 `f` x2} x2 {x2 `f` x3} x3 ] >>> scanlAroundSeparators f x0 [x1 x2 x3] {x1} {x2} ...
# LANGUAGE DeriveFunctor # module Data.InterList where import Control.Monad import Data.List import Text.Printf import Data.List.Scan type NonEmptyList a = (a,[a]) prettyNonEmptyList :: Show a => NonEmptyList a -> String prettyNonEmptyList (x,xs) = show (x:xs) data InterList s a = InterList a [(s, a)] deriving...
6f2a3728cc0bc4c86d98828cfb811315f746fe7d238cf85fb1b5eac33c653641
hipsleek/hipsleek
zrapp.mli
val debug : bool ref val doElimTemps : bool ref val deputyAttrs : bool ref class zraCilPrinterClass : Cil.cilPrinter val zraCilPrinter : Cil.cilPrinter val pp_exp : Cil.fundec -> unit -> Cil.exp -> Pretty.doc val feature : Cil.featureDescr
null
https://raw.githubusercontent.com/hipsleek/hipsleek/596f7fa7f67444c8309da2ca86ba4c47d376618c/cil/src/zrapp.mli
ocaml
val debug : bool ref val doElimTemps : bool ref val deputyAttrs : bool ref class zraCilPrinterClass : Cil.cilPrinter val zraCilPrinter : Cil.cilPrinter val pp_exp : Cil.fundec -> unit -> Cil.exp -> Pretty.doc val feature : Cil.featureDescr
80c895215fa061f748b61e40aab3b21590ddcf67f3550e6d9faedc869af76b84
janestreet/merlin-jst
mtype.ml
(**************************************************************************) (* *) (* OCaml *) (* *) ...
null
https://raw.githubusercontent.com/janestreet/merlin-jst/980b574405617fa0dfb0b79a84a66536b46cd71b/upstream/ocaml_flambda/typing/mtype.ml
ocaml
************************************************************************ OCaml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et the GNU Lesser General Public License version 2.1 , with the open Asttypes open Path open Types let rec scrape_lazy env mty = let open Subst.Lazy in match mty w...
1d8132f8efa8101621a26bfc6ebf73d14ec0f0b1082c98430e038e8761d00dd3
facebook/duckling
Tests.hs
Copyright ( c ) 2016 - present , Facebook , Inc. -- All rights reserved. -- -- This source code is licensed under the BSD-style license found in the -- LICENSE file in the root directory of this source tree. module Duckling.Time.DA.Tests ( tests ) where import Data.String import Prelude import Test.Tasty import...
null
https://raw.githubusercontent.com/facebook/duckling/72f45e8e2c7385f41f2f8b1f063e7b5daa6dca94/tests/Duckling/Time/DA/Tests.hs
haskell
All rights reserved. This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree.
Copyright ( c ) 2016 - present , Facebook , Inc. module Duckling.Time.DA.Tests ( tests ) where import Data.String import Prelude import Test.Tasty import Duckling.Dimensions.Types import Duckling.Testing.Asserts import Duckling.Time.DA.Corpus tests :: TestTree tests = testGroup "DA Tests" [ makeCorpusTest [S...
5916cfd03cfdb8ce02c5f47114fccfaa278db9a8c7e36aa47544708f6d2a5e7b
qitab/qitab
primitive-writers.lisp
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; ;;; Free Software under the MIT license . ; ; ; ;;; ;;; Copyright ( c ) 2006 - 2...
null
https://raw.githubusercontent.com/qitab/qitab/1896c544e85f71754a7397efd43a48b9edb4d311/quepasa/primitive-writers.lisp
lisp
;;; ; ; ;;; ; ; ;;; ; ; ;;; End of primitive-write...
(in-package :quepasa) (define-primitive-writer ((type (eql '$$string)) (style (eql ':id)) value stream) "If VALUE is a valid id string (i.e., all characters are alpha), either write VALUE to STREAM, if STREAM is not NIL, or return VALUE, if STREAM is NIL." (when (and (stringp value) (every #'alpha-...
a7b62578350c8b215b1631312195165aa06946bdc44f2058d122b1f53a396650
ocsigen/ocaml-eliom
sorts.ml
(**************************************************************************) (* *) (* OCaml *) (* *) ...
null
https://raw.githubusercontent.com/ocsigen/ocaml-eliom/497c6707f477cb3086dc6d8124384e74a8c379ae/testsuite/tests/misc/sorts.ml
ocaml
************************************************************************ OCaml ...
, projet , INRIA Rocquencourt Copyright 2000 Institut National de Recherche en Informatique et the GNU Lesser General Public License version 2.1 , with the open Printf;; Criteria : 0 . stack overhead : at most log n. 1 . stable or not . 2 . space ove...
b88541781cf42af0226559711407201b18597093c0436943c7917ad85d5d295e
pveber/bistro
prokka.mli
open Bistro open Formats val run : ?prefix:string -> ?addgenes:bool -> ?locustag:string -> ?increment:int -> ?gffver:string -> ?compliant:bool -> ?centre:string -> ?genus:string -> ?species:string -> ?strain:string -> ?plasmid:string -> ?kingdom:string -> ?gcode:int -> ?gram: [ `Plus | `Min...
null
https://raw.githubusercontent.com/pveber/bistro/da0ebc969c8c5ca091905366875cbf8366622280/lib/bio/prokka.mli
ocaml
open Bistro open Formats val run : ?prefix:string -> ?addgenes:bool -> ?locustag:string -> ?increment:int -> ?gffver:string -> ?compliant:bool -> ?centre:string -> ?genus:string -> ?species:string -> ?strain:string -> ?plasmid:string -> ?kingdom:string -> ?gcode:int -> ?gram: [ `Plus | `Min...
ec45957c325ab76f47a5dad25f26be7c7befbcf4b0c44eea21b93607a369be3e
camllight/camllight
hashtblc.ml
(* Hash tables, without space leaks *) #open "exc";; #open "int";; #open "eq";; #open "fvect";; (* We do dynamic hashing, and we double the size of the table when buckets become too long, re-hashing the elements. *) type ('a, 'b) t = { mutable max_len: int; (* max length of a bucket *) mu...
null
https://raw.githubusercontent.com/camllight/camllight/0cc537de0846393322058dbb26449427bfc76786/sources/contrib/camltk4/libsupport/hashtblc.ml
ocaml
Hash tables, without space leaks We do dynamic hashing, and we double the size of the table when buckets become too long, re-hashing the elements. max length of a bucket the buckets Occasionnally, a bucket may become too long during a resize
#open "exc";; #open "int";; #open "eq";; #open "fvect";; type ('a, 'b) t = and ('a, 'b) bucketlist = Empty | Cons of 'a * 'b * ('a, 'b) bucketlist ;; let new initial_size = { max_len = 2; data = make_vect initial_size Empty } ;; let clear h = for i = 0 to vect_length h.data - 1 do h.data.(i) <- Empt...
0c1bc7cc92c77ba34f6fb8b9492a074a2884effa9899a5a586c2261e1695fe9e
codinuum/cca
macro.ml
Copyright 2012 - 2020 Codinuum Software Lab < > 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 wri...
null
https://raw.githubusercontent.com/codinuum/cca/88ea07f3fe3671b78518769d804fdebabcd28e90/src/ast/analyzing/langs/verilog/parsing/src/macro.ml
ocaml
Copyright 2012 - 2020 Codinuum Software Lab < > 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 wri...
dc4d2395af1391d3ac4bcd1250a787b9549d0e9cffaa51d7c8feff9d26549276
fetburner/Coq2SML
tactic_printer.ml
(************************************************************************) 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/tactic_printer.ml
ocaml
********************************************************************** // * This file is distributed under the terms of the * GNU Lesser General Public License Version 2.1 ********************************************************************** Does not print change of evars PC...
v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2014 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * open Pp open Util open Sign o...
9b7cb8bf19b82f30b294004132d54fb21e0223391e5777c9a592735f41d3c53a
mvc-works/stack-workflow
schema.cljs
(ns app.schema ) (def store {:states {}, :data 0})
null
https://raw.githubusercontent.com/mvc-works/stack-workflow/ae932f0d2d623fe5bbf6220b120f24d73358d34d/src/app/schema.cljs
clojure
(ns app.schema ) (def store {:states {}, :data 0})
16682019af775f3f5824bc84311cc3f8bb66223873dd492e8fc1ff5e1a368106
spectrum-finance/cardano-dex-contracts
Plutus.hs
# LANGUAGE AllowAmbiguousTypes # # LANGUAGE DataKinds # # LANGUAGE DerivingStrategies # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE PartialTypeSignatures # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # # LANGUAGE NoImplicitPrelude # # OPTIONS_G...
null
https://raw.githubusercontent.com/spectrum-finance/cardano-dex-contracts/87bdbc26dbe9ae5f6c59e608d728330f8166f19c/cardano-dex-contracts-offchain/ErgoDex/Plutus.hs
haskell
# LANGUAGE AllowAmbiguousTypes # # LANGUAGE DataKinds # # LANGUAGE DerivingStrategies # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE PartialTypeSignatures # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # # LANGUAGE NoImplicitPrelude # # OPTIONS_G...
f50e09533229a64a8b5553f79352cc16154ea7a4392c51683a183ed30c0c1d78
marigold-dev/mankavar
woo_record.ml
module P = Ppxlib module A = P.Ast_builder.Default module W = Woo_types module SMap = W.SMap module Make(Params : Woo_helpers.PARAMS) = struct module Helpers = Woo_helpers.Generate(Params) open Helpers let make prefix : W.record -> P.structure_item list = fun property_declarations -> let lts = (SMap.to_kv_list prope...
null
https://raw.githubusercontent.com/marigold-dev/mankavar/ac6bf1e327ef6a91777e7d045c0f7c0cf1fd0e6e/vendors/ppx-woo/woo_record.ml
ocaml
module P = Ppxlib module A = P.Ast_builder.Default module W = Woo_types module SMap = W.SMap module Make(Params : Woo_helpers.PARAMS) = struct module Helpers = Woo_helpers.Generate(Params) open Helpers let make prefix : W.record -> P.structure_item list = fun property_declarations -> let lts = (SMap.to_kv_list prope...
2adb949d207042511dff75cb4f6718136d46077a704dbcd7716c4915591ce189
alphaHeavy/llvm-general-typed
Apply.hs
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE KindSignatures # # LANGUAGE MultiParamTypeClasses # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # # LANGUAGE TypeOperators # module LLVM.General.Typed.Instructions.Apply ( Apply(..) , ArgumentList ) where ...
null
https://raw.githubusercontent.com/alphaHeavy/llvm-general-typed/75c39111f7fc685aacb3eaf1b2948451e7222e0b/llvm-general-typed-pure/src/LLVM/General/Typed/Instructions/Apply.hs
haskell
The rightmost type is the result
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE KindSignatures # # LANGUAGE MultiParamTypeClasses # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # # LANGUAGE TypeOperators # module LLVM.General.Typed.Instructions.Apply ( Apply(..) , ArgumentList ) where ...
d4f514669eee0a5d0a287da0f3ef8bc4728cb241defa1c4f40b1e678dff91440
sirherrbatka/statistical-learning
methods.lisp
(cl:in-package #:statistical-learning.ensemble) (defmethod initialize-instance :after ((instance weights-based-data-points-sampler) &rest initargs) (declare (ignore initargs)) (let ((sampling-rate (sampling-rate instance))) (check-type sampling-rate real) (unless (< 0.0 sampling-rate 1.0) (...
null
https://raw.githubusercontent.com/sirherrbatka/statistical-learning/8f7b0127c2c123faa5cd6a92f0e9236c75de6687/source/ensemble/methods.lisp
lisp
(normalization (/ (- 1.0d0 large-gradient-sampling-rate) small-gradient-sampling-rate)) (iterate (for i from large-gradient-count below data-points-count) (for point = (aref ordered-data-points i)) (iterate (for j from 0 below (sl.data:attributes-count response))
(cl:in-package #:statistical-learning.ensemble) (defmethod initialize-instance :after ((instance weights-based-data-points-sampler) &rest initargs) (declare (ignore initargs)) (let ((sampling-rate (sampling-rate instance))) (check-type sampling-rate real) (unless (< 0.0 sampling-rate 1.0) (...
08ddd0e46465c7c0bf28f42f44b36af5bf0250834d06e98966a4d92bf9639253
OCamlPro/OCamlPro-OCaml-Branch
odoc_latex_style.ml
(***********************************************************************) (* OCamldoc *) (* *) , projet Cristal , INRIA Rocquencourt (* ...
null
https://raw.githubusercontent.com/OCamlPro/OCamlPro-OCaml-Branch/3a522985649389f89dac73e655d562c54f0456a5/inline-more/ocamldoc/odoc_latex_style.ml
ocaml
********************************************************************* OCamldoc ...
, projet Cristal , INRIA Rocquencourt Copyright 2001 Institut National de Recherche en Informatique et en Automatique . All rights reserved . This file is distributed under the terms of the Q Public License version 1.0 . * The content of the LaTeX style to genera...
bd71016bbf88a4633463b3b17012f0a5b95fa7ac6e0c06df97057f7c412c597c
leptonyu/salak
Toml.hs
{-# LANGUAGE GADTs #-} -- | Module : . Toml Copyright : ( c ) 2019 License : MIT Maintainer : -- Stability: experimental -- Portability: portable -- Toml support for " " . -- module Salak.Toml( TOML(..) , loadToml , runSalakWithToml ) where import Control.Exception ...
null
https://raw.githubusercontent.com/leptonyu/salak/0976e3f0792913df259e9bcaaee02f13d2b501f7/salak-toml/src/Salak/Toml.hs
haskell
# LANGUAGE GADTs # | Stability: experimental Portability: portable | Load Toml
Module : . Toml Copyright : ( c ) 2019 License : MIT Maintainer : Toml support for " " . module Salak.Toml( TOML(..) , loadToml , runSalakWithToml ) where import Control.Exception (Exception, throwIO) import qualified Data.HashMap.Strict as HM import ...
8b24bfe1cf14cea93b4741129833ffd563135c3d0c191df28aed59ccd5af1583
ghc/nofib
coins.hs
{-# LANGUAGE BangPatterns #-} import Data.List import System.Environment import Control.Parallel import Control.Parallel.Strategies import Control.Applicative Rough results , GHC 6.13 : ( val=777 ) V1 ( SDM ): 2.2s V2 ( SDM ): 2.7s V3 ( SDM , parallel ): 1.0s on 7 cores ...
null
https://raw.githubusercontent.com/ghc/nofib/f34b90b5a6ce46284693119a06d1133908b11856/parallel/coins/coins.hs
haskell
# LANGUAGE BangPatterns # --------------------------------------------------------------------------- --------------------------------------------------------------------------- The idea here is that by avoiding the append we might be able to below is much easier) --SDM ** making append less strict (omit ** above) ...
import Data.List import System.Environment import Control.Parallel import Control.Parallel.Strategies import Control.Applicative Rough results , GHC 6.13 : ( val=777 ) V1 ( SDM ): 2.2s V2 ( SDM ): 2.7s V3 ( SDM , parallel ): 1.0s on 7 cores V4 ( original ): got b...
0472e8740ea52e97d0205a28aa730dadfd3e282e9c849c93a7d2b5e1807eecc3
janestreet/bonsai
bonsai.ml
module Stable = struct module Private = struct module Node_path = Node_path.Stable module Graph_info = Graph_info.Stable end end open! Core open! Import module type Model = Module_types.Model module type Action = Module_types.Action module type Enum = Module_types.Enum module type Comparator = Module_type...
null
https://raw.githubusercontent.com/janestreet/bonsai/782fecd000a1f97b143a3f24b76efec96e36a398/src/bonsai.ml
ocaml
module Stable = struct module Private = struct module Node_path = Node_path.Stable module Graph_info = Graph_info.Stable end end open! Core open! Import module type Model = Module_types.Model module type Action = Module_types.Action module type Enum = Module_types.Enum module type Comparator = Module_type...
d141f86ea8cfc1b305c6a6c1847770199fc112c0910c4cf5bd39ffa5b0dd6ead
jacius/lispbuilder
mandelbrot.lisp
Demonstration / Test of using SDL ( Simple Media Layer ) library using CFFI for foreign function interfacing ... ( C)2006 Frank Busse Modifications ( more realtime , allows zoom in ) ;;;; see COPYING for license ;;;; From "-buss.de/lisp/canvas.html" (in-package #:sdl-examples) (defvar *x0* 0.2) (defvar *...
null
https://raw.githubusercontent.com/jacius/lispbuilder/e693651b95f6818e3cab70f0074af9f9511584c3/lispbuilder-sdl/examples/mandelbrot.lisp
lisp
see COPYING for license From "-buss.de/lisp/canvas.html" set the new center point set the new center point
Demonstration / Test of using SDL ( Simple Media Layer ) library using CFFI for foreign function interfacing ... ( C)2006 Frank Busse Modifications ( more realtime , allows zoom in ) (in-package #:sdl-examples) (defvar *x0* 0.2) (defvar *y0* 0.5) (defvar *x1* 0.4) (defvar *y1* 0.7) (defvar *mandelbrot-wi...
a35f92010365291b8d34e63a9a7e8a809f89b90079f88c62904c542d2a4a0880
merijn/Belewitte
V0.hs
# LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # # LANGUAGE DerivingStrategies # # LANGUAGE FlexibleInstances # {-# LANGUAGE GADTs #-} # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # # LANGUAGE QuasiQuotes # # LANGUAGE StandaloneDeriving # # LANGUAGE TemplateHaskell # # LANGUAGE TypeFamilies...
null
https://raw.githubusercontent.com/merijn/Belewitte/cab6010a2bc54acfc4f4b169c95799fe455799ef/benchmark-analysis/src/Schema/Timers/V0.hs
haskell
# LANGUAGE GADTs #
# LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # # LANGUAGE DerivingStrategies # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # # LANGUAGE QuasiQuotes # # LANGUAGE StandaloneDeriving # # LANGUAGE TemplateHaskell # # LANGUAGE TypeFamilies # # LANGUAGE Undecidab...
b0be5642fe71d5c428eabc86a3659e607edfeba3b158ab3b58e18d82a890d5aa
Glue42/gateway-modules
constants.cljc
(ns gateway.domains.metrics.constants (:require [gateway.reason :refer [reason]])) (defonce metrics-domain-uri "metrics") (defonce metrics-failure (str metrics-domain-uri ".errors.failure")) (defonce metrics-unhandled-message (str metrics-domain-uri ".errors.unhandled_message")) (defonce metrics-bad-identity (str m...
null
https://raw.githubusercontent.com/Glue42/gateway-modules/be48a132134b5f9f41fd6a6067800da6be5e6eca/metrics-domain/src/gateway/domains/metrics/constants.cljc
clojure
(ns gateway.domains.metrics.constants (:require [gateway.reason :refer [reason]])) (defonce metrics-domain-uri "metrics") (defonce metrics-failure (str metrics-domain-uri ".errors.failure")) (defonce metrics-unhandled-message (str metrics-domain-uri ".errors.unhandled_message")) (defonce metrics-bad-identity (str m...
8b2fd0583cc172c0b1fd62c0b71485d50045455b989d8c409592a33aa08d345c
namin/lambdajam
lc-direct.scm
(let () (define lc (lambda (exp env) (begin (show exp) (if (symbol? exp) (env exp) (if (pair? exp) (if (eq? (car exp) 'sub1) (- (lc (car (cdr exp)) env) 1) (if (eq? (car exp) 'zero?) (= (l...
null
https://raw.githubusercontent.com/namin/lambdajam/58824eeccc15b11f09a02db5a3e3660fbdfe9c3d/lc-direct.scm
scheme
(let () (define lc (lambda (exp env) (begin (show exp) (if (symbol? exp) (env exp) (if (pair? exp) (if (eq? (car exp) 'sub1) (- (lc (car (cdr exp)) env) 1) (if (eq? (car exp) 'zero?) (= (l...
beaf2b24b426b2747a398addae57333ebdf2ac2cbbb53f9ea8d5f05dadb3ce1f
ahungry/pseudo
config.lisp
;; Pseudo - A pseudo 3d multiplayer roguelike Copyright ( C ) 2013 ;; ;; This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or ;; (at your option) any la...
null
https://raw.githubusercontent.com/ahungry/pseudo/a3e6329313e334941f211a991e5853bbe6d247f1/config.lisp
lisp
Pseudo - A pseudo 3d multiplayer roguelike 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 PART...
Copyright ( C ) 2013 it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or You should have received a copy of the GNU Affero General Public License (in-package #:pseudo) (defparameter *websocket-port* 7155) (defparame...