_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
3a2024604a57f1ab55bd30e64c29cc1bd899af34f67da29b3a588072c68803ae
Opetushallitus/ataru
field_visibility.cljs
(ns ataru.hakija.application.field-visibility (:require [clojure.set :as set] [clojure.string :as string] [ataru.application.option-visibility :as option-visibility] [ataru.util :as u])) (defn- ylioppilastutkinto? [db] (boolean (some #(or (= "pohjakoulutus_yo" %) ...
null
https://raw.githubusercontent.com/Opetushallitus/ataru/ff720c87ecb337f08daf12acedb8cbc2c9329bb6/src/cljs/ataru/hakija/application/field_visibility.cljs
clojure
(ns ataru.hakija.application.field-visibility (:require [clojure.set :as set] [clojure.string :as string] [ataru.application.option-visibility :as option-visibility] [ataru.util :as u])) (defn- ylioppilastutkinto? [db] (boolean (some #(or (= "pohjakoulutus_yo" %) ...
da28d8ad3abd4bacee95c0f255771ed6cc9ac06e46ba9bbbc7f857795cf14899
reborg/clojure-essential-reference
1.clj
< 1 > (ns-name (.ns #'a)) ;; user (ns ns1) < 2 > (ns-name (.ns #'b)) ;; ns1
null
https://raw.githubusercontent.com/reborg/clojure-essential-reference/c37fa19d45dd52b2995a191e3e96f0ebdc3f6d69/VarsandNamespaces/ns%2Cin-ns%2Ccreate-nsandremove-ns/1.clj
clojure
user ns1
< 1 > (ns-name (.ns #'a)) (ns ns1) < 2 > (ns-name (.ns #'b))
b2ec4bd1f7e69c84ccabf7bdbbbd8bb2d8fc9111b372a741b366c8c5d953c6a4
ml4tp/tcoq
ocaml.ml
(************************************************************************) v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2017 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *...
null
https://raw.githubusercontent.com/ml4tp/tcoq/7a78c31df480fba721648f277ab0783229c8bece/plugins/extraction/ocaml.ml
ocaml
********************************************************************** // * This file is distributed under the terms of the * GNU Lesser General Public License Version 2.1 ********************************************************************** s Production of Ocaml syntax. s Som...
v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2017 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * open Pp open CErrors open Ut...
e881bdc4db6669c5f276766b9c339b4ec505ef87def3a2c05eb9994b61aa65e8
michaelmelanson/erlyweb
customer.erl
-module(customer). -compile(export_all). relations() -> [{many_to_many, [customer]}].
null
https://raw.githubusercontent.com/michaelmelanson/erlyweb/997df18b70459bfaaf8c3ab70ab4f54907045d0f/test/erlydb/customer.erl
erlang
-module(customer). -compile(export_all). relations() -> [{many_to_many, [customer]}].
d417617bda9a1bf6a043d499d358727a2306c3325b541cef27d18d1d761ffd3c
nwtgck/platy-lang-haskell
SemanticCheckSpec.hs
# LANGUAGE NamedFieldPuns # # LANGUAGE DuplicateRecordFields # # LANGUAGE QuasiQuotes # module Platy.SemanticCheckSpec where import Test.Hspec import Test.Hspec.QuickCheck import Test.QuickCheck import qualified Data.String.Here as Here import qualified Data.ByteString.Char8 as BS impo...
null
https://raw.githubusercontent.com/nwtgck/platy-lang-haskell/a8f84ab65207161b0cebd8378eb62863202723f9/test/Platy/SemanticCheckSpec.hs
haskell
# LANGUAGE NamedFieldPuns # # LANGUAGE DuplicateRecordFields # # LANGUAGE QuasiQuotes # module Platy.SemanticCheckSpec where import Test.Hspec import Test.Hspec.QuickCheck import Test.QuickCheck import qualified Data.String.Here as Here import qualified Data.ByteString.Char8 as BS impo...
2369f22c30983402851737e4b2252140c1ba388761fa9f90e54f305f88fc3a3c
vlaaad/reveal
prefs.clj
(ns vlaaad.reveal.prefs (:require [clojure.spec.alpha :as s] [clojure.edn :as edn] [clojure.main :as m]) (:import [java.net URL MalformedURLException] [javafx.scene.text Font])) (s/def ::font-size (s/and number? pos?)) (defn- valid-url? [s] (try (URL. s) true (catch ...
null
https://raw.githubusercontent.com/vlaaad/reveal/61c157b557c767aa34feb29e1e1aea197b1eed08/src/vlaaad/reveal/prefs.clj
clojure
(ns vlaaad.reveal.prefs (:require [clojure.spec.alpha :as s] [clojure.edn :as edn] [clojure.main :as m]) (:import [java.net URL MalformedURLException] [javafx.scene.text Font])) (s/def ::font-size (s/and number? pos?)) (defn- valid-url? [s] (try (URL. s) true (catch ...
57a9682a449020ea47f1b086b0f7b535d9638fd01294a30e8b086dcc56ad5be3
andrewthad/haskell-ip
IPv6.hs
{-# LANGUAGE BangPatterns #-} # LANGUAGE CPP # # LANGUAGE DataKinds # {-# LANGUAGE DeriveDataTypeable #-} # LANGUAGE DeriveGeneric # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE InstanceSigs # # LANGUAGE LambdaCase # # LANGUAGE MagicHash # # LANGUAGE ScopedTypeVariables # {-# LANGUAGE TypeInType #-} # LANGUAGE Un...
null
https://raw.githubusercontent.com/andrewthad/haskell-ip/3c6528a73660140c1c9b50914803ba54f12fbcd9/src/Net/IPv6.hs
haskell
# LANGUAGE BangPatterns # # LANGUAGE DeriveDataTypeable # # LANGUAGE TypeInType # | This module provides the IPv6 data type and functions for working with it. * Convert * Special IP Addresses * Textual Conversion ** Text * UTF-8 Bytes ** Printing * IPv6 Ranges ** Range functions ** Textual Conversion ***...
# LANGUAGE CPP # # LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE InstanceSigs # # LANGUAGE LambdaCase # # LANGUAGE MagicHash # # LANGUAGE ScopedTypeVariables # # LANGUAGE UnboxedTuples # module Net.IPv6 ipv6 , fromOctets , fromWord16s , fromWord32s , fro...
6ba982acce4f2b91e9ed146edbd5671c22d7f5329459368d48423a7244275975
franzinc/clim2
graphics.lisp
-*- Mode : Lisp ; Syntax : ANSI - Common - Lisp ; Package : SILICA ; Base : 10 ; Lowercase : Yes -*- ;; See the file LICENSE for the full license governing this code. ;; (in-package :silica) " Copyright ( c ) 1990 , 1991 , 1992 Symbolics , Inc. All rights reserved . Portions copyright ( c ) 1991 , 1992 Franz , ...
null
https://raw.githubusercontent.com/franzinc/clim2/e8d03da80e1f000be40c37d088e283d95365bfdd/silica/graphics.lisp
lisp
Syntax : ANSI - Common - Lisp ; Package : SILICA ; Base : 10 ; Lowercase : Yes -*- See the file LICENSE for the full license governing this code. NOTE: if you change this list of keywords, you also have to change the keyword arguments accepted by (CLOS:METHOD INVOKE-WITH-DRAWING-OPTIONS (DRAWING-STATE-MIXIN T)) I...
(in-package :silica) " Copyright ( c ) 1990 , 1991 , 1992 Symbolics , Inc. All rights reserved . Portions copyright ( c ) 1991 , 1992 Franz , Inc. All rights reserved . " (eval-when (compile load eval) (defparameter *all-drawing-options* '(:ink :clipping-region :transformation :...
88d81caad5e2bc79291c9fcf6e86a00724e2ebca0e259e9c20087822d6708fb5
melange-re/melange
hashtbl.ml
(**************************************************************************) (* *) (* OCaml *) (* *) ...
null
https://raw.githubusercontent.com/melange-re/melange/246e6df78fe3b6cc124cb48e5a37fdffd99379ed/jscomp/stdlib-412/stdlib_modules/hashtbl.ml
ocaml
************************************************************************ OCaml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et the GNU Lesser General Public License version 2.1 , with the type ('a, 'b) t = } and ('a, 'b) bucketlist = Empty | Cons of { mutable key: 'a; ...
0ad1e0d8004214d3dc8f4888d0824d4d7467dfeb01e89c657d9606320b7737cc
aharisu/Gauche-SDL
collide_type.scm
;;; collide_type.scm ;;; MIT License Copyright 2011 - 2012 aharisu ;;; All rights reserved. ;;; ;;; 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 witho...
null
https://raw.githubusercontent.com/aharisu/Gauche-SDL/29e997dacdb7c6b89e99843f0f0c52266abfee66/src/collide/collide_type.scm
scheme
All rights reserved. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal to use, copy, modify, merge, publish, distribute, sublicense, and/or sell furnished to do so, subject to the following conditions: The...
collide_type.scm MIT License Copyright 2011 - 2012 aharisu in the Software without restriction , including without limitation the rights copies of the Software , and to permit persons to whom the Software is copies or substantial portions of the Software . THE SOFTWARE IS PROVIDED " AS IS " , WITHOUT WARR...
7cc238d6b4f9fa80565b01544112f426cd47cc091d102168ea45042c6b82e4a4
mfikes/fifth-postulate
ns90.cljs
(ns fifth-postulate.ns90) (defn solve-for01 [xs v] (for [ndx0 (range 0 (- (count xs) 3)) ndx1 (range (inc ndx0) (- (count xs) 2)) ndx2 (range (inc ndx1) (- (count xs) 1)) ndx3 (range (inc ndx2) (count xs)) :when (= v (+ (xs ndx0) (xs ndx1) (xs ndx2) (xs ndx3)))] (list (xs...
null
https://raw.githubusercontent.com/mfikes/fifth-postulate/22cfd5f8c2b4a2dead1c15a96295bfeb4dba235e/src/fifth_postulate/ns90.cljs
clojure
(ns fifth-postulate.ns90) (defn solve-for01 [xs v] (for [ndx0 (range 0 (- (count xs) 3)) ndx1 (range (inc ndx0) (- (count xs) 2)) ndx2 (range (inc ndx1) (- (count xs) 1)) ndx3 (range (inc ndx2) (count xs)) :when (= v (+ (xs ndx0) (xs ndx1) (xs ndx2) (xs ndx3)))] (list (xs...
c0e70e18036b7bd695418950f1df656ef2d327b0950f4902d51cf1e6688c8661
BinaryAnalysisPlatform/bap
bap_trace_event_types.ml
open Bap.Std open Core_kernel[@@warning "-D"] open Bap_knowledge open Bap_core_theory module KB = Knowledge module Move = struct type 'a t = { cell : 'a; data : word; } [@@deriving bin_io, compare, fields, sexp] end module Chunk = struct type t = { addr : addr; data : string; } [@@deriving bi...
null
https://raw.githubusercontent.com/BinaryAnalysisPlatform/bap/253afc171bbfd0fe1b34f6442795dbf4b1798348/lib/bap_traces/bap_trace_event_types.ml
ocaml
open Bap.Std open Core_kernel[@@warning "-D"] open Bap_knowledge open Bap_core_theory module KB = Knowledge module Move = struct type 'a t = { cell : 'a; data : word; } [@@deriving bin_io, compare, fields, sexp] end module Chunk = struct type t = { addr : addr; data : string; } [@@deriving bi...
c775a9b15804311d544dfcf1f1824f4116b4f07b72d01d7f298a3e7c30d3f646
esl/MongooseIM
mod_http_upload_backend.erl
%% Just a proxy interface module between the main mod_http_upload module and %% the backend modules (i.e. mod_http_upload_s3). -module(mod_http_upload_backend). -export([init/2, create_slot/7]). -define(MAIN_MODULE, mod_http_upload). %%-------------------------------------------------------------------- %% Callbacks ...
null
https://raw.githubusercontent.com/esl/MongooseIM/95c55e26b4544472cf726824a04f7124e35a745d/src/http_upload/mod_http_upload_backend.erl
erlang
Just a proxy interface module between the main mod_http_upload module and the backend modules (i.e. mod_http_upload_s3). -------------------------------------------------------------------- Callbacks --------------------------------------------------------------------
-module(mod_http_upload_backend). -export([init/2, create_slot/7]). -define(MAIN_MODULE, mod_http_upload). -callback create_slot(UTCDateTime :: calendar:datetime(), UUID :: binary(), Filename :: unicode:unicode_binary(), ContentType :: binary() | undefined, Size :: pos_int...
b4e8e87b75d76606a725d5fbc4509fad6191867de12daab0fad3ae9c92e74839
haskell-works/avro
ContainerSpec.hs
{-# LANGUAGE OverloadedStrings #-} # LANGUAGE ScopedTypeVariables # module Avro.Decode.ContainerSpec where import Data.Avro.Codec (Codec (..), deflateCodec, nullCodec) import Data.ByteString.Char8 (unpack) import Data.List (unfoldr) import Avro.Data.Endpoint import Avro.TestUt...
null
https://raw.githubusercontent.com/haskell-works/avro/aeea12b07a1c6fcc3708d1afe7209c5497665296/test/Avro/Decode/ContainerSpec.hs
haskell
# LANGUAGE OverloadedStrings #
# LANGUAGE ScopedTypeVariables # module Avro.Decode.ContainerSpec where import Data.Avro.Codec (Codec (..), deflateCodec, nullCodec) import Data.ByteString.Char8 (unpack) import Data.List (unfoldr) import Avro.Data.Endpoint import Avro.TestUtils import HaskellWorks.Hsp...
aca7ba7254d23495cb8304af0a0455b93313b1f3129a2eb544b9e389af916d86
afronski/bferl
brainfuck_io_SUITE.erl
-module(brainfuck_io_SUITE). -include_lib("common_test/include/ct.hrl"). -include_lib("eunit/include/eunit.hrl"). -include("../include/interpreter_definitions.hrl"). -export([ all/0, init_per_testcase/2, end_per_testcase/2 ]). -export([ testing_input_and_output/1, testing_hello_world/1, testing_loop_with_i...
null
https://raw.githubusercontent.com/afronski/bferl/18d3482c71cdb0e39bde090d436245a2a9531f49/test/brainfuck_io_SUITE.erl
erlang
-module(brainfuck_io_SUITE). -include_lib("common_test/include/ct.hrl"). -include_lib("eunit/include/eunit.hrl"). -include("../include/interpreter_definitions.hrl"). -export([ all/0, init_per_testcase/2, end_per_testcase/2 ]). -export([ testing_input_and_output/1, testing_hello_world/1, testing_loop_with_i...
60e541e956b9e3295fe4a4d1bfc0d9466fd3a10d0c2067775c16b7244a20aef9
ucsd-progsys/liquidhaskell
BadPragma2.hs
{-@ LIQUID "--expect-error-containing=Illegal pragma" @-} {-@ LIQUID "--ghc-option=-O0" @-} module BadPragma2 where i :: Int i = 1
null
https://raw.githubusercontent.com/ucsd-progsys/liquidhaskell/f46dbafd6ce1f61af5b56f31924c21639c982a8a/tests/errors/BadPragma2.hs
haskell
@ LIQUID "--expect-error-containing=Illegal pragma" @ @ LIQUID "--ghc-option=-O0" @
module BadPragma2 where i :: Int i = 1
f191db955447dc2043dda0e73f2c3b55e459fa7a8d30abae98f045978dc39d21
shuieryin/wechat_mud
login.erl
%%%------------------------------------------------------------------- %%% @author Shuieryin ( C ) 2015 , Shuieryin %%% @doc %%% %%% Login module %%% %%% @end Created : 26 . Aug 2015 11:01 AM %%%------------------------------------------------------------------- -module(login). -author("Shuieryin"). %% API -expor...
null
https://raw.githubusercontent.com/shuieryin/wechat_mud/b2a9251a9b208fee5cd8c4213759750b95c8b8aa/src/commands/login.erl
erlang
------------------------------------------------------------------- @author Shuieryin @doc Login module @end ------------------------------------------------------------------- API =================================================================== API ===========================================================...
( C ) 2015 , Shuieryin Created : 26 . Aug 2015 11:01 AM -module(login). -author("Shuieryin"). -export([ exec/3 ]). Log user in by creating player_statem and enters user 's last logout scene . be respond to user from player_statem by sending responses to -spec exec(DispatcherPid, Uid, RawInput) -> ok whe...
95cf295253b6c577cd2f50733ad419e1ccf87f38d956db69554e01c4074115a2
Rober-t/apxr_run
population_mgr_sup.erl
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Copyright ( C ) 2018 ApproximateReality %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%---------------------------------------------------------------------------- @doc PopulationMgr top supervisor ....
null
https://raw.githubusercontent.com/Rober-t/apxr_run/9c62ab028af7ff3768ffe3f27b8eef1799540f05/src/population_mgr/population_mgr_sup.erl
erlang
---------------------------------------------------------------------------- @end ---------------------------------------------------------------------------- API Supervisor callbacks ============================================================================ Type ================================================...
Copyright ( C ) 2018 ApproximateReality @doc PopulationMgr top supervisor . -module(population_mgr_sup). -behaviour(supervisor). Start / Stop -export([ start_link/0 ]). -export([ start_population_mgr/0, restart_population_mgr/0 ]). -export([ init/1 ]). Xref -ignore_xref([ start_link/0 ]). -typ...
248ce864e85c1e1d6a9928c6ac0b6e08b162cba13c08fff08109f92efd709853
facebook/flow
object_parser.ml
* Copyright ( c ) Meta Platforms , Inc. and affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in t...
null
https://raw.githubusercontent.com/facebook/flow/2422f3f1a00f5a3ea50bb25a22ec9108aca8c70e/src/parser/object_parser.ml
ocaml
A module for parsing various object related things, like object literals * and classes this is a getter or setter, it cannot be async It's not clear how type params on getters & setters would make sense * in Flow's type system. Since this is a Flow syntax extension, we might * as...
* Copyright ( c ) Meta Platforms , Inc. and affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in t...
eeebcb045500618911203c3f7aea10afb449259db9531850ca085f1e4768fbb7
cl-axon/shop2
decls.lisp
(in-package :shop2) (defclass search-state () ( (mode :initarg :mode :accessor mode :documentation "Holds the mode -- the name -- of the current \"instruction\" in the explicit search virtual machine." ) (current-task :initarg :current-task :accessor current-task :type (or list null...
null
https://raw.githubusercontent.com/cl-axon/shop2/9136e51f7845b46232cc17ca3618f515ddcf2787/explicit-stack-search/decls.lisp
lisp
world state plan-so-far
(in-package :shop2) (defclass search-state () ( (mode :initarg :mode :accessor mode :documentation "Holds the mode -- the name -- of the current \"instruction\" in the explicit search virtual machine." ) (current-task :initarg :current-task :accessor current-task :type (or list null...
76cbdfdfbbbe4b7ed7f60e8b48bf298ca793e71b36dbceb5669d3c39d83ffea0
MinaProtocol/mina
mina_transaction_logic.ml
open Core_kernel open Mina_base open Currency open Signature_lib open Mina_transaction module Zkapp_command_logic = Zkapp_command_logic module Global_slot = Mina_numbers.Global_slot module Transaction_applied = struct module UC = Signed_command module Signed_command_applied = struct module Common = struct ...
null
https://raw.githubusercontent.com/MinaProtocol/mina/9a97ea71909a802f2ade0305a8069f7cbace5619/src/lib/transaction_logic/mina_transaction_logic.ml
ocaml
int type is OK, no danger of overflow * Apply all zkapp_command within a zkapp_command transaction. This behaves as [apply_zkapp_command_unchecked], except that the [~init] and [~f] arguments are provided to allow for the accumulation of the intermediate states. Invariant: [f] is always applied at ...
open Core_kernel open Mina_base open Currency open Signature_lib open Mina_transaction module Zkapp_command_logic = Zkapp_command_logic module Global_slot = Mina_numbers.Global_slot module Transaction_applied = struct module UC = Signed_command module Signed_command_applied = struct module Common = struct ...
614b1f3b645fbbe5d6aa2b69e08ea5bee2f40964521e2dea0b523bbc5bd4caf8
ml4tp/tcoq
ind_tables.mli
(************************************************************************) v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2017 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *...
null
https://raw.githubusercontent.com/ml4tp/tcoq/7a78c31df480fba721648f277ab0783229c8bece/toplevel/ind_tables.mli
ocaml
********************************************************************** // * This file is distributed under the terms of the * GNU Lesser General Public License Version 2.1 ********************************************************************** * This module provides support for r...
v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2017 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * open Term open Names open Dec...
6f4aaf2302ab4efe068952a5fb88d75904d3a330d3d17de385181d62b6e16009
well-typed/visualize-cbn
Pretty.hs
# LANGUAGE CPP # module CBN.Pretty (ToDoc, toDoc, heapToDoc) where #if !(MIN_VERSION_base(4,11,0)) import Data.Monoid #endif import Data.List (intersperse) import Data.Set (Set) import qualified Data.Map as Map import qualified Data.Set as Set import CBN.Closure import CBN.Eval import CBN.Heap import CBN.Language imp...
null
https://raw.githubusercontent.com/well-typed/visualize-cbn/499a8bc806ce03ce6d1bc12df1ea6e6df7768817/src/CBN/Pretty.hs
haskell
| Table-row for a match statement Used when using a vertical layout for a case statement | We make elements from the prelude blue standard rendering <+> toDoc ptr | Based on purescript implementation | For the heap we need to know which pointers we are about to collect ------------------------------------------...
# LANGUAGE CPP # module CBN.Pretty (ToDoc, toDoc, heapToDoc) where #if !(MIN_VERSION_base(4,11,0)) import Data.Monoid #endif import Data.List (intersperse) import Data.Set (Set) import qualified Data.Map as Map import qualified Data.Set as Set import CBN.Closure import CBN.Eval import CBN.Heap import CBN.Language imp...
c2fbcaa79a428e6cf7436b938fb9a15c232dcd76d8a0d639586501ede9454ad2
tweag/lagoon
Logging.hs
Copyright 2020 Pfizer Inc. Licensed under the Apache License , Version 2.0 ( the " License " ) ; -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -2.0 -- Unless required by applicable law or agreed to in writing, software distributed under th...
null
https://raw.githubusercontent.com/tweag/lagoon/2ef0440db810f4f45dbed160b369daf41d92bfa4/src/interface/src/Lagoon/Interface/Logging.hs
haskell
you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permiss...
Copyright 2020 Pfizer Inc. Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , module Lagoon.Interface.Logging ( LogLevel(..) , Logger(..) , filterLogMessages ) where import Control.Monad import Data.Functor.Contr...
e62672f9522d9955d96f1b615f0e3d25aebf2e4aa70ec18ff7eef02ce042c36d
MinaProtocol/mina
staged_ledger.mli
open Core_kernel open Async_kernel open Mina_base open Mina_transaction open Signature_lib module Ledger = Mina_ledger.Ledger type t [@@deriving sexp] module Scan_state : sig [%%versioned: module Stable : sig module V2 : sig type t [@@deriving sexp] val hash : t -> Staged_ledger_hash.Aux_hash.t ...
null
https://raw.githubusercontent.com/MinaProtocol/mina/fcbcca1b34414e52642661352588420af906cdf4/src/lib/staged_ledger/staged_ledger.mli
ocaml
* All the transactions with hash of the parent block in which they were included in the order in which they were applied * Hashes of the protocol states required for proving pending transactions * Validate protocol states required for proving the transactions. Returns an association list of state_hash and the correspon...
open Core_kernel open Async_kernel open Mina_base open Mina_transaction open Signature_lib module Ledger = Mina_ledger.Ledger type t [@@deriving sexp] module Scan_state : sig [%%versioned: module Stable : sig module V2 : sig type t [@@deriving sexp] val hash : t -> Staged_ledger_hash.Aux_hash.t ...
318a1c920c7fc0f85fe4dff3ade589ca5cee01296682f720deda02723ccbf8ee
snowleopard/alga
Arbitrary.hs
# LANGUAGE CPP # # OPTIONS_GHC -fno - warn - orphans # ----------------------------------------------------------------------------- -- | -- Module : Algebra.Graph.Test.Arbitrary Copyright : ( c ) 2016 - 2022 License : MIT ( see the file LICENSE ) -- Maintainer : -- Stability : experimental -- -- Gene...
null
https://raw.githubusercontent.com/snowleopard/alga/399b5dc538a2496b67f9322dc7247e06a4ec326b/test/Algebra/Graph/Test/Arbitrary.hs
haskell
--------------------------------------------------------------------------- | Module : Algebra.Graph.Test.Arbitrary Maintainer : Stability : experimental Generators and orphan Arbitrary instances for various data types. --------------------------------------------------------------------------- * Generator...
# LANGUAGE CPP # # OPTIONS_GHC -fno - warn - orphans # Copyright : ( c ) 2016 - 2022 License : MIT ( see the file LICENSE ) module Algebra.Graph.Test.Arbitrary ( arbitraryGraph, arbitraryRelation, arbitraryAdjacencyMap, ) where import Control.Monad import Data.List.NonEmpty (NonEmpty (..), toList) ...
f75a79c3911ac15a94fb3e30b4a2b0efab4f6c5e4cc17af23f5cb70d0ab5a4a4
OCamlPro/ocp-build
buildSubst.ml
(**************************************************************************) (* *) (* Typerex Tools *) (* *) Copyrigh...
null
https://raw.githubusercontent.com/OCamlPro/ocp-build/56aff560bb438c12b2929feaf8379bc6f31b9840/tools/ocp-build/misc/buildSubst.ml
ocaml
************************************************************************ Typerex Tools ...
Copyright 2011 - 2017 OCamlPro SAS the GNU General Public License version 3 described in the file open OcpSubst let global_subst = empty_subst ( ) let add_to_subst env var vv = ( * Printf.eprintf " BuildSubst.add % S - > % S\n% ! " v vv ; let global_subst =...
375e34bac34f64bdbee0c0ba6e63fc291fdb0559893720d50e3240f56f2d49d0
jacekschae/learn-datomic-course-files
datomic.clj
(ns cheffy.components.datomic (:require [datomic.client.api :as d] [cheffy.validation :as validation] [clojure.edn :as edn])) (defn ident-has-attr? [db ident attr] (contains? (d/pull db {:eid ident :selector '[*]}) attr)) (defn load-dataset [conn] (let [db (d/db conn) tx #(d/...
null
https://raw.githubusercontent.com/jacekschae/learn-datomic-course-files/f2378c84bade5cb64018f72aa9179a8c8bb25df4/increments/58-endpoint/src/main/cheffy/components/datomic.clj
clojure
(ns cheffy.components.datomic (:require [datomic.client.api :as d] [cheffy.validation :as validation] [clojure.edn :as edn])) (defn ident-has-attr? [db ident attr] (contains? (d/pull db {:eid ident :selector '[*]}) attr)) (defn load-dataset [conn] (let [db (d/db conn) tx #(d/...
5f3c1e49710e9e6bafaf397c7263406812467bde9029b8e48bf8bb087eae2f95
seereason/logic-classes
FirstOrder.hs
# LANGUAGE DeriveDataTypeable , FlexibleContexts , FlexibleInstances , MultiParamTypeClasses , TemplateHaskell , TypeFamilies , UndecidableInstances # module Data.Logic.Types.FirstOrder ( withUnivQuants , NFormula(..) , NTerm(..) , NPredicate(..) ) where import Data.Data (Data) import Data.Logic.A...
null
https://raw.githubusercontent.com/seereason/logic-classes/819059218027c3ee77bd2ef3a873fcca230d54b4/Data/Logic/Types/FirstOrder.hs
haskell
| Examine the formula to find the list of outermost universally quantified variables, and call a function with that list and the formula after the quantifiers are removed. | The range of a formula is {True, False} when it has no free variables. |A temporary type used in the fold method to represent the combinatio...
# LANGUAGE DeriveDataTypeable , FlexibleContexts , FlexibleInstances , MultiParamTypeClasses , TemplateHaskell , TypeFamilies , UndecidableInstances # module Data.Logic.Types.FirstOrder ( withUnivQuants , NFormula(..) , NTerm(..) , NPredicate(..) ) where import Data.Data (Data) import Data.Logic.A...
629079c8dcd156508dc6f03311539ca1d322dabf13980aaf472ebeabeca1a83f
lambdageek/unbound-generics
PropOpenClose.hs
# LANGUAGE DeriveGeneric , DeriveDataTypeable # module PropOpenClose (test_openClose) where import Control.Applicative (Applicative(..), (<$>)) import Data.Monoid (Any(..)) import Data.Typeable (Typeable) import GHC.Generics (Generic) import Test.QuickCheck import Test.Tasty (testGroup, TestTree) import Test.Tasty.Qu...
null
https://raw.githubusercontent.com/lambdageek/unbound-generics/54096156b06dda2fcc523939de6da64b43737ea4/test/PropOpenClose.hs
haskell
Wrapper around 'Name a' that has an Arbitrary instance that generates free names. Note that this doesn't guarantee /freshness/. The name may clash with some other one. But it will never be a bound name. -------------------------------------- example data structure, with no bound names. spec for free variables of ...
# LANGUAGE DeriveGeneric , DeriveDataTypeable # module PropOpenClose (test_openClose) where import Control.Applicative (Applicative(..), (<$>)) import Data.Monoid (Any(..)) import Data.Typeable (Typeable) import GHC.Generics (Generic) import Test.QuickCheck import Test.Tasty (testGroup, TestTree) import Test.Tasty.Qu...
40a5663833e0cdf5edf80e20bc64c9848b16be44a359ddd29d5f28ebf2609fee
FlowForwarding/loom
tap_yaws_sup.erl
-module(tap_yaws_sup). -behavior(supervisor). -export([start_link/0]). -export([init/1]). start_link() -> supervisor:start_link({local, ?MODULE}, ?MODULE, []). init([]) -> YBed = {tap_yaws, {tap_yaws, start_link, [self()]}, permanent, 5000, worker, [tap_yaws]}, ...
null
https://raw.githubusercontent.com/FlowForwarding/loom/86a9c5aa8b7d4776062365716c9a3dbbf3330bc5/tapestry/apps/tapestry/src/tap_yaws_sup.erl
erlang
-module(tap_yaws_sup). -behavior(supervisor). -export([start_link/0]). -export([init/1]). start_link() -> supervisor:start_link({local, ?MODULE}, ?MODULE, []). init([]) -> YBed = {tap_yaws, {tap_yaws, start_link, [self()]}, permanent, 5000, worker, [tap_yaws]}, ...
13041a3292fe87e57c64df4381acfbf6880bdd82168740a3fa59ed6499f402cb
ddssff/refact-global-hse
SrcLoc.hs
-- | Utility functions for the haskell-src-exts type SrcLoc. # LANGUAGE BangPatterns , CPP , FlexibleInstances , PackageImports , ScopedTypeVariables , TemplateHaskell , UndecidableInstances # # OPTIONS_GHC -Wall -fno - warn - orphans # module Refactor.SrcLoc * SpanInfo queries srcLoc , EndLoc(endLoc) ...
null
https://raw.githubusercontent.com/ddssff/refact-global-hse/519a017009cae8aa1a3db1b46eb560d76bd9895d/src/Refactor/SrcLoc.hs
haskell
| Utility functions for the haskell-src-exts type SrcLoc. * Location and span info for a piece of text * Split text at a location * Use span info to extract text (Annotated(ann), Module(..)) | Return a span that exactly covers the string s | Return the text before, within, and after a span This should not happe...
# LANGUAGE BangPatterns , CPP , FlexibleInstances , PackageImports , ScopedTypeVariables , TemplateHaskell , UndecidableInstances # # OPTIONS_GHC -Wall -fno - warn - orphans # module Refactor.SrcLoc * SpanInfo queries srcLoc , EndLoc(endLoc) , spanOfText , endLocOfText , splitText , splits ...
40bf87d916a1ee06be9d1e03fb16abe61838b0a7b26bbb4a992ea9810b3f9978
mvaldesdeleon/aoc18
Day9.hs
# LANGUAGE RecordWildCards # module Day9 ( day9 ) where import Control.Monad.Loops import Control.Monad.State import qualified Data.List.Zipper as Z import qualified Data.Map.Strict as M import Paths_aoc18 (getDataFileName) import Text.Parsec (Par...
null
https://raw.githubusercontent.com/mvaldesdeleon/aoc18/1a6f6de7c482e5de264360e36f97a3c7487e2457/src/Day9.hs
haskell
# LANGUAGE RecordWildCards # module Day9 ( day9 ) where import Control.Monad.Loops import Control.Monad.State import qualified Data.List.Zipper as Z import qualified Data.Map.Strict as M import Paths_aoc18 (getDataFileName) import Text.Parsec (Par...
811401d67d63cb0595477d446a831a99a13a3fbd918a9769ea39b6759c6c1606
mirage/ocaml-openflow
imperative.mli
(**************************************************************************) (* *) : a generic graph library for OCaml Copyright ( C ) 2004 - 2010 , and (* ...
null
https://raw.githubusercontent.com/mirage/ocaml-openflow/dcda113745e8edc61b5508eb8ac2d1e864e1a2df/lib/imperative.mli
ocaml
************************************************************************ This software is free software; you can redistribute it and/or described in file LICENSE....
: a generic graph library for OCaml Copyright ( C ) 2004 - 2010 , and modify it under the terms of the GNU Library General Public License version 2.1 , with the special exception on linking open Sig...
703c0a5d17a2c505d40e05bba2761c22e1a6162adf2a900c405dcb2b4acc8935
RedHatQE/katello.auto
conf.clj
(ns katello.conf (:require [clojure.java.io :as io] [clojure.string :as string] clojure.tools.cli [fn.trace :refer [all-fns]] [ovirt.client :as ovirt] katello [katello.tasks :refer [unique-names]]) (:import [java.io PushbackReader FileNotFou...
null
https://raw.githubusercontent.com/RedHatQE/katello.auto/79fec96581044bce5db5350d0da325e517024962/src/katello/conf.clj
clojure
config layer :default "-misc/sign_manifest.sh/scripts/test/manifest_generation/fake_key.pem"] Tracing setup default no limit to trace depth bid adeiu to j.u.l logging config files var to lock on for promotions
(ns katello.conf (:require [clojure.java.io :as io] [clojure.string :as string] clojure.tools.cli [fn.trace :refer [all-fns]] [ovirt.client :as ovirt] katello [katello.tasks :refer [unique-names]]) (:import [java.io PushbackReader FileNotFou...
7b4161c62fd31f68e222e5694a306c3b86988a160055ebea60bcf807e77041c4
facebookarchive/pfff
gtkThread.ml
(**************************************************************************) (* Lablgtk *) (* *) (* This program is free software; you can redistribute it *) and/or ...
null
https://raw.githubusercontent.com/facebookarchive/pfff/ec21095ab7d445559576513a63314e794378c367/external/ocamlgtk/src/gtkThread.ml
ocaml
************************************************************************ Lablgtk This program is free software; you can redistribute it comes with the library. ...
and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation version 2 , with the exception described in file COPYING which GNU Library General Public License for more details . You should have r...
f36b670e3ac1e709b13aac26988b09385f00b0d4aae70ae903bec2a9b98101e4
jvf/scalaris
prbr_SUITE.erl
2012 - 2016 Zuse Institute Berlin Licensed under the Apache License , Version 2.0 ( the " License " ) ; % you may not use this file except in compliance with the License. % You may obtain a copy of the License at % % -2.0 % % Unless required by applicable law or agreed to in writing, software di...
null
https://raw.githubusercontent.com/jvf/scalaris/c069f44cf149ea6c69e24bdb08714bda242e7ee0/test/prbr_SUITE.erl
erlang
you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language gov...
2012 - 2016 Zuse Institute Berlin Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , @author < > @author < > -module(prbr_SUITE). -author(''). -vsn('$Id$'). -compile(export_all). -include("scalaris.hrl"). -i...
7582b0130fa5b51a6934dd4fa82914f8c4bc9fe03079e3baeac8885467aec8a5
Datomic/dev.datafy
java.clj
Copyright ( c ) Cognitect , Inc. ;; All rights reserved. ;; Licensed under the Apache License , Version 2.0 ( the " License " ) ; ;; you may not use this file except in compliance with the License. ;; You may obtain a copy of the License at ;; ;; -2.0 ;; ;; Unless required by applicable law or agreed to in wri...
null
https://raw.githubusercontent.com/Datomic/dev.datafy/67a0923c3e0492503a44672b5bf74a9b35e0e46f/src/datomic/dev/datafy/java.clj
clojure
All rights reserved. you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific...
Copyright ( c ) Cognitect , Inc. distributed under the License is distributed on an " AS - IS " BASIS , (ns datomic.dev.datafy.java (:require [clojure.core.protocols :as p])) (set! *warn-on-reflection* true) (defn hexify "Convert byte array to hex string" ([^bytes bs] (hexify bs 0 (alength bs))) ([^by...
42aa9f2ed6e2a1686e72e63dcbc9d8ed10c9ab4cb92257dd7ca5b26a00a0488f
AdaCore/why3
inlining.mli
(********************************************************************) (* *) The Why3 Verification Platform / The Why3 Development Team Copyright 2010 - 2022 -- Inria - CNRS - Paris - Saclay University (* ...
null
https://raw.githubusercontent.com/AdaCore/why3/4441127004d53cf2cb0f722fed4a930ccf040ee4/src/transform/inlining.mli
ocaml
****************************************************************** This software is distributed under the terms of the GNU Lesser on linking described in file LICENSE. ...
The Why3 Verification Platform / The Why3 Development Team Copyright 2010 - 2022 -- Inria - CNRS - Paris - Saclay University General Public License version 2.1 , with the special exception val intro_attr : Ident.attribute val meta : Theory.meta * { 2 Generic inlining } val t : use_meta:boo...
aa76a0a774c34f277d60aa8b895e0bd8ca5f09a90840e5751b1d5f0ed426668e
SimulaVR/godot-haskell
Sky.hs
# LANGUAGE DerivingStrategies , GeneralizedNewtypeDeriving , TypeFamilies , TypeOperators , FlexibleContexts , DataKinds , MultiParamTypeClasses # TypeFamilies, TypeOperators, FlexibleContexts, DataKinds, MultiParamTypeClasses #-} module Godot.Core.Sky (Godot.Core.Sky._RADIANCE_SIZE_128, Godo...
null
https://raw.githubusercontent.com/SimulaVR/godot-haskell/e8f2c45f1b9cc2f0586ebdc9ec6002c8c2d384ae/src/Godot/Core/Sky.hs
haskell
| The @Sky@'s radiance map size. The higher the radiance map size, the more detailed the lighting from the @Sky@ will be. | The @Sky@'s radiance map size. The higher the radiance map size, the more detailed the lighting from the @Sky@ will be. | The @Sky@'s radiance map size. The higher the radiance map size, the mo...
# LANGUAGE DerivingStrategies , GeneralizedNewtypeDeriving , TypeFamilies , TypeOperators , FlexibleContexts , DataKinds , MultiParamTypeClasses # TypeFamilies, TypeOperators, FlexibleContexts, DataKinds, MultiParamTypeClasses #-} module Godot.Core.Sky (Godot.Core.Sky._RADIANCE_SIZE_128, Godo...
3808c045047ac8103a34fb3671e685838e5ccfe20e49ff9cbc7658beb1844f51
gedge-platform/gedge-platform
jose_jwa_concat_kdf.erl
-*- mode : erlang ; tab - width : 4 ; indent - tabs - mode : 1 ; st - rulers : [ 70 ] -*- %% vim: ts=4 sw=4 ft=erlang noet %%%------------------------------------------------------------------- @author < > 2014 - 2015 , @doc , as defined in Section 5.8.1 of NIST.800 - 56A %%% See NIST.800-56A: -56Ar2 %%...
null
https://raw.githubusercontent.com/gedge-platform/gedge-platform/97c1e87faf28ba2942a77196b6be0a952bff1c3e/gs-broker/broker-server/deps/jose/src/jwa/jose_jwa_concat_kdf.erl
erlang
vim: ts=4 sw=4 ft=erlang noet ------------------------------------------------------------------- See NIST.800-56A: -56Ar2 @end ------------------------------------------------------------------- API ==================================================================== API functions ================================...
-*- mode : erlang ; tab - width : 4 ; indent - tabs - mode : 1 ; st - rulers : [ 70 ] -*- @author < > 2014 - 2015 , @doc , as defined in Section 5.8.1 of NIST.800 - 56A Created : 24 Jul 2015 by < > -module(jose_jwa_concat_kdf). -export([kdf/3]). -export([kdf/4]). kdf(Hash, Z, OtherInfo) -> Ha...
be66952295ab73f6006a6a1a5f55330d9355df2b238f76afb82c5cc798f23f89
oden-lang/oden
InferConstraintsSpec.hs
module Oden.Infer.InferConstraintsSpec where import Test.Hspec import Oden.Core.Typed import Oden.Core.Expr import Oden.Core.Untyped import Oden.Identifier import Oden.Infer (inferExpr) import Oden.Predefined import Oden.Pretty...
null
https://raw.githubusercontent.com/oden-lang/oden/10c99b59c8b77c4db51ade9a4d8f9573db7f4d14/test/Oden/Infer/InferConstraintsSpec.hs
haskell
module Oden.Infer.InferConstraintsSpec where import Test.Hspec import Oden.Core.Typed import Oden.Core.Expr import Oden.Core.Untyped import Oden.Identifier import Oden.Infer (inferExpr) import Oden.Predefined import Oden.Pretty...
53716143a28b9bc9b6b48003cff5891f9d7d2695a8fc449ee46cefba84684689
patricoferris/ocaml-multicore-monorepo
adapt.ml
This file is part of Dream , released under the MIT license . See LICENSE.md for details , or visit . Copyright 2021 for details, or visit . Copyright 2021 Anton Bachin *) module Stream = Dream_pure.Stream module Message = Dream_pure.Message let address_to_string : Unix.sockaddr -> string =...
null
https://raw.githubusercontent.com/patricoferris/ocaml-multicore-monorepo/22b441e6727bc303950b3b37c8fbc024c748fe55/duniverse/dream/src/http/adapt.ml
ocaml
This file is part of Dream , released under the MIT license . See LICENSE.md for details , or visit . Copyright 2021 for details, or visit . Copyright 2021 Anton Bachin *) module Stream = Dream_pure.Stream module Message = Dream_pure.Message let address_to_string : Unix.sockaddr -> string =...
7699ca1e1789560fd4442f80ea95ae0503f94b21c2a392e5f3f06ee9376e3c46
linyinfeng/myml
Spec.hs
module Myml.Syntax.Spec ( tests, ) where import qualified Data.Map as Map import qualified Data.Set as Set import Myml.Syntax import Myml.Test.Helper import Test.Tasty import Test.Tasty.HUnit tests :: TestTree tests = testGroup "Myml.Syntax.Spec" [unitTests] unitTests :: TestTree unitTests = testGroup "Unit test...
null
https://raw.githubusercontent.com/linyinfeng/myml/c90446431caeebd4b67f9b6a7a172a70b92f138f/tests/Myml/Syntax/Spec.hs
haskell
module Myml.Syntax.Spec ( tests, ) where import qualified Data.Map as Map import qualified Data.Set as Set import Myml.Syntax import Myml.Test.Helper import Test.Tasty import Test.Tasty.HUnit tests :: TestTree tests = testGroup "Myml.Syntax.Spec" [unitTests] unitTests :: TestTree unitTests = testGroup "Unit test...
44b8069ad6cc54cd55dc065e6e198e52ed5288be44800149d16f038d6d98a172
klartext/any-dl
main.mli
module E = Evaluate exception AutoTry_success exception No_parser_found_for_this_url exception Unknown_parser val parse_parser_definitions_from_files : string list -> Parsetreetypes.lang_t list val parsername_lookup_by_url : string -> (string * string) list -> string val get_parserdef : string -> (string * string...
null
https://raw.githubusercontent.com/klartext/any-dl/53a962b51c82dde04d11e0685920db60cd65c458/main.mli
ocaml
module E = Evaluate exception AutoTry_success exception No_parser_found_for_this_url exception Unknown_parser val parse_parser_definitions_from_files : string list -> Parsetreetypes.lang_t list val parsername_lookup_by_url : string -> (string * string) list -> string val get_parserdef : string -> (string * string...
5c964457d31316162477212a63988e6c3d2903cea4466c9acf1c15cfc7f03531
haskell-repa/repa
Base.hs
module Data.Repa.Flow.Simple.Base ( Source, Sink , finalize_i , finalize_o , wrapI_i , wrapI_o) where import Data.Repa.Flow.States import qualified Data.Repa.Flow.Generic as G #include "repa-flow.h" -- | Source consisting of a single stream. type Source m e = G.Sources () m e ...
null
https://raw.githubusercontent.com/haskell-repa/repa/c867025e99fd008f094a5b18ce4dabd29bed00ba/repa-flow/Data/Repa/Flow/Simple/Base.hs
haskell
| Source consisting of a single stream. | Sink consisting of a single stream. Finalizers ----------------------------------------------------------------- | Attach a finalizer to a source. tries to pull an element when no more are available. The provided finalizer will be run after any finalizers already ...
module Data.Repa.Flow.Simple.Base ( Source, Sink , finalize_i , finalize_o , wrapI_i , wrapI_o) where import Data.Repa.Flow.States import qualified Data.Repa.Flow.Generic as G #include "repa-flow.h" type Source m e = G.Sources () m e type Sink m e = G.Sinks () m e T...
f9e4a63d00744de417bfc327cb6c69c811dcde2a313f275cdebf989cbb55e75a
athensresearch/athens
migrations.cljc
(ns athens.common.migrations " Migrations should be interruptible and resumable, so that crashes and mistakes will not leave the DB in a bad state that can be recovered from. If a migration fails, it should throw an error. A good way to make something interruptible is to ensure its idempotent." (:require ...
null
https://raw.githubusercontent.com/athensresearch/athens/7434452efc583ec4163894e0e4246558ac5cba41/src/cljc/athens/common/migrations.cljc
clojure
(ns athens.common.migrations " Migrations should be interruptible and resumable, so that crashes and mistakes will not leave the DB in a bad state that can be recovered from. If a migration fails, it should throw an error. A good way to make something interruptible is to ensure its idempotent." (:require ...
88eb060805b22040fdcb39fbf295b8ee71f1216f206066e54919030f95ee8a63
mfoemmel/erlang-otp
wxEvtHandler.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 2008 - 2009 . All Rights Reserved . %% The contents of this file are subject to the Erlang Public License , Version 1.1 , ( the " License " ) ; you may not use this file except in %% compliance with the License. You should have received a copy of the %% Erlang Pub...
null
https://raw.githubusercontent.com/mfoemmel/erlang-otp/9c6fdd21e4e6573ca6f567053ff3ac454d742bc2/lib/wx/src/gen/wxEvtHandler.erl
erlang
%CopyrightBegin% compliance with the License. You should have received a copy of the Erlang Public License along with this software. If not, it can be retrieved online at /. basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limita...
Copyright Ericsson AB 2008 - 2009 . All Rights Reserved . The contents of this file are subject to the Erlang Public License , Version 1.1 , ( the " License " ) ; you may not use this file except in Software distributed under the License is distributed on an " AS IS " This module is actually handwritten see ...
f1d16defef774b0d9f732545e6e0343f01fcd5dffdef4bd69db8df47c55394fa
TheAlgorithms/Haskell
SelectionSortSpec.hs
# LANGUAGE ScopedTypeVariables # module SortSpecs.SelectionSortSpec where import Test.Hspec import Test.QuickCheck import Sorts.SelectionSort spec :: Spec spec = do describe "selectionSort" $ do it "returns empty list when sorting empty list" $ property $ selectionSort [] == ([] :: [Int]) ...
null
https://raw.githubusercontent.com/TheAlgorithms/Haskell/9dcabef99fb8995a760ff25a9e0d659114c0b9d3/specs/SortSpecs/SelectionSortSpec.hs
haskell
# LANGUAGE ScopedTypeVariables # module SortSpecs.SelectionSortSpec where import Test.Hspec import Test.QuickCheck import Sorts.SelectionSort spec :: Spec spec = do describe "selectionSort" $ do it "returns empty list when sorting empty list" $ property $ selectionSort [] == ([] :: [Int]) ...
2dc21d61c87d2426a4b95d1cd0af02fd77cb1b90be46fb7e1fa665e555bb220a
LesBoloss-es/ppx_deriving_madcast
function.ml
let () = let f = [%madcast: string -> int] in let g = [%madcast: (string -> int) -> (int -> string)] in assert ((g f) 2 = "2")
null
https://raw.githubusercontent.com/LesBoloss-es/ppx_deriving_madcast/2d44cbf21f79cd7aeacb077c09672ee823e5ba3f/test/positive/function.ml
ocaml
let () = let f = [%madcast: string -> int] in let g = [%madcast: (string -> int) -> (int -> string)] in assert ((g f) 2 = "2")
4bb34740195b5389ab5b24445a5558eb962c23942a456e3ed7688b32ccd8140c
jaredly/belt
belt_HashMap.ml
module N = Belt_internalBuckets module C = Belt_internalBucketsType module A = Belt_Array type ('a,'id) eq = ('a,'id) Belt_Id.eq type ('a,'id) hash = ('a,'id) Belt_Id.hash type ('a,'id) id = ('a,'id) Belt_Id.hashable type ('a,'b,'id) t = (('a,'id) hash,('a,'id) eq,'a,'b) N.t let clear = C.clear let size = C.size let fo...
null
https://raw.githubusercontent.com/jaredly/belt/4d07f859403fdbd3fbfc5a9547c6066d657a2131/belt/belt_HashMap.ml
ocaml
module N = Belt_internalBuckets module C = Belt_internalBucketsType module A = Belt_Array type ('a,'id) eq = ('a,'id) Belt_Id.eq type ('a,'id) hash = ('a,'id) Belt_Id.hash type ('a,'id) id = ('a,'id) Belt_Id.hashable type ('a,'b,'id) t = (('a,'id) hash,('a,'id) eq,'a,'b) N.t let clear = C.clear let size = C.size let fo...
c5ab2e20c093430b0d31573775921ea985a58e9593d5d46fda21bfa838a1cb02
eglaysher/rldev
encoding.ml
RLdev : character encoding utility functions Copyright ( C ) 2006 Haeleth This program is free software ; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the License , or ( at your o...
null
https://raw.githubusercontent.com/eglaysher/rldev/e59103b165e1c20bd940942405b2eee767933c96/src/common/encoding.ml
ocaml
RLdev : character encoding utility functions Copyright ( C ) 2006 Haeleth This program is free software ; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the License , or ( at your o...
a0bdbf64ab39c6a4d68ad7049969384c2ef365cc944de2b8e6a7e2ad5c513e1f
MLstate/opalang
qmlAstUtils.ml
Copyright © 2011 , 2012 MLstate This file is part of . is free software : you can redistribute it and/or modify it under the terms of the GNU Affero General Public License , version 3 , as published by the Free Software Foundation . is distributed in the hope that it will be us...
null
https://raw.githubusercontent.com/MLstate/opalang/424b369160ce693406cece6ac033d75d85f5df4f/compiler/libqmlcompil/qmlAstUtils.ml
ocaml
refactoring in progress depends alias shorthands -- special forms to document !!! forms with a unique inner expr the empty array is the only one that is not expansive * because it is not mutable only elements taking part in the expression type counts the empty array is the only one that ...
Copyright © 2011 , 2012 MLstate This file is part of . is free software : you can redistribute it and/or modify it under the terms of the GNU Affero General Public License , version 3 , as published by the Free Software Foundation . is distributed in the hope that it will be us...
b64cf0c37fc76b3dd0bf956e8fb36737976e43cd6abb1c5e4cde686085fc52d4
CarlosMChica/HaskellBook
givenATypeWriteThefunction.hs
module GivenATypeWriteTheFunction where i :: a -> a i x = x c :: a -> b -> a c x y = x c'' :: b -> a -> b c'' x y = x c' :: a -> b -> b c' x y = y r :: [a] -> [a] r = tail solution 2 r ( x : xs ) = [ x ] soltuion 3 r xs = reverse xs co :: (b -> c) -> (a -> b) -> a -> c co f g = f . g a :: (a -> c) -> a -> a...
null
https://raw.githubusercontent.com/CarlosMChica/HaskellBook/86f82cf36cd00003b1a1aebf264e4b5d606ddfad/chapter5/givenATypeWriteThefunction.hs
haskell
module GivenATypeWriteTheFunction where i :: a -> a i x = x c :: a -> b -> a c x y = x c'' :: b -> a -> b c'' x y = x c' :: a -> b -> b c' x y = y r :: [a] -> [a] r = tail solution 2 r ( x : xs ) = [ x ] soltuion 3 r xs = reverse xs co :: (b -> c) -> (a -> b) -> a -> c co f g = f . g a :: (a -> c) -> a -> a...
dce9d026b3466eae9d274ad138b1a423e33a38a907feb318cc537a9a75d52001
NorfairKing/validity
HashableSpec.hs
# LANGUAGE DeriveGeneric # # LANGUAGE TypeApplications # | Standard ' Spec 's for ' Hashable ' instances . -- -- You will need @TypeApplications@ to use these. module Test.Validity.HashableSpec where import Data.GenValidity import Data.Hashable import GHC.Generics import Test.Hspec import Test.Validity.Hashable imp...
null
https://raw.githubusercontent.com/NorfairKing/validity/35bc8d45b27e6c21429e4b681b16e46ccd541b3b/genvalidity-hspec-hashable/test/Test/Validity/HashableSpec.hs
haskell
You will need @TypeApplications@ to use these.
# LANGUAGE DeriveGeneric # # LANGUAGE TypeApplications # | Standard ' Spec 's for ' Hashable ' instances . module Test.Validity.HashableSpec where import Data.GenValidity import Data.Hashable import GHC.Generics import Test.Hspec import Test.Validity.Hashable import Test.Validity.Utils spec :: Spec spec = do has...
74632be2fef0fecdbcc50c16537cf2818341123e6dceef3ee2496d5bef16371d
LexiFi/menhir
CompletedNat.mli
(******************************************************************************) (* *) (* *) ...
null
https://raw.githubusercontent.com/LexiFi/menhir/794e64e7997d4d3f91d36dd49aaecc942ea858b7/attic/src/CompletedNat.mli
ocaml
**************************************************************************** file LICEN...
, Paris , PPS , Université Paris Diderot . All rights reserved . This file is distributed under the terms of the GNU General Public License version 2 , as...
36b69b87458ea62231fc308db402f362c5187be8dd73fcaba798b139578bad8f
archaelus/erms
esvc_voucher_export.erl
%%%------------------------------------------------------------------- @copyright Catalyst IT Ltd ( ) %%% @author < > %% @version {@vsn}, {@date} {@time} @doc Voucher CVS file export code %% @end %%%------------------------------------------------------------------- -module(esvc_voucher_export). -include_lib(...
null
https://raw.githubusercontent.com/archaelus/erms/5dbe5e79516a16e461e7a2a345dd80fbf92ef6fa/src/esvc_voucher_export.erl
erlang
------------------------------------------------------------------- @version {@vsn}, {@date} {@time} @end ------------------------------------------------------------------- API ==================================================================== API ================================================================...
@copyright Catalyst IT Ltd ( ) @author < > @doc Voucher CVS file export code -module(esvc_voucher_export). -include_lib("eunit/include/eunit.hrl"). -include_lib("logging.hrl"). -include_lib("mnesia_model.hrl"). -include_lib("esvc_voucher.hrl"). -export([cvs_report/2]). cvs_report(Filename , Date ) - >...
35aaefab84abeaf28804850f1a3cf63bd4c04d2b9712c718ae02b3be2f28624d
mtgred/netrunner
right_pane.cljs
(ns nr.gameboard.right-pane (:require [cljs.core.async :refer [put!]] [nr.appstate :refer [app-state]] [nr.gameboard.card-preview :refer [zoom-channel]] [nr.gameboard.log :refer [log-pane]] [nr.gameboard.replay :refer [notes-pane notes-shared-pane]] [nr.game...
null
https://raw.githubusercontent.com/mtgred/netrunner/42c5ecc6a7c69c173822c0e9ef1a8d09b02b5bdc/src/cljs/nr/gameboard/right_pane.cljs
clojure
XXX: rename
(ns nr.gameboard.right-pane (:require [cljs.core.async :refer [put!]] [nr.appstate :refer [app-state]] [nr.gameboard.card-preview :refer [zoom-channel]] [nr.gameboard.log :refer [log-pane]] [nr.gameboard.replay :refer [notes-pane notes-shared-pane]] [nr.game...
7440c5483d61543e97c5ded13c1919cba30b1a246a9d59f35793d6aded107e05
janestreet/async_smtp
envelope.mli
open! Core open Email_message Two envelopes are equal when they produce the same SMTP output . In particular , ids are ignored for comparison . Same is true for hashing . particular, ids are ignored for comparison. Same is true for hashing. *) type t [@@deriving sexp_of] type envelope = t [@@deriving sexp_o...
null
https://raw.githubusercontent.com/janestreet/async_smtp/72c538d76f5c7453bbc89af44d93931cd499a912/types/envelope.mli
ocaml
Extracts sender and recipients from the headers.
open! Core open Email_message Two envelopes are equal when they produce the same SMTP output . In particular , ids are ignored for comparison . Same is true for hashing . particular, ids are ignored for comparison. Same is true for hashing. *) type t [@@deriving sexp_of] type envelope = t [@@deriving sexp_o...
8f7974c1721957fb98dd319974b81860e0927ae10461f1680a99515d7264a88f
returntocorp/semgrep
test_parsing_cpp.ml
open Common module PI = Parse_info module PS = Parsing_stat module Flag = Flag_parsing module Flag_cpp = Flag_parsing_cpp (*****************************************************************************) (* Subsystem testing *) (*****************************************************************************) let test_tok...
null
https://raw.githubusercontent.com/returntocorp/semgrep/ecfb452fde8fab7afffa5d2cdfc5ef7c1da91ad9/languages/cpp/menhir/test_parsing_cpp.ml
ocaml
*************************************************************************** Subsystem testing *************************************************************************** TODO: be more strict, List.hd failure, Stack overflow *************************************************************************** Main entry for ...
open Common module PI = Parse_info module PS = Parsing_stat module Flag = Flag_parsing module Flag_cpp = Flag_parsing_cpp let test_tokens_cpp file = Flag.verbose_lexing := true; Flag.verbose_parsing := true; let toks = Parse_cpp.tokens (Parsing_helpers.file file) in toks |> List.iter (fun x -> pr2_gen x); (...
1800184ae6255076beb530026b1e9a277db52c5daaf30694d5d52e558c51735f
patricoferris/ocaml-multicore-monorepo
zzz.ml
module Key = struct type t = Optint.Int63.t let compare = Optint.Int63.compare end module Job = struct type t = { time : float; thread : unit Suspended.t; } let compare a b = Float.compare a.time b.time end module Q = Psq.Make(Key)(Job) type t = { mutable sleep_queue: Q.t; mutable next_id : Op...
null
https://raw.githubusercontent.com/patricoferris/ocaml-multicore-monorepo/624b3293ee41e83736fe7ac3a79f810c2b70f68b/duniverse/eio/lib_eio/utils/zzz.ml
ocaml
This shouldn't happen, since any cancellation will happen in the same domain as the [pop].
module Key = struct type t = Optint.Int63.t let compare = Optint.Int63.compare end module Job = struct type t = { time : float; thread : unit Suspended.t; } let compare a b = Float.compare a.time b.time end module Q = Psq.Make(Key)(Job) type t = { mutable sleep_queue: Q.t; mutable next_id : Op...
2433081036addea6d24a48e7c280844656344420a8e25cdff9e6c497d8ef06e7
informatimago/lisp
source-test.lisp
-*- mode : lisp;coding : utf-8 -*- ;;;;************************************************************************** FILE : source-test.lisp ;;;;LANGUAGE: Common-Lisp ;;;;SYSTEM: Common-Lisp USER - INTERFACE : ;;;;DESCRIPTION ;;;; Test source.lisp ;;;; < PJB > < ...
null
https://raw.githubusercontent.com/informatimago/lisp/571af24c06ba466e01b4c9483f8bb7690bc46d03/tools/source-test.lisp
lisp
coding : utf-8 -*- ************************************************************************** LANGUAGE: Common-Lisp SYSTEM: Common-Lisp DESCRIPTION LEGAL This program is free software: you can redistribute it and/or modify (at your option) any later version. This program is distri...
FILE : source-test.lisp USER - INTERFACE : Test source.lisp < PJB > < > MODIFICATIONS 2015 - 02 - 23 < PJB > Created . AGPL3 Copyright 2015 - 2016 it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , e...
fe5ad7b4ad59aece87ad916bde5e694d8a41d026e081975aaae58b0b4a599e67
rwilcox/my-learnings-docs
learning_helm.md.rkt
#lang scribble/text @(require "scribble-utils.rkt") --- path: /learnings/helm title: Learning Helm --- # Table Of Contents <!-- toc --> # Intro / Why Automate Version handling, rollback, installation Templatize k8s resources, search and reuse templates ## components * helm client (CLI) * charts — application...
null
https://raw.githubusercontent.com/rwilcox/my-learnings-docs/8b312ae8940e5c7295b95e157a55c5a1a7074307/learning_helm.md.rkt
racket
all charts for a repo are listed in a single index you either have access to all charts in the repo or none of them
#lang scribble/text @(require "scribble-utils.rkt") --- path: /learnings/helm title: Learning Helm --- # Table Of Contents <!-- toc --> # Intro / Why Automate Version handling, rollback, installation Templatize k8s resources, search and reuse templates ## components * helm client (CLI) * charts — application...
d15ab25c63f259c6f1986eb30f9bf57cda6dc847698a5f6c449bcb61aa8591f5
dhess/sicp-solutions
ex2.62.scm
(define (union-set set1 set2) (cond ((null? set1) set2) ((null? set2) set1) (else (let ((x1 (car set1)) (x2 (car set2))) (cond ((= x1 x2) (cons x1 (union-set (cdr set1) (cdr set2)))) ((< x1 x2) (con...
null
https://raw.githubusercontent.com/dhess/sicp-solutions/2cf78db98917e9cb1252efda76fddc8e45fe4140/chap2/ex2.62.scm
scheme
(define (union-set set1 set2) (cond ((null? set1) set2) ((null? set2) set1) (else (let ((x1 (car set1)) (x2 (car set2))) (cond ((= x1 x2) (cons x1 (union-set (cdr set1) (cdr set2)))) ((< x1 x2) (con...
a88ede46d1a55d4ed7d698e015e83381a15bc3aa3b04985499f41f5da17a6dcd
huangjs/cl
zuchk.lisp
;;; Compiled by f2cl version: ( " f2cl1.l , v 1.215 2009/04/07 22:05:21 rtoy Exp $ " " f2cl2.l , v 1.37 2008/02/22 22:19:33 rtoy Exp $ " " f2cl3.l , v 1.6 2008/02/22 22:19:33 rtoy Exp $ " " f2cl4.l , v 1.7 2008/02/22 22:19:34 rtoy Exp $ " " f2cl5.l , v 1.200 2009/01/19 02:38:17 rtoy Exp $ " " f2cl6.l ,...
null
https://raw.githubusercontent.com/huangjs/cl/96158b3f82f82a6b7d53ef04b3b29c5c8de2dbf7/lib/maxima/src/numerical/slatec/zuchk.lisp
lisp
Compiled by f2cl version: Options: ((:prune-labels nil) (:auto-save t) (:relaxed-array-decls t) (:coerce-assigns :as-needed) (:array-type ':simple-array) (:array-slicing nil) (:declare-common nil) (:float-format double-float))
( " f2cl1.l , v 1.215 2009/04/07 22:05:21 rtoy Exp $ " " f2cl2.l , v 1.37 2008/02/22 22:19:33 rtoy Exp $ " " f2cl3.l , v 1.6 2008/02/22 22:19:33 rtoy Exp $ " " f2cl4.l , v 1.7 2008/02/22 22:19:34 rtoy Exp $ " " f2cl5.l , v 1.200 2009/01/19 02:38:17 rtoy Exp $ " " f2cl6.l , v 1.48 2008/08/24 00:56:27 rt...
4c87f8c3025a082cec78150a6313b28431bf548f0ce2c46273647c32d3ad7cb5
sunshineclt/Racket-Helper
homework11-2.rkt
#lang racket ;basic amb evaluator (require racket/mpair) (define (my-display x) (cond ((and (mpair? x) (eq? (mcar x) 'primitive)) (display (get-list-head x 2))) ((and (pair? x) (eq? (car x) 'procedure)) (display (get-list-head x 3))) (else (display x)))) (define (my-newline) (newli...
null
https://raw.githubusercontent.com/sunshineclt/Racket-Helper/bf85f38dd8d084db68265bb98d8c38bada6494ec/%E9%99%88%E4%B9%90%E5%A4%A9/Week11/homework11-2.rkt
racket
basic amb evaluator (my-driver-loop)
#lang racket (require racket/mpair) (define (my-display x) (cond ((and (mpair? x) (eq? (mcar x) 'primitive)) (display (get-list-head x 2))) ((and (pair? x) (eq? (car x) 'procedure)) (display (get-list-head x 3))) (else (display x)))) (define (my-newline) (newline)) (define (simple...
917bea59820db18f9cd20711d0b210897e1ccb3b120201045a7ff081e2cf2e4c
BrunoBonacci/mulog
cloudwatch_test.clj
(ns com.brunobonacci.mulog.publishers.cloudwatch.cloudwatch-test (:require [com.brunobonacci.mulog :as u] [com.brunobonacci.mulog.publishers.cloudwatch.test-publisher :as tp] [midje.sweet :refer :all])) (fact "publish to local cloudwatch logs service and assert the published message" (tp...
null
https://raw.githubusercontent.com/BrunoBonacci/mulog/e31f84ccf6d62d43c1c620ef5584722886e0d8a5/mulog-cloudwatch/test/com/brunobonacci/mulog/publishers/cloudwatch/cloudwatch_test.clj
clojure
(ns com.brunobonacci.mulog.publishers.cloudwatch.cloudwatch-test (:require [com.brunobonacci.mulog :as u] [com.brunobonacci.mulog.publishers.cloudwatch.test-publisher :as tp] [midje.sweet :refer :all])) (fact "publish to local cloudwatch logs service and assert the published message" (tp...
5a69e7121babf72ac6ef02adb4830e59b2b1b546d899283225101271913cdffd
vonzhou/LearnYouHaskellForGreatGood
foo2.hs
foo :: Maybe String foo = do x <- Just 3 y <- Just "!" Just (show x ++ y) marySue :: Maybe Bool marySue = do x <- Just 9 Just (x > 8)
null
https://raw.githubusercontent.com/vonzhou/LearnYouHaskellForGreatGood/439d848deac53ef6da6df433078b7f1dcf54d18d/chapter13/foo2.hs
haskell
foo :: Maybe String foo = do x <- Just 3 y <- Just "!" Just (show x ++ y) marySue :: Maybe Bool marySue = do x <- Just 9 Just (x > 8)
947107ae235aea6c2d7fd6f4d750b922cf0f6c7ab4ffc40105ff27fe8c0ab748
timbod7/haskell-chart
Axis.hs
----------------------------------------------------------------------------- -- | -- Module : Graphics.Rendering.Chart.Axis Copyright : ( c ) 2006 -- License : BSD-style (see chart/COPYRIGHT) -- -- Code to calculate and render axes. -- module Graphics.Rendering.Chart.Axis( module Graphics.Rend...
null
https://raw.githubusercontent.com/timbod7/haskell-chart/8c5a823652ea1b4ec2adbced4a92a8161065ead6/chart/Graphics/Rendering/Chart/Axis.hs
haskell
--------------------------------------------------------------------------- | Module : Graphics.Rendering.Chart.Axis License : BSD-style (see chart/COPYRIGHT) Code to calculate and render axes.
Copyright : ( c ) 2006 module Graphics.Rendering.Chart.Axis( module Graphics.Rendering.Chart.Axis.Types, module Graphics.Rendering.Chart.Axis.Floating, module Graphics.Rendering.Chart.Axis.Int, module Graphics.Rendering.Chart.Axis.Time, module Graphics.Rendering.Chart.Axis.Unit, module...
b3aa7215696e9d1f27120e8baa7f65ccf512316a8bc55f1a17ffff71119c4321
spurious/sagittarius-scheme-mirror
basic-hash-tables.scm
-*- mode : scheme ; coding : utf-8 ; -*- ;;; ;;; SRFI-69 Basic hash tables ;;; Copyright ( c ) 2010 - 2015 < > ;;; ;;; Redistribution and use in source and binary forms, with or without ;;; modification, are permitted provided that the following conditions ;;; are met: ;;; ;;; 1. Redistribu...
null
https://raw.githubusercontent.com/spurious/sagittarius-scheme-mirror/53f104188934109227c01b1e9a9af5312f9ce997/sitelib/srfi/%253a69/basic-hash-tables.scm
scheme
coding : utf-8 ; -*- SRFI-69 Basic hash tables 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 of conditions ...
Copyright ( c ) 2010 - 2015 < > " 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 :69 basic-hash-tables) (exp...
20491f36fb16bf830d06529b8f914ff7a11bc1c7d78369ea34eb403dc8e00326
carl-eastlund/dracula
hash.rkt
#lang scheme (require "define.ss" (for-syntax syntax/parse)) (define-if-unbound (hash-has-key? table key) (let/ec return (hash-ref table key (lambda () (return #f))) #t)) (define-if-unbound (hash-equal? table) (and (hash? table) (not (hash-eq? table)) (not (hash-eqv? table)))) (define (has...
null
https://raw.githubusercontent.com/carl-eastlund/dracula/a937f4b40463779246e3544e4021c53744a33847/private/scheme/hash.rkt
racket
#lang scheme (require "define.ss" (for-syntax syntax/parse)) (define-if-unbound (hash-has-key? table key) (let/ec return (hash-ref table key (lambda () (return #f))) #t)) (define-if-unbound (hash-equal? table) (and (hash? table) (not (hash-eq? table)) (not (hash-eqv? table)))) (define (has...
1efe18ff6b602c0adc572718bd1cd50ce77d6ed4764f9ae64f804f1030f51e4d
wireapp/saml2-web-sso
Error.hs
# LANGUAGE GeneralizedNewtypeDeriving # {-# LANGUAGE OverloadedStrings #-} module SAML2.WebSSO.Error where import Data.String.Conversions import Data.Void (Void, absurd) import Servant.Server data Error err = UnknownIdP LT | Forbidden LT | BadSamlResponseBase64Error LT | BadSamlResponseXmlError LT | BadSam...
null
https://raw.githubusercontent.com/wireapp/saml2-web-sso/ac88b934bb4a91d4d4bb90c620277188e4087043/src/SAML2/WebSSO/Error.hs
haskell
# LANGUAGE OverloadedStrings # #4xx_Client_errors)
# LANGUAGE GeneralizedNewtypeDeriving # module SAML2.WebSSO.Error where import Data.String.Conversions import Data.Void (Void, absurd) import Servant.Server data Error err = UnknownIdP LT | Forbidden LT | BadSamlResponseBase64Error LT | BadSamlResponseXmlError LT | BadSamlResponseSamlError LT | BadSamlRe...
6a2a8596cfd5ad5ccc422bfa5d545ddbb776b643cad5842288e0762407a49be4
qitab/qmynd
command-initialize-database.lisp
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; ;;; Free Software published under an MIT - like license . See LICENSE ; ; ; ;;; ;;; Copyright ( c ) 2012 -...
null
https://raw.githubusercontent.com/qitab/qmynd/7e56daf73f0ed5f49a931c01af75fb874bcf3445/src/mysql-protocol/text-protocol/command-initialize-database.lisp
lisp
;;; ; ; ;;; ; ; ;;; ; ; ;;; 15.6.3 command-initia...
(in-package :qmynd-impl) ( ( tag : mysql - type ( integer 1 ) : value + mysql - command - initialize - database+ : transient t : bind nil ) Returns OK or ERR packet (defun send-command-initialize-database (schema-name) (mysql-command-init +mysql-command-initialize-database+) (mysql-write-packet (flex...
59242ec0356df563c31c8ca31c4b637d086466acbd808df241e067de75e5e9b2
HunterYIboHu/htdp2-solution
key-event-4.3.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-beginner-reader.ss" "lang")((modname key-event-4.3) (read-case-sensitive #t) (teachpacks ((lib "image.rkt" "teachpack" "2htdp") (lib "univ...
null
https://raw.githubusercontent.com/HunterYIboHu/htdp2-solution/6182b4c2ef650ac7059f3c143f639d09cd708516/Chapter1/Section4/key-event-4.3.rkt
racket
about the language level of this file in a form that our tools can easily process. 常量 Position is a Number interpretation distance between the left margin and the ball computes the next location of the ball Position -> Position (define (tock p) ... p ...) Position -> Image render the position to the BALL pla...
The first three lines of this file were inserted by . They record metadata #reader(lib "htdp-beginner-reader.ss" "lang")((modname key-event-4.3) (read-case-sensitive #t) (teachpacks ((lib "image.rkt" "teachpack" "2htdp") (lib "universe.rkt" "teachpack" "2htdp"))) (htdp-settings #(#t write repeating-decimal #f #t non...
3a706a74e8e462001f6d657be6c5027285d3d971b14cfad5b54a4391b9d973e2
plewto/Cadejo
overwrite_warning.clj
(ns cadejo.ui.util.overwrite-warning "Pops up confirmation dialog prior to overwriting existing file. Overwrite warnings may be disabled by config" (:require [cadejo.util.path :as path]) (:require [cadejo.config :as config]) (:use [seesaw.core])) (defn overwrite-warning ([parent file-type filename] ...
null
https://raw.githubusercontent.com/plewto/Cadejo/2a98610ce1f5fe01dce5f28d986a38c86677fd67/src/cadejo/ui/util/overwrite_warning.clj
clojure
(ns cadejo.ui.util.overwrite-warning "Pops up confirmation dialog prior to overwriting existing file. Overwrite warnings may be disabled by config" (:require [cadejo.util.path :as path]) (:require [cadejo.config :as config]) (:use [seesaw.core])) (defn overwrite-warning ([parent file-type filename] ...
7f408a1de69408c1fa7d458eb0266f362984cad0b30b87f2968ef4acb112118b
mbutterick/aoc-racket
day08.rkt
#lang scribble/lp2 @(require scribble/manual aoc-racket/helper) @aoc-title[8] @defmodule[aoc-racket/day08] @link[""]{The puzzle}. Our @link-rp["day08-input.txt"]{input} consists of a list of seemingly random strings within quotation marks. @chunk[<day08> <day08-setup> <day08-q1> <day08-q2> ...
null
https://raw.githubusercontent.com/mbutterick/aoc-racket/2c6cb2f3ad876a91a82f33ce12844f7758b969d6/day08.rkt
racket
#lang scribble/lp2 @(require scribble/manual aoc-racket/helper) @aoc-title[8] @defmodule[aoc-racket/day08] @link[""]{The puzzle}. Our @link-rp["day08-input.txt"]{input} consists of a list of seemingly random strings within quotation marks. @chunk[<day08> <day08-setup> <day08-q1> <day08-q2> ...
05bc39bbaa1563f337d36626b5ef64b406f0588a6c04b51fcc490de2379d9dbe
haskell-openal/OpenAL
QueryUtils.hs
# LANGUAGE CPP # {-# OPTIONS_HADDOCK hide #-} -------------------------------------------------------------------------------- -- | -- Module : Sound.OpenAL.AL.QueryUtils Copyright : ( c ) 2003 - 2016 -- License : BSD3 -- Maintainer : < > -- Stability : stable -- Portability : portable...
null
https://raw.githubusercontent.com/haskell-openal/OpenAL/5131984f172dffc43ca8b482f215d120523fb137/src/Sound/OpenAL/AL/QueryUtils.hs
haskell
# OPTIONS_HADDOCK hide # ------------------------------------------------------------------------------ | Module : Sound.OpenAL.AL.QueryUtils License : BSD3 Stability : stable Portability : portable ------------------------------------------------------------------------------ Make the foreign ...
# LANGUAGE CPP # Copyright : ( c ) 2003 - 2016 Maintainer : < > This is a purely internal module with utilities to query OpenAL state . module Sound.OpenAL.AL.QueryUtils ( GetPName(..), marshalGetPName, StringName(..), getString ) where #if __GLASGOW_HASKELL__ >= 704 import Foreign.C.Types #...
693f4b17b5deca01b96b62f6b7e9076f26c7d415581e958d92d743da7396f12e
DavidVujic/clojurescript-amplified
avatar_stories.cljs
(ns app.stories.avatar-stories (:require [app.components.user-avatar :as user-avatar] [app.stories.helper :as helper] [reagent.core :as reagent])) (def ^:export default (helper/->default {:title "An Avatar Component" :component user-avatar/user-avatar ...
null
https://raw.githubusercontent.com/DavidVujic/clojurescript-amplified/3a98ed2a86a1aba49fcc55f0ca1207731df32620/src/stories/app/stories/avatar_stories.cljs
clojure
(ns app.stories.avatar-stories (:require [app.components.user-avatar :as user-avatar] [app.stories.helper :as helper] [reagent.core :as reagent])) (def ^:export default (helper/->default {:title "An Avatar Component" :component user-avatar/user-avatar ...
8ce79b615ae7737dd740ce5814a56f38a82266e90c717f2620ffc4542d1a2fe3
mukul-rathi/bolt
test_remove_variable_shadowing.ml
open Core open Desugaring.Remove_variable_shadowing open Ast.Ast_types open Desugaring.Desugared_ast let print_error_string = function Ok _ -> "" | Error e -> Error.to_string_hum e let test_error_if_var_not_in_var_map () = let expected_error = Fmt.str "Error: no unique var name for (potentially) shadowed variab...
null
https://raw.githubusercontent.com/mukul-rathi/bolt/1faf19d698852fdb6af2ee005a5f036ee1c76503/tests/frontend/alcotest/desugaring/test_remove_variable_shadowing.ml
ocaml
open Core open Desugaring.Remove_variable_shadowing open Ast.Ast_types open Desugaring.Desugared_ast let print_error_string = function Ok _ -> "" | Error e -> Error.to_string_hum e let test_error_if_var_not_in_var_map () = let expected_error = Fmt.str "Error: no unique var name for (potentially) shadowed variab...
7404183ff3a625ce18c3f39cdd67475aaf2415b77b76ce5df9d2260090974d14
rd--/hsc3
F0.hs
| ( f0plugins ) module Sound.Sc3.Ugen.Bindings.Hw.External.F0 where import Sound.Sc3.Common.Rate import qualified Sound.Sc3.Ugen.Bindings.Hw.Construct as C import Sound.Sc3.Ugen.Ugen | Emulation of the sound generation hardware of the Atari TIA chip . atari2600 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen ->...
null
https://raw.githubusercontent.com/rd--/hsc3/024d45b6b5166e5cd3f0142fbf65aeb6ef642d46/Sound/Sc3/Ugen/Bindings/Hw/External/F0.hs
haskell
| POKEY Chip Sound Simulator | A phasor that can loop. | A phasor that can loop. Local Variables: truncate-lines:t End:
| ( f0plugins ) module Sound.Sc3.Ugen.Bindings.Hw.External.F0 where import Sound.Sc3.Common.Rate import qualified Sound.Sc3.Ugen.Bindings.Hw.Construct as C import Sound.Sc3.Ugen.Ugen | Emulation of the sound generation hardware of the Atari TIA chip . atari2600 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen ->...
79c7dca8519342b23f647a2fec8de33326ed1f2821fa22f354b3d70fea1d0529
Tritlo/dynamic-haskell-plugin
Plugin.hs
Copyright ( c ) 2020 - 2021 # LANGUAGE LambdaCase # # LANGUAGE TypeFamilies # # LANGUAGE DataKinds # # LANGUAGE RecordWildCards # # LANGUAGE TupleSections # # LANGUAGE CPP # # LANGUAGE FlexibleContexts # # LANGUAGE ScopedTypeVariables # # LANGUAGE PolyKinds # # LANGUAGE PatternSynonyms # # LANGUAGE TypeApplication...
null
https://raw.githubusercontent.com/Tritlo/dynamic-haskell-plugin/4e0e57bcdf3b88137140cff436253fc6bfd85807/Data/Dynamic/Plugin.hs
haskell
------------------------------------------------------------------------------ Exported kind in a constraint to the given value, i.e. if there is an instance Default k for and a is a free type variable of kind k in constraint c, then a ~ Default k will be added to the context of c, and values back to static values...
Copyright ( c ) 2020 - 2021 # LANGUAGE LambdaCase # # LANGUAGE TypeFamilies # # LANGUAGE DataKinds # # LANGUAGE RecordWildCards # # LANGUAGE TupleSections # # LANGUAGE CPP # # LANGUAGE FlexibleContexts # # LANGUAGE ScopedTypeVariables # # LANGUAGE PolyKinds # # LANGUAGE PatternSynonyms # # LANGUAGE TypeApplication...
3937b198122da2c16c6192e83d1519795ffdbc07d8665d52a65aedad9477f8a1
instedd/planwise
ident.clj
(ns planwise.model.ident (:require [schema.core :as s] [planwise.model.users :refer [User]])) (def Ident "User identity as found in the session cookie and JWE tokens" {:user-id s/Int :user-email s/Str JWE tokens might include expiration information (s/optional-key :exp...
null
https://raw.githubusercontent.com/instedd/planwise/1bc2a5742ae3dc377dddf1f9e9bb60f0d2f59084/src/planwise/model/ident.clj
clojure
User identity related functions The user identity is the user information carried around in the session
(ns planwise.model.ident (:require [schema.core :as s] [planwise.model.users :refer [User]])) (def Ident "User identity as found in the session cookie and JWE tokens" {:user-id s/Int :user-email s/Str JWE tokens might include expiration information (s/optional-key :exp...
ea738b4c34dd4c11407aeab507c44ddfcf3d21db4b0639022b857d514cc27ff6
unnohideyuki/Tiger-in-Haskell
Semant.hs
module Semant where import Debug.Trace import qualified Data.List as List import qualified Absyn as A import qualified Env as E import qualified Symbol as S import qualified Types as T import qualified Translate as TL import qualified Temp import qualified DalvikFrame as Frame type VEnv = S.Table E.EnvEntry type TEn...
null
https://raw.githubusercontent.com/unnohideyuki/Tiger-in-Haskell/69fc976e64bfe7abfa842d7179e06eae740d36b9/final/src/Semant.hs
haskell
level'' TODO: check level''? translate to let/while expresion dirty hack: generate a unique number from the position. must not reach here? inserting headers A.func_body=body, level level not used? level (not level') should be returned here.
module Semant where import Debug.Trace import qualified Data.List as List import qualified Absyn as A import qualified Env as E import qualified Symbol as S import qualified Types as T import qualified Translate as TL import qualified Temp import qualified DalvikFrame as Frame type VEnv = S.Table E.EnvEntry type TEn...
caee701dce4dd15e8a0ae6736de156b303ed046c0789c665e1a8c17a66f7a124
gsakkas/rite
3021.ml
let pipe fs = let f a x a = a in let base = 0 in List.fold_left f base fs;; fix let pipe fs = let f a x a = a in let base x = x in List.fold_left f base fs ; ; let pipe fs = let f a x a = a in let base x = x in List.fold_left f base fs;; *) changed spans ( 2,45)-(2,46 ) fun x - > x LamG VarPatG Va...
null
https://raw.githubusercontent.com/gsakkas/rite/958a0ad2460e15734447bc07bd181f5d35956d3b/data/sp14/3021.ml
ocaml
let pipe fs = let f a x a = a in let base = 0 in List.fold_left f base fs;; fix let pipe fs = let f a x a = a in let base x = x in List.fold_left f base fs ; ; let pipe fs = let f a x a = a in let base x = x in List.fold_left f base fs;; *) changed spans ( 2,45)-(2,46 ) fun x - > x LamG VarPatG Va...
810e181b841c2c24ac6dda4b2bcff1d91fc2d0a038bfa1e4862149088dab2404
haskell-github/github
CommitsSpec.hs
{-# LANGUAGE OverloadedStrings #-} module GitHub.CommitsSpec where import GitHub.Auth (Auth (..)) import GitHub.Endpoints.Repos.Commits (commitSha, commitsForR, diffR, mkCommitName, FetchCount (..)) import GitHub.Request (github) import Control.Monad (forM_) import Data.Either....
null
https://raw.githubusercontent.com/haskell-github/github/d9ac0c7ffbcc720a24d06f0a96ea4e3891316d1a/spec/GitHub/CommitsSpec.hs
haskell
# LANGUAGE OverloadedStrings # diff that includes a commit where a submodule is removed
module GitHub.CommitsSpec where import GitHub.Auth (Auth (..)) import GitHub.Endpoints.Repos.Commits (commitSha, commitsForR, diffR, mkCommitName, FetchCount (..)) import GitHub.Request (github) import Control.Monad (forM_) import Data.Either.Compat (isRight) import Data.List ...
5ec21a05b573537842b698ce129e639084d52da7f51e4464ff9b60efc337b80e
onedata/op-worker
dbsync_events.erl
%%%------------------------------------------------------------------- @author ( C ) 2017 ACK CYFRONET AGH This software is released under the MIT license cited in ' LICENSE.txt ' . %%% @end %%%------------------------------------------------------------------- @doc DBSync hooks . %%% @end %%%-------------...
null
https://raw.githubusercontent.com/onedata/op-worker/c43c9ffd9aa76b309b5140fa94fa0da06c9d719f/src/modules/dbsync/dbsync_events.erl
erlang
------------------------------------------------------------------- @end ------------------------------------------------------------------- @end ------------------------------------------------------------------- API =================================================================== API ==========================...
@author ( C ) 2017 ACK CYFRONET AGH This software is released under the MIT license cited in ' LICENSE.txt ' . @doc DBSync hooks . -module(dbsync_events). -author("Rafal Slota"). -include("modules/datastore/datastore_models.hrl"). -include("modules/fslogic/fslogic_common.hrl"). -include_lib("ctool/include...
b34d14b4158cab1847f1dcaf62590785d44177cbe578af922d5cabb0edfeda37
fffej/clojure-snippets
bloom.clj
(ns bloom (:use bitarray) (:use clojure.test) (:import (java.security MessageDigest))) (defn pad [n s] (let [padding (- n (count s))] (apply str (concat (apply str (repeat padding "0")) s)))) (defn md5-hash [s] (let [m (MessageDigest/getInstance "MD5")] (.update m (.getBytes (str s)) 0 (count s)) ...
null
https://raw.githubusercontent.com/fffej/clojure-snippets/bf2e04502da88e4ecba8d4e4ffe9012f3984d451/bloom.clj
clojure
(ns bloom (:use bitarray) (:use clojure.test) (:import (java.security MessageDigest))) (defn pad [n s] (let [padding (- n (count s))] (apply str (concat (apply str (repeat padding "0")) s)))) (defn md5-hash [s] (let [m (MessageDigest/getInstance "MD5")] (.update m (.getBytes (str s)) 0 (count s)) ...
3910a7dab036237125e9f5d7d7660454ae3fc8a41be011c19c6f05567bd04147
bootstrapworld/curr
GameTemplate.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-beginner-reader.ss" "lang")((modname GameTemplate) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-deci...
null
https://raw.githubusercontent.com/bootstrapworld/curr/443015255eacc1c902a29978df0e3e8e8f3b9430/courses/reactive/resources/source-files/GameTemplate.rkt
racket
about the language level of this file in a form that our tools can easily process. DATA: define-struct: STARTING WORLD GRAPHICS GRAPHICS FUNCTIONS: draw-world: world -> Image UPDATING FUNCTIONS: update-world: world -> world What does your update-world function do? KEY EVENTS: keypress: world string -> w...
The first three lines of this file were inserted by . They record metadata #reader(lib "htdp-beginner-reader.ss" "lang")((modname GameTemplate) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #f #t none #f ()))) (require "Teachpacks/bootstrap-teachpack.rkt") The World is...
3045aa0cede83d7bdaf321e8d8367b9b9946fd0b5720b2a1eadc77d0d56824ed
logicmoo/logicmoo_nlu
dagunify.lsp
;;; % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % Example code from the book " Natural Language Processing in LISP " % % published by % % Copyright ( c ) 1989 , . % ;;; % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % %...
null
https://raw.githubusercontent.com/logicmoo/logicmoo_nlu/c066897f55b3ff45aa9155ebcf799fda9741bf74/ext/nlp_book/lisp/dagunify.lsp
lisp
% % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % % dagunify.lsp [Chapter 7] unification for dags This library file provides the following utilities for operating (unify dag1 dag2) returns substitution/nil; (simplify...
% Example code from the book " Natural Language Processing in LISP " % % published by % % Copyright ( c ) 1989 , . % (uses 'subst) on : ( GET_VALUE feature dag subst1 ) returns ( value subst2 ) ( PUT_VALUE_IN ( feature value ) dag subst1 ) returns ( subst2...
bb51c3bb8e7a14e648f33dc5ae13fa6aef9d5bdb4b6cc3e486f786fdf22fc0b2
slipstream/SlipStreamServer
session_template_oidc_lifecycle_test.clj
(ns com.sixsq.slipstream.ssclj.resources.session-template-oidc-lifecycle-test (:require [clojure.test :refer :all] [com.sixsq.slipstream.ssclj.app.params :as p] [com.sixsq.slipstream.ssclj.resources.common.utils :as u] [com.sixsq.slipstream.ssclj.resources.lifecycle-test-utils :as ltu] [com.sixsq....
null
https://raw.githubusercontent.com/slipstream/SlipStreamServer/3ee5c516877699746c61c48fc72779fe3d4e4652/cimi/test/com/sixsq/slipstream/ssclj/resources/session_template_oidc_lifecycle_test.clj
clojure
(ns com.sixsq.slipstream.ssclj.resources.session-template-oidc-lifecycle-test (:require [clojure.test :refer :all] [com.sixsq.slipstream.ssclj.app.params :as p] [com.sixsq.slipstream.ssclj.resources.common.utils :as u] [com.sixsq.slipstream.ssclj.resources.lifecycle-test-utils :as ltu] [com.sixsq....
2c04cbc9977f70a7db20b2f4ae835484c2c462c6c1e0d62d42630d1cf91ee789
albertov/bindings-gdal
OGRFieldInstances.hs
# OPTIONS_GHC -fno - warn - orphans # # LANGUAGE CPP # # LANGUAGE FlexibleInstances # # LANGUAGE ScopedTypeVariables # {-# LANGUAGE OverloadedStrings #-} module GDAL.Internal.OGRFieldInstances () where #include "bindings.h" import Data.ByteString (ByteString) import Data.Int import Data.Word import Data.Monoid (memp...
null
https://raw.githubusercontent.com/albertov/bindings-gdal/f91087e06a569fc6dc81b4c22e58b5c9a1dcdc73/src/GDAL/Internal/OGRFieldInstances.hs
haskell
# LANGUAGE OverloadedStrings #
# OPTIONS_GHC -fno - warn - orphans # # LANGUAGE CPP # # LANGUAGE FlexibleInstances # # LANGUAGE ScopedTypeVariables # module GDAL.Internal.OGRFieldInstances () where #include "bindings.h" import Data.ByteString (ByteString) import Data.Int import Data.Word import Data.Monoid (mempty, (<>)) import Data.Proxy (Proxy(...
225b39edc522d487c13b385279da253f5e5e4f13b6ca47fefec5db18e78e297b
kthielen/stlcc
InstCFG.hs
module ASM.InstCFG where import ASM.Type import ASM.Term import ASM.Liveness import Util.Annotated import Util.CFG import Util.Sequence import Util.Num import Util.Tuples import Util.Recursion import qualified Data.Map as Map block_reg_refs :: (Annotation a, Eq a) => BBlock (Inst a) -> [Reg a] block...
null
https://raw.githubusercontent.com/kthielen/stlcc/369492daad6498a93c00f5924a99ceb65b5f1062/ASM/InstCFG.hs
haskell
---- better register spilling add a prolog/epilog to allocate local variables and preserve callee-save registers also, commit stack frame references to actual offsets against the sp register produces the code to initialize a call frame produces the code to uninitialize a call frame optionally trimming the stack...
module ASM.InstCFG where import ASM.Type import ASM.Term import ASM.Liveness import Util.Annotated import Util.CFG import Util.Sequence import Util.Num import Util.Tuples import Util.Recursion import qualified Data.Map as Map block_reg_refs :: (Annotation a, Eq a) => BBlock (Inst a) -> [Reg a] block...
a5bd8a4751d9d0192ea8c18206c65ebcfaddbcc5ee59b034f63655a9adc764ca
soren-n/bidi-higher-rank-poly
Set.ml
open Extra type 'a set = 'a AVL.tree let make = AVL.make_null let is_empty set = (AVL.get_count set) = 0 let is_member = AVL.is_member let get_member = AVL.get_member let size = AVL.get_count let add = AVL.insert let remove = AVL.remove let to_list = AVL.to_list let from_list = AVL.from_list let fold empty_case item...
null
https://raw.githubusercontent.com/soren-n/bidi-higher-rank-poly/c0957759657b30a52235560d1d5f40e9bd2569b3/util/lib/Set.ml
ocaml
open Extra type 'a set = 'a AVL.tree let make = AVL.make_null let is_empty set = (AVL.get_count set) = 0 let is_member = AVL.is_member let get_member = AVL.get_member let size = AVL.get_count let add = AVL.insert let remove = AVL.remove let to_list = AVL.to_list let from_list = AVL.from_list let fold empty_case item...
400e32a83b80c8e00eb31604f40b73a53502e821b5e95bc2acb3884aa7e20450
gfour/gic
myex5.hs
result = fib 5; fib n = if n <= 1 then 1 else fib(n-1) + fib(n-2) " result " = CALL ( 0,"fib_n__0 " ) ( " fib " ) " fib " = " if " [ " < = " [ ARG 0 0,"1 " ] , " 1 " , " + " [ CALL ( 0,"fib_n__1 " ) ( " fib"),CALL ( 0,"fib_n__2 " ) ( " fib " ) ] ] " fib_n__0 " = SAVE ( 0,0 ) ACT_0 " 2 " " fib_n__1 " = SA...
null
https://raw.githubusercontent.com/gfour/gic/d5f2e506b31a1a28e02ca54af9610b3d8d618e9a/Examples/Num/myex5.hs
haskell
result = fib 5; fib n = if n <= 1 then 1 else fib(n-1) + fib(n-2) " result " = CALL ( 0,"fib_n__0 " ) ( " fib " ) " fib " = " if " [ " < = " [ ARG 0 0,"1 " ] , " 1 " , " + " [ CALL ( 0,"fib_n__1 " ) ( " fib"),CALL ( 0,"fib_n__2 " ) ( " fib " ) ] ] " fib_n__0 " = SAVE ( 0,0 ) ACT_0 " 2 " " fib_n__1 " = SA...
91ed754c3691cc6fefd523bf52fe50c306b8063f3b41fca2caec94361c794fc4
copumpkin/java
Raw.hs
# LANGUAGE TemplateHaskell # {-# OPTIONS_GHC -funbox-strict-fields #-} module Java.ClassFormat.Raw where import Data.Int import Data.Word import qualified Data.Text as T import qualified Data.ByteString as B import qualified Data.ByteString.Lazy as BL import qualified Data.Vector as V import qualified Data.Vector.Unbo...
null
https://raw.githubusercontent.com/copumpkin/java/ca5ecc025eef4463ef5f0f33e6873707aeb88bd9/src/Java/ClassFormat/Raw.hs
haskell
# OPTIONS_GHC -funbox-strict-fields # exactly one 49.0 or above 49.0 or above 49.0 or above native / abstract = 0 , otherwise = 1 49.0 or above 49.0 or above 49.0 or above 49.0 or above 49.0 or above 49.0 or above 49.0 or above 49.0 or above 49.0 or above 51.0 or above 50.0 or above ign...
# LANGUAGE TemplateHaskell # module Java.ClassFormat.Raw where import Data.Int import Data.Word import qualified Data.Text as T import qualified Data.ByteString as B import qualified Data.ByteString.Lazy as BL import qualified Data.Vector as V import qualified Data.Vector.Unboxed as U import qualified Data.IntMap as I...
b1fca81351f861046ded6a56584a83e7c9d80dc3d44debddce1bec0a50cbccdc
cloojure/tupelo
set.cljc
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) 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 th...
null
https://raw.githubusercontent.com/cloojure/tupelo/e7b5d216ba12d775a968baf445cebde8be9faa8f/src/cljc/tupelo/set.cljc
clojure
(-1.0.php) which can be found in the file epl-v10.html at the root of this distribution. By using this software in any fashion, you are agreeing to be bound by the terms of this license. You must not remove this notice, or any other, from this software. ----------------------------------------------------...
Copyright ( c ) . All rights reserved . The use and distribution terms for this software are covered by the Eclipse Public License 1.0 (ns tupelo.set "Tupelo - Making Clojure even sweeter" (:refer-clojure :exclude [remove]) (:require [clojure.set] [schema.core :as s] )) # todo wrap these ...
78f51d44df77a2be035d945131e33d565e68141dafe849c41360096ed061a5a4
metametadata/carry
actions.cljs
(ns app.actions (:require [datascript.core :as d] [cljs.core.match :refer-macros [match]])) (defn -update-db [model tx-data] (update model :db d/db-with tx-data)) (defn on-action [model action] (println " action" action) (match action [:receive-products tx-data] (assoc model...
null
https://raw.githubusercontent.com/metametadata/carry/fa5c7cd0d8f1b71edca70330acc97c6245638efb/examples/shopping-cart/src/app/actions.cljs
clojure
(ns app.actions (:require [datascript.core :as d] [cljs.core.match :refer-macros [match]])) (defn -update-db [model tx-data] (update model :db d/db-with tx-data)) (defn on-action [model action] (println " action" action) (match action [:receive-products tx-data] (assoc model...
cfac5bb574fb7d440c372439198b10a2265cd8db290d5227918520031d917d9b
ralsei/sawzall
info.rkt
#lang info (define collection "sawzall-test") (define test-omit-paths '("./info.rkt" "./test-data.rkt")) (define test-responsibles '((all ))) (define pkg-desc "Tests for Sawzall") (define version "1.0") (define deps '("base" "data-frame" "rackunit-lib" "sawzall-lib" ...
null
https://raw.githubusercontent.com/ralsei/sawzall/fb414abf103d8dc8fca0e8e8ea061a81e207a358/sawzall-test/info.rkt
racket
#lang info (define collection "sawzall-test") (define test-omit-paths '("./info.rkt" "./test-data.rkt")) (define test-responsibles '((all ))) (define pkg-desc "Tests for Sawzall") (define version "1.0") (define deps '("base" "data-frame" "rackunit-lib" "sawzall-lib" ...
8d40672cc66899a56d4d85b36c1a38500ff13a3265e632e13815e4c389913c2d
aloiscochard/codec-jvm
ConstPool.hs
module Codec.JVM.ConstPool where import Control.Monad (join) import Data.Binary.Put (Put, putByteString, putWord8, putWord16be) import Data.Map.Strict (Map) import Data.Text.Encoding (encodeUtf8) import qualified Data.List as L import qualified Data.Map.Strict as M import qualified Data.Text as T import Codec.JVM.Co...
null
https://raw.githubusercontent.com/aloiscochard/codec-jvm/2e5b73a3eb35620ae49216c8c12f0bec82bcbe26/src/Codec/JVM/ConstPool.hs
haskell
module Codec.JVM.ConstPool where import Control.Monad (join) import Data.Binary.Put (Put, putByteString, putWord8, putWord16be) import Data.Map.Strict (Map) import Data.Text.Encoding (encodeUtf8) import qualified Data.List as L import qualified Data.Map.Strict as M import qualified Data.Text as T import Codec.JVM.Co...
77009edbb59f5429318c8f3ec0ee3ced52beeba264afc825bf14a264517fc691
lemmih/lhc
Reverse.hs
module Main where import LHC.Prim import LHC.Prelude main :: IO () main = putStrLn (showInt (last (reverse longList))) longList :: [Int] longList = replicate 2000 0 entrypoint :: () entrypoint = unsafePerformIO main
null
https://raw.githubusercontent.com/lemmih/lhc/53bfa57b9b7275b7737dcf9dd620533d0261be66/examples/Reverse.hs
haskell
module Main where import LHC.Prim import LHC.Prelude main :: IO () main = putStrLn (showInt (last (reverse longList))) longList :: [Int] longList = replicate 2000 0 entrypoint :: () entrypoint = unsafePerformIO main