_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
d3a4caca071cd4fb6a65c2833ef377ca254bab0ba1aa37239db0c446b3d692b8
michaelklishin/monger
ragtime_test.clj
(ns monger.test.ragtime-test (:require [monger.core :as mg] [monger.collection :as mc] monger.ragtime [ragtime.protocols :refer :all] [clojure.test :refer :all])) (let [conn (mg/connect) db (mg/get-db conn "monger-test")] (defn purge-collections [f] ...
null
https://raw.githubusercontent.com/michaelklishin/monger/9f3d192dffb16da011f805355b87ae172c584a69/test/monger/test/ragtime_test.clj
clojure
(ns monger.test.ragtime-test (:require [monger.core :as mg] [monger.collection :as mc] monger.ragtime [ragtime.protocols :refer :all] [clojure.test :refer :all])) (let [conn (mg/connect) db (mg/get-db conn "monger-test")] (defn purge-collections [f] ...
a7773570f2bde636f2b6bd5cf0b07e189934ea7793373f396c2fb30e72481901
draperlaboratory/cbat_tools
wp_analysis.ml
(***************************************************************************) (* *) Copyright ( C ) 2018/2019 The Charles Stark Draper Laboratory , Inc. (* *) (* This...
null
https://raw.githubusercontent.com/draperlaboratory/cbat_tools/22d7cf5ce8fa2bf4bd608b79eb1b33aa85fe1b45/wp/plugin/lib/wp_analysis.ml
ocaml
************************************************************************* This file is provided under the license found in the LICENSE file in the top-level director...
Copyright ( C ) 2018/2019 The Charles Stark Draper Laboratory , Inc. This work is funded in part by ONR / NAWC Contract N6833518C0107 . Its content does not necessarily reflect the position or policy of the US open !Core open Bap_main open Bap_wp module Params = Run_parameters module Utils = Wp_...
33d5ddffb6933570b87320f1c7d68bd86037fa7fc660eb4285e67e347a2a4fba
sjl/cl-digraph
package.test.lisp
(defpackage :digraph.test (:use :cl :1am :digraph :digraph.quickutils) (:export :run-tests))
null
https://raw.githubusercontent.com/sjl/cl-digraph/380177f204bb531c13052502b2b453cb1a1fc60a/package.test.lisp
lisp
(defpackage :digraph.test (:use :cl :1am :digraph :digraph.quickutils) (:export :run-tests))
3bf119eac3e326d7c3a70cdafbd0702208230254d3d99ff29743b35acc74889c
avsm/eeww
fake_sched.mli
val run : (unit -> unit) -> Eio.Cancel.t option (** [run fn] runs [fn ()] in a new fiber and returns its context so it can be cancelled. [fn] may suspend at most once. If it doesn't suspend then [run] returns [None] after it finishes. *) val cancel : Eio.Cancel.t -> unit (** [cancel ctx] cancels the context w...
null
https://raw.githubusercontent.com/avsm/eeww/684af99c194ff082836dbb1ada05c8a023dbd844/lib/eio/lib_eio/tests/dscheck/fake_sched.mli
ocaml
* [run fn] runs [fn ()] in a new fiber and returns its context so it can be cancelled. [fn] may suspend at most once. If it doesn't suspend then [run] returns [None] after it finishes. * [cancel ctx] cancels the context with a suitable dummy exception.
val run : (unit -> unit) -> Eio.Cancel.t option val cancel : Eio.Cancel.t -> unit
0a81377d48e46e7dac8d8021de0747f2269dd9981b324bf66a2ffd6ca46467ec
input-output-hk/cardano-sl
Pagination.hs
{- | Support for resource pagination. -} {-# LANGUAGE DeriveGeneric #-} # LANGUAGE GeneralizedNewtypeDeriving # {-# LANGUAGE RankNTypes #-} # LANGUAGE RecordWildCards # module Pos.Util.Pagination ( Page(..) , PerPage(..) , maxPerPageEntries , defaultPerPageEnt...
null
https://raw.githubusercontent.com/input-output-hk/cardano-sl/1499214d93767b703b9599369a431e67d83f10a2/lib/src/Pos/Util/Pagination.hs
haskell
| Support for resource pagination. # LANGUAGE DeriveGeneric # # LANGUAGE RankNTypes # | A `Page` is used in paginated endpoints to request access to a particular subset of a collection. | A `PerPage` is used to specify the number of entries which should be returned as part of a pagina...
# LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE RecordWildCards # module Pos.Util.Pagination ( Page(..) , PerPage(..) , maxPerPageEntries , defaultPerPageEntries , PaginationMetadata(..) , PaginationParams(..) ) where import Universum import Control.Le...
d28eafb78fab7d931abdaae146aae9081400dc67f2041461aa471ab38eff6354
fission-codes/fission
Class.hs
module Fission.Web.Server.App.Content.Initializer.Class (Initializer (..)) where import Network.IPFS.CID.Types import Fission.Prelude import Fission.Web.Server.MonadDB.Types class Monad m => Initializer m where -- | Placeholder app content (e.g. splash page) placeholder :: m CID i...
null
https://raw.githubusercontent.com/fission-codes/fission/11d14b729ccebfd69499a534445fb072ac3433a3/fission-web-server/library/Fission/Web/Server/App/Content/Initializer/Class.hs
haskell
| Placeholder app content (e.g. splash page)
module Fission.Web.Server.App.Content.Initializer.Class (Initializer (..)) where import Network.IPFS.CID.Types import Fission.Prelude import Fission.Web.Server.MonadDB.Types class Monad m => Initializer m where placeholder :: m CID instance Initializer m => Initializer (Transaction ...
0e09d9e1332773ab7abe9e31f3aa92cf40423abe8d5a8ed76021c5cbe2300fa0
angavrilov/cl-simd
sse-utils.lisp
;;; -*- mode: Lisp; indent-tabs-mode: nil; -*- ;;; Copyright ( c ) 2010 , ( ) ;;; ;;; This file implements some common utility functions. ;;; (in-package #:SSE) ;;; CPU control (eval-when (:compile-toplevel :load-toplevel :execute) (declaim (ftype (function (&rest t) (unsigned-byte 32)) cpu-mxcsr-bits)) (de...
null
https://raw.githubusercontent.com/angavrilov/cl-simd/24de2135625d3b831bac2216b7318e0e9fcdab0a/sse-utils.lisp
lisp
-*- mode: Lisp; indent-tabs-mode: nil; -*- This file implements some common utility functions. CPU control
Copyright ( c ) 2010 , ( ) (in-package #:SSE) (eval-when (:compile-toplevel :load-toplevel :execute) (declaim (ftype (function (&rest t) (unsigned-byte 32)) cpu-mxcsr-bits)) (defun cpu-mxcsr-bits (&rest tags) (loop with mask = 0 for tag in tags for bit = (if (listp tag) ...
13e39ef71eb2a3828a68007f10a99689c8fa3a94039d34fd841d83a279d4c70b
rkaippully/gamgee
SecretInput.hs
module Gamgee.Effects.SecretInput ( -- * Effect SecretInput(..) -- * Actions , secretInput -- * Interpretations , runSecretInputIO ) where import Control.Exception.Safe (bracket_) import Polysemy (Embed, Member, Sem) import qualified Polysemy ...
null
https://raw.githubusercontent.com/rkaippully/gamgee/9e510c24b221181e78cd3bdd79c76b4030ddcc23/src/Gamgee/Effects/SecretInput.hs
haskell
* Effect * Actions * Interpretations -------------------------------------------------------------------------------------------------- Effect -------------------------------------------------------------------------------------------------- | An effect that provides input to the application. Intended to be used ...
module Gamgee.Effects.SecretInput SecretInput(..) , secretInput , runSecretInputIO ) where import Control.Exception.Safe (bracket_) import Polysemy (Embed, Member, Sem) import qualified Polysemy as P import Relude import qualified System.IO ...
f6808f28dffb9b510af6d5537090deffbd9578402313288335a99e8cf860a1c3
aaronallen8455/hi-fi
IncorrectType.hs
#!/usr/bin/env cabal {- cabal: build-depends: base -} # OPTIONS_GHC -fplugin HiFi # import HiFi data TestRec = TestRec { f1 :: Bool , f2 :: Int , f3 :: String } hkd :: HKD TestRec Maybe hkd = mkHKD { f1 = Just True , f2 = Just 9 , f3 = Just () } main :: IO () main = pure ()
null
https://raw.githubusercontent.com/aaronallen8455/hi-fi/8dece5086a3c5b2bd8bc335dbd7c5d253e78d9e1/type-error-test/IncorrectType.hs
haskell
cabal: build-depends: base
#!/usr/bin/env cabal # OPTIONS_GHC -fplugin HiFi # import HiFi data TestRec = TestRec { f1 :: Bool , f2 :: Int , f3 :: String } hkd :: HKD TestRec Maybe hkd = mkHKD { f1 = Just True , f2 = Just 9 , f3 = Just () } main :: IO () main = pure ()
384a4b7b5b2b29dd2887796cdb3cfd5bc0262e60cc90639c23d520bd6944ec51
gvannest/piscine_OCaml
one_nn.ml
type radar = float array * string let eu_dist (a:float array) (b:float array) : float = let diff (x:float) (y:float) = x -. y in let square (x:float) = x *. x in let sum (x:float) (y:float) = x +. y in let toSum = Array.map square (Array.map2 diff a b) in let toSroot = Array.fold_left s...
null
https://raw.githubusercontent.com/gvannest/piscine_OCaml/2533c6152cfb46c637d48a6d0718f7c7262b3ba6/d05/ex07/one_nn.ml
ocaml
b g
type radar = float array * string let eu_dist (a:float array) (b:float array) : float = let diff (x:float) (y:float) = x -. y in let square (x:float) = x *. x in let sum (x:float) (y:float) = x +. y in let toSum = Array.map square (Array.map2 diff a b) in let toSroot = Array.fold_left s...
4b7725ca273baf1c34da75d1af8ff4fb95598874c4ccc311e0e84f149f2aa53f
vikram/lisplibraries
timers.lisp
;;;; ;;;; timers.lisp ;;;; Created : 2003 - 11 - 07 by < > ;;;; ;;;; Creating and manipulating timer structures. ;;;; ;;;; ;;;; See the file COPYING for license information. timers.lisp , v 1.5 2003/11/19 17:21:54 xach Exp (in-package #:timer) (defstruct (timer (:conc-name %timer-) ...
null
https://raw.githubusercontent.com/vikram/lisplibraries/105e3ef2d165275eb78f36f5090c9e2cdd0754dd/site/timer-0.4.0/timers.lisp
lisp
timers.lisp Creating and manipulating timer structures. See the file COPYING for license information.
Created : 2003 - 11 - 07 by < > timers.lisp , v 1.5 2003/11/19 17:21:54 xach Exp (in-package #:timer) (defstruct (timer (:conc-name %timer-) (:constructor %make-timer)) name function expire-time repeat-time thread) (defmethod print-object ((object timer) stream) (print-...
d6842d301186d55be31b316f05ad45095c891f57f68d3ba2b871bb2c968356a0
perkss/tinklj
primitives.clj
(ns tinklj.primitives (:import (com.google.crypto.tink.mac MacFactory) (com.google.crypto.tink.streamingaead StreamingAeadFactory) (com.google.crypto.tink.daead DeterministicAeadFactory) (com.google.crypto.tink.signature PublicKeySignFactory ...
null
https://raw.githubusercontent.com/perkss/tinklj/5bd65782c1dbf5112952d76ab7db1efe986fbe1a/src/tinklj/primitives.clj
clojure
(ns tinklj.primitives (:import (com.google.crypto.tink.mac MacFactory) (com.google.crypto.tink.streamingaead StreamingAeadFactory) (com.google.crypto.tink.daead DeterministicAeadFactory) (com.google.crypto.tink.signature PublicKeySignFactory ...
101ce43ff11f328012dd119c67253154ec5e7380181f5101bd6a7661c223e374
shantiii/fds
fds_ft.erl
-module(fds_ft). -compile(inline). -compile(inline_list_funcs). -compile({inline_size , 1000 } ) . -export([new/0, push/2, pop/1, peek/1, drop/1, foldl/3]). -export([rpush/2, rpop/1, rpeek/1, rdrop/1, foldr/3]). -export([from_list/1, to_list/1, count/1]). -export([reverse/1, concat/2]). Core Data Structure : Finge...
null
https://raw.githubusercontent.com/shantiii/fds/5c941db87ef425fe014642ddc33753c08c8b9999/src/fds_ft.erl
erlang
The finger tree is a double-ended sequence representation that allows for efficient access at either end. new() push(Item, Seq) pop(Seq) peek(Seq) drop(Seq) O(n) count(Seq) a finger tree of type t() requires understanding a few basic types: empty tree (the atom ft0) monoid tree (the tuple { Term}) ...
-module(fds_ft). -compile(inline). -compile(inline_list_funcs). -compile({inline_size , 1000 } ) . -export([new/0, push/2, pop/1, peek/1, drop/1, foldl/3]). -export([rpush/2, rpop/1, rpeek/1, rdrop/1, foldr/3]). -export([from_list/1, to_list/1, count/1]). -export([reverse/1, concat/2]). Core Data Structure : Finge...
833fd49b3961c6b8f8a39dc0d443a638a65af9f2a6f72869aa21ff76d7c4e326
g-andrade/locus
locus_mmdb_tree_walk_manager.erl
Copyright ( c ) 2021 - 2023 %% %% 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 without limitation %% the rights to use, copy, modify, merge, publish, di...
null
https://raw.githubusercontent.com/g-andrade/locus/c731b1a4a819e998c60d90a0484e75e36966aa8c/src/locus_mmdb_tree_walk_manager.erl
erlang
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), the rights to use, copy, modify, merge, publish, distribute, sublicense, Software is furnished to do so, subject to the following conditions: The above copyright not...
Copyright ( c ) 2021 - 2023 to deal in the Software without restriction , including without limitation and/or sell copies of the Software , and to permit persons to whom the all copies or substantial portions of the Software . THE SOFTWARE IS PROVIDED " AS IS " , WITHOUT WARRANTY OF ANY KIND , EXPRESS OR ...
fb7de5d93d50f36c7236faf96a837ef4861eb544419d27623032939326003f63
MinaProtocol/mina
pasta.ml
module Basic = Kimchi_pasta_basic include Basic module Pallas_based_plonk = Pallas_based_plonk
null
https://raw.githubusercontent.com/MinaProtocol/mina/8403887a428f56e91bfdf4187c6b8dc260e5424a/src/lib/crypto/kimchi_backend/pasta/pasta.ml
ocaml
module Basic = Kimchi_pasta_basic include Basic module Pallas_based_plonk = Pallas_based_plonk
65b2edd2313f9736a8c42d484b80eca2e21b4bb2d0ca8d853eff41ca1fc66ed9
samuela/bidirectional-typing
Lib.hs
module Lib where import Data.List (nub, intersect) import Data.Map (Map, (!)) import qualified Data.Map as Map import qualified Data.Set as Set -- import Debug.Trace (trace) type Id = String type AnnoTypeId = String newtype Loc = Loc Integer deriving (Show, Eq, Ord) data AnnoType = AUnit | AIdent AnnoTypeId...
null
https://raw.githubusercontent.com/samuela/bidirectional-typing/7fd88cbbb477698fe4c56a6326cde2caee0be456/src/Lib.hs
haskell
import Debug.Trace (trace) A convenience form of expressions that do not require source locations. These show (EIdent _ (Id x)) = x show (ELam _ (Id x) body) = "(" ++ x ++ " => " ++ (show body) ++ ")" ------------------------------------------------------------------------------ annotation quantifiers and conv...
module Lib where import Data.List (nub, intersect) import Data.Map (Map, (!)) import qualified Data.Map as Map import qualified Data.Set as Set type Id = String type AnnoTypeId = String newtype Loc = Loc Integer deriving (Show, Eq, Ord) data AnnoType = AUnit | AIdent AnnoTypeId | ALam AnnoType AnnoType ...
95937965663ba45aaacbf9a8f88cb8b2602b310fcba7cb9f7707a81fe3961bca
empear-analytics/codescene-ci-cd
bitbucket_api.clj
(ns codescene-ci-cd.bitbucket-api "Wraps the bitbucket http API" (:require [clj-http.client :as http] [clojure.data.json :as json])) (defn get-commits "Returns a list of commits (maps)" [commits-url user password timeout] (:body (http/get commits-url {:basic-auth [user pass...
null
https://raw.githubusercontent.com/empear-analytics/codescene-ci-cd/abb445e43c5127589c623fa7917d4ac136814881/src/codescene_ci_cd/bitbucket_api.clj
clojure
:body (format "{\"content\": {\"raw\": \"%s\"}}" text)
(ns codescene-ci-cd.bitbucket-api "Wraps the bitbucket http API" (:require [clj-http.client :as http] [clojure.data.json :as json])) (defn get-commits "Returns a list of commits (maps)" [commits-url user password timeout] (:body (http/get commits-url {:basic-auth [user pass...
937c549acc993b9efb93e68475527628f25f6143d223480d8c054a93bf70f258
panicz/grasp
print.scm
(import (define-syntax-rule)) (import (define-interface)) (import (define-object)) (import (define-parameter)) (import (for)) (import (conversions)) (import (functions)) (define-parameter (current-display-procedure)::procedure display) (define-syntax-rule (print elements ...) ((current-display-procedure) elements...
null
https://raw.githubusercontent.com/panicz/grasp/7badf508a4f38d49cba285bc44dbe13681728beb/src/print.scm
scheme
(import (define-syntax-rule)) (import (define-interface)) (import (define-object)) (import (define-parameter)) (import (for)) (import (conversions)) (import (functions)) (define-parameter (current-display-procedure)::procedure display) (define-syntax-rule (print elements ...) ((current-display-procedure) elements...
c9c6240bb5d9669e79ca4a82ff75d13b16d4b25199b7c3253f2ccf08111042b9
privet-kitty/dufy
gen-inversed-mrd.lisp
-*- coding : utf-8 -*- ;;; This script file outputs the LCHab - to - Munsell data as a ;;; file. ;;; (eval-when (:compile-toplevel :load-toplevel :execute) (ql:quickload '(:dufy/core :dufy/munsell :alexandria :iterate))) (use-package '(:iterate :dufy/internal :dufy/munsell)) (defparameter *this-pathname* (uio...
null
https://raw.githubusercontent.com/privet-kitty/dufy/c6ad03a9fca16a759c1c52449ac88420a536feca/src/munsell/gen-inversed-mrd.lisp
lisp
file. values
-*- coding : utf-8 -*- This script file outputs the LCHab - to - Munsell data as a (eval-when (:compile-toplevel :load-toplevel :execute) (ql:quickload '(:dufy/core :dufy/munsell :alexandria :iterate))) (use-package '(:iterate :dufy/internal :dufy/munsell)) (defparameter *this-pathname* (uiop:current-lisp-fil...
a17f5dd13fcc34a0fb183d13fa284bc86b2fb69342c1d577e5cff55e89317b72
SNePS/SNePS2
sneps79.lisp
-*- Mode : Lisp ; Syntax : Common - Lisp ; Package : USER ; Base : 10 -*- Copyright ( C ) 1984 - -2013 Research Foundation of State University of New York Version : $ I d : , v ;;; This file is part of SNePS. $ BEGIN LICENSE$ The contents of this file are subject to the University at Buffalo Public ...
null
https://raw.githubusercontent.com/SNePS/SNePS2/d3862108609b1879f2c546112072ad4caefc050d/demo/sneps/sneps79.lisp
lisp
Syntax : Common - Lisp ; Package : USER ; Base : 10 -*- This file is part of SNePS. you may not use this file except in compliance with the License. You may obtain a copy of the License at . edu/sneps/Downloads/ubpl.pdf. or implied. See the License for the specific language gov erning rights and limitations ...
Copyright ( C ) 1984 - -2013 Research Foundation of State University of New York Version : $ I d : , v $ BEGIN LICENSE$ The contents of this file are subject to the University at Software distributed under the License is distributed on an " AS IS " basis , WITHOUT WARRANTY OF ANY KIND , either expre...
cc9972719af0ef321bb90279160371c8f0b32555ad1afe3b1c01da6167637603
aeternity/mnesia_rocksdb
mnesia_rocksdb_fallback.erl
%%---------------------------------------------------------------- Copyright ( c ) 2013 - 2016 Klarna AB %% 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 License at %% %% ...
null
https://raw.githubusercontent.com/aeternity/mnesia_rocksdb/b0bf4b6b9c68b35e37df0fb56a8b5c6417d20e54/test/mnesia_rocksdb_fallback.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 permissions an...
Copyright ( c ) 2013 - 2016 Klarna AB 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 -module(mnesia_rocksdb_fallback). -expo...
556abc2b2ad880c44e9c35e7aa43c89cdde1e7e6c92c7d8742bb78d0c6ff0f2d
rtoy/cmucl
boot-2009-03-cross-unicode-sparc.lisp
(load "target:bootfiles/19e/boot-2008-05-cross-unicode-sparc")
null
https://raw.githubusercontent.com/rtoy/cmucl/9b1abca53598f03a5b39ded4185471a5b8777dea/src/bootfiles/19f/boot-2009-03-cross-unicode-sparc.lisp
lisp
(load "target:bootfiles/19e/boot-2008-05-cross-unicode-sparc")
241e61883c128ea924120190e8fbf885b9130b266fc01d4873cd9a8fb4bdd6f8
yoriyuki/Camomile
uMap.ml
(** Maps over Unicode characters. *) Copyright ( C ) 2002 , 2003 . (* This library 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 of the License , or ( at your option ...
null
https://raw.githubusercontent.com/yoriyuki/Camomile/d7d8843c88fae774f513610f8e09a613778e64b3/Camomile/public/uMap.ml
ocaml
* Maps over Unicode characters. This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License may link, statically or dynamically, a "work that uses this library" with a publicly distributed version of this library to produce an executable fil...
Copyright ( C ) 2002 , 2003 . as published by the Free Software Foundation ; either version 2 of the License , or ( at your option ) any later version . As a special exception to the GNU Library General Public License , you additional requirements listed in clause 6 of the GNU Library General we mean e...
dc037296b3be4cc705b938c310302d89a9a50de3a6a6dc6eb679dd83caf28e98
webyrd/n-grams-for-synthesis
tiny-clos.scm
; Mode: Scheme ; ; ; ********************************************************************** Copyright ( c ) 1992 Xerox Corporation . All Rights Reserved . ; ; Use, reproduction, and preparation of derivative works are permitted. ; Any copy of this software or of any derivative work must include the above copy...
null
https://raw.githubusercontent.com/webyrd/n-grams-for-synthesis/b53b071e53445337d3fe20db0249363aeb9f3e51/datasets/srfi/srfi-44/srfi-44/tiny-clos/tiny-clos.scm
scheme
Mode: Scheme ********************************************************************** Use, reproduction, and preparation of derivative works are permitted. Any copy of this software or of any derivative work must include the one after it. Any distribution of this software or derivative works ALL WARRANTIES, EX...
Copyright ( c ) 1992 Xerox Corporation . All Rights Reserved . above copyright notice of Xerox Corporation , this paragraph and the must comply with all applicable United States export control laws . This software is made available AS IS , and XEROX CORPORATION DISCLAIMS IMPLIED WARRANTIES OF MERCHANTAB...
e0d8e5d5b3d8b890fc66eb93a8ea78cb135a8419d0dfbd3e08993ee90b6e4f6e
mhallin/graphql_ppx
arg_named_query.ml
open Test_shared module My_query = [%graphql {| query ($query: String!) { argNamedQuery(query: $query) } |}] let serializes_variables () = test_json ((My_query.make ~query:"a query" ())#variables) (Yojson.Basic.from_string {|{"query": "a query"}|}) let no_name_clash () = Alcotest.(check (neg str...
null
https://raw.githubusercontent.com/mhallin/graphql_ppx/5796b3759bdf0d29112f48e43a2f0623f7466e8a/tests_native/arg_named_query.ml
ocaml
open Test_shared module My_query = [%graphql {| query ($query: String!) { argNamedQuery(query: $query) } |}] let serializes_variables () = test_json ((My_query.make ~query:"a query" ())#variables) (Yojson.Basic.from_string {|{"query": "a query"}|}) let no_name_clash () = Alcotest.(check (neg str...
6f6526e28c01c0c5f3162fe03cde41d22838d6d9d6f1d5b9afbb3c31afb1d5e0
spurious/sagittarius-scheme-mirror
comparators.scm
-*- mode : scheme ; coding : utf-8 ; -*- ;;; ;;; comparators.scm - SRFI-114 comparators ;;; Copyright ( c ) 2010 - 2014 < > ;;; ;;; Redistribution and use in source and binary forms, with or without ;;; modification, are permitted provided that the following conditions ;;; are met: ;;; ;;; ...
null
https://raw.githubusercontent.com/spurious/sagittarius-scheme-mirror/53f104188934109227c01b1e9a9af5312f9ce997/sitelib/srfi/%253a114/comparators.scm
scheme
coding : utf-8 ; -*- comparators.scm - SRFI-114 comparators Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list o...
Copyright ( c ) 2010 - 2014 < > " AS IS " AND ANY EXPRESS OR IMPLIED WARRANTIES , INCLUDING , BUT NOT SPECIAL , EXEMPLARY , OR CONSEQUENTIAL DAMAGES ( INCLUDING , BUT NOT LIMITED LIABILITY , WHETHER IN CONTRACT , STRICT LIABILITY , OR TORT ( INCLUDING (library (srfi :114 comparators) (export...
b9eefee38738935f0ab502ccf8f3d91a343044aac107742e6e2328954d6b072a
emina/rosette
solve.rkt
#lang rosette (require rackunit rackunit/text-ui rosette/lib/roseunit) (define-symbolic a b c boolean?) (define-symbolic xi yi zi integer?) (define-symbolic xr yr zr real?) (define-symbolic xb yb zb (bitvector 4)) (define basic-tests (test-suite+ "Solve tests with no (effective) finitization." (current-bitwidt...
null
https://raw.githubusercontent.com/emina/rosette/a64e2bccfe5876c5daaf4a17c5a28a49e2fbd501/test/query/solve.rkt
racket
#lang rosette (require rackunit rackunit/text-ui rosette/lib/roseunit) (define-symbolic a b c boolean?) (define-symbolic xi yi zi integer?) (define-symbolic xr yr zr real?) (define-symbolic xb yb zb (bitvector 4)) (define basic-tests (test-suite+ "Solve tests with no (effective) finitization." (current-bitwidt...
ee25017a19643dbcbd2febb9b66f8b838412cf4fad43e65185ec145fb7371f0f
exercism/haskell
Matrix.hs
module Matrix (saddlePoints) where import Data.Array (Array) saddlePoints :: Array i e -> [i] saddlePoints matrix = error "You need to implement this function."
null
https://raw.githubusercontent.com/exercism/haskell/2b98084efc7d5ab098975c462f7977ee19c2fd29/exercises/practice/saddle-points/src/Matrix.hs
haskell
module Matrix (saddlePoints) where import Data.Array (Array) saddlePoints :: Array i e -> [i] saddlePoints matrix = error "You need to implement this function."
8eb947ccde7e12759017c959502a62938e5ebcd7934b2ee99efda85e8bf400f9
marcoheisig/Typo
upgraded-complex-part-ntype.lisp
(in-package #:typo.ntype) (defmethod upgraded-complex-part-ntype ((primitive-ntype primitive-ntype)) (primitive-ntype-upgraded-complex-part-ntype primitive-ntype)) (defmethod upgraded-complex-part-ntype ((ntype ntype)) (primitive-ntype-upgraded-complex-part-ntype (ntype-primitive-ntype ntype))) (let ((cache (...
null
https://raw.githubusercontent.com/marcoheisig/Typo/88f2708bbb8f8f8ac2dd19cd153a16c06554a6aa/code/ntype/upgraded-complex-part-ntype.lisp
lisp
(in-package #:typo.ntype) (defmethod upgraded-complex-part-ntype ((primitive-ntype primitive-ntype)) (primitive-ntype-upgraded-complex-part-ntype primitive-ntype)) (defmethod upgraded-complex-part-ntype ((ntype ntype)) (primitive-ntype-upgraded-complex-part-ntype (ntype-primitive-ntype ntype))) (let ((cache (...
dc8eb06a3befeb0c061c912b3450fa4d2d2cfa5e5ea4729671fb25ef2f396fca
zotonic/mod_vault
mod_vault.erl
@author < > 2012 %% @doc Provides encryption of values. Copyright 2012 %% 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 applic...
null
https://raw.githubusercontent.com/zotonic/mod_vault/3f197250f728a167867d9939b084fa2717c86966/mod_vault.erl
erlang
@doc Provides encryption of values. you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License f...
@author < > 2012 Copyright 2012 Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(mod_vault). -mod_title("Secure Vault"). -mod_description("Implements a secure vault for encryption of data."). -mod_sche...
b9221baa790d3fa2b94c21c2eb4de933904d4f392ac4afd88ea72713e0da1cb4
ryanpbrewster/haskell
P026.hs
module Problems.P026 ( solve ) where import Data.Function (on) import Data.List (nub, (\\)) import Util.Math (powerMod) import Util.List (maximumBy) - A unit fraction contains 1 in the numerator . The decimal representation of the - unit fractions with denominators 2 to 10 are given : - - 1/2 =...
null
https://raw.githubusercontent.com/ryanpbrewster/haskell/6edd0afe234008a48b4871032dedfd143ca6e412/project-euler/src/Problems/P026.hs
haskell
module Problems.P026 ( solve ) where import Data.Function (on) import Data.List (nub, (\\)) import Util.Math (powerMod) import Util.List (maximumBy) - A unit fraction contains 1 in the numerator . The decimal representation of the - unit fractions with denominators 2 to 10 are given : - - 1/2 =...
ce63f23c3163ed7914c18e73ef1f85ec4c6cc3ece84ccf38662e44d6f162f2a0
thi-ng/demos
webgl07.cljs
(ns ex03.webgl07 (:require [thi.ng.math.core :as m :refer [PI HALF_PI TWO_PI]] [thi.ng.geom.gl.core :as gl] [thi.ng.geom.gl.webgl.constants :as glc] [thi.ng.geom.gl.webgl.animator :as anim] [thi.ng.geom.gl.buffers :as buf] [thi.ng.geom.gl.shaders :as sh] [thi.ng.geom.gl.glmesh :as glm] [thi.ng...
null
https://raw.githubusercontent.com/thi-ng/demos/048cd131099a7db29be56b965c053908acad4166/ws-ldn-11/day1/ex03/src/ex03/webgl07.cljs
clojure
(ns ex03.webgl07 (:require [thi.ng.math.core :as m :refer [PI HALF_PI TWO_PI]] [thi.ng.geom.gl.core :as gl] [thi.ng.geom.gl.webgl.constants :as glc] [thi.ng.geom.gl.webgl.animator :as anim] [thi.ng.geom.gl.buffers :as buf] [thi.ng.geom.gl.shaders :as sh] [thi.ng.geom.gl.glmesh :as glm] [thi.ng...
8c53c89b27f25d365d29bc7faef3469f98c7149f81fe62f15198c6340d8c5d36
HealthSamurai/unit-map
io.cljc
(ns unit-map.impl.io (:refer-clojure :exclude [format]) (:require [unit-map.impl.util :as util] [clojure.string :as str])) ;; TODO: move all date time related consts to type definition ;; TODO: add convert from/to java/js date objects ;;;;;;;;;; registrator & registry (defn reg-format! [registry-a...
null
https://raw.githubusercontent.com/HealthSamurai/unit-map/22d30031d3cb695298d0da8211066946d07fa590/src/unit_map/impl/io.cljc
clojure
TODO: move all date time related consts to type definition TODO: add convert from/to java/js date objects registrator & registry reader parse format util
(ns unit-map.impl.io (:refer-clojure :exclude [format]) (:require [unit-map.impl.util :as util] [clojure.string :as str])) (defn reg-format! [registry-atom format-name format-params] (swap! registry-atom assoc-in [:format format-name] format-params)) (defn read-format-params [fmt-el] (cond...
5f726c56f2f15795ecfb97abd0e644a9708fa354aca7678a5af07161a3390339
exoscale/telex
ring2.clj
(ns exoscale.telex.interceptor.ring2 (:require [exoscale.interceptor :as ix] [exoscale.telex.interceptor :as interceptor] [exoscale.telex.request :as request] [exoscale.telex.response :as response]) (:import (java.net.http HttpRequest HttpResponse))) (d...
null
https://raw.githubusercontent.com/exoscale/telex/3effada3a3089dcda232c900d3b8d386cac86e20/src/exoscale/telex/interceptor/ring2.clj
clojure
(ns exoscale.telex.interceptor.ring2 (:require [exoscale.interceptor :as ix] [exoscale.telex.interceptor :as interceptor] [exoscale.telex.request :as request] [exoscale.telex.response :as response]) (:import (java.net.http HttpRequest HttpResponse))) (d...
f1142c05a9c2330457c4ee076dd1b6c5f03868367c9376048c32dfbf8df38ae7
titola/incudine
allpass.lisp
(in-package :incudine-tests) (dsp! allpass-test-1 ((dt1 fixnum) (dt2 fixnum) (dt3 fixnum)) (vuglet ((ap ((dt fixnum) in) (allpass-s in 2000 dt .7))) (out (ap dt3 (ap dt2 (ap dt1 (impulse))))))) (dsp! allpass-test-2 (dt1 dt2 dt3) (vuglet ((ap (dt in) (allpass in (* 2000 *sample-durati...
null
https://raw.githubusercontent.com/titola/incudine/325174a54a540f4daa67bcbb29780073c35b7b80/tests/vug/filter/allpass.lisp
lisp
(in-package :incudine-tests) (dsp! allpass-test-1 ((dt1 fixnum) (dt2 fixnum) (dt3 fixnum)) (vuglet ((ap ((dt fixnum) in) (allpass-s in 2000 dt .7))) (out (ap dt3 (ap dt2 (ap dt1 (impulse))))))) (dsp! allpass-test-2 (dt1 dt2 dt3) (vuglet ((ap (dt in) (allpass in (* 2000 *sample-durati...
b390dfbe5053d5b618db41950b32623bc9fa38934b336cde46d2bfe6481f9954
jameshaydon/lawvere
Check.hs
# LANGUAGE OverloadedLists # module Lawvere.Check where import Control.Lens import Data.Generics.Labels () import Data.List (lookup) import qualified Data.Map as Map import qualified Data.Set as Set import Lawvere.Core import Lawvere.Decl import Lawvere.Disp import Lawvere.Expr import Lawvere.Ob import Lawvere.Scalar...
null
https://raw.githubusercontent.com/jameshaydon/lawvere/2d7d12347658b502b317fece26d97984d280226c/src/Lawvere/Check.hs
haskell
TODO: we should also handle the non-equal case
# LANGUAGE OverloadedLists # module Lawvere.Check where import Control.Lens import Data.Generics.Labels () import Data.List (lookup) import qualified Data.Map as Map import qualified Data.Set as Set import Lawvere.Core import Lawvere.Decl import Lawvere.Disp import Lawvere.Expr import Lawvere.Ob import Lawvere.Scalar...
ab0178bb7d9e209aff50159220df3e5165b2b376e84f9693af818777b1a7dd19
rvantonder/CryptOSS
chart.ml
open Core open Cryptoss open Tyxml.Html let changes_highcharts_js crypto = let changes = crypto.Crypto.Stats.changes_1y_per_week in let _dates = List.map changes ~f:(fun { Crypto.Stats.week_timestamp; _ } -> Time.to_span_since_epoch week_timestamp |> Time.Span.to_ms (* ms for highcharts *) ...
null
https://raw.githubusercontent.com/rvantonder/CryptOSS/acd931433f70fd097930b2e62a294af6d31a2a77/site/chart.ml
ocaml
ms for highcharts commits don't have a timestamp, so this is annoying
open Core open Cryptoss open Tyxml.Html let changes_highcharts_js crypto = let changes = crypto.Crypto.Stats.changes_1y_per_week in let _dates = List.map changes ~f:(fun { Crypto.Stats.week_timestamp; _ } -> Time.to_span_since_epoch week_timestamp |> Int.of_float |> Int.to_string) in ...
e4941c51f5573c6f601f727321030417a077032da472b6e433f646d8c19d8e25
cubicle-model-checker/cubicle
solver.ml
(**************************************************************************) (* *) Cubicle (* *) ...
null
https://raw.githubusercontent.com/cubicle-model-checker/cubicle/00f09bb2d4bb496549775e770d7ada08bc1e4866/smt/solver.ml
ocaml
************************************************************************ ...
Cubicle Copyright ( C ) 2011 - 2014 and Universite Paris - Sud 11 This file is distributed under the terms ...
adf8cbcd6e60d91b3f3251489299c4f0f331a35fca2de0f2746df65f4f76cb13
input-output-hk/cardano-sl
Lock.hs
{-# LANGUAGE ConstraintKinds #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE RankNTypes #-} {-# LANGUAGE RecordWildCards #-} # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeApplications # | Module : Pos . DB.GState . Lock Description : A lock on the local state of a node Provides...
null
https://raw.githubusercontent.com/input-output-hk/cardano-sl/1499214d93767b703b9599369a431e67d83f10a2/db/src/Pos/DB/GState/Lock.hs
haskell
# LANGUAGE ConstraintKinds # # LANGUAGE FlexibleContexts # # LANGUAGE RankNTypes # # LANGUAGE RecordWildCards # | Effectful getters and setters for metrics related to the actions remains a goal. But we can't free it up right now because the current mockable system doesn't work well with ethe...
# LANGUAGE ScopedTypeVariables # # LANGUAGE TypeApplications # | Module : Pos . DB.GState . Lock Description : A lock on the local state of a node Provides a lock that is to be taken while modifying , or requiring a consistent view on , the local state ( the database and ) . It collects metrics o...
eba750d42c9a7ce44a9866eca00dac6f0232c297bcd95f6540198460068bf011
gedge-platform/gedge-platform
pg_local.erl
This file is a copy of pg2.erl from the R13B-3 Erlang / OTP %% distribution, with the following modifications: %% 1 ) Process groups are node - local only . %% 2 ) Groups are created / deleted implicitly . %% 3 ) ' join ' and ' leave ' are asynchronous . %% 4 ) the type specs of the exported non - callback fu...
null
https://raw.githubusercontent.com/gedge-platform/gedge-platform/97c1e87faf28ba2942a77196b6be0a952bff1c3e/gs-broker/broker-server/deps/rabbit/src/pg_local.erl
erlang
distribution, with the following modifications: extracted into a separate, guarded section, and rewritten in old-style spec syntax, for better compatibility with older removed. %CopyrightBegin% compliance with the License. You should have received a copy of the Erlang Public License along with thi...
This file is a copy of pg2.erl from the R13B-3 Erlang / OTP 1 ) Process groups are node - local only . 2 ) Groups are created / deleted implicitly . 3 ) ' join ' and ' leave ' are asynchronous . 4 ) the type specs of the exported non - callback functions have been versions of Erlang / OTP . The remaining...
2316eba31473bb97543c7bac0c43fe00fb34b527af2966596ffb6b13c887637d
helpshift/mongrove
core_test.clj
(ns mongrove.core-test (:require [clojure.string :as cs] [clojure.test :refer :all] [mongrove.core :as mc]) (:import (com.mongodb.client MongoClient MongoCollection MongoDatabase))) (def shared-connection (atom nil)) (defn- init-connection-fixture "This will run once before t...
null
https://raw.githubusercontent.com/helpshift/mongrove/85f4723d7a11a17bb1fcd344250b6b371e790331/test/mongrove/core_test.clj
clojure
(ns mongrove.core-test (:require [clojure.string :as cs] [clojure.test :refer :all] [mongrove.core :as mc]) (:import (com.mongodb.client MongoClient MongoCollection MongoDatabase))) (def shared-connection (atom nil)) (defn- init-connection-fixture "This will run once before t...
2b6d43a36261f2a2c2818c065ac0c700d2fd2071abe3eadb472ac982bb375bcf
ghcjs/jsaddle-dom
Setup.hs
import Control.Monad (void) import Control.Concurrent (threadDelay, forkIO) import Data.Foldable (forM_) import Distribution.Simple (simpleUserHooks, buildHook, defaultMainWithHooks) import System.IO (stdout, hFlush) We should split JSDOM.Types into smaller packages . -- For now let the user (or CI system) kn...
null
https://raw.githubusercontent.com/ghcjs/jsaddle-dom/5f5094277d4b11f3dc3e2df6bb437b75712d268f/Setup.hs
haskell
For now let the user (or CI system) know that it is not unusual for there to be no output for a long time.
import Control.Monad (void) import Control.Concurrent (threadDelay, forkIO) import Data.Foldable (forM_) import Distribution.Simple (simpleUserHooks, buildHook, defaultMainWithHooks) import System.IO (stdout, hFlush) We should split JSDOM.Types into smaller packages . main = defaultMainWithHooks simpleUserHoo...
135b20aafd388fa95b0e6da57d9a7b7e66ba34bf5a0b8f2ff72889aedd56e835
rd--/hsc3
sos.help.hs
sos ; same as twopole let theta = line kr (0.2 * pi) pi 5 RemoveSynth rho = line kr 0.6 0.99 5 RemoveSynth b1 = 2 * rho * cos theta b2 = - (rho * rho) in sos (lfSaw ar 200 0 * 0.1) 1 0 0 b1 b2 sos ; -formulas/ let fc = 100 sr = 48000 k = tan (pi * fc / sr) q = 0.707 norm = 1 / (1 + k / ...
null
https://raw.githubusercontent.com/rd--/hsc3/e1c9377f4985f4cc209a9cb11421bc8f1686c6f2/Help/Ugen/sos.help.hs
haskell
sos ; same as twopole let theta = line kr (0.2 * pi) pi 5 RemoveSynth rho = line kr 0.6 0.99 5 RemoveSynth b1 = 2 * rho * cos theta b2 = - (rho * rho) in sos (lfSaw ar 200 0 * 0.1) 1 0 0 b1 b2 sos ; -formulas/ let fc = 100 sr = 48000 k = tan (pi * fc / sr) q = 0.707 norm = 1 / (1 + k / ...
e7bbeaa77310ef312860070c109fccd3579caad7f1759878f731f4b0131887f6
Risto-Stevcev/bastet
Functors.ml
(** * * * * * * * * * * * * * * * * Common instantiated functors * * * * * * * * * * * * * * * * **) module OcamlAbstractInt = Int module OcamlAbstractBool = Bool module OcamlAbstractString = String module OcamlAbstractFloat = Float module ArrayF = struct module Functions = struct module Travsersable = Funct...
null
https://raw.githubusercontent.com/Risto-Stevcev/bastet/030db286f57d2e316897f0600d40b34777eabba6/bastet/src/Functors.ml
ocaml
* * * * * * * * * * * * * * * * * Common instantiated functors * * * * * * * * * * * * * * * * *
module OcamlAbstractInt = Int module OcamlAbstractBool = Bool module OcamlAbstractString = String module OcamlAbstractFloat = Float module ArrayF = struct module Functions = struct module Travsersable = Functions.Traversable (Array.Traversable) end module Int = struct module Eq = Array.Eq (Int.Eq) ...
f8869926dfc409803750206d3e59e0b300bcb7240e8b6e6ad072b79f8d7626ae
ollef/sixty
Binding.hs
{-# LANGUAGE DeriveAnyClass #-} # LANGUAGE DeriveGeneric # # LANGUAGE TupleSections # module Core.Binding where import Data.Persist import Data.String import Name (Name (Name)) import qualified Name import Protolude import qualified Span import qualified Surface.Syntax as Surface data Binding = Spanned !Span.Relat...
null
https://raw.githubusercontent.com/ollef/sixty/571bbe946b698f291ebb19a3f7fc996ae5015391/src/Core/Binding.hs
haskell
# LANGUAGE DeriveAnyClass #
# LANGUAGE DeriveGeneric # # LANGUAGE TupleSections # module Core.Binding where import Data.Persist import Data.String import Name (Name (Name)) import qualified Name import Protolude import qualified Span import qualified Surface.Syntax as Surface data Binding = Spanned !Span.Relative !Name | Unspanned !Name ...
1542e6ce930ac697d064e8e996a152bd00d07297338dea1d9564095a183446e4
qkrgud55/ocamlmulti
typemod.mli
(***********************************************************************) (* *) (* OCaml *) (* *) , projet ...
null
https://raw.githubusercontent.com/qkrgud55/ocamlmulti/74fe84df0ce7be5ee03fb4ac0520fb3e9f4b6d1f/typing/typemod.mli
ocaml
********************************************************************* OCaml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et en Automatique . All rights reserved . This file is distributed under the terms of the Q Public License version 1.0 . $ I d : typemod.mli 12542 2012 - 06 -...
f1ec8a3c6a496dc560f021406acc9376b5db4a2988db1e267fb5ebc9059350ba
clojure/core.typed
errors_ann.clj
Copyright ( c ) , contributors . ;; 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 distribution. ;; By using this software in any fashion, you are agreeing to be bound by ;...
null
https://raw.githubusercontent.com/clojure/core.typed/f5b7d00bbb29d09000d7fef7cca5b40416c9fa91/typed/checker.jvm/src/clojure/core/typed/checker/errors_ann.clj
clojure
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 distribution. By using this software in any fashion, you are agreeing to be bound by the terms of this license. You must not remove ...
Copyright ( c ) , contributors . (ns clojure.core.typed.checker.errors-ann (:require [clojure.core.typed :as t])) (t/ann ^:no-check clojure.core.typed.errors/deprecated-warn [String -> nil]) (t/ann ^:no-check clojure.core.typed.errors/int-error [String -> t/Nothing])
54265519a5bd9834444bcfb2ee9a3ce95b856c9d1168a8347df3b44ed0a685fb
RyanHope/ACT-R
perceptual-motor-issues.lisp
(defvar *response* nil) (defvar *response-time* nil) (defmethod rpm-window-key-event-handler ((win rpm-window) key) (unless *response-time* (setf *response-time* (get-time))) (push (string key) *response*)) (defun simple-task (&optional which) (reset) (let* ((alphabet (list "a" "b" "c" "d" "e" "f" "g" ...
null
https://raw.githubusercontent.com/RyanHope/ACT-R/c65f3fe7057da0476281ad869c7963c84c0ad735/tutorial/unit3/perceptual-motor-issues.lisp
lisp
(defvar *response* nil) (defvar *response-time* nil) (defmethod rpm-window-key-event-handler ((win rpm-window) key) (unless *response-time* (setf *response-time* (get-time))) (push (string key) *response*)) (defun simple-task (&optional which) (reset) (let* ((alphabet (list "a" "b" "c" "d" "e" "f" "g" ...
890467fd793df791bb063ef44fd519a71388d325109ca63ce23262c23a594716
b0-system/b0
test_memo_postdep.ml
--------------------------------------------------------------------------- Copyright ( c ) 2018 The b0 programmers . All rights reserved . Distributed under the ISC license , see terms at the end of the file . --------------------------------------------------------------------------- Copyright (c) 20...
null
https://raw.githubusercontent.com/b0-system/b0/2e7fa30e7e565e8edf831ea5e62c578eeca7c626/test/test_memo_postdep.ml
ocaml
--------------------------------------------------------------------------- Copyright ( c ) 2018 The b0 programmers . All rights reserved . Distributed under the ISC license , see terms at the end of the file . --------------------------------------------------------------------------- Copyright (c) 20...
163e38f185a243d3acde949747ea47266e62bbd6832e3aa83af797768475355e
fulcrologic/semantic-ui-wrapper
ui_dropdown.cljc
(ns com.fulcrologic.semantic-ui.modules.dropdown.ui-dropdown (:require [com.fulcrologic.semantic-ui.factory-helpers :as h] #?(:cljs ["semantic-ui-react$Dropdown" :as Dropdown]))) (def ui-dropdown "A dropdown allows a user to select a value from a series of options. Props: - additionLabel (element|...
null
https://raw.githubusercontent.com/fulcrologic/semantic-ui-wrapper/7bd53f445bc4ca7e052c69596dc089282671df6c/src/main/com/fulcrologic/semantic_ui/modules/dropdown/ui_dropdown.cljc
clojure
(ns com.fulcrologic.semantic-ui.modules.dropdown.ui-dropdown (:require [com.fulcrologic.semantic-ui.factory-helpers :as h] #?(:cljs ["semantic-ui-react$Dropdown" :as Dropdown]))) (def ui-dropdown "A dropdown allows a user to select a value from a series of options. Props: - additionLabel (element|...
48ca25489bdfb4b243499bc291e3147c9aaa405fe7fa0852b2131e9c7d32973f
candera/khordr
main.clj
(ns khordr.main (:require [clojure.stacktrace :as trace] [khordr :as k] [khordr.logging :as log] [khordr.platform :as p] [khordr.platform.common :as com])) ;;; Adding a tray icon ;; TODO: Make this actually work (defn create-image [] (let [image (java.awt.image.Bu...
null
https://raw.githubusercontent.com/candera/khordr/cd9ad9df3dc6692b583b844244260b5b619745f7/src/clj/khordr/main.clj
clojure
Adding a tray icon TODO: Make this actually work Main
(ns khordr.main (:require [clojure.stacktrace :as trace] [khordr :as k] [khordr.logging :as log] [khordr.platform :as p] [khordr.platform.common :as com])) (defn create-image [] (let [image (java.awt.image.BufferedImage. 32 32 java.awt.image.BufferedImage/TYPE_INT...
17b7a5edcc085342e8f10a7a2f22ce6fd8eb8d799a19bf9ae0271fc16bb0bc10
realworldocaml/book
type_abstract.mli
(** Abstract types helpers. An abstract type in the sense of the typerep library is a type whose representation is unknown. Such a type has only a name that can be used to provide and register custom implementation of generics. This is typically a type obtained with the following syntax extension: {...
null
https://raw.githubusercontent.com/realworldocaml/book/d822fd065f19dbb6324bf83e0143bc73fd77dbf9/duniverse/typerep/lib/type_abstract.mli
ocaml
* Abstract types helpers. An abstract type in the sense of the typerep library is a type whose representation is unknown. Such a type has only a name that can be used to provide and register custom implementation of generics. This is typically a type obtained with the following syntax extension: {[ ...
module Make0 (X : Named_intf.S0) : Typerepable.S with type t := X.t module Make1 (X : Named_intf.S1) : Typerepable.S1 with type 'a t := 'a X.t module Make2 (X : Named_intf.S2) : Typerepable.S2 with type ('a, 'b) t := ('a, 'b) X.t module Make3 (X : Named_intf.S3) : Typerepable.S3 with type ('a, 'b, 'c) t := ('a, 'b,...
f5a5fcb2eeff7e01014a6052d26a1d11af52c69fd94f2951656f41369da0e7a5
CodyReichert/qi
enum.lisp
;;;; -*- Mode: lisp; indent-tabs-mode: nil -*- ;;; ;;; enum.lisp --- Tests on C enums. ;;; Copyright ( C ) 2005 - 2006 , loliveira(@)common - lisp.net > ;;; ;;; Permission is hereby granted, free of charge, to any person ;;; obtaining a copy of this software and associated documentation files ( the " Software "...
null
https://raw.githubusercontent.com/CodyReichert/qi/9cf6d31f40e19f4a7f60891ef7c8c0381ccac66f/dependencies/cffi-master/tests/enum.lisp
lisp
-*- Mode: lisp; indent-tabs-mode: nil -*- enum.lisp --- Tests on C enums. 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, distribute, sublicense,...
Copyright ( C ) 2005 - 2006 , loliveira(@)common - lisp.net > 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 ...
b6156cd4d19bc03f2d842c3dfa2b7de238581627618aa5418aa9798b2721b2cc
jeromesimeon/Galax
id.mli
(***********************************************************************) (* *) (* GALAX *) (* XQuery Engine *) (* ...
null
https://raw.githubusercontent.com/jeromesimeon/Galax/bc565acf782c140291911d08c1c784c9ac09b432/base/id.mli
ocaml
********************************************************************* GALAX XQuery Engine ...
Copyright 2001 - 2007 . $ I d : id.mli , v 1.7 2007/02/01 22:08:45 simeon Exp $ type id_gen val create : int -> id_gen val init : id_gen -> int -> unit val next : id_gen -> int val top : id_gen -> int
72f502c863eaaef4c1cda2e34d4e1b5960a7a9e3dd1fa3dba3c14371afda098e
votinginfoproject/data-processor
ballot_measure_contest_test.clj
(ns vip.data-processor.validation.v5.ballot-measure-contest-test (:require [vip.data-processor.validation.v5.ballot-measure-contest :as v5.bmc] [clojure.test :refer :all] [vip.data-processor.test-helpers :refer :all] [vip.data-processor.db.postgres :as psql] [vip.data-p...
null
https://raw.githubusercontent.com/votinginfoproject/data-processor/b4baf334b3a6219d12125af8e8c1e3de93ba1dc9/test/vip/data_processor/validation/v5/ballot_measure_contest_test.clj
clojure
(ns vip.data-processor.validation.v5.ballot-measure-contest-test (:require [vip.data-processor.validation.v5.ballot-measure-contest :as v5.bmc] [clojure.test :refer :all] [vip.data-processor.test-helpers :refer :all] [vip.data-processor.db.postgres :as psql] [vip.data-p...
47a53e0ca9efdd5fd9f257414fccce97038c7777cbd0502013d4803a430bbfc5
pa-ba/equivalence
Monad.hs
# LANGUAGE DefaultSignatures # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE RankNTypes #-} # LANGUAGE TypeFamilies # for type equality ~ with GHC 9.4 # LANGUAGE UndecidableInstan...
null
https://raw.githubusercontent.com/pa-ba/equivalence/af81d7b20638dd7abe70c66bfeaf4b97fe64ea4a/src/Data/Equivalence/Monad.hs
haskell
# LANGUAGE RankNTypes # ------------------------------------------------------------------------------ | Module : Data.Equivalence.Monad License : BSD-3-Clause Stability : stable This is an alternative interface to the union-find implementation in ''Data.Equivalence.STT''. It is wrapped into the mon...
# LANGUAGE DefaultSignatures # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # # LANGUAGE TypeFamilies # for type equality ~ with GHC 9.4 # LANGUAGE UndecidableInstances # Copyright : , ...
9d5b207c968fbc74d4eb6e67019ad9caebd0248a1d232856014ca68d1d1f3890
static-analysis-engineering/codehawk
jCHInstruction.ml
= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = CodeHawk Java Analyzer Author : ------------------------------------------------------------------------------ The MIT License ( MIT ) Copy...
null
https://raw.githubusercontent.com/static-analysis-engineering/codehawk/98ced4d5e6d7989575092df232759afc2cb851f6/CodeHawk/CHJ/jchlib/jCHInstruction.ml
ocaml
jchlib for aligned instructions
= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = CodeHawk Java Analyzer Author : ------------------------------------------------------------------------------ The MIT License ( MIT ) Copy...
279272b93675067e524ef8c4984b9e55697089194da7e5df15f6844636f281c7
Mbodin/murder-generator
pool.mli
(** Module Pool Deals with a pool of current elements, prioritising elements that can explain the currently needed attributes. *) open Libutils (** In this file, elements are supposed to be given as identifiers. *) type element = Id.t (** A register of existing elements. *) type global (** An empty register. ...
null
https://raw.githubusercontent.com/Mbodin/murder-generator/2024a924ffb4ee12d1b7119b699346b21e098892/src/pool.mli
ocaml
* Module Pool Deals with a pool of current elements, prioritising elements that can explain the currently needed attributes. * In this file, elements are supposed to be given as identifiers. * A register of existing elements. * An empty register. * Register that an element exists, and that it may provide the ...
open Libutils type element = Id.t type global val empty_global : global val register_element : global -> element -> Attribute.attribute list -> global val unregister_element : global -> element -> global val unregister_elements : global -> element PSet.t -> global * any element not satisfying the provided pred...
07747a1fdcd2814f773730bbc2ea8173e1ad25cf80693cd1a516f043041d757b
leo-project/leo_gateway
leo_nlm_lock_handler_common.erl
%%====================================================================== %% Network Lock Manager written in Erlang %% Copyright ( c ) 2012 - 2015 Rakuten , 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 Lice...
null
https://raw.githubusercontent.com/leo-project/leo_gateway/7bac8912b762688f0ef237b31fee17e30e3888a3/src/leo_nlm_lock_handler_common.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 permis...
Network Lock Manager written in Erlang Copyright ( c ) 2012 - 2015 Rakuten , 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...
f54ce0ee37ef3c0b99c1f914e4cd4bf897bd31182cd4562681a7bdc2c967d9dc
NorfairKing/smos
TUI.hs
{-# LANGUAGE OverloadedStrings #-} # LANGUAGE RecordWildCards # # LANGUAGE TemplateHaskell # module Smos.Web.Server.Handler.TUI ( getTUIR, getTUIInstanceR, ) where import Smos.Web.Server.Handler.Import getTUIR :: Handler Html getTUIR = withLogin $ \_ -> do navbar <- makeNavBar let terminalWidget = makeTe...
null
https://raw.githubusercontent.com/NorfairKing/smos/cf1669f353dce8c5d5fc2f378a89a9bc945f3f0b/smos-web-server/src/Smos/Web/Server/Handler/TUI.hs
haskell
# LANGUAGE OverloadedStrings #
# LANGUAGE RecordWildCards # # LANGUAGE TemplateHaskell # module Smos.Web.Server.Handler.TUI ( getTUIR, getTUIInstanceR, ) where import Smos.Web.Server.Handler.Import getTUIR :: Handler Html getTUIR = withLogin $ \_ -> do navbar <- makeNavBar let terminalWidget = makeTerminalWidget TUIInstanceR default...
9de4944fad7435eb7906c01e5a5fcfa4329d64e011b2776fd0da29c0e70eae4a
bhauman/figwheel-main
config.clj
(ns figwheel.main.schema.config (:require [clojure.java.io :as io] [clojure.string :as string] [clojure.spec.alpha :as s] [clojure.set] [figwheel.main.util :as util] [figwheel.main.schema.core :as schema :refer [def-spec-meta non-blank-string? directory-exists? file-exists? ensur...
null
https://raw.githubusercontent.com/bhauman/figwheel-main/8db5e58c6e951d9db08600f2552d0170a7cc2932/src/figwheel/main/schema/config.clj
clojure
------ Uncommon options ----------------------------------
(ns figwheel.main.schema.config (:require [clojure.java.io :as io] [clojure.string :as string] [clojure.spec.alpha :as s] [clojure.set] [figwheel.main.util :as util] [figwheel.main.schema.core :as schema :refer [def-spec-meta non-blank-string? directory-exists? file-exists? ensur...
518922345f70ddb27645590d7365f1db020294a1606b14e38d455e5f4ce96acb
nikodemus/SBCL
call.lisp
;;;; function call for the x86 VM This software is part of the SBCL system . See the README file for ;;;; more information. ;;;; This software is derived from the CMU CL system , which was written at Carnegie Mellon University and released into the ;;;; public domain. The software is in the public domain and is ...
null
https://raw.githubusercontent.com/nikodemus/SBCL/3c11847d1e12db89b24a7887b18a137c45ed4661/src/compiler/x86-64/call.lisp
lisp
function call for the x86 VM 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. interfaces to IR2 conversion location. Always wire the return PC location to the stack in its standard locati...
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") Return a wired TN describing the N'th full call argument passing (!def-vm-support-routine standard-...
5d80cbd78b571fb3f82c1756693eb5868ed4627ae6d7c5011d962a7f3f4039d5
clojure/core.typed
kw_args.clj
(ns clojure.core.typed.test.kw-args (:require [clojure.core.typed :refer [ann check-ns ann-form cf] :as t])) (ann empty-kw [& :optional {} -> nil]) (defn empty-kw [& {:as opts}] nil) (ann foo-kw [& :optional {:a Number} -> (t/U nil Number)]) (defn foo-kw [& {:keys [a]}] (when a (inc a))) (fn [] (foo-kw :a ...
null
https://raw.githubusercontent.com/clojure/core.typed/f5b7d00bbb29d09000d7fef7cca5b40416c9fa91/typed/checker.jvm/test/clojure/core/typed/test/kw_args.clj
clojure
(fn [] (foo-kw :a 'a)) [& {:a x :b [x -> t/Any]} -> t/Any])) What happens if we don't supply a :b parameter? Is `x` detected to be contravariant? It should probably be invariant keyword map is a (union of) complete hash-map(s)
(ns clojure.core.typed.test.kw-args (:require [clojure.core.typed :refer [ann check-ns ann-form cf] :as t])) (ann empty-kw [& :optional {} -> nil]) (defn empty-kw [& {:as opts}] nil) (ann foo-kw [& :optional {:a Number} -> (t/U nil Number)]) (defn foo-kw [& {:keys [a]}] (when a (inc a))) (fn [] (foo-kw :a ...
8296753f3f6cca50ec1737a6d2718aa0f566acaf21d99f35c7398d4fc7feb3a3
kkinnear/zprint
spec_test.cljc
(ns zprint.spec-test (:require [expectations.clojure.test #?(:clj :refer :cljs :refer-macros) [defexpect expect]] [zprint.spec :refer [explain-more coerce-to-boolean]] [zprint.core :refer [set-options!]] [#?(:clj clojure.spec.alpha :cljs...
null
https://raw.githubusercontent.com/kkinnear/zprint/f9031d6762e3c7dc557baadc1e9d3a842944cb8c/test/zprint/spec_test.cljc
clojure
Keep some of the test from wrapping so they still work Keep tests from configuring from any $HOME/.zprintrc or local .zprintrc # Random tests, see more systematic tests below This used to fail, but now works due to the alias capability: ## Should be an integer ## Should be a map ## Should be a boole...
(ns zprint.spec-test (:require [expectations.clojure.test #?(:clj :refer :cljs :refer-macros) [defexpect expect]] [zprint.spec :refer [explain-more coerce-to-boolean]] [zprint.core :refer [set-options!]] [#?(:clj clojure.spec.alpha :cljs...
4ec54e86274bd25e624f6cd492a35b1677fca7fa526cf76ba0d949e6dd2d0987
fukamachi/clozure-cl
l1-sort.lisp
-*-Mode : LISP ; Package : CCL -*- ;;; Copyright ( C ) 2009 Clozure Associates Copyright ( C ) 1994 - 2001 Digitool , Inc This file is part of Clozure CL . ;;; Clozure CL is licensed under the terms of the Lisp Lesser GNU Public License , known as the LLGPL and distributed with Clozure CL as the ;...
null
https://raw.githubusercontent.com/fukamachi/clozure-cl/4b0c69452386ae57b08984ed815d9b50b4bcc8a2/level-1/l1-sort.lisp
lisp
Package : CCL -*- file "LICENSE". The LLGPL consists of a preamble and the LGPL, conflict, the preamble takes precedence. Clozure CL is referenced in the preamble as the "LIBRARY." The LLGPL is also available online at modified to return a pointer to the end of the result and to n...
Copyright ( C ) 2009 Clozure Associates Copyright ( C ) 1994 - 2001 Digitool , Inc This file is part of Clozure CL . Clozure CL is licensed under the terms of the Lisp Lesser GNU Public License , known as the LLGPL and distributed with Clozure CL as the which is distributed with Clozure CL as ...
643bc1e4681cc6ed67648da838de07691ea884f79095a8d3c3f68157963ffa7b
ndmitchell/catch
Backward.hs
module Tram.Backward(backward) where import Tram.Req import Tram.Template import Tram.Propagate import Tram.Reduce import System.IO import Data.Proposition import Data.Maybe import Data.List import Control.Monad import Hill.All import Safe import qualified Data.Map as Map -- basic idea: store everything as a Map ...
null
https://raw.githubusercontent.com/ndmitchell/catch/5d834416a27b4df3f7ce7830c4757d4505aaf96e/src/Tram/Backward.hs
haskell
basic idea:
module Tram.Backward(backward) where import Tram.Req import Tram.Template import Tram.Propagate import Tram.Reduce import System.IO import Data.Proposition import Data.Maybe import Data.List import Control.Monad import Hill.All import Safe import qualified Data.Map as Map store everything as a Map , with a BDD of...
8b24685527dcbf3968584e88f2864a599b9125824d01361c51564663c5e79f10
barrucadu/irc-client
Client.hs
{-# LANGUAGE OverloadedStrings #-} -- | -- Module : Network.IRC.Client Copyright : ( c ) 2016 License : MIT Maintainer : < > -- Stability : experimental -- Portability : OverloadedStrings -- A simple IRC client library . Typical usage will be of this form : -- -- > run :: ByteString -> In...
null
https://raw.githubusercontent.com/barrucadu/irc-client/a60b35580ff9594f823b513aab8609a537285892/Network/IRC/Client.hs
haskell
# LANGUAGE OverloadedStrings # | Module : Network.IRC.Client Stability : experimental Portability : OverloadedStrings > run :: ByteString -> Int -> Text -> IO () You shouldn't really need to tweak anything other than the event handlers, as everything has been designed to be as simple as possible. * C...
Copyright : ( c ) 2016 License : MIT Maintainer : < > A simple IRC client library . Typical usage will be of this form : > run host port nick = do > let conn = plainConnection host port > let cfg = defaultInstanceConfig nick & handlers % ~ ( yourCustomEventHandlers :) > runCli...
bb770f84b2947fe1efa86eefbad7c877cff6f8b54f3d3f53891034b9b39912f7
xvw/preface
divisible.mli
* [ Divisible ] is a " Contravariant Applicative Functor " , in other word , [ Divisible ] is the dual of an { ! module : Applicative } [Divisible] is the dual of an {!module:Applicative} *) * { 2 Laws } To have a predictable behaviour , the instance of [ Divisible ] must obey some laws . ...
null
https://raw.githubusercontent.com/xvw/preface/51892a7ce2ddfef69de963265da3617968cdb7ad/lib/preface_specs/divisible.mli
ocaml
* Exposes the [divide] and [conquer] functions, mandatory for each requirement. * The type held by the [Divisible]. * The contravariant version of [apply] from [Applicative]. * Provide and empty value. * {1 Structure anatomy} * Basis operations. * Additional operations. * The type held by the [Divisible]. * ...
* [ Divisible ] is a " Contravariant Applicative Functor " , in other word , [ Divisible ] is the dual of an { ! module : Applicative } [Divisible] is the dual of an {!module:Applicative} *) * { 2 Laws } To have a predictable behaviour , the instance of [ Divisible ] must obey some laws . ...
f152bdadcde3a59a99bd89e77a324358c927a45b9e1055f29ce66fa81cddf4ff
S8A/htdp-exercises
ex258.rkt
The first three lines of this file were inserted by . They record metadata ;; about the language level of this file in a form that our tools can easily process. #reader(lib "htdp-intermediate-reader.ss" "lang")((modname ex258) (read-case-sensitive #t) (teachpacks ((lib "image.rkt" "teachpack" "2htdp") (lib "universe...
null
https://raw.githubusercontent.com/S8A/htdp-exercises/578e49834a9513f29ef81b7589b28081c5e0b69f/ex258.rkt
racket
about the language level of this file in a form that our tools can easily process. – (cons Posn Polygon) a plain background image Image Polygon -> Image adds an image of p to the background Image NELoP -> Image [X] [List-of X] -> X extracts the last item from l
The first three lines of this file were inserted by . They record metadata #reader(lib "htdp-intermediate-reader.ss" "lang")((modname ex258) (read-case-sensitive #t) (teachpacks ((lib "image.rkt" "teachpack" "2htdp") (lib "universe.rkt" "teachpack" "2htdp") (lib "batch-io.rkt" "teachpack" "2htdp") (lib "web-io.rkt" ...
225bc4d86fe78a9194e2bcb6992639d08f482e3c7c56f171de2eb66f096205f1
lindenbaum/hinterface
NodeState.hs
# LANGUAGE NamedFieldPuns # {-# LANGUAGE Strict #-} {-# OPTIONS_GHC -Wno-unrecognised-pragmas #-} {-# HLINT ignore "Use camelCase" #-} module Foreign.Erlang.NodeState ( NodeState (), logNodeState, newNodeState, new_pid, new_port, new_ref, getMailboxes, putMailboxForPid, getMailboxForP...
null
https://raw.githubusercontent.com/lindenbaum/hinterface/e49810b5984486cebad6fa06dba0f2c7f2bfd2fa/src/Foreign/Erlang/NodeState.hs
haskell
# LANGUAGE Strict # # OPTIONS_GHC -Wno-unrecognised-pragmas # # HLINT ignore "Use camelCase" # ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ serial pidId portId refId0 refId1 refId2 pid2Mbox n...
# LANGUAGE NamedFieldPuns # module Foreign.Erlang.NodeState ( NodeState (), logNodeState, newNodeState, new_pid, new_port, new_ref, getMailboxes, putMailboxForPid, getMailboxForPid, putMailboxForName, getMailboxForName, putConnectionForNode, getConnectionForNode, r...
c0c94b52288560703b46cd06441d09c5af77c332f65724dc313f0c98da61801c
softwarelanguageslab/maf
R5RS_various_grid-2.scm
; Changes: * removed : 0 * added : 0 * swaps : 0 * negated predicates : 1 ; * swapped branches: 0 ; * calls to id fun: 0 (letrec ((make-grid (lambda (start dims) (let ((v (make-vector (car dims) start))) (if (not (null? (cdr dims))) (let...
null
https://raw.githubusercontent.com/softwarelanguageslab/maf/11acedf56b9bf0c8e55ddb6aea754b6766d8bb40/test/changes/scheme/generated/R5RS_various_grid-2.scm
scheme
Changes: * swapped branches: 0 * calls to id fun: 0
* removed : 0 * added : 0 * swaps : 0 * negated predicates : 1 (letrec ((make-grid (lambda (start dims) (let ((v (make-vector (car dims) start))) (if (not (null? (cdr dims))) (letrec ((loop (lambda (i) ...
28b6bf7899af86cf9cb54bac4c51890248ad0a72aa8ea2c4d98b00dc9aafe5b6
DavidAlphaFox/RabbitMQ
mochijson.erl
@author < > @copyright 2006 Mochi Media , Inc. @doc Yet another JSON ( RFC 4627 ) library for Erlang . -module(mochijson). -author(''). -export([encoder/1, encode/1]). -export([decoder/1, decode/1]). -export([binary_encoder/1, binary_encode/1]). -export([binary_decoder/1, binary_decode/1]). % This is a macro...
null
https://raw.githubusercontent.com/DavidAlphaFox/RabbitMQ/0a64e6f0464a9a4ce85c6baa52fb1c584689f49a/plugins-src/mochiweb-wrapper/mochiweb-git/src/mochijson.erl
erlang
This is a macro to placate syntax highlighters.. @type json_string() = atom | string() | binary() @type json_number() = integer() | float() @type json_array() = {array, [json_term()]} @type json_object() = {struct, [{json_string(), json_term()}]} @type json_term() = json_string() | json_number() | json_array() | ...
@author < > @copyright 2006 Mochi Media , Inc. @doc Yet another JSON ( RFC 4627 ) library for Erlang . -module(mochijson). -author(''). -export([encoder/1, encode/1]). -export([decoder/1, decode/1]). -export([binary_encoder/1, binary_encode/1]). -export([binary_decoder/1, binary_decode/1]). -define(Q, $\"). ...
a90bdf2c6dd6da1a36b92d34791b225581b1228d17e92320d619fa8835829813
sjl/advent
day-09.lisp
(advent:defpackage* :advent/2017/09) (in-package :advent/2017/09) (define-problem (2017 9) (stream) (15922 7314) (let ((garbage-total 0)) (labels ((read-garbage-char () (if (eql #\! (peek-char nil stream)) (progn (read-char stream) (read-char stream)) ...
null
https://raw.githubusercontent.com/sjl/advent/dc3debda9bd1a0570a6ab06919b1af7b285413dc/src/2017/days/day-09.lisp
lisp
< > { }
(advent:defpackage* :advent/2017/09) (in-package :advent/2017/09) (define-problem (2017 9) (stream) (15922 7314) (let ((garbage-total 0)) (labels ((read-garbage-char () (if (eql #\! (peek-char nil stream)) (progn (read-char stream) (read-char stream)) ...
45935ad8cd6d01f7670339f5dabfba2ff0131601432b895244c83096100af906
xandkar/tiger.ml
tree_unbalanced_vanilla.ml
module List = ListLabels type ('k, 'v) t = | Node of 'k * 'v * ('k, 'v) t * ('k, 'v) t | Leaf let empty = Leaf let rec set t ~k ~v = match t with | Leaf -> Node (k, v, Leaf, Leaf) | Node (k', v', l, r) when k < k' -> Node (k', v', set l ~k ~v, r) | Node (k', v', l, r) when k > k' -> Node (k', v', l, set ...
null
https://raw.githubusercontent.com/xandkar/tiger.ml/cc540a7e2dfcee4411953075210a64de874b91e5/exercises/ch01/tree_unbalanced_vanilla.ml
ocaml
module List = ListLabels type ('k, 'v) t = | Node of 'k * 'v * ('k, 'v) t * ('k, 'v) t | Leaf let empty = Leaf let rec set t ~k ~v = match t with | Leaf -> Node (k, v, Leaf, Leaf) | Node (k', v', l, r) when k < k' -> Node (k', v', set l ~k ~v, r) | Node (k', v', l, r) when k > k' -> Node (k', v', l, set ...
c4fd35980fd4d4b584bd885ae439c01be722c7bc6b3c0c0db7cbea7fa83e43cd
GaloisInc/daedalus
Extract.hs
# Language ScopedTypeVariables , FlexibleInstances , MultiParamTypeClasses # module Daedalus.Value.Extract ( Value(..) , FromValue(..) ) where import qualified Data.Text as Text import GHC.OverloadedLabels(IsLabel(..)) import GHC.TypeLits(symbolVal,KnownSymbol) import Data.Proxy(Proxy(..)) import Data.Vector(Vec...
null
https://raw.githubusercontent.com/GaloisInc/daedalus/ca8b2309751a1ca6ad4f92139f02eb60aa2759c6/daedalus-value/src/Daedalus/Value/Extract.hs
haskell
# Language ScopedTypeVariables , FlexibleInstances , MultiParamTypeClasses # module Daedalus.Value.Extract ( Value(..) , FromValue(..) ) where import qualified Data.Text as Text import GHC.OverloadedLabels(IsLabel(..)) import GHC.TypeLits(symbolVal,KnownSymbol) import Data.Proxy(Proxy(..)) import Data.Vector(Vec...
fad59f5a54167ebea31282356ceecfd5eb0de27ab97a53ce8da763fe4f6df043
evincarofautumn/kitten
Substitute.hs
| Module : Kitten . Substitute Description : Substituting type variables Copyright : ( c ) , 2016 License : MIT Maintainer : Stability : experimental Portability : GHC Module : Kitten.Substitute Description : Substituting type variables Copyright : (c) Jon Purdy, 2016 Licens...
null
https://raw.githubusercontent.com/evincarofautumn/kitten/a5301fe24dbb9ea91974abee73ad544156ee4722/lib/Kitten/Substitute.hs
haskell
| Capture-avoiding substitution of a type variable α with a type τ throughout a type σ, [α ↦ τ]σ. FIXME: Generics could eventually quantify over non-value kinds.
| Module : Kitten . Substitute Description : Substituting type variables Copyright : ( c ) , 2016 License : MIT Maintainer : Stability : experimental Portability : GHC Module : Kitten.Substitute Description : Substituting type variables Copyright : (c) Jon Purdy, 2016 Licens...
fcf7eb0054530bda137cb5b5863120f3b266897a157573f8e0e80a11b6d33c84
nasa/Common-Metadata-Repository
dev.clj
(ns cmr.plugin.jar.dev "CMR JAR-Plugin development namespace." (:require [clojure.java.classpath :as classpath] [clojure.java.io :as io] [clojure.pprint :refer [pprint]] [clojure.string :as string] [clojure.tools.namespace.repl :as repl] [clojusc.system-manager.core :as system-api :refer :all] ...
null
https://raw.githubusercontent.com/nasa/Common-Metadata-Repository/63001cf021d32d61030b1dcadd8b253e4a221662/other/cmr-exchange/jar-plugin-lib/dev-resources/src/cmr/plugin/jar/dev.clj
clojure
Initial Setup & Utility Functions ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; It is not always desired that a system be started up upon REPL loading. Thus, we set the options and perform any global operations with init, and let the user determine when then want to bring up (a potentially computationally intensive) s...
(ns cmr.plugin.jar.dev "CMR JAR-Plugin development namespace." (:require [clojure.java.classpath :as classpath] [clojure.java.io :as io] [clojure.pprint :refer [pprint]] [clojure.string :as string] [clojure.tools.namespace.repl :as repl] [clojusc.system-manager.core :as system-api :refer :all] ...
6884b54a9555af909dca7a4785e1fb1c3fc1c5cc7d2d2328389b82e6d98df1df
lucasdicioccio/prodapi
Reports.hs
# LANGUAGE KindSignatures # module Prod.Reports ( ReportsApi, Report(..), countReports, Runtime, initRuntime, ) where import Control.Monad.IO.Class (liftIO) import Data.Aeson ((.:), (.=), FromJSON (..), withObject, ToJSON(..), object) import GHC.TypeLits (Symbol) import qualified Prometheus as Pro...
null
https://raw.githubusercontent.com/lucasdicioccio/prodapi/4c43e1d617832f8ae88cb15afada1d5ab5e46ea4/prodapi/src/Prod/Reports.hs
haskell
| Some minimal report wrapper. Has low expectations on the client. | A set of counters tracking . | A default runtime for the `dropReports` route. | Count and drop reports.
# LANGUAGE KindSignatures # module Prod.Reports ( ReportsApi, Report(..), countReports, Runtime, initRuntime, ) where import Control.Monad.IO.Class (liftIO) import Data.Aeson ((.:), (.=), FromJSON (..), withObject, ToJSON(..), object) import GHC.TypeLits (Symbol) import qualified Prometheus as Pro...
9c6299308db648cb120c34e9db5ff41a13068d069aac6798c73aa1f308512eec
uncomplicate/commons
core_test.clj
Copyright ( c ) . All rights reserved . ;; The use and distribution terms for this software are covered by the ;; Eclipse Public License 1.0 (-1.0.php) or later ;; which can be found in the file LICENSE at the root of this distribution. ;; By using this software in any fashion, you are agreeing to be boun...
null
https://raw.githubusercontent.com/uncomplicate/commons/027697a454281e18c1c2f7d3875e4439034caa14/test/uncomplicate/commons/core_test.clj
clojure
The use and distribution terms for this software are covered by the Eclipse Public License 1.0 (-1.0.php) or later which can be found in the file LICENSE at the root of this distribution. By using this software in any fashion, you are agreeing to be bound by the terms of this license. You must not rem...
Copyright ( c ) . All rights reserved . (ns uncomplicate.commons.core-test (:require [clojure.set :refer [superset?]] [uncomplicate.commons.core :refer :all] [midje.sweet :refer [facts]]) (:import [clojure.lang IFn IFn$D IFn$DD IFn$DDD IFn$DDDD IFn$DDDDD IFn$L IFn$LL IFn$L...
558e35b459bc3a21852734e6d7a994aae1e465f9bc64a2b6acdcfb04e0cab536
ekmett/representable-tries
Zeroless.hs
# LANGUAGE TypeFamilies , Rank2Types , TypeOperators , GADTs , EmptyDataDecls , FlexibleInstances , FlexibleContexts , UndecidableInstances # ---------------------------------------------------------------------- -- | -- Module : Data.Vector.Zeroless Copyright : ( c ) 2011 -- License : BSD3 -- --...
null
https://raw.githubusercontent.com/ekmett/representable-tries/1f935ca273daa48a91b928692f3ef63858a0e486/src/Data/Vector/Zeroless.hs
haskell
-------------------------------------------------------------------- | Module : Data.Vector.Zeroless License : BSD3 Maintainer : Stability : experimental Fixed-length Vectors with zeroless binary indexing -------------------------------------------------------------------- each vector memoiz...
# LANGUAGE TypeFamilies , Rank2Types , TypeOperators , GADTs , EmptyDataDecls , FlexibleInstances , FlexibleContexts , UndecidableInstances # Copyright : ( c ) 2011 module Data.Vector.Zeroless ( Vector , (<|) , NonEmpty(tail,head,uncons) , size ) where import Control.Arrow import Control.Applic...
fc16ca33229faa1ac86fb3ab26d74e330c44e4fd133909f44b6740890382ba84
blockmason/lndr
Admin.hs
{-# LANGUAGE OverloadedStrings #-} module Lndr.Handler.Admin where import Control.Concurrent.STM import Control.Monad.Reader import Data.List ((\\), find) import Data.Pool (withResource) import Data.Text (Text) import qualified Lndr.Db as Db import Lndr.Ha...
null
https://raw.githubusercontent.com/blockmason/lndr/58fe5f82d5d057e463be23821454e3a0515ef9b9/lndr-backend/src/Lndr/Handler/Admin.hs
haskell
# LANGUAGE OverloadedStrings #
module Lndr.Handler.Admin where import Control.Concurrent.STM import Control.Monad.Reader import Data.List ((\\), find) import Data.Pool (withResource) import Data.Text (Text) import qualified Lndr.Db as Db import Lndr.Handler.Types import Lndr.Eth...
fda545715e54092eb536bcc6ec277acc0d5bc973b30ba4ddfe5c3410ecbf476c
racket/gui
search.rkt
#lang racket/base (require (for-syntax racket/base) "test-suite-utils.rkt") (module test racket/base) (define-syntax (test-search stx) (syntax-case stx () [(_ args ...) (with-syntax ([line (syntax-line stx)]) #'(test-search/proc line args ...))])) ;; creates a search text, binds it to 't' ...
null
https://raw.githubusercontent.com/racket/gui/d1fef7a43a482c0fdd5672be9a6e713f16d8be5c/gui-test/framework/tests/search.rkt
racket
creates a search text, binds it to 't' and then, for each expression in 'commands', evaluates it in a let binding 't'. In between each call to commands, it waits for the search text to quiesce and then finally gets the search bubbles, comparing them to 'bubble-table' (printf "running test on line ~s\n" line)
#lang racket/base (require (for-syntax racket/base) "test-suite-utils.rkt") (module test racket/base) (define-syntax (test-search stx) (syntax-case stx () [(_ args ...) (with-syntax ([line (syntax-line stx)]) #'(test-search/proc line args ...))])) (define (test-search/proc line commands bu...
e0e84358ddd61dc11568a5b9e129676abd8bf878162d286d00598b1f1c63618b
composewell/streamly
Lifted.hs
-- | Module : Streamly . Internal . Data . IOFinalizer . Lifted Copyright : ( c ) 2020 Composewell Technologies and Contributors -- License : BSD-3-Clause -- Maintainer : -- Stability : experimental Portability : GHC -- -- A value associated with an IO action that is automatically called whenever...
null
https://raw.githubusercontent.com/composewell/streamly/135c55e669de640731c6495996403077e6808ec8/src/Streamly/Internal/Data/IOFinalizer/Lifted.hs
haskell
| License : BSD-3-Clause Maintainer : Stability : experimental A value associated with an IO action that is automatically called whenever the value is garbage collected. | Create a finalizer that calls the supplied function automatically when the it is garbage collected. /The finalizer is always run ...
Module : Streamly . Internal . Data . IOFinalizer . Lifted Copyright : ( c ) 2020 Composewell Technologies and Contributors Portability : GHC module Streamly.Internal.Data.IOFinalizer.Lifted ( IOFinalizer , newIOFinalizer , runIOFinalizer , clearingIOFinalizer ) where import C...
6818fc5c066081f62ec33bf87527db13f1090785c840cea1b5a9e950ddba2a5c
NoRedInk/haskell-libraries
Dict.hs
-- | A dictionary mapping unique keys to values. The keys can be any comparable type . This includes @Int@ , , @Time@ , @Char@ , @String@ , and tuples or -- lists of comparable types. -- Insert , remove , and query operations all take /O(log n)/ time . module Dict ( -- * Dictionaries Dict, -- * Build ...
null
https://raw.githubusercontent.com/NoRedInk/haskell-libraries/7af1e05549e09d519b08ab49dff956b5a97d4f7e/nri-prelude/src/Dict.hs
haskell
| A dictionary mapping unique keys to values. The keys can be any comparable lists of comparable types. * Dictionaries * Build * Query * Lists * Transform * Combine DICTIONARIES | A dictionary of keys and values. So a @Dict String User@ is a dictionary that lets you look up a @String@ (such as user names) a...
type . This includes @Int@ , , @Time@ , @Char@ , @String@ , and tuples or Insert , remove , and query operations all take /O(log n)/ time . module Dict Dict, empty, singleton, insert, update, remove, isEmpty, member, get, size, keys, values, toList, fromLi...
d2bffacf4b7e09f5cacde4af8a743a9fffb8b1c2e30d9b15aafc79c6e9264216
larcenists/larceny
simple-macros-tests.scm
;;;=========================================================== ;;; Portable Hygienic Macros : Examples and Tests ;;; ;;; ;;;=========================================================== (load "simple-macros.scm") (repl ' ( (import (for "scheme" all)) ;;========================================...
null
https://raw.githubusercontent.com/larcenists/larceny/fef550c7d3923deb7a5a1ccd5a628e54cf231c75/src/Lib/Common/SimpleMacros/simple-macros-tests.scm
scheme
=========================================================== =========================================================== ========================================================================= Introductory examples: ========================================================================= Simplified COND: ==> u...
Portable Hygienic Macros : Examples and Tests (load "simple-macros.scm") (repl ' ( (import (for "scheme" all)) (define-syntax (swap! a b) (quasisyntax (let ((temp ,a)) (set! ,a ,b) (set! ,b temp)))) (let ((temp 1) (set! 2)) (swap! set! temp) = = > ...
6c69c17903516042495c36d588ef684835ec87716c2d6acf40a41c869f40bded
casperschipper/ocaml-cisp
cisp2.ml
open Cisp let sr = ref 44100.0 let sec s = !sr *. s (* (float -> float) -> seq.t float -> seq.t float *) (* frequency is the thing *) let phase_inc = (1.0 /. !sr) *. Float.pi *. 2.0 * recursive @control : the control stream , that allows us to customize the update @init : the initial state ( can be any...
null
https://raw.githubusercontent.com/casperschipper/ocaml-cisp/571ffb8e508c5427d01e407ba5e91ff2a4604f40/examples/cisp_backup/delaySynthBatch1/cisp2.ml
ocaml
(float -> float) -> seq.t float -> seq.t float frequency is the thing
open Cisp let sr = ref 44100.0 let sec s = !sr *. s let phase_inc = (1.0 /. !sr) *. Float.pi *. 2.0 * recursive @control : the control stream , that allows us to customize the update @init : the initial state ( can be anything ! ) @update : takes a state and one value of control then produces a new s...
70cb617b722dd72b9df4587e294e4dec28af087afaa78349e4ea272e1e9585b6
xsc/claro
blocking_composition.cljc
(ns claro.data.tree.blocking-composition (:require [claro.data.protocols :as p] [claro.data.error :refer [error?]]) (:import [claro.data.protocols ResolvableTree ])) (deftype BlockingComposition [tree f] ResolvableTree (wrapped? [this] true) (processable? [this] false) (unwrap-tree [thi...
null
https://raw.githubusercontent.com/xsc/claro/16db75b7a775a14f3b656362e8ee4f65dd8b0d49/src/claro/data/tree/blocking_composition.cljc
clojure
(ns claro.data.tree.blocking-composition (:require [claro.data.protocols :as p] [claro.data.error :refer [error?]]) (:import [claro.data.protocols ResolvableTree ])) (deftype BlockingComposition [tree f] ResolvableTree (wrapped? [this] true) (processable? [this] false) (unwrap-tree [thi...
b5eb4d7f12c3142d10156b7133170171c9bce83e8538381ddcec755198d1b623
rd--/hsc3
dseq.help.hs
-- dseq ; at control rate let n = dseqId 'α' 3 (mce [1,3,2,7,8]) x = mouseX kr 1 40 Exponential 0.1 t = impulse kr x 0 f = demand t 0 n * 30 + 340 in sinOsc ar f 0 * 0.1 -- dseq ; at audio rate let n = dseqId 'α' dinf (mce [1,3,2,7,8,32,16,18,12,24]) x = mouseX kr 1 10000 Exponential 0.1 t = impuls...
null
https://raw.githubusercontent.com/rd--/hsc3/60cb422f0e2049f00b7e15076b2667b85ad8f638/Help/Ugen/dseq.help.hs
haskell
dseq ; at control rate dseq ; at audio rate -- ; drawings
let n = dseqId 'α' 3 (mce [1,3,2,7,8]) x = mouseX kr 1 40 Exponential 0.1 t = impulse kr x 0 f = demand t 0 n * 30 + 340 in sinOsc ar f 0 * 0.1 let n = dseqId 'α' dinf (mce [1,3,2,7,8,32,16,18,12,24]) x = mouseX kr 1 10000 Exponential 0.1 t = impulse ar x 0 f = demand t 0 n * 30 + 340 in sinOsc...
2286868bdd538597b102ca7b04f67fa699fe482a2c60198b7c9c84ee723adc0e
LCBH/UKano
pitransl.ml
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * UKano : UnlinKability and ANOnymity verifier * * * ...
null
https://raw.githubusercontent.com/LCBH/UKano/13c046ddaca48b45d3652c3ea08e21599e051527/src/pitransl.ml
ocaml
For key compromise For non-interference Returns true when event f is present in the process. Raises an error when event f is present several times in the same then/else branch, so that it could be executed several times with the same session identifiers Compute in accu the list of events that are inject...
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * UKano : UnlinKability and ANOnymity verifier * * * ...
64f585a142d120e4d758a212813044599480095fa4e4558efcd06e776591033b
BillHallahan/G2
Test1.hs
{-@ LIQUID "--short-names" @-} {-@ LIQUID "--no-termination" @-} {-@ LIQUID "--prune-unsorted" @-} module Combined () where import qualified Data.Map as M data D a = Emp | R a deriving (Eq, Ord, Show) {-@ f :: D Int -> M.Map {v:Int | 0 <= v } Int @-} f :: D Int -> M.Map Int Int f xs = M.map (\x ->...
null
https://raw.githubusercontent.com/BillHallahan/G2/4d287df8ed7ba13c06d96d4911b9eedf870e80a1/tests/LiquidInf/Artificial/Neg/Test1.hs
haskell
@ LIQUID "--short-names" @ @ LIQUID "--no-termination" @ @ LIQUID "--prune-unsorted" @ @ f :: D Int -> M.Map {v:Int | 0 <= v } Int @
module Combined () where import qualified Data.Map as M data D a = Emp | R a deriving (Eq, Ord, Show) f :: D Int -> M.Map Int Int f xs = M.map (\x -> 1) (g h M.empty xs) g :: (a -> b -> b) -> b -> D a -> b g _ b Emp = b g op b (R x) = x `op` b h k m = M.insert k (R 1) m
d94603731ad8395f94c6360fececaa11520c7e201ddfb01e8233ae718d1c3a9f
hiroshi-unno/coar
a-copy-print.ml
(* USED: PLDI2011 as a-cppr USED: PEPM2013 as a-cppr *) (* modified *) let make_array n i = assert (0 <= i && i < n); 0 let a i des x (j:int) : int = if i=j then x else des i let update (i:int) (n:int) des x : int -> int = des i; a i des x let print_int (n:int) = () let rec bcopy (m:int) src des i = if i >= m th...
null
https://raw.githubusercontent.com/hiroshi-unno/coar/90a23a09332c68f380efd4115b3f6fdc825f413d/benchmarks/OCaml/safety/tacas2015/a-copy-print.ml
ocaml
USED: PLDI2011 as a-cppr USED: PEPM2013 as a-cppr modified * (* original
let make_array n i = assert (0 <= i && i < n); 0 let a i des x (j:int) : int = if i=j then x else des i let update (i:int) (n:int) des x : int -> int = des i; a i des x let print_int (n:int) = () let rec bcopy (m:int) src des i = if i >= m then des else let des = update i m des (src i) in bcopy m s...
cf848d16e315b4a878af6ca17a4984adfe3016b55c5c24c6be82157ed01ec80c
plumatic/grab-bag
models.clj
(ns model-explorer.models (:use plumbing.core) (:require [schema.core :as s] [plumbing.graph :as graph] [plumbing.hash :as hash] [plumbing.index :as index] [plumbing.parallel :as parallel] flop.weight-vector [classify.classify :as classify] [classify.learn :as learn] [store.bucket :as buc...
null
https://raw.githubusercontent.com/plumatic/grab-bag/a15e943322fbbf6f00790ce5614ba6f90de1a9b5/service/model-explorer/src/model_explorer/models.clj
clojure
:train-evaluation :evaluation :model :final-train-evaluation :auto-tags
(ns model-explorer.models (:use plumbing.core) (:require [schema.core :as s] [plumbing.graph :as graph] [plumbing.hash :as hash] [plumbing.index :as index] [plumbing.parallel :as parallel] flop.weight-vector [classify.classify :as classify] [classify.learn :as learn] [store.bucket :as buc...
860ac4e79279ae5cb980db8d7f5e737a169a60d02199c65755aa7a9a8b074b31
sellout/haskerwaul
Bounded.hs
# language UndecidableInstances , UndecidableSuperClasses # , UndecidableSuperClasses #-} module Haskerwaul.Lattice.Bounded ( module Haskerwaul.Lattice.Bounded -- * extended modules , module Haskerwaul.Lattice , module Haskerwaul.Semilattice.Bounded ) where import Data.Prox...
null
https://raw.githubusercontent.com/sellout/haskerwaul/cf54bd7ce5bf4f3d1fd0d9d991dc733785b66a73/src/Haskerwaul/Lattice/Bounded.hs
haskell
* extended modules | [nLab](#bounded_lattices_and_pseudolattices) __NB__: Instances for this are automatically coalesced.
# language UndecidableInstances , UndecidableSuperClasses # , UndecidableSuperClasses #-} module Haskerwaul.Lattice.Bounded ( module Haskerwaul.Lattice.Bounded , module Haskerwaul.Lattice , module Haskerwaul.Semilattice.Bounded ) where import Data.Proxy (Proxy) import Hasker...
4be97cc75b32cc321944806952a2eb3a1c8466ca5a3508cdcbf36cb06e3b80e8
gerlion/secure-e-voting-with-coq
lib.ml
type __ = Obj.t let __ = let rec f _ = Obj.repr f in Obj.repr f * negb : bool - > bool * let negb = function | true -> false | false -> true type nat = | O | S of nat (** val fst : ('a1 * 'a2) -> 'a1 **) let fst = function | (x, _) -> x * snd : ( ' a1 * ' a2 ) - > ' a2 * let snd = function | (_, y) -> y type...
null
https://raw.githubusercontent.com/gerlion/secure-e-voting-with-coq/c85f58f5759b960cc9d90a96fe7970e038523a9a/OCamlVerificatum/lib.ml
ocaml
* val fst : ('a1 * 'a2) -> 'a1 * singleton inductive, whose constructor was exist * val pred : nat -> nat * * val succ_double_mask : mask -> mask * * val sub_mask_carry : Big.big_int -> Big.big_int -> mask * * val compare_cont : comparison -> Big.big_int -> Big.big_int -> comparison * * val compare : Big.big_in...
type __ = Obj.t let __ = let rec f _ = Obj.repr f in Obj.repr f * negb : bool - > bool * let negb = function | true -> false | false -> true type nat = | O | S of nat let fst = function | (x, _) -> x * snd : ( ' a1 * ' a2 ) - > ' a2 * let snd = function | (_, y) -> y type comparison = | Eq | Lt | Gt type 'a...
9748f51277f6871af85ed42642853c0c5d646bb900ca8b2ab5aa15ea144c3e5d
dongcarl/guix
maven.scm
;;; GNU Guix --- Functional package management for GNU Copyright © 2020 < > ;;; ;;; This file is part of GNU Guix. ;;; GNU 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 Lice...
null
https://raw.githubusercontent.com/dongcarl/guix/82543e9649da2da9a5285ede4ec4f718fd740fcb/guix/build-system/maven.scm
scheme
GNU Guix --- Functional package management for GNU 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 WARRANTY; without even the implied wa...
Copyright © 2020 < > under the terms of the GNU General Public License as published by You should have received a copy of the GNU General Public License along with GNU . If not , see < / > . (define-module (guix build-system maven) #:use-module (guix store) #:use-module (guix utils) #:use-module (g...
e6ecb4924ca790ba7a6156b04c8ac6e3732270d657234dfef754090abd789c15
msakai/toysolver
htc.hs
# LANGUAGE CPP # # LANGUAGE ScopedTypeVariables # # OPTIONS_GHC -Wall # module Main where import Control.Monad import Data.Char import Data.List import qualified Data.IntSet as IntSet import qualified Data.Set as Set import System.Environment import System.Exit import System.IO import qualified ToySolver.Combinatorial...
null
https://raw.githubusercontent.com/msakai/toysolver/6233d130d3dcea32fa34c26feebd151f546dea85/samples/programs/htc/htc.hs
haskell
# LANGUAGE CPP # # LANGUAGE ScopedTypeVariables # # OPTIONS_GHC -Wall # module Main where import Control.Monad import Data.Char import Data.List import qualified Data.IntSet as IntSet import qualified Data.Set as Set import System.Environment import System.Exit import System.IO import qualified ToySolver.Combinatorial...
5bd4ecaf4303191dc5dee14c10ca5309132924faac50d1350e7f770052f58902
BillHallahan/G2
CoinductionIncorrect.hs
{-# LANGUAGE BangPatterns #-} module CoinductionIncorrect where import Data.List cons :: t -> [t] -> [t] cons n (!l) = n:l intForce :: [Int] -> [Int] intForce [] = [] intForce (h:t) = cons h $ intForce t maybeForce :: Maybe t -> Maybe t maybeForce !Nothing = Nothing maybeForce !(Just !x) = Just x intDrop :: Int -...
null
https://raw.githubusercontent.com/BillHallahan/G2/a65e0071c66c56ef531b1e90596acdcb8e819320/tests/RewriteVerify/Incorrect/CoinductionIncorrect.hs
haskell
# LANGUAGE BangPatterns # some of these rules are incorrect only because of laziness
module CoinductionIncorrect where import Data.List cons :: t -> [t] -> [t] cons n (!l) = n:l intForce :: [Int] -> [Int] intForce [] = [] intForce (h:t) = cons h $ intForce t maybeForce :: Maybe t -> Maybe t maybeForce !Nothing = Nothing maybeForce !(Just !x) = Just x intDrop :: Int -> [Int] -> [Int] intDrop 0 l =...
4fbc2b489493a23004b5bc21c7f6f9d3338fdb737dacd89228623b948e7ad1a4
haskell-CI/haskell-ci
Jobs.hs
# LANGUAGE RecordWildCards # -- | Which jobs to generate. Also helper for diagnostics output. module HaskellCI.Jobs ( JobVersions (..), describeJobs, makeJobVersions, ) where import HaskellCI.Prelude import qualified Data.Set as S import HaskellCI.Compiler import HaskellCI.Config import HaskellCI.Diagnos...
null
https://raw.githubusercontent.com/haskell-CI/haskell-ci/950186dd246d810bf59f4da06dbcb60a4fd6a82e/src/HaskellCI/Jobs.hs
haskell
| Which jobs to generate. Also helper for diagnostics output. ^ linux jobs ^ macos jobs ^ config All jobs -04-28-tabular.html
# LANGUAGE RecordWildCards # module HaskellCI.Jobs ( JobVersions (..), describeJobs, makeJobVersions, ) where import HaskellCI.Prelude import qualified Data.Set as S import HaskellCI.Compiler import HaskellCI.Config import HaskellCI.Diagnostics import HaskellCI.Package import HaskellCI.TestedWith data J...
edd92f2034cb679babb38aa7c6b1c9457e6f26dc4c0839402531f44ac3d96357
Kappa-Dev/KappaTools
odes.mli
* Network / ODE generation * Creation : 15/07/2016 * Last modification : Time - stamp : < Dec 19 2018 > * Creation: 15/07/2016 * Last modification: Time-stamp: <Dec 19 2018> *) module Make(I:Symmetry_interface_sig.Interface) : sig type ode_var_id type ('a,'b) network type enriched_rule type rule_i...
null
https://raw.githubusercontent.com/Kappa-Dev/KappaTools/eef2337e8688018eda47ccc838aea809cae68de7/core/odes/odes.mli
ocaml
rules
* Network / ODE generation * Creation : 15/07/2016 * Last modification : Time - stamp : < Dec 19 2018 > * Creation: 15/07/2016 * Last modification: Time-stamp: <Dec 19 2018> *) module Make(I:Symmetry_interface_sig.Interface) : sig type ode_var_id type ('a,'b) network type enriched_rule type rule_i...
390a9ab5e96669854a71d7d3ad72b1ba46eb9fd2110cfde3cb52f7f3d68c3d7d
siilisolutions/hedge
cloudformation_api.clj
(ns boot-hedge.aws.cloudformation-api (:require [boot-hedge.common.core :refer [now]] [camel-snake-kebab.core :refer [->camelCaseString ->PascalCase]]) (:import [com.amazonaws.services.cloudformation AmazonCloudFormationClientBuilder] [com.amazonaws.regions Regions] [com.amazonaws....
null
https://raw.githubusercontent.com/siilisolutions/hedge/c856b232f3057530921a1e186371647317819f16/boot/src/boot_hedge/aws/cloudformation_api.clj
clojure
this should be autogenerated API endpoint communication logic TODO: simplify this?
(ns boot-hedge.aws.cloudformation-api (:require [boot-hedge.common.core :refer [now]] [camel-snake-kebab.core :refer [->camelCaseString ->PascalCase]]) (:import [com.amazonaws.services.cloudformation AmazonCloudFormationClientBuilder] [com.amazonaws.regions Regions] [com.amazonaws....