_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
f847837918d93ff251fd1c1a216d8daafc3caccd591c49066e409b86f3432e0c
borkdude/advent-of-cljc
mfikes.cljc
(ns aoc.y2018.d11.mfikes (:refer-clojure :exclude [read-string format]) (:require [aoc.utils :as u :refer [deftest read-string format]] [aoc.y2018.d11.data :refer [input answer-1 answer-2]] [clojure.test :as t :refer [is testing]] [clojure.string :as string])) (defn max-by [f xs] (let [[ndx max] (red...
null
https://raw.githubusercontent.com/borkdude/advent-of-cljc/17c8abb876b95ab01eee418f1da2e402e845c596/src/aoc/y2018/d11/mfikes.cljc
clojure
(ns aoc.y2018.d11.mfikes (:refer-clojure :exclude [read-string format]) (:require [aoc.utils :as u :refer [deftest read-string format]] [aoc.y2018.d11.data :refer [input answer-1 answer-2]] [clojure.test :as t :refer [is testing]] [clojure.string :as string])) (defn max-by [f xs] (let [[ndx max] (red...
4c34fceae2e03974a98d39374281d5cf9572a56789f053eeabda6746642da670
klauso/KdP2012
test.rkt
#lang scribble/manual @(require scribble/eval) @(require "marburg-utils.rkt") @(require (for-label lang/htdp-beginner)) @(require (for-label (except-in 2htdp/image image?))) @(require (for-label 2htdp/universe)) asdfasdf
null
https://raw.githubusercontent.com/klauso/KdP2012/c0d0c34d3a7816c6aeb93d29d09822b151f44b86/test.rkt
racket
#lang scribble/manual @(require scribble/eval) @(require "marburg-utils.rkt") @(require (for-label lang/htdp-beginner)) @(require (for-label (except-in 2htdp/image image?))) @(require (for-label 2htdp/universe)) asdfasdf
9cf5623580f731b2e0c90b0cb8667f20aee719c4058f8ccbc2fbd372d882dbcd
dbuenzli/carcass
carcass_cli.mli
--------------------------------------------------------------------------- Copyright ( c ) 2016 . All rights reserved . Distributed under the ISC license , see terms at the end of the file . --------------------------------------------------------------------------- Copyright (c) 2016 Daniel C. Bün...
null
https://raw.githubusercontent.com/dbuenzli/carcass/1221231b1e3d9ba5b7697707d0e7e901d51ac376/src/carcass_cli.mli
ocaml
* [env ()] is a {!Cmdliner} term that has all the options to setup a carcass environment. The closure should be called once {!Logs} has been setup. The options are documented under the [docs] section (defaults to the default in {!Cmdliner.Arg.info}). * [env_with_cli_flesh ~pos] is like {!env} but also defi...
--------------------------------------------------------------------------- Copyright ( c ) 2016 . All rights reserved . Distributed under the ISC license , see terms at the end of the file . --------------------------------------------------------------------------- Copyright (c) 2016 Daniel C. Bün...
f8ad0de7edf9571cee2e88e96a2050f9a49a63d23bb99f5e8310796201bf55d8
ygrek/ocaml-extlib
optParse.mli
* optParse - Functions for parsing command line arguments . * Copyright ( C ) 2004 * * Heavily influenced by the optparse.py module from the Python * standard library , but with lots of adaptation to the ' Ocaml Way ' * * * This library is free software ; you can redistribute it and/or * mo...
null
https://raw.githubusercontent.com/ygrek/ocaml-extlib/69b77f0f0500c98371aea9a6f2abb56c946cdab0/src/optParse.mli
ocaml
* Modules for GNU [getopt(3)]-style command line parsing. * This module contains the basic functions and types for defining new option types and accessing the values of options. * [No_value] gets raised by {!OptParse.Opt.get} when an option value is not available. * When an option wants to display a usage me...
* optParse - Functions for parsing command line arguments . * Copyright ( C ) 2004 * * Heavily influenced by the optparse.py module from the Python * standard library , but with lots of adaptation to the ' Ocaml Way ' * * * This library is free software ; you can redistribute it and/or * mo...
636de113d8f18e93147379ec3cbf8993b16e9d6cb5b015e0d821d892fc1e58ba
michiakig/sicp
ex-2.67-huffman-encoding.scm
;;;; Structure and Interpretation of Computer Programs Chapter 2 Section 3 Symbolic Data implementation of Huffman encoding from section 2.3.4 (define (make-leaf symbol weight) (list 'leaf symbol weight)) (define (leaf? object) (eq? (car object) 'leaf)) (define (symbol-leaf x) (cadr x)) (define (weight-leaf x)...
null
https://raw.githubusercontent.com/michiakig/sicp/1aa445f00b7895dbfaa29cf6984b825b4e5af492/ch2/2.3-symbolic-data/ex-2.67-huffman-encoding.scm
scheme
Structure and Interpretation of Computer Programs symbol frequency
Chapter 2 Section 3 Symbolic Data implementation of Huffman encoding from section 2.3.4 (define (make-leaf symbol weight) (list 'leaf symbol weight)) (define (leaf? object) (eq? (car object) 'leaf)) (define (symbol-leaf x) (cadr x)) (define (weight-leaf x) (caddr x)) (define (make-code-tree left right) (lis...
362e98e413ad6b92659f0ca8fd45e3a8a9357b86b4fe94daaa5cca620d1bd948
clojupyter/clojupyter
history.clj
(ns clojupyter.kernel.handle-event.history (:require [clojupyter.kernel.handle-event.ops :refer [definterceptor s*append-enter-action s*set-response]] [clojupyter.messages :as msgs] [clojupyter.plan :refer [s*bind-state]] [clojupyter.state :as state] [io.simplect.compos...
null
https://raw.githubusercontent.com/clojupyter/clojupyter/b54b30b5efa115937b7a85e708a7402bd9efa0ab/src/clojupyter/kernel/handle_event/history.clj
clojure
(ns clojupyter.kernel.handle-event.history (:require [clojupyter.kernel.handle-event.ops :refer [definterceptor s*append-enter-action s*set-response]] [clojupyter.messages :as msgs] [clojupyter.plan :refer [s*bind-state]] [clojupyter.state :as state] [io.simplect.compos...
b596d3e8514567cfe7716e9e3bdad1a97eba9b9fa117a6b43deb2a19790fe19f
paurkedal/ocaml-radixmap
testkit.ml
Copyright ( C ) 2017 - -2022 Petter A. Urkedal < > * * This library is free software ; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation , either version 3 of the License , or ( at your * option ) any la...
null
https://raw.githubusercontent.com/paurkedal/ocaml-radixmap/93d0df62ac1da91c42dfdbac579e0e55a2dbdd5e/tests/testkit.ml
ocaml
Copyright ( C ) 2017 - -2022 Petter A. Urkedal < > * * This library is free software ; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation , either version 3 of the License , or ( at your * option ) any la...
74101b466155921980c5c96530c307995d1a7b32ea1e1393c5bb432c43844b24
ocaml/merlin
typeclass.ml
(**************************************************************************) (* *) (* OCaml *) (* *) ...
null
https://raw.githubusercontent.com/ocaml/merlin/d78b9d517d8b7265b4af03482252e6dfb7e9ee1e/src/ocaml/typing/typeclass.ml
ocaml
************************************************************************ OCaml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et the GNU Lesser General Public License version 2.1 , with the open Parsetree open Asttypes open Path open Types open Typecore open Typetexp open Format type 'a class_inf...
e023c0ee7fd5aeb2796081bb290149259cab09f2712f4f0ca78d687ff1ae2100
nallen05/djula
run.lisp
djula-test::!run-process-tokens-test
null
https://raw.githubusercontent.com/nallen05/djula/331e2d5b0c9967b636e4df22e847ac98f16f6ba9/test/1-process-tokens-group/run.lisp
lisp
djula-test::!run-process-tokens-test
dbd3ebecece3f311e240d5e279d3efa24ec9e8be5aafb7d55db83c5b398e2594
DaMSL/K3
Options.hs
# LANGUAGE DeriveGeneric # # LANGUAGE TupleSections # # LANGUAGE ViewPatterns # | Options for the K3 Driver module Language.K3.Driver.Options where import Control.Applicative import Control.Arrow ( second ) import Options.Applicative import Data.Binary import Data.Serialize import Data.Char import Data.Map ( Map ...
null
https://raw.githubusercontent.com/DaMSL/K3/51749157844e76ae79dba619116fc5ad9d685643/src/Language/K3/Driver/Options.hs
haskell
| Program Options. | Modes of Operation. | Compiler input and output options. | Parsing options. | Metaprogramming options | Typechecking options | Compilation options datatypes. | Interpretation options. | Logging and information output options. | Logging directives, passed through to K3.Logger.Config . | K...
# LANGUAGE DeriveGeneric # # LANGUAGE TupleSections # # LANGUAGE ViewPatterns # | Options for the K3 Driver module Language.K3.Driver.Options where import Control.Applicative import Control.Arrow ( second ) import Options.Applicative import Data.Binary import Data.Serialize import Data.Char import Data.Map ( Map ...
823dcf603cf8f33fa72262927daf0caab0579cbef71c97883059a068141ea50d
melange-re/melange
node.ml
Copyright ( C ) 2015 - 2016 Bloomberg Finance L.P. * * 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 , either version 3 of the License , or * ( at your option ) any later...
null
https://raw.githubusercontent.com/melange-re/melange/246e6df78fe3b6cc124cb48e5a37fdffd99379ed/jscomp/others/node.ml
ocaml
* Placeholder for Node bindings
Copyright ( C ) 2015 - 2016 Bloomberg Finance L.P. * * 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 , either version 3 of the License , or * ( at your option ) any later...
958957272af1e0320b42a152b16502e34c13a2ef2d254000f71700e57ea6ca61
mattgreen/hython
Ref.hs
module Hython.Ref where import Control.Monad.IO.Class (MonadIO, liftIO) import Data.IORef type Ref a = IORef a newRef :: MonadIO m => a -> m (IORef a) newRef obj = liftIO $ newIORef obj readRef :: MonadIO m => IORef a -> m a readRef ref = liftIO $ readIORef ref modifyRef :: MonadIO m => IORef a -> (a -> a) -> m ()...
null
https://raw.githubusercontent.com/mattgreen/hython/fcbde98e9b5a033f0d4bea73ac9914bc5e12b746/src/Hython/Ref.hs
haskell
module Hython.Ref where import Control.Monad.IO.Class (MonadIO, liftIO) import Data.IORef type Ref a = IORef a newRef :: MonadIO m => a -> m (IORef a) newRef obj = liftIO $ newIORef obj readRef :: MonadIO m => IORef a -> m a readRef ref = liftIO $ readIORef ref modifyRef :: MonadIO m => IORef a -> (a -> a) -> m ()...
89a1ee72a454bb5f7cdaf6e2c333dd88fc33a42d74f0806e1a97f0f69c250a1f
HealthSamurai/re-form
project.clj
(defproject ui "0.1.0-SNAPSHOT" :description "FIXME: write description" :url "" :license {:name "Eclipse Public License" :url "-v10.html"} :dependencies [[org.clojure/clojure "1.8.0"] [org.clojure/clojurescript "1.9.521" :scope "provided"] [cljsjs/react-with-addons...
null
https://raw.githubusercontent.com/HealthSamurai/re-form/810321d67e3946876c834998e3472d0693846953/example/project.clj
clojure
:foreign-libs [] :externs [] :externs [] :output-dir "build/js/out"
(defproject ui "0.1.0-SNAPSHOT" :description "FIXME: write description" :url "" :license {:name "Eclipse Public License" :url "-v10.html"} :dependencies [[org.clojure/clojure "1.8.0"] [org.clojure/clojurescript "1.9.521" :scope "provided"] [cljsjs/react-with-addons...
d44ec2a1b1c790b0de5cb5b09602fa3992aef282efd1e5bee50f8f9c97b492ec
brendanlong/ocaml-ooxml
relationship.mli
module Target_mode : sig type t = | Internal | External [@@deriving sexp_of] val of_string : string -> t end type t = { target_mode : Target_mode.t ; target : string (** xsd:anyURI *) ; type_ : string (** xsd:anyURI *) ; id : string (** xsd:ID *) } [@@deriving fields, sexp_of] val of_...
null
https://raw.githubusercontent.com/brendanlong/ocaml-ooxml/dd6b8496d22670cc0fa0b50990414f955267ded9/open_packaging/src/relationship.mli
ocaml
* xsd:anyURI * xsd:anyURI * xsd:ID
module Target_mode : sig type t = | Internal | External [@@deriving sexp_of] val of_string : string -> t end type t = { target_mode : Target_mode.t [@@deriving fields, sexp_of] val of_xml : Xml.xml -> t option
85d20b46ef13451301ac2161a58e80eff476ba2a6c2c223cee8fdbb69b497e6a
facebook/infer
Cfg.mli
* Copyright ( c ) 2009 - 2013 , Monoidics ltd . * Copyright ( c ) Facebook , Inc. and its 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) 2009-2013, Monoidics ltd. * Copyright (c) Facebook, In...
null
https://raw.githubusercontent.com/facebook/infer/b9d77e72a1c6c56f7013299d363c56fd16c29f63/infer/src/IR/Cfg.mli
ocaml
* Control Flow Graph for Interprocedural Analysis * A control-flow graph is a collection of all the CFGs for the procedure names in a file * get all the procedure names that are defined in the current file * create a new empty cfg * Create a new procdesc. If the procedure is defined, you need to create and set the ...
* Copyright ( c ) 2009 - 2013 , Monoidics ltd . * Copyright ( c ) Facebook , Inc. and its 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) 2009-2013, Monoidics ltd. * Copyright (c) Facebook, In...
64e471eaa69aafa19919201ee9db5119d0150c53da3a4b29e0b25d188b06bfbe
racket/scribble
manual-mod.rkt
#lang racket/base (require "../decode.rkt" "../struct.rkt" "../basic.rkt" "../manual-struct.rkt" (only-in "../core.rkt" table-columns) "manual-ex.rkt" "manual-style.rkt" "manual-scheme.rkt" "manual-utils.rkt" setup/main-collects p...
null
https://raw.githubusercontent.com/racket/scribble/d36a983e9d216e04ac1738fa3689c80731937f38/scribble-lib/scribble/private/manual-mod.rkt
racket
--------------------------------------------------------------------------------------------------- @deprecated[Precontent]{Precontent ... } produces a nested paragraph with a yellow NOTE label to warn readers of deprecated modules -----------------------------------------------------------------------------------...
#lang racket/base (require "../decode.rkt" "../struct.rkt" "../basic.rkt" "../manual-struct.rkt" (only-in "../core.rkt" table-columns) "manual-ex.rkt" "manual-style.rkt" "manual-scheme.rkt" "manual-utils.rkt" setup/main-collects p...
b0fc552357e3f6769879ee1e8686a5418afe3142b9f4b9ae7ae70c2dd089740a
bluelisp/hemlock
bitmap-rompsite.lisp
;;;; -*- Mode: Lisp; indent-tabs-mode: nil -*- (in-package :hi) (eval-when (:compile-toplevel :load-toplevel :execute) (defvar group-interesting-xevents '(:structure-notify))) (defvar group-interesting-xevents-mask (apply #'xlib:make-event-mask group-interesting-xevents)) (eval-when (:compile-toplevel :load...
null
https://raw.githubusercontent.com/bluelisp/hemlock/47e16ba731a0cf4ffd7fb2110e17c764ae757170/src/bitmap-rompsite.lisp
lisp
-*- Mode: Lisp; indent-tabs-mode: nil -*- Actually, this ignores default-highlight-font and default-open-paren-font Font" when these are defined. GB if the request is valid or not, so we finish the output to get synch'ed with the server which will cause any errors to get signaled. At this level, we want to dea...
(in-package :hi) (eval-when (:compile-toplevel :load-toplevel :execute) (defvar group-interesting-xevents '(:structure-notify))) (defvar group-interesting-xevents-mask (apply #'xlib:make-event-mask group-interesting-xevents)) (eval-when (:compile-toplevel :load-toplevel :execute) (defvar child-interesting...
1982bd69cd8fb7025d610fef0b707f95cb0b2faba83f79ca587f3d8a3873eaa9
AbstractMachinesLab/caramel
env.ml
module Var = struct module T = struct type t = string let compare = if Sys.win32 then fun a b -> String.compare (String.lowercase a) (String.lowercase b) else String.compare let to_dyn = Dyn.Encoder.string end include Comparable.Make (T) include T end module Map...
null
https://raw.githubusercontent.com/AbstractMachinesLab/caramel/7d4e505d6032e22a630d2e3bd7085b77d0efbb0c/vendor/ocaml-lsp-1.4.0/vendor/stdune/env.ml
ocaml
The use of [mutable] here is safe, since we never call (back) to the memoization framework when computing [unix].
module Var = struct module T = struct type t = string let compare = if Sys.win32 then fun a b -> String.compare (String.lowercase a) (String.lowercase b) else String.compare let to_dyn = Dyn.Encoder.string end include Comparable.Make (T) include T end module Map...
e0f3f428978112255890f1f720ccd3fe537f8b014dd1f590750b3dbecabfac35
ComputerAidedLL/click-and-collect
proof_with_notations.ml
open Proof open Notations type proof_with_notations = {proof: proof; notations: notations} exception Json_exception of string let from_json proof_with_notations_as_json = try let notations_as_json = Request_utils.get_key proof_with_notations_as_json "notations" in let notations = Notations.from_j...
null
https://raw.githubusercontent.com/ComputerAidedLL/click-and-collect/c1e882a496aaec054a05164ada6fc1056dd8ec18/proof_with_notations.ml
ocaml
open Proof open Notations type proof_with_notations = {proof: proof; notations: notations} exception Json_exception of string let from_json proof_with_notations_as_json = try let notations_as_json = Request_utils.get_key proof_with_notations_as_json "notations" in let notations = Notations.from_j...
04343452da75e7d911b8a6e1129e36a0b4b5a4143893901c7f8c04e92f601f9d
joshvera/effects
State.hs
# LANGUAGE FlexibleContexts # # LANGUAGE TypeApplications # module Tests.State ( testPutGet, testPutGetPutGetPlus, testGetStart ) where import Control.Monad.Effect import Control.Monad.Effect.State testPutGet :: Int -> Int -> (Int,Int) testPutGet n start = run @Eff (runState start go) where go = put n >> get ...
null
https://raw.githubusercontent.com/joshvera/effects/b2693454131dc7c00d2cf45bea69c17b986f0ea5/tests/Tests/State.hs
haskell
# LANGUAGE FlexibleContexts # # LANGUAGE TypeApplications # module Tests.State ( testPutGet, testPutGetPutGetPlus, testGetStart ) where import Control.Monad.Effect import Control.Monad.Effect.State testPutGet :: Int -> Int -> (Int,Int) testPutGet n start = run @Eff (runState start go) where go = put n >> get ...
d4de9c306395bb1a7ae25dd1ee921ef58e5932ac727085ce1783346ebf4e77f5
mcgizzle/haxchange
ApiSpec.hs
{-# LANGUAGE OverloadedStrings #-} module Binance.ApiSpec where import Haxchange.Binance.Api import Test.Hspec import Test.Hspec.Expectations.Contrib import Haxchange.Types import Haxchange.Utils spec :: Spec spec = do keys <- runIO $ getKeys "keys/binance.txt...
null
https://raw.githubusercontent.com/mcgizzle/haxchange/620a4c93ae28abdd637b7c1fd8b018628b3bd0e9/test/Binance/ApiSpec.hs
haskell
# LANGUAGE OverloadedStrings #
module Binance.ApiSpec where import Haxchange.Binance.Api import Test.Hspec import Test.Hspec.Expectations.Contrib import Haxchange.Types import Haxchange.Utils spec :: Spec spec = do keys <- runIO $ getKeys "keys/binance.txt" describe "Connectivity" $...
8b0589674a18fba88486be1ebfcafb1e3bbcc56ca53bf5f84bbee8b78634f76a
BrunoBonacci/safely
core_test.clj
(ns safely.core-test (:require [clojure.test.check :as tc] [clojure.test.check.generators :as gen] [clojure.test.check.properties :as prop] [midje.sweet :refer :all] [safely.core :refer :all] [safely.test-utils :refer :all])) ;;;;;;;;;;;;;;;;;;;;;;;;;;;...
null
https://raw.githubusercontent.com/BrunoBonacci/safely/8aadfcba9dbddf942228da90d3478c769e39a3ac/test/safely/core_test.clj
clojure
;; ---==| T E S T R A N D O M I Z E R S |==---- ;; ;; ;; ...
(ns safely.core-test (:require [clojure.test.check :as tc] [clojure.test.check.generators :as gen] [clojure.test.check.properties :as prop] [midje.sweet :refer :all] [safely.core :refer :all] [safely.test-utils :refer :all])) (def rand-between-boudari...
f48228215e72bf8caa627eb4aa6208411cd485ba6b406222f125d3ac3d310f68
ltoth/unison
myMap.mli
This file is taken from the Objective Caml standard library . Some functions have been added to suit Unison 's needs . This file is taken from the Objective Caml standard library. Some functions have been added to suit Unison's needs. *) (***********************************************************************) (*...
null
https://raw.githubusercontent.com/ltoth/unison/e763510165e3d93c5140a4c5f2ea0dcbf5825a0c/ubase/myMap.mli
ocaml
********************************************************************* Objective Caml ...
This file is taken from the Objective Caml standard library . Some functions have been added to suit Unison 's needs . This file is taken from the Objective Caml standard library. Some functions have been added to suit Unison's needs. *) , projet Cristal , INRIA Rocquencourt Copyright 1...
ab743af56fe829fbd26b7e138d6100214c47bf0245a72264dbb2b56ee429fbd3
wireapp/wire-server
Create.hs
-- This file is part of the Wire Server implementation. -- Copyright ( C ) 2022 Wire Swiss GmbH < > -- -- This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License...
null
https://raw.githubusercontent.com/wireapp/wire-server/97286de4e9745b89e0146c0cb556b1f90e660133/services/brig/test/integration/Index/Create.hs
haskell
This file is part of the Wire Server implementation. This program is free software: you can redistribute it and/or modify it under 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 PARTI...
Copyright ( C ) 2022 Wire Swiss GmbH < > the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or ( at your option ) any You should have received a copy of the GNU Affero General Public License along module Index.Create where impor...
90c3b319102d8e3f4e3df38004401894d08ceb732033d5b902f44c402682973e
SparkFund/useful-specs
number_test.clj
(ns specs.number-test (:require [clojure.spec.test :as stest] [clojure.test :refer :all] [specs.number :refer :all])) (deftest test-decimal-in (testing "generative" (is (every? nil? (map :failure (stest/check `decimal-in))))))
null
https://raw.githubusercontent.com/SparkFund/useful-specs/947148cfe23c5a1babc23df895587fbb71d918ec/test/specs/number_test.clj
clojure
(ns specs.number-test (:require [clojure.spec.test :as stest] [clojure.test :refer :all] [specs.number :refer :all])) (deftest test-decimal-in (testing "generative" (is (every? nil? (map :failure (stest/check `decimal-in))))))
7acc235834f261c2cf40a997d3552b4efe9466a37cd77423e89e25a3d768bac9
cgrand/parsley
views.clj
(ns net.cgrand.parsley.views) ; Right now compute is responsible for memoization (defprotocol ViewableNode (compute [n leaf node] "Applies either the leaf or node function to the node at hand. The leaf function expects one argument: a string. The node function expects two arguments: a keyword and a col...
null
https://raw.githubusercontent.com/cgrand/parsley/c5c4783b5976b9412c80f35cf48ce79e77c9fee5/src/net/cgrand/parsley/views.clj
clojure
Right now compute is responsible for memoization TODO: make Node and String Viewable + memoization zipper on viewable trees we need indexed/measured zippers!
(ns net.cgrand.parsley.views) (defprotocol ViewableNode (compute [n leaf node] "Applies either the leaf or node function to the node at hand. The leaf function expects one argument: a string. The node function expects two arguments: a keyword and a collection of children nodes.")) (defn view ...
b9708a429cc8fa8369050102bd1074daefc0265a5ae83ee7a4f31df7448930c9
phronmophobic/membrane
vdom.cljs
(ns membrane.vdom (:require-macros [membrane.ui :refer [add-default-draw-impls-cljs! ]] [membrane.component :refer [defui]] [cljs.tools.reader.reader-types]) (:require [vdom.core :as vdom] [membrane.basic-components :as basic :refer [textarea]] ...
null
https://raw.githubusercontent.com/phronmophobic/membrane/237640d83b1c1258bc3845b7febdd30d3a94893f/src/membrane/vdom.cljs
clojure
(add-default-draw-impls-cljs! IDraw draw) :width "1000px" TODO: do better [[local-x local-y] result] (find-first-under ui [x y] [0 0] #(satisfies? IScroll %)) (membrane.basic-components/textarea :text s :focus? true)
(ns membrane.vdom (:require-macros [membrane.ui :refer [add-default-draw-impls-cljs! ]] [membrane.component :refer [defui]] [cljs.tools.reader.reader-types]) (:require [vdom.core :as vdom] [membrane.basic-components :as basic :refer [textarea]] ...
c837dcacf5319870bec40f3ef248dfd2aaeb7b3b0cb583906a53381e09eea8df
mrosset/nomad
bookmark.scm
bookmark --- bookmarks for Nomad Copyright ( C ) 2019 > Copyright ( C ) 2019 Amar Singh< > This file is part of Nomad . ;; 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 vers...
null
https://raw.githubusercontent.com/mrosset/nomad/c94a65ede94d86eff039d2ef62d5ef3df609568a/scheme/nomad/bookmark.scm
scheme
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...
bookmark --- bookmarks for Nomad Copyright ( C ) 2019 > Copyright ( C ) 2019 Amar Singh< > This file is part of Nomad . 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...
93ddb302152bb1dfd0dd2e1eb164244463bd5a0c38a5015717aecd3dab7ca2dd
oriansj/mes-m2
niladic.scm
GNU --- Maxwell Equations of Software Copyright ( C ) 2008 Kragen ;;; This file is part of GNU . ;;; GNU is free software ; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 3 of the License , or ( ...
null
https://raw.githubusercontent.com/oriansj/mes-m2/b44fbc976ae334252de4eb82a57c361a195f2194/test/test038/niladic.scm
scheme
you can redistribute it and/or modify it either version 3 of the License , or ( at your option) any later version. WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. Setup output file Test proc...
GNU --- Maxwell Equations of Software Copyright ( C ) 2008 Kragen This file is part of GNU . under the terms of the GNU General Public License as published by GNU is distributed in the hope that it will be useful , but You should have received a copy of the GNU General Public License along with GNU...
d67ed8885596938c894c0d4f66322fd44083c08c2c4245a85f5974d51cea18b6
zeromq/cljzmq
receivable.clj
(ns zeromq.receivable) (defprotocol Receivable (receive [this socket flags]))
null
https://raw.githubusercontent.com/zeromq/cljzmq/b8252906a149fe68c49e83568b8f256c8ca2523e/src/zeromq/receivable.clj
clojure
(ns zeromq.receivable) (defprotocol Receivable (receive [this socket flags]))
fe21c3fa1b7d749068c2b59a8cdea80d9d2b45bf0de32d9099bfefe80772e45e
fossas/fossa-cli
Closure.hs
# LANGUAGE RecordWildCards # module Strategy.Maven.Pom.Closure ( findProjects, MavenProjectClosure (..), buildProjectClosures, ) where import Algebra.Graph.AdjacencyMap qualified as AM import Algebra.Graph.AdjacencyMap.Algorithm qualified as AM import Control.Algebra import Control.Carrier.State.Strict import C...
null
https://raw.githubusercontent.com/fossas/fossa-cli/cddea296c88ddc021913c7d0222a53948b6f1893/src/Strategy/Maven/Pom/Closure.hs
haskell
Find reachable nodes both below (children, grandchildren, ...) and above (parents, grandparents) the node This ensures that the absolute path is relative to the root directory ^ the root of global fossa-analyze analysis; needed for pathfinder license scan ^ path of the pom file used as the root of this project clos...
# LANGUAGE RecordWildCards # module Strategy.Maven.Pom.Closure ( findProjects, MavenProjectClosure (..), buildProjectClosures, ) where import Algebra.Graph.AdjacencyMap qualified as AM import Algebra.Graph.AdjacencyMap.Algorithm qualified as AM import Control.Algebra import Control.Carrier.State.Strict import C...
9212dc79a257afd235ee3dda629804e3bb1158568b2d8a07b4201b867378ac2b
shayan-najd/NativeMetaprogramming
tcrun037.hs
# LANGUAGE ConstrainedClassMethods # module Main where class C a where op :: (Show a, Show b) => a -> b -> String -- This class op has local quantification, but -- also adds a constraint on 'a' instance C Bool where op x y = show x ++ " " ++ show y main = do { putStrLn (op True 'x'); putStrLn (op False (3::In...
null
https://raw.githubusercontent.com/shayan-najd/NativeMetaprogramming/24e5f85990642d3f0b0044be4327b8f52fce2ba3/testsuite/tests/typecheck/should_run/tcrun037.hs
haskell
This class op has local quantification, but also adds a constraint on 'a'
# LANGUAGE ConstrainedClassMethods # module Main where class C a where op :: (Show a, Show b) => a -> b -> String instance C Bool where op x y = show x ++ " " ++ show y main = do { putStrLn (op True 'x'); putStrLn (op False (3::Int)) }
b9bf2aa228b18bf009f1dd42dff79b046eac5151555175788638d8b8c3be31a3
abeaumont/ocaml-pbkdf
pbkdf_tests.ml
PBKDF1 let test_pbkdf1 ~hash ~password ~salt ~count ~dk_len ~dk = let salt = Cstruct.of_hex salt and dk = Cstruct.of_hex dk and password = Cstruct.of_string password in (fun () -> let edk = Pbkdf.pbkdf1 ~hash ~password ~salt ~count ~dk_len in let sedk = Cstruct.to_string edk and sdk = Cstruct.t...
null
https://raw.githubusercontent.com/abeaumont/ocaml-pbkdf/fd444b7d853da86329e9ceffcf60812ddbe43d12/test/pbkdf_tests.ml
ocaml
Taken from -mgt.com.au/cryptoKDFs.html PBKDF2 Taken from
PBKDF1 let test_pbkdf1 ~hash ~password ~salt ~count ~dk_len ~dk = let salt = Cstruct.of_hex salt and dk = Cstruct.of_hex dk and password = Cstruct.of_string password in (fun () -> let edk = Pbkdf.pbkdf1 ~hash ~password ~salt ~count ~dk_len in let sedk = Cstruct.to_string edk and sdk = Cstruct.t...
2317befb161a1088b608d2cef551eba840537d7bab4db1d697d5e38edbd441e5
rabbitmq/ra
ra_fifo.erl
-module(ra_fifo). -behaviour(ra_machine). -compile(inline_list_funcs). -compile(inline). -compile({no_auto_import, [apply/3]}). -include("src/ra.hrl"). -include_lib("eunit/include/eunit.hrl"). -export([ init/1, apply/3, state_enter/2, tick/2, overview/1, get_che...
null
https://raw.githubusercontent.com/rabbitmq/ra/5f84a20a7a565233f466108c2cc5d65df9164c79/test/ra_fifo.erl
erlang
aux queries misc profile/1 The raw message. It is opaque to ra_fifo. a queue scoped monotonically incrementing integer used to enforce order in the unassigned messages map A customer-scoped monotonically incrementing integer included with a {@link ra_fifo_client:settle/3.} A sender process scoped monotonical...
-module(ra_fifo). -behaviour(ra_machine). -compile(inline_list_funcs). -compile(inline). -compile({no_auto_import, [apply/3]}). -include("src/ra.hrl"). -include_lib("eunit/include/eunit.hrl"). -export([ init/1, apply/3, state_enter/2, tick/2, overview/1, get_che...
684e9ab306e60d274ffd02efbcbcbdc99f59ad153f63574fdbda335bef8b629f
metaocaml/ber-metaocaml
lazy1.ml
(* TEST ocamlopt_flags += " -O3 " *) Mantis 7301 , due to let foo () = (fun xs0 () -> Lazy.force (List.hd xs0) ()) (List.map (fun g -> lazy g) [Lazy.force ( lazy ( let _ = () in fun () -> () ) )] ) let () = let gen = foo () in gen (); Gc.compact (); print_char 'A'; flush stdout; g...
null
https://raw.githubusercontent.com/metaocaml/ber-metaocaml/4992d1f87fc08ccb958817926cf9d1d739caf3a2/testsuite/tests/lazy/lazy1.ml
ocaml
TEST ocamlopt_flags += " -O3 "
Mantis 7301 , due to let foo () = (fun xs0 () -> Lazy.force (List.hd xs0) ()) (List.map (fun g -> lazy g) [Lazy.force ( lazy ( let _ = () in fun () -> () ) )] ) let () = let gen = foo () in gen (); Gc.compact (); print_char 'A'; flush stdout; gen ()
f85905c1d9b9ad82c92c52cdbcf4fa11641a2e867efdebb0e5701f9e9fa6d3c0
theodormoroianu/SecondYearCourses
HaskellChurchMonad_20210415160845.hs
module HaskellChurchMonad where A boolean is any way to choose between two alternatives newtype CBool t = CBool {cIf :: t -> t -> t} toBool :: CBool Bool -> Bool toBool b = cIf b True False The boolean constant true always chooses the first alternative cTrue :: CBool t cTrue = CBool $ \t f -> t The boolean consta...
null
https://raw.githubusercontent.com/theodormoroianu/SecondYearCourses/5e359e6a7cf588a527d27209bf53b4ce6b8d5e83/FLP/Laboratoare/Lab%209/.history/HaskellChurchMonad_20210415160845.hs
haskell
The boolean negation switches the alternatives The boolean conjunction can be built as a conditional The boolean disjunction can be built as a conditional a pair is a way to compute something based on the values contained within the pair. a function to be applied on the values, it will apply it on them. A natural nu...
module HaskellChurchMonad where A boolean is any way to choose between two alternatives newtype CBool t = CBool {cIf :: t -> t -> t} toBool :: CBool Bool -> Bool toBool b = cIf b True False The boolean constant true always chooses the first alternative cTrue :: CBool t cTrue = CBool $ \t f -> t The boolean consta...
525e4c9b9e8baf53e427ef6b20afe8982741f5e04c35ddaa25933bb86b25b847
killme2008/secure-rand
core_test.clj
(ns secure-rand.core-test (:require [clojure.test :refer :all] [secure-rand.core :refer :all])) (deftest a-test (testing "FIXME, I fail." (is (= 0 1))))
null
https://raw.githubusercontent.com/killme2008/secure-rand/5048ad740624eb50803df447f587dfe397d8af7f/test/secure_rand/core_test.clj
clojure
(ns secure-rand.core-test (:require [clojure.test :refer :all] [secure-rand.core :refer :all])) (deftest a-test (testing "FIXME, I fail." (is (= 0 1))))
6d06a53ef0a893b6a48db550146840b4f101d4245dddafead0dd571417715b73
8c6794b6/guile-tjit
foreign.scm
Copyright ( C ) 2010 , 2011 , 2013 Free Software Foundation , Inc. ;;;; ;;;; This library is free software; you can redistribute it and/or ;;;; modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation ; either version 2.1 of the License , or ( at your option...
null
https://raw.githubusercontent.com/8c6794b6/guile-tjit/9566e480af2ff695e524984992626426f393414f/module/system/foreign.scm
scheme
This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public either This library 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...
Copyright ( C ) 2010 , 2011 , 2013 Free Software Foundation , Inc. version 2.1 of the License , or ( at your option ) any later version . You should have received a copy of the GNU Lesser General Public Foundation , Inc. , 51 Franklin Street , Fifth Floor , Boston , USA (define-module (system foreign) ...
ae0aea462fc1af0653ead6df04952877da959397e5e805f68c632762fbad9b9d
dmitryvk/sbcl-win32-threads
fopcompile.lisp
;;;; A compiler from simple top-level forms to FASL operations. 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 i...
null
https://raw.githubusercontent.com/dmitryvk/sbcl-win32-threads/5abfd64b00a0937ba2df2919f177697d1d91bde4/src/compiler/fopcompile.lisp
lisp
A compiler from simple top-level forms to FASL operations. 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. but its FOPs are a sort of byte code which is expressive enough that we can compil...
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!C") SBCL has no proper byte compiler ( having ditched the rather ambitious and slightly flaky byte compi...
c01c43769eddeb2eb9cc3ac42900b9cd6a3a769b59ef0e74979d5033f17a5d37
Kappa-Dev/KappaTools
superarg.ml
Similar to OCaml 's standard Arg module but with some improvements : - options are classified with respect to categories - neophyte / expert modes - hidden options Note that the spec type is really different . Copyright ( C ) 2006 - options are classified with respect to categories...
null
https://raw.githubusercontent.com/Kappa-Dev/KappaTools/5e756eb3529db9976cf0a0884a22676925985978/core/cli/superarg.ml
ocaml
shows expert options accept _ALL_ options Types ***** command-line argument help message type of option always shown & accepted never shown To skip a line Sets a boolean value Sets an integer value Sets an optional integer value Sets a string value Sets an optional string value Sets a lis...
Similar to OCaml 's standard Arg module but with some improvements : - options are classified with respect to categories - neophyte / expert modes - hidden options Note that the spec type is really different . Copyright ( C ) 2006 - options are classified with respect to categories...
3d5cf35517c2c4df70153b03e7d2bf58967ec43b887328d1b2bcca66f6be6860
faylang/fay
LazyOperators.hs
module LazyOperators where main :: Fay () main = print testFn testFn = let f a b = snd (a/b,10::Double) in f (1::Double) (0::Double)
null
https://raw.githubusercontent.com/faylang/fay/8455d975f9f0db2ecc922410e43e484fbd134699/tests/LazyOperators.hs
haskell
module LazyOperators where main :: Fay () main = print testFn testFn = let f a b = snd (a/b,10::Double) in f (1::Double) (0::Double)
5d91e7c938f6bd77d50dfdca14a808c856925ef4086cfe77cc0d1d3da6cb5706
hspec/hspec
FooSpec.hs
module FooSpec (main, spec) where import Prelude import Test.Hspec main :: IO () main = hspec spec spec :: Spec spec = do describe "reverse" $ do it "reverses a list" $ do reverse [1 :: Int, 2, 3] `shouldBe` [3, 2, 1]
null
https://raw.githubusercontent.com/hspec/hspec/b48eee41032450123044de82c4c02213813563b1/hspec-discover/integration-test/with-no-implicit-prelude/FooSpec.hs
haskell
module FooSpec (main, spec) where import Prelude import Test.Hspec main :: IO () main = hspec spec spec :: Spec spec = do describe "reverse" $ do it "reverses a list" $ do reverse [1 :: Int, 2, 3] `shouldBe` [3, 2, 1]
508a54ed57af9e8d534d055229a2b8cc7467969a6fb3a11558dd900e9c8f14fb
tokiwoousaka/ttask
Pretty.hs
module Data.TTask.Pretty ( module Data.TTask.Pretty.Contents , module Data.TTask.Pretty.Status ) where import Data.TTask.Pretty.Contents import Data.TTask.Pretty.Status
null
https://raw.githubusercontent.com/tokiwoousaka/ttask/ef5a14ee49e9d8a1e8d0b5c35ee4ae131f4e9acc/src/Data/TTask/Pretty.hs
haskell
module Data.TTask.Pretty ( module Data.TTask.Pretty.Contents , module Data.TTask.Pretty.Status ) where import Data.TTask.Pretty.Contents import Data.TTask.Pretty.Status
2a19c58d83d685ea7b575bbeeaba1292387a1f130624a97408c62bbdf4826f59
hammerlab/coclobas
myocamlbuild.ml
open Nonstd open Solvuu_build.Std let project_name = "coclobas" let version = "0.0.3-dev" let build_tests = try Sys.getenv "WITH_TESTS" = "true" with _ -> false let findlib_deps = [ "nonstd"; "sosa"; "pvem_lwt_unix"; "cohttp.lwt"; "trakeva_of_uri"; "cmdliner"; "ppx_deriving.std"; "ppx_deriving_yojs...
null
https://raw.githubusercontent.com/hammerlab/coclobas/5341ea53fdb5bcea0dfac3e4bd94213b34a48bb9/myocamlbuild.ml
ocaml
open Nonstd open Solvuu_build.Std let project_name = "coclobas" let version = "0.0.3-dev" let build_tests = try Sys.getenv "WITH_TESTS" = "true" with _ -> false let findlib_deps = [ "nonstd"; "sosa"; "pvem_lwt_unix"; "cohttp.lwt"; "trakeva_of_uri"; "cmdliner"; "ppx_deriving.std"; "ppx_deriving_yojs...
e9cb07c3d7652e125d1a055f19bb738abea6c8a08f45153dd127855671e80ff8
quchen/generative-art
Interpolation.hs
-- | Interpolate between values. module Numerics.Interpolation ( lerp , lerpDI , lerpID , lerpII ) where import Algebra.VectorSpace | Linearly interpolate the interval \([a , b]\ ) to \([x , y]\ ) . In computer graphics -- lingo, this is often known as /lerp/. -- -- \[ -- f(t) = x + \frac{y-x...
null
https://raw.githubusercontent.com/quchen/generative-art/47877f7a3c1e7fc272b4c70b4ac1faf1831ed6d6/src/Numerics/Interpolation.hs
haskell
| Interpolate between values. lingo, this is often known as /lerp/. \[ f(t) = x + \frac{y-x}{b-a} (t-a) \] | Linear interpolation from 'Double' to 'Integral' (hence: @DI@). | Linear interpolation from 'Integral' to 'Double' (hence: @ID@).
module Numerics.Interpolation ( lerp , lerpDI , lerpID , lerpII ) where import Algebra.VectorSpace | Linearly interpolate the interval \([a , b]\ ) to \([x , y]\ ) . In computer graphics > > > lerp ( 0,1 ) ( 10,20 ) 0.5 15.0 lerp :: VectorSpace vec => (Double, Double) -> (vec, vec) -> Dou...
b9e13193da39765f74eaac6a2f6d53f25c5b9c7268b2d5fef0d44a50c754442b
scrintal/heroicons-reagent
bell.cljs
(ns com.scrintal.heroicons.mini.bell) (defn render [] [:svg {:xmlns "" :viewBox "0 0 20 20" :fill "currentColor" :aria-hidden "true"} [:path {:fillRule "evenodd" :d "M10 2a6 6 0 00-6 6c0 1.887-.454 3.665-1.257 5.234a.75.75 0 00.515 1.076 32.91 32.91 0 ...
null
https://raw.githubusercontent.com/scrintal/heroicons-reagent/572f51d2466697ec4d38813663ee2588960365b6/src/com/scrintal/heroicons/mini/bell.cljs
clojure
(ns com.scrintal.heroicons.mini.bell) (defn render [] [:svg {:xmlns "" :viewBox "0 0 20 20" :fill "currentColor" :aria-hidden "true"} [:path {:fillRule "evenodd" :d "M10 2a6 6 0 00-6 6c0 1.887-.454 3.665-1.257 5.234a.75.75 0 00.515 1.076 32.91 32.91 0 ...
bec82fc8430531e2fc9f1ac42e8f1da9cb409c8f74bc25c5828dedcb5fad3da9
heliaxdev/extensible-data
DeBruijn.hs
module DeBruijn where import LamBase data DeBruijn extendLam "DBTerm" [] [t|DeBruijn|] $ \a p -> defaultExtLam { typeVar = Nothing, -- replaced with Free and Bound typeAbs = Nothing, -- replaced with a version without absVar typeLamX = [("Free", [("freeVar", a)]), ("Bound", [("boundVar", [...
null
https://raw.githubusercontent.com/heliaxdev/extensible-data/d11dee6006169cb537e95af28c3541a24194dea8/examples/lam/DeBruijn.hs
haskell
replaced with Free and Bound replaced with a version without absVar
module DeBruijn where import LamBase data DeBruijn extendLam "DBTerm" [] [t|DeBruijn|] $ \a p -> defaultExtLam { typeLamX = [("Free", [("freeVar", a)]), ("Bound", [("boundVar", [t|Int|])]), ("Abs", [("absBody", [t|Lam' DeBruijn $a $p|])])] }
32c80b06a4e88b6b02fd366eae20d24a206e97dd5f70e8c421b824badadb6fcd
gsakkas/rite
2114.ml
type expr = | VarX | VarY | Sine of expr | Cosine of expr | Average of expr* expr | Times of expr* expr | Thresh of expr* expr* expr* expr;; let rec eval (e,x,y) = match e with | VarX -> x +. 0.0 | VarY -> y +. 0.0 | Sine s1 -> sin s1 | Average (a1,a2) -> (eval (VarX, x, y)) +. (eval (VarY, ...
null
https://raw.githubusercontent.com/gsakkas/rite/958a0ad2460e15734447bc07bd181f5d35956d3b/data/sp14/2114.ml
ocaml
type expr = | VarX | VarY | Sine of expr | Cosine of expr | Average of expr* expr | Times of expr* expr | Thresh of expr* expr* expr* expr;; let rec eval (e,x,y) = match e with | VarX -> x +. 0.0 | VarY -> y +. 0.0 | Sine s1 -> sin s1 | Average (a1,a2) -> (eval (VarX, x, y)) +. (eval (VarY, ...
18ff92c7f99bb2789a15ca75a438cdda01aab9fa5fac8dfcb6983c1b980fd41f
takikawa/racket-ppa
binding-for-transformer.rkt
#lang racket/base (require "env.rkt" "../common/module-path.rkt" "../syntax/module-binding.rkt" "../namespace/namespace.rkt" "../namespace/module.rkt" "../namespace/provided.rkt") (provide binding-for-transformer?) ;; Determine whether `b`, which is the binding of `id` at ...
null
https://raw.githubusercontent.com/takikawa/racket-ppa/26d6ae74a1b19258c9789b7c14c074d867a4b56b/src/expander/expand/binding-for-transformer.rkt
racket
Determine whether `b`, which is the binding of `id` at `at-phase`, refers to a variable or transformer binding; also, check taints (for bindings other than for-label) The binding must be imported; determine whether it's syntax by consulting the exporting module Use `binding-lookup` to both check for taints and de...
#lang racket/base (require "env.rkt" "../common/module-path.rkt" "../syntax/module-binding.rkt" "../namespace/namespace.rkt" "../namespace/module.rkt" "../namespace/provided.rkt") (provide binding-for-transformer?) (define (binding-for-transformer? b id at-phase ns) (con...
510da8bbb56580e24a230f30df809f5c7e0382ccbaaf5eeea958cbe59c795289
philnguyen/soft-contract
extensionality.rkt
1421365820240 #lang racket (require soft-contract/fake-contract) (define (f g) (= (g 5) (g 5))) (provide (contract-out [f ((integer? . -> . integer?) . -> . (lambda (x) x))]))
null
https://raw.githubusercontent.com/philnguyen/soft-contract/5e07dc2d622ee80b961f4e8aebd04ce950720239/soft-contract/test/programs/safe/sym-exe/extensionality.rkt
racket
1421365820240 #lang racket (require soft-contract/fake-contract) (define (f g) (= (g 5) (g 5))) (provide (contract-out [f ((integer? . -> . integer?) . -> . (lambda (x) x))]))
829a512cc803ae29387f8339bc3258f832f3be0fad12b4d94f2ad5fa381761dd
andreasabel/java-adt
List.hs
data List A = Nil | Cons { head :: A, tail :: List A }
null
https://raw.githubusercontent.com/andreasabel/java-adt/21c7b40359201eab26ee427be1b8fe3698f35f47/test/List.hs
haskell
data List A = Nil | Cons { head :: A, tail :: List A }
556a63d90f576ded099adf932d3fa7541db0ab1d139f09f4ecbdbe57ac34938f
owickstrom/komposition
UndoableAction.hs
{-# LANGUAGE DataKinds #-} {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE FlexibleContexts #-} # LANGUAGE FlexibleInstances # # LANGUAGE GADTs # {-# LANGUAGE LambdaCase #-} # LANGUAGE MultiParamTypeClasses # # LANGUAGE OverloadedStrings # # LANGUAGE TupleSecti...
null
https://raw.githubusercontent.com/owickstrom/komposition/64893d50941b90f44d77fea0dc6d30c061464cf3/src/Komposition/Project/UndoableAction.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # # LANGUAGE FlexibleContexts # # LANGUAGE LambdaCase # trace ("Can't delete" :: Text) $ trace ("Can't insert" :: Text) $ TODO: rewrite Split to contain this logic:
# LANGUAGE FlexibleInstances # # LANGUAGE GADTs # # LANGUAGE MultiParamTypeClasses # # LANGUAGE OverloadedStrings # # LANGUAGE TupleSections # module Komposition.Project.UndoableAction where import Komposition.Prelude import Control.Lens import Kompos...
c9e435c2ea5ac23be1649f8417cb8b4b7ffc05f5fdee4a98bac66c5f4ea917d7
fission-codes/fission
Serialization.hs
module Fission.Web.Serialization ( parseHeader , module Fission.Web.Serialization.Error ) where import qualified Servant.API as Servant import Fission.Prelude import Fission.Web.Serialization.Error parseHeader :: Servant.FromHttpApiData a => ByteString -> Either Error a...
null
https://raw.githubusercontent.com/fission-codes/fission/11d14b729ccebfd69499a534445fb072ac3433a3/fission-core/library/Fission/Web/Serialization.hs
haskell
module Fission.Web.Serialization ( parseHeader , module Fission.Web.Serialization.Error ) where import qualified Servant.API as Servant import Fission.Prelude import Fission.Web.Serialization.Error parseHeader :: Servant.FromHttpApiData a => ByteString -> Either Error a...
a9cce644b1770082df8c04f7dd5bce22c1829e52398b771de1917b051fea3d77
donald-pinckney/WasmContinuations
test.rkt
#lang racket ; (system "cc -fPIC -shared -o test.so test.c") ; If on linux If on macOS (load-shared-object "./test.so") (define bar (foreign-procedure "bar" () void)) (define set_bad (foreign-procedure "set_bad" (void*) void)) (define gk1 0) (define h1 (lambda (k1) (display "Starting h1\n") (s...
null
https://raw.githubusercontent.com/donald-pinckney/WasmContinuations/a9e524858c0481ed97021b64f97266e8b574bf3d/racket/test.rkt
racket
(system "cc -fPIC -shared -o test.so test.c") ; If on linux ; (display bad_ep) (newline)
#lang racket If on macOS (load-shared-object "./test.so") (define bar (foreign-procedure "bar" () void)) (define set_bad (foreign-procedure "set_bad" (void*) void)) (define gk1 0) (define h1 (lambda (k1) (display "Starting h1\n") (set! gk1 k1) (bar) (display "Ending h1\n") ...
53b0bc88b20e41dced1558dac068f9cefa25fb32b857e24bbc43ffe42fd17f40
noinia/hgeometry
WSPD.hs
-------------------------------------------------------------------------------- -- | Module : Algorithms . Geometry . WellSeparatedPairDecomposition . WSPD Copyright : ( C ) -- License : see the LICENSE file Maintainer : -- -- Algorithm to construct a well separated pair decomposition (...
null
https://raw.githubusercontent.com/noinia/hgeometry/a6abecb1ce4a7fd96b25cc1a5c65cd4257ecde7a/hgeometry/src/Algorithms/Geometry/WellSeparatedPairDecomposition/WSPD.hs
haskell
------------------------------------------------------------------------------ | License : see the LICENSE file Algorithm to construct a well separated pair decomposition (wspd). ------------------------------------------------------------------------------
Module : Algorithms . Geometry . WellSeparatedPairDecomposition . WSPD Copyright : ( C ) Maintainer : module Algorithms.Geometry.WellSeparatedPairDecomposition.WSPD # DEPRECATED " This module will be deleted after 2021 - 06 - 01 . \ \Use Algorithms . Geometry . WSPD instead...
c44a0c519da3b60f3a543eadd48b8c6e6d0a3cf05d423e34c0654158989ab8af
stchang/macrotypes
mlish-do.rkt
#lang racket/base (provide do) (require (only-in "mlish.rkt" #%app λ Unit) (for-syntax racket/base syntax/parse)) (define-syntax do (syntax-parser #:datum-literals (<- :) [(do bind:id body:expr) #'body] [(do bind:id [x1:id <- m1:expr] rst ... body...
null
https://raw.githubusercontent.com/stchang/macrotypes/05ec31f2e1fe0ddd653211e041e06c6c8071ffa6/macrotypes-example/macrotypes/examples/mlish-do.rkt
racket
#lang racket/base (provide do) (require (only-in "mlish.rkt" #%app λ Unit) (for-syntax racket/base syntax/parse)) (define-syntax do (syntax-parser #:datum-literals (<- :) [(do bind:id body:expr) #'body] [(do bind:id [x1:id <- m1:expr] rst ... body...
1b5d96111c931ac74ee68ba250c08a2d2b2c62b228717632f1b70f682e07f778
cyverse-archive/DiscoveryEnvironmentBackend
uuids.clj
(ns donkey.services.filesystem.uuids (:use [clj-jargon.metadata] [clj-jargon.permissions] [clojure-commons.validators] [slingshot.slingshot :only [throw+]] [donkey.services.filesystem.validators]) (:require [clojure.tools.logging :as log] [clj-icat-direct.icat :as icat] ...
null
https://raw.githubusercontent.com/cyverse-archive/DiscoveryEnvironmentBackend/7f6177078c1a1cb6d11e62f12cfe2e22d669635b/services/Donkey/src/donkey/services/filesystem/uuids.clj
clojure
(ns donkey.services.filesystem.uuids (:use [clj-jargon.metadata] [clj-jargon.permissions] [clojure-commons.validators] [slingshot.slingshot :only [throw+]] [donkey.services.filesystem.validators]) (:require [clojure.tools.logging :as log] [clj-icat-direct.icat :as icat] ...
1deb4209009be2f7e968288a16eb46fba8a36e0a62f5d125522054fa032b9134
svenssonjoel/Obsidian
Memory2.hs
2012 , 2013 Notes : - 2015 : Bug fix related to arrays alive when entering into loops . Fix seems to solve the problem . Need to investigate that it still frees arrays as soon as possible . Nov-25 - 2014 : Changes ...
null
https://raw.githubusercontent.com/svenssonjoel/Obsidian/90886a0ef513cdaa58bb63765c230fa193d1ef10/Obsidian/CodeGen/Memory2.hs
haskell
------------------------------------------------------------------------- Planned improvements ------------------------------------------------------------------------- # Always start a shared memory array at a "bank-aligned" address + So that programmer can really effect access patterns. # Do not rename with...
2012 , 2013 Notes : - 2015 : Bug fix related to arrays alive when entering into loops . Fix seems to solve the problem . Need to investigate that it still frees arrays as soon as possible . Nov-25 - 2014 : Changes ...
ee56879446abcedcd53c2ab27f21379db7ceea2e3df8126816bfa23f44d76ce3
5HT/ant
Group.mli
open ParseState; value begin_group : parse_state -> unit; value end_group : parse_state -> unit;
null
https://raw.githubusercontent.com/5HT/ant/6acf51f4c4ebcc06c52c595776e0293cfa2f1da4/Markup/Group.mli
ocaml
open ParseState; value begin_group : parse_state -> unit; value end_group : parse_state -> unit;
b9e2f46c44b6bef6573c9456c100b1f7f38eceb103798dfac8cb19093e5ace5b
lloda/guile-newra
base.scm
-*- mode : scheme ; coding : utf-8 -*- ( c ) 2016 - 2023 ; This library is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 3 of the License , or ( at your option ) any ; later version. ;;...
null
https://raw.githubusercontent.com/lloda/guile-newra/d6e76544e202ad69e8c38128c5518045bc09299b/mod/newra/base.scm
scheme
coding : utf-8 -*- This library is free software; you can redistribute it and/or modify it under either version 3 of the License , or ( at your option ) any later version. Commentary: Basic definitions for arrays. Code: for internal (newra) use, don't re-export from (newra) ---------------- Conventions -----...
( c ) 2016 - 2023 the terms of the GNU General Public License as published by the Free (define-module (newra base) #:export (ra? ra-root ra-zero ra-zero-set! ra-dims ra-type ra-vlen ra-vref ra-vset! ra-check ra-rank ra-type make-ra-new make-ra-root make-aseq a...
94b49fb932965d99f0294f8f521149e9847d28da1eb657a82c556ecbc0dc749e
kit-clj/kit
core.cljs
(ns <<ns-name>>.core (:require [reagent.core :as r] [reagent.dom :as d])) ;; ------------------------- ;; Views (defn home-page [] [:div [:h2 "Welcome to Reagent!"]]) ;; ------------------------- Initialize app (defn ^:dev/after-load mount-root [] (d/render [home-page] (.getElementById js/docu...
null
https://raw.githubusercontent.com/kit-clj/kit/320b920dcf25c33130f33b0e1cd55ff13f3157f6/libs/kit-generator/test/resources/modules/kit/cljs/assets/src/core.cljs
clojure
------------------------- Views -------------------------
(ns <<ns-name>>.core (:require [reagent.core :as r] [reagent.dom :as d])) (defn home-page [] [:div [:h2 "Welcome to Reagent!"]]) Initialize app (defn ^:dev/after-load mount-root [] (d/render [home-page] (.getElementById js/document "app"))) (defn ^:export ^:dev/once init! [] (mount-root))
c526809d785d2e1cb65e3eadc16c5cf7f47fb105eac0268608c74ab09f2311cc
passy/coding-puzzles
Main.hs
import Control.Applicative ((<$>)) import Control.Arrow import Control.Monad import Data.Char (digitToInt) import Debug.Trace import qualified Data.Map.Strict as Map wschars :: String wschars = " \t\r\n" strip :: String -> String strip = lstrip . rstrip ...
null
https://raw.githubusercontent.com/passy/coding-puzzles/686bd0775ee5a98004229d44c913376d033b13de/hackerrank/equivalent-passwords/Main.hs
haskell
| Same as 'strip', but applies only to the left side of the string. | Same as 'strip', but applies only to the right side of the string. Careful, I dropped the length check here since that invariant is controlled higher up.
import Control.Applicative ((<$>)) import Control.Arrow import Control.Monad import Data.Char (digitToInt) import Debug.Trace import qualified Data.Map.Strict as Map wschars :: String wschars = " \t\r\n" strip :: String -> String strip = lstrip . rstrip ...
bbd03f3289f57922aa11072d61585d91d29c91e70a014945f7d02b0f799a500a
sellout/haskerwaul
Right.hs
# language UndecidableInstances , UndecidableSuperClasses # , UndecidableSuperClasses #-} module Haskerwaul.Category.Monoidal.Rigid.Right ( module Haskerwaul.Category.Monoidal.Rigid.Right -- * extended modules , module Haskerwaul.Category.Monoidal ) where import Data.Kind (Ty...
null
https://raw.githubusercontent.com/sellout/haskerwaul/cf54bd7ce5bf4f3d1fd0d9d991dc733785b66a73/src/Haskerwaul/Category/Monoidal/Rigid/Right.hs
haskell
* extended modules | * references - [nLab](+monoidal+category) - [Wikipedia]() __NB__: Instances for this are automatically coalesced.
# language UndecidableInstances , UndecidableSuperClasses # , UndecidableSuperClasses #-} module Haskerwaul.Category.Monoidal.Rigid.Right ( module Haskerwaul.Category.Monoidal.Rigid.Right , module Haskerwaul.Category.Monoidal ) where import Data.Kind (Type) import Haskerwaul.C...
09728ae503d1c7126f2299ae6d4ba0138c898c5c0efa65c6ec60a944513d063e
camfort/fortran-src
Natural.hs
# LANGUAGE CPP # | Compatibility definitions for working with term and type level natural numbers across multiple GHC versions . Prior to GHC 9.2 : * Term level natural numbers : @Natural : : Type@ * Type level natural numbers : @n : : As of GHC 9.2 : * Term level natural numbers : @Natur...
null
https://raw.githubusercontent.com/camfort/fortran-src/43058030e2f6f9e5264b923134da0291e7ae807f/src/Language/Fortran/Repr/Compat/Natural.hs
haskell
# LANGUAGE CPP # | Compatibility definitions for working with term and type level natural numbers across multiple GHC versions . Prior to GHC 9.2 : * Term level natural numbers : @Natural : : Type@ * Type level natural numbers : @n : : As of GHC 9.2 : * Term level natural numbers : @Natur...
157996b31b0eecc6688bc712c76ad42aec59de8959407602af776b20a3864d49
tonsky/icfpc2019
generator.clj
(ns icfpc.generator (:require [icfpc.core :refer :all] [icfpc.level :refer :all] [icfpc.parser :as parser] [icfpc.writer :as writer])) (defn build-path [parents point] (loop [path [] current point depth 0] (if-let [parent (get parents current)] (if (or (< 10000 depth) (= par...
null
https://raw.githubusercontent.com/tonsky/icfpc2019/9f6869f78cc16ede79353a433b9aba93ecab8317/src/icfpc/generator.clj
clojure
(ns icfpc.generator (:require [icfpc.core :refer :all] [icfpc.level :refer :all] [icfpc.parser :as parser] [icfpc.writer :as writer])) (defn build-path [parents point] (loop [path [] current point depth 0] (if-let [parent (get parents current)] (if (or (< 10000 depth) (= par...
32a898c8c4ccb17f30b8ed22546bbce81ab27d904097859eac6b22e977dfea78
clojure-interop/java-jdk
HTMLFrameHyperlinkEvent.clj
(ns javax.swing.text.html.HTMLFrameHyperlinkEvent "HTMLFrameHyperlinkEvent is used to notify interested parties that link was activated in a frame." (:refer-clojure :only [require comment defn ->]) (:import [javax.swing.text.html HTMLFrameHyperlinkEvent])) (defn ->html-frame-hyperlink-event "Constructor. ...
null
https://raw.githubusercontent.com/clojure-interop/java-jdk/8d7a223e0f9a0965eb0332fad595cf7649d9d96e/javax.swing/src/javax/swing/text/html/HTMLFrameHyperlinkEvent.clj
clojure
(ns javax.swing.text.html.HTMLFrameHyperlinkEvent "HTMLFrameHyperlinkEvent is used to notify interested parties that link was activated in a frame." (:refer-clojure :only [require comment defn ->]) (:import [javax.swing.text.html HTMLFrameHyperlinkEvent])) (defn ->html-frame-hyperlink-event "Constructor. ...
919b037f6da34e141c4b7694e8019be4fb566d53bce66842b37b59f1d8fcad1b
namin/biohacker
sudoku.lisp
(defvar *puzzle* '#( #(4 0 0 0 0 0 8 0 5) #(0 3 0 0 0 0 0 0 0) #(0 0 0 7 0 0 0 0 0) #(0 2 0 0 0 0 0 6 0) #(0 0 0 0 8 0 4 0 0) #(0 0 0 0 1 0 0 0 0) #(0 0 0 6 0 3 0 7 0) #(5 0 0 2 0 0 0 0 0) #(1 0 4 0 0 0 0 0 0) )) (defvar *net* nil) (defun name (i j) (format nil "c...
null
https://raw.githubusercontent.com/namin/biohacker/6b5da4c51c9caa6b5e1a68b046af171708d1af64/BPS/relax/sudoku.lisp
lisp
(solve-sudoku *puzzle*)
(defvar *puzzle* '#( #(4 0 0 0 0 0 8 0 5) #(0 3 0 0 0 0 0 0 0) #(0 0 0 7 0 0 0 0 0) #(0 2 0 0 0 0 0 6 0) #(0 0 0 0 8 0 4 0 0) #(0 0 0 0 1 0 0 0 0) #(0 0 0 6 0 3 0 7 0) #(5 0 0 2 0 0 0 0 0) #(1 0 4 0 0 0 0 0 0) )) (defvar *net* nil) (defun name (i j) (format nil "c...
73e3c13c4f35c49f4a8b7c09d53a9c142ea4f55ce4a48b098b5ad1fe12a2c850
GillianPlatform/Gillian
ParserAndCompiler.mli
(** This defines an interface that allows a user to indicate how to parse their own programming language, preprocess the obtained language and compile it to GIL (type [Prog.t]) *) type ('annot, 'tl_ast, 'init_data) compiled_progs = { gil_progs : (string * ('annot, string) Prog.t) list; source_files : SourceFil...
null
https://raw.githubusercontent.com/GillianPlatform/Gillian/eaa028aaed7414c216b04ee25e0332dbc3d3cf8b/GillianCore/parserAndCompiler/ParserAndCompiler.mli
ocaml
* This defines an interface that allows a user to indicate how to parse their own programming language, preprocess the obtained language and compile it to GIL (type [Prog.t]) * Command line options specific to the target language. * A term that will be added to every command. * A side-effect function that will d...
type ('annot, 'tl_ast, 'init_data) compiled_progs = { gil_progs : (string * ('annot, string) Prog.t) list; source_files : SourceFiles.t; tl_ast : 'tl_ast; init_data : 'init_data; } module type S = sig module TargetLangOptions : sig type t val term : t Cmdliner.Term.t val apply : t -> unit en...
6175697de1c0eac6fa448e95c49ec73f8b9dbce18aa65c42a5e65a7f767db7c7
JacquesCarette/Drasil
Modules.hs
module Language.Drasil.Code.Imperative.Modules ( genMain, genMainFunc, chooseInModule, genInputClass, genInputDerived, genInputConstraints, genInputFormat, genConstMod, genConstClass, genCalcMod, genCalcFunc, genOutputMod, genOutputFormat, genSampleInput ) where import Language.Drasil (Constraint(..), RealInte...
null
https://raw.githubusercontent.com/JacquesCarette/Drasil/d9d9e7ac87131ccaae889029481cd34e0c0ad773/code/drasil-code/lib/Language/Drasil/Code/Imperative/Modules.hs
haskell
-- MAIN --- | Generates a controller module. | Generates a main function, to act as the controller for an SCS program. The controller declares input and constant variables, then calls the functions for reading input values, calculating derived inputs, checking constraints, calculating outputs, and printing outpu...
module Language.Drasil.Code.Imperative.Modules ( genMain, genMainFunc, chooseInModule, genInputClass, genInputDerived, genInputConstraints, genInputFormat, genConstMod, genConstClass, genCalcMod, genCalcFunc, genOutputMod, genOutputFormat, genSampleInput ) where import Language.Drasil (Constraint(..), RealInte...
e4becc56884116892edf19f4c5900f3f5dd08306a155286db2713795fb2c4d61
modular-macros/ocaml-macros
t254-offsetclosure.ml
open Lib;; let rec f _ = 11 and g _ = 0 and h _ = f in if h 3 4 <> 11 then raise Not_found ;; * 0 CONSTINT 42 2 PUSHACC0 3 MAKEBLOCK1 0 5 POP 1 7 9 BRANCH 22 11 CONSTINT 11 13 RETURN 1 15 CONST0 16 RETURN 1 18 OFFSE...
null
https://raw.githubusercontent.com/modular-macros/ocaml-macros/05372c7248b5a7b1aa507b3c581f710380f17fcd/testsuite/tests/tool-ocaml/t254-offsetclosure.ml
ocaml
open Lib;; let rec f _ = 11 and g _ = 0 and h _ = f in if h 3 4 <> 11 then raise Not_found ;; * 0 CONSTINT 42 2 PUSHACC0 3 MAKEBLOCK1 0 5 POP 1 7 9 BRANCH 22 11 CONSTINT 11 13 RETURN 1 15 CONST0 16 RETURN 1 18 OFFSE...
c736b1d826456187aa21e0a919d56da9348dfbc2a83d894fdb2acfa94b535735
metawilm/cl-python
aupprint.lisp
-*- Mode : LISP ; Syntax : COMMON - LISP ; Package : -*- ;; This software is Copyright ( c ) Franz Inc. and . Franz Inc. and grant you the rights to ;; distribute and use this software as governed by the terms of the Lisp Lesser GNU Public License ;; (), ;; known as the LLGPL. ;;;; A pretty printer, that ...
null
https://raw.githubusercontent.com/metawilm/cl-python/bce7f80b0c67d3c9f514556f2d14d098efecdde8/shared/aupprint.lisp
lisp
Syntax : COMMON - LISP ; Package : -*- distribute and use this software as governed by the terms (), known as the LLGPL. A pretty printer, that prints symbol `x' in the `clpython.ast' and It is the reverse of the `readtable.lisp'. prevent nil being printed as [nil]
This software is Copyright ( c ) Franz Inc. and . Franz Inc. and grant you the rights to of the Lisp Lesser GNU Public License ` clpython.user ' packages as [ x ] and { x } , respectively . (in-package :clpython) (defvar *ast-user-pprint-dispatch* (copy-pprint-dispatch nil)) (defvar *ast-user-print-delim...
377306a64c5689764baeece8df02d8cd30551793209ecb643a1bb30f4bd95fa0
hemmi/coq2scala
classops.ml
(************************************************************************) v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2012 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *...
null
https://raw.githubusercontent.com/hemmi/coq2scala/d10f441c18146933a99bf2088116bd213ac3648d/coq-8.4pl2-old/pretyping/classops.ml
ocaml
********************************************************************** // * This file is distributed under the terms of the * GNU Lesser General Public License Version 2.1 ********************************************************************** coercion_info : coe_typ -> coe_info...
v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2012 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * open Util open Pp open Flags ...
7626afe339421a457a609c08f8f84417fffa901700d0e914eaf73f274d5aefd9
soulomoon/SICP
Exercise 2.28.scm
Exercise 2.28 : Write a procedure fringe that takes as argument a tree ( represented as a list ) and returns a list whose elements are all the leaves of the tree arranged in left - to - right order . For example , (define (fringe l) (define (get_new_car x) (let ((cr (car x))) (if (pair? cr) ...
null
https://raw.githubusercontent.com/soulomoon/SICP/1c6cbf5ecf6397eaeb990738a938d48c193af1bb/Chapter2/Exercise%202.28.scm
scheme
(1 2 3 4) (1 2 3 4 1 2 3 4)
Exercise 2.28 : Write a procedure fringe that takes as argument a tree ( represented as a list ) and returns a list whose elements are all the leaves of the tree arranged in left - to - right order . For example , (define (fringe l) (define (get_new_car x) (let ((cr (car x))) (if (pair? cr) ...
30a52ea51e4dbd0a9d4467213ec752e14e2d3d462c2d217879d4525f7a5c686e
jiangpengnju/htdp2e
ex202.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 ex202) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decima...
null
https://raw.githubusercontent.com/jiangpengnju/htdp2e/d41555519fbb378330f75c88141f72b00a9ab1d3/arbitrarily-large-data/extended-exercises-lists/ex202.rkt
racket
about the language level of this file in a form that our tools can easily process. Modify your program from ex201 so that it stops if the worm has run into the walls of the world. When the program stops because of this condition, it should render the final scene with the text "worm hit border" in the lower left of ...
The first three lines of this file were inserted by . They record metadata #reader(lib "htdp-beginner-abbr-reader.ss" "lang")((modname ex202) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #f #t none #f () #f))) (require 2htdp/image) (require 2htdp/universe) (define R...
68e6b570f134bad43f59cd1c7db5c2f4a83013d7abef4d766fd4ef8e41d4f7e7
HugoPeters1024/hs-sleuth
Show.hs
# LANGUAGE CPP , MagicHash # # OPTIONS_GHC -fno - warn - orphans # #if __GLASGOW_HASKELL__ >= 702 # LANGUAGE Trustworthy # #endif -- | -- Module : Data.Text.Show Copyright : ( c ) 2009 - 2015 -- -- License : BSD-style -- Maintainer : -- Stability : experimental Portability : GHC module Data.Text...
null
https://raw.githubusercontent.com/HugoPeters1024/hs-sleuth/385655e62031959a14a3bac5e9ccd1c42c045f0c/test-project/text-1.2.4.0/Data/Text/Show.hs
haskell
| Module : Data.Text.Show License : BSD-style Maintainer : Stability : experimental | /O(n)/ Convert a 'Text' into a 'String'. Subject to fusion. | /O(n)/ Convert a literal string into a 'Text'. | /O(1)/ Convert a character into a Text. Subject to fusion. Performs replacement on invalid scala...
# LANGUAGE CPP , MagicHash # # OPTIONS_GHC -fno - warn - orphans # #if __GLASGOW_HASKELL__ >= 702 # LANGUAGE Trustworthy # #endif Copyright : ( c ) 2009 - 2015 Portability : GHC module Data.Text.Show ( singleton , unpack , unpackCString# ) where import Control.Monad.ST (ST) import Data...
0183a4d1d2f165b059e18b1cc61f5f75ecfa93bdfa991d77ba33234db3282c0a
exoscale/automata
view.cljc
(ns automata.view "Simplistic visualization builder. Leaves calling graphviz tools up to the caller") (defn identifier [x] (str \" (name x) \")) (defn ^:no-doc draw-transition "Single transition view builder" [[state transitions]] (for [{:automata.fsm/keys [event to]} transitions] (str (identifier ...
null
https://raw.githubusercontent.com/exoscale/automata/533135d7d33af706daef6cf58c846de623fa38b8/src/automata/view.cljc
clojure
(ns automata.view "Simplistic visualization builder. Leaves calling graphviz tools up to the caller") (defn identifier [x] (str \" (name x) \")) (defn ^:no-doc draw-transition "Single transition view builder" [[state transitions]] (for [{:automata.fsm/keys [event to]} transitions] (str (identifier ...
f2151638f576312f0fc35d291f91042231dca8dfdde623352320802500ef4dc9
avatar29A/hs-aitubots-api
Button.hs
# LANGUAGE DuplicateRecordFields # # LANGUAGE RecordWildCards # {-# LANGUAGE OverloadedStrings #-} module Aitu.Bot.Forms.Content.Button ( Button(..) , ButtonType(..) ) where import Data.Text import Data.Aeson hiding ( Options ...
null
https://raw.githubusercontent.com/avatar29A/hs-aitubots-api/9cc3fd1e4e9e81491628741a6bbb68afbb85704e/src/Aitu/Bot/Forms/Content/Button.hs
haskell
# LANGUAGE OverloadedStrings #
# LANGUAGE DuplicateRecordFields # # LANGUAGE RecordWildCards # module Aitu.Bot.Forms.Content.Button ( Button(..) , ButtonType(..) ) where import Data.Text import Data.Aeson hiding ( Options , defaultOptions ...
4aea278bd15d559c04bb5ee4543197afe228743b8a45df853050c5b17ce12e26
OlivierSohn/hamazed
DiscreteMorphing.hs
{-# OPTIONS_HADDOCK hide #-} # LANGUAGE NoImplicitPrelude # # LANGUAGE FlexibleInstances # module Imj.Graphics.Class.DiscreteMorphing ( DiscreteMorphing(..) -- * Reexport , module Imj.Graphics.Class.DiscreteDistance , module Imj.Graphics.Class.Drawable , module Imj.Graphics.C...
null
https://raw.githubusercontent.com/OlivierSohn/hamazed/c0df1bb60a8538ac75e413d2f5bf0bf050e5bc37/imj-base/src/Imj/Graphics/Class/DiscreteMorphing.hs
haskell
# OPTIONS_HADDOCK hide # * Reexport ^ last value ^ the current step
# LANGUAGE NoImplicitPrelude # # LANGUAGE FlexibleInstances # module Imj.Graphics.Class.DiscreteMorphing ( DiscreteMorphing(..) , module Imj.Graphics.Class.DiscreteDistance , module Imj.Graphics.Class.Drawable , module Imj.Graphics.Class.Draw ) where import Imj.Prelu...
4f961d118882504d8e154431500bd6c810ad81aaf071cc92e13c1b701e2dd632
RolfRolles/PandemicML
AVM2multiname_info.mli
open AVM2Pervasives (* *) type t = { kind: u8; data: u8 array; } val parse : prim_parser -> t
null
https://raw.githubusercontent.com/RolfRolles/PandemicML/9c31ecaf9c782dbbeb6cf502bc2a6730316d681e/Incubator/AVM2/AVM2multiname_info.mli
ocaml
open AVM2Pervasives type t = { kind: u8; data: u8 array; } val parse : prim_parser -> t
8cd441b02427bdfef5894934fc978bb4e089ae57e1af6b5e9f4f346d4599b9b5
ocramz/taco-hs
HOAS.hs
module Data.Tensor.Compiler.HOAS where data Expr a = Const a | Let (Expr a) (a -> Expr a) let_ :: Expr a -> (a -> Expr a) -> Expr a let_ = Let pprint expr = go expr 0 where go (Const x) _ = show x go (Let e f) c = unwords ["(let", v, "=", go e (c+1), "in", go (f c) (c+1), ")"] where v = "v" ...
null
https://raw.githubusercontent.com/ocramz/taco-hs/19d208e2ddc628835a816568cd32029fb0b85048/old/Data/Tensor/Compiler/HOAS.hs
haskell
qf = undefined
module Data.Tensor.Compiler.HOAS where data Expr a = Const a | Let (Expr a) (a -> Expr a) let_ :: Expr a -> (a -> Expr a) -> Expr a let_ = Let pprint expr = go expr 0 where go (Const x) _ = show x go (Let e f) c = unwords ["(let", v, "=", go e (c+1), "in", go (f c) (c+1), ")"] where v = "v" ...
163df7e7f0f14fffb801061fdaa4da29ebff5937dd8abd77c05ba99f320650e0
karamellpelle/grid
StepDT.hs
grid is a game written in Haskell Copyright ( C ) 2018 -- -- This file is part of grid. -- -- grid 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 optio...
null
https://raw.githubusercontent.com/karamellpelle/grid/56729e63ed6404fd6cfd6d11e73fa358f03c386f/designer/source/Game/Grid/StepDT.hs
haskell
This file is part of grid. grid is free software: you can redistribute it and/or modify (at your option) any later version. grid 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 GN...
grid is a game written in Haskell Copyright ( C ) 2018 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 module Game.Grid.StepDT ( defaultStepDT, ...
2f8318060981cf589555fa7d50a1b85b8553f407a09b6154ccc978c54f071a5c
jonase/eastwood
deprecated.clj
(ns eastwood.linters.deprecated (:require [eastwood.copieddeps.dep1.clojure.tools.analyzer.ast :as ast] [eastwood.passes :as pass]) (:import (java.lang.reflect Constructor Field Method))) (defn no-constructor-found [ctor-info] (when (map? ctor-info) (let [{:keys [arg-types]} ctor-info] (printl...
null
https://raw.githubusercontent.com/jonase/eastwood/605ab4a1d169270701200005792fa37b4c025405/src/eastwood/linters/deprecated.clj
clojure
this piece of metadata should generally be here, but might be dissoced for whatever reason
(ns eastwood.linters.deprecated (:require [eastwood.copieddeps.dep1.clojure.tools.analyzer.ast :as ast] [eastwood.passes :as pass]) (:import (java.lang.reflect Constructor Field Method))) (defn no-constructor-found [ctor-info] (when (map? ctor-info) (let [{:keys [arg-types]} ctor-info] (printl...
7cd4c3b2bbbcf91bd7e8d306765709e71b775b8a628285394c08b57057410165
uim/sigscheme
test-named-let.scm
;; Filename : test-named-let.scm About : unit test for R5RS named let ;; Copyright ( C ) 2005 - 2006 YAMAMOTO Kengo < yamaken AT > Copyright ( c ) 2007 - 2008 SigScheme Project < uim - en AT googlegroups.com > ;; ;; All rights reserved. ;; ;; Redistribution and use in source and binary forms, with or w...
null
https://raw.githubusercontent.com/uim/sigscheme/ccf1f92d6c2a0f45c15d93da82e399c2a78fe5f3/test/test-named-let.scm
scheme
Filename : test-named-let.scm 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 ...
About : unit test for R5RS named let Copyright ( C ) 2005 - 2006 YAMAMOTO Kengo < yamaken AT > Copyright ( c ) 2007 - 2008 SigScheme Project < uim - en AT googlegroups.com > 1 . Redistributions of source code must retain the above copyright 2 . Redistributions in binary form must reproduce the above...
a779a576c4b9954ee66a4d55b4c5f86af757fc28230763169e95fd988cd46780
nextjournal/clerk-demo
images.clj
# 🏞 Automatic Image Support ^{:nextjournal.clerk/visibility #{:hide-ns}} (ns images (:require [nextjournal.clerk :as clerk] [clojure.java.io :as io]) (:import [java.net URL] [java.nio.file Paths Files] [java.awt.image BufferedImage] [javax.imageio ImageIO])) ;; Clerk...
null
https://raw.githubusercontent.com/nextjournal/clerk-demo/3ccf0697a44908458d13485fbaf2ff680f7f25de/notebooks/images.clj
clojure
Clerk now has built-in support for the When combined with `javax.imageio.ImageIO/read`, one can easily load images in a variety of formats from a `java.io.File`, an `java.io.InputStream`, or any resource that a `java.net.URL` can address. Gogh's famous painting of a farmer sowing a field from Wiki Commons like t...
# 🏞 Automatic Image Support ^{:nextjournal.clerk/visibility #{:hide-ns}} (ns images (:require [nextjournal.clerk :as clerk] [clojure.java.io :as io]) (:import [java.net URL] [java.nio.file Paths Files] [java.awt.image BufferedImage] [javax.imageio ImageIO])) ` java...
2c6ee83ec39e54d8346fefc89d73b4a489ea03ef5e8df722080fb33da73bda09
tanrax/calculate-wordpress-usage
project.clj
(defproject wordpress-used "1.0.0-SNAPSHOT" :description "Calculates WordPress usage index from a CSV list of domains" :url "" :license {:name "EPL-2.0 OR GPL-2.0-or-later WITH Classpath-exception-2.0" :url "-2.0/"} :dependencies [[org.clojure/clojure "1.10.0"] [clj-http "3.10.0"] ...
null
https://raw.githubusercontent.com/tanrax/calculate-wordpress-usage/fa9fa1dca65c4fdb673ed86acfbbb212c5ae8ff9/project.clj
clojure
(defproject wordpress-used "1.0.0-SNAPSHOT" :description "Calculates WordPress usage index from a CSV list of domains" :url "" :license {:name "EPL-2.0 OR GPL-2.0-or-later WITH Classpath-exception-2.0" :url "-2.0/"} :dependencies [[org.clojure/clojure "1.10.0"] [clj-http "3.10.0"] ...
226dd34a8c955244c69462fcae535683569380312a720a9fc6265fda1bc5f035
gfZeng/time.clj
core_test.cljs
(ns time.core-test (:require [time.core :as t])) (def m (js/require "moment")) (println (re-find #"[^']+" "'年'")) (time (dotimes [_ 1000] (re-find #"[^']+" "'年'"))) (time (dotimes [_ 1000] (first "yyyy"))) (println (t/format (t/date) "yyyy'年'MM'月'dd'日' HH'时'mm'分'ss'秒'")) (time (dotimes [_ 10000...
null
https://raw.githubusercontent.com/gfZeng/time.clj/874bb2c7a1b4debc07818f4a25e241f8cfa8c5f8/test/time/core_test.cljs
clojure
(ns time.core-test (:require [time.core :as t])) (def m (js/require "moment")) (println (re-find #"[^']+" "'年'")) (time (dotimes [_ 1000] (re-find #"[^']+" "'年'"))) (time (dotimes [_ 1000] (first "yyyy"))) (println (t/format (t/date) "yyyy'年'MM'月'dd'日' HH'时'mm'分'ss'秒'")) (time (dotimes [_ 10000...
f66f7e886a5310fb1276e093f6bba781ce1210fc44bb9c6eb735e628f16c0f23
racehub/om-bootstrap
live.cljs
#_ (:require [om-bootstrap.modal :as md]) (defn trigger [app-state owner] (reify om/IInitState (init-state [_] {:visible? false}) om/IRender (render [_] (d/div (md/modal {:header (d/h4 "This is a Modal") :footer (d/div (b/button {} "Save") ...
null
https://raw.githubusercontent.com/racehub/om-bootstrap/18fb7f67c306d208bcb012a1b765ac1641d7a00b/dev/snippets/modal/live.cljs
clojure
#_ (:require [om-bootstrap.modal :as md]) (defn trigger [app-state owner] (reify om/IInitState (init-state [_] {:visible? false}) om/IRender (render [_] (d/div (md/modal {:header (d/h4 "This is a Modal") :footer (d/div (b/button {} "Save") ...
962aedafb06672c59ba30ae9941caf412a40db5ba103889a95706eb3b4dffd29
commercialhaskell/curator
UploadDocs.hs
# LANGUAGE FlexibleContexts # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE ViewPatterns # module Curator.UploadDocs ( uploadDocs ) where import Conduit import Pantry hiding (SHA256) import RIO import qualified RIO.Directory as D import qualified RIO.FilePath as F import RIO.List (stripPrefix) import qualified...
null
https://raw.githubusercontent.com/commercialhaskell/curator/4ae7a59717f163e15c69ddf75d31d0f775de2561/src/Curator/UploadDocs.hs
haskell
# LANGUAGE OverloadedStrings # ^ directory containing docs ^ name of current docs, used as prefix in object names ^ bucket name
# LANGUAGE FlexibleContexts # # LANGUAGE ViewPatterns # module Curator.UploadDocs ( uploadDocs ) where import Conduit import Pantry hiding (SHA256) import RIO import qualified RIO.Directory as D import qualified RIO.FilePath as F import RIO.List (stripPrefix) import qualified RIO.Set as Set import qualified RI...
05825b238adee4e37a13ad0d9e4e1b816b8204f9fd9259dcdd0da52f93804138
sunshineclt/Racket-Helper
homework10-1.rkt
#lang racket (require compatibility/mlist) (define (eval exp env) ((analyze exp) env)) (define (analyze exp) ;返回值是一个可执行函数(不是源代码形式的也不是函数对象), 以环境为参数。 (cond ((self-evaluating? exp) (analyze-self-evaluating exp)) ((quoted? exp) (analyze-quoted exp)) ((variable? exp) (analyze-variable exp)) ...
null
https://raw.githubusercontent.com/sunshineclt/Racket-Helper/bf85f38dd8d084db68265bb98d8c38bada6494ec/%E9%99%88%E4%B9%90%E5%A4%A9/Week10/homework10-1.rkt
racket
返回值是一个可执行函数(不是源代码形式的也不是函数对象), 以环境为参数。 simple number?是scheme基本过程 string?是scheme基本过程 symbol?是scheme基本过程 set define exp形如(define ....) 针对第一种形式 针对第一种形式 formal parameters body lambda 构造一个lambda表达式 if begin 把表达式列表变成一个表达式 cond , 如 ( ( > x 3 ) ( + x 3 ) ( * x 3 ) ) no else clause application eval-many procedure frame envi...
#lang racket (require compatibility/mlist) (define (eval exp env) ((analyze exp) env)) (cond ((self-evaluating? exp) (analyze-self-evaluating exp)) ((quoted? exp) (analyze-quoted exp)) ((variable? exp) (analyze-variable exp)) ((assignment? exp) (analyze-assignment exp)) ((...
202d72010cefb86bf09a138390ed4bfd718bed868db73918775c06e5e8b849ba
epiccastle/bbssh
utils.clj
(ns bbssh.impl.utils (:require [clojure.string :as string]) (:import [java.util Base64 Base64$Encoder Base64$Decoder])) (set! *warn-on-reflection* true) (defn to-camel-case [^String a] (apply str (map string/capitalize (.split (name a) "-")))) #_ (to-camel-case "one-two-three") #_ (to-camel-case "one") (defn ...
null
https://raw.githubusercontent.com/epiccastle/bbssh/a77869e2c3f4dfc32d93fd51b046a01e3c458e34/src/clj/bbssh/impl/utils.clj
clojure
(ns bbssh.impl.utils (:require [clojure.string :as string]) (:import [java.util Base64 Base64$Encoder Base64$Decoder])) (set! *warn-on-reflection* true) (defn to-camel-case [^String a] (apply str (map string/capitalize (.split (name a) "-")))) #_ (to-camel-case "one-two-three") #_ (to-camel-case "one") (defn ...
dcaa853f2b5f90d86da77ecc765476c2674ddfa05bd2470e57df3cba5632de93
Vetd-Inc/vetd-app
fx.cljs
(ns vetd-app.orgs.fx (:require [re-frame.core :as rf])) (rf/reg-event-fx :o/invite-user-to-org (fn [{:keys [db]} [_ email org-id from-user-id]] {:ws-send {:payload {:cmd :invite-user-to-org :return {:handler :o/invite-user-to-org-return :email email} ...
null
https://raw.githubusercontent.com/Vetd-Inc/vetd-app/9b33b1443b9d84d39305a63fc58119f8e014cf11/src/cljs/app/vetd_app/orgs/fx.cljs
clojure
(ns vetd-app.orgs.fx (:require [re-frame.core :as rf])) (rf/reg-event-fx :o/invite-user-to-org (fn [{:keys [db]} [_ email org-id from-user-id]] {:ws-send {:payload {:cmd :invite-user-to-org :return {:handler :o/invite-user-to-org-return :email email} ...
521a34201fc0d427c6eed03072d0651feee5093f549ec85c33ca9707e466fd53
mirage/colombe
fuzz.ml
open Crowbar let ( <.> ) f g x = f (g x) let char_from_alphabet alphabet = map [ range (String.length alphabet) ] (String.make 1 <.> String.get alphabet) let string_from_alphabet alphabet len = let rec go acc = function | 0 -> concat_gen_list (const "") acc | n -> go (char_from_alphabet alphabet :: acc) ...
null
https://raw.githubusercontent.com/mirage/colombe/bbecbb17b581fa1db70a61de14efb51a66f30451/fuzz/fuzz.ml
ocaml
TODO: [`String]
open Crowbar let ( <.> ) f g x = f (g x) let char_from_alphabet alphabet = map [ range (String.length alphabet) ] (String.make 1 <.> String.get alphabet) let string_from_alphabet alphabet len = let rec go acc = function | 0 -> concat_gen_list (const "") acc | n -> go (char_from_alphabet alphabet :: acc) ...
20bbabbebb2d629c9a4b5d95edb319ab91781ff25013c834e5da18aa5adfa347
rbkmoney/cds
cds_card_v2_client.erl
-module(cds_card_v2_client). -include_lib("cds_proto/include/cds_proto_storage_thrift.hrl"). -include_lib("cds_proto/include/cds_proto_base_thrift.hrl"). -export([get_card_data/2]). -export([put_card_and_session/3]). -export([get_session_data/2]). -export([get_session_card_data/3]). -export([put_card/2]). -export([pu...
null
https://raw.githubusercontent.com/rbkmoney/cds/6e6541c99d34b0633775f0c5304f5008e6b2aaf3/apps/cds/test/cds_card_v2_client.erl
erlang
Internal types API NOTE: This method added for backward compatibility with client v1 tests.
-module(cds_card_v2_client). -include_lib("cds_proto/include/cds_proto_storage_thrift.hrl"). -include_lib("cds_proto/include/cds_proto_base_thrift.hrl"). -export([get_card_data/2]). -export([put_card_and_session/3]). -export([get_session_data/2]). -export([get_session_card_data/3]). -export([put_card/2]). -export([pu...
f3eefdd59fc9440d8f64df038b8abd6ef3abc154f6037f863850d537e33fa418
alanz/ghc-exactprint
TH_localname.hs
{-# LANGUAGE TemplateHaskellQuotes #-} module TH_localname where x = \y -> [| y |]
null
https://raw.githubusercontent.com/alanz/ghc-exactprint/b6b75027811fa4c336b34122a7a7b1a8df462563/tests/examples/ghc80/TH_localname.hs
haskell
# LANGUAGE TemplateHaskellQuotes #
module TH_localname where x = \y -> [| y |]
95a0cdf5b7cddd175a6b7fd25b5287de9f35a74255408c0d1378317e527af553
jackfirth/rebellion
mutable-red-black-tree-invariants.rkt
#lang racket/base (module+ test (provide check-mutable-rb-tree-structurally-equal? check-mutable-rb-tree-invariants)) (module+ test (require rackunit rebellion/collection/private/mutable-red-black-tree-base rebellion/private/guarded-block)) ;@---------------------------------------...
null
https://raw.githubusercontent.com/jackfirth/rebellion/206ced365b07d1c6da5dcbe93f892fbb9bd7ba72/collection/private/testing/mutable-red-black-tree-invariants.rkt
racket
@---------------------------------------------------------------------------------------------------- Checks the red-black tree invariants: that red nodes only have black children, and that every path from the root to a leaf must traverse the same number of black nodes.
#lang racket/base (module+ test (provide check-mutable-rb-tree-structurally-equal? check-mutable-rb-tree-invariants)) (module+ test (require rackunit rebellion/collection/private/mutable-red-black-tree-base rebellion/private/guarded-block)) (module+ test (define-check (check-m...
b3388ff2d6177bf43c775b9d63163062f8ac653f19d68f320d4698ec4462dffd
exercism/clojure
triangle.clj
(ns triangle) (defn is-valid? [] ;; <- arglist goes here ;; your code goes here ) (defn equilateral? [] ;; <- arglist goes here ;; your code goes here ) (defn isosceles? [] ;; <- arglist goes here ;; your code goes here ) (defn scalene? [] ;; <- arglist goes here ;; your code goes here )
null
https://raw.githubusercontent.com/exercism/clojure/7ed96a5ae3c471c37db2602baf3db2be3b5a2d1a/exercises/practice/triangle/src/triangle.clj
clojure
<- arglist goes here your code goes here <- arglist goes here your code goes here <- arglist goes here your code goes here <- arglist goes here your code goes here
(ns triangle) ) ) ) )
012a6d8b68cf03d640c9b803c745f7d317a753eaca5763e4e313e4cc04e2763b
mattmundell/nightshade
css.lisp
;;; Cascading Style Sheet (CSS) support. ;; ;; FIX add comment parsing (in-package "CSS") (export '(css parse-css style style-property)) (eval-when (compile eval load) (parse:defparser ;; FIX too much of this is spent handling the space cases `((:css (any :css-space :css-style :css-space)) ...
null
https://raw.githubusercontent.com/mattmundell/nightshade/68e960eff95e007462f2613beabc6cac11e0dfa1/src/code/css.lisp
lisp
Cascading Style Sheet (CSS) support. FIX add comment parsing FIX too much of this is spent handling the space cases ) :css-space :css-property :css-space) ) :css-space #\} #\newline))))))) eval-when (compile eval load) FIX sounds like style (verb) property (noun). get/return-style-property?
(in-package "CSS") (export '(css parse-css style style-property)) (eval-when (compile eval load) (parse:defparser `((:css (any :css-space :css-style :css-space)) (:css-style :css-style-name :css-space (any #\, :css-space :css-style-name :css-space) #\{ :css-spac...
9b40f7c74c19c5e3b53670af20b1919dd59121b6af7fad1cf06595c12f00afdd
erleans/erleans
erleans_providers.erl
-module(erleans_providers). -behaviour(gen_server). -export([start_link/0, default/0, provider/1]). -export([init/1, handle_call/3, handle_cast/2]). -include_lib("kernel/include/logger.hrl"). -record(state, {providers :: term()}). start_link() -> gen_server:start_link({loca...
null
https://raw.githubusercontent.com/erleans/erleans/7d640d84654b45a27399ca258406c31005d600df/src/erleans_providers.erl
erlang
start provider as child of erleans_provider_sup handle crash here so application stops with good error message?
-module(erleans_providers). -behaviour(gen_server). -export([start_link/0, default/0, provider/1]). -export([init/1, handle_call/3, handle_cast/2]). -include_lib("kernel/include/logger.hrl"). -record(state, {providers :: term()}). start_link() -> gen_server:start_link({loca...
81d99b52f3913ef4ba5ec55e0c91ef5c738ee005517f3fcfa38b70bf020416e8
google/mlir-hs
BuilderSpec.hs
Copyright 2021 Google LLC -- Licensed under the Apache License , Version 2.0 ( the " License " ) ; -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- -2.0 -- -- Unless required by applicable law or agreed to in writing, software distributed un...
null
https://raw.githubusercontent.com/google/mlir-hs/1063e17154ef927f531b756ed6e0d080ec43f22a/test/MLIR/BuilderSpec.hs
haskell
you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing per...
Copyright 2021 Google LLC Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , module MLIR.BuilderSpec where import Test.Hspec import Control.Monad.Identity import MLIR.AST import MLIR.AST.Builder import MLIR.AST.Serialize i...
30b9d62ef237b511d62ac08fdbf8ec5887cabef373bedc6b4e260ef7b9ff7289
coccinelle/coccinelle
asttomember.ml
* This file is part of Coccinelle , licensed under the terms of the GPL v2 . * See copyright.txt in the Coccinelle source code for more information . * The Coccinelle source code can be obtained at * This file is part of Coccinelle, licensed under the terms of the GPL v2. * See copyright.txt in the Cocci...
null
https://raw.githubusercontent.com/coccinelle/coccinelle/2d0014efa4c67f4c3b4687cbcddef7456bad9aac/engine/asttomember.ml
ocaml
contains an inherited metavariable or contains a constant --------------------------------------------------------------------- --------------------------------------------------------------------- drop all distinguishing information from a term except inherited variables, which are used to improve efficiency...
* This file is part of Coccinelle , licensed under the terms of the GPL v2 . * See copyright.txt in the Coccinelle source code for more information . * The Coccinelle source code can be obtained at * This file is part of Coccinelle, licensed under the terms of the GPL v2. * See copyright.txt in the Cocci...