_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 |
|---|---|---|---|---|---|---|---|---|
ac48a7e4e99fb28e9ce5e809d75ecb8ec7a1902624a2a83dccf98167f6f1c9ec | swarm-game/swarm | Typed.hs | # LANGUAGE TemplateHaskell #
-- |
SPDX - License - Identifier : BSD-3 - Clause
module Swarm.Language.Typed (Typed (..), value, polytype, requires) where
import Control.Lens (makeLenses)
import Data.Aeson (ToJSON)
import Data.Aeson.Types (FromJSON)
import GHC.Generics (Generic)
import Swarm.Language.Requirement (Req... | null | https://raw.githubusercontent.com/swarm-game/swarm/affc8668b77b7e85d3d23c182a5159df36d17306/src/Swarm/Language/Typed.hs | haskell | |
| A value, or a hole, or something else that has its type & requirements fixed | # LANGUAGE TemplateHaskell #
SPDX - License - Identifier : BSD-3 - Clause
module Swarm.Language.Typed (Typed (..), value, polytype, requires) where
import Control.Lens (makeLenses)
import Data.Aeson (ToJSON)
import Data.Aeson.Types (FromJSON)
import GHC.Generics (Generic)
import Swarm.Language.Requirement (Requirem... |
46f40f5641b94cbe0dbdb23029ba4bea1c88e2bd2c5cea215f0119823b3fb416 | ocaml/ocaml-lsp | json_gen.mli | val json_t : Ml.Type.t
val add_json_conv_for_t :
Ml.Module.sig_ Ml.Module.t -> Ml.Module.sig_ Ml.Module.t
module Enum : sig
val conv :
allow_other:bool
-> poly:bool
-> (string * Ts_types.Literal.t) list Named.t
-> Ml.Expr.toplevel Named.t list
end
module Poly_variant : sig
val of_json : Ml.T... | null | https://raw.githubusercontent.com/ocaml/ocaml-lsp/b5c482491743187750b631de2983395154f02895/lsp/bin/ocaml/json_gen.mli | ocaml | val json_t : Ml.Type.t
val add_json_conv_for_t :
Ml.Module.sig_ Ml.Module.t -> Ml.Module.sig_ Ml.Module.t
module Enum : sig
val conv :
allow_other:bool
-> poly:bool
-> (string * Ts_types.Literal.t) list Named.t
-> Ml.Expr.toplevel Named.t list
end
module Poly_variant : sig
val of_json : Ml.T... | |
6962a11e436a9280c61f36c3c3f71459c61f956a7f2dd9ffd5a027aa5401216f | Deep-Symmetry/afterglow | show.clj | (ns afterglow.show
"Encapsulates a synchronized light show, executing a varying
collection of effects with output to a number of DMX universes.
Assumes control of the assigned universes, so only one show at a
time should be assigned a given universe. Of course, you can stack
as many effects as you'd like in t... | null | https://raw.githubusercontent.com/Deep-Symmetry/afterglow/5688e44e265a0e91248d1d42041d89d383dc687d/src/afterglow/show.clj | clojure | this
All went well
TODO: Since we are already using core.async elsewhere, it would be nice to
remove that dependency (and conceptual complexity) from the project.
to do that.
If assigner returned nil value, it wants to be skipped
Just means the show was stopped
We have not been shut down
TODO: Shou... | (ns afterglow.show
"Encapsulates a synchronized light show, executing a varying
collection of effects with output to a number of DMX universes.
Assumes control of the assigned universes, so only one show at a
time should be assigned a given universe. Of course, you can stack
as many effects as you'd like in t... |
f9acd0584cf53dc2d8d29dde9c17e0f45fcc9abda053606d4278d8d4951de488 | FreeProving/free-compiler | Encoder.hs | {-# LANGUAGE OverloadedStrings #-}
# LANGUAGE TypeApplications #
# OPTIONS_GHC -Wno - orphans #
| This module contains functions for encoding ' ModuleInterface 's in JSON
-- and writing them to @.json@ files.
--
Encoding module interfaces as TOML files is not supported , since TOML is
-- intended for human ... | null | https://raw.githubusercontent.com/FreeProving/free-compiler/6931b9ca652a185a92dd824373f092823aea4ea9/src/lib/FreeC/Environment/ModuleInterface/Encoder.hs | haskell | # LANGUAGE OverloadedStrings #
and writing them to @.json@ files.
intended for human maintained configuration files (e.g., the module
the interface file format.
| The version number of the module interface file format.
Remember to keep this in sync with the version number specified in
a breaking cha... | # LANGUAGE TypeApplications #
# OPTIONS_GHC -Wno - orphans #
| This module contains functions for encoding ' ModuleInterface 's in JSON
Encoding module interfaces as TOML files is not supported , since TOML is
interface of the @Prelude@ ) only .
See " FreeC.Environment . ModuleInterface . Decoder " for ... |
694f95819ec77157b9f0d840f1e389c762736926bd176680365e914909df53ad | silky/myth | timeout.ml | open Unix
type t = { base : float; timeout : float }
exception Timeout_exception
let unlimited : t = { base = 0.0; timeout = -1.0 }
let create (period:float) : t = { base = gettimeofday (); timeout = period }
let check_timeout (tmo:t) =
if tmo.timeout > 0.0 && gettimeofday () -. tmo.base > tmo.timeout then
rais... | null | https://raw.githubusercontent.com/silky/myth/b631edefb2a27a1d731daa6654517d91ca660b95/src/timeout.ml | ocaml | open Unix
type t = { base : float; timeout : float }
exception Timeout_exception
let unlimited : t = { base = 0.0; timeout = -1.0 }
let create (period:float) : t = { base = gettimeofday (); timeout = period }
let check_timeout (tmo:t) =
if tmo.timeout > 0.0 && gettimeofday () -. tmo.base > tmo.timeout then
rais... | |
b23f5f326869d0cf29d74115703940d7f3d4c43bf799b5933ecdb3ab4d45e3e2 | kraison/langutils | file.lisp | -*- Mode : Lisp ; Syntax : ANSI - Common - Lisp ; Base : 10 ; Package : utils -*-
;;;; *************************************************************************
;;;; FILE IDENTIFICATION
;;;;
;;;; Name: file.lisp
;;;; Purpose: File related utility functions
Programmer :
Date Started : Augus... | null | https://raw.githubusercontent.com/kraison/langutils/2c75cf08c9dbaf22ed7209c485b7157e5ab5143a/stdutils/file.lisp | lisp | Syntax : ANSI - Common - Lisp ; Base : 10 ; Package : utils -*-
*************************************************************************
FILE IDENTIFICATION
Name: file.lisp
Purpose: File related utility functions
Slurp
With and do macros on files as streams
returning the last line read
... | Programmer :
Date Started : August 2004
(in-package :stdutils)
Operations over files
(defun split-file (infile outfile1 outfile2 &key (type :half))
"Allows you to split a file by :alternate lines or to split
it in half by length"
(with-open-file (in infile :direction :input)
(with-open-file... |
ae146fcdffe976c517db5eedaf3378fb35eadc216c8cc8a353b15e145a570626 | ultralisp/ultralisp | github.lisp | (defpackage #:ultralisp/utils/github
(:use #:cl)
(:import-from #:cl-ppcre)
(:import-from #:github)
(:import-from #:rutils
#:fmt)
(:import-from #:ultralisp/utils/http
#:get-json)
(:import-from #:trivial-timeout
#:with-timeout)
(:import-from #:dexador
... | null | https://raw.githubusercontent.com/ultralisp/ultralisp/6d7b50a3398d8464017699c2baff89f02441b387/src/utils/github.lisp | lisp | These topics are too generic for a site about Common Lisp packages: | (defpackage #:ultralisp/utils/github
(:use #:cl)
(:import-from #:cl-ppcre)
(:import-from #:github)
(:import-from #:rutils
#:fmt)
(:import-from #:ultralisp/utils/http
#:get-json)
(:import-from #:trivial-timeout
#:with-timeout)
(:import-from #:dexador
... |
ddf0e9188eb8e94ef47a7bf118a9c9bef86cc79888354ed2aa87424fc2f278c7 | aeternity/aeternity | aec_metrics_test_utils.erl | -module(aec_metrics_test_utils).
-export([make_port_map/2,
port_map/1,
maybe_set_statsd_port_in_user_config/3,
start_statsd_loggers/1,
stop_statsd_loggers/0,
fetch_data/0]).
make_port_map(Devs, Config) ->
Ports = case os:getenv("AE_STATSD_PORTS") of
fal... | null | https://raw.githubusercontent.com/aeternity/aeternity/b7ce6ae15dab7fa22287c2da3d4405c29bb4edd7/apps/aecore/test/aec_metrics_test_utils.erl | erlang | -module(aec_metrics_test_utils).
-export([make_port_map/2,
port_map/1,
maybe_set_statsd_port_in_user_config/3,
start_statsd_loggers/1,
stop_statsd_loggers/0,
fetch_data/0]).
make_port_map(Devs, Config) ->
Ports = case os:getenv("AE_STATSD_PORTS") of
fal... | |
1e44ffde1aefaa8a911a2e93232c0907b3b234b7fb9144355f58bad2e61faed0 | hopv/MoCHi | sexp.ml | open Util
open Combinator
(** S-expressions *)
type t = S of string | L of t list
let rec pr ppf = function
| S(str) -> Format.fprintf ppf "%a" String.pr str
| L(es) -> Format.fprintf ppf "(%a)" (List.pr_app pr "@ ") es
| null | https://raw.githubusercontent.com/hopv/MoCHi/b0ac0d626d64b1e3c779d8e98cb232121cc3196a/fpat/sexp.ml | ocaml | * S-expressions | open Util
open Combinator
type t = S of string | L of t list
let rec pr ppf = function
| S(str) -> Format.fprintf ppf "%a" String.pr str
| L(es) -> Format.fprintf ppf "(%a)" (List.pr_app pr "@ ") es
|
a80acff2a47893dcb01adcdb366a740dfc2dab44698895d4c422acb644eb6fab | moon-chilled/loop | loop4.scm | ;-*- Mode: Lisp -*-
Author :
Created : Sun Oct 27 22:46:39 2002
;;;; Contains: Tests for LOOP FOR-AS-EQUAL-THEN
(deftest loop.4.1
(loop
for x = 1 then (+ 1 x)
until (> x 5)
collect x)
(1 2 3 4 5))
(deftest loop.4.2
(loop
for i from 1 to 10
for j = (+ 1 i) collect j)
(2 3 4 5 6 7 ... | null | https://raw.githubusercontent.com/moon-chilled/loop/09b08a5f0c442710f129d2de10d78128e21863a3/test/loop4.scm | scheme | -*- Mode: Lisp -*-
Contains: Tests for LOOP FOR-AS-EQUAL-THEN
this one is quite clever. But, cdr/car of nil in scheme...
(deftest loop.4.5
(loop for (x . y) = '(a b c d e) then y
while x
collect x)
(a b c d e))
Error cases
(deftest loop.4.6
(signals-error
(loop for (x . x) = '(nil ni... | Author :
Created : Sun Oct 27 22:46:39 2002
(deftest loop.4.1
(loop
for x = 1 then (+ 1 x)
until (> x 5)
collect x)
(1 2 3 4 5))
(deftest loop.4.2
(loop
for i from 1 to 10
for j = (+ 1 i) collect j)
(2 3 4 5 6 7 8 9 10 11))
(deftest loop.4.3
(loop
for i from 1 to 10
for j of... |
39fa5c0393e400a97238f04eaae553148359de13dd61c7ff2d84e80a856bd5d5 | clojure-interop/aws-api | AWSShieldClient.clj | (ns com.amazonaws.services.shield.AWSShieldClient
"Client for accessing AWS Shield. All service calls made using this client are blocking, and will not return until the
service call completes.
AWS Shield Advanced
This is the AWS Shield Advanced API Reference. This guide is for developers who need detailed inf... | null | https://raw.githubusercontent.com/clojure-interop/aws-api/59249b43d3bfaff0a79f5f4f8b7bc22518a3bf14/com.amazonaws.services.shield/src/com/amazonaws/services/shield/AWSShieldClient.clj | clojure | (ns com.amazonaws.services.shield.AWSShieldClient
"Client for accessing AWS Shield. All service calls made using this client are blocking, and will not return until the
service call completes.
AWS Shield Advanced
This is the AWS Shield Advanced API Reference. This guide is for developers who need detailed inf... | |
86322697af287c655c4245b6009fa3c28c3d55f2706d92b2c35b382b905dbf29 | GriffinScribe-LLC/clojure-aes | inverse_shift_rows.clj | (ns clojure-aes.decrypt.inverse-shift-rows
(:require [clojure-aes.utils :as utils]))
(defn inv-shift-rows
"Cyclically shifting the last three rows of the 4x4 state by different offsets to the right."
[[row1 row2 row3 row4] round-num]
(let [[row2-a row2-b row2-c row2-d] row2
[row3-a row3-b row3-c row3-d... | null | https://raw.githubusercontent.com/GriffinScribe-LLC/clojure-aes/cf9643503a89abea5b0243877c905889f9136219/src/clojure_aes/decrypt/inverse_shift_rows.clj | clojure | (ns clojure-aes.decrypt.inverse-shift-rows
(:require [clojure-aes.utils :as utils]))
(defn inv-shift-rows
"Cyclically shifting the last three rows of the 4x4 state by different offsets to the right."
[[row1 row2 row3 row4] round-num]
(let [[row2-a row2-b row2-c row2-d] row2
[row3-a row3-b row3-c row3-d... | |
6337f3a2504d0706dc1f9828f918b7799d6ff7c0c8c82bf7c2347d6f7fff179d | racket/pkg-build | build.rkt | #lang racket/base
(require (for-syntax racket/base)
pkg-build
racket/runtime-path)
(define-runtime-path workdir
(build-path "workdir"))
(build-pkgs
#:work-dir workdir
#:vms (list (vbox-vm #:name "pkg-build-1" #:host "192.168.33.2")
(vbox-vm #:name "pkg-build-2" #:host "192.168.33.3... | null | https://raw.githubusercontent.com/racket/pkg-build/31fea3651b501e2ad333cf6133527290abd2eed1/examples/vbox/build.rkt | racket | #lang racket/base
(require (for-syntax racket/base)
pkg-build
racket/runtime-path)
(define-runtime-path workdir
(build-path "workdir"))
(build-pkgs
#:work-dir workdir
#:vms (list (vbox-vm #:name "pkg-build-1" #:host "192.168.33.2")
(vbox-vm #:name "pkg-build-2" #:host "192.168.33.3... | |
177b3bd004353c531c4489b7c53cbcab2b798d0cd345148613ee8afdee7d94b0 | haskell/cabal | ShortText.hs | {-# LANGUAGE CPP #-}
{-# LANGUAGE DeriveDataTypeable #-}
# LANGUAGE DeriveGeneric #
-- | Compact representation of short 'Strings'
--
-- This module is designed to be import qualified
--
-- @
import Distribution . Utils . ShortText ( ShortText )
import qualified Distribution . Utils . ShortTex... | null | https://raw.githubusercontent.com/haskell/cabal/53c5dc9f9b19d01284e2b07d43e010b732ac91a8/Cabal-syntax/src/Distribution/Utils/ShortText.hs | haskell | # LANGUAGE CPP #
# LANGUAGE DeriveDataTypeable #
| Compact representation of short 'Strings'
This module is designed to be import qualified
@
@
* 'ShortText' type
* Operations
* internal utilities
make command . This
means no MIN_VERSION_binary macro is available.
We could try to cleverly ... | # LANGUAGE DeriveGeneric #
import Distribution . Utils . ShortText ( ShortText )
import qualified Distribution . Utils . ShortText as ShortText
module Distribution.Utils.ShortText
ShortText
, toShortText
, fromShortText
, unsafeFromUTF8BS
, null
, length
, decodeStringUtf8
... |
8e59bafec97ab5379c0d9e7f4510542bb983836f2273ae1180deb149735800d0 | programaker-project/Programaker-Core | automate_bot_engine_triggers.erl | -module(automate_bot_engine_triggers).
%% API
-export([ get_expected_signals/1
, get_triggered_threads/2
]).
-define(SERVER, ?MODULE).
-define(UTILS, automate_bot_engine_utils).
-include("../../automate_storage/src/records.hrl").
-include("program_records.hrl").
-include("instructions.hrl").
-include(... | null | https://raw.githubusercontent.com/programaker-project/Programaker-Core/e9a14b09d6a82edf4bb3976a7369e5cee2373624/backend/apps/automate_bot_engine/src/automate_bot_engine_triggers.erl | erlang | API
===================================================================
API
===================================================================
===================================================================
===================================================================
Expected signals
TODO: return a more... | -module(automate_bot_engine_triggers).
-export([ get_expected_signals/1
, get_triggered_threads/2
]).
-define(SERVER, ?MODULE).
-define(UTILS, automate_bot_engine_utils).
-include("../../automate_storage/src/records.hrl").
-include("program_records.hrl").
-include("instructions.hrl").
-include("../../... |
b1be7c27675dd7166f362ddc7fb96b6d492f78fac316ac2952aa7c385035f216 | avsm/mirage-duniverse | parser_.mli | open Result
type sections_allowed = Ast.sections_allowed
val parse_comment :
permissive:bool ->
sections_allowed:sections_allowed ->
containing_definition:Model.Paths.Identifier.label_parent ->
location:Lexing.position ->
text:string ->
((Model.Comment.docs, Model.Error.t) result) Model.Error.with_warni... | null | https://raw.githubusercontent.com/avsm/mirage-duniverse/983e115ff5a9fb37e3176c373e227e9379f0d777/ocaml_modules/odoc/src/parser/parser_.mli | ocaml | * Converts fatal errors to warnings for now, by emitting a blank comment. This
is a temporary measure, because the code that drives the parser does not yet
have proper error handling written. | open Result
type sections_allowed = Ast.sections_allowed
val parse_comment :
permissive:bool ->
sections_allowed:sections_allowed ->
containing_definition:Model.Paths.Identifier.label_parent ->
location:Lexing.position ->
text:string ->
((Model.Comment.docs, Model.Error.t) result) Model.Error.with_warni... |
32cf33900d06953b10d540927febbbc4b28ffa729b89e633846740cb8fd14413 | GaloisInc/mistral | Lens.hs | module Mistral.Utils.Lens where
import MonadLib
import Control.Applicative
import Data.Monoid
type LensLike f s t a b = (a -> f b) -> s -> f t
over :: LensLike Id s t a b -> (a -> b) -> s -> t
over l f x = runId (l (return.f) x)
set :: LensLike Id s t a b -> b -> s -> t
set l a ... | null | https://raw.githubusercontent.com/GaloisInc/mistral/3464ab332d73c608e64512e822fe2b8a619ec8f3/src/Mistral/Utils/Lens.hs | haskell | module Mistral.Utils.Lens where
import MonadLib
import Control.Applicative
import Data.Monoid
type LensLike f s t a b = (a -> f b) -> s -> f t
over :: LensLike Id s t a b -> (a -> b) -> s -> t
over l f x = runId (l (return.f) x)
set :: LensLike Id s t a b -> b -> s -> t
set l a ... | |
707329687b53a2eb89f586c9d92de62a177eac8be831363135a8096bc2cd311d | ndpar/erlang | pkix.erl | %%
@doc Utility functions to work with PKIX standard .
%%
-module(pkix).
-author("Andrey Paramonov").
-export([public_key/2]).
%%
@doc Converts RSA public key from PKCS#1 format to PKIX .
%%
-spec public_key(FileNameIn :: string(), FileNameOut :: string()) -> ok.
public_key(FileIn, FileOut) when is_list(FileIn),... | null | https://raw.githubusercontent.com/ndpar/erlang/e215841a1d370e0fc5eb6b9ff40ea7ae78fc8763/lib/ndpar/src/pkix.erl | erlang |
=============================================================================
Unit tests
============================================================================= | @doc Utility functions to work with PKIX standard .
-module(pkix).
-author("Andrey Paramonov").
-export([public_key/2]).
@doc Converts RSA public key from PKCS#1 format to PKIX .
-spec public_key(FileNameIn :: string(), FileNameOut :: string()) -> ok.
public_key(FileIn, FileOut) when is_list(FileIn), is_list(Fil... |
c51f1882878dbe9a5882492747faaa180a7a4a8e0f0681e0cb1912656f65c24b | roglo/mlrogue | level.mli | $ I d : level.mli , v 1.6 2005/11/06 02:34:10
open Rogue;
value place_at : game -> objet -> int -> int -> unit;
value put_player : game -> option int -> unit;
value create : game -> unit;
value trap_mess : trap_type -> string;
value trap_string : trap_type -> string;
| null | https://raw.githubusercontent.com/roglo/mlrogue/b73238bbbc8cd88c83579c3b72772a8c418020e5/level.mli | ocaml | $ I d : level.mli , v 1.6 2005/11/06 02:34:10
open Rogue;
value place_at : game -> objet -> int -> int -> unit;
value put_player : game -> option int -> unit;
value create : game -> unit;
value trap_mess : trap_type -> string;
value trap_string : trap_type -> string;
| |
54cd41720d10235e5728ab196a964caea126c6d722f28867cef133942d6b863b | elaforge/karya | Rambat.hs | Copyright 2018
-- This program is distributed under the terms of the GNU General Public
-- License 3.0, see COPYING or -3.0.txt
module Synth.Sampler.Patch.Rambat (patches, getVariations) where
import qualified Data.Char as Char
import qualified Data.List as List
import qualified Data.Map as Map
import qualified Da... | null | https://raw.githubusercontent.com/elaforge/karya/8ea15e6a5fb57e2f15f8c19836751e315f9c09f2/Synth/Sampler/Patch/Rambat.hs | haskell | This program is distributed under the terms of the GNU General Public
License 3.0, see COPYING or -3.0.txt
implementation detail.
| Reign in some samples that stick out.
Open.
var3 sample has a click and clunk.
Forgot this sample.
0 gets this value.
| Time to mute at the end of a note.
* tuning
* implementat... | Copyright 2018
module Synth.Sampler.Patch.Rambat (patches, getVariations) where
import qualified Data.Char as Char
import qualified Data.List as List
import qualified Data.Map as Map
import qualified Data.Maybe as Maybe
import qualified Data.Set as Set
import qualified Data.Text as Text
import qualified Sound.Fil... |
9fbded091adc16ea14051ec6a0a32c4f70a5fd840c4feb715c45da9eb65b30b0 | wilkerlucio/spec-coerce | core_test.cljc | (ns spec-coerce.core-test
#?(:cljs (:require-macros [cljs.test :refer [deftest testing is are run-tests]]))
(:require
#?(:clj [clojure.test :refer [deftest testing is are]])
[clojure.spec.alpha :as s]
[clojure.string :as str]
[clojure.test.check :as tc]
[clojure.test.check.generators]
[cloju... | null | https://raw.githubusercontent.com/wilkerlucio/spec-coerce/c729ef41d4523e4442fd1f716df924d8e119354e/test/spec_coerce/core_test.cljc | clojure | (is (= (sc/coerce ::symbol-set "foo/bar") 'foo/bar))
The following tests can't work without using `eval`. We will avoid this
(is (= (sc/coerce ::referenced-set ":a") :a))
(is (= (sc/coerce ::calculated-set ":foo") :foo))
(is (= (sc/coerce ::nilable-referenced-set ":a") :a))
(is (= (sc/coerce ::nilable-calculated-set "... | (ns spec-coerce.core-test
#?(:cljs (:require-macros [cljs.test :refer [deftest testing is are run-tests]]))
(:require
#?(:clj [clojure.test :refer [deftest testing is are]])
[clojure.spec.alpha :as s]
[clojure.string :as str]
[clojure.test.check :as tc]
[clojure.test.check.generators]
[cloju... |
c35b7b63fb76b9575ad1d764637645f6fd0a2f06690410d83c80669218fbf317 | antifuchs/autobench | pg-import.lisp | (in-package #:autobench)
(defvar *version-translations*)
(defparameter *suppress-pg-errors-on-import* t
"Parameter specifying whether or not to suppress duplicate key
constraint and other errors when importing a build into the
database. Required to be T in normal operation.")
(defparameter *suppress-pg-errors-on... | null | https://raw.githubusercontent.com/antifuchs/autobench/acc14ee2a8899cb630aa8dd02f3ffd7f5858ce28/lisp/pg-import.lisp | lisp | Pre versions belong to their releases
Releases belong to themselves
All other candidates get their last component stripped
release versions look like clisp.2.25-2001-03-15
non-release versions: clisp.2.41-2006-10-13-nn-g0126e2a
No results
already exists.
Now insert the actual benchmark data | (in-package #:autobench)
(defvar *version-translations*)
(defparameter *suppress-pg-errors-on-import* t
"Parameter specifying whether or not to suppress duplicate key
constraint and other errors when importing a build into the
database. Required to be T in normal operation.")
(defparameter *suppress-pg-errors-on... |
61b0f78b74533b33a21841e56adb6d365791fb367fe4fb1ce0d855d3d349d1a3 | icicle-lang/icicle-ambiata | Name.hs | # LANGUAGE NoImplicitPrelude #
# LANGUAGE TemplateHaskell #
module Icicle.Test.Sea.Name where
import Data.Char (chr)
import Data.Maybe (fromJust)
import qualified Data.Text as Text
import Disorder.Core.Gen
import Disorder.Core.Tripping
import Icicle.Test.Arbitrary
im... | null | https://raw.githubusercontent.com/icicle-lang/icicle-ambiata/9b9cc45a75f66603007e4db7e5f3ba908cae2df2/icicle-compiler/test/Icicle/Test/Sea/Name.hs | haskell | # LANGUAGE NoImplicitPrelude #
# LANGUAGE TemplateHaskell #
module Icicle.Test.Sea.Name where
import Data.Char (chr)
import Data.Maybe (fromJust)
import qualified Data.Text as Text
import Disorder.Core.Gen
import Disorder.Core.Tripping
import Icicle.Test.Arbitrary
im... | |
4fb8c18bc61edf8724b353fa796a376135f73de1a8280d652c1c626084883e6b | karlhof26/gimp-scheme | jmat-layout2_02.scm | Scripts for combining images side - by - side or atop in given width .
By 30 March 2003
v0.1 - 04 April 2003
;
Modified by Karlhof26
; --------------------------------------------------------------------
;
; This program is free software; you can redistribute it and/or modify
it under the terms of the GNU... | null | https://raw.githubusercontent.com/karlhof26/gimp-scheme/65d1002e85a5de40d8835bef17dde8b9e7624bc6/jmat-layout2_02.scm | scheme |
--------------------------------------------------------------------
This program is free software; you can redistribute it and/or modify
either version 2 of the License , or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without ev... | Scripts for combining images side - by - side or atop in given width .
By 30 March 2003
v0.1 - 04 April 2003
Modified by Karlhof26
it under the terms of the GNU General Public License as published by
You should have received a copy of the GNU General Public License
Foundation , Inc. , 675 Mass Ave , C... |
9d454da59c5b0408371ed9712e1fd8bf8d353a3a28125a9c51036096bbc24843 | 8c6794b6/guile-tjit | t-br-if-tc7-01.scm | ;;; Simple loop containing `br-if-tc7'.
(define (loop lst acc)
(let lp ((lst lst) (acc acc))
(if (null? lst)
acc
(let ((x (car lst))
(lst (cdr lst)))
(lp lst (if (vector? x)
(+ acc 1)
acc))))))
(let* ((vs (make-list 100 #(1 2 3)... | null | https://raw.githubusercontent.com/8c6794b6/guile-tjit/9566e480af2ff695e524984992626426f393414f/test-suite/tjit/t-br-if-tc7-01.scm | scheme | Simple loop containing `br-if-tc7'. |
(define (loop lst acc)
(let lp ((lst lst) (acc acc))
(if (null? lst)
acc
(let ((x (car lst))
(lst (cdr lst)))
(lp lst (if (vector? x)
(+ acc 1)
acc))))))
(let* ((vs (make-list 100 #(1 2 3)))
(ls (make-list 100 '(1 2 3)))
... |
b28cd306ea5c2c042947c080d080e1197f87be328503aa63c910a6e3047c9c46 | soegaard/sketching | sketch-random-lines.rkt | #lang sketching
(define (setup)
(size 800 600)
(stroke-cap 'butt)
(frame-rate 10))
(define (draw)
(background 255)
(stroke 0 0 0 20)
(for ([i (in-range 10000)])
(define x0 (random (* -2 width) (* 2 width)))
(define y0 (random (* -2 height) (* 2 height)))
(define x1 (random (* -2 width) (* 2 ... | null | https://raw.githubusercontent.com/soegaard/sketching/3773cb790ac69201c967201a2fa1727d90a4ad62/sketching-examples/examples/sketch-random-lines.rkt | racket | #lang sketching
(define (setup)
(size 800 600)
(stroke-cap 'butt)
(frame-rate 10))
(define (draw)
(background 255)
(stroke 0 0 0 20)
(for ([i (in-range 10000)])
(define x0 (random (* -2 width) (* 2 width)))
(define y0 (random (* -2 height) (* 2 height)))
(define x1 (random (* -2 width) (* 2 ... | |
341f7361622390e633dd533b7bd586e8d2cea2bae1a1324a646acb7adb4dd00a | mpickering/ghcide-reflex | Diagnostics.hs | # LANGUAGE FlexibleContexts #
# LANGUAGE TypeFamilies #
module Development.IDE.Core.Reflex.Diagnostics where
import qualified Data.List.NonEmpty as NL
import { - # SOURCE # - } Language . Haskell . Core . FileStore ( getModificationTime )
import Language.Haskell.LSP.Diagnostics
import qualified Data.SortedList as SL
i... | null | https://raw.githubusercontent.com/mpickering/ghcide-reflex/67ddebf0c1d4728e850057b9bd7c6852c0d96350/src/Development/IDE/Core/Reflex/Diagnostics.hs | haskell | Diagnostics
publish
| Sets the diagnostics for a file and compilation step
if you want to clear the diagnostics call this with an empty list
^ the time that the file these diagnostics originate from was last edited | # LANGUAGE FlexibleContexts #
# LANGUAGE TypeFamilies #
module Development.IDE.Core.Reflex.Diagnostics where
import qualified Data.List.NonEmpty as NL
import { - # SOURCE # - } Language . Haskell . Core . FileStore ( getModificationTime )
import Language.Haskell.LSP.Diagnostics
import qualified Data.SortedList as SL
i... |
4a82d4fa5fa267c8a9da08326ba51fe956ffbd9ae31d02cdb4384cb437735699 | ygrek/mldonkey | tcpdump2txt.ml | let i_a = int_of_char 'a'
let i_A = int_of_char 'A'
let i_f = int_of_char 'f'
let i_F = int_of_char 'F'
let i_0 = int_of_char '0'
let i_9 = int_of_char '9'
let digit_hexa c =
let i = int_of_char c in
if i >= i_a && i <= i_f then i - i_a + 10 else
if i >= i_A && i <= i_F then i - i_A + 10 else
if i >= i... | null | https://raw.githubusercontent.com/ygrek/mldonkey/333868a12bb6cd25fed49391dd2c3a767741cb51/tools/tcpdump2txt.ml | ocaml |
lprintf "DISCARD [%s]" line; lprint_newline ();
| let i_a = int_of_char 'a'
let i_A = int_of_char 'A'
let i_f = int_of_char 'f'
let i_F = int_of_char 'F'
let i_0 = int_of_char '0'
let i_9 = int_of_char '9'
let digit_hexa c =
let i = int_of_char c in
if i >= i_a && i <= i_f then i - i_a + 10 else
if i >= i_A && i <= i_F then i - i_A + 10 else
if i >= i... |
cb81231f4b01dceb23b7a1b28bc8afd9eb0e2e450ca89482e470820ebaba89ba | tov/dssl2 | color-lexer.rkt | #lang racket/base
(provide get-syntax-token)
(require "../lexer.rkt"
parser-tools/lex
(prefix-in : parser-tools/lex-sre)
syntax/parse/define
(for-syntax racket/base
(only-in racket/syntax
format-id)
syntax/pars... | null | https://raw.githubusercontent.com/tov/dssl2/105d18069465781bd9b87466f8336d5ce9e9a0f3/private/drracket/color-lexer.rkt | racket | #lang racket/base
(provide get-syntax-token)
(require "../lexer.rkt"
parser-tools/lex
(prefix-in : parser-tools/lex-sre)
syntax/parse/define
(for-syntax racket/base
(only-in racket/syntax
format-id)
syntax/pars... | |
f1202f742c7063f13597e4de1e492fea1fffd1c26ecb69ed007bab806d0789d6 | theam/aws-lambda-haskell-runtime | Publish.hs | {-# LANGUAGE GADTs #-}
-- | Publishing of results/errors back to the
-- AWS Lambda runtime API
module Aws.Lambda.Runtime.Publish
( result,
invocationError,
parsingError,
runtimeInitError,
)
where
import qualified Aws.Lambda.Runtime.API.Endpoints as Endpoints
import Aws.Lambda.Runtime.Common
import Aws... | null | https://raw.githubusercontent.com/theam/aws-lambda-haskell-runtime/0031c3eea919d0b1505dde5aa24fd31436a49503/src/Aws/Lambda/Runtime/Publish.hs | haskell | # LANGUAGE GADTs #
| Publishing of results/errors back to the
AWS Lambda runtime API
| Publishes the result back to AWS Lambda
| Publishes an invocation error back to AWS Lambda
| Publishes a parsing error back to AWS Lambda
| Publishes a runtime initialization error back to AWS Lambda |
module Aws.Lambda.Runtime.Publish
( result,
invocationError,
parsingError,
runtimeInitError,
)
where
import qualified Aws.Lambda.Runtime.API.Endpoints as Endpoints
import Aws.Lambda.Runtime.Common
import Aws.Lambda.Runtime.Context (Context (..))
import qualified Aws.Lambda.Runtime.Error as Error
impor... |
864e84b15237af84363ec21cfc21348bbb94a40c950c7ebd534aeb9844940b63 | tfeb/dsm | define-matching-macro.lisp | (in-package :cl-user)
(needs (:org.tfeb.dsm :compile t :use t))
(defmacro define-matching-macro (name &body clauses)
(let ((<whole> (make-symbol "WHOLE"))
(<junk> (make-symbol "JUNK")))
(destructuring-match clauses
((doc . the-clauses)
(:when (stringp doc))
`(defmacro ,name (&whole ,... | null | https://raw.githubusercontent.com/tfeb/dsm/4ff10b817797073a67ac10fd00ddd68c4e8869f9/examples/define-matching-macro.lisp | lisp | (in-package :cl-user)
(needs (:org.tfeb.dsm :compile t :use t))
(defmacro define-matching-macro (name &body clauses)
(let ((<whole> (make-symbol "WHOLE"))
(<junk> (make-symbol "JUNK")))
(destructuring-match clauses
((doc . the-clauses)
(:when (stringp doc))
`(defmacro ,name (&whole ,... | |
030bc9b5f60ff51c6dc29aa12266444b6244ea65262fc2a3b06a87c11159563d | HaskellForCats/HaskellForCats | NOMONOMORPHING.hs | # LANGUAGE NoMonomorphismRestriction #
module Dada123 where
dada1 (x,y) = x + y
dada2 = \(x,y) -> x + y
dada3 x = \y -> x + y
dada4 = \x -> \y -> x + y
dada5 x y = x + y
the rule is known as the " monomorphic restriction
- so when there is a type variable such as x or y
- to... | null | https://raw.githubusercontent.com/HaskellForCats/HaskellForCats/2d7a15c0cdaa262c157bbf37af6e72067bc279bc/NOMONOMORPHING.hs | haskell |
# LANGUAGE NoMonomorphismRestriction # | # LANGUAGE NoMonomorphismRestriction #
module Dada123 where
dada1 (x,y) = x + y
dada2 = \(x,y) -> x + y
dada3 x = \y -> x + y
dada4 = \x -> \y -> x + y
dada5 x y = x + y
the rule is known as the " monomorphic restriction
- so when there is a type variable such as x or y
- to... |
10552d6137338bc5abd20e745d636b6189c1599e9c49657a456d941ede46ccbf | subtitle-master/subtitlemaster | subdb.cljs | (ns sm.sources.subdb
(:require-macros [wilkerdev.util.macros :refer [<? go-catch]])
(:require [sm.protocols :refer [SearchProvider UploadProvider Subtitle Linkable]]
[wilkerdev.util.nodejs :refer [lstat fopen fread http] :as node]
[wilkerdev.util :as util]))
(def ^:dynamic *subdb-endpoint* ... | null | https://raw.githubusercontent.com/subtitle-master/subtitlemaster/d88c2fb007c6c3d4030fefbd4b7e3eafb0e797a9/src/cljs/sm/sources/subdb.cljs | clojure | (ns sm.sources.subdb
(:require-macros [wilkerdev.util.macros :refer [<? go-catch]])
(:require [sm.protocols :refer [SearchProvider UploadProvider Subtitle Linkable]]
[wilkerdev.util.nodejs :refer [lstat fopen fread http] :as node]
[wilkerdev.util :as util]))
(def ^:dynamic *subdb-endpoint* ... | |
78bbca676a7fc840012ca6c4a0a204d9c91b6326c6e206034d615c6aad85a467 | zwizwa/rai | libproc.rkt | #lang racket/base
(require racket/dict
racket/match
racket/pretty
ffi/vector
ffi/unsafe
ffi/unsafe/define
"f32vector.rkt")
(require racket/runtime-path)
(define-runtime-path libproc-path "src/libproc")
(provide
;; Provide only safe ops
proc-load-sp
proc-instant... | null | https://raw.githubusercontent.com/zwizwa/rai/6bcacb7da4172971816027fd88a0209adbd60e30/libproc.rkt | racket | Provide only safe ops
FIXME: make sure libproc.so is compiled with PROC_NUMBER_T = double
We don't know the types at compile time. It is necessary to use
proc.h metadata to reconstruct data layout information at run time.
array of input arrays
param array
array of output arrays
store
nb_samples
Stateless sin... | #lang racket/base
(require racket/dict
racket/match
racket/pretty
ffi/vector
ffi/unsafe
ffi/unsafe/define
"f32vector.rkt")
(require racket/runtime-path)
(define-runtime-path libproc-path "src/libproc")
(provide
proc-load-sp
proc-instantiate
proc-run!
proc-run-... |
598212121d8b2d7d80cfc0a57cfbef02bebdf26b97170a0de9eb9fee183152cd | OCamlPro/alt-ergo | satml_frontend_hybrid.ml | (******************************************************************************)
(* *)
Alt - Ergo : The SMT Solver For Software Verification
Copyright ( C ) 2013 - 2018
(* ... | null | https://raw.githubusercontent.com/OCamlPro/alt-ergo/291523151417f4cd112744d740b58ab1e8a630b4/src/lib/reasoners/satml_frontend_hybrid.ml | ocaml | ****************************************************************************
This file is distributed under the terms of the license indicated
in the ... | Alt - Ergo : The SMT Solver For Software Verification
Copyright ( C ) 2013 - 2018
module Make (Th : Theory.S) = struct
open Options
module E = Expr
module ME = E.Map
module SE = E.Set
module Ex = Explanation
module Atom = Satml_types.Ato... |
f8e6cfb8dfd86331d3df6f68601f3bafbc6e135f5f44e212848b4f7ee9f17cac | SimulaVR/godot-haskell | ClippedCamera.hs | # LANGUAGE DerivingStrategies , GeneralizedNewtypeDeriving ,
TypeFamilies , TypeOperators , FlexibleContexts , DataKinds ,
MultiParamTypeClasses #
TypeFamilies, TypeOperators, FlexibleContexts, DataKinds,
MultiParamTypeClasses #-}
module Godot.Core.ClippedCamera
(Godot.Core.ClippedCamera._CLIP_PROCES... | null | https://raw.githubusercontent.com/SimulaVR/godot-haskell/e8f2c45f1b9cc2f0586ebdc9ec6002c8c2d384ae/src/Godot/Core/ClippedCamera.hs | haskell | | Adds a collision exception so the camera does not collide with the specified node.
| Adds a collision exception so the camera does not collide with the specified node.
| Adds a collision exception so the camera does not collide with the specified @RID@.
| Adds a collision exception so the camera does not collide ... | # LANGUAGE DerivingStrategies , GeneralizedNewtypeDeriving ,
TypeFamilies , TypeOperators , FlexibleContexts , DataKinds ,
MultiParamTypeClasses #
TypeFamilies, TypeOperators, FlexibleContexts, DataKinds,
MultiParamTypeClasses #-}
module Godot.Core.ClippedCamera
(Godot.Core.ClippedCamera._CLIP_PROCES... |
8d3be2eeac45ba5f058e8243f094040a1414ebb29db24504954409ee462a59f8 | xtdb/core2 | logical_plan.clj | (ns core2.logical-plan
(:require [clojure.set :as set]
[clojure.spec.alpha :as s]
[clojure.string :as str]
[clojure.walk :as w]
[core2.error :as err]
[core2.rewrite :as r]
[core2.util :as util])
(:import (clojure.lang Var)))
;; See also:
;; -u... | null | https://raw.githubusercontent.com/xtdb/core2/3adeb391ca4dd73a3f79faba8024289376597d23/core/src/main/clojure/core2/logical_plan.clj | clojure | See also:
-uibk.github.io/relax/help#relalg-reference
also contains operators for path expansion:
Rewriting of logical plan.
Attempt to clean up tree, removing names internally and only add
them back at the top. Scan still needs explicit names to access the
columns, so these are directly renamed.
NOTE: mi... | (ns core2.logical-plan
(:require [clojure.set :as set]
[clojure.spec.alpha :as s]
[clojure.string :as str]
[clojure.walk :as w]
[core2.error :as err]
[core2.rewrite :as r]
[core2.util :as util])
(:import (clojure.lang Var)))
See " Formalisi... |
dc313feb1a6c2466619728a0103865731da6da88a7c223d5824143a1e64a3890 | palkan/erlgrpc | math_SUITE.erl | -module(math_SUITE).
-include_lib("common_test/include/ct.hrl").
-include_lib("erlgrpc/include/erlgrpc.hrl").
-include_lib("erlgrpc/include/log.hrl").
-include_lib("erlgrpc/include/priv.hrl").
-include("protos/math_pb.hrl").
-compile(export_all).
-define(RUBY_PATH, filename:join([element(2, file:get_cwd()), "../../..... | null | https://raw.githubusercontent.com/palkan/erlgrpc/5a764009020e993ffcc31952c5478c9f4526f3ad/specs/math_SUITE.erl | erlang | -module(math_SUITE).
-include_lib("common_test/include/ct.hrl").
-include_lib("erlgrpc/include/erlgrpc.hrl").
-include_lib("erlgrpc/include/log.hrl").
-include_lib("erlgrpc/include/priv.hrl").
-include("protos/math_pb.hrl").
-compile(export_all).
-define(RUBY_PATH, filename:join([element(2, file:get_cwd()), "../../..... | |
31c90bfe1ee0409b37bd5a528bf7c5eb1f4d05bbac9442dc7eb340a151bca4f5 | coccinelle/coccinelle | pyml_tests_common.ml | let use_version = ref (None, None)
type status =
| Passed
| Failed of string
| Disabled of string
let tests = Queue.create ()
let add_test ~title f =
Queue.add (title, f) tests
let failed = ref false
let launch_test (title, f) =
Printf.printf "Test '%s' ... %!" title;
try
match f () with
Pass... | null | https://raw.githubusercontent.com/coccinelle/coccinelle/f121696c9fe1aa4efaec43ad2152960d86c923bd/bundles/pyml/pyml-current/pyml_tests_common.ml | ocaml | let use_version = ref (None, None)
type status =
| Passed
| Failed of string
| Disabled of string
let tests = Queue.create ()
let add_test ~title f =
Queue.add (title, f) tests
let failed = ref false
let launch_test (title, f) =
Printf.printf "Test '%s' ... %!" title;
try
match f () with
Pass... | |
7de00dcb5f3a2e4fad1fe6e8f114f1d74847bcf2c5e0bbee7a375423742d18aa | GrammaTech/sel | clang-expression.lisp | ;;; clang-expression.lisp --- calculate lisp expressions from clang ASTs
(defpackage :software-evolution-library/software/clang-expression
(:nicknames :sel/software/clang-expression :sel/sw/clang-expression)
(:use :gt/full
:software-evolution-library
:software-evolution-library/software/parseable
... | null | https://raw.githubusercontent.com/GrammaTech/sel/a4238945dfbf98b67b9d8a10b08924634544f9f8/software/clang-expression.lisp | lisp | clang-expression.lisp --- calculate lisp expressions from clang ASTs
source text. This conversion may be made more robust by
extending more ASTs types with additional information like
opcode, e.g. the following.
- UnaryExprOrTypeTraitExpr :: sizeof | alignof | vec_step
- UnaryO... | (defpackage :software-evolution-library/software/clang-expression
(:nicknames :sel/software/clang-expression :sel/sw/clang-expression)
(:use :gt/full
:software-evolution-library
:software-evolution-library/software/parseable
:software-evolution-library/software/clang
:software-evolut... |
f00944ef88505e2da90eed760a10dc79ffdeef935bca08d3afab5bdb256e34f0 | OscarSouth/theHarmonicAlgorithm | MusicData.hs | # LANGUAGE FlexibleContexts #
# LANGUAGE InstanceSigs #
module MusicData where
import Utility
import Data.Function (on)
import Data.Maybe (fromMaybe)
import Data.Set (Set)
import GHC.Base (modInt, quotInt, remInt)
import GHC.Real ... | null | https://raw.githubusercontent.com/OscarSouth/theHarmonicAlgorithm/615b87c7ac98e06f59af225bb892c6caf97a4a29/src/MusicData.hs | haskell | | MusicData class definition
mappings into pitch classes
mappings into sharp note names
mappings into flat note names
automatic derivation
|
|
|
v
|data type defining set all (standard) enharmonic note names
|custom Show instance f... | # LANGUAGE FlexibleContexts #
# LANGUAGE InstanceSigs #
module MusicData where
import Utility
import Data.Function (on)
import Data.Maybe (fromMaybe)
import Data.Set (Set)
import GHC.Base (modInt, quotInt, remInt)
import GHC.Real ... |
7a572372ccacddec02bf88bf575f6f3e3a9994128479a1b59de2b4c2726d92ab | haskell/cabal | Format.hs | {-# LANGUAGE OverloadedStrings #-}
-- |
Module : Distribution . Client . Init . Format
Copyright : ( c ) 2009
-- License : BSD-like
--
-- Maintainer :
-- Stability : provisional
-- Portability : portable
--
-- Pretty printing and field formatting utilities used for file creation.
--
modul... | null | https://raw.githubusercontent.com/haskell/cabal/c21dbcd2a9d54962eb39f598dfce2d012ff7fd1c/cabal-install/src/Distribution/Client/Init/Format.hs | haskell | # LANGUAGE OverloadedStrings #
|
License : BSD-like
Maintainer :
Stability : provisional
Portability : portable
Pretty printing and field formatting utilities used for file creation.
* cabal file formatters
* stanza generation
converted to a 'Doc' via 'display'.
^ Name of the field
^ Field c... | Module : Distribution . Client . Init . Format
Copyright : ( c ) 2009
module Distribution.Client.Init.Format
listFieldS
, field
, fieldD
, commentedOutWithComments
, withComments
, annNoComments
, postProcessFieldLines
, mkCommonStanza
, mkLibStanza
, mkExeStanza
, mkTestStanza
, mkPkgDescription
)... |
cdb1edb0c93ed768e21bfb0fd49aee9dcdd72ba9dca282c547b4571e89c9f772 | mokus0/junkbox | which.hs | : m Prelude System . Environment Text . Regex Control . Monad System . . Files
-- let path = getEnv "PATH" >>= return.(splitRegex (mkRegex ":"))
-- let which x = path >>= mapM (return.(++ ("/" ++ x))) >>= filterM (fileExist)
module Main where
import System.Environment
import Text.Regex
import Control.Monad
import ... | null | https://raw.githubusercontent.com/mokus0/junkbox/151014bbef9db2b9205209df66c418d6d58b0d9e/Haskell/Odd%20little%20utilities/which.hs | haskell | let path = getEnv "PATH" >>= return.(splitRegex (mkRegex ":"))
let which x = path >>= mapM (return.(++ ("/" ++ x))) >>= filterM (fileExist) | : m Prelude System . Environment Text . Regex Control . Monad System . . Files
module Main where
import System.Environment
import Text.Regex
import Control.Monad
import System.Posix.Files
path = liftM (splitRegex (mkRegex ":")) (getEnv "PATH")
which x = path >>= mapM (return.(++ ("/" ++ x))) >>= filterM (fileExis... |
9f5fee40cd3c86a725783dfb73b0706d24fc88c1ae21c3c8e8c20f8559e696ec | TristanCacqueray/haskell-butler | Mumbler.hs | module Butler.App.Mumbler where
import Data.ByteString qualified as BS
import Butler
import Butler.Core.Logger
import Butler.Core.NatMap qualified as NM
import Butler.App.SoundBlaster
import Butler.Display.Session
import Butler.Display.User
mumblerApp :: App
mumblerApp =
(defaultApp "mumbler" startMumbler)
... | null | https://raw.githubusercontent.com/TristanCacqueray/haskell-butler/1c4f00c0f7539ac08d25bd07eb34b79af09e7f0f/src/Butler/App/Mumbler.hs | haskell | --
Individual user
--
--
Update state, handling double click to toggle continuous state
--
double clicked
--
Collection of users
--
--
App implementation
--
wait for the very last frame before pausing the channel
User is still muted, pause the chan
wait for mouseup event
user didn't double click for continuous... | module Butler.App.Mumbler where
import Data.ByteString qualified as BS
import Butler
import Butler.Core.Logger
import Butler.Core.NatMap qualified as NM
import Butler.App.SoundBlaster
import Butler.Display.Session
import Butler.Display.User
mumblerApp :: App
mumblerApp =
(defaultApp "mumbler" startMumbler)
... |
83ae4577f8690925d869769cb1aca7d0897c5b02244b6666d81fdfdeafee8fe0 | AshleyYakeley/Truth | Optics.hs | {-# OPTIONS -fno-warn-orphans #-}
module Pinafore.Language.Library.Optics
( opticsLibSection
, propertyGroundType
) where
import Pinafore.Language.Convert
import Pinafore.Language.Library.Convert ()
import Pinafore.Language.Library.Defs
import Pinafore.Language.Library.Model ()
import Pinafore.Language.Ty... | null | https://raw.githubusercontent.com/AshleyYakeley/Truth/f567d19253bb471cbd8c39095fb414229b27706a/Pinafore/pinafore-language/lib/Pinafore/Language/Library/Optics.hs | haskell | # OPTIONS -fno-warn-orphans #
LangLens |
module Pinafore.Language.Library.Optics
( opticsLibSection
, propertyGroundType
) where
import Pinafore.Language.Convert
import Pinafore.Language.Library.Convert ()
import Pinafore.Language.Library.Defs
import Pinafore.Language.Library.Model ()
import Pinafore.Language.Type
import Pinafore.Language.Value
... |
178938dd1c5aa29e20b44378630f33af6560ffd55f50bbafc2bd68ec99adfe80 | xh4/web-toolkit | helper.lisp | (in-package :utility-test)
| null | https://raw.githubusercontent.com/xh4/web-toolkit/e510d44a25b36ca8acd66734ed1ee9f5fe6ecd09/test/utility/helper.lisp | lisp | (in-package :utility-test)
| |
628cf3ba1e614f5c62be9678e88410ea078cbe45b2a839bbeda837635fa4fe8f | onyx-platform/onyx-twitter-sample | trending.clj | (ns twit.jobs.trending
(:require [lib-onyx.joplin :as joplin]
[onyx.job :refer [add-task register-job]]
[onyx.tasks.null :as null]
[onyx.tasks
[core-async :as core-async-task]
[twitter :as twitter]]
[twit.tasks
[reshape :as reshape... | null | https://raw.githubusercontent.com/onyx-platform/onyx-twitter-sample/bd206630a0ee083867f44e856544c6bd664962e8/src/twit/jobs/trending.clj | clojure | "Picking up where trending-hashtags-job left off, we add the root and 'leafs'
to the graph for a production environment. This is input from the actual live
twitter stream, a core-async output channel (since we dont care about
the workflow output, just the :trigger/sync) and a :trigger/sync sending
data to ... | (ns twit.jobs.trending
(:require [lib-onyx.joplin :as joplin]
[onyx.job :refer [add-task register-job]]
[onyx.tasks.null :as null]
[onyx.tasks
[core-async :as core-async-task]
[twitter :as twitter]]
[twit.tasks
[reshape :as reshape... |
4be381308d3c8d6abf5679107be426bcac892c94f06be2904b3ff912432a026e | NorfairKing/feedback | Test.hs | module Test where
import Feedback.Test
main :: IO ()
main = runFeedbackTest
| null | https://raw.githubusercontent.com/NorfairKing/feedback/e5a0969c0b41e03717bf55a424612df3b817d16f/feedback/app/Test.hs | haskell | module Test where
import Feedback.Test
main :: IO ()
main = runFeedbackTest
| |
f75519f80281a25e01a9b496aa3d9aa36b1cc6f0633c3ef9da587aa915c175e9 | processone/ejabberd | ejabberd_shaper.erl | %%%----------------------------------------------------------------------
ejabberd , Copyright ( C ) 2002 - 2023 ProcessOne
%%%
%%% 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 ver... | null | https://raw.githubusercontent.com/processone/ejabberd/c103182bc7e5b8a8ab123ce02d1959a54e939480/src/ejabberd_shaper.erl | erlang | ----------------------------------------------------------------------
This program is free software; you can redistribute it and/or
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCH... | ejabberd , Copyright ( C ) 2002 - 2023 ProcessOne
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation ; either version 2 of the
You should have received a copy of the GNU General Public License along
with this program ; if not , write to the Free Softwar... |
507002f92bc3dec25bb8db78a8234f011213e01d6100a55edf060c64620a53ad | tkaryadis/squery-mongo-core | diagnostic.cljc | (ns squery-mongo-core.diagnostic
(:require [squery-mongo-core.internal.convert.commands :refer [squery-map->mql-map split-db-namespace]]
[squery-mongo-core.internal.convert.stages :refer [squery-vector->squery-map]]))
(def coll-stats-def
{
:collStats "<string>",
:scale "<int>"
})
shell has a ... | null | https://raw.githubusercontent.com/tkaryadis/squery-mongo-core/7df7d6733cfacaf0379d2a39908e6ceb0d86ffeb/src/squery_mongo_core/diagnostic.cljc | clojure | db.read-write.totalIndexSize
db.read-write.totalSize
---------------------------------general------------------------------------------------------------------------- | (ns squery-mongo-core.diagnostic
(:require [squery-mongo-core.internal.convert.commands :refer [squery-map->mql-map split-db-namespace]]
[squery-mongo-core.internal.convert.stages :refer [squery-vector->squery-map]]))
(def coll-stats-def
{
:collStats "<string>",
:scale "<int>"
})
shell has a ... |
e8cd18c97f410c5c2fad50447abd98dce78c054d14295a320e819f2c2531a2bb | NorfairKing/smos | Streaming.hs | module Smos.Cursor.Report.Streaming where
import Conduit
import Path
import Smos.Data
import Smos.Report.Archive
import Smos.Report.Config
import Smos.Report.ShouldPrint
import Smos.Report.Streaming
produceReportCursorEntries :: MonadIO m => ConduitT (Path Rel File, SmosFile) a m () -> DirectoryConfig -> m [a]
produc... | null | https://raw.githubusercontent.com/NorfairKing/smos/f72b26c2e66ab4f3ec879a1bedc6c0e8eeb18a01/smos-report-cursor/src/Smos/Cursor/Report/Streaming.hs | haskell | module Smos.Cursor.Report.Streaming where
import Conduit
import Path
import Smos.Data
import Smos.Report.Archive
import Smos.Report.Config
import Smos.Report.ShouldPrint
import Smos.Report.Streaming
produceReportCursorEntries :: MonadIO m => ConduitT (Path Rel File, SmosFile) a m () -> DirectoryConfig -> m [a]
produc... | |
772635a3c8bc7552e5ed87b41948ce9c150a0d9cf8f921ad438270a2314ba029 | astrada/ocaml-extjs | ext_data_proxy_Ajax.mli | * AjaxProxy is one of the most widely - used ways of g ...
{ % < p > AjaxProxy is one of the most widely - used ways of getting data into your application . It uses AJAX requests to load
data from the server , usually to be placed into a < a href="#!/api / Ext.data . Store " rel="Ext.data . Store " class="docC... | null | https://raw.githubusercontent.com/astrada/ocaml-extjs/77df630a75fb84667ee953f218c9ce375b3e7484/lib/ext_data_proxy_Ajax.mli | ocaml | * [of_configs c] casts a config object [c] to an instance of class [t]
* [to_configs o] casts instance [o] of class [t] to a config object | * AjaxProxy is one of the most widely - used ways of g ...
{ % < p > AjaxProxy is one of the most widely - used ways of getting data into your application . It uses AJAX requests to load
data from the server , usually to be placed into a < a href="#!/api / Ext.data . Store " rel="Ext.data . Store " class="docC... |
86e5a079f99275b46088619e467c2c630b146aff1a67372f5b66a70c1a88e661 | nackjicholson/haskellbook-solutions | arith2.hs | -- arith2.hs
module Arith2 where
add :: Int -> Int -> Int
add x y = x + y
addPF :: Int -> Int -> Int
addPF = (+)
addOne :: Int -> Int
addOne = \x -> x + 1
addOnePF :: Int -> Int
addOnePF = (+1)
main :: IO ()
main = do
0
1
1
1
2
2
2
2
print (negate (addOne 0)) -- -1
print ((negate . addOne) 0) -... | null | https://raw.githubusercontent.com/nackjicholson/haskellbook-solutions/c21bd87773734ba2ae1559553a6a4d10891c61c8/chapter7/arith2.hs | haskell | arith2.hs
-1
-1 | module Arith2 where
add :: Int -> Int -> Int
add x y = x + y
addPF :: Int -> Int -> Int
addPF = (+)
addOne :: Int -> Int
addOne = \x -> x + 1
addOnePF :: Int -> Int
addOnePF = (+1)
main :: IO ()
main = do
0
1
1
1
2
2
2
2
print ((addOne . addOne . addOne
2
|
b917c0f84cb4aae99b36a4eecf0bd9bced4a67cb574335c52990079997be6da1 | erlang/erlide_kernel | erlide_parse.erl | -module(erlide_parse).
%% API
-export([consult/1]).
%% for tests
-export([split/1]).
consult(B) when is_binary(B) ->
consult(binary_to_list(B));
consult(L) when is_list(L) ->
{ok, Toks, _} = erl_scan_local:string(L),
FormToks = split(Toks),
lists:map(fun parse1/1, FormToks).
parse1(Toks) ->
R = ... | null | https://raw.githubusercontent.com/erlang/erlide_kernel/763a7fe47213f374b59862fd5a17d5dcc2811c7b/ide/apps/erlide_ide_core/src/erlide_parse.erl | erlang | API
for tests | -module(erlide_parse).
-export([consult/1]).
-export([split/1]).
consult(B) when is_binary(B) ->
consult(binary_to_list(B));
consult(L) when is_list(L) ->
{ok, Toks, _} = erl_scan_local:string(L),
FormToks = split(Toks),
lists:map(fun parse1/1, FormToks).
parse1(Toks) ->
R = erl_parse:parse_expr... |
9134f2faef6ed5a36248355de243c9b130f4677cc53b5775418e8652eac6199a | philnguyen/soft-contract | qc-insert.rkt | #lang racket
(require soft-contract/fake-contract)
(define (insert x xs)
(cond [(null? xs) (cons x null)]
[(< x (car xs)) (cons x xs)]
[else (cons (car xs) (insert x (cdr xs)))]))
(define (ordered? xs)
(or (null? xs)
(null? (cdr xs))
(and (<= (car xs) (car (cdr xs)))
(ordere... | null | https://raw.githubusercontent.com/philnguyen/soft-contract/5e07dc2d622ee80b961f4e8aebd04ce950720239/soft-contract/test/programs/safe/qc-insert.rkt | racket | #lang racket
(require soft-contract/fake-contract)
(define (insert x xs)
(cond [(null? xs) (cons x null)]
[(< x (car xs)) (cons x xs)]
[else (cons (car xs) (insert x (cdr xs)))]))
(define (ordered? xs)
(or (null? xs)
(null? (cdr xs))
(and (<= (car xs) (car (cdr xs)))
(ordere... | |
bfb44388504c71b952670096ba56050177c20c40a35259fd54fbcc29bfd78578 | potapenko/playphraseme-site | google_translate.clj | (ns playphraseme.common.google-translate
(:require [clj-http.client :as client]
[playphraseme.app.config :refer [env]]
[cheshire.core :as parser]
[clojure.data.json :as json]
[playphraseme.api.queries.common-phrases :as common-phrases-db]
[clojure.string :as... | null | https://raw.githubusercontent.com/potapenko/playphraseme-site/d50a62a6bc8f463e08365dca96b3a6e5dde4fb12/src/clj/playphraseme/common/google_translate.clj | clojure | (ns playphraseme.common.google-translate
(:require [clj-http.client :as client]
[playphraseme.app.config :refer [env]]
[cheshire.core :as parser]
[clojure.data.json :as json]
[playphraseme.api.queries.common-phrases :as common-phrases-db]
[clojure.string :as... | |
691433f80e62010dbe539197aebce3e9657cf50b3115a50620f9630ac45a5222 | ygmpkk/house | Utils.hs | -- | Various utilities used in the network protocol stack modules
module Net.Utils where
import Net.Concurrent
import Kernel.Bits
import Data.List(unfoldr)
import Data.Array.IArray
class Functor f = > Sequence f where sequence : : = > f ( m a ) - > m ( f a )
class Functor f => Container f where contents :: f a -> a... | null | https://raw.githubusercontent.com/ygmpkk/house/1ed0eed82139869e85e3c5532f2b579cf2566fa2/kernel/Net/Utils.hs | haskell | | Various utilities used in the network protocol stack modules
-----------------------------------------------------------------------------
-- If there is a timeout, m is still completed and the result is ignored...
timeout t m =
do c <- newChan
fork $ do delay t ; writeChan c Nothing
fork $ writeChan c ... | module Net.Utils where
import Net.Concurrent
import Kernel.Bits
import Data.List(unfoldr)
import Data.Array.IArray
class Functor f = > Sequence f where sequence : : = > f ( m a ) - > m ( f a )
class Functor f => Container f where contents :: f a -> a
replace x b = fmap (const b) x
emap f p= fmap (replace p) (f (c... |
eca046922e7efe5a1cf91dab557bc8f6db7d5d5928eb8ace32a8716372f9ddad | shayne-fletcher/ghc-lib-parser-ex | Expr.hs | Copyright ( c ) 2020 , . All rights reserved .
SPDX - License - Identifier : BSD-3 - Clause .
# OPTIONS_GHC -Wno - missing - fields #
# LANGUAGE CPP #
# LANGUAGE LambdaCase #
#include "ghclib_api.h"
module Language.Haskell.GhclibParserEx.GHC.Hs.Expr(
isTag, isDol, isDot, isReturn, isSection, isRecConstr, isRec... | null | https://raw.githubusercontent.com/shayne-fletcher/ghc-lib-parser-ex/a3788bbc12434ee3cf81a2b4cc345288a9ca422e/src/Language/Haskell/GhclibParserEx/GHC/Hs/Expr.hs | haskell | 'True' if the provided expression is a variable with name 'tag'.
Allow both 'pure' and 'return' as they have the same semantics.
Backwards compat.
Other (unknown) constructors may have bang patterns in them, so
approximate.
Field puns in updates have a different type to field puns in
constructions.
Contains a '... | Copyright ( c ) 2020 , . All rights reserved .
SPDX - License - Identifier : BSD-3 - Clause .
# OPTIONS_GHC -Wno - missing - fields #
# LANGUAGE CPP #
# LANGUAGE LambdaCase #
#include "ghclib_api.h"
module Language.Haskell.GhclibParserEx.GHC.Hs.Expr(
isTag, isDol, isDot, isReturn, isSection, isRecConstr, isRec... |
68909ee2b1339a99860b4b665667cdba8069b781efdf5e097cb4b886c3f1a5b1 | janestreet/krb | test_mode_protocol_intf.ml | open! Core
open Async
module type S = sig
type protocol_backend
module Connection : T
module Server : sig
val serve
: authorize:Authorize.t
-> principal:Principal.Name.t
-> client_addr:Socket.Address.Inet.t
-> protocol_backend
-> Connection.t Protocol_intf.serve_res
end
... | null | https://raw.githubusercontent.com/janestreet/krb/76ff1f5372c7610d8b14ea1a143a79f74d6e8c26/src/test_mode_protocol_intf.ml | ocaml | open! Core
open Async
module type S = sig
type protocol_backend
module Connection : T
module Server : sig
val serve
: authorize:Authorize.t
-> principal:Principal.Name.t
-> client_addr:Socket.Address.Inet.t
-> protocol_backend
-> Connection.t Protocol_intf.serve_res
end
... | |
3f4385394354825a02f899d381d9b840c88e3ad282d2aaf30cfdf5ebc4efe41e | tweag/ormolu | unboxed-sums.hs | # LANGUAGE UnboxedSums #
foo :: (# Int|Bool #)
foo = (# 1 | #)
bar :: (#Int|Int|Int|Int #)
bar = (# | |2| #)
baz :: (# Int |
Int | Int | Int | Int | Int | Int |
Int | Int #)
baz = (# |
| | 10 | | | |
| #)
type UbxPair = (# | #)
| null | https://raw.githubusercontent.com/tweag/ormolu/54642a7966d1d0787ba84636a2eb52f6729f600e/data/examples/declaration/value/function/unboxed-sums.hs | haskell | # LANGUAGE UnboxedSums #
foo :: (# Int|Bool #)
foo = (# 1 | #)
bar :: (#Int|Int|Int|Int #)
bar = (# | |2| #)
baz :: (# Int |
Int | Int | Int | Int | Int | Int |
Int | Int #)
baz = (# |
| | 10 | | | |
| #)
type UbxPair = (# | #)
| |
446c2e3e9b9d6c3e0a8ab0d98afcc85309530e7370ee5eedcf99376bf9a4c011 | janestreet/hardcaml_of_verilog | verilog_design.mli | open Base
module Parameter : sig
type t = Hardcaml.Parameter.t [@@deriving sexp, equal]
val create : name:string -> value:Hardcaml.Parameter.Value.t -> t
val name : t -> string
val value : t -> Hardcaml.Parameter.Value.t
val string_of_value : t -> string
end
module Parameters : sig
type t = Parameter.t l... | null | https://raw.githubusercontent.com/janestreet/hardcaml_of_verilog/c1d4e5abe18a1b15e8858151a43aa69efcbbe07b/src/verilog_design.mli | ocaml | * Convert to a list. The "top" of the design is at the head of the list.
* Name of top level module
* Override the parameters of the top level module
* [map_paths t ~f] applies [f] to each modules path
* Read verilog files from [ocaml-cruch]ed file system(s) and extract to temp files.
* Read verilog files from [e... | open Base
module Parameter : sig
type t = Hardcaml.Parameter.t [@@deriving sexp, equal]
val create : name:string -> value:Hardcaml.Parameter.Value.t -> t
val name : t -> string
val value : t -> Hardcaml.Parameter.Value.t
val string_of_value : t -> string
end
module Parameters : sig
type t = Parameter.t l... |
3977e6bcca4f1d8481bea3ac814dffb64c61169b7fca4c8fd7bfd70d774cd189 | PacktWorkshops/The-Clojure-Workshop | project.clj | (defproject js-interop "0.1.0-SNAPSHOT"
:dependencies [[org.clojure/clojure "1.9.0"]
[org.clojure/clojurescript "1.10.339"]]
:jvm-opts ^:replace ["-Xmx1g" "-server"]
:plugins [[lein-npm "0.6.2"]]
:npm {:dependencies [[source-map-support "0.4.0"]]}
:source-paths ["test" "target/classes"]
:cl... | null | https://raw.githubusercontent.com/PacktWorkshops/The-Clojure-Workshop/3d309bb0e46a41ce2c93737870433b47ce0ba6a2/Chapter09/tests/Exercise9.07/js-interop/project.clj | clojure | (defproject js-interop "0.1.0-SNAPSHOT"
:dependencies [[org.clojure/clojure "1.9.0"]
[org.clojure/clojurescript "1.10.339"]]
:jvm-opts ^:replace ["-Xmx1g" "-server"]
:plugins [[lein-npm "0.6.2"]]
:npm {:dependencies [[source-map-support "0.4.0"]]}
:source-paths ["test" "target/classes"]
:cl... | |
b4bc0a018df64ae5b38d7f39f091b27e55ec8fb058a10a180993a5cbfc6393be | keigoi/session-ocaml | unixAdapter.ml | open Session
let bufsize = 4096
type raw_chan = {in_ch:in_channel; in_buf:string; out_ch:out_channel}
type 'p net = raw_chan -> (('p, serv) sess * all_empty, all_empty, unit) session
let consume (read:string->'v parse_result) {in_ch;in_buf} =
let consume_buf : string -> 'v parse_result = function
FIXME : EOF
|... | null | https://raw.githubusercontent.com/keigoi/session-ocaml/f365456043b349874a5ce5444d313f365d5573c6/lib/unixAdapter.ml | ocaml | open Session
let bufsize = 4096
type raw_chan = {in_ch:in_channel; in_buf:string; out_ch:out_channel}
type 'p net = raw_chan -> (('p, serv) sess * all_empty, all_empty, unit) session
let consume (read:string->'v parse_result) {in_ch;in_buf} =
let consume_buf : string -> 'v parse_result = function
FIXME : EOF
|... | |
5162c403691d32d56cec893b712209aff3aeb79247a41b008e1e884ea76c5500 | tolysz/postgresql-simple-typed | DBmoreTH.hs | # LANGUAGE NoMonomorphismRestriction #
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE ScopedTypeVariables #-}
# LANGUAGE TemplateHaskell #
# LANGUAGE TupleSections #
{-# LANGUAGE CPP #-}
module Database.PostgreSQL.Simple.DBmoreTH (qr) where
import ... | null | https://raw.githubusercontent.com/tolysz/postgresql-simple-typed/69718cf6bf52d8d663e4c2661db9d8e337f1bbb9/src/Database/PostgreSQL/Simple/DBmoreTH.hs | haskell | # LANGUAGE OverloadedStrings #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE CPP # | # LANGUAGE NoMonomorphismRestriction #
# LANGUAGE TemplateHaskell #
# LANGUAGE TupleSections #
module Database.PostgreSQL.Simple.DBmoreTH (qr) where
import Control.Applicative (Applicative (..), (*>), (<$>), (<|>))
import Control.Monad ... |
ae98211d221ef2ec455581f52f12e571564ef4a46e7143d67c540b6d47d84a5c | FlowForwarding/LINC-Switch | linc_us5_actions.erl | %%------------------------------------------------------------------------------
Copyright 2012 FlowForwarding.org
%%
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
%% you may not use this file except in compliance with the License.
%% You may obtain a copy of the License at
%%
%% -2.0
%%... | null | https://raw.githubusercontent.com/FlowForwarding/LINC-Switch/9c28e7c8677c03440a62023292dd700fef0c3420/apps/linc_us5/src/linc_us5_actions.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, eithe... | Copyright 2012 FlowForwarding.org
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
distributed under the License is distributed on an " AS IS " BASIS ,
@author Erlang Solutions Ltd. < >
2012 FlowForwarding.org
-module(linc_us5_actions).
-export([apply_set/1,
apply_list/2]).
... |
4592b560e09b8a3ab77f9d59e08541071b4cf72a0f4b6d65151bc70863c02613 | r0man/sablono | specs_test.cljc | (ns sablono.specs-test
(:require [clojure.spec.alpha :as s]
[clojure.test :refer [deftest is]]
[sablono.specs :as specs]))
(deftest execise-tag
(is (s/exercise ::specs/tag)))
(deftest execise-attribute
(is (s/exercise ::specs/attribute)))
(deftest execise-children
(is (s/exercise ::sp... | null | https://raw.githubusercontent.com/r0man/sablono/3221c5bacd1c81f1f79bc1ec86f3d2652b1a12d2/test/sablono/specs_test.cljc | clojure | (ns sablono.specs-test
(:require [clojure.spec.alpha :as s]
[clojure.test :refer [deftest is]]
[sablono.specs :as specs]))
(deftest execise-tag
(is (s/exercise ::specs/tag)))
(deftest execise-attribute
(is (s/exercise ::specs/attribute)))
(deftest execise-children
(is (s/exercise ::sp... | |
f4115560b4bfe74086696210c5330b8a82ab08d072104f900d359eb02dc6f6d9 | travelping/ergw | gtp_c_lib.erl | Copyright 2015 - 2019 , Travelping GmbH < >
%% 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 option ) any later version .
-module(gtp_c_lib... | null | https://raw.githubusercontent.com/travelping/ergw/1b6cc3ee89eea4cf9df1d7de612744f0a850dfd9/apps/ergw_core/src/gtp_c_lib.erl | erlang | This program is free software; you can redistribute it and/or
permited characters (labels have to start with letters and
not end with hyphens, but we don't check that)
also do not consider "." (dot) as not permitted character
but split labels by it
==================================================================... | Copyright 2015 - 2019 , Travelping GmbH < >
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 option ) any later version .
-module(gtp_c_lib).
-compile({parse_transform, cut}).
-export([fmt_gtp/1]).
-exp... |
28108af959466fb573b3a5207c0064f7059741d6d075045c3f16454f095b3761 | marigold-dev/deku | payload.ml | type payload = Payload of string list
type t = payload
let encoding = Data_encoding.(list string)
let encode ~payload =
let (Payload payload) = payload in
Data_encoding.Binary.to_string_exn encoding payload
let decode ~payload =
let payload = Data_encoding.Binary.of_string_exn encoding payload in
Payload pay... | null | https://raw.githubusercontent.com/marigold-dev/deku/21ec2bf05ce688c5b6012be16545175e75403f06/deku-p/src/core/consensus/payload.ml | ocaml | type payload = Payload of string list
type t = payload
let encoding = Data_encoding.(list string)
let encode ~payload =
let (Payload payload) = payload in
Data_encoding.Binary.to_string_exn encoding payload
let decode ~payload =
let payload = Data_encoding.Binary.of_string_exn encoding payload in
Payload pay... | |
0ff0e303bb33fa8b2007b90275c47a04b4a18d20d3a568a54a79207e82c981de | avsm/mirage-duniverse | uTop.mli |
* uTop.mli
* --------
* Copyright : ( c ) 2011 , < >
* Licence : BSD3
*
* This file is a part of utop .
* uTop.mli
* --------
* Copyright : (c) 2011, Jeremie Dimino <>
* Licence : BSD3
*
* This file is a part of utop.
*)
(** UTop configuration. *)
open React
val version : string
... | null | https://raw.githubusercontent.com/avsm/mirage-duniverse/983e115ff5a9fb37e3176c373e227e9379f0d777/ocaml_modules/utop/src/lib/uTop.mli | ocaml | * UTop configuration.
* Version of utop.
* The number of commands already executed.
* The set of OCaml keywords.
* Add a new OCaml keyword.
* The user interface in use.
* Returns the user interface in use.
* Returns the value of {!hide_reserved}.
* Modifies {!hide_reserved}.
* Returns the value of {!topfind_ve... |
* uTop.mli
* --------
* Copyright : ( c ) 2011 , < >
* Licence : BSD3
*
* This file is a part of utop .
* uTop.mli
* --------
* Copyright : (c) 2011, Jeremie Dimino <>
* Licence : BSD3
*
* This file is a part of utop.
*)
open React
val version : string
val count : int React.signa... |
229157d3da5387e883d87c862baf1111e31e18bce5155e416e255875ba881c65 | ggreif/omega | Main.hs |
module Main where
import qualified Toplevel as T
main = T.omega
| null | https://raw.githubusercontent.com/ggreif/omega/016a3b48313ec2c68e8d8ad60147015bc38f2767/src/Main.hs | haskell |
module Main where
import qualified Toplevel as T
main = T.omega
| |
aee8f54456528d790023753fbd894c3d1f54715017d7d145e08be266616e6dd6 | erlang-ls/erlang_ls | diagnostics_behaviour_impl.erl | -module(diagnostics_behaviour_impl).
-behaviour(diagnostics_behaviour).
| null | https://raw.githubusercontent.com/erlang-ls/erlang_ls/36bf0815e35db5d25a76e80f98f306f25fff7d8c/apps/els_lsp/priv/code_navigation/src/diagnostics_behaviour_impl.erl | erlang | -module(diagnostics_behaviour_impl).
-behaviour(diagnostics_behaviour).
| |
cebaada42ae336f9b97fd03ba998364c0c01cf764b41d887af8ceb6e04ed3a28 | elaforge/karya | FltkUtil.hs | Copyright 2017
-- This program is distributed under the terms of the GNU General Public
-- License 3.0, see COPYING or -3.0.txt
-- | Utilities for "Util.Fltk".
--
-- It's a separate module so it can avoid foreign imports, which break ghci.
module Util.FltkUtil where
import qualified Data.Char as Char
import Data.M... | null | https://raw.githubusercontent.com/elaforge/karya/471a2131f5a68b3b10b1a138e6f9ed1282980a18/Util/FltkUtil.hs | haskell | This program is distributed under the terms of the GNU General Public
License 3.0, see COPYING or -3.0.txt
| Utilities for "Util.Fltk".
It's a separate module so it can avoid foreign imports, which break ghci. | Copyright 2017
module Util.FltkUtil where
import qualified Data.Char as Char
import Data.Maybe (fromMaybe)
import qualified System.Console.GetOpt as GetOpt
type Pixels = Int
data Geometry = Geometry (Maybe (Pixels, Pixels)) (Maybe Pixels) (Maybe Pixels)
deriving (Eq, Show)
option :: (Geometry -> a) -> GetO... |
78516d87dfa6a14662aef2c68755e6255f91998b7f4011ca3e8e93ed6a85fff6 | lspector/Clojush | krypto.clj | ;; krypto.clj
an example problem for clojush , a Push / PushGP system written in Clojure
, , 2010
(ns clojush.problems.demos.krypto
(:use [clojush.pushgp.pushgp]
[clojush.pushstate]
[clojush.interpreter]
[clojure.math.numeric-tower]))
Chooses and then tries to solve ( via pushgp ) a... | null | https://raw.githubusercontent.com/lspector/Clojush/685b991535607cf942ae1500557171a0739982c3/src/clojush/problems/demos/krypto.clj | clojure | krypto.clj
See (game)
Might produce solutions that rely on truncation in integer division.
deck with right number of each card | an example problem for clojush , a Push / PushGP system written in Clojure
, , 2010
(ns clojush.problems.demos.krypto
(:use [clojush.pushgp.pushgp]
[clojush.pushstate]
[clojush.interpreter]
[clojure.math.numeric-tower]))
Chooses and then tries to solve ( via pushgp ) a game of Krypt... |
5057d247b3965c70e547544aeb2f2a9b7b42bb60e0a68bfd46f2e4c4be5ba865 | lspitzner/brittany | Test124.hs | testMethod foo bar baz qux =
let x = undefined foo bar baz qux qux baz bar :: String
-- some comment explaining the in expression
in undefined foo x :: String
| null | https://raw.githubusercontent.com/lspitzner/brittany/a15eed5f3608bf1fa7084fcf008c6ecb79542562/data/Test124.hs | haskell | some comment explaining the in expression | testMethod foo bar baz qux =
let x = undefined foo bar baz qux qux baz bar :: String
in undefined foo x :: String
|
bc88e4d5138c1f1ce15750a762b951474dad29c8dc2def656f3acb54ace18470 | flipstone/orville | Trigger.hs | module Database.Orville.PostgreSQL.Trigger
( insertTriggered
, InsertTrigger(insertTriggers)
, updateTriggered
, UpdateTrigger(updateTriggers)
, deleteTriggered
, DeleteTrigger(deleteTriggers)
, MonadTrigger(runTriggers)
, OrvilleTriggerT
, RecordedTriggers
, committedTriggers
, uncommittedTrigger... | null | https://raw.githubusercontent.com/flipstone/orville/aee8d7a47ab3a7b442fdb274dbb5a95d687a23ce/orville-postgresql/src/Database/Orville/PostgreSQL/Trigger.hs | haskell | module Database.Orville.PostgreSQL.Trigger
( insertTriggered
, InsertTrigger(insertTriggers)
, updateTriggered
, UpdateTrigger(updateTriggers)
, deleteTriggered
, DeleteTrigger(deleteTriggers)
, MonadTrigger(runTriggers)
, OrvilleTriggerT
, RecordedTriggers
, committedTriggers
, uncommittedTrigger... | |
b2cd1baf773d228532a40d4121bc0f73a8c99b2b7273a88f1373dd01b81f32a2 | borkdude/advent-of-cljc | dfuenzalida.cljc | (ns aoc.y2017.d09.dfuenzalida
(:refer-clojure :exclude [read-string format])
(:require
[aoc.utils :as u :refer [deftest read-string format]]
[aoc.y2017.d09.data :refer [input answer-1 answer-2]]
[clojure.string :as s]
[clojure.test :as t :refer [is testing]]))
(defn clean [s]
(-> s
(s/replace #... | null | https://raw.githubusercontent.com/borkdude/advent-of-cljc/17c8abb876b95ab01eee418f1da2e402e845c596/src/aoc/y2017/d09/dfuenzalida.cljc | clojure | Scratch | (ns aoc.y2017.d09.dfuenzalida
(:refer-clojure :exclude [read-string format])
(:require
[aoc.utils :as u :refer [deftest read-string format]]
[aoc.y2017.d09.data :refer [input answer-1 answer-2]]
[clojure.string :as s]
[clojure.test :as t :refer [is testing]]))
(defn clean [s]
(-> s
(s/replace #... |
492dfeee6a3fac8c9d2200b844c482c74446f3a7578580ec8440eec3e6b3dd63 | unnohideyuki/bunny | Symbol.hs | module Symbol where
import Data.Char
import qualified Data.Map.Strict as Map
type Id = String
type Pos = (Int, Int) -- line number, column number
posLine :: Pos -> Int
posLine (line, _) = line
posCol :: Pos -> Int
posCol (_, col) = col
data Name = Name { origName :: Id
, namePos :: Po... | null | https://raw.githubusercontent.com/unnohideyuki/bunny/501856ff48f14b252b674585f25a2bf3801cb185/compiler/src/Symbol.hs | haskell | line number, column number | module Symbol where
import Data.Char
import qualified Data.Map.Strict as Map
type Id = String
posLine :: Pos -> Int
posLine (line, _) = line
posCol :: Pos -> Int
posCol (_, col) = col
data Name = Name { origName :: Id
, namePos :: Pos
, isConName :: Bool
... |
fc5b0c777b0937cd0f13cb3fee471a2909256eac983ae9036f777ef28664a52b | silky/myth | arith.ml | -matches 2 -scrutinee 8
type nat =
| O
| S of nat
type cmp =
| LT
| EQ
| GT
type exp =
| Const of nat
| Sum of exp * exp
| Prod of exp * exp
| Pred of exp
| Max of exp * exp
let rec sum (n1:nat) (n2:nat) : nat =
match n1 with
| O -> n2
| S (n1) -> S (sum n1 n2)
;;
let rec mult (n1:nat) (n2:na... | null | https://raw.githubusercontent.com/silky/myth/b631edefb2a27a1d731daa6654517d91ca660b95/tests/pldi-2015-extended/arith.ml | ocaml | -matches 2 -scrutinee 8
type nat =
| O
| S of nat
type cmp =
| LT
| EQ
| GT
type exp =
| Const of nat
| Sum of exp * exp
| Prod of exp * exp
| Pred of exp
| Max of exp * exp
let rec sum (n1:nat) (n2:nat) : nat =
match n1 with
| O -> n2
| S (n1) -> S (sum n1 n2)
;;
let rec mult (n1:nat) (n2:na... | |
523fe14349df1430776610e6a54eb2a5bf13a2e9eb4412905470d37bd17d816b | SKS-Keyserver/sks-keyserver | bitstring.mli | exception Error of string
exception LengthError of string
val width : int
type t
val bytelength : int -> int
val create : int -> t
val get : t -> int -> int
val lget : t -> int -> bool
val flip : t -> int -> unit
val set : t -> int -> unit
val unset : t -> int -> unit
val setval : t -> int -> bool -> unit
val print : t... | null | https://raw.githubusercontent.com/SKS-Keyserver/sks-keyserver/a4e5267d817cddbdfee13d07a7fb38a9b94b3eee/bitstring.mli | ocaml | exception Error of string
exception LengthError of string
val width : int
type t
val bytelength : int -> int
val create : int -> t
val get : t -> int -> int
val lget : t -> int -> bool
val flip : t -> int -> unit
val set : t -> int -> unit
val unset : t -> int -> unit
val setval : t -> int -> bool -> unit
val print : t... | |
f05cdbd31d35ce795c55b6990ed27bf990053b868557ae00891962835bbfd9cd | SparkFund/types-to-schema | test_functions.clj | (ns types-to-schema.test-functions
(:require [clojure.core.typed :as t]))
(t/defalias TestAlias '{:test t/Keyword})
(t/defalias TestRecursiveAlias (t/U nil (t/List TestRecursiveAlias)))
(def function-calls (atom 0))
(t/ann ^:no-check broken-input [TestAlias Long -> Long])
(defn broken-input
"Used for when the f... | null | https://raw.githubusercontent.com/SparkFund/types-to-schema/e7e88359422417e3a6fe79f004727412f561762e/test/types_to_schema/test_functions.clj | clojure | putting these out of natural order to be difficult on ourselves. | (ns types-to-schema.test-functions
(:require [clojure.core.typed :as t]))
(t/defalias TestAlias '{:test t/Keyword})
(t/defalias TestRecursiveAlias (t/U nil (t/List TestRecursiveAlias)))
(def function-calls (atom 0))
(t/ann ^:no-check broken-input [TestAlias Long -> Long])
(defn broken-input
"Used for when the f... |
d916f649284af910f0538efad47016674d8ad484c8e52e07eb93ad024c1c87c9 | racket/redex | red-sem-macro-helpers.rkt | #lang racket/base
(provide extract-names)
(require racket/match)
(define (extract-names stx)
(let ([dup-names
(let loop ([sexp (syntax->datum stx)]
[names null])
(match sexp
[`(name ,(and sym (? symbol?)) ,pat)
(loop pat (cons sym names))]
... | null | https://raw.githubusercontent.com/racket/redex/4c2dc96d90cedeb08ec1850575079b952c5ad396/redex-lib/redex/private/red-sem-macro-helpers.rkt | racket | #lang racket/base
(provide extract-names)
(require racket/match)
(define (extract-names stx)
(let ([dup-names
(let loop ([sexp (syntax->datum stx)]
[names null])
(match sexp
[`(name ,(and sym (? symbol?)) ,pat)
(loop pat (cons sym names))]
... | |
50e520a14377a77c9742e098d5520ee6dd11b28816153f86b4fac55e5b8a75cb | ejgallego/coq-lsp | range.mli | (************************************************************************)
(* Flèche => document manager: Language Support *)
Copyright 2019 - 2023 Inria -- Dual License LGPL 2.1 / GPL3 +
Written by :
(****************************************... | null | https://raw.githubusercontent.com/ejgallego/coq-lsp/e20f1f7146580b3b21d200da75650882e71ad81a/lang/range.mli | ocaml | **********************************************************************
Flèche => document manager: Language Support
********************************************************************** | Copyright 2019 - 2023 Inria -- Dual License LGPL 2.1 / GPL3 +
Written by :
type t =
{ start : Point.t
; end_ : Point.t [@key "end"]
}
val pp : Format.formatter -> t -> unit
val to_string : t -> string
|
11fde046bf4098435a7bbb9a2cb73dd1d61ceb92d0c479e75608dac6694d6ace | fortytools/holumbus | StrMapTest.hs | -- ----------------------------------------------------------------------------
|
Module : StrMapTest
Copyright : Copyright ( C ) 2007
License : MIT
Maintainer : ( )
Stability : experimental
Portability : portable
Version : 0.1
The some unit tests for the Hol... | null | https://raw.githubusercontent.com/fortytools/holumbus/4b2f7b832feab2715a4d48be0b07dca018eaa8e8/searchengine/test/StrMapTest.hs | haskell | ----------------------------------------------------------------------------
----------------------------------------------------------------------------
# OPTIONS -fno-warn-type-defaults -fno-warn-orphans -fno-warn-missing-signatures # |
|
Module : StrMapTest
Copyright : Copyright ( C ) 2007
License : MIT
Maintainer : ( )
Stability : experimental
Portability : portable
Version : 0.1
The some unit tests for the Holumbus trie .
Module : StrMapTest
Copyright : Copyright (C) 2007 Tim... |
46af4e489dbc97efb98f58fcf292f9985e592d35c8681d71a88e967ad970d090 | clj-commons/etaoin | spec.clj | (ns ^:no-doc etaoin.ide.impl.spec
"
Parsing IDE flow with spec.
"
(:require
[clojure.spec.alpha :as s]))
(def control-flow-commands
#{:do :times :while :forEach :if :elseIf :else :end :repeatIf})
(defn cmd? [cmd]
(fn [command]
(some-> command :command (= cmd))))
(s/def ::command-if
(s/cat :if... | null | https://raw.githubusercontent.com/clj-commons/etaoin/e1b7df647740536cec7b8528fe4c84ae21f94ab7/src/etaoin/ide/impl/spec.clj | clojure | (ns ^:no-doc etaoin.ide.impl.spec
"
Parsing IDE flow with spec.
"
(:require
[clojure.spec.alpha :as s]))
(def control-flow-commands
#{:do :times :while :forEach :if :elseIf :else :end :repeatIf})
(defn cmd? [cmd]
(fn [command]
(some-> command :command (= cmd))))
(s/def ::command-if
(s/cat :if... | |
4a09163a3ef3bcdf5216144d7a3b56d26edcc061a66a804cd586a9223de89dd3 | 2600hz-archive/whistle | jonny5_sup.erl | %%%-------------------------------------------------------------------
@author < >
( C ) 2011 , VoIP INC
%%% @doc
%%%
%%% @end
Created : 7 Jul 2011 by < >
%%%-------------------------------------------------------------------
-module(jonny5_sup).
-behaviour(supervisor).
%% API
-export([start_link/0, up... | null | https://raw.githubusercontent.com/2600hz-archive/whistle/1a256604f0d037fac409ad5a55b6b17e545dcbf9/whistle_apps/apps/jonny5/src/jonny5_sup.erl | erlang | -------------------------------------------------------------------
@doc
@end
-------------------------------------------------------------------
API
Supervisor callbacks
Helper macro for declaring children of supervisor
===================================================================
API functions
========... | @author < >
( C ) 2011 , VoIP INC
Created : 7 Jul 2011 by < >
-module(jonny5_sup).
-behaviour(supervisor).
-export([start_link/0, upgrade/0, start_child/1, get_blacklist_server/0]).
-export([init/1]).
-include("jonny5.hrl").
-define(CHILD(I, Type), {I, {I, start_link, []}, permanent, 5000, Type, [I]... |
2bd00d199afce396b1f9a1ac68f14ba939aa1295b49a6c9c35fceabe101a2067 | johnwhitington/camlpdf | pdfmarks.ml | (* PDF Bookmarks *)
open Pdfutil
type t =
{level : int;
text : string;
target : Pdfdest.t;
isopen : bool}
let string_of_bookmark m =
Printf.sprintf "%i %s %s %b\n"
m.level
m.text
(Pdfwrite.string_of_pdf (Pdfdest.pdfobject_of_destination m.target))
m.isopen
let remove_bookmarks pdf =... | null | https://raw.githubusercontent.com/johnwhitington/camlpdf/a263cca958dfeaee8092bde6e54fc1667a695b2f/pdfmarks.ml | ocaml | PDF Bookmarks
bool is will_be_open
True if there are any open nodes in the tree
Total visible nodes in a tree
Add /Parent links to root
Calculate sum of the number of visible descendent items
Negative - abs value is number of descendants which would be visible
Add /Parent entries to an ntree
Make an nt... | open Pdfutil
type t =
{level : int;
text : string;
target : Pdfdest.t;
isopen : bool}
let string_of_bookmark m =
Printf.sprintf "%i %s %s %b\n"
m.level
m.text
(Pdfwrite.string_of_pdf (Pdfdest.pdfobject_of_destination m.target))
m.isopen
let remove_bookmarks pdf =
match Pdf.lookup_... |
9423ab4513ff78d82ee1c75ba49469cdde68473e8ee85345cafcabfa8d81fe50 | openmusic-project/openmusic | treeeditor.lisp | ;;===========================================================================
;LW Score Editors
;Interface tools for score editing and inspection
;;===========================================================================
;===========================================================================
; This program i... | null | https://raw.githubusercontent.com/openmusic-project/openmusic/64bf80647c71d1f863ef44fda8ef9e1db9c08062/OPENMUSIC/code/api/om-LW/editors/treeeditor.lisp | lisp | ===========================================================================
LW Score Editors
Interface tools for score editing and inspection
===========================================================================
===========================================================================
This program is free so... |
modify it under the terms of the GNU General Public License
of the License , or ( at your option ) any later version .
You should have received a copy of the GNU General Public License
Foundation , Inc. , 59 Temple Place - Suite 330 , Boston , MA 02111 - 1307 , USA .
Author :
DocFile
(in-package :om-e... |
ea7ec16fed274194337748e704428c81f6ad41a8fcacfc17a658eaf1d47aa6d8 | ormf/cm | asdf.lisp | This is asdf : Another System Definition Facility . $ Revision$
;;;
;;; Feedback, bug reports, and patches are all welcome: please mail to
< > . But note first that the canonical
;;; source for asdf is presently the cCLan CVS repository at
;;; <URL:-bin/viewcvs.cgi/cclan/asdf/>
;;;
;;; If you obtained this cop... | null | https://raw.githubusercontent.com/ormf/cm/26843eec009bd6c214992a8e67c49fffa16d9530/src/asdf.lisp | lisp |
Feedback, bug reports, and patches are all welcome: please mail to
source for asdf is presently the cCLan CVS repository at
<URL:-bin/viewcvs.cgi/cclan/asdf/>
If you obtained this copy from anywhere else, and you experience
trouble using it, or find bugs, you may want to check at the
location above for a more r... | This is asdf : Another System Definition Facility . $ Revision$
< > . But note first that the canonical
bugs . There are usually two " supported " revisions - the CVS HEAD
Copyright ( c ) 2001 - 2003 and contributors
" Software " ) , to deal in the Software without restriction , including
distribu... |
0f2e065472f4f3f6356bb7a2bdf24538fe7eb623389e2151b75e9424bfe51e31 | senapk/funcional_arcade | solver.hs | unico x xs = 1 == length (filter (==x) xs)
| null | https://raw.githubusercontent.com/senapk/funcional_arcade/70fa04b4799d5a8c7e5add39d9f217f38f418600/base/019/solver.hs | haskell | unico x xs = 1 == length (filter (==x) xs)
| |
7717c0a424a6388de84a13cafe4371e5f2e9d51d16f868c898b23c8a85436020 | haskell-compat/base-compat | Compat.hs | # LANGUAGE CPP , NoImplicitPrelude #
module Data.Bool.Compat (
module Base
, bool
) where
import Data.Bool as Base
#if !(MIN_VERSION_base(4,7,0))
-- | Case analysis for the 'Bool' type.
-- @bool a b p@ evaluates to @a@ when @p@ is @False@, and evaluates to @b@
when @p@ is
--
/Since : 4.7.0.0/
bool :: a -> a ->... | null | https://raw.githubusercontent.com/haskell-compat/base-compat/847aa35c4142f529525ffc645cd035ddb23ce8ee/base-compat/src/Data/Bool/Compat.hs | haskell | | Case analysis for the 'Bool' type.
@bool a b p@ evaluates to @a@ when @p@ is @False@, and evaluates to @b@
| # LANGUAGE CPP , NoImplicitPrelude #
module Data.Bool.Compat (
module Base
, bool
) where
import Data.Bool as Base
#if !(MIN_VERSION_base(4,7,0))
when @p@ is
/Since : 4.7.0.0/
bool :: a -> a -> Bool -> a
bool f _ False = f
bool _ t True = t
#endif
|
92af0dc3f8364432dac701f3185a4c05755eb23fd73120fa711e7e70d6fa5882 | scrintal/heroicons-reagent | gif.cljs | (ns com.scrintal.heroicons.mini.gif)
(defn render []
[:svg {:xmlns ""
:viewBox "0 0 20 20"
:fill "currentColor"
:aria-hidden "true"}
[:path {:fillRule "evenodd"
:d "M1 5.25A2.25 2.25 0 013.25 3h13.5A2.25 2.25 0 0119 5.25v9.5A2.25 2.25 0 0116.75 17H3.25... | null | https://raw.githubusercontent.com/scrintal/heroicons-reagent/572f51d2466697ec4d38813663ee2588960365b6/src/com/scrintal/heroicons/mini/gif.cljs | clojure | (ns com.scrintal.heroicons.mini.gif)
(defn render []
[:svg {:xmlns ""
:viewBox "0 0 20 20"
:fill "currentColor"
:aria-hidden "true"}
[:path {:fillRule "evenodd"
:d "M1 5.25A2.25 2.25 0 013.25 3h13.5A2.25 2.25 0 0119 5.25v9.5A2.25 2.25 0 0116.75 17H3.25... | |
3942a832a57bfcced041fd96872ce700c32c374998842dfc24f125253f71efa8 | dakk/bitcoinml | simplicity.mli | type t | null | https://raw.githubusercontent.com/dakk/bitcoinml/16a09393f4b10961db91f30200e2926f03a8716c/src/experimental/simplicity.mli | ocaml | type t | |
83022a5afe12c71293d8358dec59a9bb0c27fe5fe00fd64dc7b9d8556f09de2d | takikawa/racket-ppa | phase+space.rkt | #lang racket/base
(require ffi/unsafe/atomic
racket/private/place-local
(rename-in racket/phase+space
[phase+space+ raw:phase+space+])
"phase.rkt")
;; Terminology:
;;
;; See "phase.rkt" for an explanation of "<x>" vs. "<x> shift".
;;
;; In the case of spaces, the represen... | null | https://raw.githubusercontent.com/takikawa/racket-ppa/26d6ae74a1b19258c9789b7c14c074d867a4b56b/src/expander/common/phase%2Bspace.rkt | racket | Terminology:
See "phase.rkt" for an explanation of "<x>" vs. "<x> shift".
In the case of spaces, the representations of "space" and
"space shift" are different:
* A standalone space is either #f or a symbol
* A standalone space shift is either #f, a symbol, or '#:none; a
space shift of #f shifts other s... | #lang racket/base
(require ffi/unsafe/atomic
racket/private/place-local
(rename-in racket/phase+space
[phase+space+ raw:phase+space+])
"phase.rkt")
Standalone space shifts are only ever represented internally . They
(provide space?
space+
p... |
820c642cf4396db19de20f014d8eeff4047ea48830e454c7c4d5bc432b7393b1 | amuletml/amulet | Raise.hs | # LANGUAGE ScopedTypeVariables #
module Syntax.Raise (raiseT) where
import Data.Bifunctor
import Syntax.Var
import Syntax
| Raise variables from one phase to another within a type .
{-# DEPRECATED #-}
raiseT :: forall p p'
. (Var p -> Var p')
-- ^ Raise a single variable. This will be a type variabl... | null | https://raw.githubusercontent.com/amuletml/amulet/fcba0b7e198b8d354e95722bbe118bccc8483f4e/src/Syntax/Raise.hs | haskell | # DEPRECATED #
^ Raise a single variable. This will be a type variable, type
name or constructor. | # LANGUAGE ScopedTypeVariables #
module Syntax.Raise (raiseT) where
import Data.Bifunctor
import Syntax.Var
import Syntax
| Raise variables from one phase to another within a type .
raiseT :: forall p p'
. (Var p -> Var p')
-> (TypeAnn p -> TypeAnn p')
-> Type p -> Type p'
raiseT fv fa = ty w... |
85e4b6b2174f5e4a6591fc458b01c88807d9abaf75c2be5e57e5e46af258826b | webyrd/n-grams-for-synthesis | test-suite.body.scm | ;;; This doesn't test weakness, external representation, and quasiquote.
(test-begin "SRFI-126")
(test-group "constructors & inspection"
(test-group "eq"
(let ((tables (list (make-eq-hashtable)
(make-eq-hashtable 10)
(make-eq-hashtable #f #f)
... | null | https://raw.githubusercontent.com/webyrd/n-grams-for-synthesis/b53b071e53445337d3fe20db0249363aeb9f3e51/datasets/srfi/srfi-126/test-suite.body.scm | scheme | This doesn't test weakness, external representation, and quasiquote.
Local Variables:
End: |
(test-begin "SRFI-126")
(test-group "constructors & inspection"
(test-group "eq"
(let ((tables (list (make-eq-hashtable)
(make-eq-hashtable 10)
(make-eq-hashtable #f #f)
(make-hashtable #f eq?)
(alist->eq-hashtable '... |
52025ec416d89fa535be4a704474cb64365ee79158851fe9004fbf57b1e92b9b | snowleopard/hadrian | Type.hs | module Way.Type where
import Data.IntSet (IntSet)
import qualified Data.IntSet as Set
import Data.List
import Data.Maybe
import Development.Shake.Classes
import Hadrian.Utilities
-- Note: order of constructors is important for compatibility with the old build
-- system, e.g. we want "thr_p", not "p_thr" (see instance... | null | https://raw.githubusercontent.com/snowleopard/hadrian/b9a3f9521b315942e1dabb006688ee7c9902f5fe/src/Way/Type.hs | haskell | Note: order of constructors is important for compatibility with the old build
system, e.g. we want "thr_p", not "p_thr" (see instance Show Way).
| A 'WayUnit' is a single way of building source code, for example with
profiling enabled, or dynamically linked.
TODO: get rid of non-derived Show instances
is to be bu... | module Way.Type where
import Data.IntSet (IntSet)
import qualified Data.IntSet as Set
import Data.List
import Data.Maybe
import Development.Shake.Classes
import Hadrian.Utilities
data WayUnit = Threaded
| Debug
| Profiling
| Logging
| Dynamic
deriving (... |
a9e7055615cecf4f4df2415bc833fe98a041dd1f41e33d81718ff7784d6b1bb8 | haskell/haskell-language-server | EmptyCaseApply.expected.hs | blah = case show 5 of
[] -> _
c : s -> _
| null | https://raw.githubusercontent.com/haskell/haskell-language-server/f3ad27ba1634871b2240b8cd7de9f31b91a2e502/plugins/hls-tactics-plugin/new/test/golden/EmptyCaseApply.expected.hs | haskell | blah = case show 5 of
[] -> _
c : s -> _
| |
e6d8d0a201e327a8c8afa3fd3d2172fbaa0605e8e43c5ad4852c1600d2068eb5 | milho-lang/milho-haskell | Parser.hs | module Pipoquinha.Parser
( sExpLine
, sExpFile
, parseFile
, parseExpression
) where
import Control.Monad.Combinators.NonEmpty
( endBy1 )
import Control.Monad.Fail ( fail )
import Data.List.NonEmpty
import Dat... | null | https://raw.githubusercontent.com/milho-lang/milho-haskell/ebea4dc2a2b84d7b8358b20fcfc4073ed7a93c76/src/Pipoquinha/Parser.hs | haskell | module Pipoquinha.Parser
( sExpLine
, sExpFile
, parseFile
, parseExpression
) where
import Control.Monad.Combinators.NonEmpty
( endBy1 )
import Control.Monad.Fail ( fail )
import Data.List.NonEmpty
import Dat... | |
0e6719dba63124f61caee5ac7a50afd5f0ea0a438b5507aea1d056426161c020 | bmeurer/ocaml-arm | exec.mli | (***********************************************************************)
(* *)
(* OCaml *)
(* *)
, projet Cr... | null | https://raw.githubusercontent.com/bmeurer/ocaml-arm/43f7689c76a349febe3d06ae7a4fc1d52984fd8b/debugger/exec.mli | ocaml | *********************************************************************
OCaml
... | , projet Cristal , INRIA Rocquencourt
OCaml port by and
Copyright 1996 Institut National de Recherche en Informatique et
en Automatique . All rights reserved . This file is distributed
under the terms of the Q Public License version 1.0 .
$ Id$
... |
2fde0bded1e47382f40e66bf1983da830775d80da2c1e6ab8269d48f11c235dd | solarbit/pool | hex.erl | Copyright 2016 < >
See MIT LICENSE
-module(hex).
-export([encode/1, decode/1, value/1, dump/1]).
encode(0) ->
<<$0, $0>>;
encode(Num) when is_integer(Num) ->
encode(encode_number(Num, []));
encode(Bin) when is_binary(Bin) ->
encode(Bin, <<>>).
encode(<<A:4, B:4, Rest/binary>>, Acc) ->
U ... | null | https://raw.githubusercontent.com/solarbit/pool/5576f1b71a469dfa2fcb6b5766667402eacc3860/lib/base/src/hex.erl | erlang | TODO: Consider...
| Copyright 2016 < >
See MIT LICENSE
-module(hex).
-export([encode/1, decode/1, value/1, dump/1]).
encode(0) ->
<<$0, $0>>;
encode(Num) when is_integer(Num) ->
encode(encode_number(Num, []));
encode(Bin) when is_binary(Bin) ->
encode(Bin, <<>>).
encode(<<A:4, B:4, Rest/binary>>, Acc) ->
U ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.