_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 |
|---|---|---|---|---|---|---|---|---|
ff20d7f9ec331844ef845f7ea8d99887c4c4e214c8be94baab7b7c4146e44480 | TeMPOraL/tracer | main.lisp | (in-package #:tracer)
Trace operations :
1 . Reset
2 . Trace
2.5 snapshot tracing ?
3 . Stop tracing
4 . Save report
#-sbcl (error "This system currently works only on SBCL.")
(defvar *tracing-p* nil "Is currently tracing activity happening?")
Trace info entry type , for function call
;;; - Timestamp
... | null | https://raw.githubusercontent.com/TeMPOraL/tracer/d7e236752aa291776c49c0bbe435a64dc1fbff78/src/main.lisp | lisp | - Timestamp
- Function name
- Function args maybe? (trace-with-args), on enter
- Function return value, on exit
- Beginning or ending
- Thread ID
This prints a representation of the return values delivered.
*TRACED-ENTRIES*; if it is not, then we need to adjust this list
to determine the correct indentation fo... | (in-package #:tracer)
Trace operations :
1 . Reset
2 . Trace
2.5 snapshot tracing ?
3 . Stop tracing
4 . Save report
#-sbcl (error "This system currently works only on SBCL.")
(defvar *tracing-p* nil "Is currently tracing activity happening?")
Trace info entry type , for function call
First , th... |
a7ad9776865f7e7ae039cd08edd6d5ecf790ed42aba13484be4039adac505292 | CrossRef/event-data-query | facet_test.clj | (ns event-data-query.facet-test
(:require [clojure.test :refer :all]
[event-data-query.facet :as facet]
[event-data-query.parameters :as parameters]
[slingshot.test]
[slingshot.test :as stest]))
; A regression test to make sure that parameters/parse suits the facet syn... | null | https://raw.githubusercontent.com/CrossRef/event-data-query/ede3c91afccd89dbb7053e81dd425bc3c3ad966a/test/event_data_query/facet_test.clj | clojure | A regression test to make sure that parameters/parse suits the facet syntax. | (ns event-data-query.facet-test
(:require [clojure.test :refer :all]
[event-data-query.facet :as facet]
[event-data-query.parameters :as parameters]
[slingshot.test]
[slingshot.test :as stest]))
(deftest parse-input
(testing "parameters/parse can parse facets input"
... |
cfad335ab4317c468dc996bde1d6ad94beb17e27095d5189c6a7514a9a665441 | pasberth/granjure | trans.clj | (ns granjure.control.monad.trans
(:use granjure.primitive
granjure.control))
(defprotocol MonadTrans
(lift-monad [this m]))
(defrecord Lift [m])
(extend-protocol TypeClass
Lift
(specialize [t cxt] (lift-monad cxt (:m t))))
(def lift (cfn [m] (Lift. m))) | null | https://raw.githubusercontent.com/pasberth/granjure/b2c85b794ef7e98c91178f0b6a59f748d3af7390/src/granjure/control/monad/trans.clj | clojure | (ns granjure.control.monad.trans
(:use granjure.primitive
granjure.control))
(defprotocol MonadTrans
(lift-monad [this m]))
(defrecord Lift [m])
(extend-protocol TypeClass
Lift
(specialize [t cxt] (lift-monad cxt (:m t))))
(def lift (cfn [m] (Lift. m))) | |
675de3b44b5754d34f91944d3a224937912fb53e1d9479ea7910b7761d030c3d | deadcode/Learning-CL--David-Touretzky | 7.9.lisp | (defun find-nested (x)
(find-if #'(lambda (y) (and (listp y) (not (equal y nil)))) x))
(let ((foo '(find-nested '(a () b (c d) e (f g h) i))))
(format t "~s = ~s~%" foo (eval foo)))
| null | https://raw.githubusercontent.com/deadcode/Learning-CL--David-Touretzky/b4557c33f58e382f765369971e6a4747c27ca692/Chapter%207/7.9.lisp | lisp | (defun find-nested (x)
(find-if #'(lambda (y) (and (listp y) (not (equal y nil)))) x))
(let ((foo '(find-nested '(a () b (c d) e (f g h) i))))
(format t "~s = ~s~%" foo (eval foo)))
| |
4f2d753e64a91c43705c2b45d2c9fad6485ac48bd07e4a8a31b1d78e968e4189 | tweag/ormolu | Fixity.hs | # LANGUAGE CPP #
# LANGUAGE LambdaCase #
{-# LANGUAGE MultiWayIf #-}
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE PatternSynonyms #
# LANGUAGE TemplateHaskell #
-- | Definitions for fixity analysis.
module Ormolu.Fixity
( OpName,
pattern OpName,
unOpName,
occOpName,
FixityDirection (..),
FixityI... | null | https://raw.githubusercontent.com/tweag/ormolu/f6dcd728b3abfdb9b4b352111be4d4448cf4e17e/src/Ormolu/Fixity.hs | haskell | # LANGUAGE MultiWayIf #
# LANGUAGE OverloadedStrings #
| Definitions for fixity analysis.
pass in the encoded fixity DB via pre-initialization with Wizer.
Hackage does not reflect their high popularity.
See #issuecomment-986609572.
"base" is not is this list, because it is already whitelisted
by buildFixityMap'.
... | # LANGUAGE CPP #
# LANGUAGE LambdaCase #
# LANGUAGE PatternSynonyms #
# LANGUAGE TemplateHaskell #
module Ormolu.Fixity
( OpName,
pattern OpName,
unOpName,
occOpName,
FixityDirection (..),
FixityInfo (..),
FixityMap,
LazyFixityMap,
lookupFixity,
HackageInfo (..),
defaultStrate... |
e5898f47362ed900bfd066807b46bbc796fda9f9d5f36819240433dce47447c9 | SNePS/SNePS2 | orders.lisp | -*- Mode : Lisp ; Syntax : Common - Lisp ; Package : SNEPSLOG ; Base : 10 -*-
Copyright ( C ) 1984 - -2013
Research Foundation of State University of New York
Version : $ I d : , v 1.6 2013/08/28 19:07:26 shapiro Exp $
;; This file is part of SNePS.
$ BEGIN LICENSE$
The contents of this file are subje... | null | https://raw.githubusercontent.com/SNePS/SNePS2/d3862108609b1879f2c546112072ad4caefc050d/snepslog/orders.lisp | lisp | Syntax : Common - Lisp ; Package : SNEPSLOG ; Base : 10 -*-
This file is part of SNePS.
you may
not use this file except in compliance with the License. You
may obtain a copy of the License at
. edu/sneps/Downloads/ubpl.pdf.
or implied. See the License for the specific language gov
erning rights and limitati... |
Copyright ( C ) 1984 - -2013
Research Foundation of State University of New York
Version : $ I d : , v 1.6 2013/08/28 19:07:26 shapiro Exp $
$ BEGIN LICENSE$
The contents of this file are subject to the University at
Software distributed under the License is distributed on an
" AS IS " basis , WITHO... |
cf627416208afe40e9d689c2686f88e716d0e6c1cdfb229d72342e07f7de7ec9 | pixlsus/registry.gimp.org_static | elsamuko-photochrom-batch.scm | ; The GIMP -- an image manipulation program
Copyright ( C ) 1995 and
;
; This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation ; either version 3 of the License , or
; (at your option) any later ve... | null | https://raw.githubusercontent.com/pixlsus/registry.gimp.org_static/ffcde7400f402728373ff6579947c6ffe87d1a5e/registry.gimp.org/files/elsamuko-photochrom-batch.scm | scheme | The GIMP -- an image manipulation program
This program is free software; you can redistribute it and/or modify
either version 3 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 even the implied warranty of
... | Copyright ( C ) 1995 and
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 , Cambridge , , USA .
Copyright ( C ) 2011 elsamuko < >
gimp -i -b ' ( elsamuko - photochrom - batch " pictu... |
27befc685a1e9bc0c6d835acc87ab29321877ffb6126197705f4fec4209ebf42 | google/ghc-source-gen | Internal.hs | Copyright 2019 Google LLC
--
-- Use of this source code is governed by a BSD-style
-- license that can be found in the LICENSE file or at
-- -source/licenses/bsd
# LANGUAGE CPP #
module GHC.SourceGen.Expr.Internal where
import GHC.Hs.Expr
#if MIN_VERSION_ghc(9,0,0)
import GHC.Types.SrcLoc (unLoc)
#else
import SrcLo... | null | https://raw.githubusercontent.com/google/ghc-source-gen/f6b9130d8f384be0ef7a02b371870d532090ccb6/src/GHC/SourceGen/Expr/Internal.hs | haskell |
Use of this source code is governed by a BSD-style
license that can be found in the LICENSE file or at
-source/licenses/bsd
TODO: more care for literals; only needed for negative numbers? | Copyright 2019 Google LLC
# LANGUAGE CPP #
module GHC.SourceGen.Expr.Internal where
import GHC.Hs.Expr
#if MIN_VERSION_ghc(9,0,0)
import GHC.Types.SrcLoc (unLoc)
#else
import SrcLoc (unLoc)
#endif
import GHC.SourceGen.Lit.Internal
import GHC.SourceGen.Syntax.Internal
parenthesizeExprForApp, parenthesizeExprForOp
... |
5f83953804cdde076de29ddd6029a9b34d10183b093df91ce9f049c8b3a16c43 | gusenov/stepik-functional-programming-hs | Demo.hs |
Ðåàëèçóéòå ôóíêöèþ sumOdd , öåëûõ ÷èñåë , íå÷åòíûå çíà÷åíèÿ :
GHCi > sumOdd [ 2,5,30,37 ]
42
Ðåàëèçóéòå ôóíêöèþ sumOdd, êîòîðàÿ ñóììèðóåò ýëåìåíòû ñïèñêà öåëûõ ÷èñåë, èìåþùèå íå÷åòíûå çíà÷åíèÿ:
GHCi> sumOdd [2,5,30,37]
42
-}
module Demo where
foo x y = if (odd x) then x + y else y
sumOdd :: [Integer] ... | null | https://raw.githubusercontent.com/gusenov/stepik-functional-programming-hs/904164012b9b842a15d5ba3af05cfe589295fa5c/SumOdd/Demo.hs | haskell | (2 + (5 + (30 + (37 + 0)))) |
Ðåàëèçóéòå ôóíêöèþ sumOdd , öåëûõ ÷èñåë , íå÷åòíûå çíà÷åíèÿ :
GHCi > sumOdd [ 2,5,30,37 ]
42
Ðåàëèçóéòå ôóíêöèþ sumOdd, êîòîðàÿ ñóììèðóåò ýëåìåíòû ñïèñêà öåëûõ ÷èñåë, èìåþùèå íå÷åòíûå çíà÷åíèÿ:
GHCi> sumOdd [2,5,30,37]
42
-}
module Demo where
foo x y = if (odd x) then x + y else y
sumOdd :: [Integer] ... |
6606d78b317a993bfd1702d994d54847e2d3a10b656e758c29e9644d5ebfc34d | AccelerateHS/accelerate | Vec.hs | # LANGUAGE ScopedTypeVariables #
# LANGUAGE MagicHash #
{-# LANGUAGE ConstraintKinds #-}
# LANGUAGE TypeFamilies #
{-# OPTIONS_HADDOCK hide #-}
# OPTIONS_GHC -fno - warn - orphans #
-- |
Module : Data . Array . Accelerate . Sugar .
Copyright : [ 2008 .. 2020 ] The Accelerate Team
--... | null | https://raw.githubusercontent.com/AccelerateHS/accelerate/63e53be22aef32cd0b3b6f108e637716a92b72dc/src/Data/Array/Accelerate/Sugar/Vec.hs | haskell | # LANGUAGE ConstraintKinds #
# OPTIONS_HADDOCK hide #
|
License : BSD3
Stability : experimental
| # LANGUAGE ScopedTypeVariables #
# LANGUAGE MagicHash #
# LANGUAGE TypeFamilies #
# OPTIONS_GHC -fno - warn - orphans #
Module : Data . Array . Accelerate . Sugar .
Copyright : [ 2008 .. 2020 ] The Accelerate Team
Maintainer : < >
Portability : non - portable ( GHC extensions ... |
cc3e4446898db954f3d8ed62e0413b99af308cc470ab86234d9bbb27a4fa0b1a | fredfeng/CS162 | repl.ml | open Ast
open Eval
open Format
let rec repl () =
match LNoise.linenoise "> " with
| None -> ()
| Some l -> begin
LNoise.history_add l |> ignore;
try
let e = parse l in
printf "<== %s\n%!" (string_of_expr e);
let v = eval e in
printf "==> %s\n%!" (string_of_expr v)
... | null | https://raw.githubusercontent.com/fredfeng/CS162/3e868a98e2b2b1ffc749a46a98b62df75ca4d46c/homework/hw4/repl.ml | ocaml | execute expression in file
repl mode | open Ast
open Eval
open Format
let rec repl () =
match LNoise.linenoise "> " with
| None -> ()
| Some l -> begin
LNoise.history_add l |> ignore;
try
let e = parse l in
printf "<== %s\n%!" (string_of_expr e);
let v = eval e in
printf "==> %s\n%!" (string_of_expr v)
... |
5478a0635788fdcecad738346bf4c1caf1b031054c9b0ce6e9e99cfe329f0bc0 | cbaggers/rtg-math | docs.lisp | (in-package :rtg-math.base-matrices)
;;----------------------------------------------------------------
(docs:define-docs
(defun m!
"
Creates a new `mat2`, `mat3` or `mat4` based on the number of
components provided.
"))
| null | https://raw.githubusercontent.com/cbaggers/rtg-math/29fc5b3d0028a4a11a82355ecc8cca62662c69e0/matrices/base/docs.lisp | lisp | ---------------------------------------------------------------- | (in-package :rtg-math.base-matrices)
(docs:define-docs
(defun m!
"
Creates a new `mat2`, `mat3` or `mat4` based on the number of
components provided.
"))
|
f4c70dbd19e328ba0e17d380fcc0821fcfabc9974909dfdceb7f8770a6c17447 | sol/tinc | RunSpec.hs | module RunSpec (spec) where
import Helper
import System.Exit
import Run
spec :: Spec
spec = do
describe "callPlugin" $ do
it "propagates success" $ do
callPlugin "true" [] `shouldThrow` (== ExitSuccess)
it "propagates error" $ do
callPlugin "false" [] `shouldThrow... | null | https://raw.githubusercontent.com/sol/tinc/427df659df20d548bbe4c7bd0ea76cc13de40238/test/RunSpec.hs | haskell | module RunSpec (spec) where
import Helper
import System.Exit
import Run
spec :: Spec
spec = do
describe "callPlugin" $ do
it "propagates success" $ do
callPlugin "true" [] `shouldThrow` (== ExitSuccess)
it "propagates error" $ do
callPlugin "false" [] `shouldThrow... | |
c852435b4b176a4bdf6a60ee17ef275550d20c98f680f13cd9226626330e9809 | sogaiu/alc.x-as-tests | runner.clj | (ns alc.x-as-tests.impl.runner
(:require
[alc.x-as-tests.impl.paths :as paths]
[alc.x-as-tests.impl.rewrite :as rewrite]
[clojure.java.io :as cji]
[clojure.java.shell :as cjs]
[clojure.string :as cs]))
(defn enum-src-files-in-dir
[dir exts]
(some->> (file-seq (java.io.File. dir))
(keep ... | null | https://raw.githubusercontent.com/sogaiu/alc.x-as-tests/86cfc58393f4d81e1a74d58e85f89717afb3d9b0/src/alc/x_as_tests/impl/runner.clj | clojure |
XXX: generates test file paths and populates the corr files
XXX: debris ends up in /tmp -- clean up?
XXX: break this up?
don't include file extension | (ns alc.x-as-tests.impl.runner
(:require
[alc.x-as-tests.impl.paths :as paths]
[alc.x-as-tests.impl.rewrite :as rewrite]
[clojure.java.io :as cji]
[clojure.java.shell :as cjs]
[clojure.string :as cs]))
(defn enum-src-files-in-dir
[dir exts]
(some->> (file-seq (java.io.File. dir))
(keep ... |
1642d0c401d933d97085b8772ec383098b45b52a7ed898d2832585f3a47067df | sighingnow/mxnet-haskell | Base.hs | -----------------------------------------------------------
-- |
-- module: MXNet.Core.Base
copyright : ( c ) 2016
license : MIT
-- maintainer:
--
Interfaces in core module of MXNet .
--
module MXNet.Core.Base
( -- * Necessary r... | null | https://raw.githubusercontent.com/sighingnow/mxnet-haskell/b8e8c6834519df512533094122ee223fd9fb91d8/mxnet/src/MXNet/Core/Base.hs | haskell | ---------------------------------------------------------
|
module: MXNet.Core.Base
maintainer:
* Necessary raw functions
* Symbol
* Executor
* Heterogeneous Dictionary. | copyright : ( c ) 2016
license : MIT
Interfaces in core module of MXNet .
module MXNet.Core.Base
mxGetLastError
, mxListAllOpNames
* NDArray
, NDArray
, waitAll
, makeEmptyNDArray
, makeNDArray
, ndshape
, ndsize
, context
, at... |
0bee491cdd70fb42d43b6d9e5035e52c9f13668de4f3a4ec1ee5320d90fd316f | whamtet/Excel-REPL | client.clj | (ns clr-http.lite.client
"Batteries-included HTTP client."
(:require [clojure.string :as str]
[clojure.clr.io :as io]
[clr-http.lite.core :as core]
[clr-http.lite.util :as util])
(:import
System.Text.Encoding
System.Text.UTF8Encoding
)
(:refer-clojure :exclude (get))... | null | https://raw.githubusercontent.com/whamtet/Excel-REPL/cae2ef8e423e2f2723c60e4758785973f06c6ba4/Excel-REPL/nrepl/clr_http/lite/client.clj | clojure | Don't do anything for streams
Don't do anything when it's a byte-array
Automatically determine response type
No :as matches found
Try the charset given if a string is specified
wrap-unknown-host | (ns clr-http.lite.client
"Batteries-included HTTP client."
(:require [clojure.string :as str]
[clojure.clr.io :as io]
[clr-http.lite.core :as core]
[clr-http.lite.util :as util])
(:import
System.Text.Encoding
System.Text.UTF8Encoding
)
(:refer-clojure :exclude (get))... |
bfd03e3276f7bb1acbe40bb76a4792116f64ccf3a43df4888c4ae6c4de823b03 | mveritym/markov-bot | make_bot.clj | (ns markov-bot.make-bot
(:require [markov-bot.twitter :as twitter]
[markov-bot.generator :refer :all]
[cemerick.url :refer [url-encode]]))
(defn get-tweets-for-users [users]
(->> users
(map twitter/get-all-tweets-for-user)
(apply concat)))
(defn gen-chain-from-tweets [tweets]... | null | https://raw.githubusercontent.com/mveritym/markov-bot/138ac43d2c5b016ae1b8beeeee2dc854cd748e53/markov-bot-lambda/src/markov_bot/make_bot.clj | clojure | (ns markov-bot.make-bot
(:require [markov-bot.twitter :as twitter]
[markov-bot.generator :refer :all]
[cemerick.url :refer [url-encode]]))
(defn get-tweets-for-users [users]
(->> users
(map twitter/get-all-tweets-for-user)
(apply concat)))
(defn gen-chain-from-tweets [tweets]... | |
9715f70d2e961902fc9684cb578bdceaf8d2c62a23c38fb26b58a042e83ec9a2 | xoken/xoken-node | StoreSpec.hs | module Xoken.StoreSpec
(
) where
| null | https://raw.githubusercontent.com/xoken/xoken-node/99124fbe1b1cb9c2fc442c788c7c2bac06f5e900/node/test/Xoken/StoreSpec.hs | haskell | module Xoken.StoreSpec
(
) where
| |
69660e784c94640f8c98c64e6970eb99b6830d257ad147ebedd8cf8ebc070e7b | puppetlabs/jdbc-util | pool.clj | (ns puppetlabs.jdbc-util.pool
(:require [clojure.set :as set]
[clojure.tools.logging :as log]
[puppetlabs.i18n.core :refer [tru trs trun]]
[puppetlabs.jdbc-util.migration :as migration])
(:import com.codahale.metrics.health.HealthCheckRegistry
[com.zaxxer.hikari Hikari... | null | https://raw.githubusercontent.com/puppetlabs/jdbc-util/b9175b6e4899bc1d41817301abc325d83a058392/src/puppetlabs/jdbc_util/pool.clj | clojure | Try to get a connection to make sure the db is ready
ensure both the db and a migration directory is specified
replicating our migrations for us, so we poll until
the migrations have been replicated
return the datasource so we know we are done.
since we have cancelled the init, we need to specifically wait until ... | (ns puppetlabs.jdbc-util.pool
(:require [clojure.set :as set]
[clojure.tools.logging :as log]
[puppetlabs.i18n.core :refer [tru trs trun]]
[puppetlabs.jdbc-util.migration :as migration])
(:import com.codahale.metrics.health.HealthCheckRegistry
[com.zaxxer.hikari Hikari... |
82eb6d62584fc1a52e81576e8e1a86cf3bd2b398de60513514785bdc62ce7991 | feldi/clj-swipl7 | swipl7_test.clj | (ns clj.swipl7-test
(:require [clojure.test :refer :all]
[clj.swipl7.protocols :refer :all]
[clj.swipl7.core :refer :all]))
(deftest jpl-tests
(testing "version"
(is (= (get-jpl-version-as-string) "7.6.1-stable")))
(testing "prolog lists"
(let [pl-list (to-pl [... | null | https://raw.githubusercontent.com/feldi/clj-swipl7/a40c22161a3a6c30edad64675b90f7552f20b984/test/clj/swipl7_test.clj | clojure | (ns clj.swipl7-test
(:require [clojure.test :refer :all]
[clj.swipl7.protocols :refer :all]
[clj.swipl7.core :refer :all]))
(deftest jpl-tests
(testing "version"
(is (= (get-jpl-version-as-string) "7.6.1-stable")))
(testing "prolog lists"
(let [pl-list (to-pl [... | |
b7caa7eab423b86389bddb9601e16137757f38e7cbd25bc34eaa60369d0a6d39 | chenyukang/eopl | 03.scm | (load-relative "../libs/init.scm")
(load-relative "./base/test.scm")
(load-relative "./base/equal-type.scm")
(load-relative "./base/data-structures.scm")
(load-relative "./base/cases.scm")
(load-relative "./base/simplemodule-lang.scm")
;; see the new stuff
;;;;;;;;;;;;;;;; grammatical specification ;;;;;;;;;;;;;;;;
(... | null | https://raw.githubusercontent.com/chenyukang/eopl/0406ff23b993bfe020294fa70d2597b1ce4f9b78/ch8/03.scm | scheme | see the new stuff
grammatical specification ;;;;;;;;;;;;;;;;
new stuff
new expression:
new stuff
new types
no changes in grammar below here
sllgen boilerplate ;;;;;;;;;;;;;;;;
new stuff, a hack | (load-relative "../libs/init.scm")
(load-relative "./base/test.scm")
(load-relative "./base/equal-type.scm")
(load-relative "./base/data-structures.scm")
(load-relative "./base/cases.scm")
(load-relative "./base/simplemodule-lang.scm")
(define the-lexical-spec
'((whitespace (whitespace) skip)
(comment ("%" (arb... |
5e28f21b82a7c862147d97cab817076868f86c1ac3fffd4ebf33fc90a169a912 | nijohando/event | emitter.cljc | (ns jp.nijohando.event.emitter
(:require [clojure.core.async :as ca]))
(defn pipe
[emitter-id emitter-ch bus-ch]
(ca/go-loop []
(when-some [v (ca/<! emitter-ch)]
(when-let [event (when (map? v)
(assoc-in v [:header :emitter-id] emitter-id))]
(when-not (ca/>! bus-ch even... | null | https://raw.githubusercontent.com/nijohando/event/34e359c554d2baaa01e4fec524942f513a26d7f5/src/jp/nijohando/event/emitter.cljc | clojure | (ns jp.nijohando.event.emitter
(:require [clojure.core.async :as ca]))
(defn pipe
[emitter-id emitter-ch bus-ch]
(ca/go-loop []
(when-some [v (ca/<! emitter-ch)]
(when-let [event (when (map? v)
(assoc-in v [:header :emitter-id] emitter-id))]
(when-not (ca/>! bus-ch even... | |
a084b96c85fed97d71866ce0032fc7bf2d9dbfce08773e765f0bd81f1d33b33d | EMSL-NMR-EPR/Haskell-MFAPipe-Executable | IsotopicLabeling.hs | -----------------------------------------------------------------------------
-- |
-- Module : Science.Chemistry.IsotopicLabeling
Copyright : 2016 - 17 Pacific Northwest National Laboratory
-- License : ECL-2.0 (see the LICENSE file in the distribution)
--
-- Maintainer :
-- Stability : experime... | null | https://raw.githubusercontent.com/EMSL-NMR-EPR/Haskell-MFAPipe-Executable/8a7fd13202d3b6b7380af52d86e851e995a9b53e/MFAPipe/src/Science/Chemistry/IsotopicLabeling.hs | haskell | ---------------------------------------------------------------------------
|
Module : Science.Chemistry.IsotopicLabeling
License : ECL-2.0 (see the LICENSE file in the distribution)
Maintainer :
Stability : experimental
Portability : portable
This module exports modules for isotopic labeling... | Copyright : 2016 - 17 Pacific Northwest National Laboratory
module Science.Chemistry.IsotopicLabeling
module Science.Chemistry.IsotopicLabeling.FractionType
, module Science.Chemistry.IsotopicLabeling.FractionTypeDict
, module Science.Chemistry.IsotopicLabeling.FractionMatrix
, module Science.Chemistry.Isotop... |
03dc708941adc6cae8a3456286ea43fde69dfaf2bd3cfba8ce292f396992a798 | ocaml-flambda/ocaml-jst | simplif.mli | (**************************************************************************)
(* *)
(* OCaml *)
(* *)
... | null | https://raw.githubusercontent.com/ocaml-flambda/ocaml-jst/7e5a626e4b4e12f1e9106564e1baba4d0ef6309a/lambda/simplif.mli | ocaml | ************************************************************************
OCaml
... | , projet Cristal , INRIA Rocquencourt
Copyright 1996 Institut National de Recherche en Informatique et
the GNU Lesser General Public License version 2.1 , with the
open Lambda
val simplify_lambda: lambda -> lambda
val split_default_wrapper
: id:Ident.t
-> kind... |
078f1b7629d02aac9ff27e33404d7d5582c8c5dd99fb2593ad1502812cb43e7e | scicloj/tablecloth.time | validatable_test.clj | (ns tablecloth.time.utils.validatable-test
(:require [clojure.test :refer [deftest is]]
[tablecloth.api :as tablecloth]
[tablecloth.time.utils.validatable :as validatable]))
(deftest validatable-test
(let [ds (tablecloth/dataset {:x [1 2 3]
:y [4 5 6]})
... | null | https://raw.githubusercontent.com/scicloj/tablecloth.time/9eba5d0aa22fed087c2c0b072c40f58e91c0505d/test/tablecloth/time/utils/validatable_test.clj | clojure | without validatable | (ns tablecloth.time.utils.validatable-test
(:require [clojure.test :refer [deftest is]]
[tablecloth.api :as tablecloth]
[tablecloth.time.utils.validatable :as validatable]))
(deftest validatable-test
(let [ds (tablecloth/dataset {:x [1 2 3]
:y [4 5 6]})
... |
8f883d49674099a37116904408e1a633616e982c08748a1af53c1e468255ac89 | lazy-cat-io/metaverse | reporter.cljs | (ns metaverse.common.reporter
(:require
[metaverse.common.env :as env]
[metaverse.common.logger :as log :include-macros true]
[metaverse.common.utils.string :as str]
[tenet.response :as r]))
TODO : [ 2022 - 05 - 02 , ] validate opts
(defn init!
([^js sentry]
(init! sentry {}))
([^js sentr... | null | https://raw.githubusercontent.com/lazy-cat-io/metaverse/4c566278d253ce6b85e4644b2fdec93dab58355c/src/main/clojure/metaverse/common/reporter.cljs | clojure | (ns metaverse.common.reporter
(:require
[metaverse.common.env :as env]
[metaverse.common.logger :as log :include-macros true]
[metaverse.common.utils.string :as str]
[tenet.response :as r]))
TODO : [ 2022 - 05 - 02 , ] validate opts
(defn init!
([^js sentry]
(init! sentry {}))
([^js sentr... | |
0209d7be44b0f9232ec7cc26cb66e1d0ab87916466bd01c1d827957043e27a6d | runeksvendsen/restful-payment-channel-server | Types.hs | module BlockchainAPI.Impl.Bitcoind.Types
(
module APISpec.Types
) where
import APISpec.Types
| null | https://raw.githubusercontent.com/runeksvendsen/restful-payment-channel-server/0fe65eadccad5ef2b840714623ec407e509ad00b/src/BlockchainAPI/Impl/Bitcoind/Types.hs | haskell | module BlockchainAPI.Impl.Bitcoind.Types
(
module APISpec.Types
) where
import APISpec.Types
| |
a559c77c36f8f166c30a1b749e3a880cf7e98e2864419aefd2d29b4160b67f33 | ocaml-flambda/flambda-backend | simplify_switch_expr.ml | (**************************************************************************)
(* *)
(* OCaml *)
(* *)
... | null | https://raw.githubusercontent.com/ocaml-flambda/flambda-backend/30c53039a2256b46a77527493419067271bec0a8/middle_end/flambda2/simplify/simplify_switch_expr.ml | ocaml | ************************************************************************
OCaml
... | , OCamlPro
and ,
Copyright 2014 - -2020 Jane Street Group LLC
the GNU Lesser General Public License version 2.1 , with the
open! Simplify_import
module TE = Flambda2_types.Typing_env
module A... |
74ab81de0978102202045d54bda88694b6818df467cb05ab494484b9c940c753 | alexandergunnarson/quantum | core.cljc | (ns quantum.security.core
(:require
#?@(:clj [[less.awful.ssl :as las]]))
#?(:clj
(:import java.security.KeyStore
[javax.net.ssl TrustManagerFactory KeyManagerFactory]
[io.netty.handler.ssl SslProvider SslContextBuilder])))
;; Disabling developer tools (e.g. console) doesn't matter. Thi... | null | https://raw.githubusercontent.com/alexandergunnarson/quantum/0c655af439734709566110949f9f2f482e468509/src/quantum/security/core.cljc | clojure | Disabling developer tools (e.g. console) doesn't matter. This doesn't protect against hackers.
so we'll defensively lock before mutating here: | (ns quantum.security.core
(:require
#?@(:clj [[less.awful.ssl :as las]]))
#?(:clj
(:import java.security.KeyStore
[javax.net.ssl TrustManagerFactory KeyManagerFactory]
[io.netty.handler.ssl SslProvider SslContextBuilder])))
#?(:clj
(defn trust-manager-factory
"An X.509 trust manager ... |
e2adff0924fa815d8f9d900b44cd824c779141a3b434c510cccf3f09077db084 | FranklinChen/learn-you-some-erlang | recursive_tests.erl | -module(recursive_tests).
-include_lib("eunit/include/eunit.hrl").
%% those were not in the module, but yeah
fac_test_() ->
[?_assert(24 == recursive:fac(4)),
?_assert(1 == recursive:fac(0)),
?_assert(1 == recursive:fac(1)),
?_assertError(function_clause, recursive:fac(-1))].
tail_fac_t... | null | https://raw.githubusercontent.com/FranklinChen/learn-you-some-erlang/878c8bc2011a12862fe72dd7fdc6c921348c79d6/tests/recursive_tests.erl | erlang | those were not in the module, but yeah
exercises!
quick, sort!
| -module(recursive_tests).
-include_lib("eunit/include/eunit.hrl").
fac_test_() ->
[?_assert(24 == recursive:fac(4)),
?_assert(1 == recursive:fac(0)),
?_assert(1 == recursive:fac(1)),
?_assertError(function_clause, recursive:fac(-1))].
tail_fac_test_() ->
[?_assert(recursive:fac(4) =... |
aad80ebecd48a9d82d79db279aeb0aafca14ab49eda1ca72d87b856c5a5a6377 | ku-fpg/haskino | Utils.hs | -------------------------------------------------------------------------------
-- |
-- Module : System.Hardware.Haskino.Utils
-- Based on System.Hardware.Arduino.Utils
Copyright : ( c ) University of Kansas
System . Hardware . Arduino ( c )
-- License : BSD3
-- Stabi... | null | https://raw.githubusercontent.com/ku-fpg/haskino/9a0709c92c2da9b9371e292b00fd076e5539eb18/System/Hardware/Haskino/Utils.hs | haskell | -----------------------------------------------------------------------------
|
Module : System.Hardware.Haskino.Utils
Based on System.Hardware.Arduino.Utils
License : BSD3
Stability : experimental
-----------------------------------------------------------------------------
| A simp... | Copyright : ( c ) University of Kansas
System . Hardware . Arduino ( c )
Internal utilities
module System.Hardware.Haskino.Utils where
import Data.Bits (shiftL, shiftR, (.&.), (.|.))
import qualified Data.ByteString as B
import Data.Char ... |
ee1a76253207b0a85aa96c84b7e48b9ad7f2da8933a07879686bf01a16e20a7c | lilactown/helix-todo-mvc | components.cljs | (ns todo-mvc.components
(:require
[helix.core :as hx :refer [$ <>]]
[helix.dom :as d]
[helix.hooks :as hooks]
[todo-mvc.lib :refer [defnc]])
(:require-macros
[todo-mvc.components]))
(defn enter-key? [ev]
(= (.-which ev) 13))
(defn escape-key? [ev]
(= (.-which ev) 27))
(defnc Title
[]
(d/h1... | null | https://raw.githubusercontent.com/lilactown/helix-todo-mvc/bd1be0be6388264b70329817348c6cda616b6fdd/src/todo_mvc/components.cljs | clojure | (ns todo-mvc.components
(:require
[helix.core :as hx :refer [$ <>]]
[helix.dom :as d]
[helix.hooks :as hooks]
[todo-mvc.lib :refer [defnc]])
(:require-macros
[todo-mvc.components]))
(defn enter-key? [ev]
(= (.-which ev) 13))
(defn escape-key? [ev]
(= (.-which ev) 27))
(defnc Title
[]
(d/h1... | |
77c2486a85c8eacae4851d84ccd8acb1ef1515e6d37cfa106c1a3f2420983c08 | mattmundell/nightshade | cdbuild.lisp | ;;; Build the boot CD core from the boot .assem files.
(in-package "LISP")
(or (fboundp 'genesis)
(load "target:compiler/generic/new-genesis"))
(defparameter lisp-files
`(,@(when (c:backend-featurep :pmax)
'("target:assembly/mips/boot.assem"))
,@(when (c:backend-featurep :sparc)
'("target:assembly/sparc/... | null | https://raw.githubusercontent.com/mattmundell/nightshade/7a67f9eac96414355de1463ec251b98237cb4009/src/tools/cdbuild.lisp | lisp | Build the boot CD core from the boot .assem files. |
(in-package "LISP")
(or (fboundp 'genesis)
(load "target:compiler/generic/new-genesis"))
(defparameter lisp-files
`(,@(when (c:backend-featurep :pmax)
'("target:assembly/mips/boot.assem"))
,@(when (c:backend-featurep :sparc)
'("target:assembly/sparc/boot.assem"))
,@(when (c:backend-featurep :rt)
'("... |
368eaea9115d7dd9b0d357d2c7602b55f85a1014a7497ab1caaef1e5ef56d99c | typedclojure/typedclojure | utils.clj | Copyright ( c ) , Rich Hickey & contributors .
;; The use and distribution terms for this software are covered by the
;; Eclipse Public License 1.0 (-1.0.php)
;; which can be found in the file epl-v10.html at the root of this distribution.
;; By using this software in any fashion, you are agreeing to be b... | null | https://raw.githubusercontent.com/typedclojure/typedclojure/45556897356f3c9cbc7b1b6b4df263086a9d5803/typed/clj.reader/src/typed/clj/reader/impl/utils.clj | clojure | The use and distribution terms for this software are covered by the
Eclipse Public License 1.0 (-1.0.php)
which can be found in the file epl-v10.html at the root of this distribution.
By using this software in any fashion, you are agreeing to be bound by
the terms of this license.
You must not remove ... | Copyright ( c ) , Rich Hickey & contributors .
(ns ^:no-doc typed.clj.reader.impl.utils
(:refer-clojure :exclude [char reader-conditional tagged-literal]))
(defn char [x]
(when x
(clojure.core/char x)))
(def <=clojure-1-7-alpha5
(let [{:keys [minor qualifier]} *clojure-version*]
(or (< minor 7)
... |
bef5347c5f8c1f68223cba33a2117ec508501478c95f65d44fb9736d6bb0c06d | aharisu/Gauche-CV | cv.scm | ;;;
;;; gauche_cv
;;;
MIT License
Copyright 2011 - 2012 aharisu
;;; All rights reserved.
;;;
;;; Permission is hereby granted, free of charge, to any person obtaining a copy
;;; of this software and associated documentation files (the "Software"), to deal
in the Software without restriction , including... | null | https://raw.githubusercontent.com/aharisu/Gauche-CV/5e4c51501431c72270765121ea4d92693f11d60b/lib/cv.scm | scheme |
gauche_cv
All rights reserved.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
furnished to do so, subject to the followin... | MIT License
Copyright 2011 - 2012 aharisu
in the Software without restriction , including without limitation the rights
copies of the Software , and to permit persons to whom the Software is
copies or substantial portions of the Software .
THE SOFTWARE IS PROVIDED " AS IS " , WITHOUT WARRANTY OF A... |
030f195f3c6c30b7d8002023c9bc2b58a0a83e1fd53993348395a92ff42284f5 | realworldocaml/examples | compare_poly.ml | let cmp a b =
if a > b then a else b
| null | https://raw.githubusercontent.com/realworldocaml/examples/32ea926861a0b728813a29b0e4cf20dd15eb486e/code/back-end/compare_poly.ml | ocaml | let cmp a b =
if a > b then a else b
| |
66302a63a97756ae268760ae5516bc5da59b6d145f38133b0aa5ccba589a1363 | ghc/packages-Cabal | setup.test.hs | import Test.Cabal.Prelude
-- Test executable depends on internal library.
main = setupAndCabalTest $ setup_build []
| null | https://raw.githubusercontent.com/ghc/packages-Cabal/6f22f2a789fa23edb210a2591d74ea6a5f767872/cabal-testsuite/PackageTests/BuildDeps/InternalLibrary1/setup.test.hs | haskell | Test executable depends on internal library. | import Test.Cabal.Prelude
main = setupAndCabalTest $ setup_build []
|
b7324f295e929c667a8613385ba0c4a20359f91149fc3f6156eef75b3ad1e8a2 | fakedata-haskell/fakedata | Basketball.hs | {-# LANGUAGE OverloadedStrings #-}
# LANGUAGE TemplateHaskell #
module Faker.Provider.Basketball where
import Config
import Control.Monad.Catch
import Data.Monoid ((<>))
import Data.Text (Text)
import Data.Vector (Vector)
import Data.Yaml
import Faker
import Faker.Internal
import Faker.Provider.TH
import Language.Has... | null | https://raw.githubusercontent.com/fakedata-haskell/fakedata/7b0875067386e9bb844c8b985c901c91a58842ff/src/Faker/Provider/Basketball.hs | haskell | # LANGUAGE OverloadedStrings # | # LANGUAGE TemplateHaskell #
module Faker.Provider.Basketball where
import Config
import Control.Monad.Catch
import Data.Monoid ((<>))
import Data.Text (Text)
import Data.Vector (Vector)
import Data.Yaml
import Faker
import Faker.Internal
import Faker.Provider.TH
import Language.Haskell.TH
parseBasketball :: FromJS... |
75d29a908224d7f784da38e4b2e3b24a8251dd49ba4b5a0ab81c32821e36bc16 | plaidfinch/ComonadSheet | Z2.hs | # LANGUAGE MultiParamTypeClasses , FlexibleInstances #
module Z2
( module Generic , Z2(..) , wrapZ2
) where
import Generic
import Z1
newtype Z2 c r a = Z2 { fromZ2 :: Z1 r (Z1 c a) }
wrapZ2 :: (Z1 r (Z1 c a) -> Z1 r' (Z1 c' a')) -> Z2 c r a -> Z2 c' r' a'
wrapZ2 = (Z2 .) . (. fromZ2)
instance Functor (Z2 c r... | null | https://raw.githubusercontent.com/plaidfinch/ComonadSheet/1cc9a91dc311bc1c692df4faaea091238b7871c2/Old/Z2.hs | haskell | TODO...
insertColsR, insertColsL, insertRowsU, insertRowsD | # LANGUAGE MultiParamTypeClasses , FlexibleInstances #
module Z2
( module Generic , Z2(..) , wrapZ2
) where
import Generic
import Z1
newtype Z2 c r a = Z2 { fromZ2 :: Z1 r (Z1 c a) }
wrapZ2 :: (Z1 r (Z1 c a) -> Z1 r' (Z1 c' a')) -> Z2 c r a -> Z2 c' r' a'
wrapZ2 = (Z2 .) . (. fromZ2)
instance Functor (Z2 c r... |
5287dae6ed063b3e83a33bdea8457e3d8f4913c8b99380759ad000270c091d63 | magnusjonsson/tidder-icfpc-2008 | hello-world.scm | #! /usr/bin/env mzscheme
#lang scheme
(display "Hello world!")
(newline)
| null | https://raw.githubusercontent.com/magnusjonsson/tidder-icfpc-2008/84d68fd9ac358c38e7eff99117d9cdfa86c1864a/playground/scheme/hello-world.scm | scheme | #! /usr/bin/env mzscheme
#lang scheme
(display "Hello world!")
(newline)
| |
74d28c7f4cdaa78621514ddbbbeefd28d81137c67ff8d520ebe953e35bbacc1d | dmjio/compiler-in-haskell | PrettyPrinter.hs | module DLC.PrettyPrinter
(prettyPrintTransResult, prettyPrintClassDef, prettyPrintMethodDef)
where
import DLC.TAST
import Data.Char (chr)
import Data.Map
prettyPrintTransResult :: Int -> TransResult -> IO ()
prettyPrintTransResult il (cdMap, mdMap) = do
mapM_ (\cName -> prettyPrintClassDef il (cdMap ! cName))... | null | https://raw.githubusercontent.com/dmjio/compiler-in-haskell/1dbd377d72290f1a3614710df877b1a95f4242b8/src/DLC/PrettyPrinter.hs | haskell | no prefix indent, no suffix ";" and newline
ppBodyList _ [] = putStrLn ""
for parens and escaping | module DLC.PrettyPrinter
(prettyPrintTransResult, prettyPrintClassDef, prettyPrintMethodDef)
where
import DLC.TAST
import Data.Char (chr)
import Data.Map
prettyPrintTransResult :: Int -> TransResult -> IO ()
prettyPrintTransResult il (cdMap, mdMap) = do
mapM_ (\cName -> prettyPrintClassDef il (cdMap ! cName))... |
747bd882689311684f82b00026741cf6beae3c9a04ae45dfd49df4bf61f55bd9 | agda/agda | DisplayForm.hs | # LANGUAGE UndecidableInstances #
| Tools for ' DisplayTerm ' and ' DisplayForm ' .
module Agda.TypeChecking.DisplayForm (displayForm) where
import Control.Monad
import Control.Monad.Trans (lift)
import Control.Monad.Trans.Maybe
import Data.Monoid (All(..))
import Data.Map (Map)
import qualified Data.Map as Map
i... | null | https://raw.githubusercontent.com/agda/agda/9afe77020541b944331685ef2720a81bb312a925/src/full/Agda/TypeChecking/DisplayForm.hs | haskell | | Get the arities of all display forms for a name.
| Lift a local display form to an outer context. The substitution goes from the parent context to
the parent context.
We lift a display form by turning matches on free variables into pattern variables, which can
be done by simply adding to the dfPatternVars fiel... | # LANGUAGE UndecidableInstances #
| Tools for ' DisplayTerm ' and ' DisplayForm ' .
module Agda.TypeChecking.DisplayForm (displayForm) where
import Control.Monad
import Control.Monad.Trans (lift)
import Control.Monad.Trans.Maybe
import Data.Monoid (All(..))
import Data.Map (Map)
import qualified Data.Map as Map
i... |
6971b27d1204dc79b274cfbfa17d5d2b57feaff463e083eb8c08887dad9ea53b | soupi/chip-8 | Bits.hs | Bits Utilities
module CPU.Bits where
import Data.Word
import Data.Bits
import qualified Data.ByteString as BS
import qualified Numeric as Nume (showHex)
import Data.Char (toUpper)
mergeList16 :: [Word8] -> [Word16]
mergeList16 [] = []
mergeList16 [x] = [merge16 x 0]
mergeList16 (x:y:rest) = merge16 x y : mergeLis... | null | https://raw.githubusercontent.com/soupi/chip-8/b2ded9808cd5a071f0b797286bb040bc73e19b27/src/CPU/Bits.hs | haskell | |
|
|
|
Formatting Word8 for debugging purposes
|
a helper function for bit pattern matching | Bits Utilities
module CPU.Bits where
import Data.Word
import Data.Bits
import qualified Data.ByteString as BS
import qualified Numeric as Nume (showHex)
import Data.Char (toUpper)
mergeList16 :: [Word8] -> [Word16]
mergeList16 [] = []
mergeList16 [x] = [merge16 x 0]
mergeList16 (x:y:rest) = merge16 x y : mergeLis... |
7f121c8a14a9c240a0f8df2caa3dcf94ee7100ee986130b4a283e479ddcf1147 | utkarshkukreti/bs-preact | WindowSize.ml | module P = Preact
module WindowSize = struct
type t =
{ width : float
; height : float
}
external innerWidth : float = "" [@@bs.val] [@@bs.scope "window"]
external innerHeight : float = "" [@@bs.val] [@@bs.scope "window"]
external addEventListener : string -> (unit -> unit) -> unit = ""
[@@b... | null | https://raw.githubusercontent.com/utkarshkukreti/bs-preact/61d10d40543e1f8fc83b8a82f6353bcb52489c91/examples/WindowSize.ml | ocaml | module P = Preact
module WindowSize = struct
type t =
{ width : float
; height : float
}
external innerWidth : float = "" [@@bs.val] [@@bs.scope "window"]
external innerHeight : float = "" [@@bs.val] [@@bs.scope "window"]
external addEventListener : string -> (unit -> unit) -> unit = ""
[@@b... | |
7c8c039a7a33007fc7a9436c7c1e1488d65874174ac874f42ae699c1c5f98db4 | b1412/clojure-web-admin | kit.clj | (ns clojure-web.db.kit
(:require [clojure-web.db.entity :refer [resource role-resource]]
[inflections.core :refer [plural titleize]]
[korma.core :as k]))
(defn get-res-for-entity
"Generate basic resources of an entity like follows
+----+----------------+--------+-------------------+
| i... | null | https://raw.githubusercontent.com/b1412/clojure-web-admin/018161dcdb364cc168d6f5a56ceb798005a0701f/src/clj/clojure_web/db/kit.clj | clojure | (ns clojure-web.db.kit
(:require [clojure-web.db.entity :refer [resource role-resource]]
[inflections.core :refer [plural titleize]]
[korma.core :as k]))
(defn get-res-for-entity
"Generate basic resources of an entity like follows
+----+----------------+--------+-------------------+
| i... | |
520a53ba8ff6cce1306fc1efe8605cc64e7993a2f1000da1565d062ea7f96866 | bobzhang/fan | ctypN.mli |
(** Utilities for Fan's deriving mechanism *)
open Astfn
type vrn =
| Sum
| TyVrnEq
| TyVrnSup
| TyVrnInf
| TyVrnInfSup
| TyAbstr
type col = {
col_label:string;
col_mutable:bool;
col_ctyp:ctyp
}
type ty_info = {
name_exp: exp; (* [meta_int] *)
[ test _ a3 ]
ep0: ep; (* _a3*)
... | null | https://raw.githubusercontent.com/bobzhang/fan/7ed527d96c5a006da43d3813f32ad8a5baa31b7f/src/cold/ctypN.mli | ocaml | * Utilities for Fan's deriving mechanism
[meta_int]
_a3
(_a3,_b3)
[_a3;_b3]
int
Iter style
Map style
Feed to user to compose an expession node
types below are used to tell fan how to produce
function of type [ident -> ident]
decompose to a list of ident and compose as an ident
just pass the id... |
open Astfn
type vrn =
| Sum
| TyVrnEq
| TyVrnSup
| TyVrnInf
| TyVrnInfSup
| TyAbstr
type col = {
col_label:string;
col_mutable:bool;
col_ctyp:ctyp
}
type ty_info = {
[ test _ a3 ]
}
type vbranch =
[ `variant of (string* ctyp list )
| `abbrev of ident ]
type branch =
[ `bran... |
de013287842c33bab0e47f878a59f655a46c0a5bdca89bc431bb59bdd9556aa5 | brendanhay/amazonka | SamlStatusEnum.hs | # LANGUAGE DeriveGeneric #
# LANGUAGE DerivingStrategies #
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE LambdaCase #
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE PatternSynonyms #
{-# LANGUAGE StrictData #-}
# LANGUAGE NoImplicitPrelude #
# OPTIONS_GHC -fno - warn - unused - imports #
Derived from AWS service... | null | https://raw.githubusercontent.com/brendanhay/amazonka/09f52b75d2cfdff221b439280d3279d22690d6a6/lib/services/amazonka-workspaces/gen/Amazonka/WorkSpaces/Types/SamlStatusEnum.hs | haskell | # LANGUAGE OverloadedStrings #
# LANGUAGE StrictData #
|
Module : Amazonka.WorkSpaces.Types.SamlStatusEnum
Stability : auto-generated | # LANGUAGE DeriveGeneric #
# LANGUAGE DerivingStrategies #
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE LambdaCase #
# LANGUAGE PatternSynonyms #
# LANGUAGE NoImplicitPrelude #
# OPTIONS_GHC -fno - warn - unused - imports #
Derived from AWS service descriptions , licensed under Apache 2.0 .
Copyright : (... |
c86adc25f3536f2a72adb9616cce4c504d9cc848d1b2fe11dd96a702e05784ac | clojure-interop/java-jdk | HTMLEditorKit$HTMLFactory.clj | (ns javax.swing.text.html.HTMLEditorKit$HTMLFactory
"A factory to build views for HTML. The following
table describes what this factory will build by
default.
TagView created
HTML.Tag.CONTENTInlineView
HTML.Tag.IMPLIEDjavax.swing.text.html.ParagraphView
HTML.Tag.Pjavax.swing.text.html.ParagraphView... | null | https://raw.githubusercontent.com/clojure-interop/java-jdk/8d7a223e0f9a0965eb0332fad595cf7649d9d96e/javax.swing/src/javax/swing/text/html/HTMLEditorKit%24HTMLFactory.clj | clojure | (ns javax.swing.text.html.HTMLEditorKit$HTMLFactory
"A factory to build views for HTML. The following
table describes what this factory will build by
default.
TagView created
HTML.Tag.CONTENTInlineView
HTML.Tag.IMPLIEDjavax.swing.text.html.ParagraphView
HTML.Tag.Pjavax.swing.text.html.ParagraphView... | |
f6d1dfc79a00c2ad813dbc45ff7c240e68c683ad1ca67fe7f6791cecd660bc36 | bvaugon/ocapic | list.mli | (**************************************************************************)
(* *)
(* OCaml *)
(* *)
... | null | https://raw.githubusercontent.com/bvaugon/ocapic/a14cd9ec3f5022aeb5fe2264d595d7e8f1ddf58a/lib/list.mli | ocaml | ************************************************************************
OCaml
... | , projet Cristal , INRIA Rocquencourt
Copyright 1996 Institut National de Recherche en Informatique et
the GNU Lesser General Public License version 2.1 , with the
* List operations .
Some functions are flagged as not tail - recursive . A tail - recursive
... |
f8dbfe045b1888044c22dddeb315c1f8c7dae7db1fa3925a4bc08a75c3938d89 | dsheets/gloc | glo.ml | Copyright ( c ) 2012 Ashima Arts . All rights reserved .
* Author :
* Use of this source code is governed by a BSD - style license that can be
* found in the LICENSE file .
* Author: David Sheets
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*)... | null | https://raw.githubusercontent.com/dsheets/gloc/d5917c072ec314ae93a61344da2407f520fac1b5/src/glo.ml | ocaml | TODO: inference
TODO: inference
maintain order
TODO: interleaved overloads
Line is safe | Copyright ( c ) 2012 Ashima Arts . All rights reserved .
* Author :
* Use of this source code is governed by a BSD - style license that can be
* found in the LICENSE file .
* Author: David Sheets
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*)... |
f93a19db17e50f28b0c55459b14b292efabde69cfc8d15ca460f07a58e1bce93 | sdiehl/bulletproofs | Common.hs | module Test.Common
( commutes
, associates
, isIdentity
, isInverse
, distributes
) where
import Protolude
commutes
:: Eq a
=> (a -> a -> a)
-> a -> a -> Bool
commutes op x y
= (x `op` y) == (y `op` x)
associates
:: Eq a
=> (a -> a -> a)
-> a -> a -> a -> Bool
associates op x y z
= (x `op... | null | https://raw.githubusercontent.com/sdiehl/bulletproofs/6cb356a2ad44dea139abb81214f1babab8456b91/test/Test/Common.hs | haskell | module Test.Common
( commutes
, associates
, isIdentity
, isInverse
, distributes
) where
import Protolude
commutes
:: Eq a
=> (a -> a -> a)
-> a -> a -> Bool
commutes op x y
= (x `op` y) == (y `op` x)
associates
:: Eq a
=> (a -> a -> a)
-> a -> a -> a -> Bool
associates op x y z
= (x `op... | |
0e91dd0cf904ab6113f8a6cafec57c52938bd3a491ff13e7faba8ae92da999a5 | clojurecademy/clojurecademy | resume.clj | (ns clojurecademy.controller.course.resume
(:require [clojurecademy.dao.subject :as subject.dao]
[clojurecademy.dao.progress :as progress.dao]
[clojurecademy.dao.db :as db]
[clojurecademy.dao.chapter :as chapter.dao]
[clojurecademy.dao.sub-chapter :as sub-chapter.dao]
... | null | https://raw.githubusercontent.com/clojurecademy/clojurecademy/97dc7f9b91a90a3f30ca5a3de88542c90a50ce01/src/clj/clojurecademy/controller/course/resume.clj | clojure | TODO chain with ->>....refactor | (ns clojurecademy.controller.course.resume
(:require [clojurecademy.dao.subject :as subject.dao]
[clojurecademy.dao.progress :as progress.dao]
[clojurecademy.dao.db :as db]
[clojurecademy.dao.chapter :as chapter.dao]
[clojurecademy.dao.sub-chapter :as sub-chapter.dao]
... |
7f1f42e55599888ba993308ed09660554866fe3bcbb3814f90841721c9c0b7bb | ocsigen/lwt | lwt_luv.ml | let from_unix : Unix.file_descr -> int = Obj.magic
class engine = object
inherit Lwt_engine.abstract
val loop = ref (Luv.Loop.default ())
method! fork =
Luv.Loop.fork !loop |> function
| Ok () -> ()
| Error e -> failwith (Printf.sprintf "Could not handle the fork, this is probably a error in Lwt, p... | null | https://raw.githubusercontent.com/ocsigen/lwt/b3e7dd029dacbe37df9565c142c2206cfe6831c2/src/unix/luv/lwt_luv.ml | ocaml | let from_unix : Unix.file_descr -> int = Obj.magic
class engine = object
inherit Lwt_engine.abstract
val loop = ref (Luv.Loop.default ())
method! fork =
Luv.Loop.fork !loop |> function
| Ok () -> ()
| Error e -> failwith (Printf.sprintf "Could not handle the fork, this is probably a error in Lwt, p... | |
80c3255fc397868582e31235228011da8cb028570207a983984566ba395d9106 | hhugo/merge-fmt | resolve_cmd.ml | open Base
open Stdio
open Common
type version =
| Common
| Theirs
| Ours
let string_of_version = function
| Common -> "common"
| Theirs -> "theirs"
| Ours -> "ours"
type rev = Object of string
type versions =
{ common : rev
; theirs : rev
; ours : rev
}
let conflict ~filename =
In_channel.wit... | null | https://raw.githubusercontent.com/hhugo/merge-fmt/ddcddd85cbf1a596ad1759163ae2eb75673924f5/src/resolve_cmd.ml | ocaml | open Base
open Stdio
open Common
type version =
| Common
| Theirs
| Ours
let string_of_version = function
| Common -> "common"
| Theirs -> "theirs"
| Ours -> "ours"
type rev = Object of string
type versions =
{ common : rev
; theirs : rev
; ours : rev
}
let conflict ~filename =
In_channel.wit... | |
0d5d6240344c8631d3050fefa6aa744cc3c94f1fb9074a1ced969ded051184e1 | Martoon-00/toy-compiler | Data.hs | module Toy.Execution.Data
( In
, Out
, InOut
, Meta (..)
, withEmptyInput
) where
import Data.Text (Text)
import Data.Text.Buildable (Buildable (..))
import Formatting ((%))
import qualified Formatting as F
import Toy.Base ... | null | https://raw.githubusercontent.com/Martoon-00/toy-compiler/a325d56c367bbb673608d283197fcd51cf5960fa/src/Toy/Execution/Data.hs | haskell | module Toy.Execution.Data
( In
, Out
, InOut
, Meta (..)
, withEmptyInput
) where
import Data.Text (Text)
import Data.Text.Buildable (Buildable (..))
import Formatting ((%))
import qualified Formatting as F
import Toy.Base ... | |
646f8bf44934510d9629e7c539b46f6fb8122900a1e77461d04ab1d5922581b4 | gigasquid/hyperdimensional-playground | fairytale_nouns.clj | (ns hyperdimensional-playground.fairytale-nouns
(:require [clojure.string :as string])
(:import (java.util Properties)
(edu.stanford.nlp.pipeline StanfordCoreNLP Annotation)
(edu.stanford.nlp.ling CoreAnnotations$SentencesAnnotation CoreAnnotations$TokensAnnotation
... | null | https://raw.githubusercontent.com/gigasquid/hyperdimensional-playground/ee83b9b38467f3ae60b82e70ec78db6563dbf17a/src/hyperdimensional_playground/fairytale_nouns.clj | clojure | get all the nouns in our corpus
to put frequenies | (ns hyperdimensional-playground.fairytale-nouns
(:require [clojure.string :as string])
(:import (java.util Properties)
(edu.stanford.nlp.pipeline StanfordCoreNLP Annotation)
(edu.stanford.nlp.ling CoreAnnotations$SentencesAnnotation CoreAnnotations$TokensAnnotation
... |
68c80ea2c3300f43f499a42a136e5b9cbfb6520c768dc80ff5b8ad02c67afe7f | inconvergent/weird | extra.lisp | (in-package :weir)
; TODO: copy properties?
; TODO: copy grps?
(veq:fvdef 3->2 (wer fx &key new)
(declare (weir wer) (function fx))
(weird:with-struct (weir- verts max-verts num-verts) wer
(let* ((new (if new new (make :max-verts max-verts)))
(new-verts (weir-verts new)))
(declare (weir new) (... | null | https://raw.githubusercontent.com/inconvergent/weird/106d154ec2cd0e4ec977c3672ba717d6305c1056/src/weir/extra.lisp | lisp | TODO: copy properties?
TODO: copy grps?
swap indices | (in-package :weir)
(veq:fvdef 3->2 (wer fx &key new)
(declare (weir wer) (function fx))
(weird:with-struct (weir- verts max-verts num-verts) wer
(let* ((new (if new new (make :max-verts max-verts)))
(new-verts (weir-verts new)))
(declare (weir new) (veq:fvec new-verts))
(setf (weir-num-v... |
ff33471a8ea5c535dda6fbca33c2c73b2792b3ffbd342aa4212701ca81fca8a3 | chef/opscoderl_httpc | oc_httpc_worker.erl | -*- erlang - indent - level : 4;indent - tabs - mode : nil ; fill - column : 92 -*-
%% ex: ts=4 sw=4 et
@author < >
Copyright 2013 Opscode , Inc. All Rights Reserved .
%%
This file is provided to you under the Apache License ,
%% Version 2.0 (the "License"); you may not use this file
except in compliance w... | null | https://raw.githubusercontent.com/chef/opscoderl_httpc/58efd00f9e21f119890a3b105089878140ecd6fe/src/oc_httpc_worker.erl | erlang | ex: ts=4 sw=4 et
Version 2.0 (the "License"); you may not use this file
a copy of the License at
-2.0
Unless required by applicable law or agreed to in writing,
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
API
gen_se... | -*- erlang - indent - level : 4;indent - tabs - mode : nil ; fill - column : 92 -*-
@author < >
Copyright 2013 Opscode , Inc. All Rights Reserved .
This file is provided to you under the Apache License ,
except in compliance with the License . You may obtain
software distributed under the License is di... |
c7aaadbc0a996f1a36f38e1475c777e711fe633a96826886a4207cdc47aa8340 | smaccoun/beam-servant | User.hs | {-# LANGUAGE TypeFamilies #-}
module Api.Endpoints.User where
import Api.Resource
import Config.AppConfig
import AppPrelude
import Control.Lens hiding (element)
import qualified Crypto.Scrypt as S
import Data.Text.Encoding (encodeUtf8)
i... | null | https://raw.githubusercontent.com/smaccoun/beam-servant/1560f81c56ca7a324be1ee68208fb05c4dfea844/src/Api/Endpoints/User.hs | haskell | # LANGUAGE TypeFamilies # |
module Api.Endpoints.User where
import Api.Resource
import Config.AppConfig
import AppPrelude
import Control.Lens hiding (element)
import qualified Crypto.Scrypt as S
import Data.Text.Encoding (encodeUtf8)
import Data.UUID ... |
2dc711402fdea35fbb7fbd950bc5e000620c353febc83f34d30f9be3fc4d3674 | typedclojure/typedclojure | test_base_env.cljs | (ns cljs.core.typed.test.ympbyc.test-base-env
(:require-macros [cljs.core.typed :refer [ann ann-jsnominal] :as t])
(:require [cljs.core :refer [IVector ISeq ASeq List]]))
;;seq
(ann seq-vec (t/NonEmptySeqable number))
(def seq-vec (seq [1 2 3]))
(ann seq-empty (t/Option (t/NonEmptyASeq nil)))
(def seq-empty (seq ... | null | https://raw.githubusercontent.com/typedclojure/typedclojure/514f2a46ae0145f34bef0400495079ba3292b82b/typed/cljs.checker/test/cljs/core/typed/test/ympbyc/test_base_env.cljs | clojure | seq
fst
rest
last
test if NonEmptySeqable is Seqable
test vars in base-env-common
BUG: subtyping fails
BUG: Use of `list` invokes an error
; this fails somehow
(def list?-test (list? (list 1 2 3)))
BUG: this throws assert failed
jsnominals
inheritance | (ns cljs.core.typed.test.ympbyc.test-base-env
(:require-macros [cljs.core.typed :refer [ann ann-jsnominal] :as t])
(:require [cljs.core :refer [IVector ISeq ASeq List]]))
(ann seq-vec (t/NonEmptySeqable number))
(def seq-vec (seq [1 2 3]))
(ann seq-empty (t/Option (t/NonEmptyASeq nil)))
(def seq-empty (seq []))
... |
99860fb199d646c328721f7c6ee814c3fefd12ed1ce735f5ad68cf095ef48e87 | input-output-hk/ouroboros-network | RAWLock.hs | {-# LANGUAGE DeriveAnyClass #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DerivingStrategies #-}
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE LambdaCase #
# LANGUAGE ScopedTypeVariables #
-- | A Read-Append-Write (RAW) lock
--
-- Intended for qualified i... | null | https://raw.githubusercontent.com/input-output-hk/ouroboros-network/c82309f403e99d916a76bb4d96d6812fb0a9db81/ouroboros-consensus/src/Ouroboros/Consensus/Util/MonadSTM/RAWLock.hs | haskell | # LANGUAGE DeriveAnyClass #
# LANGUAGE DeriveGeneric #
# LANGUAGE DerivingStrategies #
| A Read-Append-Write (RAW) lock
Intended for qualified import
* Public API
* Exposed internals: non-bracketed acquire & release
------------------------------------------------------------------... | # LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE LambdaCase #
# LANGUAGE ScopedTypeVariables #
module Ouroboros.Consensus.Util.MonadSTM.RAWLock (
RAWLock
, new
, poison
, read
, withAppendAccess
, withReadAccess
, withWriteAccess
, unsafeAcquireAppendAccess
, unsafeAcquire... |
1721c5089c6db505f2b62861b2ad2b3462b66fb76d0beadec65a413bf0214259 | nmichel/ejpet | ejpet_scanner.erl | -module(ejpet_scanner).
-author('').
-export([tokenize/2]).
-define(is_hexa(C),
(C >= $A andalso C =< $F) orelse
(C >= $a andalso C =< $f) orelse
(C >= $0 andalso C =< $9)).
-record(config, {
string_apply_escape_sequence = true,
string_raw = false
}).
tokenize(... | null | https://raw.githubusercontent.com/nmichel/ejpet/f2cafee31582d1e538cd3623edf249d0d3fc1162/src/ejpet_scanner.erl | erlang | state_inject is never on top, except when the wrapped capture has been parsed.
We just have to transform the token "capture", into "inject", and we are done.
do not apply escape sequence in regex | -module(ejpet_scanner).
-author('').
-export([tokenize/2]).
-define(is_hexa(C),
(C >= $A andalso C =< $F) orelse
(C >= $a andalso C =< $f) orelse
(C >= $0 andalso C =< $9)).
-record(config, {
string_apply_escape_sequence = true,
string_raw = false
}).
tokenize(... |
e4c5314c2784658774b8b748c9f6eff93d597874183789bc6681d7c0251eef0b | basho-labs/riak_nagios | check_node_tests.erl | -module(check_node_tests).
-include_lib("eunit/include/eunit.hrl").
-include_lib("eunit_helper/include/eunit_helper.hrl").
-export([run/2]).
run(_, _) ->
erlang:error(check_node_tests).
cleanup_each(_, _) ->
net_kernel:stop().
should_fail_when_using_an_unknown_check() ->
Options = [{check, unknown_chec... | null | https://raw.githubusercontent.com/basho-labs/riak_nagios/9cc200e8cec7d6f71f445df5a7bd195f7a772e8a/test/check_node_tests.erl | erlang | -module(check_node_tests).
-include_lib("eunit/include/eunit.hrl").
-include_lib("eunit_helper/include/eunit_helper.hrl").
-export([run/2]).
run(_, _) ->
erlang:error(check_node_tests).
cleanup_each(_, _) ->
net_kernel:stop().
should_fail_when_using_an_unknown_check() ->
Options = [{check, unknown_chec... | |
8b59d350a4eea7b514863e7ad5ffeaec8c67d0c47f35976ef025bde8f7c29082 | jyh/metaprl | czf_itt_set.ml | doc <:doc<
@module[Czf_itt_set]
The @tt{Czf_itt_set} module provides the basic definition
of sets and their elements. The @tt{set} term denotes
the type of all sets, defined using the $W$-type in
the module @hrefmodule[Itt_w], as follows:
$$@set @equiv @w{T; @univ{1}; T}.$$
That is, the @emph{s... | null | https://raw.githubusercontent.com/jyh/metaprl/51ba0bbbf409ecb7f96f5abbeb91902fdec47a19/theories/czf/czf_itt_set.ml | ocaml |
***********************************************************************
* TERMS *
***********************************************************************
***********************************************************************
* DEFINITIONS ... | doc <:doc<
@module[Czf_itt_set]
The @tt{Czf_itt_set} module provides the basic definition
of sets and their elements. The @tt{set} term denotes
the type of all sets, defined using the $W$-type in
the module @hrefmodule[Itt_w], as follows:
$$@set @equiv @w{T; @univ{1}; T}.$$
That is, the @emph{s... |
75f46b8802a175d6fba0dc8064c4d9072b6a17e11dc095bbe07cbfb4b13a84dc | thephoeron/quipper-language | Types.hs | This file is part of Quipper . Copyright ( C ) 2011 - 2014 . Please see the
-- file COPYRIGHT for a list of authors, copyright holders, licensing,
-- and other details. All rights reserved.
--
-- ======================================================================
# LANGUAGE MultiParamTypeClasses #
# LANGUAGE Fle... | null | https://raw.githubusercontent.com/thephoeron/quipper-language/15e555343a15c07b9aa97aced1ada22414f04af6/Algorithms/CL/Types.hs | haskell | file COPYRIGHT for a list of authors, copyright holders, licensing,
and other details. All rights reserved.
======================================================================
# LANGUAGE DeriveDataTypeable #
| This module defines the specialized datatypes of the Class Number algorithm, and basic utility funct... | This file is part of Quipper . Copyright ( C ) 2011 - 2014 . Please see the
# LANGUAGE MultiParamTypeClasses #
# LANGUAGE FlexibleInstances #
# LANGUAGE FlexibleContexts #
# LANGUAGE UndecidableInstances #
# LANGUAGE TypeFamilies #
# LANGUAGE OverlappingInstances #
# LANGUAGE IncoherentInstances #
module Algorithms... |
ac6d473d5212939f5556144af00a66d5663ed059cd8509914189eece11895c81 | iu-parfunc/HSBencher | Fusion.hs | # LANGUAGE NamedFieldPuns , RecordWildCards , ScopedTypeVariables , CPP , BangPatterns #
# LANGUAGE TupleSections , DeriveDataTypeable #
# LANGUAGE TypeFamilies #
-- | Google Fusion Table upload of benchmark data.
--
-- This module must be used in conjunction with the main "hsbencher" package,
e.g. " import HSB... | null | https://raw.githubusercontent.com/iu-parfunc/HSBencher/76782b75b3a4b276c45a2c159e0b4cb6bd8a2360/hsbencher-fusion/HSBencher/Backend/Fusion.hs | haskell | | Google Fusion Table upload of benchmark data.
This module must be used in conjunction with the main "hsbencher" package,
* The plugin itself, what you probably want
* Creating and finding tables
* Details and configuration options.
* Prepping and uploading tuples (rows)
| A default plugin. This binding p... | # LANGUAGE NamedFieldPuns , RecordWildCards , ScopedTypeVariables , CPP , BangPatterns #
# LANGUAGE TupleSections , DeriveDataTypeable #
# LANGUAGE TypeFamilies #
e.g. " import HSBencher " .
module HSBencher.Backend.Fusion
defaultFusionPlugin
, getTableId, findTableId, makeTable, ensureColumns
... |
6ef10265c65f2d136cae7ace0642907d3f166f7cd3d99793d50895850d675bd9 | luksamuk/sonic-lisp-engine | animations.lisp | ;;;; animations.lisp
Copyright ( c ) 2018 - 2020 < >
This file is distributed under the MIT License .
;;;; See LICENSE for details.
(in-package :sonic-lisp)
(defstruct animation-props
keyframes
(time-per-frame 0.16 :type single-float)
(loopback nil))
(defclass animator ()
((%atlas :initarg :atla... | null | https://raw.githubusercontent.com/luksamuk/sonic-lisp-engine/28987769a8c60411862a415010e44c495c4ea875/animations.lisp | lisp | animations.lisp
See LICENSE for details.
Only set to a registered animation
Reset animation data only when not attributing to
same animation
If we surpassed the frame duration for the
animation, calculate the amount of frames
to skip and then wrap the timer around.
Restore timer
Increment current frame
If be... | Copyright ( c ) 2018 - 2020 < >
This file is distributed under the MIT License .
(in-package :sonic-lisp)
(defstruct animation-props
keyframes
(time-per-frame 0.16 :type single-float)
(loopback nil))
(defclass animator ()
((%atlas :initarg :atlas
:reader atlas)
(%atlas-size ... |
2889ea93f9254b01845da1a60f4eb7a00a47c64f2191f3945ba874ce7b0177dc | ocaml-sf/learn-ocaml-corpus | update1.ml | let rec cons : 'a . 'a -> 'a seq -> 'a seq =
fun x ys ->
match ys with
| Nil ->
One (x, Nil)
| Zero ys ->
One (x, ys)
| One (y, ys) ->
Zero (cons (x, y) ys)
let rec fupdate : 'a . int -> ('a -> 'a) -> 'a seq -> 'a seq =
fun i f xs ->
match xs with
| Nil ->
as... | null | https://raw.githubusercontent.com/ocaml-sf/learn-ocaml-corpus/7dcf4d72b49863a3e37e41b3c3097aa4c6101a69/exercises/fpottier/random_access_lists/wrong/update1.ml | ocaml | cannot happen; [i] is within bounds
wrong | let rec cons : 'a . 'a -> 'a seq -> 'a seq =
fun x ys ->
match ys with
| Nil ->
One (x, Nil)
| Zero ys ->
One (x, ys)
| One (y, ys) ->
Zero (cons (x, y) ys)
let rec fupdate : 'a . int -> ('a -> 'a) -> 'a seq -> 'a seq =
fun i f xs ->
match xs with
| Nil ->
| One ... |
ebb3c745c41af9bfd9367361952bc0c980d4f67baf2f78b72d6764f16b43118a | philnguyen/soft-contract | issue-101.rkt | #lang racket/base
(require racket/contract)
(define-syntax-rule (define2 x ctc e)
(begin
(define x e)
(provide (contract-out [x ctc]))))
(define2 g (between/c 1 10) 8)
| null | https://raw.githubusercontent.com/philnguyen/soft-contract/5e07dc2d622ee80b961f4e8aebd04ce950720239/soft-contract/test/programs/safe/issues/issue-101.rkt | racket | #lang racket/base
(require racket/contract)
(define-syntax-rule (define2 x ctc e)
(begin
(define x e)
(provide (contract-out [x ctc]))))
(define2 g (between/c 1 10) 8)
| |
9968791b598eca058f4d850724be0e069d3707e2b293d24b00134df9a537595f | nvim-treesitter/nvim-treesitter | locals.scm | (var_declaration
declarators: (var_declarators
(var (identifier)) @definition.var))
(var_assignment
variables: (assignment_variables
(var (identifier) @definition.var) @definition.associated))
(arg name: (identifier) @definition.parameter)
(anon_function) @scope
((function_statement
(function_name) @defi... | null | https://raw.githubusercontent.com/nvim-treesitter/nvim-treesitter/f96c409e3d2b5c4f8fe76f3e049958a293f13167/queries/teal/locals.scm | scheme | (var_declaration
declarators: (var_declarators
(var (identifier)) @definition.var))
(var_assignment
variables: (assignment_variables
(var (identifier) @definition.var) @definition.associated))
(arg name: (identifier) @definition.parameter)
(anon_function) @scope
((function_statement
(function_name) @defi... | |
7621df63e77316cc031ab7993c98f9a230f244bee057a680644872b944b76afd | PEZ/reagent-bidi-accountant-example | server.clj | (ns routing-example.server)
(defn handler [request]
{:status 200
:body (slurp "resources/public/index.html")})
| null | https://raw.githubusercontent.com/PEZ/reagent-bidi-accountant-example/de0ffe9ca5eb0a83e6bedea741b4335feb0ee255/dev/routing_example/server.clj | clojure | (ns routing-example.server)
(defn handler [request]
{:status 200
:body (slurp "resources/public/index.html")})
| |
40618522784f0e935017e12323fb7d0b7993a1c9b3e023253bb962d2b28acfa2 | lava-jato-the-game/lava-jato-the-game | client.cljs | (ns lava-jato-the-game.client
(:require [com.fulcrologic.fulcro.components :as comp :refer [defsc]]
[com.fulcrologic.fulcro.application :as fa]
[goog.dom :as gdom]
[goog.object :as gobj]
[goog.events :as gevt]
[goog.history.EventType :as history.EventType]
... | null | https://raw.githubusercontent.com/lava-jato-the-game/lava-jato-the-game/05c324ecc6ef4eab20042ee478f3ff2da957d0d0/src/main/lava_jato_the_game/client.cljs | clojure | (ns lava-jato-the-game.client
(:require [com.fulcrologic.fulcro.components :as comp :refer [defsc]]
[com.fulcrologic.fulcro.application :as fa]
[goog.dom :as gdom]
[goog.object :as gobj]
[goog.events :as gevt]
[goog.history.EventType :as history.EventType]
... | |
b430e0a3343d3adee0e36aef8f783ddb35a5fdfdd8469e64dbc144c80f83b09c | wireless-net/erlang-nommu | erts_alloc_config.erl | %%
%% %CopyrightBegin%
%%
Copyright Ericsson AB 2007 - 2011 . All Rights Reserved .
%%
The contents of this file are subject to the Erlang Public License ,
Version 1.1 , ( the " License " ) ; you may not use this file except in
%% compliance with the License. You should have received a copy of the
%% Erlang Pub... | null | https://raw.githubusercontent.com/wireless-net/erlang-nommu/79f32f81418e022d8ad8e0e447deaea407289926/lib/runtime_tools/src/erts_alloc_config.erl | erlang |
%CopyrightBegin%
compliance with the License. You should have received a copy of the
Erlang Public License along with this software. If not, it can be
retrieved online at /.
basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
the License for the specific language governing rights and limita... | Copyright Ericsson AB 2007 - 2011 . All Rights Reserved .
The contents of this file are subject to the Erlang Public License ,
Version 1.1 , ( the " License " ) ; you may not use this file except in
Software distributed under the License is distributed on an " AS IS "
The Initial Developer of the Original Cod... |
c9d2e655405874246aef07f6547f8c2365aa66c931dd4b50a356147197360d0b | iustin/corydalis | Settings.hs |
Copyright ( C ) 2013
This program is free software : you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation , either version 3 of the License , or
( at your option ) any later version .
This program is distributed i... | null | https://raw.githubusercontent.com/iustin/corydalis/43f8bf004904847fad43c428a9e1b20e67da964d/src/Settings.hs | haskell | # LANGUAGE OverloadedStrings #
| Settings are centralized, as much as possible, into this file. This
includes database connection settings, static file locations, etc.
| Runtime settings to configure this application. These settings can be
loaded from various sources: defaults, environment variables, config files,
... |
Copyright ( C ) 2013
This program is free software : you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation , either version 3 of the License , or
( at your option ) any later version .
This program is distributed i... |
baffa520937a2a5c3c994bbc1b3152db6d2f3504e36240221f4b4f049f0517c2 | nd/bird | 9.2.4.hs | --it is in my opinion | null | https://raw.githubusercontent.com/nd/bird/06dba97af7cfb11f558eaeb31a75bd04cacf7201/ch09/9.2.4.hs | haskell | it is in my opinion | |
459dda73dcc6b3fb834fef2f9e7c5782c1042724de1931860fec09a2d4bb3433 | jayrbolton/coursework | Lexer.hs | module Lexer where
import Data.Char
data Token =
{- Data types -}
Bool | Int | Float | Char |
{- Constants -}
True | False |
{- Loops -}
While |
{- Conditionals -}
If | Else |
{- Functions -}
... | null | https://raw.githubusercontent.com/jayrbolton/coursework/f0da276527d42a6751fb8d29c76de35ce358fe65/computability_and_formal_languages/Kingston_backup/cnc/Haskell/hws/Clite/Lexer.hs | haskell | Data types
Constants
Loops
Conditionals
Functions
Punctuation
Values
Formatting | module Lexer where
import Data.Char
data Token =
Bool | Int | Float | Char |
True | False |
While |
If | Else |
Main |
LeftBrace | RightBrace | LeftBracket | RightBracket |
LeftParen | RightParen | Semicolon | Comma |
... |
664eebbd7df4b5e393190219e105d15148eca173cfa42fef822498ddb4a33593 | akazukin5151/kpxhs | ExitDialogEvents.hs | module ViewEvents.ExitDialogEvents (exitEvent) where
import qualified Brick.Main as M
import qualified Brick.Types as T
import Brick.Widgets.Dialog (handleDialogEvent)
import qualified Brick.Widgets.Dialog as D
import Control.Monad.IO.Class (MonadIO (liftIO))
import ... | null | https://raw.githubusercontent.com/akazukin5151/kpxhs/a8fd8eae38e145a2d7e6eccd8e9e40cb15d974c6/src/kpxhs/ViewEvents/ExitDialogEvents.hs | haskell | module ViewEvents.ExitDialogEvents (exitEvent) where
import qualified Brick.Main as M
import qualified Brick.Types as T
import Brick.Widgets.Dialog (handleDialogEvent)
import qualified Brick.Widgets.Dialog as D
import Control.Monad.IO.Class (MonadIO (liftIO))
import ... | |
b17076be80b1f4c1eb432cda3b75446dc72eab93403498e9d3c9c418fb296b2d | qfpl/reflex-tutorial | Run.hs | {-# LANGUAGE OverloadedStrings #-}
# LANGUAGE RecursiveDo #
{-# LANGUAGE GADTs #-}
module Ex06.Run (
host
) where
import Control.Monad.Fix (MonadFix)
import Data.Monoid ((<>))
import Data.Text (Text)
import qualified Data.Text as Text
import Reflex.Dom.Core
import qualified Util.Bootstrap as B
import Ex06.Co... | null | https://raw.githubusercontent.com/qfpl/reflex-tutorial/07c1e6fab387cbeedd031630ba6a5cd946cc612e/code/exercises/src/Ex06/Run.hs | haskell | # LANGUAGE OverloadedStrings #
# LANGUAGE GADTs #
add
spend
refund | # LANGUAGE RecursiveDo #
module Ex06.Run (
host
) where
import Control.Monad.Fix (MonadFix)
import Data.Monoid ((<>))
import Data.Text (Text)
import qualified Data.Text as Text
import Reflex.Dom.Core
import qualified Util.Bootstrap as B
import Ex06.Common
moneyDisplay ::
Money ->
Text
moneyDisplay =
(... |
66f1e522c5f5e4426cbf0e8eae0d1f147869c680bea12905bffd38a7d01debcf | pixlsus/registry.gimp.org_static | sg-luminosity-masks.scm | ; Create Luminosity Masks for an image
Originally authored by < >
re - coded by to honor selection and layer offsets
; Will isolate light, mid, and dark tones in an image as channel masks
Adapted from tutorial by ( originally for PS )
; -1.html
; This program is free software; you can redistribute it and... | null | https://raw.githubusercontent.com/pixlsus/registry.gimp.org_static/ffcde7400f402728373ff6579947c6ffe87d1a5e/registry.gimp.org/files/sg-luminosity-masks.scm | scheme | Create Luminosity Masks for an image
Will isolate light, mid, and dark tones in an image as channel masks
-1.html
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... | Originally authored by < >
re - coded by to honor selection and layer offsets
Adapted from tutorial by ( originally for PS )
it under the terms of the GNU General Public License as published by
(define (script-fu-sg-luminosity-masks image drawable)
(gimp-image-undo-group-start image)
(let ((orig-se... |
296ad626650cfa40ed38e362efdbfc4afa8f9862f9d92075549be8cf5eb8197d | lesguillemets/sicp-haskell | NewtonsMethod.hs | module NewtonsMethod where
newtonsMethod :: (Double -> Double) -> Double -> Double
newtonsMethod g guess = fixP (newtonTransform g) guess
newtonTransform :: (Double -> Double) -> Double -> Double
newtonTransform g x = x - (g x / deriv g x)
deriv :: (Double -> Double) -> Double -> Double
deriv g = \x -> (g (x+dx) - g... | null | https://raw.githubusercontent.com/lesguillemets/sicp-haskell/df524a1e28c45fb16a56f539cad8babc881d0431/exercise/chap01/sect3/NewtonsMethod.hs | haskell | module NewtonsMethod where
newtonsMethod :: (Double -> Double) -> Double -> Double
newtonsMethod g guess = fixP (newtonTransform g) guess
newtonTransform :: (Double -> Double) -> Double -> Double
newtonTransform g x = x - (g x / deriv g x)
deriv :: (Double -> Double) -> Double -> Double
deriv g = \x -> (g (x+dx) - g... | |
4896aba95a792e9575e305a64deaf145eec56adae578ddde751fd228a4a5e3ad | EFanZh/EOPL-Exercises | exercise-2.16-test.rkt | #lang racket/base
(require rackunit)
(require "../solutions/exercise-2.16.rkt")
(let ([var-exp-example (var-exp 'a)]
[lambda-exp-example (lambda-exp 'a (var-exp 'b))]
[app-exp-example (app-exp (var-exp 'a) (var-exp 'b))])
(check-true (var-exp? var-exp-example))
(check-false (var-exp? lambda-exp-exampl... | null | https://raw.githubusercontent.com/EFanZh/EOPL-Exercises/11667f1e84a1a3e300c2182630b56db3e3d9246a/tests/exercise-2.16-test.rkt | racket | #lang racket/base
(require rackunit)
(require "../solutions/exercise-2.16.rkt")
(let ([var-exp-example (var-exp 'a)]
[lambda-exp-example (lambda-exp 'a (var-exp 'b))]
[app-exp-example (app-exp (var-exp 'a) (var-exp 'b))])
(check-true (var-exp? var-exp-example))
(check-false (var-exp? lambda-exp-exampl... | |
058785537048bad76958aacdea4578e66ad1885f787bf66b3ce8e496dcd4be8f | wargrey/graphics | constants.rkt | #lang typed/racket/base
(provide (all-defined-out))
(require "color.rkt")
(require "paint.rkt")
(require "font.rkt")
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
#;(void transparent hilite black)
(define white : FlRGBA (rgb* 'white))
(define gray : FlRGBA ... | null | https://raw.githubusercontent.com/wargrey/graphics/203b69dca12a5f3db384ef7096bf41f87360a2f0/bitmap/constants.rkt | racket |
(void transparent hilite black)
| #lang typed/racket/base
(provide (all-defined-out))
(require "color.rkt")
(require "paint.rkt")
(require "font.rkt")
(define white : FlRGBA (rgb* 'white))
(define gray : FlRGBA (rgb* 'gray))
(define brown : FlRGBA (rgb* 'brown))
(define magenta : FlRGBA (rgb* 'magenta))
(define red : FlRGBA (rgb* 'red))... |
bf6185a74cd127c08c77dd93cbc440923b91e184d98ccdaef7930711ead12d6f | gretay-js/ocamlfdo | report.ml | open Core
let verbose = ref true
let extension = "fdo.org"
let last_id = ref 0
let names = String.Table.create ()
let save_names = false
let get_id name =
if save_names
then (
match Hashtbl.find names name with
| None ->
Hashtbl.add_exn names ~key:name ~data:!last_id;
incr last_id;
!last... | null | https://raw.githubusercontent.com/gretay-js/ocamlfdo/5866fe9c2bfea03bc7efb033cc7b91a3a25cf520/src/report.ml | ocaml | depending on whether the name is write-only, or need to be reused, we can
save ids associated with each name. | open Core
let verbose = ref true
let extension = "fdo.org"
let last_id = ref 0
let names = String.Table.create ()
let save_names = false
let get_id name =
if save_names
then (
match Hashtbl.find names name with
| None ->
Hashtbl.add_exn names ~key:name ~data:!last_id;
incr last_id;
!last... |
0f5ed126c5aed7bc14696f297dfc5e1a2d25366697158207989428a2e61d0596 | marcoheisig/adventofcode | day-09.lisp | (defpackage :adventofcode-2019-day-9
(:use :cl :intcode-computer))
(in-package :adventofcode-2019-day-9)
(defun solve-day-09-part-1 ()
(run-intcode-computer
(make-intcode-computer
:input (constantly 1)
:program (read-intcode-computer-program "input"))))
(defun solve-day-09-part-2 ()
(run-intcode-com... | null | https://raw.githubusercontent.com/marcoheisig/adventofcode/e96a0da17cd79f424af984ed2648b49ffdacb893/2019/day-09/day-09.lisp | lisp | (defpackage :adventofcode-2019-day-9
(:use :cl :intcode-computer))
(in-package :adventofcode-2019-day-9)
(defun solve-day-09-part-1 ()
(run-intcode-computer
(make-intcode-computer
:input (constantly 1)
:program (read-intcode-computer-program "input"))))
(defun solve-day-09-part-2 ()
(run-intcode-com... | |
8037e105f1d4c17ae593013ecc585dadf89535b2ea9bc2fb6327ce57863b2f5d | ghcjs/jsaddle-dom | MediaStreamAudioSourceNode.hs | # LANGUAGE PatternSynonyms #
-- For HasCallStack compatibility
{-# LANGUAGE ImplicitParams, ConstraintKinds, KindSignatures #-}
# OPTIONS_GHC -fno - warn - unused - imports #
module JSDOM.Generated.MediaStreamAudioSourceNode
(getMediaStream, MediaStreamAudioSourceNode(..),
gTypeMediaStreamAudioSourceNode... | null | https://raw.githubusercontent.com/ghcjs/jsaddle-dom/5f5094277d4b11f3dc3e2df6bb437b75712d268f/src/JSDOM/Generated/MediaStreamAudioSourceNode.hs | haskell | For HasCallStack compatibility
# LANGUAGE ImplicitParams, ConstraintKinds, KindSignatures # | # LANGUAGE PatternSynonyms #
# OPTIONS_GHC -fno - warn - unused - imports #
module JSDOM.Generated.MediaStreamAudioSourceNode
(getMediaStream, MediaStreamAudioSourceNode(..),
gTypeMediaStreamAudioSourceNode)
where
import Prelude ((.), (==), (>>=), return, IO, Int, Float, Double, Bool(..), Maybe, m... |
c11d0ebafad2e35a24f404a2578fa8476577b0f0b740ca0e920f8e0752761443 | pokepay/aws-sdk-lisp | streams.dynamodb.lisp | ;; DO NOT EDIT: File is generated by AWS-SDK/GENERATOR.
(uiop:define-package #:aws-sdk/services/streams.dynamodb
(:use)
(:use-reexport #:aws-sdk/services/streams.dynamodb/api))
| null | https://raw.githubusercontent.com/pokepay/aws-sdk-lisp/836b87df520391478a19462443342dc56f4b3f2c/services/streams.dynamodb.lisp | lisp | DO NOT EDIT: File is generated by AWS-SDK/GENERATOR. |
(uiop:define-package #:aws-sdk/services/streams.dynamodb
(:use)
(:use-reexport #:aws-sdk/services/streams.dynamodb/api))
|
510831c33a098cf1364c92dd5e7f8601cc0b4871c6540bc747daa28381f08480 | binghe/OSCAR | pc-examples.lisp | ;; This runs on OSCAR_3.31
#| To run these problems, first load Perception-Causes_3.31a.lisp.
Then load this file. To run problem n, execute (simulate-oscar n). |#
(in-package "OSCAR")
(setf *simulation-problems* nil)
;======================================================================
(make-simulation-problem
... | null | https://raw.githubusercontent.com/binghe/OSCAR/049f3ea3cda8f7de1d58174d6fca019dbf2176df/pc-examples.lisp | lisp | This runs on OSCAR_3.31
To run these problems, first load Perception-Causes_3.31a.lisp.
Then load this file. To run problem n, execute (simulate-oscar n).
======================================================================
======================================================================
====================... |
(in-package "OSCAR")
(setf *simulation-problems* nil)
(make-simulation-problem
:number 1
:message
"This is the perceptual updating problem. First, Fred looks red to me. Later, Fred looks blue to me.
What should I conclude about the color of Fred?"
:reasons
*PERCEPTION*
*TEMPORAL-PROJECTION*
*incomp... |
b8f50a12466e84e7aacc635f54a32e17aea99a03a122cac598dbe1757b0b0124 | input-output-hk/cardano-wallet | Wallets.hs | # LANGUAGE AllowAmbiguousTypes #
# LANGUAGE DataKinds #
# LANGUAGE DuplicateRecordFields #
# LANGUAGE FlexibleContexts #
# LANGUAGE OverloadedLabels #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE TypeApplications #
# LANGUAGE TypeFamilies #
module Test.Integration.Scenario.CLI.Byron.Wallets
( spec
) where
impo... | null | https://raw.githubusercontent.com/input-output-hk/cardano-wallet/7b0192110fe226f992bca6198b8ee83fa4a37f46/lib/wallet/integration/src/Test/Integration/Scenario/CLI/Byron/Wallets.hs | haskell | create
delete
not available
re-create
re-create again? No!
create
get
list
❌
✔️
✔️
✔️
✔️
✔️
❌
✔️
✔️
✔️
✔️
✔️
❌
✔️
✔️
✔️
✔️
✔️
❌
✔️
✔️
✔️
✔️
✔️ | # LANGUAGE AllowAmbiguousTypes #
# LANGUAGE DataKinds #
# LANGUAGE DuplicateRecordFields #
# LANGUAGE FlexibleContexts #
# LANGUAGE OverloadedLabels #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE TypeApplications #
# LANGUAGE TypeFamilies #
module Test.Integration.Scenario.CLI.Byron.Wallets
( spec
) where
impo... |
c6295dc77abdcfd3e1d16fc5f7633ff41bec9bfe1e72bd6da1bc41134e461105 | wireless-net/erlang-nommu | system_information.erl | %% %CopyrightBegin%
%%
Copyright Ericsson AB 2013 . All Rights Reserved .
%%
The contents of this file are subject to the Erlang Public License ,
Version 1.1 , ( the " License " ) ; you may not use this file except in
%% compliance with the License. You should have received a copy of the
%% Erlang Public Licens... | null | https://raw.githubusercontent.com/wireless-net/erlang-nommu/79f32f81418e022d8ad8e0e447deaea407289926/lib/runtime_tools/src/system_information.erl | erlang | %CopyrightBegin%
compliance with the License. You should have received a copy of the
Erlang Public License along with this software. If not, it can be
retrieved online at /.
basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
the License for the specific language governing rights and limitat... | Copyright Ericsson AB 2013 . All Rights Reserved .
The contents of this file are subject to the Erlang Public License ,
Version 1.1 , ( the " License " ) ; you may not use this file except in
Software distributed under the License is distributed on an " AS IS "
-module(system_information).
-behaviour(gen_se... |
232a899d808513f7d361235cad2ddf5aa2ff45d96f58e522670338099ad21081 | monadbobo/ocaml-core | file_tail.mli | File_tail is useful for pulling data from a file that is being appended to by another
process . Creating a file tail returns the reader half of a pipe whose writer half is
populated by a background process that roughly does the following loop .
loop :
stat to find out if data is available
... | null | https://raw.githubusercontent.com/monadbobo/ocaml-core/9c1c06e7a1af7e15b6019a325d7dbdbd4cdb4020/base/async/extra/lib/file_tail.mli | ocaml | Errors are written to the pipe, and are nonrecoverable. After an error, the pipe
will always be closed.
* [Read_failed] occurs if some aspect of the open-seek-read-close used to get data
fails.
* [Stat_failed] occurs if [stat] fails.
* [Did_not_reach_eof_for span] occurs if it has been longer than
... | File_tail is useful for pulling data from a file that is being appended to by another
process . Creating a file tail returns the reader half of a pipe whose writer half is
populated by a background process that roughly does the following loop .
loop :
stat to find out if data is available
... |
3d94ffd908f51e11f91d344d840e183c2a090e25ab1e9b0e6efba7512edbe08b | helium/erlang-tpke | dealer_test.erl | -module(dealer_test).
-include_lib("eunit/include/eunit.hrl").
first_secret_equality_test() ->
{ok, Dealer} = dealer:new(),
{ok, Group} = dealer:group(Dealer),
TODO make this work over the MNT224 curve
Group = erlang_pbc : group_new('MNT224 ' ) ,
Element = erlang_pbc:element_new('Zr', Group),
K = 5,... | null | https://raw.githubusercontent.com/helium/erlang-tpke/0d9f8c5b30c10c73727402465963e6a33e680a56/test/dealer_test.erl | erlang | -module(dealer_test).
-include_lib("eunit/include/eunit.hrl").
first_secret_equality_test() ->
{ok, Dealer} = dealer:new(),
{ok, Group} = dealer:group(Dealer),
TODO make this work over the MNT224 curve
Group = erlang_pbc : group_new('MNT224 ' ) ,
Element = erlang_pbc:element_new('Zr', Group),
K = 5,... | |
a42c4f1ccd99486fdb9ec2cf5bcc84e9b43b5835022cac6aa0880fff344c0b4c | gedge-platform/gedge-platform | jose_jwe_enc_c20p.erl | -*- mode : erlang ; tab - width : 4 ; indent - tabs - mode : 1 ; st - rulers : [ 70 ] -*-
%% vim: ts=4 sw=4 ft=erlang noet
%%%-------------------------------------------------------------------
@author < >
2014 - 2019 ,
%%% @doc
%%%
%%% @end
Created : 31 May 2016 by < >
%%%---------------------------... | null | https://raw.githubusercontent.com/gedge-platform/gedge-platform/97c1e87faf28ba2942a77196b6be0a952bff1c3e/gs-broker/broker-server/deps/jose/src/jwe/jose_jwe_enc_c20p.erl | erlang | vim: ts=4 sw=4 ft=erlang noet
-------------------------------------------------------------------
@doc
@end
-------------------------------------------------------------------
jose_jwe callbacks
jose_jwe_enc callbacks
API
Types
====================================================================
jose_jwe callb... | -*- mode : erlang ; tab - width : 4 ; indent - tabs - mode : 1 ; st - rulers : [ 70 ] -*-
@author < >
2014 - 2019 ,
Created : 31 May 2016 by < >
-module(jose_jwe_enc_c20p).
-behaviour(jose_jwe).
-behaviour(jose_jwe_enc).
-export([from_map/1]).
-export([to_map/2]).
-export([algorithm/1]).
-export([bi... |
7a04eb4d8a964201db8adb99e35c3b6dbecea51edc2493b8bd5bbb7560cf31fe | sullyj3/adventofcode2022 | Day01.hs | module Day01 where
import AOC
import Data.Maybe (fromJust)
import Data.Text (Text)
import qualified Data.Text as T
import Utils (tRead)
solution = Solution {..}
where
parse = id
part1 = const ()
part2 = const ()
main = aocMain "inputs/01.txt" solution
| null | https://raw.githubusercontent.com/sullyj3/adventofcode2022/beff93b2f464ccd149f5a9d7bbae648aa9429eab/src/Day01.hs | haskell | module Day01 where
import AOC
import Data.Maybe (fromJust)
import Data.Text (Text)
import qualified Data.Text as T
import Utils (tRead)
solution = Solution {..}
where
parse = id
part1 = const ()
part2 = const ()
main = aocMain "inputs/01.txt" solution
| |
ae58e638db58e7eb1cf8c9c833351105711843094471f4cd7af77797261e6c23 | rudymatela/conjure | Prim.hs | -- |
-- Module : Conjure.Prim
Copyright : ( c ) 2021
License : 3 - Clause BSD ( see the file LICENSE )
Maintainer : < >
--
This module is part of " Conjure " .
--
-- The 'Prim' type and utilities involving it.
--
-- You are probably better off importing "Conjure".
module Conjure.Prim
( P... | null | https://raw.githubusercontent.com/rudymatela/conjure/9d2167e758e72b6be5970bc33f6b9e893fc5874f/src/Conjure/Prim.hs | haskell | |
Module : Conjure.Prim
The 'Prim' type and utilities involving it.
You are probably better off importing "Conjure".
| A primtive expression (paired with instance reification).
| Provides a primitive value to Conjure.
To be used on 'Show' instances.
(cf. 'prim')
| Provides a primitive value to Conj... | Copyright : ( c ) 2021
License : 3 - Clause BSD ( see the file LICENSE )
Maintainer : < >
This module is part of " Conjure " .
module Conjure.Prim
( Prim (..)
, prim
, pr
, prif
, primOrdCaseFor
, cjHoles
, cjTiersFor
, cjAreEqual
, cjMkEquation
)
where
import Conjure.Conju... |
5895b1c93e28d29b28f1ae682559f56046031bc52dfe438871b9c015b88f3a9f | screenshotbot/screenshotbot-oss | help.lisp | ;; Copyright 2018-Present Modern Interpreters Inc.
;;
This Source Code Form is subject to the terms of the Mozilla Public
License , v. 2.0 . If a copy of the MPL was not distributed with this
file , You can obtain one at /.
(uiop:define-package :screenshotbot/sdk/help
(:use #:cl
#:alexandria)
(:expor... | null | https://raw.githubusercontent.com/screenshotbot/screenshotbot-oss/da6a181de5222dc78f19951e32efa3a46277c32e/src/screenshotbot/sdk/help.lisp | lisp | Copyright 2018-Present Modern Interpreters Inc.
| This Source Code Form is subject to the terms of the Mozilla Public
License , v. 2.0 . If a copy of the MPL was not distributed with this
file , You can obtain one at /.
(uiop:define-package :screenshotbot/sdk/help
(:use #:cl
#:alexandria)
(:export
#:help))
(in-package :screenshotbot/sdk/help)
(... |
6109f07c79fa57dcdcadde97675a8e8f416af0486ba39f605f14270dff779fe7 | thierry-martinez/stdcompat | weak.mli | type 'a t
val create : int -> 'a t
val length : 'a t -> int
val set : 'a t -> int -> 'a option -> unit
val get : 'a t -> int -> 'a option
val get_copy : 'a t -> int -> 'a option
val check : 'a t -> int -> bool
val fill : 'a t -> int -> int -> 'a option -> unit
val blit : 'a t -> int -> 'a t -> int -> int -> unit
module... | null | https://raw.githubusercontent.com/thierry-martinez/stdcompat/83d786cdb17fae0caadf5c342e283c3dcfee2279/interfaces/3.07/weak.mli | ocaml | type 'a t
val create : int -> 'a t
val length : 'a t -> int
val set : 'a t -> int -> 'a option -> unit
val get : 'a t -> int -> 'a option
val get_copy : 'a t -> int -> 'a option
val check : 'a t -> int -> bool
val fill : 'a t -> int -> int -> 'a option -> unit
val blit : 'a t -> int -> 'a t -> int -> int -> unit
module... | |
6284f7120b47e83d01ee189fed6ed0371dcd1d2c31b47629768f2424d0886ec3 | SamB/coq | lib.mli | (************************************************************************)
v * The Coq Proof Assistant / The Coq Development Team
< O _ _ _ , , * CNRS - Ecole Polytechnique - INRIA Futurs - Universite Paris Sud
\VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *... | null | https://raw.githubusercontent.com/SamB/coq/8f84aba9ae83a4dc43ea6e804227ae8cae8086b1/library/lib.mli | ocaml | **********************************************************************
// * This file is distributed under the terms of the
* GNU Lesser General Public License Version 2.1
**********************************************************************
i $Id$ i
s This module provides a ge... | v * The Coq Proof Assistant / The Coq Development Team
< O _ _ _ , , * CNRS - Ecole Polytechnique - INRIA Futurs - Universite Paris Sud
\VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
type node =
| Leaf of... |
801ddf42af149916ab4570ddedd304790a7d5fb110fd37a3cf633b2e85973fb4 | quil-lang/qvm | ping.lisp | api / ping.lisp
;;;;
Author :
(in-package #:qvm-app)
(defun handle-ping ()
(format nil "pong ~D" (get-universal-time)))
| null | https://raw.githubusercontent.com/quil-lang/qvm/de95ead6e7df70a1f8e0212455a802bd0cef201c/app/src/api/ping.lisp | lisp | api / ping.lisp
Author :
(in-package #:qvm-app)
(defun handle-ping ()
(format nil "pong ~D" (get-universal-time)))
| |
7a9be8d824a7beb76f17f1080a4cd12b4e94b7283b15a802c763cad2f59c656e | cronburg/antlr-haskell | Common.hs | |
Module : Text . Description : Haskell - level helper functions used throughout Text . ANTLR
Copyright : ( c ) , 2018
License : BSD3
Maintainer :
Stability : experimental
Portability : POSIX
Module : Text.ANTLR.Common
Description : Haskell-level helper functi... | null | https://raw.githubusercontent.com/cronburg/antlr-haskell/7a9367038eaa58f9764f2ff694269245fbebc155/src/Text/ANTLR/Common.hs | haskell | |
Module : Text . Description : Haskell - level helper functions used throughout Text . ANTLR
Copyright : ( c ) , 2018
License : BSD3
Maintainer :
Stability : experimental
Portability : POSIX
Module : Text.ANTLR.Common
Description : Haskell-level helper functi... | |
affcd6971cd49425d0ef9a6a6c24e6c1af19f2c2195f0817303f3a9a3cae9ea6 | scmlab/gcl | Pretty.hs | # LANGUAGE FlexibleInstances #
# LANGUAGE MultiParamTypeClasses #
{-# LANGUAGE OverloadedStrings #-}
module Pretty
( module Prettyprinter
, module Pretty.Util
) where
import Error ( Error )
import Prelude hiding ( Ordering(..) )
import Prett... | null | https://raw.githubusercontent.com/scmlab/gcl/3d3aefb513ce6d3821265d77b6f3f0ffba0f4c66/src/Pretty.hs | haskell | # LANGUAGE OverloadedStrings #
------------------------------------------------------------------------------
| Misc
# OVERLAPPING # | # LANGUAGE FlexibleInstances #
# LANGUAGE MultiParamTypeClasses #
module Pretty
( module Prettyprinter
, module Pretty.Util
) where
import Error ( Error )
import Prelude hiding ( Ordering(..) )
import Pretty.Abstract ( )
impor... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.