_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 |
|---|---|---|---|---|---|---|---|---|
9ea5bc94013b624f0037149b7275e2e18b44715dc5f161e3725d77676c60be2f | evrim/core-server | 3501.lisp | Core Server : Web Application Server
Copyright ( C ) 2006 - 2008 , Aycan iRiCAN
;; 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 opti... | null | https://raw.githubusercontent.com/evrim/core-server/200ea8151d2f8d81b593d605b183a9cddae1e82d/src/rfc/3501.lisp | lisp | This program is free software: you can redistribute it and/or modify
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public L... | Core Server : Web Application Server
Copyright ( C ) 2006 - 2008 , Aycan iRiCAN
it under the terms of the GNU General Public License as published by
the Free Software Foundation , either version 3 of the License , or
You should have received a copy of the GNU General Public License
(in-package :tr.g... |
9e88cb17b52811aad32db3dc3a6719fc152bd43fdb0fa0f738fd09bfad8b181b | f-o-a-m/kepler | Keeper.hs | # LANGUAGE TemplateHaskell #
module Tendermint.SDK.Modules.Auth.Keeper
( AuthEffs
, Accounts(..)
, createAccount
, updateAccount
, getAccount
, eval
-- stores
, accountsMap
) where
import Polysemy
import Polysemy.Error (Error, mapError, throw)
import ... | null | https://raw.githubusercontent.com/f-o-a-m/kepler/6c1ad7f37683f509c2f1660e3561062307d3056b/hs-abci-sdk/src/Tendermint/SDK/Modules/Auth/Keeper.hs | haskell | stores
------------------------------------------------------------------------------
------------------------------------------------------------------------------ | # LANGUAGE TemplateHaskell #
module Tendermint.SDK.Modules.Auth.Keeper
( AuthEffs
, Accounts(..)
, createAccount
, updateAccount
, getAccount
, eval
, accountsMap
) where
import Polysemy
import Polysemy.Error (Error, mapError, throw)
import Tendermint.S... |
a77c102cba96b388958bd923e19461d774674e8c7a14314c7ebd227fe8ba0dfd | matthiasn/inspect | menu.cljs | (ns inspect.main.menu
(:require [taoensso.timbre :as timbre :refer-macros [info debug]]
[electron :refer [app Menu dialog]]
[cljs.nodejs :as nodejs :refer [process]]
[inspect.main.runtime :as rt]))
(defn open-dialog [put-fn]
(let [options (clj->js {:properties ["openFile"]
... | null | https://raw.githubusercontent.com/matthiasn/inspect/963ae5e29fc1c836c620cfed67787f1b99c3fe0c/src/cljs/inspect/main/menu.cljs | clojure | (ns inspect.main.menu
(:require [taoensso.timbre :as timbre :refer-macros [info debug]]
[electron :refer [app Menu dialog]]
[cljs.nodejs :as nodejs :refer [process]]
[inspect.main.runtime :as rt]))
(defn open-dialog [put-fn]
(let [options (clj->js {:properties ["openFile"]
... | |
08c55a046c43c743aabb2a1de80eb51e61a1da657e1a666f86a55176902fb0d5 | metabase/metabase | ldap_test.clj | (ns metabase-enterprise.enhancements.integrations.ldap-test
(:require
[clojure.test :refer :all]
[metabase-enterprise.enhancements.integrations.ldap :as ldap-ee]
[metabase.integrations.ldap :as ldap]
[metabase.models.user :as user :refer [User]]
[metabase.public-settings.premium-features :as premium-fe... | null | https://raw.githubusercontent.com/metabase/metabase/18d190cf05df4233aa6d14d6580faa68293ba980/enterprise/backend/test/metabase_enterprise/enhancements/integrations/ldap_test.clj | clojure | (ns metabase-enterprise.enhancements.integrations.ldap-test
(:require
[clojure.test :refer :all]
[metabase-enterprise.enhancements.integrations.ldap :as ldap-ee]
[metabase.integrations.ldap :as ldap]
[metabase.models.user :as user :refer [User]]
[metabase.public-settings.premium-features :as premium-fe... | |
221c45ff1492093aff983dc28c67c11f48b2737764f7b0348a61b677705b05c9 | Beluga-lang/Beluga | show.mli | (** Module type for types with functions for pretty-printing and converting
values to readable strings. *)
module type SHOW = sig
type t
(** [pp ppf t] emits [t] pretty-printed to [ppf]. *)
val pp : Format.formatter -> t -> unit
(** [show t] pretty-prints [t] to a string. *)
val show : t -> string
end
... | null | https://raw.githubusercontent.com/Beluga-lang/Beluga/4d1c1bd917daac43c304c527b155c12dba76391a/src/support/show.mli | ocaml | * Module type for types with functions for pretty-printing and converting
values to readable strings.
* [pp ppf t] emits [t] pretty-printed to [ppf].
* [show t] pretty-prints [t] to a string.
* Functor building an implementation of {!SHOW} given a type with a
pretty-printer. | module type SHOW = sig
type t
val pp : Format.formatter -> t -> unit
val show : t -> string
end
module Make (T : sig
type t
val pp : Format.formatter -> t -> unit
end) : SHOW with type t = T.t
* If [ f : ' t - > 's ] , then [ contramap show f ] is an instance of { ! SHOW }
for values of type [ ' t... |
fc34988f9dd9c880592efcc25ed6989ac88bdfded84d62e7b27699247f06724a | LiteTabs/CL-CAD | cl-cad.printing.lisp | (in-package :cl-cad)
(defun print-properties ()
(let ((print-dlg (make-instance 'gtk:page-setup-unix-dialog)))
(gtk:dialog-run print-dlg)
(gtk:object-destroy print-dlg)))
(defun print-dialog ()
(let ((print-dlg (make-instance 'gtk:print-unix-dialog
:title "Print")))
(gtk:dialog-run print-dlg)
... | null | https://raw.githubusercontent.com/LiteTabs/CL-CAD/539c90e58e668b72a2849e8c0caebf65236866c6/cl-cad.printing.lisp | lisp | (in-package :cl-cad)
(defun print-properties ()
(let ((print-dlg (make-instance 'gtk:page-setup-unix-dialog)))
(gtk:dialog-run print-dlg)
(gtk:object-destroy print-dlg)))
(defun print-dialog ()
(let ((print-dlg (make-instance 'gtk:print-unix-dialog
:title "Print")))
(gtk:dialog-run print-dlg)
... | |
80e20c71106f3b25510b0bfaf07389b6ce02a4cc8bb4dd17c7030ced1122c620 | solita/mnt-teet | contract_style.cljs | (ns teet.contract.contract-style
(:require [teet.theme.theme-colors :as theme-colors]))
(defn contract-page-container-style
[]
{:padding "2rem 2.5rem"
:background-color theme-colors/white
:flex 1})
(defn contract-responsibilities-container-style
[]
{:padding "1rem 1rem"
:background-color theme-colo... | null | https://raw.githubusercontent.com/solita/mnt-teet/f4936672a9a6523ba9eec3fa5c63505913c63259/app/frontend/src/cljs/teet/contract/contract_style.cljs | clojure | (ns teet.contract.contract-style
(:require [teet.theme.theme-colors :as theme-colors]))
(defn contract-page-container-style
[]
{:padding "2rem 2.5rem"
:background-color theme-colors/white
:flex 1})
(defn contract-responsibilities-container-style
[]
{:padding "1rem 1rem"
:background-color theme-colo... | |
3f653c6069c09b104c41386ab2d24d048a817d2466516b5c4011af2d38f5d7ff | mikera/core.matrix | pagerank.clj | (ns clojure.core.matrix.demo.pagerank
(:refer-clojure :exclude [* - + / == < <= > >= not= = min max])
(:require clojure.core.matrix.impl.ndarray
[clojure.core.matrix :refer :all]
[clojure.core.matrix.operators :refer :all]))
(defn demo []
;; ================================================... | null | https://raw.githubusercontent.com/mikera/core.matrix/0a35f6e3d6d2335cb56f6f3e5744bfa1dd0390aa/src/test/clojure/clojure/core/matrix/demo/pagerank.clj | clojure | =================================================================================
A demo of a simple Pagerank calculation
For more info on background and algoritrhm see:
-
link matrix: each row represnts the number of
outbound links from a page to other pages
where do outbound visitors go, as a proportion?
... | (ns clojure.core.matrix.demo.pagerank
(:refer-clojure :exclude [* - + / == < <= > >= not= = min max])
(:require clojure.core.matrix.impl.ndarray
[clojure.core.matrix :refer :all]
[clojure.core.matrix.operators :refer :all]))
(defn demo []
(def links
[[0 0 1 1 0 0 1 2 0 0]
[1 0 0 1 0 ... |
ee7e96a4b04dba57f2507cf3adcd88f979e441ba98594261cd75bf6d4b130e49 | NorfairKing/tickler | Tickles.hs | {-# LANGUAGE OverloadedStrings #-}
# LANGUAGE QuasiQuotes #
# LANGUAGE RecordWildCards #
# LANGUAGE TemplateHaskell #
module Tickler.Web.Server.Handler.Tickles
( getTicklesR,
makeItemInfoWidget,
)
where
import Data.Time
import Import
import Tickler.API
import Tickler.Client
import Tickler.Web.Server.Foundatio... | null | https://raw.githubusercontent.com/NorfairKing/tickler/1b0c05dc1d32847596bd3ffe4f93d094e1f6382a/tickler-web-server/src/Tickler/Web/Server/Handler/Tickles.hs | haskell | # LANGUAGE OverloadedStrings # | # LANGUAGE QuasiQuotes #
# LANGUAGE RecordWildCards #
# LANGUAGE TemplateHaskell #
module Tickler.Web.Server.Handler.Tickles
( getTicklesR,
makeItemInfoWidget,
)
where
import Data.Time
import Import
import Tickler.API
import Tickler.Client
import Tickler.Web.Server.Foundation
import Tickler.Web.Server.Time
im... |
20c144a55b359cd09df1f043f1aceeb50f5525dd3f6dfe5c17983c6bba16ac9a | xapi-project/xen-api | datamodel_main.ml |
* Copyright ( C ) 2006 - 2009 Citrix Systems Inc.
*
* This program is free software ; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation ; version 2.1 only . with the special
* exception on linking describe... | null | https://raw.githubusercontent.com/xapi-project/xen-api/50c8a2edfd1c78eb35ec75348738f8ae9ccf5f3e/ocaml/idl/datamodel_main.ml | ocaml | shows release_closed
shows release_impl as well
Add all implicit messages to the API directly
Only show those visible to the client
And only messages marked as not hidden from the docs, and non-internal fields |
* Copyright ( C ) 2006 - 2009 Citrix Systems Inc.
*
* This program is free software ; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation ; version 2.1 only . with the special
* exception on linking describe... |
d8b2c2b26286022207f2b4bd8a4568c09a572dd3162a1b5fe1f0cd38b84b8599 | robert-strandh/Acclimation | restart.lisp | (cl:in-package #:acclimation)
(defgeneric report-function (restart language))
(defgeneric interactive-function (restart language))
(defmacro with-restarts (cases &body body)
(let ((block-name (gensym))
(instance-names (loop repeat (length cases)
collect (gensym))))
`(block... | null | https://raw.githubusercontent.com/robert-strandh/Acclimation/8b4418c5760a377b5e82d821658b7fd7ac494fb1/restart.lisp | lisp | (cl:in-package #:acclimation)
(defgeneric report-function (restart language))
(defgeneric interactive-function (restart language))
(defmacro with-restarts (cases &body body)
(let ((block-name (gensym))
(instance-names (loop repeat (length cases)
collect (gensym))))
`(block... | |
802b1246d59f09d0942c3eeb2acce571027ab24d7b1600e2f3b90b4790c8cab6 | hakaru-dev/hakaru | CoinBias20.hs | # LANGUAGE DataKinds , TypeOperators , OverloadedStrings #
module CoinBias20 where
import Prelude (print, length, IO)
import Language.Hakaru.Syntax.Prelude
import Language.Hakaru.Disintegrate
import Language.Hakaru.Syntax.ABT
import Language.Hakaru.Syntax.AST
import Language.Hakaru.Types.DataKind
import Language.Haka... | null | https://raw.githubusercontent.com/hakaru-dev/hakaru/94157c89ea136c3b654a85cce51f19351245a490/haskell/Tests/Unroll/CoinBias20.hs | haskell | # LANGUAGE DataKinds , TypeOperators , OverloadedStrings #
module CoinBias20 where
import Prelude (print, length, IO)
import Language.Hakaru.Syntax.Prelude
import Language.Hakaru.Disintegrate
import Language.Hakaru.Syntax.ABT
import Language.Hakaru.Syntax.AST
import Language.Hakaru.Types.DataKind
import Language.Haka... | |
2595148128779957e3d40e455eb5cbba58bc82df0987a180457f118d623a4344 | justone/brisk | main.clj | (ns brisk.main
(:require
[clojure.edn :as edn]
[clojure.java.io :as io]
[clojure.string :as string]
[clojure.tools.cli :refer [parse-opts]]
[pod-racer.core :as pod]
[taoensso.nippy :as nippy]
[brisk.lib.opts :as opts]
[brisk.lib.string]
)
(:import
[java.io Writer OutputStre... | null | https://raw.githubusercontent.com/justone/brisk/333d083466d7466d976fa9721d69ef73f0b47e1c/src/brisk/main.clj | clojure | Main | (ns brisk.main
(:require
[clojure.edn :as edn]
[clojure.java.io :as io]
[clojure.string :as string]
[clojure.tools.cli :refer [parse-opts]]
[pod-racer.core :as pod]
[taoensso.nippy :as nippy]
[brisk.lib.opts :as opts]
[brisk.lib.string]
)
(:import
[java.io Writer OutputStre... |
bfacaa264a26dacb10023b4dd17a9cd61cde6edeb9f5f6cc72a3e32fa2e39df8 | acl2/acl2 | blake2s-mixing-proof.lisp | ; A proof of an R1CS for a mixing function from blake2s
;
Copyright ( C ) 2021 Kestrel Institute
;
License : A 3 - clause BSD license . See the file books/3BSD - mod.txt .
;
Author : ( )
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(in-package "ZKSEMAPHORE")
;; STATUS: CO... | null | https://raw.githubusercontent.com/acl2/acl2/48f6f076b9d1558c37cf6e1392b39bcbb020aa84/books/kestrel/ethereum/semaphore/blake2s-mixing-proof.lisp | lisp | A proof of an R1CS for a mixing function from blake2s
STATUS: COMPLETE
the spec
for equal-of-cons
The Spec
The spec for this R1CS. Conceptually, this takes inputs v_in, x and y, and
also takes the expected output, v_out. But the values come in as individual
g (the mixing function from blake2s) on the pac... | Copyright ( C ) 2021 Kestrel Institute
License : A 3 - clause BSD license . See the file books/3BSD - mod.txt .
Author : ( )
(in-package "ZKSEMAPHORE")
(include-book "r1cs-proof-support")
(include-book "r1cs-proof-rules")
(include-book "kestrel/crypto/r1cs/sparse/rules-axe" :dir :system)
(include-book "kes... |
a4a6b9374e37c72c2591ff61e618ad0303e514b855ca139db3a734cdc345aaba | cram2/cram | matrix-set-all.lisp | Regression test MATRIX - SET - ALL for GSLL , automatically generated
;;
Copyright 2009 , 2011 , 2014
Distributed under the terms of the GNU General Public License
;;
;; 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
... | null | https://raw.githubusercontent.com/cram2/cram/dcb73031ee944d04215bbff9e98b9e8c210ef6c5/cram_3rdparty/gsll/src/tests/matrix-set-all.lisp | lisp |
This program is free software: you can redistribute it and/or modify
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Publi... | Regression test MATRIX - SET - ALL for GSLL , automatically generated
Copyright 2009 , 2011 , 2014
Distributed under the terms of the GNU General Public License
it under the terms of the GNU General Public License as published by
the Free Software Foundation , either version 3 of the License , or
You sho... |
0f0746dae3d428d6e8dba27365b0bfd2225e927c85cd6a0422fd1e80511bf94f | fakedata-haskell/fakedata | SlackEmoji.hs | # LANGUAGE TemplateHaskell #
{-# LANGUAGE OverloadedStrings #-}
module Faker.SlackEmoji where
import Data.Text
import Faker
import Faker.Internal
import Faker.Provider.SlackEmoji
import Faker.TH
$(generateFakeField "slackEmoji" "people")
$(generateFakeField "slackEmoji" "nature")
$(generateFakeField "slackEmoji" "... | null | https://raw.githubusercontent.com/fakedata-haskell/fakedata/e6fbc16cfa27b2d17aa449ea8140788196ca135b/src/Faker/SlackEmoji.hs | haskell | # LANGUAGE OverloadedStrings # | # LANGUAGE TemplateHaskell #
module Faker.SlackEmoji where
import Data.Text
import Faker
import Faker.Internal
import Faker.Provider.SlackEmoji
import Faker.TH
$(generateFakeField "slackEmoji" "people")
$(generateFakeField "slackEmoji" "nature")
$(generateFakeField "slackEmoji" "food_and_drink")
$(generateFakeFie... |
360104c84a0dd89ef5fbdf9dbb46cb86fc8d4ef3e0e51c476fac4338620f0b21 | mirage/irmin | contents.ml |
* Copyright ( c ) 2013 - 2022 < >
*
* Permission to use , copy , modify , and distribute this software for any
* purpose with or without fee is hereby granted , provided that the above
* copyright notice and this permission notice appear in all copies .
*
* THE SOFTWARE IS PROVIDED " AS IS " AND... | null | https://raw.githubusercontent.com/mirage/irmin/abeee121a6db7b085b3c68af50ef24a8d8f9ed05/src/irmin/contents.ml | ocaml | Manually add a prefix to default contents, in order to prevent hash
collision between contents and nodes or commits (see
). |
* Copyright ( c ) 2013 - 2022 < >
*
* Permission to use , copy , modify , and distribute this software for any
* purpose with or without fee is hereby granted , provided that the above
* copyright notice and this permission notice appear in all copies .
*
* THE SOFTWARE IS PROVIDED " AS IS " AND... |
6e178727b8c2749c3e2d6f5a5beb3ef3c176d16efd345bccb37bddc81b44a110 | static-analysis-engineering/codehawk | jCHVarInfo.mli | = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
CodeHawk Java Analyzer
Author :
------------------------------------------------------------------------------
The MIT License ( MIT )
... | null | https://raw.githubusercontent.com/static-analysis-engineering/codehawk/98ced4d5e6d7989575092df232759afc2cb851f6/CodeHawk/CHJ/jchsys/jCHVarInfo.mli | ocaml | jchlib
jchpre | = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
CodeHawk Java Analyzer
Author :
------------------------------------------------------------------------------
The MIT License ( MIT )
... |
82818547a03ecdc1d9ec93df694dd699ba94d02a43f6114950fbcfa08495035f | nominolo/scion | TypeOf.hs | # LANGUAGE CPP #
-- |
Module : Scion . Inspect .
Copyright : ( c ) 2008
-- License : BSD-style
--
-- Maintainer :
-- Stability : experimental
-- Portability : portable
--
module Scion.Inspect.TypeOf where
import Scion.Inspect.Find ( SearchResult(..) )
import GHC
import Var ( varType )
import T... | null | https://raw.githubusercontent.com/nominolo/scion/99b4589175665687181a932cd836850205625f71/lib/Scion/Inspect/TypeOf.hs | haskell | |
License : BSD-style
Maintainer :
Stability : experimental
Portability : portable
----------------------------------------------------------------------------
XXX: really?
do something else with coercion/dict vars?
| Reduce a top-level type application if possible. That is, we perform the
following... | # LANGUAGE CPP #
Module : Scion . Inspect .
Copyright : ( c ) 2008
module Scion.Inspect.TypeOf where
import Scion.Inspect.Find ( SearchResult(..) )
import GHC
import Var ( varType )
import TypeRep ( Type(..), PredType(..) )
typeOf :: (SearchResult Id, [SearchResult Id]) -> Maybe Type
typeOf (leaf, p... |
bba14160c6b189ed7533be8613a03bd92fdc4e497cc145a339f7f49ceab46cf7 | HowProgrammingWorks/Lenses | 1-lens.hs | -- cabal install template-haskell
--
-- Lens is implementation of most common of optics.
--
Real makeLens implementation more complex supporting all of syntax
-- cases for creating types.
--
{-# LANGUAGE Rank2Types #-}
# LANGUAGE TemplateHaskell #
module Lens where
import Language.Haskell.TH
type Lens s t a b = fo... | null | https://raw.githubusercontent.com/HowProgrammingWorks/Lenses/a5056f444a6b1e6fc1e42cfde173eb4e88d6110a/Haskell/advanced/1-lens.hs | haskell | cabal install template-haskell
Lens is implementation of most common of optics.
cases for creating types.
# LANGUAGE Rank2Types # | Real makeLens implementation more complex supporting all of syntax
# LANGUAGE TemplateHaskell #
module Lens where
import Language.Haskell.TH
type Lens s t a b = forall f . Functor f => (a -> f b) -> s -> f t
type Lens' s a = Lens s s a a
lens :: (s -> a) -> (s -> b -> t) -> Lens s t a b
lens getter setter = \afb ... |
6d397cdca60905f065e63de932254a6146276e6ba706f7d1f8a5d66d6874f0c2 | lambe-lang/nethra | common.ml | open Nethra.Syntax.Source
open Nethra.Syntax.Parser
open Nethra.Toy.Cst.Render
let response f r =
let open Response.Destruct in
fold
~success:(fun (a, b, _) -> (Some (f a), b))
~failure:(fun (_, b, _) -> (None, b))
r
module Parsec = Parsers.Parsec (Sources.FromChars)
let render term =
let buffer = ... | null | https://raw.githubusercontent.com/lambe-lang/nethra/bf68fa1d0e002cbb871ce2a21d99287e99405a8d/test/nethra/toy/s01_parser/common.ml | ocaml | open Nethra.Syntax.Source
open Nethra.Syntax.Parser
open Nethra.Toy.Cst.Render
let response f r =
let open Response.Destruct in
fold
~success:(fun (a, b, _) -> (Some (f a), b))
~failure:(fun (_, b, _) -> (None, b))
r
module Parsec = Parsers.Parsec (Sources.FromChars)
let render term =
let buffer = ... | |
551863afe7cb67f4a48b623683d39126b28a459410737f85fe972352a93d2b8e | timvisher/lein-checkout | utils.clj | (ns leiningen.checkout.utils
(:require [clojure.pprint]
[fs.core :as fs])
(:import [java.io BufferedReader StringReader]))
(defn pprint-str [o]
(with-open [w (java.io.StringWriter.)]
(clojure.pprint/pprint o w)
(.toString w)))
(defn bash-comment [o]
{:pre [(= java.lang.String (type o))]}
... | null | https://raw.githubusercontent.com/timvisher/lein-checkout/bb3f83e33e17e45645428c1f2421711eb60cc003/src/leiningen/checkout/utils.clj | clojure | (ns leiningen.checkout.utils
(:require [clojure.pprint]
[fs.core :as fs])
(:import [java.io BufferedReader StringReader]))
(defn pprint-str [o]
(with-open [w (java.io.StringWriter.)]
(clojure.pprint/pprint o w)
(.toString w)))
(defn bash-comment [o]
{:pre [(= java.lang.String (type o))]}
... | |
b4e66a4fc54ec58c82bc706889d2c3652c0813389264cc3bcc771352b0cb512e | stumpwm/stumpwm | init.lisp | Exit with non - zero exit code on error at top level , during loading this rc file , and during command execution .
(setf *top-level-error-action* :abort)
;; Configuration
(setf *timeout-frame-indicator-wait* 60)
;; Invariant testing
(load "~/.stumpwm.d/invariants.lisp")
| null | https://raw.githubusercontent.com/stumpwm/stumpwm/4f71d30483a03b97faf684ba406d0fd0517d634d/tests/integration-tests/stumpwm.d/init.lisp | lisp | Configuration
Invariant testing | Exit with non - zero exit code on error at top level , during loading this rc file , and during command execution .
(setf *top-level-error-action* :abort)
(setf *timeout-frame-indicator-wait* 60)
(load "~/.stumpwm.d/invariants.lisp")
|
680ed5d539979c42595ccc39360af0b8e123c3a8177135485187f24f7674f7f9 | clojure-android/lein-droid | droid.clj | # # Clojure is simple . Android should also be .
This plugin is intended to make your Clojure / Android development as
;; seamless and efficient as when developing ordinar Clojure JVM programs.
;;
(ns leiningen.droid
(:refer-clojure :exclude [compile doall repl])
(:require clojure.pprint
[leiningen.... | null | https://raw.githubusercontent.com/clojure-android/lein-droid/1e0f8d5a5dd3c53232e21a1874867c212edb9848/src/leiningen/droid.clj | clojure | seamless and efficient as when developing ordinar Clojure JVM programs.
Test tasks
Help tasks | # # Clojure is simple . Android should also be .
This plugin is intended to make your Clojure / Android development as
(ns leiningen.droid
(:refer-clojure :exclude [compile doall repl])
(:require clojure.pprint
[leiningen.droid.aar :refer [extract-aar-dependencies]]
[leiningen.droid.code... |
f356e4dc98a7f21978995e1d4bbc9b8d73775bfbad77c3c03694a6c9f8a06e1e | qnikst/imagemagick | MagickWand.hs | module Graphics.ImageMagick.MagickWand
( module Graphics.ImageMagick.MagickCore
, module Graphics.ImageMagick.MagickWand.DrawingWand
, module Graphics.ImageMagick.MagickWand.MagickWand
, module Graphics.ImageMagick.MagickWand.PixelIterator
, module Graphics.ImageMagick.MagickWand.PixelPacket
, module Graphi... | null | https://raw.githubusercontent.com/qnikst/imagemagick/bc9e7ac85749f42a87901b722c5d36a8bed07d5c/src/Graphics/ImageMagick/MagickWand.hs | haskell | module Graphics.ImageMagick.MagickWand
( module Graphics.ImageMagick.MagickCore
, module Graphics.ImageMagick.MagickWand.DrawingWand
, module Graphics.ImageMagick.MagickWand.MagickWand
, module Graphics.ImageMagick.MagickWand.PixelIterator
, module Graphics.ImageMagick.MagickWand.PixelPacket
, module Graphi... | |
8df1b643cbeae2175767f93ca587f478077cd9b0babac9e7ec8c6438bb3281b6 | herd/herdtools7 | testVariant.mli | (****************************************************************************)
(* the diy toolsuite *)
(* *)
, University College London , UK .
, INRIA Par... | null | https://raw.githubusercontent.com/herd/herdtools7/df4bf581e7a1cc8d15f5ce6d39cfd701e8c7f40a/lib/testVariant.mli | ocaml | **************************************************************************
the diy toolsuite
en Automatique and ... | , University College London , UK .
, INRIA Paris - Rocquencourt , France .
Copyright 2020 - present Institut National de Recherche en Informatique et
This software is governed by the CeCILL - B license under French law and
modify and/ or redistribu... |
9e4c75259c54269d0fac4b8869eaf1d1dfcc1afc59a15305125eecfba2e0664c | brendanhay/terrafomo | Types.hs | -- This module was auto-generated. If it is modified, it will not be overwritten.
-- |
Module : .
Copyright : ( c ) 2017 - 2018
License : Mozilla Public License , v. 2.0 .
Maintainer : < brendan.g.hay+ >
-- Stability : auto-generated
Portability : non - portable ( GHC extensions )
--
... | null | https://raw.githubusercontent.com/brendanhay/terrafomo/387a0e9341fb9cd5543ef8332dea126f50f1070e/provider/terrafomo-opc/src/Terrafomo/OPC/Types.hs | haskell | This module was auto-generated. If it is modified, it will not be overwritten.
|
Stability : auto-generated
import Formatting (Format, (%)) |
Module : .
Copyright : ( c ) 2017 - 2018
License : Mozilla Public License , v. 2.0 .
Maintainer : < brendan.g.hay+ >
Portability : non - portable ( GHC extensions )
module Terrafomo.OPC.Types where
import Data . Text ( Text )
import Terrafomo
import Terrafomo . OPC.Lens
impo... |
d5bd0e4f69e9d55296a2f53d693610afd2bd8c1daedc69c74b2cc7bdf2c2511a | HunterYIboHu/htdp2-solution | 9.3-name-list.rkt | The first three lines of this file were inserted by . They record metadata
;; about the language level of this file in a form that our tools can easily process.
#reader(lib "htdp-beginner-abbr-reader.ss" "lang")((modname 9.3-name-list) (read-case-sensitive #t) (teachpacks ((lib "image.rkt" "teachpack" "2htdp") (lib ... | null | https://raw.githubusercontent.com/HunterYIboHu/htdp2-solution/6182b4c2ef650ac7059f3c143f639d09cd708516/Chapter2/Section9-Lists/9.3-name-list.rkt | racket | about the language level of this file in a form that our tools can easily process.
- '()
- (cons String List-of-names)
interpretation a List-of-names represents a list of invitees by last name.
List-of-names -> Boolean
determine whether "Flatt" occurs on a-list-of-names
examples: | The first three lines of this file were inserted by . They record metadata
#reader(lib "htdp-beginner-abbr-reader.ss" "lang")((modname 9.3-name-list) (read-case-sensitive #t) (teachpacks ((lib "image.rkt" "teachpack" "2htdp") (lib "universe.rkt" "teachpack" "2htdp"))) (htdp-settings #(#t constructor repeating-decima... |
70b819be67da5a2ecc1c62da4cbbcefff832ef3d7f3f5a05af09b64d33ed87bb | ua-parser/uap-clj | browser.clj | (ns uap-clj.java.api.browser
"Java API wrapper for useragent browser lookup"
(:require [uap-clj.browser :refer [browser]]
[clojure.walk :refer [stringify-keys]])
(:import [java.util HashMap])
(:gen-class
:name uap_clj.java.api.Browser
:methods [#^{:static true} [lookup [String] java.util.HashM... | null | https://raw.githubusercontent.com/ua-parser/uap-clj/62ce2aeca0c33444537a5d357a3a24ecce69d0ba/src/uap_clj/java/api/browser.clj | clojure | (ns uap-clj.java.api.browser
"Java API wrapper for useragent browser lookup"
(:require [uap-clj.browser :refer [browser]]
[clojure.walk :refer [stringify-keys]])
(:import [java.util HashMap])
(:gen-class
:name uap_clj.java.api.Browser
:methods [#^{:static true} [lookup [String] java.util.HashM... | |
283baee66055bdfcf66093e5e57fb1b8bcd5bb3e2c84cdb2a4b44d0d5b8e311e | zack-bitcoin/amoveo | oracle_winnings_tx.erl | -module(oracle_winnings_tx).
-export([go/4, make/4, make_dict/3, from/1, oracle_id/1]).
-include("../../records.hrl").
%If you bet in an oracle, and the oracle has closed, this is how you get your winnings out.
If you bet on the winning outcome , then you get positive winnings . If you bet on one of the losing outcome... | null | https://raw.githubusercontent.com/zack-bitcoin/amoveo/2d5755abd80f0852ab2faf3f1fda83c76de07f93/apps/amoveo_core/src/consensus/txs/oracle_winnings_tx.erl | erlang | If you bet in an oracle, and the oracle has closed, this is how you get your winnings out.
The difficulty of the winnings was announced when the oracle was launched.
true -> none
end, | -module(oracle_winnings_tx).
-export([go/4, make/4, make_dict/3, from/1, oracle_id/1]).
-include("../../records.hrl").
If you bet on the winning outcome , then you get positive winnings . If you bet on one of the losing outcomes , then you get negative winnings .
from(X) -> X#oracle_winnings.from.
oracle_id(X) -> X#or... |
a7c19514af04011950342d16b959ef25c48d06a4b8f2e9184cbdf53995ec7cae | nixeagle/nisp | ppjs.lisp | (defpackage #:ppjs
(:use :cl :alexandria :eos))
(in-package :ppjs)
(nisp.i::define-simple-command ppjs
(let* ((*read-eval* nil))
(nisp.i::reply (format nil "js: ~A"
(remove #\newline
(call-with-js-pprint-table
(la... | null | https://raw.githubusercontent.com/nixeagle/nisp/680b40b3b9ea4c33db0455ac73cbe3756afdbb1e/ppjs/ppjs.lisp | lisp | )
Ignore defun | (defpackage #:ppjs
(:use :cl :alexandria :eos))
(in-package :ppjs)
(nisp.i::define-simple-command ppjs
(let* ((*read-eval* nil))
(nisp.i::reply (format nil "js: ~A"
(remove #\newline
(call-with-js-pprint-table
(la... |
ea367e378bfd6597e51eeed8933b5febabf1f6e0ac8f5dbf06122e2de68dd88c | fortytools/holumbus | Persistent.hs | -- ----------------------------------------------------------------------------
|
Module : Holumbus . Index . Persistent
Copyright : Copyright ( C ) 2008
License : MIT
Maintainer : ( )
Stability : experimental
Portability : portable
Version : 0.1
A persis... | null | https://raw.githubusercontent.com/fortytools/holumbus/4b2f7b832feab2715a4d48be0b07dca018eaa8e8/searchengine/source/Holumbus/Index/Inverted/Persistent.hs | haskell | ----------------------------------------------------------------------------
----------------------------------------------------------------------------
# OPTIONS -XTypeSynonymInstances -XFlexibleInstances -XMultiParamTypeClasses #
* Persistent index types
| The index consists of a table which maps documents to id... |
|
Module : Holumbus . Index . Persistent
Copyright : Copyright ( C ) 2008
License : MIT
Maintainer : ( )
Stability : experimental
Portability : portable
Version : 0.1
A persistent version of the inverted index , which keeps the dictionary
in memory bu... |
7978c65cabb861492fe401c4f1242c1b4ca75ac4d7033d7fa16f21162e971240 | phantomics/seed | extension.lisp | ;;;; extension.lisp
(in-package #:seed.ui-model.react)
(export 'document-view-mode)
| null | https://raw.githubusercontent.com/phantomics/seed/f128969c671c078543574395d6b23a1a5f2723f8/seed.ui-spec.form.mode-document/extension.lisp | lisp | extension.lisp |
(in-package #:seed.ui-model.react)
(export 'document-view-mode)
|
5dedd186c1da75054b9f91b0d762e999e0ffcc822891f26865fd6846396921b0 | no-defun-allowed/concurrent-hash-tables | threadmill.lisp | (in-package :concurrent-hash-table)
(defun make-chash-table (&rest rest
&key test hash-function size
&allow-other-keys)
(declare (ignore test hash-function size))
(apply #'threadmill:make-hash-table rest))
(declaim (inline getchash (setf getchash) remchash))
(defu... | null | https://raw.githubusercontent.com/no-defun-allowed/concurrent-hash-tables/1b9f0b5da54fece4f42296e1bdacfcec0c370a5a/Code/threadmill.lisp | lisp | (in-package :concurrent-hash-table)
(defun make-chash-table (&rest rest
&key test hash-function size
&allow-other-keys)
(declare (ignore test hash-function size))
(apply #'threadmill:make-hash-table rest))
(declaim (inline getchash (setf getchash) remchash))
(defu... | |
77897906123764b819b31c7c4d4883cdf7292c3833cf4f5203940f1bca8d676d | haskellweekly/haskellweekly | Common.hs | module HW.Template.Common
( openGraph,
twitter,
)
where
import qualified Data.Text as Text
import qualified Lucid as Html
import qualified Lucid.Base as Html
openGraph :: Text.Text -> Text.Text -> Html.Html ()
openGraph property content =
Html.meta_
[Html.content_ content, Html.makeAttributes "property"... | null | https://raw.githubusercontent.com/haskellweekly/haskellweekly/c6e725c2d53fbb23b18321593f687a5731506064/source/library/HW/Template/Common.hs | haskell | module HW.Template.Common
( openGraph,
twitter,
)
where
import qualified Data.Text as Text
import qualified Lucid as Html
import qualified Lucid.Base as Html
openGraph :: Text.Text -> Text.Text -> Html.Html ()
openGraph property content =
Html.meta_
[Html.content_ content, Html.makeAttributes "property"... | |
cf06a035c4fc74cdbf7e60c6a92658ab074c0a729d577fe57cb99bd6032bd6bb | schleyfox/storm-test | drpc.clj | (ns storm.test.drpc
(:import [backtype.storm LocalDRPC])
(:import [backtype.storm.utils Time])
(:use [backtype.storm testing util]))
(defn- do-execute
[_ client func func-args]
(.execute client func func-args))
(defn execute-drpc!
"Executes a DRPC request in a possibly simulated time environment"
[clus... | null | https://raw.githubusercontent.com/schleyfox/storm-test/db55be66c059e5310a2a90ae1423f3a4667b238a/src/clj/storm/test/drpc.clj | clojure | (ns storm.test.drpc
(:import [backtype.storm LocalDRPC])
(:import [backtype.storm.utils Time])
(:use [backtype.storm testing util]))
(defn- do-execute
[_ client func func-args]
(.execute client func func-args))
(defn execute-drpc!
"Executes a DRPC request in a possibly simulated time environment"
[clus... | |
96be0ce246f8ef2302d666bcbefbdd3a837fc0e61bfe3e3ad1f71c4e9f13f8db | scicloj/tablecloth.time | rolling_window.clj | (ns tablecloth.time.api.rolling-window
(:import [java.util Map LinkedHashMap])
(:require [tablecloth.api :as tablecloth]
[tablecloth.time.api :refer [slice]]
[tablecloth.time.utils.indexing :refer [get-index-column-name-or-error]]))
;; A rolling-window for a row is defined by it's length, ... | null | https://raw.githubusercontent.com/scicloj/tablecloth.time/a5161c1b2bf67c04e3476f56551ca1998894825c/src/tablecloth/time/api/rolling_window.clj | clojure | A rolling-window for a row is defined by it's length, and maps to a set of rows preceding it
We use a grouped dataset, which is a dataset of datasets, to hold the rows of a rolling-window
notation
window-size is the number of rows in the dataset. same as row-count
index-name is column name in the dataset that is u... | (ns tablecloth.time.api.rolling-window
(:import [java.util Map LinkedHashMap])
(:require [tablecloth.api :as tablecloth]
[tablecloth.time.api :refer [slice]]
[tablecloth.time.utils.indexing :refer [get-index-column-name-or-error]]))
loc is row location in a column
(defn- rw-index
"... |
d8f5f028816f94c7910af535ddc433fe480a0aba5631086c8cc72ec7ac71b92c | opencog/learn | clique-pair-count.scm | ;
; clique-pair-count.scm
;
; Word-pair counting by counting all possible pairings (the "clique")
; inside a window. The window slides along (sliding window).
;
Copyright ( c ) 2013 , 2017 Linas Vepstas < >
;
Word - pairs show up , and can be counted in several different ways . One
method is a windowed clique ... | null | https://raw.githubusercontent.com/opencog/learn/f000b7a5e146a69fbc76e9e4311bf688a6ee2d87/scm/attic/pair-count/clique-pair-count.scm | scheme |
clique-pair-count.scm
Word-pair counting by counting all possible pairings (the "clique")
inside a window. The window slides along (sliding window).
fixed distance from each other (the window size), the corresponding
word-pair count is incremented. This is a clique-count, because every
counter can lead to ver... | Copyright ( c ) 2013 , 2017 Linas Vepstas < >
Word - pairs show up , and can be counted in several different ways . One
method is a windowed clique - counter . If two words appear within a
possible pairing is considered . This count is stored in the CountTV
for the EvaluationLink on ( PredicateNode " * -Se... |
07c584adf219ff5578b9bde2e1590d5e6403483279a2e6c98db25980c48e78b1 | oakes/Paravim | core_test.clj | (ns paravim.core-test
(:require [clojure.test :refer :all]
[paravim.start :as start]
[paravim.vim :as vim]
[paravim.session :as session]
[libvim-clj.core :as v]
[paravim.core :as c]
[play-cljc.gl.core :as pc]
[clojure.core.async :as a... | null | https://raw.githubusercontent.com/oakes/Paravim/871b9adf4e9819a7b9f2c63466c55640f0f8c280/test/paravim/core_test.clj | clojure | undo changes
dedent
undo
when search highlighting is enabled
without hlsearch set | (ns paravim.core-test
(:require [clojure.test :refer :all]
[paravim.start :as start]
[paravim.vim :as vim]
[paravim.session :as session]
[libvim-clj.core :as v]
[paravim.core :as c]
[play-cljc.gl.core :as pc]
[clojure.core.async :as a... |
a3a95c1a01d6202f0e735efa517571598d4d29e3f844febfbb7298577fb9a3ff | henrik42/spring-break | script-code.clj | ;; This file should be loaded as a *script file*.
;; It has no namespace declaration and it may
;; not be loaded via (require).
(.print System/out (format "+++ loading %s in namespace '%s'\n" *file* *ns*))
| null | https://raw.githubusercontent.com/henrik42/spring-break/0d4e51f6ec0ffab023c46709a43b9d877fac4536/src/main/clojure/no-namespace-scripts/script-code.clj | clojure | This file should be loaded as a *script file*.
It has no namespace declaration and it may
not be loaded via (require). | (.print System/out (format "+++ loading %s in namespace '%s'\n" *file* *ns*))
|
e5f599738083cf8e97ad9a5a230758a9783f9f8b8df3af00e9367bc94219099b | uim/uim | run-test.scm | #!/usr/bin/env gosh
Copyright ( c ) 2004 - 2013 uim Project
;;;
;;; All rights reserved.
;;;
;;; Redistribution and use in source and binary forms, with or without
;;; modification, are permitted provided that the following conditions
;;; are met:
1 . Redistributions of source code must retain the above copyright... | null | https://raw.githubusercontent.com/uim/uim/d1ac9d9315ff8c57c713b502544fef9b3a83b3e5/test/run-test.scm | scheme |
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer in the
document... | #!/usr/bin/env gosh
Copyright ( c ) 2004 - 2013 uim Project
1 . Redistributions of source code must retain the above copyright
2 . Redistributions in binary form must reproduce the above copyright
3 . Neither the name of authors nor the names of its contributors
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HO... |
4cff622b8dcef92a6efb6bc3c56638cbdf42ddc6c97f099ce072d88b91e5ddf3 | ghc/testsuite | TH_Roles3.hs | # LANGUAGE TemplateHaskell , PolyKinds , RoleAnnotations #
module Roles3 where
import Language.Haskell.TH
import System.IO
$( do { decls <- [d| data Foo a (b :: k) c (d :: k)
type role Foo _ _ representational nominal |]
; runIO $ putStrLn (pprint decls) >> hFlush stdout
; return dec... | null | https://raw.githubusercontent.com/ghc/testsuite/998a816ae89c4fd573f4abd7c6abb346cf7ee9af/tests/th/TH_Roles3.hs | haskell | # LANGUAGE TemplateHaskell , PolyKinds , RoleAnnotations #
module Roles3 where
import Language.Haskell.TH
import System.IO
$( do { decls <- [d| data Foo a (b :: k) c (d :: k)
type role Foo _ _ representational nominal |]
; runIO $ putStrLn (pprint decls) >> hFlush stdout
; return dec... | |
44852bdf68146e14669d08500aa050deed7951b8ba41bb9c08ef00cff4b86d0d | billstclair/trubanc-lisp | cffi-allegro.lisp | ;;;; -*- Mode: lisp; indent-tabs-mode: nil -*-
;;;
cffi-allegro.lisp --- CFFI - SYS implementation for Allegro CL .
;;;
Copyright ( C ) 2005 - 2009 , loliveira(@)common - lisp.net >
;;;
;;; Permission is hereby granted, free of charge, to any person
;;; obtaining a copy of this software and associated documenta... | null | https://raw.githubusercontent.com/billstclair/trubanc-lisp/5436d2eca5b1ed10bc47eec7080f6cb90f98ca65/systems/cffi_0.10.4/src/cffi-allegro.lisp | lisp | -*- Mode: lisp; indent-tabs-mode: nil -*-
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
restriction, including without limitation the rights to use, copy,
modify, merge, publish, distribute, sublicense, and/or sell copies
furnished to... | cffi-allegro.lisp --- CFFI - SYS implementation for Allegro CL .
Copyright ( C ) 2005 - 2009 , loliveira(@)common - lisp.net >
files ( the " Software " ) , to deal in the Software without
of the Software , and to permit persons to whom the Software is
included in all copies or substantial portions of the ... |
7d2cbc327641c1a36967e52f1ee04f4205294399c5d2b030674237707673806f | russ/openpoker | delayed_exit.erl | Copyright ( C ) 2005 - 2008 Wager Labs , SA
%%%%
%%%% THE WORK (AS DEFINED BELOW) IS PROVIDED UNDER THE TERMS OF THIS
CREATIVE COMMONS PUBLIC LICENSE ( " CCPL " OR " LICENSE " ) . THE WORK IS
%%%% PROTECTED BY COPYRIGHT AND/OR OTHER APPLICABLE LAW. ANY USE OF
%%%% THE WORK OTHER THAN AS AUTHORIZED UNDER THIS LICE... | null | https://raw.githubusercontent.com/russ/openpoker/62edd72a35b9ef52f55da9303cf1e06142e95895/src/delayed_exit.erl | erlang |
THE WORK (AS DEFINED BELOW) IS PROVIDED UNDER THE TERMS OF THIS
PROTECTED BY COPYRIGHT AND/OR OTHER APPLICABLE LAW. ANY USE OF
THE WORK OTHER THAN AS AUTHORIZED UNDER THIS LICENSE OR COPYRIGHT
LAW IS PROHIBITED.
BY EXERCISING ANY RIGHTS TO THE WORK PROVIDED HERE, YOU ACCEPT
AND AGREE TO BE BOUND BY THE TERM... | Copyright ( C ) 2005 - 2008 Wager Labs , SA
CREATIVE COMMONS PUBLIC LICENSE ( " CCPL " OR " LICENSE " ) . THE WORK IS
-nc-sa/3.0/us/
-module(delayed_exit).
-export([start/3, delayed_exit/3]).
-include("common.hrl").
-include("pp.hrl").
-define(DELAY, 5000).
start(Game, Ctx, []) ->
Game1 = g:restart_timer... |
c19297426e5f0e3d39762894a682413b492d567b31fb0f65a7052a0ab5631c66 | launchdarkly/erlang-server-sdk | ldclient_storage_redis_SUITE.erl | -module(ldclient_storage_redis_SUITE).
-include_lib("common_test/include/ct.hrl").
%% ct functions
-export([all/0]).
-export([init_per_suite/1]).
-export([end_per_suite/1]).
-export([init_per_testcase/2]).
-export([end_per_testcase/2]).
%% Tests
-export([
server_init/1,
server_bucket_exists/1,
server_get... | null | https://raw.githubusercontent.com/launchdarkly/erlang-server-sdk/d9a4442a8a214bf950dec8182b26cd042436f4c8/test-redis/ldclient_storage_redis_SUITE.erl | erlang | ct functions
Tests
====================================================================
ct functions
====================================================================
this sets the caching layer to testing mode
this sets the caching layer to testing mode
=========================================================... | -module(ldclient_storage_redis_SUITE).
-include_lib("common_test/include/ct.hrl").
-export([all/0]).
-export([init_per_suite/1]).
-export([end_per_suite/1]).
-export([init_per_testcase/2]).
-export([end_per_testcase/2]).
-export([
server_init/1,
server_bucket_exists/1,
server_get_upsert/1,
server_ups... |
010b606a8a3b5de6af5131424259bd0cccc1ea4069b193749540520f4c347d96 | zenhack/haskell-capnp | Transport.hs | # LANGUAGE DataKinds #
# LANGUAGE DuplicateRecordFields #
# LANGUAGE RecordWildCards #
# LANGUAGE TypeApplications #
-- |
-- Module: Capnp.Rpc.Transport
-- Description: Support for exchanging messages with remote vats.
--
-- This module provides a 'Transport' type, which provides operations
used to transmit messages... | null | https://raw.githubusercontent.com/zenhack/haskell-capnp/6cf9fae35189a3668f2740d64c634675ec5fbdec/lib/Capnp/Rpc/Transport.hs | haskell | |
Module: Capnp.Rpc.Transport
Description: Support for exchanging messages with remote vats.
This module provides a 'Transport' type, which provides operations
| A @'Transport'@ handles transmitting RPC messages.
| Send a message
| Receive a message
| @'handleTransport' handle limit@ is a transport which reads... | # LANGUAGE DataKinds #
# LANGUAGE DuplicateRecordFields #
# LANGUAGE RecordWildCards #
# LANGUAGE TypeApplications #
used to transmit messages between vats in the RPC protocol .
module Capnp.Rpc.Transport
( Transport (..),
handleTransport,
socketTransport,
tracingTransport,
TraceConfig (..),
)
wh... |
1e82474d060ad795bc7ffda3d0a37ea14ddf87bbc3a3ad760fa1b7c6353902eb | themetaschemer/malt | B-comparators.rkt | #lang racket
(require "../autodiff.rkt")
;;----------------------------
Boolean comparators
;;----------------------------
(define comparator
(λ (f)
(λ (da db)
(f (ρ da) (ρ db)))))
(define =-0-0
(comparator =))
(define <-0-0
(comparator <))
(define <=-0-0
(comparator <=))
(define >-0-0
(com... | null | https://raw.githubusercontent.com/themetaschemer/malt/78a04063a5a343f5cf4332e84da0e914cdb4d347/nested-tensors/ext-ops/B-comparators.rkt | racket | ----------------------------
----------------------------
----------------------------
Tensorized comparators
---------------------------- | #lang racket
(require "../autodiff.rkt")
Boolean comparators
(define comparator
(λ (f)
(λ (da db)
(f (ρ da) (ρ db)))))
(define =-0-0
(comparator =))
(define <-0-0
(comparator <))
(define <=-0-0
(comparator <=))
(define >-0-0
(comparator >))
(define >=-0-0
(comparator >))
(define compar... |
3aeb2ed581cbc56f0d04ab37dc737369c991853c5478b132da0f8d430bb1b94f | lindenbaum/hinterface | LocalNode.hs | # LANGUAGE DuplicateRecordFields #
# LANGUAGE FlexibleInstances #
# LANGUAGE MultiParamTypeClasses #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE TypeFamilies #
# LANGUAGE UndecidableInstances #
{-# OPTIONS_GHC -Wno-unrecognised-pragmas #-}
{-# HLINT ignore "Use camelCase" #-}
{-# HLINT ignore "Use <$>" #-}
module For... | null | https://raw.githubusercontent.com/lindenbaum/hinterface/e49810b5984486cebad6fa06dba0f2c7f2bfd2fa/src/Foreign/Erlang/LocalNode.hs | haskell | # OPTIONS_GHC -Wno-unrecognised-pragmas #
# HLINT ignore "Use camelCase" #
# HLINT ignore "Use <$>" #
, closeLocalNode | # LANGUAGE DuplicateRecordFields #
# LANGUAGE FlexibleInstances #
# LANGUAGE MultiParamTypeClasses #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE TypeFamilies #
# LANGUAGE UndecidableInstances #
module Foreign.Erlang.LocalNode
( LocalNode (),
NodeT (),
LocalNodeConfig (..),
askCreation,
askNodeName,
... |
6e14c7e3593ae4e7b207f8be16deede272da9b434d924bae106ea297ed0f8560 | sabracrolleton/uax-15 | uax-15.lisp | -*- Mode : LISP ; Syntax : Ansi - Common - Lisp ; Base : 10 ; Package : UAX-15 -*-
(in-package :uax-15)
(defun normalize (str normalization-form &key (rfc 3454))
"Base external function which calls the appropriate normalization for the normalization form. The default normaliation form is :nfkc, but :nfd, :nfkd an... | null | https://raw.githubusercontent.com/sabracrolleton/uax-15/d111dca4020604baf8f4d1fc2823726efd8ae95c/src/uax-15.lisp | lisp | Syntax : Ansi - Common - Lisp ; Base : 10 ; Package : UAX-15 -*-
hangul |
(in-package :uax-15)
(defun normalize (str normalization-form &key (rfc 3454))
"Base external function which calls the appropriate normalization for the normalization form. The default normaliation form is :nfkc, but :nfd, :nfkd and :nfc are also available."
(if (= rfc 3454)
(ecase normalization-form
... |
4e3fc0c46f6760855202f0de7ec8fcefdec76ca7502a6e0e0ebc90921735f399 | facebook/flow | codemodCommand.ml |
* Copyright ( c ) Meta Platforms , Inc. and affiliates .
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree .
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in t... | null | https://raw.githubusercontent.com/facebook/flow/3087a6613a614e5a08f1fe2a7cb2b65edd07fff8/src/commands/codemodCommand.ml | ocaml | Disable monitor updates as this is a single-use tool
Improve backtraces
Mark the environment as initialized
EX_USAGE
*********************
********************* |
* Copyright ( c ) Meta Platforms , Inc. and affiliates .
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree .
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in t... |
577f02cf7acf4943edd91256716d07e0ec7952227a968eb102b787350721b015 | janestreet/hardcaml | test_cyclesim_combine.ml | open! Import
open Signal
(* Xor gate *)
let xor_sim () =
let a, b = input "a" 1, input "b" 1 in
let c = output "c" (a ^: b) in
Circuit.create_exn ~name:"xor" [ c ] |> Cyclesim.create
;;
(* Or gate *)
let or_sim () =
let a, b = input "a" 1, input "b" 1 in
let c = output "c" (a |: b) in
Circuit.create_exn ~... | null | https://raw.githubusercontent.com/janestreet/hardcaml/4126f65f39048fef5853ba9b8d766143f678a9e4/test/lib/test_cyclesim_combine.ml | ocaml | Xor gate
Or gate
Rename [b] input as [foo]
Rename [c] output as [foo]
Add an extra [foo] input | open! Import
open Signal
let xor_sim () =
let a, b = input "a" 1, input "b" 1 in
let c = output "c" (a ^: b) in
Circuit.create_exn ~name:"xor" [ c ] |> Cyclesim.create
;;
let or_sim () =
let a, b = input "a" 1, input "b" 1 in
let c = output "c" (a |: b) in
Circuit.create_exn ~name:"or" [ c ] |> Cyclesim.c... |
f16a2dfbda91eb6f529fa889a030fffe32640951167dea6aef4d7d0530c0e725 | SquidDev/urn | argparse.lisp | "An argument parsing library.
You specify the arguments for this parser, and the arg parser will
handle parsing and documentation generation.
The parser is created with [[create]] and arguments can be added with
[[add-argument!]]. Should you want the parser to handle `--help` and
friends, you should call [[add-h... | null | https://raw.githubusercontent.com/SquidDev/urn/6e6717cf1376b0950e569e3771cb7e287aed291d/lib/io/argparse.lisp | lisp | Add them to the appropriate maps
Read the options
Set the metavar for variable argument things.
Set the action for variable argument things.
Try to consume as many additonal tokens as possible
Try to consume as many as possible
If we've already got a value and this doesn't accept many then fail.
Call the setter... | "An argument parsing library.
You specify the arguments for this parser, and the arg parser will
handle parsing and documentation generation.
The parser is created with [[create]] and arguments can be added with
[[add-argument!]]. Should you want the parser to handle `--help` and
friends, you should call [[add-h... |
4321cb6678b6a2ef53fca878c4464b08402d8be065ef3c7e1a5dc079078c7ad8 | mattwilliamson/erlfs | erlfs_store_sup.erl | %%%-------------------------------------------------------------------
@private
%%%
@author < mwilliamson@mwvmubhhlap >
%%%
@doc This is the top supervisor for the ErlFS storage
%%% application.
%%%
%%% @end
%%%-------------------------------------------------------------------
-module(erlfs_store_sup).
-defin... | null | https://raw.githubusercontent.com/mattwilliamson/erlfs/59738d3283cbfb97daeca9ed373a7cf65252ec9b/lib/erlfs_store/src/erlfs_store_sup.erl | erlang | -------------------------------------------------------------------
application.
@end
-------------------------------------------------------------------
API
Supervisor callbacks
====================================================================
API functions
==================================================... | @private
@author < mwilliamson@mwvmubhhlap >
@doc This is the top supervisor for the ErlFS storage
-module(erlfs_store_sup).
-define(SERVER, ?MODULE).
-behaviour(supervisor).
-export([start_link/1]).
-export([init/1]).
@spec start_link(StartArgs ) - > { ok , Pid } | ignore | { error , Error }
= [ ... |
716443ef94af50fafd0fceb7f8374052304c793af4c401f6a74fc21f828f874a | mtnygard/dawn | project.clj | (defproject com.cognitect/fern "0.1.6-SNAPSHOT"
:description "Plain but useful language for data"
:url "-labs/fern"
:license {:name "Eclipse Public License"
:url "-v10.html"}
:dependencies [[org.clojure/clojure "1.10.1" :scope "provided"]
[org.clojure/tools.read... | null | https://raw.githubusercontent.com/mtnygard/dawn/da033767b30c975b973991806eda8069a3b43ac8/framework/fern/project.clj | clojure | (defproject com.cognitect/fern "0.1.6-SNAPSHOT"
:description "Plain but useful language for data"
:url "-labs/fern"
:license {:name "Eclipse Public License"
:url "-v10.html"}
:dependencies [[org.clojure/clojure "1.10.1" :scope "provided"]
[org.clojure/tools.read... | |
83d8621399b3fbc37a51b9fb62e350ba90945e8f76479292257e1b7e61690b55 | mclumd/Meta-AQUA | learn-operators5.lisp | -*- Mode : LISP ; Syntax : Common - lisp ; Package : NONLINEAR ; Base : 10 -*-
(in-package :nonlin)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;
Nonlin Hierarchical Planning Subsystem
for Meta - AQUA
;;;;
Copyright ( C ) 1994 ( )
;;;;... | null | https://raw.githubusercontent.com/mclumd/Meta-AQUA/e4d4f83330fd07d1354aec245a49bde9e246c618/Nonlin/learn-operators5.lisp | lisp | Syntax : Common - lisp ; Package : NONLINEAR ; Base : 10 -*-
File: learn-operators5.lisp
*******************************************************
This program is free software; you can redistribute it and/or modify it
either version 1 , or ( at your option ) any later ... |
(in-package :nonlin)
Nonlin Hierarchical Planning Subsystem
for Meta - AQUA
Copyright ( C ) 1994 ( )
under the terms of the GNU General Public License as published by the Free
You should have received a copy of the GNU General Public License along
Mass Ave , ... |
280d6a07576e3efefff5915c558a399c75ac9feb90e2e26b8d4574068ad5fa08 | racket/plai | global-roots.rkt | #lang plai/gc2/mutator
(allocator-setup "../good-collectors/good-collector.rkt" 20)
(define car first)
'junk
'junk
'junk
(test/value=? (car (cons 'this-car 2)) 'this-car)
| null | https://raw.githubusercontent.com/racket/plai/164f3b763116fcfa7bd827be511650e71fa04319/plai-lib/tests/gc2/good-mutators/global-roots.rkt | racket | #lang plai/gc2/mutator
(allocator-setup "../good-collectors/good-collector.rkt" 20)
(define car first)
'junk
'junk
'junk
(test/value=? (car (cons 'this-car 2)) 'this-car)
| |
00307659294a21049755ffeeeed3dd7ab3d8829317ab3ec2dcf7ee2f163afc43 | VisionsGlobalEmpowerment/webchange | icon_add_item.cljs | (ns webchange.ui-framework.components.icon.icon-add-item)
(def data
[:svg {:width "20" :height "20" :viewBox "0 0 20 20"
:fill "none" :stroke "#D99BFF" :stroke-width "2" :stroke-linecap "round" :stroke-linejoin "round"
:class-name "stroke-colored" :xmlns ""}
[:path {:d "M17.5 10L5.625... | null | https://raw.githubusercontent.com/VisionsGlobalEmpowerment/webchange/f551c935c8dec0cceab69ff5752cf86145d7a3ba/src/cljs/webchange/ui_framework/components/icon/icon_add_item.cljs | clojure | (ns webchange.ui-framework.components.icon.icon-add-item)
(def data
[:svg {:width "20" :height "20" :viewBox "0 0 20 20"
:fill "none" :stroke "#D99BFF" :stroke-width "2" :stroke-linecap "round" :stroke-linejoin "round"
:class-name "stroke-colored" :xmlns ""}
[:path {:d "M17.5 10L5.625... | |
93dfece28c3cc385fd2f0bf05f1b42f08caf6d930506349aa504439fd915d79e | GaloisInc/tower | I2C.hs | # LANGUAGE DataKinds #
# LANGUAGE QuasiQuotes #
# LANGUAGE FlexibleInstances #
# OPTIONS_GHC -fno - warn - orphans #
module Ivory.Tower.HAL.Bus.I2C where
import Ivory.Language
import Ivory.Tower.HAL.Bus.I2C.DeviceAddr
[ivory|
struct i2c_transaction_request
{ tx_addr :: Stored I2CDeviceAddr
; tx_buf :: Array... | null | https://raw.githubusercontent.com/GaloisInc/tower/a43f5e36c6443472ea2dc15bbd49faf8643a6f87/tower-hal/src/Ivory/Tower/HAL/Bus/I2C.hs | haskell | # LANGUAGE DataKinds #
# LANGUAGE QuasiQuotes #
# LANGUAGE FlexibleInstances #
# OPTIONS_GHC -fno - warn - orphans #
module Ivory.Tower.HAL.Bus.I2C where
import Ivory.Language
import Ivory.Tower.HAL.Bus.I2C.DeviceAddr
[ivory|
struct i2c_transaction_request
{ tx_addr :: Stored I2CDeviceAddr
; tx_buf :: Array... | |
e9e294d44dcb66f470fdac280fbb4e40c835c25929e5afa765e80e931bc78df9 | dchelimsky/sicp-exercises | ex-2.2.scm | #lang scheme
(require rackunit)
(provide make-segment start-segment end-segment make-point x-point y-point)
; Consider the problem of representing line segments in a plane. Each segment is represented as a pair of points: a starting point and an ending point. Define a constructor make-segment and selectors start-segm... | null | https://raw.githubusercontent.com/dchelimsky/sicp-exercises/55c804e3775b87a490e05f8337fc59bc7ce07f28/chapter-2/ex-2.2.scm | scheme | Consider the problem of representing line segments in a plane. Each segment is represented as a pair of points: a starting point and an ending point. Define a constructor make-segment and selectors start-segment and end-segment that define the representation of segments in terms of points. Furthermore, a point can be ... | #lang scheme
(require rackunit)
(provide make-segment start-segment end-segment make-point x-point y-point)
(define (print-point p)
(newline)
(display "(")
(display (x-point p))
(display ",")
(display (y-point p))
(display ")"))
(define (make-segment start end)
(cons start end))
(define (start-segment... |
ed1bfa4df80010f492194dc85c39683d74e92b450760ceac08fb761790d1c8f4 | MassD/mongo | mongoHeader.ml | open MongoUtils;;
type t =
{
message_len: int32;
request_id: int32;
response_to: int32;
op: MongoOperation.t
};;
let create_header body_len request_id response_to op =
{
message_len = Int32.of_int(body_len+4*4);
request_id = request_id;
response_to = response_to;
op... | null | https://raw.githubusercontent.com/MassD/mongo/054779d843a227d486b55dff6ebc915b44906b0d/src/mongoHeader.ml | ocaml | open MongoUtils;;
type t =
{
message_len: int32;
request_id: int32;
response_to: int32;
op: MongoOperation.t
};;
let create_header body_len request_id response_to op =
{
message_len = Int32.of_int(body_len+4*4);
request_id = request_id;
response_to = response_to;
op... | |
0beff0711a99bf5b15d9a504634aefeb8cf5f71eb19248db16b5b0d935f5940f | clojars/clojars-web | email_test.clj | (ns clojars.unit.email-test
(:require
[bote.core :refer [create-smtp-server]]
[clojars.email :as email]
[clojure.test :refer [deftest is]])
(:import
org.apache.commons.mail.EmailException
(org.subethamail.smtp.auth
EasyAuthenticationHandlerFactory
LoginFailedException
UsernamePasswordVali... | null | https://raw.githubusercontent.com/clojars/clojars-web/22f831c9e8749ac7933af48655764ad5f5bdc3e8/test/clojars/unit/email_test.clj | clojure | and checking the message would be better
but it looks like the tls stuff is a mess
this sufficies to say it tried | (ns clojars.unit.email-test
(:require
[bote.core :refer [create-smtp-server]]
[clojars.email :as email]
[clojure.test :refer [deftest is]])
(:import
org.apache.commons.mail.EmailException
(org.subethamail.smtp.auth
EasyAuthenticationHandlerFactory
LoginFailedException
UsernamePasswordVali... |
717af54bdbf6acd26b33b7e50bf13a40d25ab21b6324f368faf0e349189cb1cc | moleike/line-bot-sdk | WebhookSpec.hs | # LANGUAGE DataKinds #
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE QuasiQuotes #-}
{-# LANGUAGE TypeOperators #-}
module Line.Bot.WebhookSpec (spec) where
import qualified Crypto.Hash.SHA256 as SHA256
import Data.Aeson (Value, encode)
import Data.Aeson.... | null | https://raw.githubusercontent.com/moleike/line-bot-sdk/c2e6d132d9a8c262e1d0667d63d3aa185ab33025/test/Line/Bot/WebhookSpec.hs | haskell | # LANGUAGE OverloadedStrings #
# LANGUAGE QuasiQuotes #
# LANGUAGE TypeOperators # | # LANGUAGE DataKinds #
module Line.Bot.WebhookSpec (spec) where
import qualified Crypto.Hash.SHA256 as SHA256
import Data.Aeson (Value, encode)
import Data.Aeson.QQ
import Data.Aeson.Types (emptyObject)
import qualified Data.ByteString.Base64 as... |
e5b69584ce8f0c7d9681627f6d5d40a8d3abfd37f3be40c48c459fee654ea359 | cxxxr/apispec | parameter.lisp | (uiop:define-package #:apispec/classes/parameter
(:use-reexport #:apispec/classes/parameter/class
#:apispec/classes/parameter/parse
#:apispec/classes/parameter/errors))
| null | https://raw.githubusercontent.com/cxxxr/apispec/4bdd238f6b5effed305d284e0e6b7cef214e94a2/src/classes/parameter.lisp | lisp | (uiop:define-package #:apispec/classes/parameter
(:use-reexport #:apispec/classes/parameter/class
#:apispec/classes/parameter/parse
#:apispec/classes/parameter/errors))
| |
693eff7fe55c8c6d2020d123b3e282b90e6f4a9a33ef0df0a56511700f262592 | bishboria/learnyouahaskell | 9_isPalindrome.hs | main = interact respondPalindromes
respondPalindromes :: String -> String
respondPalindromes =
unlines .
map (\xs -> if isPalindrome xs then "palindrome" else "not a palindrome") .
lines
isPalindrome :: String -> Bool
isPalindrome xs = xs == reverse xs
| null | https://raw.githubusercontent.com/bishboria/learnyouahaskell/d8c7b41398e9672db18c1b1360372fc4a4adefa8/09/9_isPalindrome.hs | haskell | main = interact respondPalindromes
respondPalindromes :: String -> String
respondPalindromes =
unlines .
map (\xs -> if isPalindrome xs then "palindrome" else "not a palindrome") .
lines
isPalindrome :: String -> Bool
isPalindrome xs = xs == reverse xs
| |
b1b84ad2486f29194e2a5c762475e1d08b9a27bb656be8c6930f037c3453fad3 | ragkousism/Guix-on-Hurd | refresh.scm | ;;; GNU Guix --- Functional package management for GNU
Copyright © 2013 , 2014 , 2015 , 2016 < >
Copyright © 2013 < >
Copyright © 2014 < >
Copyright © 2015 < >
Copyright © 2016 < >
;;;
;;; This file is part of GNU Guix.
;;;
GNU is free software ; you can redistribute it and/or modify it
un... | null | https://raw.githubusercontent.com/ragkousism/Guix-on-Hurd/e951bb2c0c4961dc6ac2bda8f331b9c4cee0da95/guix/scripts/refresh.scm | scheme | GNU Guix --- Functional package management for GNU
This file is part of GNU Guix.
you can redistribute it and/or modify it
either version 3 of the License , or ( at
your option) any later version.
GNU Guix is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied wa... | Copyright © 2013 , 2014 , 2015 , 2016 < >
Copyright © 2013 < >
Copyright © 2014 < >
Copyright © 2015 < >
Copyright © 2016 < >
under the terms of the GNU General Public License as published by
You should have received a copy of the GNU General Public License
along with GNU . If not , se... |
1482d0726ac5ec19cc734a514acc67bf4754b389abe8631ca604744f99cacd6a | GregoryTravis/rhythmr | Rand.hs | module Rand
( randParam
, randParam2
, randParam2same
, randListChoice
, randListParam
, randListParam2
, randBools
, randDoubles
, shuffleList ) where
import System.Random
import Util
randParam :: (Int, Int) -> (Int -> f) -> [f]
--randParam range f = zipWith ($) (repeat f) rands
randParam range f = map f rands
wh... | null | https://raw.githubusercontent.com/GregoryTravis/rhythmr/55fd5b5af6a52da16b7d730c27fb408aa3c61538/src/Rand.hs | haskell | randParam range f = zipWith ($) (repeat f) rands
randParam range f = zipWith ($) (repeat f) rands
randParam2 range f = zipWith ($) (zipWith ($) (repeat f) rands) rands'
Return a list of randomly-chosen elements from the given list. | module Rand
( randParam
, randParam2
, randParam2same
, randListChoice
, randListParam
, randListParam2
, randBools
, randDoubles
, shuffleList ) where
import System.Random
import Util
randParam :: (Int, Int) -> (Int -> f) -> [f]
randParam range f = map f rands
where rands = randomRs range (mkStdGen 37)
randParam... |
e2e5a15ef0a3dcdb2eba4296772621fbd52fc4cad87ceae8abf2d65cb569c3d3 | camllight/camllight | lexuniv.ml | let rec lire_entier accumulateur flux =
match flux with
| [< '(`0`..`9` as c) >] ->
lire_entier (10 * accumulateur + int_of_char c - 48) flux
| [< >] ->
accumulateur;;
let tampon = "----------------";;
let rec lire_mot position flux =
match flux with
| [< '(`A`..`Z` | `a`..`z` | `0`..`9` | `_` |... | null | https://raw.githubusercontent.com/camllight/camllight/0cc537de0846393322058dbb26449427bfc76786/sources/examples/pascal/lexuniv.ml | ocaml | let rec lire_entier accumulateur flux =
match flux with
| [< '(`0`..`9` as c) >] ->
lire_entier (10 * accumulateur + int_of_char c - 48) flux
| [< >] ->
accumulateur;;
let tampon = "----------------";;
let rec lire_mot position flux =
match flux with
| [< '(`A`..`Z` | `a`..`z` | `0`..`9` | `_` |... | |
08b453bbbc5e4eba09b85271b97e5691c9ecdb51c6a9cb32a4d1cfe757c768e3 | MedeaMelana/Magic | AvacynRestored.hs | {-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE GADTs #-}
module Magic.AvacynRestored where
import Magic
import Control.Applicative ((<$>))
import Control.Category ((.))
import Control.Monad (void)
import Data.Boolean ((||*), false)
import Data.Label.Monadic (asks, (=:))
import Data.Monoid ((<>))
import Prelude hidi... | null | https://raw.githubusercontent.com/MedeaMelana/Magic/7bd87e4e1d54a7c5e5f81661196cafb87682c62a/Magic-Cards/src/Magic/AvacynRestored.hs | haskell | # LANGUAGE OverloadedStrings #
# LANGUAGE GADTs # |
module Magic.AvacynRestored where
import Magic
import Control.Applicative ((<$>))
import Control.Category ((.))
import Control.Monad (void)
import Data.Boolean ((||*), false)
import Data.Label.Monadic (asks, (=:))
import Data.Monoid ((<>))
import Prelude hiding ((.))
misthollowGriffin :: Card
misthollowGriffin = ... |
a8ffd1b9b2fd0d7689c39572652b700c2f832884ca37206d658065d3dd99d146 | Sekomer/Victim | Main.hs | {-
Victim programming language interpreter entry point
-}
module Main (main) where
import Language.Parser ( parseCode )
import Language.Interpreter ( runInterpreter )
import System.Environment (getArgs)
main :: IO ()
main = do
args <- getArgs
case args of
[] -> showUsage
(fi... | null | https://raw.githubusercontent.com/Sekomer/Victim/9cba13921426a1cf50337d6195db0ad07a856af5/Main.hs | haskell |
Victim programming language interpreter entry point
print stmts |
module Main (main) where
import Language.Parser ( parseCode )
import Language.Interpreter ( runInterpreter )
import System.Environment (getArgs)
main :: IO ()
main = do
args <- getArgs
case args of
[] -> showUsage
(filename: _) -> do
code <- readFile filename
... |
c2c4b6610708ea50e002514d280c663042290a027650a489bfe856db64d24dd5 | jrm-code-project/LISP-Machine | qcdefs.lisp | -*- Mode : LISP ; Package : COMPILER ; Lowercase : T ; Base:8 ; : ZL -*-
Definitions and specials for the Lisp machine Lisp compiler
* * ( c ) Copyright 1980 Massachusetts Institute of Technology * *
;; "This is insane. What we clearly want to do is not completely
clear , and is rooted in NCOM... | null | https://raw.githubusercontent.com/jrm-code-project/LISP-Machine/0a448d27f40761fafabe5775ffc550637be537b2/lambda/sys/qcdefs.lisp | lisp | Package : COMPILER ; Lowercase : T ; Base:8 ; : ZL -*-
"This is insane. What we clearly want to do is not completely
or 'k
get generators off this.
to define things we decide not to compile.
note: P2SBIND-FOR-TOPLEVEL goes to P2SBIND for LAMBDA.
or nlisp-fasd-interface.
Holds the arglist for the function being... | Definitions and specials for the Lisp machine Lisp compiler
* * ( c ) Copyright 1980 Massachusetts Institute of Technology * *
clear , and is rooted in NCOMPLR . " -- BSG / Dissociated Press .
(defmacro compiler-fasd-switch (form)
`(let ((fctn (get *fasd-interface* ',(car form))))
(if (null... |
409cedb5a0339ae839106f1146f06c86bd7be35d3ec0424ba22fb9d244a4e592 | dmitryvk/sbcl-win32-threads | rename-package-carefully.lisp | This software is part of the SBCL system . See the README file for
;;;; more information.
;;;;
This software is derived from the CMU CL system , which was
written at Carnegie Mellon University and released into the
;;;; public domain. The software is in the public domain and is
;;;; provided with absolutely no wa... | null | https://raw.githubusercontent.com/dmitryvk/sbcl-win32-threads/5abfd64b00a0937ba2df2919f177697d1d91bde4/src/cold/rename-package-carefully.lisp | lisp | more information.
public domain. The software is in the public domain and is
provided with absolutely no warranty. See the COPYING and CREDITS
files for more information.
(ANSI on RENAME-PACKAGE: "The consequences are undefined if new-name or any
new-nickname conflicts with any existing package names.") | This software is part of the SBCL system . See the README file for
This software is derived from the CMU CL system , which was
written at Carnegie Mellon University and released into the
(in-package "SB-COLD")
RENAME - PACKAGE in two steps in order to avoid the possibility of undefined
behavior when one of ... |
8dce2282de8aebabc4842d38b0a0e44fd5c9117a7a1c248357ee0908a39665b4 | huangjs/cl | maxima-build.lisp | #+lispworks
(setq hcl:*packages-for-warn-on-redefinition*
(remove-if (lambda (package-name)
(member package-name
'("HARLEQUIN-COMMON-LISP"
;"CL-USER"
)
:test #'string-equal))
*pack... | null | https://raw.githubusercontent.com/huangjs/cl/96158b3f82f82a6b7d53ef04b3b29c5c8de2dbf7/lib/maxima/src/maxima-build.lisp | lisp | "CL-USER" | #+lispworks
(setq hcl:*packages-for-warn-on-redefinition*
(remove-if (lambda (package-name)
(member package-name
'("HARLEQUIN-COMMON-LISP"
)
:test #'string-equal))
*packages-for-warn-on-redefinition*))
#+lis... |
b07d0d69dfa84c6ae3c3020605a47eea9d8683b244a86d7c6e2f2ddbb25f7901 | ethercrow/lightstep-haskell | Collector_Fields.hs | {- This file was auto-generated from collector.proto by the proto-lens-protoc program. -}
# LANGUAGE ScopedTypeVariables , DataKinds , TypeFamilies , UndecidableInstances , GeneralizedNewtypeDeriving , MultiParamTypeClasses , FlexibleContexts , FlexibleInstances , PatternSynonyms , MagicHash , NoImplicitPrelude , DataK... | null | https://raw.githubusercontent.com/ethercrow/lightstep-haskell/f447fd37a6c53dcd38c32c53f71a71386f3e425a/gen/Proto/Collector_Fields.hs | haskell | This file was auto-generated from collector.proto by the proto-lens-protoc program.
# OPTIONS_GHC -Wno-unused-imports#
# OPTIONS_GHC -Wno-duplicate-exports# | # LANGUAGE ScopedTypeVariables , DataKinds , TypeFamilies , UndecidableInstances , GeneralizedNewtypeDeriving , MultiParamTypeClasses , FlexibleContexts , FlexibleInstances , PatternSynonyms , MagicHash , NoImplicitPrelude , DataKinds , BangPatterns , TypeApplications , OverloadedStrings , DerivingStrategies #
# OPTION... |
e40841b60d5f14f28c4a5ce3d04b6cacbefc705e6ad777210a49d8a742ba80b7 | herd/herdtools7 | parseTest.mli | (****************************************************************************)
(* the diy toolsuite *)
(* *)
, University College London , UK .
, INRIA Par... | null | https://raw.githubusercontent.com/herd/herdtools7/574c59e111deda09afbba1f2bdd94353f437faaf/herd/parseTest.mli | ocaml | **************************************************************************
the diy toolsuite
en Automatique and ... | , University College London , UK .
, INRIA Paris - Rocquencourt , France .
Copyright 2013 - present Institut National de Recherche en Informatique et
This software is governed by the CeCILL - B license under French law and
modify and/ or redistribu... |
26bef3677d3f895a4b019aaf2e2c5b392afb408c7c93f79500874df16d812b4e | 8c6794b6/guile-tjit | t-br-if-pair-01.scm | ;;; Simple loop with `br-if-pair'.
(define (loop lst acc)
(if (pair? lst)
(loop (cdr lst) (+ acc (car lst)))
acc))
(loop (iota #e1e3) 0)
| null | https://raw.githubusercontent.com/8c6794b6/guile-tjit/9566e480af2ff695e524984992626426f393414f/test-suite/tjit/t-br-if-pair-01.scm | scheme | Simple loop with `br-if-pair'. |
(define (loop lst acc)
(if (pair? lst)
(loop (cdr lst) (+ acc (car lst)))
acc))
(loop (iota #e1e3) 0)
|
ce41f211d0814e9408b7cc96c16afd1583946c4c881698359b6e259610fd19a8 | logicmoo/wam_common_lisp | helpfile.lsp | ;;;; -*- Mode: Lisp; Syntax: Common-Lisp; indent-tabs-mode: nil; Package: SYSTEM -*-
;;;; vim: set filetype=lisp tabstop=8 shiftwidth=2 expandtab:
;;;;
Copyright ( c ) 2001 , .
;;;;
;;;; This program is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General P... | null | https://raw.githubusercontent.com/logicmoo/wam_common_lisp/4396d9e26b050f68182d65c9a2d5a939557616dd/prolog/wam_cl/src/lsp/helpfile.lsp | lisp | -*- Mode: Lisp; Syntax: Common-Lisp; indent-tabs-mode: nil; Package: SYSTEM -*-
vim: set filetype=lisp tabstop=8 shiftwidth=2 expandtab:
This program is free software; you can redistribute it and/or
either
See file '../Copyright' for full details.
---------------------------------------------------------... |
Copyright ( c ) 2001 , .
modify it under the terms of the GNU Library General Public
version 2 of the License , or ( at your option ) any later version .
(in-package "SYSTEM")
#+ecl-min
(progn
(*make-special '*documentation-pool*)
(setq *documentation-pool* nil)
(*make-special '*keep-documen... |
04fe25c3182b690503a1cd9ae8dc33354c55ef89f5838191a4c232edebe71c01 | crategus/cl-cffi-gtk | gtk.search-bar.lisp | ;;; ----------------------------------------------------------------------------
;;; gtk.search-bar.lisp
;;;
The documentation of this file is taken from the GTK+ 3 Reference Manual
Version 3.24 and modified to document the Lisp binding to the GTK+ library .
;;; See <>. The API documentation of the Lisp binding is
... | null | https://raw.githubusercontent.com/crategus/cl-cffi-gtk/08fe484105eec87fe50805282c61578bbd1143e4/gtk/gtk.search-bar.lisp | lisp | ----------------------------------------------------------------------------
gtk.search-bar.lisp
See <>. The API documentation of the Lisp binding is
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License for Lisp
License, or (at your op... | The documentation of this file is taken from the GTK+ 3 Reference Manual
Version 3.24 and modified to document the Lisp binding to the GTK+ library .
available from < -cffi-gtk/ > .
Copyright ( C ) 2019 - 2020
as published by the Free Software Foundation , either version 3 of the
the GNU Lesser General Pu... |
67a900016775e1445d27e26c3ffc85af234969a621a935f34a4f201b86654035 | vseloved/cl-nlp | greedy-ap.lisp | ( c ) 2014 Vsevolod Dyomkin
(in-package #:nlp.parsing)
(named-readtables:in-readtable rutils-readtable)
(defclass greedy-ap-depparser (avg-perceptron depparser)
()
(:documentation
"A greedy averaged perceptron dependency parser."))
(defmethod parse ((parser greedy-ap-depparser) (sent sent))
)
(defmethod... | null | https://raw.githubusercontent.com/vseloved/cl-nlp/f180b6c3c0b9a3614ae43f53a11bc500767307d0/src/parsing/greedy-ap.lisp | lisp | ( c ) 2014 Vsevolod Dyomkin
(in-package #:nlp.parsing)
(named-readtables:in-readtable rutils-readtable)
(defclass greedy-ap-depparser (avg-perceptron depparser)
()
(:documentation
"A greedy averaged perceptron dependency parser."))
(defmethod parse ((parser greedy-ap-depparser) (sent sent))
)
(defmethod... | |
abe6ad614a560fad5c49e512cb8d0ce2268035bbbc050c2ab0e3c42ebcb440c9 | ekmett/lens | Turtle.hs | # LANGUAGE TemplateHaskell #
{-# LANGUAGE DeriveDataTypeable #-}
| A simple Turtle - graphics demonstration for modeling the location of a turtle .
--
This is based on the code presented by at the Boston Area Scala
-- Enthusiasts meeting during his lens talk.
--
-- Usage:
--
> def & forward 10 & down & color .~... | null | https://raw.githubusercontent.com/ekmett/lens/a26281a49e85af46821964d8f7455b82cfd4251d/examples/Turtle.hs | haskell | # LANGUAGE DeriveDataTypeable #
Enthusiasts meeting during his lens talk.
Usage:
| # LANGUAGE TemplateHaskell #
| A simple Turtle - graphics demonstration for modeling the location of a turtle .
This is based on the code presented by at the Boston Area Scala
> def & forward 10 & down & color .~ red % turn ( pi/2 ) & forward 5
module Turtle where
import Control.Lens
import Data.Default.Class
... |
163d230d39865858698f39e0092ec4ff97addb85ea854aabf1c5303b36d83a07 | MondayMorningHaskell/haskellings | Types3.hs | module Types3 where
-- I AM NOT DONE
- We can combine values of different types together using * tuples * .
- A tuple consists of 2 or more comma - separated values within parentheses .
- The type signature similarly has each individual type within parens .
- We can combine values of different types togethe... | null | https://raw.githubusercontent.com/MondayMorningHaskell/haskellings/fafadd5bbb722b54c1b7b114e34dc9b96bb7ca4d/exercises/basics/Types3.hs | haskell | I AM NOT DONE
TODO: Fill in the missing type signatures or expression values | module Types3 where
- We can combine values of different types together using * tuples * .
- A tuple consists of 2 or more comma - separated values within parentheses .
- The type signature similarly has each individual type within parens .
- We can combine values of different types together using *tuples*.... |
61dc066d79be8475f3eb8d4cfc22523404c92ba89add4d9bd24c7e634d00a367 | clojure/core.typed | fixed_varargs.clj | (ns clojure.core.typed.annotator.test.runtime-infer.fixed-varargs
{:lang :core.typed
:core.typed {:features #{:runtime-infer}}
}
(:require [clojure.core.typed :as t]
[clojure.spec.alpha :as s]
[clojure.pprint :refer [pprint]]))
;; Start: Generated by clojure.core.typed - DO NOT EDIT
(... | null | https://raw.githubusercontent.com/clojure/core.typed/f5b7d00bbb29d09000d7fef7cca5b40416c9fa91/typed/annotator.jvm/test/clojure/core/typed/annotator/test/runtime_infer/fixed_varargs.clj | clojure | Start: Generated by clojure.core.typed - DO NOT EDIT
End: Generated by clojure.core.typed - DO NOT EDIT | (ns clojure.core.typed.annotator.test.runtime-infer.fixed-varargs
{:lang :core.typed
:core.typed {:features #{:runtime-infer}}
}
(:require [clojure.core.typed :as t]
[clojure.spec.alpha :as s]
[clojure.pprint :refer [pprint]]))
(s/fdef collapse-me :args (s/cat :args (s/* int?)) :ret n... |
9cda205a1e015bfd448f739ada54e5cbedb56891c128d46ab72ed55261b19b8b | ruHaskell/ruhaskell | RSSFeed.hs | {-# LANGUAGE OverloadedStrings #-}
module RSSFeed (
setupRSSFeed
) where
import Control.Monad.Reader
import Hakyll
import Context (postContext)
import Misc (TagsReader, aHost)
Формируем стандартную RSS - ленту , на основе последних 10 публикаций .
setupRSSFeed :: TagsR... | null | https://raw.githubusercontent.com/ruHaskell/ruhaskell/1e38eae50011307d11a2026af925a23a6fd8a346/src/RSSFeed.hs | haskell | # LANGUAGE OverloadedStrings # |
module RSSFeed (
setupRSSFeed
) where
import Control.Monad.Reader
import Hakyll
import Context (postContext)
import Misc (TagsReader, aHost)
Формируем стандартную RSS - ленту , на основе последних 10 публикаций .
setupRSSFeed :: TagsReader
setupRSSFeed = do
tagsAnd... |
a8135da367065ea993027d1cc8a2ce632384b33fc384aad34d7300a6b88d739e | matthewdowney/excel-clj | core.clj | (ns excel-clj.core
"Utilities for declarative creation of Excel (.xlsx) spreadsheets,
with higher level abstractions over Apache POI (/).
The highest level data abstraction used to create excel spreadsheets is a
tree, followed by a table, and finally the most basic abstraction is a grid.
The tree and table ... | null | https://raw.githubusercontent.com/matthewdowney/excel-clj/89732329e4adc0ca7b926a41fbbad42d6c3f4b02/src/excel_clj/core.clj | clojure | Write a table
Write a table that highlights rows where N has a whole square root
Write a table with a merged top row
Insert total rows below nodes with children
header
children
total row
leaf
so we should invert the sign on the liabilities to get a
meaningful sum
Helpers to manipulate [[cell]] data structure... | (ns excel-clj.core
"Utilities for declarative creation of Excel (.xlsx) spreadsheets,
with higher level abstractions over Apache POI (/).
The highest level data abstraction used to create excel spreadsheets is a
tree, followed by a table, and finally the most basic abstraction is a grid.
The tree and table ... |
62304563075967f7c0cd9255b5dfd5ff2107bcbd41c831d2b7dc6fff36990c3f | tsloughter/rebar3_tests | yaws_test_sup.erl | %%%-------------------------------------------------------------------
%% @doc yaws_test top level supervisor.
%% @end
%%%-------------------------------------------------------------------
-module(yaws_test_sup).
-behaviour(supervisor).
-export([start_link/0]).
-export([init/1]).
-define(SERVER, ?MODULE).
start_... | null | https://raw.githubusercontent.com/tsloughter/rebar3_tests/090bfef7d3a4790bb6b16e4c38df6e4c0460b4b2/yaws_test/src/yaws_test_sup.erl | erlang | -------------------------------------------------------------------
@doc yaws_test top level supervisor.
@end
-------------------------------------------------------------------
sup_flags() = #{strategy => strategy(), % optional
intensity => non_neg_integer(), % optional
optional
child_spe... |
-module(yaws_test_sup).
-behaviour(supervisor).
-export([start_link/0]).
-export([init/1]).
-define(SERVER, ?MODULE).
start_link() ->
supervisor:start_link({local, ?SERVER}, ?MODULE, []).
init([]) ->
SupFlags = #{strategy => one_for_all,
intensity => 0,
period => 1},
... |
f77644aba0a0694d862d45cb5f528cd7961553c56b7953e12c12ddac836d5c4d | buntine/Haskell--Craft-of-FP | Chapter8.hs | ---------------------------------------------------------------------
Haskell : The Craft of Functional Programming
( c ) Addison - Wesley , 1999 .
--
Chapter 8
---------------------------------------------------------------------
-- Reasoning about programs
^^^^^^^^^^^^^^^^^^^^^^^^
module Chapter8 w... | null | https://raw.githubusercontent.com/buntine/Haskell--Craft-of-FP/a1a8cd70eb9d1609fd384e608b7fe26b2a878803/Chapter8.hs | haskell | -------------------------------------------------------------------
-------------------------------------------------------------------
Reasoning about programs
Testing and verification
^^^^^^^^^^^^^^^^^^^^^^^^^^^
A factorial function, giving an undefined result on negative integers.
An infinite list
^^^^^^^^^
... | Haskell : The Craft of Functional Programming
( c ) Addison - Wesley , 1999 .
Chapter 8
^^^^^^^^^^^^^^^^^^^^^^^^
module Chapter8 where
import Prelude hiding (sum,length,(++),reverse,unzip)
^^^^^^^^^^^^^^^^^^^^^^^^
A function supposed to give the maximum of three ( integer ) values .
mysteryMax... |
0426c90df5bb50b5a43e583335d81bdd52ee1a4bd7826e93a8ed8ee588fdf07b | amnh/phylocaml | costMatrix.ml | open Internal
module type TCM =
sig
type spec
type cost
type elt
val get_alphabet : spec -> Alphabet.t
val zero : spec -> cost
val inf : spec -> cost
val lt : spec -> cost -> cost -> bool
val eq : spec -> cost -> cost -> bool
val add : spec -> cost -> cost -> cost
val cost :... | null | https://raw.githubusercontent.com/amnh/phylocaml/86aebc4f2664752668b16707214b3cad099434c0/lib/costMatrix.ml | ocaml | exhaustively look through each median assignment and collect optimal states
use state intersections/unions to determine optimal median
median must be subset of the union of parent states
fill a cost matrix
* extend to match [Alignment.AssignCostMatrix]
* extend to match [Alignment.AssignCostMatrix] | open Internal
module type TCM =
sig
type spec
type cost
type elt
val get_alphabet : spec -> Alphabet.t
val zero : spec -> cost
val inf : spec -> cost
val lt : spec -> cost -> cost -> bool
val eq : spec -> cost -> cost -> bool
val add : spec -> cost -> cost -> cost
val cost :... |
3524522de7c2423b9a8829eb9359f554c9adf12f0d9599ae347cc53bad1fecd9 | erlangonrails/devdb | syslog_appender.erl | -module(syslog_appender).
-include("../include/log4erl.hrl").
-behaviour(gen_event).
%% gen_event callbacks
-export([init/1, handle_event/2, handle_call/2,
handle_info/2, terminate/2, code_change/3]).
-define(DEFAULT_HOST, "localhost").
-define(DEFAULT_PORT, 514).
init({conf, Conf}) ->
Level = p... | null | https://raw.githubusercontent.com/erlangonrails/devdb/0e7eaa6bd810ec3892bfc3d933439560620d0941/dev/scalaris/contrib/log4erl/src/syslog_appender.erl | erlang | gen_event callbacks
{Level, Facility, Host, Port, Format}
The following code has been shamefully copied from
from the user contribution section in erlang.org
Convenient routine for specifying levels.
system is unusable
shortcut for emergency
action must be taken immediately
critical conditions
... | -module(syslog_appender).
-include("../include/log4erl.hrl").
-behaviour(gen_event).
-export([init/1, handle_event/2, handle_call/2,
handle_info/2, terminate/2, code_change/3]).
-define(DEFAULT_HOST, "localhost").
-define(DEFAULT_PORT, 514).
init({conf, Conf}) ->
Level = proplists:get_value(level... |
cfb922c0070a0cde5e66107c140fad86f8dd924608557004f501eb7f7aefb895 | mfikes/fifth-postulate | ns92.cljs | (ns fifth-postulate.ns92)
(defn solve-for01 [xs v]
(for [ndx0 (range 0 (- (count xs) 3))
ndx1 (range (inc ndx0) (- (count xs) 2))
ndx2 (range (inc ndx1) (- (count xs) 1))
ndx3 (range (inc ndx2) (count xs))
:when (= v (+ (xs ndx0) (xs ndx1) (xs ndx2) (xs ndx3)))]
(list (xs... | null | https://raw.githubusercontent.com/mfikes/fifth-postulate/22cfd5f8c2b4a2dead1c15a96295bfeb4dba235e/src/fifth_postulate/ns92.cljs | clojure | (ns fifth-postulate.ns92)
(defn solve-for01 [xs v]
(for [ndx0 (range 0 (- (count xs) 3))
ndx1 (range (inc ndx0) (- (count xs) 2))
ndx2 (range (inc ndx1) (- (count xs) 1))
ndx3 (range (inc ndx2) (count xs))
:when (= v (+ (xs ndx0) (xs ndx1) (xs ndx2) (xs ndx3)))]
(list (xs... | |
f72817fb3626eb75b15eeeb0a74934ef9a6cd12ec48c54a1529140753a2756ac | sdiehl/pairing | BN254C.hs | module Test.BN254C where
import Protolude
import Data.Curve.Weierstrass as C
import Data.Field.Galois as F
import Data.Pairing.BN254C
import Test.Tasty
import Test.Tasty.HUnit
import Test.Curve
import Test.Field
import Test.Pairing
testBN254C :: TestTree
testBN254C = testGroup "BN254C"
[ testField "Fq" (witness :... | null | https://raw.githubusercontent.com/sdiehl/pairing/9e3fd026fb43fd64917a3b267d0d8d351eba77cc/test/Test/BN254C.hs | haskell | module Test.BN254C where
import Protolude
import Data.Curve.Weierstrass as C
import Data.Field.Galois as F
import Data.Pairing.BN254C
import Test.Tasty
import Test.Tasty.HUnit
import Test.Curve
import Test.Field
import Test.Pairing
testBN254C :: TestTree
testBN254C = testGroup "BN254C"
[ testField "Fq" (witness :... | |
333bcee5047e9e69d367cfe364376ae4ce99035d156cae5bc8cd59f987e37946 | sgbj/MaximaSharp | dgtsl.lisp | ;;; Compiled by f2cl version:
( " f2cl1.l , v 46c1f6a93b0d 2012/05/03 04:40:28 toy $ "
" f2cl2.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ "
" f2cl3.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ "
" f2cl4.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ "
;;; "f2cl5.l,v 46c1f6a93b0d 2012/05/03 04:40:28 toy $... | null | https://raw.githubusercontent.com/sgbj/MaximaSharp/75067d7e045b9ed50883b5eb09803b4c8f391059/Test/bin/Debug/Maxima-5.30.0/share/maxima/5.30.0/src/numerical/slatec/dgtsl.lisp | lisp | Compiled by f2cl version:
"f2cl5.l,v 46c1f6a93b0d 2012/05/03 04:40:28 toy $"
Options: ((:prune-labels nil) (:auto-save t) (:relaxed-array-decls t)
(:coerce-assigns :as-needed) (:array-type ':array)
(:array-slicing t) (:declare-common nil)
(:float-format double-float)) | ( " f2cl1.l , v 46c1f6a93b0d 2012/05/03 04:40:28 toy $ "
" f2cl2.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ "
" f2cl3.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ "
" f2cl4.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ "
" f2cl6.l , v 1d5cbacbb977 2008/08/24 00:56:27 rtoy $ "
" macros.l , v fceac53... |
85088ddd82855d847b9fea766e05975de225c5c83733a9bffce933f7062bcc5f | rjnw/sham | transformer.rkt | #lang racket
(require syntax/parse
racket/syntax
racket/exn
(for-template racket racket/match))
(require (prefix-in rt: (submod "runtime.rkt" ast))
(submod "spec.rkt" ast)
"pat.rkt"
"kw-info.rkt"
"utils.rkt"
(for-template (prefix-in rrt: "../runt... | null | https://raw.githubusercontent.com/rjnw/sham/6e0524b1eb01bcda83ae7a5be6339da4257c6781/sham-sam/sham/sam/syntax/transformer.rkt | racket | [(empty? (syntax-e stx)) stx] | #lang racket
(require syntax/parse
racket/syntax
racket/exn
(for-template racket racket/match))
(require (prefix-in rt: (submod "runtime.rkt" ast))
(submod "spec.rkt" ast)
"pat.rkt"
"kw-info.rkt"
"utils.rkt"
(for-template (prefix-in rrt: "../runt... |
ee5289ad5657a4d8197a311c094f79e5732a20de684e5d44bfd97835901360f6 | montyly/gueb | reil.ml | open Program_piqi
open Function_
open Node
open Absenvgenerique
module REIL = functor (Absenv_v : AbsEnvGenerique ) ->
struct
(*
* REIL
**)
type type_of_node_reil=
| Sub
| And
| Xor
| Str
| Bsh
| Jcc
| Stm
| Ldm
| Add
| Nop
| Mul
| Mod
| Div
| Or
| Bi... | null | https://raw.githubusercontent.com/montyly/gueb/45f496a5a1e8e908e562928762ece304c2408c3a/src/reil.ml | ocaml |
* REIL
*
Unused for now
type size_arg_reil=
|OPERAND_SIZE_ADDRESS
|OPERAND_SIZE_BYTE
|OPERAND_SIZE_WORD
|OPERAND_SIZE_DWORD
|OPERAND_SIZE_EMPTY
|OPERAND_SIZE_QWORD
|OPERAND_SIZE_OWORD;;
jmp create by reil
* REIL parsing
*
* REIL pretty printing functions
*
*
jmp create by reil
TODO : handle ... | open Program_piqi
open Function_
open Node
open Absenvgenerique
module REIL = functor (Absenv_v : AbsEnvGenerique ) ->
struct
type type_of_node_reil=
| Sub
| And
| Xor
| Str
| Bsh
| Jcc
| Stm
| Ldm
| Add
| Nop
| Mul
| Mod
| Div
| Or
| Bisz
| Undef
... |
a0cbc33b09a090484fed66bc054c53db9d19160f1098eaed3816100d3646e679 | MBcode/LispUtils | knn.lisp | ;;;; A simple version of a k nearest neighbor algorithm. Handles linear
features ( by normalizing values to [ 0,1 ] ) and missing features ( dist is 0.5 )
Copyright ( c ) 1991 by . This program may be freely
;;;; copied, used, or modified provided that this copyright notice is included
;;;; in each copy of thi... | null | https://raw.githubusercontent.com/MBcode/LispUtils/8c9d09aa732fca1c7c5b42b6c5067b89de98cb49/stat/ml-progs/ml/knn.lisp | lisp | A simple version of a k nearest neighbor algorithm. Handles linear
copied, used, or modified provided that this copyright notice is included
in each copy of this code and parts thereof.
==========================================================================================
Variant systems
====================... | features ( by normalizing values to [ 0,1 ] ) and missing features ( dist is 0.5 )
Copyright ( c ) 1991 by . This program may be freely
(in-package :user)
(provide 'knn)
(require 'data-utilities (ml-progs-file "data-utilities"))
(setf (get 'knn 'parameters) '(*neighbors*))
(setf (get 'knn 'expect-training-err... |
af3b91c6783dc0a805c0fde4b5b08fe54be56aec11a2e404b0fa74cd7c6854dc | lambdaisland/metabase-datomic | test.clj | (ns metabase.driver.datomic.test
(:require [metabase.driver :as driver]
[metabase.query-processor :as qp]))
(require 'metabase.driver.datomic)
(require 'metabase.driver.datomic.test-data)
(require 'matcher-combinators.test)
(defmacro with-datomic [& body]
`(driver/with-driver :datomic
~@body))
(... | null | https://raw.githubusercontent.com/lambdaisland/metabase-datomic/7506e67bb5fe2ba0a2ff744ec17ccdeb573e869e/test/metabase/driver/datomic/test.clj | clojure | (ns metabase.driver.datomic.test
(:require [metabase.driver :as driver]
[metabase.query-processor :as qp]))
(require 'metabase.driver.datomic)
(require 'metabase.driver.datomic.test-data)
(require 'matcher-combinators.test)
(defmacro with-datomic [& body]
`(driver/with-driver :datomic
~@body))
(... | |
f210923432626ec81fd364678dee356a570962ea75033078c0ce9dbf9fc48f8a | haskell-works/avro | DeconflictSpec.hs | # LANGUAGE DataKinds #
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE TypeApplications #
module Avro.Encoding.DeconflictSpec
where
import qualified Avro.Data.Deconflict.Read as Read
import qualified Avro.Data.Deconflict.Write as Write
import Control.Lens
import Data.Avro ... | null | https://raw.githubusercontent.com/haskell-works/avro/9eb4970fd72939a68aa6f947d3d2dc17280352f8/test/Avro/Encoding/DeconflictSpec.hs | haskell | # LANGUAGE OverloadedStrings #
Default values are only considered if the writer doesn't have that field | # LANGUAGE DataKinds #
# LANGUAGE TypeApplications #
module Avro.Encoding.DeconflictSpec
where
import qualified Avro.Data.Deconflict.Read as Read
import qualified Avro.Data.Deconflict.Write as Write
import Control.Lens
import Data.Avro (decodeValueWithSchema, encodeV... |
4f683334b502dd0ec6cdaeb98a0496a8f8fda4d32e22a63e58c16a023d8dd6d0 | bhaskara/programmable-reinforcement-learning | td-taxi-examples.lisp | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; envs/taxi/td-taxi-examples.lisp - some functions to create some specific
;; examples of <td-taxi-env>s
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(in-package td-taxi-env)
(defun make-exampl... | null | https://raw.githubusercontent.com/bhaskara/programmable-reinforcement-learning/8afc98116a8f78163b3f86076498d84b3f596217/lisp/envs/taxi/td-taxi-examples.lisp | lisp |
envs/taxi/td-taxi-examples.lisp - some functions to create some specific
examples of <td-taxi-env>s
|
(in-package td-taxi-env)
(defun make-example-env1 ()
"Create an example td-taxi-env with a 2x3 world with a wall at (0,1), in which the source is always (1,0) and the destination is either (0,2) or (1,1). Moves are deterministic and costs are default (see <td-taxi-env>)"
(let ((pass-source '((1 0)))
(pass... |
690f55f141b9b214cc2d1f224a210e319c1dcb663039b0312ca1570e16962c09 | DavidAlphaFox/RabbitMQ | rabbit_test_runner.erl | The contents of this file are subject to the Mozilla Public License
Version 1.1 ( the " License " ) ; you may not use this file except in
%% compliance with the License. You may obtain a copy of the License at
%% /
%%
Software distributed under the License is distributed on an " AS IS "
%% basis, WITH... | null | https://raw.githubusercontent.com/DavidAlphaFox/RabbitMQ/0a64e6f0464a9a4ce85c6baa52fb1c584689f49a/plugins-src/rabbitmq-test/src/rabbit_test_runner.erl | erlang | compliance with the License. You may obtain a copy of the License at
/
basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
License for the specific language governing rights and limitations
under the License.
Used by HTTP tests
[0]
Partition tests change this, let's revert
try
... | The contents of this file are subject to the Mozilla 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 Original Code is RabbitMQ
The Initial Developer of the Original Code is GoPivotal , Inc.... |
e86ce5632f581a52a8b414b2734ccb4f086ed7f502796b164aaf1faf3feabd52 | kupl/LearnML | original.ml | type formula =
| True
| False
| Not of formula
| AndAlso of (formula * formula)
| OrElse of (formula * formula)
| Imply of (formula * formula)
| Equal of (exp * exp)
and exp = Num of int | Plus of (exp * exp) | Minus of (exp * exp)
let rec chlwhd (e : exp) : int =
match e with
| Num a -> a
| Plus ... | null | https://raw.githubusercontent.com/kupl/LearnML/c98ef2b95ef67e657b8158a2c504330e9cfb7700/result/cafe2/formula/sub110/original.ml | ocaml | type formula =
| True
| False
| Not of formula
| AndAlso of (formula * formula)
| OrElse of (formula * formula)
| Imply of (formula * formula)
| Equal of (exp * exp)
and exp = Num of int | Plus of (exp * exp) | Minus of (exp * exp)
let rec chlwhd (e : exp) : int =
match e with
| Num a -> a
| Plus ... | |
d21f283dbaa9d81cf348530562bea6922ed9ff822848890400c00f6eacd06dab | craigl64/clim-ccl | old-clx-implementation.lisp | -*- Mode : Lisp ; Syntax : ANSI - Common - Lisp ; Package : CLX - CLIM ; Base : 10 ; Lowercase : Yes -*-
;; See the file LICENSE for the full license governing this code.
;;
--- ( 1 ) Why does the new CLX port flush WHITE- and BLACK - PIXEL ?
--- ( 2 ) What to do about reparenting ?
(defclass clx-window
(window-... | null | https://raw.githubusercontent.com/craigl64/clim-ccl/301efbd770745b429f2b00b4e8ca6624de9d9ea9/clx/old-clx-implementation.lisp | lisp | Syntax : ANSI - Common - Lisp ; Package : CLX - CLIM ; Base : 10 ; Lowercase : Yes -*-
See the file LICENSE for the full license governing this code.
true when wm reparents us
--- New CLX port needs to handle this reparenting stuff
No hang-p argument, use :timeout 0.
The idea below is that EVENT-COND will return ... |
--- ( 1 ) Why does the new CLX port flush WHITE- and BLACK - PIXEL ?
--- ( 2 ) What to do about reparenting ?
(defclass clx-window
(window-stream)
((white-pixel)
(black-pixel)
(mapped-p :initform nil :reader window-visibility)
(defmethod stream-event-handler ((stream clx-root-window)
&key (time... |
575fc44b202c1dc982e265ff74253c65b53908ccb4ae06b53c86696f73113934 | BoeingX/haskell-programming-from-first-principles | Exercises.hs | module MonadTransformers.EitherT.Exercises where
import Control.Applicative (liftA2)
newtype EitherT e m a = EitherT { runEitherT :: m (Either e a) }
Question 1
instance (Functor m) => Functor (EitherT e m) where
fmap f (EitherT mea) = EitherT $ (fmap . fmap) f mea
Question 2
instance (Applicative m) => App... | null | https://raw.githubusercontent.com/BoeingX/haskell-programming-from-first-principles/ffb637f536597f552a4e4567fee848ed27f3ba74/src/MonadTransformers/EitherT/Exercises.hs | haskell | module MonadTransformers.EitherT.Exercises where
import Control.Applicative (liftA2)
newtype EitherT e m a = EitherT { runEitherT :: m (Either e a) }
Question 1
instance (Functor m) => Functor (EitherT e m) where
fmap f (EitherT mea) = EitherT $ (fmap . fmap) f mea
Question 2
instance (Applicative m) => App... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.