_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
ab538d3b27e278db78cd5e21a90e7c84af1dd6e3667989cc598774adea288188
lingnand/VIMonad
Selective.hs
# LANGUAGE NoMonomorphismRestriction # {-# LANGUAGE ScopedTypeVariables, FlexibleInstances #-} module Selective where -- Tests for limitSelect-related code in L.LimitWindows. To run these tests , export ( select , update , Selection( .. ),updateAndSelect ) from -- L.LimitWindows. import XMonad.Layout.LimitWindows i...
null
https://raw.githubusercontent.com/lingnand/VIMonad/048e419fc4ef57a5235dbaeef8890faf6956b574/XMonadContrib/tests/Selective.hs
haskell
# LANGUAGE ScopedTypeVariables, FlexibleInstances # Tests for limitSelect-related code in L.LimitWindows. L.LimitWindows. as many windows as possible should be selected (when the selection is normalized) update normalizes selections (is idempotent) select selects the master pane the focus should always be selec...
# LANGUAGE NoMonomorphismRestriction # module Selective where To run these tests , export ( select , update , Selection( .. ),updateAndSelect ) from import XMonad.Layout.LimitWindows import XMonad.StackSet hiding (focusUp, focusDown, filter) import Control.Applicative ((<$>)) import Test.QuickCheck import Control.A...
e1792cbd7d706a68eebcee3bb084fa4d811679efa440ad5184ae62037a7e68bc
fission-codes/fission
Handler.hs
module Fission.CLI.Handler ( module Fission.CLI.Handler.App.Delegate , module Fission.CLI.Handler.App.Info , module Fission.CLI.Handler.App.Init , module Fission.CLI.Handler.App.Publish -- , module Fission.CLI.Handler.Generate.Credentials -- , module Fission.CLI.Handler.User.Login , module Fission.CLI...
null
https://raw.githubusercontent.com/fission-codes/fission/afaae0dc5f83f4e35a3d4fdbdea2608a8d49bef8/fission-cli/library/Fission/CLI/Handler.hs
haskell
module Fission.CLI.Handler ( module Fission.CLI.Handler.App.Delegate , module Fission.CLI.Handler.App.Info , module Fission.CLI.Handler.App.Init , module Fission.CLI.Handler.App.Publish , module Fission.CLI.Handler.Generate.Credentials , module Fission.CLI.Handler.User.Login , module Fission.CLI.Handler.U...
ac1ca9e9b75cf4368fc8cc25d9dcb29ce89f27d58ed6851f2490a87ac64c1ada
datalogisk-fagraad/DIKUNotes
district_qc.erl
-module(district_qc). -export([ex/0, territory/0, setup_territory/1]). -export([prop_activate/0, prop_take_action/0]). -include_lib("eqc/include/eqc.hrl"). % Choose between SIZE different districts -define(SIZE, 10). % ok, so I run quickcheck tests by running the command: eqc : : territory ( ) ) % Used for conne...
null
https://raw.githubusercontent.com/datalogisk-fagraad/DIKUNotes/fb0487d62599e37bf94da4dab3f63728e0c4c4c8/Advanced%20Programming%20(AP)/2018%20Exam%20and%20Solution/handin/ravnica/district_qc.erl
erlang
Choose between SIZE different districts ok, so I run quickcheck tests by running the command: Used for connections between districts. DOCUMENTATION ON ?LET Generate integet between 1 and SIZE Is the neighbour already created? if so, we just connect and go on otherwise, we have to create the neighbour before con...
-module(district_qc). -export([ex/0, territory/0, setup_territory/1]). -export([prop_activate/0, prop_take_action/0]). -include_lib("eqc/include/eqc.hrl"). -define(SIZE, 10). eqc : : territory ( ) ) atom() -> elements([a,b,c,d,e,f,g,h,i,j,k,l]). Generates a value from G1 , binds it to , then generates a valu...
256178547a97187f1e423d1c9deebefcce6497d88ba9ae27dbe2da96b944e73d
matijapretnar/eff
skeleton.ml
open Utils module TyParam = TyParam.TyParam (** skeleton parameters *) module Param = Symbol.Make (Symbol.Parameter (struct let ascii_symbol = "skl" let utf8_symbol = "ς" end)) type t = | Param of Param.t | Basic of Const.ty | Arrow of t * t | Apply of { ty_name : TyName.t; skel_args : t TyParam.Map.t } ...
null
https://raw.githubusercontent.com/matijapretnar/eff/1be07f0c7fbaadf5c28437bf11fe818aa76640e7/src/01-language/skeleton.ml
ocaml
* skeleton parameters
open Utils module TyParam = TyParam.TyParam module Param = Symbol.Make (Symbol.Parameter (struct let ascii_symbol = "skl" let utf8_symbol = "ς" end)) type t = | Param of Param.t | Basic of Const.ty | Arrow of t * t | Apply of { ty_name : TyName.t; skel_args : t TyParam.Map.t } | Handler of t * t | Tu...
ffe5324d78e724ea97f088417a3f809af0391ab217e04b9bceb78e387c4da374
mclumd/Meta-AQUA
loader.lisp
(in-package :user) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; ;;;; The Meta-AQUA Introspective Multistrategy Learning System ;;;; Version 6 ;;;; META - AQUA SYSTEM LOADER ;;; Copyright ( C ) 1996 ( ) ;;; ;;; IMPORTANT, YOU MUS...
null
https://raw.githubusercontent.com/mclumd/Meta-AQUA/e4d4f83330fd07d1354aec245a49bde9e246c618/loader.lisp
lisp
The Meta-AQUA Introspective Multistrategy Learning System Version 6 IMPORTANT, YOU MUST CHANGE THE *Meta-AQUA-system-dir* VARIABLE BELOW. YOU CAN ACCOMPLISH THIS WITHOUT RECOMPILING THE CODE OR CHANGING THE SOURCE BY *MUST* CHANGE THE :default-pathname VALUE IN THE DEFSYSTEM BELOW ...
(in-package :user) META - AQUA SYSTEM LOADER Copyright ( C ) 1996 ( ) PLACING A SETF CALL IN YOUR .clinit.cl INITIALIZATION FILE . HOWEVER YOU EXPLICITLY . under the terms of the GNU General Public License as published by the Free You should have received a copy of...
e9bb6c70b994b883a2649d9c8b42dc9bc8e55a54ced0963f76aa3286c9d63b57
moby/datakit
cI_static.mli
val read : string -> string option to avoid warning 32 val file_list : string list
null
https://raw.githubusercontent.com/moby/datakit/e047e55a2dfa3aaec02398d7d7699f4f7afd2b47/ci/src/cI_static.mli
ocaml
val read : string -> string option to avoid warning 32 val file_list : string list
b2ab42d4aff7152587080b730d48ddceb51ecf7593c286855e4f8631484f0aec
uwplse/coq-plugin-lib
typehofs.ml
(* * Utilities for types *) open Reducers (* --- Higher-order functions --- *) (* Apply on types instead of on terms; use the supplied reducer to reduce *) let on_red_type r f env sigma trm = let sigma, typ = reduce_type_using r env sigma trm in f env sigma typ Instantiations of on_type_red let on_re...
null
https://raw.githubusercontent.com/uwplse/coq-plugin-lib/b249fc1954e2f1bc0b776e2d06e8ec1fc4d48ad9/src/coq/logicutils/hofs/typehofs.ml
ocaml
* Utilities for types --- Higher-order functions --- Apply on types instead of on terms; use the supplied reducer to reduce
open Reducers let on_red_type r f env sigma trm = let sigma, typ = reduce_type_using r env sigma trm in f env sigma typ Instantiations of on_type_red let on_red_type_default f env sigma trm = on_red_type reduce_term f env sigma trm let on_type f env sigma trm = on_red_type do_not_reduce f env sigm...
b8ee6a32545958de95717a67b7d0b26524f82a82bb2b35fc41c32ed763d17a33
TrustInSoft/tis-kernel
mergemap.mli
(**************************************************************************) (* *) This file is part of . (* *) is a fork of Frama - C. Al...
null
https://raw.githubusercontent.com/TrustInSoft/tis-kernel/748d28baba90c03c0f5f4654d2e7bb47dfbe4e7d/src/plugins/wp/qed/src/mergemap.mli
ocaml
************************************************************************ ...
This file is part of . is a fork of Frama - C. All the differences are : Copyright ( C ) 2016 - 2017 is released under GPLv2 This file is part of WP plug - in of Frama - C. Copyright ( C ) 2007 - 2015 ...
a45ddbdadfd53ed5e77fe7c33988287f952986254168f7b53ed9496a6cb83e6d
lingnand/VIMonad
FloatNext.hs
{-# LANGUAGE DeriveDataTypeable #-} ----------------------------------------------------------------------------- -- | -- Module : XMonad.Hooks.FloatNext Copyright : < > -- License : BSD-style (see LICENSE) -- -- Maintainer : orphaned -- Stability : unstable -- Portability : unportable -- -- ...
null
https://raw.githubusercontent.com/lingnand/VIMonad/048e419fc4ef57a5235dbaeef8890faf6956b574/XMonadContrib/XMonad/Hooks/FloatNext.hs
haskell
# LANGUAGE DeriveDataTypeable # --------------------------------------------------------------------------- | Module : XMonad.Hooks.FloatNext License : BSD-style (see LICENSE) Maintainer : orphaned Stability : unstable Portability : unportable Hook and keybindings for automatically sending the...
Copyright : < > floatNextHook , floatNext , toggleFloatNext , floatAllNew , toggleFloatAllNew , willFloatNext ...
0c8093fe3e12a1f7842a4c5e73879f42993318c82d870ff4af2e975f3b363d76
plumatic/om-tools
util_test.clj
(ns om-tools.util-test (:require [om-tools.util :as util] [clojure.test :refer :all])) (deftest possibly-destructured?-test (are [form] (util/possibly-destructured? :foo form) '[foo] '[foo bar] '[bar foo] '[[:foo bar]] '[[:foo [:bar baz]]] '[bar :as m]) (are [form]...
null
https://raw.githubusercontent.com/plumatic/om-tools/e7bc536e16f28bd6125550ab3d2bff62393a6a7c/test/om_tools/util_test.clj
clojure
(ns om-tools.util-test (:require [om-tools.util :as util] [clojure.test :refer :all])) (deftest possibly-destructured?-test (are [form] (util/possibly-destructured? :foo form) '[foo] '[foo bar] '[bar foo] '[[:foo bar]] '[[:foo [:bar baz]]] '[bar :as m]) (are [form]...
8218625f0385f982ce0f1f12d2d10e0cc746e83bdac9a34d380532ac8661c428
sharplispers/ironclad
ed448.lisp
;;;; -*- mode: lisp; indent-tabs-mode: nil -*- ;;;; ed448.lisp -- implementation of the ed448 signature algorithm (in-package :crypto) ;;; class definitions (defclass ed448-public-key () ((y :initarg :y :reader ed448-key-y :type (simple-array (unsigned-byte 8) (*))))) (defclass ed448-private-key () ((x :initar...
null
https://raw.githubusercontent.com/sharplispers/ironclad/6cc4da8554558ee2e89ea38802bbf6d83100d4ea/src/public-key/ed448.lisp
lisp
-*- mode: lisp; indent-tabs-mode: nil -*- ed448.lisp -- implementation of the ed448 signature algorithm class definitions Internally, a point (x, y) is represented using the projective coordinates (X, Y, Z), with x = X / Z and y = Y / Z. constant and function definitions Ed448 (x = 0), no context (y = #())
(in-package :crypto) (defclass ed448-public-key () ((y :initarg :y :reader ed448-key-y :type (simple-array (unsigned-byte 8) (*))))) (defclass ed448-private-key () ((x :initarg :x :reader ed448-key-x :type (simple-array (unsigned-byte 8) (*))) (y :initarg :y :reader ed448-key-y :type (simple-array (unsigned...
22f9876e5a27f4a9aeda67e872b9b9dd5524f8934e772dec5df9258e321a3cb1
hgoes/smtlib2
Struct.hs
module Language.SMTLib2.Internals.Type.Struct where import Language.SMTLib2.Internals.Type.Nat import Language.SMTLib2.Internals.Type.List (List(..)) import qualified Language.SMTLib2.Internals.Type.List as List import Prelude hiding (mapM,insert) import Data.GADT.Compare import Data.GADT.Show import Data.Functor.Ide...
null
https://raw.githubusercontent.com/hgoes/smtlib2/c35747f2a5a9ec88dc7b1db41a5aab6e98c0458d/Language/SMTLib2/Internals/Type/Struct.hs
haskell
module Language.SMTLib2.Internals.Type.Struct where import Language.SMTLib2.Internals.Type.Nat import Language.SMTLib2.Internals.Type.List (List(..)) import qualified Language.SMTLib2.Internals.Type.List as List import Prelude hiding (mapM,insert) import Data.GADT.Compare import Data.GADT.Show import Data.Functor.Ide...
e626cdcb3a978d4d61f14929a8b6e326e7b4d134ce3c2c7ceae1eaf8d1cdd7a7
sdiehl/elliptic-curve
Edwards.hs
module Test.Edwards where import Protolude import qualified Data.Curve.Edwards.Curve1174 as Curve1174 import qualified Data.Curve.Edwards.Curve41417 as Curve41417 import qualified Data.Curve.Edwards.E222 as E222 import qualified Data.Curve.Edwards.E382 as E382 import qualified Data.Curve.Edwards.E521 ...
null
https://raw.githubusercontent.com/sdiehl/elliptic-curve/445e196a550e36e0f25bd4d9d6a38676b4cf2be8/test/Test/Edwards.hs
haskell
module Test.Edwards where import Protolude import qualified Data.Curve.Edwards.Curve1174 as Curve1174 import qualified Data.Curve.Edwards.Curve41417 as Curve41417 import qualified Data.Curve.Edwards.E222 as E222 import qualified Data.Curve.Edwards.E382 as E382 import qualified Data.Curve.Edwards.E521 ...
9d6604916be37ff1975a5e622a76c63c34f67acbde02e529d07d8212e5e35865
bendyworks/api-server
PendingUserResource.hs
# OPTIONS_GHC -fno - warn - orphans # {-# LANGUAGE TypeSynonymInstances #-} module Api.Types.PendingUserResource ( PendingUCFields (..) , PendingUserResource (..) ) where import Api.Helpers.Controller (FromParams (..), reqParam) import Control.Applicative ((<$>), (<*>)) import Hasql (RowParser, parseRow) import Hasql...
null
https://raw.githubusercontent.com/bendyworks/api-server/9dd6d7c2599bd1c5a7e898a417a7aeb319415dd2/lib/Api/Types/PendingUserResource.hs
haskell
# LANGUAGE TypeSynonymInstances #
# OPTIONS_GHC -fno - warn - orphans # module Api.Types.PendingUserResource ( PendingUCFields (..) , PendingUserResource (..) ) where import Api.Helpers.Controller (FromParams (..), reqParam) import Control.Applicative ((<$>), (<*>)) import Hasql (RowParser, parseRow) import Hasql.Postgres (Postgres) import Api.Types...
e3bd79eda5dec112dad6d69a63f23b3edd29c7f5b33aa1018581644b12ad3c68
Drup/adtr
scheduling.ml
module LF = struct type t = int Index.index Index.index let import = Index.map_factors (fun i -> Index.const i) let ( * ) k x : t = Index.map_factors (fun f -> Index.(f * k)) x let ( *@ ) k x : t = Index.map_factors (fun f -> Index.(k *@ f)) x let (+) x1 x2 : t = Index.map2 (Index.plus) x1 ...
null
https://raw.githubusercontent.com/Drup/adtr/a2d1cb8473522a52e475fd1261892cf363f215aa/src/scheduling.ml
ocaml
Fmt.epr "@[<v2>σ(%a) =@ %a@]@." * Id.pp name * LF.pp lf; All 0 ≤ λ All 0 ≤ μ Fmt.epr "No schedule@.";
module LF = struct type t = int Index.index Index.index let import = Index.map_factors (fun i -> Index.const i) let ( * ) k x : t = Index.map_factors (fun f -> Index.(f * k)) x let ( *@ ) k x : t = Index.map_factors (fun f -> Index.(k *@ f)) x let (+) x1 x2 : t = Index.map2 (Index.plus) x1 ...
26958a08815c85b2bd03884dc395f0dd022da152f239a265033111a9f6b05231
knutin/elli
elli_http_tests.erl
-module(elli_http_tests). -include_lib("eunit/include/eunit.hrl"). -include("elli.hrl"). %% UNIT TESTS chunk_loop_test_() -> fun ()-> Here = self(), ChunkLoopWrapper = fun() -> Result = elli_http:chunk_loop({some_type, some_socket}), Here ! Result, ok end, ...
null
https://raw.githubusercontent.com/knutin/elli/35eb9e8af459f48698bae7c6096d128e2f34fd6a/test/elli_http_tests.erl
erlang
UNIT TESTS
-module(elli_http_tests). -include_lib("eunit/include/eunit.hrl"). -include("elli.hrl"). chunk_loop_test_() -> fun ()-> Here = self(), ChunkLoopWrapper = fun() -> Result = elli_http:chunk_loop({some_type, some_socket}), Here ! Result, ok end, Pid = sp...
fd63385c3061a27c694f1c5c46d5bbed4c38747eee09baabbc10b8ccf2023c35
tov/dssl2
default-timeout-slow-fail.rkt
#lang dssl2 assert time < 1 assert sleep(10) is None
null
https://raw.githubusercontent.com/tov/dssl2/105d18069465781bd9b87466f8336d5ce9e9a0f3/test/dssl2/default-timeout-slow-fail.rkt
racket
#lang dssl2 assert time < 1 assert sleep(10) is None
9accff22a13e11afdf51cbbd795ec427576691b13282344039c21fd5cbd805c3
2600hz-archive/whistle
riak_err_app.erl
Copyright ( c ) 2010 Basho Technologies , Inc. All Rights Reserved . %% This file is provided to you under the Apache License , %% Version 2.0 (the "License"); you may not use this file except in compliance with the License . You may obtain %% a copy of the License at %% %% -2.0 %% %% Unless required by app...
null
https://raw.githubusercontent.com/2600hz-archive/whistle/1a256604f0d037fac409ad5a55b6b17e545dcbf9/lib/riak_err-1.0.1/src/riak_err_app.erl
erlang
Version 2.0 (the "License"); you may not use this file a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. @doc A memory-limited info/err...
Copyright ( c ) 2010 Basho Technologies , Inc. All Rights Reserved . This file is provided to you under the Apache License , except in compliance with the License . You may obtain software distributed under the License is distributed on an " AS IS " BASIS , WITHOUT WARRANTIES OR CONDITIONS OF ANY Repla...
d8e3155ca36c1d612e3e304b882f3e0f72a80458c62badf739d806cb4bc97b82
tsloughter/grpcbox
grpc_testing_unimplemented_service_client.erl
%%%------------------------------------------------------------------- @doc Client module for grpc service grpc.testing . UnimplementedService . %% @end %%%------------------------------------------------------------------- this module was generated on 2019 - 03 - 09T00:28:54 + 00:00 and should not be modified man...
null
https://raw.githubusercontent.com/tsloughter/grpcbox/49d9275b2bb264e3ecd4c3adee5cf0c03972d496/interop/src/grpc_testing_unimplemented_service_client.erl
erlang
------------------------------------------------------------------- @end ------------------------------------------------------------------- @doc Unary RPC
@doc Client module for grpc service grpc.testing . UnimplementedService . this module was generated on 2019 - 03 - 09T00:28:54 + 00:00 and should not be modified manually -module(grpc_testing_unimplemented_service_client). -compile(export_all). -compile(nowarn_export_all). -include_lib("grpcbox/include/grpcbox....
df743fcd6fed06a48c1d5c23c5a5e60ba20a855d251158bd925b8b6da9e0d29c
kokuyouwind/haskell-exercises
Chapter6.hs
module Answer.Chapter6 ( sortByFrequency , initialMap , infixPalindromicNumber , vernam ) where import Data.Ord import Data.List import qualified Data.Map as Map import Data.Char import Data.Bits ( 1.1 ) sortByFrequency :: Ord a => [a] -> [a] sortByFrequency = ma...
null
https://raw.githubusercontent.com/kokuyouwind/haskell-exercises/dbc68ba477ce525c75fe7c31301f2b632da3b08a/Answer/Chapter6.hs
haskell
module Answer.Chapter6 ( sortByFrequency , initialMap , infixPalindromicNumber , vernam ) where import Data.Ord import Data.List import qualified Data.Map as Map import Data.Char import Data.Bits ( 1.1 ) sortByFrequency :: Ord a => [a] -> [a] sortByFrequency = ma...
078d62e8fda7352dd641aa60838735689fdacd3c10a16bd7e305dee8fd02cd7f
sysbio-bioinf/avatar
edit_distance.clj
Copyright ( c ) . All rights reserved . ; The use and distribution terms for this software are covered by the Eclipse Public License 2.0 ( -v20.html ) ; which can be found in the file LICENSE at the root of this distribution. ; By using this software in any fashion, you are agreeing to be bound by ; the terms of ...
null
https://raw.githubusercontent.com/sysbio-bioinf/avatar/cbf9968485f96fb61725aaa7381dba53624d6189/src/clojure/avatar/algorithms/edit_distance.clj
clojure
The use and distribution terms for this software are covered by the which can be found in the file LICENSE at the root of this distribution. By using this software in any fashion, you are agreeing to be bound by the terms of this license. You must not remove this notice, or any other, from this software.
Copyright ( c ) . All rights reserved . Eclipse Public License 2.0 ( -v20.html ) (ns avatar.algorithms.edit-distance) (defn double-min ^double [^double a, ^double b, ^double c] (if (< a b) (if (< a c) a c) (if (< b c) b c))) (defn edit-distance ^double [^String s1, ^String s2] (let [[^String ...
317ebe11d3a9369a4894c36284589ae0a44be4fa5da85526940408ccd4252f7e
basho/riak_test
verify_busy_dist_port.erl
%% ------------------------------------------------------------------- %% Copyright ( c ) 2012 Basho Technologies , Inc. %% Test for regression in riak_sysmon where busy_port / busy_dist_port were not set to true in app.config by default . Originally reported in az1018 ( AgileZen 1018 ) . %% This test starts tw...
null
https://raw.githubusercontent.com/basho/riak_test/8170137b283061ba94bc85bf42575021e26c929d/tests/verify_busy_dist_port.erl
erlang
------------------------------------------------------------------- of messages to the paused node, which should cause busy_dist_port. We then check for busy_dist_port messages in the logs. see: mis-configured and buggy and therefore was not logging 'busy_dist_port' events when they were happening. While tr...
Copyright ( c ) 2012 Basho Technologies , Inc. Test for regression in riak_sysmon where busy_port / busy_dist_port were not set to true in app.config by default . Originally reported in az1018 ( AgileZen 1018 ) . This test starts two riak nodes and pauses the process of one of the node 's vms using " kill -ST...
92370a91756093cca7e1d17583e66f69fc75787c5eef1b0fb97ec820def2203f
shayne-fletcher/zen
fortune.ml
open Printf let get_fortune f g = let repeat_eat_int ch n = for i = 0 to (n - 1) do let _ = input_binary_int ch in () done in let bin_ch = open_in_bin g in try repeat_eat_int bin_ch 1; let num_quotes = input_binary_int bin_ch in repeat_eat_int bin_ch 3; Rando...
null
https://raw.githubusercontent.com/shayne-fletcher/zen/10a1d0b9bf261bb133918dd62fb1593c3d4d21cb/ocaml/fortune/fortune.ml
ocaml
open Printf let get_fortune f g = let repeat_eat_int ch n = for i = 0 to (n - 1) do let _ = input_binary_int ch in () done in let bin_ch = open_in_bin g in try repeat_eat_int bin_ch 1; let num_quotes = input_binary_int bin_ch in repeat_eat_int bin_ch 3; Rando...
8beabc6f145a160ba0a9303b0451a07c6021882376f28f66dd98eb8b3bf8f494
cffi/cffi
types.lisp
;;;; -*- Mode: lisp; indent-tabs-mode: nil -*- ;;; ;;; types.lisp --- User-defined CFFI types. ;;; Copyright ( C ) 2005 - 2006 , < > Copyright ( C ) 2005 - 2007 , ;;; ;;; Permission is hereby granted, free of charge, to any person ;;; obtaining a copy of this software and associated documentation files...
null
https://raw.githubusercontent.com/cffi/cffi/743a90251e5a4407147a20bd8354df03a87ca46d/src/types.lisp
lisp
-*- Mode: lisp; indent-tabs-mode: nil -*- types.lisp --- User-defined CFFI types. 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, sub...
Copyright ( C ) 2005 - 2006 , < > Copyright ( C ) 2005 - 2007 , 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 Software . THE SOFTWARE IS PROVIDED " AS IS " , WITHOU...
1d92c4df8955440d2aab91a96df9648dbd268a6f9ac586c9c1e8ba7925bb0ccb
dradtke/Lisp-Text-Editor
cell-renderer-text.lisp
(in-package :gtk-cffi) (defclass cell-renderer-text (cell-renderer) ()) (defcfun "gtk_cell_renderer_text_new" :pointer) (defmethod gconstructor ((cell-renderer-text cell-renderer-text) &key &allow-other-keys) (gtk-cell-renderer-text-new))
null
https://raw.githubusercontent.com/dradtke/Lisp-Text-Editor/b0947828eda82d7edd0df8ec2595e7491a633580/quicklisp/dists/quicklisp/software/gtk-cffi-20120208-cvs/gtk/cell-renderer-text.lisp
lisp
(in-package :gtk-cffi) (defclass cell-renderer-text (cell-renderer) ()) (defcfun "gtk_cell_renderer_text_new" :pointer) (defmethod gconstructor ((cell-renderer-text cell-renderer-text) &key &allow-other-keys) (gtk-cell-renderer-text-new))
bf34c42b1bdac866d50e340f74fdc971bf062a94e623936364000f2ab46303a4
Clozure/ccl
mach-o.lisp
;;; ;;; Copyright 2009 Clozure Associates ;;; 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, softw...
null
https://raw.githubusercontent.com/Clozure/ccl/6c1a9458f7a5437b73ec227e989aa5b825f32fd3/library/mach-o.lisp
lisp
Copyright 2009 Clozure Associates 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...
distributed under the License is distributed on an " AS IS " BASIS , (defstruct mach-o-file header load-commands segments symbols strings) (defmethod print-object ((m mach-o-file) stream) (print-unreadable-object (m stream :type t :identity t))) (defstruct mach-o-string-table (hash (make-hash-table ...
3543d3693630e87d751423379012f45e35e3fbb8f55a2d1a92ec329a12708851
malcolmreynolds/GSLL
rayleigh-tail.lisp
Rayleigh tail distribution , Sat Sep 30 2006 Time - stamp : < 2009 - 05 - 24 20:07:27EDT rayleigh-tail.lisp > $ Id$ (in-package :gsl) ;;; /usr/include/gsl/gsl_randist.h (defmfun sample ((generator random-number-generator) (type (eql 'rayleigh-tail)) &key a sigma) "gsl_ran_rayleigh_tail" (((mpo...
null
https://raw.githubusercontent.com/malcolmreynolds/GSLL/2f722f12f1d08e1b9550a46e2a22adba8e1e52c4/random/rayleigh-tail.lisp
lisp
/usr/include/gsl/gsl_randist.h Examples and unit test
Rayleigh tail distribution , Sat Sep 30 2006 Time - stamp : < 2009 - 05 - 24 20:07:27EDT rayleigh-tail.lisp > $ Id$ (in-package :gsl) (defmfun sample ((generator random-number-generator) (type (eql 'rayleigh-tail)) &key a sigma) "gsl_ran_rayleigh_tail" (((mpointer generator) :pointer) (a :doub...
5e44a47355e3383970c732e4bf463eea7ab5b8d313112dbb657ddba4d474881c
janestreet/ecaml
test_color.ml
open! Core open! Async_kernel open! Import open! Color let show t = print_s [%message "" ~color:(t : t) ~is_gray:(is_gray t : bool) ~is_defined:(is_defined t : bool) ~is_supported:(is_supported t : bool) ~rgb:(rgb_exn t : RGB.t)] ;; let%expect_test "[defined]" = p...
null
https://raw.githubusercontent.com/janestreet/ecaml/7c16e5720ee1da04e0757cf185a074debf9088df/test/test_color.ml
ocaml
open! Core open! Async_kernel open! Import open! Color let show t = print_s [%message "" ~color:(t : t) ~is_gray:(is_gray t : bool) ~is_defined:(is_defined t : bool) ~is_supported:(is_supported t : bool) ~rgb:(rgb_exn t : RGB.t)] ;; let%expect_test "[defined]" = p...
a3e42e0912dd277e56df9201ec72b48d73c76e0b633ddd848b8ab0edcc5c100f
mejgun/haskell-tdlib
AssignGooglePlayTransaction.hs
{-# LANGUAGE OverloadedStrings #-} -- | module TD.Query.AssignGooglePlayTransaction where import qualified Data.Aeson as A import qualified Data.Aeson.Types as T import qualified TD.Data.StorePaymentPurpose as StorePaymentPurpose import qualified Utils as U -- | Informs server about a purchase through Google Play ...
null
https://raw.githubusercontent.com/mejgun/haskell-tdlib/dc380d18d49eaadc386a81dc98af2ce00f8797c2/src/TD/Query/AssignGooglePlayTransaction.hs
haskell
# LANGUAGE OverloadedStrings # | | | Transaction purpose | Google Play purchase token | Identifier of the purchased store product | Application package name
module TD.Query.AssignGooglePlayTransaction where import qualified Data.Aeson as A import qualified Data.Aeson.Types as T import qualified TD.Data.StorePaymentPurpose as StorePaymentPurpose import qualified Utils as U Informs server about a purchase through Google Play . For official applications only data AssignG...
de9dec15474c7d41fc07411d4d109dedcb95a3bc335ebbeee243b13fc3e669ce
tezos-commons/baseDAO
Proposal.hs
SPDX - FileCopyrightText : 2021 Tezos Commons SPDX - License - Identifier : LicenseRef - MIT - TC module SMT.Model.BaseDAO.Proposal ( applyFreeze , applyUnfreeze , applyVote , applyPropose , applyFlush , applyDropProposal , applyUpdateDelegate , applyUnstakeVote ) where import Universum import ...
null
https://raw.githubusercontent.com/tezos-commons/baseDAO/c8cc03362b64e8f27432ec70cdb4c0df82abff35/haskell/test/SMT/Model/BaseDAO/Proposal.hs
haskell
Execute decision callback if the proposal is passed. ------------------------------------------------------------- Delegate ------------------------------------------------------------- ------------------------------------------------------------- Unstake_vote --------------------------------------------------------...
SPDX - FileCopyrightText : 2021 Tezos Commons SPDX - License - Identifier : LicenseRef - MIT - TC module SMT.Model.BaseDAO.Proposal ( applyFreeze , applyUnfreeze , applyVote , applyPropose , applyFlush , applyDropProposal , applyUpdateDelegate , applyUnstakeVote ) where import Universum import ...
0e66c37fc0216354ae78948076574b1998d512c0a5767f06230fbdcd547a9728
johnmn3/cljs-thread
msg.cljs
(ns cljs-thread.msg (:require [cljs-thread.state :as s] [cljs-thread.env :as e] [cljs-thread.id :refer [IDable get-id]] [clojure.edn :as edn] [clojure.pprint :refer [pprint]])) (def event-message "message") (defmulti dispatch :dispatch) (defn read-id [id] (if (.startsWith id ":") (edn/read-str...
null
https://raw.githubusercontent.com/johnmn3/cljs-thread/e98edc26ae71d1e17cea96a1f0e978df41b34d3f/src/cljs_thread/msg.cljs
clojure
(ns cljs-thread.msg (:require [cljs-thread.state :as s] [cljs-thread.env :as e] [cljs-thread.id :refer [IDable get-id]] [clojure.edn :as edn] [clojure.pprint :refer [pprint]])) (def event-message "message") (defmulti dispatch :dispatch) (defn read-id [id] (if (.startsWith id ":") (edn/read-str...
4408803883ef75673082ab2216f7757a90c0e9fbe354c69c70ba743d22a3cda7
mini-monkey/mini-monkey
prop_auth.erl
-module(prop_auth). -include_lib("proper/include/proper.hrl"). -import(mm_test_tokens, [god_token/0]). %%%%%%%%%%%%%%%%%% %%% Properties %%% %%%%%%%%%%%%%%%%%% prop_admin_with_wrong_token_test() -> ?FORALL({Token, Name}, {blob(), blob()}, begin mm_test_common:setup(), {ok, Room} = mm_room_sup:create_room...
null
https://raw.githubusercontent.com/mini-monkey/mini-monkey/4afa4385256c0f1d23db522c0725c3291a8c86c8/test/prop_auth.erl
erlang
Properties %%% this needs to be last or we cannot admin anymore :) Helpers %%% Generators %%%
-module(prop_auth). -include_lib("proper/include/proper.hrl"). -import(mm_test_tokens, [god_token/0]). prop_admin_with_wrong_token_test() -> ?FORALL({Token, Name}, {blob(), blob()}, begin mm_test_common:setup(), {ok, Room} = mm_room_sup:create_room(Name), true andalso error =:= mm_room:permission...
7b56b346de4154e3d0c010aa7e494f5511569112ace6c2fe2ec3ba2a5b8fb402
adrianton3/staplo
project.clj
(defproject staplo "0.1.0-SNAPSHOT" :description "FIXME: write this!" :url "" :dependencies [[org.clojure/clojure "1.8.0"] [org.clojure/clojurescript "1.9.562"] [reagent "0.7.0"]] :node-dependencies [[source-map-support "0.2.8"]] :plugins [[lein-cljsbuild "1.1.6"] ...
null
https://raw.githubusercontent.com/adrianton3/staplo/c251d24644c24fe100a6da63c6e32c9ba8b60fe9/project.clj
clojure
(defproject staplo "0.1.0-SNAPSHOT" :description "FIXME: write this!" :url "" :dependencies [[org.clojure/clojure "1.8.0"] [org.clojure/clojurescript "1.9.562"] [reagent "0.7.0"]] :node-dependencies [[source-map-support "0.2.8"]] :plugins [[lein-cljsbuild "1.1.6"] ...
08d6e3018fe285a8925bfba8d6aa578f6b54e3821394e59719e87bdb55c94485
ragkousism/Guix-on-Hurd
rails.scm
;;; GNU Guix --- Functional package management for GNU Copyright © 2016 < > ;;; ;;; This file is part of GNU Guix. ;;; 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 Lice...
null
https://raw.githubusercontent.com/ragkousism/Guix-on-Hurd/e951bb2c0c4961dc6ac2bda8f331b9c4cee0da95/gnu/packages/rails.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 © 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 , see < / > . (define-module (gnu packages rails) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix downlo...
1b990ec3fa64ea66e75ba9b0f61412ef72c7cbc5c794a0a55c9cf4f47ce3e67f
tschady/advent-of-code
d10_test.clj
(ns aoc.2022.d10-test (:require [aoc.2022.d10 :as sut] [clojure.test :refer :all])) (def ex "noop addx 3 addx -5") (def ex2 "addx 15 addx -11 addx 6 addx -3 addx 5 addx -1 addx -8 addx 13 addx 4 noop addx -1 addx 5 addx -1 addx 5 addx -1 addx 5 addx -1 addx 5 addx -1 addx -35 addx 1 addx 24 addx -19 add...
null
https://raw.githubusercontent.com/tschady/advent-of-code/3e4880e7f8771ad4de3296186c033de7c9e66ee9/test/aoc/2022/d10_test.clj
clojure
(ns aoc.2022.d10-test (:require [aoc.2022.d10 :as sut] [clojure.test :refer :all])) (def ex "noop addx 3 addx -5") (def ex2 "addx 15 addx -11 addx 6 addx -3 addx 5 addx -1 addx -8 addx 13 addx 4 noop addx -1 addx 5 addx -1 addx 5 addx -1 addx 5 addx -1 addx 5 addx -1 addx -35 addx 1 addx 24 addx -19 add...
8da7ec054720903e4bcc80f7062dd18af61338d0b0ae0f358af55472a46cf348
olivermg/owlisp
macroexpansion.lisp
(in-package #:owlisp/analyzer) (export '(do-macroexpansion)) (defparameter *global-macro-symboltable* (make-symboltable :symbols owl/m:*builtin-macro-symbols*)) ( defparameter * - level * 0 ) ;(defparameter *unquote-count* 0) (defparameter *convert-builtin-macros-walker* (make-walker (declare (ignore #'wa...
null
https://raw.githubusercontent.com/olivermg/owlisp/dbf6d1d9e813f16124c170a0e1bfe155752e017b/src/analyzer/macroexpansion.lisp
lisp
(defparameter *unquote-count* 0)
(in-package #:owlisp/analyzer) (export '(do-macroexpansion)) (defparameter *global-macro-symboltable* (make-symboltable :symbols owl/m:*builtin-macro-symbols*)) ( defparameter * - level * 0 ) (defparameter *convert-builtin-macros-walker* (make-walker (declare (ignore #'walk-sequence-last)) (defrule ...
50a0595ab6c8f14e3a2be3d7469f1b3ac664f27a0e506ff5d01017e9a8c53b6c
Atidot/snippets
Terraform.hs
#! /usr/bin/env nix-shell #! nix-shell -I nixpkgs= -i runhaskell -p "(pkgs.haskell.packages.ghc864.extend (self: super: with haskell; { language-python = lib.doJailbreak super.language-python; terraform-hs = lib.doJailbreak (self.callPackage({ mkDerivation, base, containers, data-default, fetchgit, filepath, stdenv, te...
null
https://raw.githubusercontent.com/Atidot/snippets/55fa5fbff396817e16c039dc16d859338e411ac1/Haskell/Terraform.hs
haskell
# LANGUAGE PackageImports # # LANGUAGE OverloadedStrings # -started/build the difference is only in instances name, due to the terraform-hs name labeling
#! /usr/bin/env nix-shell #! nix-shell -I nixpkgs= -i runhaskell -p "(pkgs.haskell.packages.ghc864.extend (self: super: with haskell; { language-python = lib.doJailbreak super.language-python; terraform-hs = lib.doJailbreak (self.callPackage({ mkDerivation, base, containers, data-default, fetchgit, filepath, stdenv, te...
4defb03d721f2c4df1d874f27504c8eb19af4eb727652a4534376781e86bcbee
ruhatch/mirage-oram
stash.ml
open Core_kernel.Std type t = Cstruct.t Int64.Table.t let bin_size_cstruct cstruct = let string = Cstruct.to_string cstruct in bin_size_string string let bin_write_cstruct buf ~pos cstruct = let string = Cstruct.to_string cstruct in bin_write_string buf ~pos string let bin_read_cstruct buf ~pos_ref = let ...
null
https://raw.githubusercontent.com/ruhatch/mirage-oram/533a7f7726c4a499b60c71ed627b730349a3816b/lib/stash.ml
ocaml
open Core_kernel.Std type t = Cstruct.t Int64.Table.t let bin_size_cstruct cstruct = let string = Cstruct.to_string cstruct in bin_size_string string let bin_write_cstruct buf ~pos cstruct = let string = Cstruct.to_string cstruct in bin_write_string buf ~pos string let bin_read_cstruct buf ~pos_ref = let ...
62b9c4014d85581a1db876d8a46f1970ad53c3ec3ead102d287926f24c9d4a09
incoherentsoftware/defect-process
Run.hs
module Enemy.All.Bat.AI.Run ( runBehaviorInstr ) where import Collision import Configs.All.Enemy import Configs.All.Enemy.Bat import Constants import Enemy as E import Enemy.All.Bat.AttackDescriptions import Enemy.All.Bat.Behavior import Enemy.All.Bat.Data import Msg import Util import Window.Graphics runBeha...
null
https://raw.githubusercontent.com/incoherentsoftware/defect-process/8797aad1d93bff5aadd7226c39a48f45cf76746e/src/Enemy/All/Bat/AI/Run.hs
haskell
module Enemy.All.Bat.AI.Run ( runBehaviorInstr ) where import Collision import Configs.All.Enemy import Configs.All.Enemy.Bat import Constants import Enemy as E import Enemy.All.Bat.AttackDescriptions import Enemy.All.Bat.Behavior import Enemy.All.Bat.Data import Msg import Util import Window.Graphics runBeha...
8ef3976f88ac5f692051fd10bae1fb66f8575ab74409327c6bd7d91278182873
footprintanalytics/footprint-web
cumulative_aggregations.clj
(ns metabase.query-processor.middleware.cumulative-aggregations "Middlware for handling cumulative count and cumulative sum aggregations." (:require [metabase.mbql.schema :as mbql.s] [metabase.mbql.util :as mbql.u] [schema.core :as s])) ;;;; Pre-processing (defn- diff-indecies "Given two...
null
https://raw.githubusercontent.com/footprintanalytics/footprint-web/d3090d943dd9fcea493c236f79e7ef8a36ae17fc/src/metabase/query_processor/middleware/cumulative_aggregations.clj
clojure
Pre-processing cumulative count doesn't neccesarily have a field-id arg figure out which indexes are being changed in the results. Since breakouts always get included in Post-processing
(ns metabase.query-processor.middleware.cumulative-aggregations "Middlware for handling cumulative count and cumulative sum aggregations." (:require [metabase.mbql.schema :as mbql.s] [metabase.mbql.util :as mbql.u] [schema.core :as s])) (defn- diff-indecies "Given two sequential collecti...
720c9ccb55042550d1850f6ad7179e9f6cc1a5c64c9e74e3ebb42b53f37a2d12
appleby/99-lisp-problems
p23.lisp
;;;; (**) Extract a given number of randomly selected elements from a ;;;; list. The selected items shall be returned in a list. ;;;; Example: * ( rnd - select ' ( a b c d e f g h ) 3 ) ;;;; (E D A) ;;;; Hint: Use the built-in random number generator and the result of ;;;; problem P20. (in-package :99-problems) (de...
null
https://raw.githubusercontent.com/appleby/99-lisp-problems/a12b2a585ac5af06f456f844d308bbada78e647c/p23.lisp
lisp
(**) Extract a given number of randomly selected elements from a list. The selected items shall be returned in a list. Example: (E D A) Hint: Use the built-in random number generator and the result of problem P20. Heavy lifting done by random-sample. Just convert between list and array types. Implemented as su...
* ( rnd - select ' ( a b c d e f g h ) 3 ) (in-package :99-problems) (defun random-sample (vector n) "Based on Algorithm S from Knuth. TAOCP, vol. 2. p. 142. Lifted from the source code of the book Practical Common Lisp. See Chapter27/database.lisp." (loop with selected = (make-array n :fill-pointer 0) ...
d4a05acb3afb43df8d2e9038446dad20695b76746866aa796d813019cad9f9a8
GregoryTravis/holfenstein
Util.hs
module Util ( assert , assertM , esp , eesp , fesp , eeesp , feesp , sp , msp , fromLeftReal , mappily , mcompose ) where import Control.Exception.Base import Data.Either import Data.Text (unpack) import Data.Text.Lazy (toStrict) import System.IO.Unsafe import Text.Pretty.Simple (pShow, pShowNoColor) esp a = unsafePe...
null
https://raw.githubusercontent.com/GregoryTravis/holfenstein/fcb8743351700c701757dc13fb6defcde53be306/Util.hs
haskell
Fake ones for quickly disabling Really surprised this doesn't exist return a I am giving this a terrible name because I know it must exist but I don't know enough to know what it's called and I refused to accept at the moment that it might be called fmap.
module Util ( assert , assertM , esp , eesp , fesp , eeesp , feesp , sp , msp , fromLeftReal , mappily , mcompose ) where import Control.Exception.Base import Data.Either import Data.Text (unpack) import Data.Text.Lazy (toStrict) import System.IO.Unsafe import Text.Pretty.Simple (pShow, pShowNoColor) esp a = unsafePe...
c64fef2e3bd04c94820e67391eb020d4e4c4ce3a1e15a35c74d94873a3156a08
haskell-effectful/effectful
Env.hs
# LANGUAGE AllowAmbiguousTypes # # OPTIONS_HADDOCK not - home # module Effectful.Internal.Env ( -- * The environment Env(..) , Storage(..) -- ** Relinker , Relinker(..) , dummyRelinker -- * Dispatch , Dispatch(..) , SideEffects(..) , DispatchOf , EffectRep -- * Operations , emptyEnv...
null
https://raw.githubusercontent.com/haskell-effectful/effectful/6b0f620588e353f541fdcde7562c877d0660e43e/effectful-core/src/Effectful/Internal/Env.hs
haskell
* The environment ** Relinker * Dispatch * Operations ** Modification of the effect stack ** Data retrieval and update of kind 'Effect'. __Warning: the environment is a mutable data structure and cannot be simultaneously used from multiple threads under any circumstances.__ In order to pass it to a different...
# LANGUAGE AllowAmbiguousTypes # # OPTIONS_HADDOCK not - home # module Effectful.Internal.Env Env(..) , Storage(..) , Relinker(..) , dummyRelinker , Dispatch(..) , SideEffects(..) , DispatchOf , EffectRep , emptyEnv , cloneEnv , restoreEnv , sizeEnv , tailEnv , consEnv , unconsEnv ...
08e1b99a78a89d2150053dc57e71483fa98ab5e957a01b1b7d50e67298c6861e
fakedata-haskell/fakedata
Show.hs
# LANGUAGE TemplateHaskell # {-# LANGUAGE OverloadedStrings #-} module Faker.Show where import Data.Text (Text) import Faker (Fake(..)) import Faker.Provider.Show import Faker.TH $(generateFakeField "show" "adult_musical")
null
https://raw.githubusercontent.com/fakedata-haskell/fakedata/e6fbc16cfa27b2d17aa449ea8140788196ca135b/src/Faker/Show.hs
haskell
# LANGUAGE OverloadedStrings #
# LANGUAGE TemplateHaskell # module Faker.Show where import Data.Text (Text) import Faker (Fake(..)) import Faker.Provider.Show import Faker.TH $(generateFakeField "show" "adult_musical")
46b00aa5941c6fb50893174dd5efc89062b16bdb6fc978b184c2ef4ef51418ec
phoe-trash/gateway
kernel.lisp
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;; GATEWAY " phoe " Herda 2017 ;;;; protocols/kernel.lisp (in-package #:gateway/protocol) (define-protocol kernel (:documentation "The KERNEL protocol describes objects which are capable of ~ processing messages, either sequent...
null
https://raw.githubusercontent.com/phoe-trash/gateway/a8d579ccbafcaee8678caf59d365ec2eab0b1a7e/protocol/class/kernel.lisp
lisp
GATEWAY protocols/kernel.lisp
" phoe " Herda 2017 (in-package #:gateway/protocol) (define-protocol kernel (:documentation "The KERNEL protocol describes objects which are capable of ~ processing messages, either sequentially or concurrently. In the second case, ~ the kernel contains implementation-dependent objects called workers. \ The m...
4c084ed925bc280fccf613cd84c074b223d4a1c43c3242efbf9f1586d03d3f86
tjammer/olox
olox.ml
module Ast = Ast open Lexing let report line where message = Format.eprintf "[line %i] Error%s: %s" line where message let print_position _ lexbuf = let pos = lexbuf.lex_curr_p in Printf.sprintf "%s:%d:%d" pos.pos_fname pos.pos_lnum (pos.pos_cnum - pos.pos_bol + 1) let parse_with_error lexbuf = try Ok (P...
null
https://raw.githubusercontent.com/tjammer/olox/f8febbbec5ecd1a7bd4955b0cd51da02a705e72f/lib/olox.ml
ocaml
module Ast = Ast open Lexing let report line where message = Format.eprintf "[line %i] Error%s: %s" line where message let print_position _ lexbuf = let pos = lexbuf.lex_curr_p in Printf.sprintf "%s:%d:%d" pos.pos_fname pos.pos_lnum (pos.pos_cnum - pos.pos_bol + 1) let parse_with_error lexbuf = try Ok (P...
4e3d5f8b5377fa19dd77ae5bae6876897234363af1765cf9c3ea940ed1450968
CloudI/CloudI
rebar_qc.erl
-*- erlang - indent - level : 4;indent - tabs - mode : nil -*- %% ex: ts=4 sw=4 et %% ------------------------------------------------------------------- %% rebar : Erlang Build Tools %% Copyright ( c ) 2011 - 2012 %% %% Permission is hereby granted, free of charge, to any person obtaining a copy %% of this sof...
null
https://raw.githubusercontent.com/CloudI/CloudI/3e45031c7ee3e974ead2612ea7dd06c9edf973c9/src/external/rebar/src/rebar_qc.erl
erlang
ex: ts=4 sw=4 et ------------------------------------------------------------------- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal to use, copy, modify, merge, publish, distribute, sublicense, and/or sel...
-*- erlang - indent - level : 4;indent - tabs - mode : nil -*- rebar : Erlang Build Tools Copyright ( c ) 2011 - 2012 in the Software without restriction , including without limitation the rights copies of the Software , and to permit persons to whom the Software is all copies or substantial portions of t...
a5ecf95b6fb3f1a1537002e6a10579e4bb7352a681fa04ed207eeeaa99ab364e
futurice/haskell-mega-repo
API.hs
{-# LANGUAGE DataKinds #-} # LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE TypeFamilies # {-# LANGUAGE TypeOperators #-} module Futurice.App.GitHubSync.API where import Futurice.Lucid.Foundation (HtmlPage) import Futurice.Prelude import Futurice.Servant i...
null
https://raw.githubusercontent.com/futurice/haskell-mega-repo/2647723f12f5435e2edc373f6738386a9668f603/github-sync/src/Futurice/App/GitHubSync/API.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE TypeOperators #
# LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE TypeFamilies # module Futurice.App.GitHubSync.API where import Futurice.Lucid.Foundation (HtmlPage) import Futurice.Prelude import Futurice.Servant import Prelude () import Servant import qualified GitHub as GH type GitHubSyn...
08f654593563a8a37085f5b4a61d98b46f400b410850c1c4a27f694deee9dd0a
mfoemmel/erlang-otp
ssl_base64.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 2003 - 2009 . All Rights Reserved . %% The contents of this file are subject to the Erlang Public License , Version 1.1 , ( the " License " ) ; you may not use this file except in %% compliance with the License. You should have received a copy of the %% Erlang Pub...
null
https://raw.githubusercontent.com/mfoemmel/erlang-otp/9c6fdd21e4e6573ca6f567053ff3ac454d742bc2/lib/ssl/src/ssl_base64.erl
erlang
%CopyrightBegin% compliance with the License. You should have received a copy of the Erlang Public License along with this software. If not, it can be retrieved online at /. basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limita...
Copyright Ericsson AB 2003 - 2009 . All Rights Reserved . The contents of this file are subject to the Erlang Public License , Version 1.1 , ( the " License " ) ; you may not use this file except in Software distributed under the License is distributed on an " AS IS " -module(ssl_base64). -export([encode/1,...
45d640f9ba044aa1ba9f9170a2ee507fa2c26db68c2e515749417f4bbc03a91e
jrm-code-project/LISP-Machine
chatst.lisp
;; -*- Mode: LISP; Package: CHAOS; Base:8 -*- ;;; TESTING FUNCTIONS: ;;; SET-BASE-ADDRESS - sets the base unibus address for the network interface ( defaults to 764140 ) CHATST - send to self with and without loopback printing the results , using pattern set ...
null
https://raw.githubusercontent.com/jrm-code-project/LISP-Machine/0a448d27f40761fafabe5775ffc550637be537b2/lambda/io1/chatst.lisp
lisp
-*- Mode: LISP; Package: CHAOS; Base:8 -*- TESTING FUNCTIONS: SET-BASE-ADDRESS - sets the base unibus address for the network interface CHATST-LOOP - send packets to another host (defaults to MC) which will echo it back (useful for scope loops) CHATST-MONITOR - looks at everying flowin...
( defaults to 764140 ) CHATST - send to self with and without loopback printing the results , using pattern set by SET - PATTERN CHATST - ECHO - CHATST - ECHO - ONCE SET - NCP - BASE - ADDRESS - Sets the device address used by the NCP so that th...
902f61180ffe94120fa7842a9674d7102f954e6c25ec71369660bb12598ab7fa
8c6794b6/haskell-sc-scratch
SampleData.hs
# LANGUAGE NoMonomorphismRestriction # | Module : $ Header$ CopyRight : ( c ) 8c6794b6 License : : Stability : unstable Portability : non - portable Sample patterns . Module : $Header$ CopyRight : (c) 8c6794b6 License : BSD3 Maintainer : Stability : unstable Portabil...
null
https://raw.githubusercontent.com/8c6794b6/haskell-sc-scratch/22de2199359fa56f256b544609cd6513b5e40f43/hsc3-lepton/src/Scratch/SampleData.hs
haskell
pspeFreq = [74,75,77,79,81]] Different random seed will be used in leptseq. pspe2' = bundle' 1 0 [ l_new "pspe1" $ ,("freq", midiCPS pspeFreq)] , l_new "pspe2" $ ,("freq", midiCPS (prepeat (-7) + pspeFreq))] ] Unison , using papp and plam Unison , high pitch pattern repeati...
# LANGUAGE NoMonomorphismRestriction # | Module : $ Header$ CopyRight : ( c ) 8c6794b6 License : : Stability : unstable Portability : non - portable Sample patterns . Module : $Header$ CopyRight : (c) 8c6794b6 License : BSD3 Maintainer : Stability : unstable Portabil...
a12d1f433296986b9334f566ddca696b67ee717f9658373811224ad8634b49bc
nathanmarz/cascalog
vars.clj
(ns cascalog.logic.vars "This namespace deals with all Cascalog variable transformations." (:require [clojure.set :refer (intersection difference)] [clojure.walk :refer (postwalk)] [jackknife.seq :as s])) ;; # Var Generation ;; This first section contains functions that allow to gene...
null
https://raw.githubusercontent.com/nathanmarz/cascalog/deaad977aa98985f68f3d1cc3e081d345184c0c8/cascalog-core/src/clj/cascalog/logic/vars.clj
clojure
# Var Generation nullable (prefixed by !), non-nullable (prefixed by ?), and ungrounding (prefixed by !!). ## Reserved Keywords => \"?a?b:see\"" # Sanitizing The following code serves to 'sanitize' a query by converting its logic variables to strings.
(ns cascalog.logic.vars "This namespace deals with all Cascalog variable transformations." (:require [clojure.set :refer (intersection difference)] [clojure.walk :refer (postwalk)] [jackknife.seq :as s])) This first section contains functions that allow to (defn uniquify-var "Append...
bb2e8563c31d16133653e8ce07a69033d1f1e25aaf6a06d2fa9be6f4e70ff6a0
kwrooijen/gungnir
model.cljc
(ns gungnir.model (:refer-clojure :exclude [find keys]) (:require [clojure.string :as string] [clojure.edn :as edn] [malli.util :as mu] [gungnir.util.malli :as util.malli] [malli.core :as m] [gungnir.spec] [clojure.spec.alpha :as s])) (defonce ^:dynamic *models* {}) (defonce ^:dynamic *table->...
null
https://raw.githubusercontent.com/kwrooijen/gungnir/1b4b70a72082a89150d01a72e0dfb9037caf50ce/src/cljc/gungnir/model.cljc
clojure
(ns gungnir.model (:refer-clojure :exclude [find keys]) (:require [clojure.string :as string] [clojure.edn :as edn] [malli.util :as mu] [gungnir.util.malli :as util.malli] [malli.core :as m] [gungnir.spec] [clojure.spec.alpha :as s])) (defonce ^:dynamic *models* {}) (defonce ^:dynamic *table->...
96b6f7d93203a375bb40e8e54d533541dbad34a8b4e1d4b88e0f2e208a21bfa3
dm3/sicp
interval.clj
(ns util.interval) (defn make-interval [a b] [a b]) (defn lower-bound [z] (get z 0)) (defn upper-bound [z] (get z 1)) (defn mul-interval [a b] (let [p1 (* (lower-bound a) (lower-bound b)) p2 (* (lower-bound a) (upper-bound b)) p3 (* (upper-bound a) (lower-bound b)) p4 (* (upper-bound a...
null
https://raw.githubusercontent.com/dm3/sicp/14f0361cbd0cce817d93e38dcc895f3e845515b1/src/main/clojure/util/interval.clj
clojure
(ns util.interval) (defn make-interval [a b] [a b]) (defn lower-bound [z] (get z 0)) (defn upper-bound [z] (get z 1)) (defn mul-interval [a b] (let [p1 (* (lower-bound a) (lower-bound b)) p2 (* (lower-bound a) (upper-bound b)) p3 (* (upper-bound a) (lower-bound b)) p4 (* (upper-bound a...
7239d7cf6de96b792e30a5c0aed2e690d5672ded85508e75a019eaa733c9360c
vaibhavsagar/experiments
Main.hs
# LANGUAGE RecursiveDo # # LANGUAGE ScopedTypeVariables # import Reflex import Reflex.Dom import Data.Map (Map) import qualified Data.Map as Map import Data.Text (pack, unpack, Text) import Text.Read (readMaybe) import HAMT import Text.Show.Pretty (ppShow) import Data.Functor ((<$), void) import Control.Monad.F...
null
https://raw.githubusercontent.com/vaibhavsagar/experiments/848ed9ccd6d50f93b1b0336f0a1114a14b1f6011/rp-example/hamt/app/Main.hs
haskell
# LANGUAGE RecursiveDo # # LANGUAGE ScopedTypeVariables # import Reflex import Reflex.Dom import Data.Map (Map) import qualified Data.Map as Map import Data.Text (pack, unpack, Text) import Text.Read (readMaybe) import HAMT import Text.Show.Pretty (ppShow) import Data.Functor ((<$), void) import Control.Monad.F...
59bcb3e84b90423b93eb4560e7b25a0ce0f3fc8e392ecab1f503724e00637dbd
exoscale/clojure-kubernetes-client
v1_label_selector_requirement.clj
(ns clojure-kubernetes-client.specs.v1-label-selector-requirement (:require [clojure.spec.alpha :as s] [spec-tools.data-spec :as ds] ) (:import (java.io File))) (declare v1-label-selector-requirement-data v1-label-selector-requirement) (def v1-label-selector-requirement-data { (ds/req...
null
https://raw.githubusercontent.com/exoscale/clojure-kubernetes-client/79d84417f28d048c5ac015c17e3926c73e6ac668/src/clojure_kubernetes_client/specs/v1_label_selector_requirement.clj
clojure
(ns clojure-kubernetes-client.specs.v1-label-selector-requirement (:require [clojure.spec.alpha :as s] [spec-tools.data-spec :as ds] ) (:import (java.io File))) (declare v1-label-selector-requirement-data v1-label-selector-requirement) (def v1-label-selector-requirement-data { (ds/req...
fe1f6685f3fb93b568d8d756b1b7e9520be2acbf55b8356bea34f4e50f6d6f14
exercism/scheme
hello-world.scm
(import (rnrs)) (define hello-world "Goodbye, Mars!")
null
https://raw.githubusercontent.com/exercism/scheme/6bbba92266ffe45af8a4f0a479aecff6569824a0/exercises/practice/hello-world/hello-world.scm
scheme
(import (rnrs)) (define hello-world "Goodbye, Mars!")
d0e62b5e922e7f49dea734fb16c6a56beaef561a48c02ab1c2708523f4f8313e
fisherdj/miniAdapton
microadapton-impl.scm
(define (make-athunk thunk) (adapton-cons thunk 'empty empty-set empty-set #f)) (define (adapton-add-dcg-edge! a-super a-sub) (adapton-sub-set! a-super (set-cons a-sub (adapton-sub a-super))) (adapton-super-set! a-sub (set-cons a-super (adapton-super a-sub)))) (define (adapton-del-dcg-edge! a-super a-sub) (a...
null
https://raw.githubusercontent.com/fisherdj/miniAdapton/1b5749422304567c96ac5367f2221dda9eff5880/microadapton-impl.scm
scheme
(define (make-athunk thunk) (adapton-cons thunk 'empty empty-set empty-set #f)) (define (adapton-add-dcg-edge! a-super a-sub) (adapton-sub-set! a-super (set-cons a-sub (adapton-sub a-super))) (adapton-super-set! a-sub (set-cons a-super (adapton-super a-sub)))) (define (adapton-del-dcg-edge! a-super a-sub) (a...
eb6be9ce1a2e7df5147cfbed7730066a6a9aba2182ddb6f74f45e0dee7701175
andersfugmann/ppx_protocol_conv
ppx_protocol_driver.mli
module type Parameters = sig * Map field names of records Mapping is done after applying [ [ @key ] ] attribute . is [ identity ] Mapping is done after applying [[@key]] attribute. Default is [identity] *) val field_name: string -> string * Map variant and constructor names . ...
null
https://raw.githubusercontent.com/andersfugmann/ppx_protocol_conv/add1548320707df042d64a4c81d3faa3c6cf2475/drivers/generic/ppx_protocol_driver.mli
ocaml
* Set of default Parameters * Helper function to convert snake case identifiers to camel case, e.g. a_bcd_ef -> aBcdEf
module type Parameters = sig * Map field names of records Mapping is done after applying [ [ @key ] ] attribute . is [ identity ] Mapping is done after applying [[@key]] attribute. Default is [identity] *) val field_name: string -> string * Map variant and constructor names . ...
d328885fc849dfcc5f99ef93150d4d706d0fd03d35c33770c65f79c1028d8fad
windock/erlyvideo
mochijson2.erl
@author < > 2007 Mochi Media , Inc. @doc Yet another JSON ( RFC 4627 ) library for Erlang . mochijson2 works %% with binaries as strings, arrays as lists (without an {array, _}) wrapper and it only knows how to decode UTF-8 ( and ASCII ) . -module(mochijson2). -author(''). -export([encoder/1, en...
null
https://raw.githubusercontent.com/windock/erlyvideo/80fdc4175de86f0ab5fb6db20a5b3c2fd4d5a075/src/mochijson2.erl
erlang
with binaries as strings, arrays as lists (without an {array, _}) This is a macro to placate syntax highlighters.. @type iolist() = [char() | binary() | iolist()] @type json_string() = atom | binary() @type json_number() = integer() | float() @type json_array() = [json_term()] @type json_object() = {struct,...
@author < > 2007 Mochi Media , Inc. @doc Yet another JSON ( RFC 4627 ) library for Erlang . mochijson2 works wrapper and it only knows how to decode UTF-8 ( and ASCII ) . -module(mochijson2). -author(''). -export([encoder/1, encode/1]). -export([decoder/1, decode/1]). -export([test/0]). -define(Q, $...
e33c966841fe9f5a50bda8f65cc4e0d69ea7d90a34a50d38b435be1762c13f3b
marcoheisig/Petalisp
lazy-index-components.lisp
© 2016 - 2023 - license : GNU AGPLv3 -*- coding : utf-8 -*- (in-package #:petalisp.api) (defun lazy-index-components (shape-designator &optional (axis 0)) (let* ((shape (shape-designator-shape shape-designator)) (rank (shape-rank shape))) (unless (<= 0 axis (1- rank)) (error "~@<Inva...
null
https://raw.githubusercontent.com/marcoheisig/Petalisp/b124ff1133a3f1f71c591608460cc993bdc0ec3c/code/api/lazy-index-components.lisp
lisp
© 2016 - 2023 - license : GNU AGPLv3 -*- coding : utf-8 -*- (in-package #:petalisp.api) (defun lazy-index-components (shape-designator &optional (axis 0)) (let* ((shape (shape-designator-shape shape-designator)) (rank (shape-rank shape))) (unless (<= 0 axis (1- rank)) (error "~@<Inva...
792c367e9fc379d39bbcdc9fdc72f1c563c5d1c75aa9e005afc05b5344b8d6fe
tonyg/kali-scheme
values.scm
(define (sender) (values 1 2 3 4)) (define (receiver a b c d) (+ a (- b (* c d)))) (define (test) (call-with-values sender receiver))
null
https://raw.githubusercontent.com/tonyg/kali-scheme/79bf76b4964729b63fce99c4d2149b32cb067ac0/ps-compiler/prescheme/test/values.scm
scheme
(define (sender) (values 1 2 3 4)) (define (receiver a b c d) (+ a (- b (* c d)))) (define (test) (call-with-values sender receiver))
1bd48fe1b38a185ac4b8685354a9a1687533497ff45a9a82f65d632bae9f4b6c
typelead/etlas
Package.hs
{-# LANGUAGE DeriveDataTypeable #-} # LANGUAGE DeriveGeneric # # LANGUAGE GeneralizedNewtypeDeriving # ----------------------------------------------------------------------------- -- | -- Module : Distribution.Package Copyright : 2003 - 2004 -- License : BSD3 -- -- Maintainer : -- Portability :...
null
https://raw.githubusercontent.com/typelead/etlas/bbd7c558169e1fda086e759e1a6f8c8ca2807583/etlas-cabal/Distribution/Package.hs
haskell
# LANGUAGE DeriveDataTypeable # --------------------------------------------------------------------------- | Module : Distribution.Package License : BSD3 Maintainer : Portability : portable Defines a package identifier along with a parser and pretty printer for it. a 'Dependency' data type. A d...
# LANGUAGE DeriveGeneric # # LANGUAGE GeneralizedNewtypeDeriving # Copyright : 2003 - 2004 ' PackageIdentifier 's consist of a name and an exact version . It also defines range , like @\"foo > = 1.2 & & < 2\"@. module Distribution.Package ( module Distribution.Types.AbiHash , module Distribution.Type...
36164f9404d57207935ba0cb3e531cd5be1f3048d3dafca75828434ccf8093f3
dyzsr/ocaml-selectml
ephetest_new.ml
(* TEST *) let debug = false open Printf open Ephemeron let is_true test s b = printf "%s %s: %s\n" test s (if b then "OK" else "FAIL") let is_false test s b = is_true test s (not b) let final r v = Gc.finalise_last (fun () -> r := false) v let is_key_value test (key_alive, _) = is_true test "key set" !key_alive l...
null
https://raw.githubusercontent.com/dyzsr/ocaml-selectml/875544110abb3350e9fb5ec9bbadffa332c270d2/testsuite/tests/misc/ephetest_new.ml
ocaml
TEST * test: key alive data dangling * test: key dangling data dangling * test: key dangling data alive * test: key accessible from data but all dangling
let debug = false open Printf open Ephemeron let is_true test s b = printf "%s %s: %s\n" test s (if b then "OK" else "FAIL") let is_false test s b = is_true test s (not b) let final r v = Gc.finalise_last (fun () -> r := false) v let is_key_value test (key_alive, _) = is_true test "key set" !key_alive let is_data_...
c974ad2bc896ab47de3c0e7d57bbf40c29afc0de076eb7d81733a08d7a13faac
EgorDm/fp-pacman
Helpers.hs
module Game.Rules.Helpers where import Engine.Base import Game.Agents.Base import Game.Level.Base import Game.Structure.Base import Constants import Resources {- Data structures -} {- Classes -} {- Instances -} {- Functions -} -- | Check if agent and a coordinate overlap onAgentOverlapsPos :: Float -> Agent...
null
https://raw.githubusercontent.com/EgorDm/fp-pacman/19781c92c97641b0a01b8f1554f50f19ff6d3bf4/src/Game/Rules/Helpers.hs
haskell
Data structures Classes Instances Functions | Check if agent and a coordinate overlap | Check if agents positions overlap | Check if agents are on the same tiles | Check if any agent in given list is on the same tile | Set agent dead | Get agent position | Check if agent is on the given tile | Stops the...
module Game.Rules.Helpers where import Engine.Base import Game.Agents.Base import Game.Level.Base import Game.Structure.Base import Constants import Resources onAgentOverlapsPos :: Float -> Agent -> Coordinate -> Bool onAgentOverlapsPos maxDist a bc = coordDist (position a) bc < maxDist onAgentsOverlap :: ...
c3eca6fdd36d884c27c3168162f0d2324760f6b0ccf6d8deb958d9cdb8bdba76
arsalan0c/cdp-hs
Runtime.hs
{-# LANGUAGE OverloadedStrings, RecordWildCards, TupleSections #-} # LANGUAGE ScopedTypeVariables # # LANGUAGE FlexibleContexts # # LANGUAGE MultiParamTypeClasses # # LANGUAGE FlexibleInstances # # LANGUAGE DeriveGeneric # # LANGUAGE TypeFamilies # {- | = Runtime Runtime domain exposes JavaScript runtime by means of...
null
https://raw.githubusercontent.com/arsalan0c/cdp-hs/f946d706485b0dd16360a753321c46d6f098649d/src/CDP/Domains/Runtime.hs
haskell
# LANGUAGE OverloadedStrings, RecordWildCards, TupleSections # | = Runtime Runtime domain exposes JavaScript runtime by means of remote evaluation and mirror objects. Evaluation results are returned as mirror object that expose object type, string representation and unique identifier that can be used for further obje...
# LANGUAGE ScopedTypeVariables # # LANGUAGE FlexibleContexts # # LANGUAGE MultiParamTypeClasses # # LANGUAGE FlexibleInstances # # LANGUAGE DeriveGeneric # # LANGUAGE TypeFamilies # module CDP.Domains.Runtime (module CDP.Domains.Runtime) where import Control.Applicative ((<$>)) import Control....
cc4a1b9d73e928e0837fe69f198c0a07456f49093b23f41dfdcb8855d6c9810a
haskell/lsp
OsPath.hs
# LANGUAGE CPP # # LANGUAGE ScopedTypeVariables # #if MIN_VERSION_filepath(1,4,100) #define OS_PATH 1 #endif module Language.LSP.Types.Uri.OsPath ( #ifdef OS_PATH osPathToNormalizedFilePath , normalizedFilePathToOsPath , EncodingException #endif ) where #ifdef OS_PATH import C...
null
https://raw.githubusercontent.com/haskell/lsp/b0f8596887088b8ab65fc1015c773f45b47234ae/lsp-types/src/Language/LSP/Types/Uri/OsPath.hs
haskell
| Extracts 'OsPath' from 'NormalizedFilePath'. Throws 'EncodingException' if the conversion fails.
# LANGUAGE CPP # # LANGUAGE ScopedTypeVariables # #if MIN_VERSION_filepath(1,4,100) #define OS_PATH 1 #endif module Language.LSP.Types.Uri.OsPath ( #ifdef OS_PATH osPathToNormalizedFilePath , normalizedFilePathToOsPath , EncodingException #endif ) where #ifdef OS_PATH import C...
f307f5f26635045f4b1d2ddc9ce2af9d4acd7dd07c9139427b2d1cb7af6cf61b
phadej/staged
Kleene.hs
# LANGUAGE ScopedTypeVariables # {-# LANGUAGE GADTs #-} # LANGUAGE TemplateHaskell # module Staged.Kleene ( compileRE, ) where import Kleene.RE import Kleene.Internal.Partition import Data.Traversable (for) import Staged.Commons import qualified Data.Set as Set import qualified Data.Map as Map compileRE :: RE Ch...
null
https://raw.githubusercontent.com/phadej/staged/b51c8c508af71ddb2aca4a75030da9b2c4f9e3dd/staged-kleene/src/Staged/Kleene.hs
haskell
# LANGUAGE GADTs #
# LANGUAGE ScopedTypeVariables # # LANGUAGE TemplateHaskell # module Staged.Kleene ( compileRE, ) where import Kleene.RE import Kleene.Internal.Partition import Data.Traversable (for) import Staged.Commons import qualified Data.Set as Set import qualified Data.Map as Map compileRE :: RE Char -> Code Q ([Char] ->...
4d9b2e3dce011a1a39f7be059f7ab2a2231f483e997f3105af5d6774ad01f4bd
silentsignal/DirBustErl
dirbusterl.erl
-module(dirbusterl). -export([start/0, start_link/0, stop/0]). -export([bust/2, bust_async/3, bust_file/2, bust_dir/2]). -export([bust_core/3, bust_monitor/3]). %% for spawning -include_lib("dirbusterl_server_state.hrl"). -include_lib("dirbusterl_requests_counter.erl"). %% External API bust(URL, UserConfig) -> Id =...
null
https://raw.githubusercontent.com/silentsignal/DirBustErl/bbdfdebb93241036500794e7055aae45a7ac9514/src/dirbusterl.erl
erlang
for spawning External API @doc Starts the app for inclusion in a supervisor tree @doc Start the dirbusterl server. @doc Stop the dirbusterl server.
-module(dirbusterl). -export([start/0, start_link/0, stop/0]). -export([bust/2, bust_async/3, bust_file/2, bust_dir/2]). -include_lib("dirbusterl_server_state.hrl"). -include_lib("dirbusterl_requests_counter.erl"). bust(URL, UserConfig) -> Id = dirbusterl_storage:generate_bust_id(), dirbusterl_storage:register_bus...
013b4c1b7b3accf4fc202c8d0c3f1362062e18c1a1ad6a5f650c156e66cc8967
hanshuebner/cadr2
dmon.lisp
-*- MODE : LISP ; PACKAGE : CADR -*- Diagnostic " monitor " ( will be anyway . pretty simpleminded for now ) . (DEFVAR CC-MAIN-MEMORY-SIZE NIL) (ADD-INITIALIZATION "clear target machine core size" '(SETQ CC-MAIN-MEMORY-SIZE NIL)) (DEFUN CC-RUN-MTEST (&OPTIONAL ALREADY-LOADED RANGE (MAP-OFFSET 0) &AUX ...
null
https://raw.githubusercontent.com/hanshuebner/cadr2/2398a1303804d41c4cdcb2d3d8454cd4a48912b8/mit/lcadr/dmon.lisp
lisp
PACKAGE : CADR -*- SAME SPEED, DISABLE PROM, ENABLE ERROR STOPS. WHY WAIT AS LONG? DISCOVER THE AMOUNT OF MAIN MEMORY, SETQ THE VARIABLE CC-MAIN-MEMORY-SIZE Read and write the sync program Set pointer Set pointer Start and stop the sync program Disable output of sync Write into the sync program from a list with re...
Diagnostic " monitor " ( will be anyway . pretty simpleminded for now ) . (DEFVAR CC-MAIN-MEMORY-SIZE NIL) (ADD-INITIALIZATION "clear target machine core size" '(SETQ CC-MAIN-MEMORY-SIZE NIL)) (DEFUN CC-RUN-MTEST (&OPTIONAL ALREADY-LOADED RANGE (MAP-OFFSET 0) &AUX PC CHAR) (COND ((AND (NULL CC-MA...
ef49e30188e6a708fd370ee0183a963cbb7ba4eb60e218c68fb8c3b934f55173
sealchain-project/sealchain
Shared.hs
{-# LANGUAGE ConstraintKinds #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE DeriveTraversable #-} # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # {-# LANGUAGE GADTs #-} # LANGUAGE General...
null
https://raw.githubusercontent.com/sealchain-project/sealchain/e97b4bac865fb147979cb14723a12c716a62e51e/pact/src/Pact/Analyze/Types/Shared.hs
haskell
# LANGUAGE ConstraintKinds # # LANGUAGE DataKinds # # LANGUAGE DeriveDataTypeable # # LANGUAGE DeriveTraversable # # LANGUAGE GADTs # # LANGUAGE OverloadedStrings # # LANGUAGE PatternSynonyms # # LANGUAGE PolyKinds # ...
# LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # # LANGUAGE MultiParamTypeClasses # # LANGUAGE ScopedTypeVariables # # LANGUAGE StandaloneDeriving # # LANGUAGE TypeApplications ...
e3ae2945f6ad529fccec243612aad78c2825cdd6aea32460ac9fcc0f494e2d5c
OlafChitil/hat
TestParser3.hs
module TestParser3 where f x = y where y = x
null
https://raw.githubusercontent.com/OlafChitil/hat/8840a480c076f9f01e58ce24b346850169498be2/trans/TestParser3.hs
haskell
module TestParser3 where f x = y where y = x
20dcbcdcd77aa281e88aa732971c6713bdae8e05913b0d3951883b64e191fee3
fetburner/Coq2SML
proof.mli
(************************************************************************) v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2014 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *...
null
https://raw.githubusercontent.com/fetburner/Coq2SML/322d613619edbb62edafa999bff24b1993f37612/coq-8.4pl4/proofs/proof.mli
ocaml
********************************************************************** // * This file is distributed under the terms of the * GNU Lesser General Public License Version 2.1 ********************************************************************** Type of a proof. Returns a stylis...
v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2014 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * Module defining the last es...
833bc7a1cc61c0d32fe7ad4b0684dbf5d2f48b6d75e153f73a7ba9ad2ae9348d
stepcut/plugins
One.hs
module One where import qualified Two resource = "This is the sub-plugin of (" ++ Two.resource ++ ")"
null
https://raw.githubusercontent.com/stepcut/plugins/52c660b5bc71182627d14c1d333d0234050cac01/testsuite/hier/hier3/One.hs
haskell
module One where import qualified Two resource = "This is the sub-plugin of (" ++ Two.resource ++ ")"
3c5ef02953c37ad8c6871916cfceff72e296a51ff857d0ee098b70f27f552a05
wavewave/hoodle
File.hs
# LANGUAGE LambdaCase # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE ScopedTypeVariables # # OPTIONS_GHC -fno - warn - unused - matches -fno - warn - incomplete - uni - patterns # module Hoodle.Coroutine.File where import Control.Lens (at, over, set, view, (.~), (?~)) import Control.Monad (guard, unless, void, when,...
null
https://raw.githubusercontent.com/wavewave/hoodle/0d94530020e3e9641a652edade77cd0eb8d9a1a4/core/src/Hoodle/Coroutine/File.hs
haskell
# LANGUAGE OverloadedStrings # | | | get file content from xournal file and update hoodle state | | deprecated | this is rather temporary not to make mistake | interleaving a monadic action between each pair of subsequent actions | this is rather temporary not to make mistake | need to be merged with Contex...
# LANGUAGE LambdaCase # # LANGUAGE ScopedTypeVariables # # OPTIONS_GHC -fno - warn - unused - matches -fno - warn - incomplete - uni - patterns # module Hoodle.Coroutine.File where import Control.Lens (at, over, set, view, (.~), (?~)) import Control.Monad (guard, unless, void, when, (<=<)) import Control.Monad.State ...
048c8a59a20a4743b21f9f3cf3d68ca434bbc4e2d23f54c1131aebce89046f26
NorfairKing/yamlparse-applicative
ApplicativeSpec.hs
# LANGUAGE AllowAmbiguousTypes # # LANGUAGE DeriveGeneric # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeApplications # module YamlParse.ApplicativeSpec where import qualified Data.Aeson.Types as Aeson import Data.GenValidity.Aeson () import Data.GenValidity.Containers () import Data.GenValidity.UnorderedContainer...
null
https://raw.githubusercontent.com/NorfairKing/yamlparse-applicative/7a329d06ffa45595963cf98f34910887115eb471/yamlparse-applicative-demo/test/YamlParse/ApplicativeSpec.hs
haskell
# LANGUAGE AllowAmbiguousTypes # # LANGUAGE DeriveGeneric # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeApplications # module YamlParse.ApplicativeSpec where import qualified Data.Aeson.Types as Aeson import Data.GenValidity.Aeson () import Data.GenValidity.Containers () import Data.GenValidity.UnorderedContainer...
ab7cd4bfa87a58cb4922649bf47bd29186f646db709ea3b4aeda796af00f9700
racket/algol60
simplify.rkt
#lang racket (require "parse.rkt" (except-in racket/match ==)) (provide simplify) ;; flatten/label-block : list-of-decl list-of-stmt -> block-stmt Desugars ` for ' , converts ` if ' so that it 's always of the form ` if < test > then goto < label > else < label > ' , flattens ;; compound statements into...
null
https://raw.githubusercontent.com/racket/algol60/e4aebcaff66f121cf52a1f58f4f7bd285eded728/simplify.rkt
racket
flatten/label-block : list-of-decl list-of-stmt -> block-stmt compound statements into the enclosing block, and gives every "dummy" statements that could easily be eliminated by merging labels. +0 => number
#lang racket (require "parse.rkt" (except-in racket/match ==)) (provide simplify) Desugars ` for ' , converts ` if ' so that it 's always of the form ` if < test > then goto < label > else < label > ' , flattens statement exactly one label . The result usually has lots of (define (flatten/label-block ...
b1aee55ff3f5f1e78eab30ec3665720c11f2c90da5c593e8c084bc8fe2b3c4d8
triffon/fp-2022-23
06-double-factorial.rkt
#lang racket дадена наготово (define (accumulate operation null-value start end term next) (if (> start end) null-value (operation (term start) (accumulate operation null-value (next start) end term next)))) (define (double-factorial number) (accumulate * 1 (if (=...
null
https://raw.githubusercontent.com/triffon/fp-2022-23/2fca66b8c82dca3063b0b6b55a41e4d54defdaee/exercises/inf2/03/06-double-factorial.rkt
racket
#lang racket дадена наготово (define (accumulate operation null-value start end term next) (if (> start end) null-value (operation (term start) (accumulate operation null-value (next start) end term next)))) (define (double-factorial number) (accumulate * 1 (if (=...
c7895185c6cd4ec59324d47fc82fba3df2ff2e542db19cea8860df43ee196a71
input-output-hk/marlowe-cardano
Aeson.hs
| Encoding and decoding of ' ByteString ' and serialisable values -- as base16 encoded JSON strings module Data.ByteString.Base16.Aeson ( EncodeBase16(..) , byteStringFromJSON , byteStringToJSON , unBase16 ) where import Data.Aeson (FromJSON, ToJSON(toJSON)) import qualified Data.Aeson as A import qualif...
null
https://raw.githubusercontent.com/input-output-hk/marlowe-cardano/78a3dbb1cd692146b7d1a32e1e66faed884f2432/libs/base16-aeson/src/Data/ByteString/Base16/Aeson.hs
haskell
as base16 encoded JSON strings
| Encoding and decoding of ' ByteString ' and serialisable values module Data.ByteString.Base16.Aeson ( EncodeBase16(..) , byteStringFromJSON , byteStringToJSON , unBase16 ) where import Data.Aeson (FromJSON, ToJSON(toJSON)) import qualified Data.Aeson as A import qualified Data.Aeson as Aeson import quali...
f5e80d30ca2871c214a43e90387cec271d8e8edab138658eef1c5d42b52f59c6
fjames86/frpc2
errors.lisp
Copyright ( c ) 2016 < > This code is licensed under the MIT license . (in-package #:frpc2) (define-condition rpc-error (error) ((msg :initarg :msg :reader rpc-error-msg)) (:report (lambda (c stream) (format stream "RPC-ERROR: ~A" (rpc-error-msg c))))) (defun rpc-error (format-string &rest ar...
null
https://raw.githubusercontent.com/fjames86/frpc2/6b7ec2c7d57a0918ecc3755af75ff183e24d7e85/errors.lisp
lisp
Copyright ( c ) 2016 < > This code is licensed under the MIT license . (in-package #:frpc2) (define-condition rpc-error (error) ((msg :initarg :msg :reader rpc-error-msg)) (:report (lambda (c stream) (format stream "RPC-ERROR: ~A" (rpc-error-msg c))))) (defun rpc-error (format-string &rest ar...
176e2fda24d3eb13113613a93ce6563d9df7837ea7129a185d863f4aaa79f803
haskell-graphql/graphql-api
Validation.hs
# LANGUAGE TypeApplications # module Validation (benchmarks) where import Protolude import Criterion (Benchmark, bench, nf) import GraphQL.Internal.Validation (findDuplicates) benchmarks :: [Benchmark] benchmarks = [ bench "findDuplicates" (nf findDuplicates exampleData) ] where exampleData :: [Int] e...
null
https://raw.githubusercontent.com/haskell-graphql/graphql-api/8ced344485cd638cee50eeb6b653baecea359406/benchmarks/Validation.hs
haskell
# LANGUAGE TypeApplications # module Validation (benchmarks) where import Protolude import Criterion (Benchmark, bench, nf) import GraphQL.Internal.Validation (findDuplicates) benchmarks :: [Benchmark] benchmarks = [ bench "findDuplicates" (nf findDuplicates exampleData) ] where exampleData :: [Int] e...
51e637d850cd93d891a173c471c002015ced31f2dadefaeb274e42c4f8a95e69
purebred-mua/purebred
UserAgent.hs
-- This file is part of purebred Copyright ( C ) 2021 -- -- purebred is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or -- (at your option) any later version. -- -...
null
https://raw.githubusercontent.com/purebred-mua/purebred/0dd659c8644fd6a4010ebe7be1a78fac22ca6be1/src/Purebred/Plugin/UserAgent.hs
haskell
This file is part of purebred purebred 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. ...
Copyright ( C ) 2021 it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or You should have received a copy of the GNU Affero General Public License # LANGUAGE FlexibleContexts # module Purebred.Plugin.UserAgent (plugin...
d6a460fe72c1fb893715d1561ee0a38948dd29563a356c6cad732e7ed38d4494
vvvvalvalval/datalog-rules
project.clj
(defproject vvvvalvalval/datalog-rules "0.1.0" :description "Utilities for managing Datalog rulesets from Clojure." :url "-rules" :license {:name "MIT" :url ""} :dependencies [[org.clojure/clojure "1.7.0"]] )
null
https://raw.githubusercontent.com/vvvvalvalval/datalog-rules/9cc5305725fd2c4ac266478ebf558d6886a1d69c/project.clj
clojure
(defproject vvvvalvalval/datalog-rules "0.1.0" :description "Utilities for managing Datalog rulesets from Clojure." :url "-rules" :license {:name "MIT" :url ""} :dependencies [[org.clojure/clojure "1.7.0"]] )
6aeb686453c2a99b0ebd92178b2693ba8a8b94d3109936286087586fca38203b
huangz1990/SICP-answers
79-equ.scm
;;; 79-equ.scm (load "p125-apply-generic.scm") (define (equ? x y) (apply-generic 'equ? x y))
null
https://raw.githubusercontent.com/huangz1990/SICP-answers/15e3475003ef10eb738cf93c1932277bc56bacbe/chp2/code/79-equ.scm
scheme
79-equ.scm
(load "p125-apply-generic.scm") (define (equ? x y) (apply-generic 'equ? x y))
fefe595db4eeb0359e6caadcb33709edbd9a9349e50189308aaf5f3596b63bd0
erlang/percept
percept_SUITE.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 2007 - 2016 . All Rights Reserved . %% Licensed under the Apache License , Version 2.0 ( the " License " ) ; %% you may not use this file except in compliance with the License. %% You may obtain a copy of the License at %% %% -2.0 %% %% Unless required by applic...
null
https://raw.githubusercontent.com/erlang/percept/44ee3ca98bcd37dfab691072e953131107ebec55/test/percept_SUITE.erl
erlang
%CopyrightBegin% 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 l...
Copyright Ericsson AB 2007 - 2016 . All Rights Reserved . Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(percept_SUITE). -include_lib("common_test/include/ct.hrl"). -export([all/0, suite/0]). -export([app/1, ...
51cf4dcaabfe700a561e000f949729fa46a99c69e0f1c0defb453b6e88c3cd3c
ghcjs/jsaddle-dom
CSSImportRule.hs
# LANGUAGE PatternSynonyms # -- For HasCallStack compatibility {-# LANGUAGE ImplicitParams, ConstraintKinds, KindSignatures #-} # OPTIONS_GHC -fno - warn - unused - imports # module JSDOM.Generated.CSSImportRule (getHref, getHrefUnsafe, getHrefUnchecked, getMedia, getStyleSheet, CSSImportRule(..), gTypeC...
null
https://raw.githubusercontent.com/ghcjs/jsaddle-dom/5f5094277d4b11f3dc3e2df6bb437b75712d268f/src/JSDOM/Generated/CSSImportRule.hs
haskell
For HasCallStack compatibility # LANGUAGE ImplicitParams, ConstraintKinds, KindSignatures #
# LANGUAGE PatternSynonyms # # OPTIONS_GHC -fno - warn - unused - imports # module JSDOM.Generated.CSSImportRule (getHref, getHrefUnsafe, getHrefUnchecked, getMedia, getStyleSheet, CSSImportRule(..), gTypeCSSImportRule) where import Prelude ((.), (==), (>>=), return, IO, Int, Float, Double, Bool(....
2cabead1e90b850554b08dc3954cd56cf7e8c8a8f0933204283c1ac56cc16565
brainsickcc/bscc
Main.hs
Copyright © 2012 -- This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or -- (at your option) any later version. -- -- This program is distributed in th...
null
https://raw.githubusercontent.com/brainsickcc/bscc/f47a83f5c77d0ef483e957032715ac4007fcb44d/Bscc/Main.hs
haskell
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 Affero General ...
Copyright © 2012 it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or You should have received a copy of the GNU Affero General Public License # LANGUAGE TemplateHaskell # | Implements the entry procedure of the bs...
b2d3e914075e0b8bb0d4cf38ad50f8877811b068f237f8c4be661d55105548af
YoshikuniJujo/test_haskell
SortResultHason.hs
# LANGUAGE ImportQualifiedPost # # LANGUAGE LambdaCase , OverloadedStrings # # OPTIONS_GHC -Wall -fno - warn - tabs # module SortResultHason where import Control.Arrow import Data.List qualified as L import Data.Map qualified as M import Data.Text qualified as T import Data.Time import Data.Hason data All = All { m...
null
https://raw.githubusercontent.com/YoshikuniJujo/test_haskell/56d5151151daf8e5fb8157cc27a801f17ebf0479/tribial/graph/try-graph/src/SortResultHason.hs
haskell
# LANGUAGE ImportQualifiedPost # # LANGUAGE LambdaCase , OverloadedStrings # # OPTIONS_GHC -Wall -fno - warn - tabs # module SortResultHason where import Control.Arrow import Data.List qualified as L import Data.Map qualified as M import Data.Text qualified as T import Data.Time import Data.Hason data All = All { m...
cfcf1e7b1f30223e17ce9b656f4b82e8f9deb46631f7dd3d6809243d4acbcfb8
facebookarchive/pfff
gtkEdit.ml
(**************************************************************************) (* Lablgtk *) (* *) (* This program is free software; you can redistribute it *) and/or ...
null
https://raw.githubusercontent.com/facebookarchive/pfff/ec21095ab7d445559576513a63314e794378c367/external/ocamlgtk/src/gtkEdit.ml
ocaml
************************************************************************ Lablgtk This program is free software; you can redistribute it comes with the library. ...
and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation version 2 , with the exception described in file COPYING which GNU Library General Public License for more details . You should have r...
92754b9c60df0627f448995aa37c35a2059016c3ca87d0a090cafd94e46dd3c5
anmonteiro/ocaml-mongodb
simple.ml
open Lwt.Infix module Client = Mongo_lwt_unix.Client type user = { name : string } [@@deriving bson] let example () = let config = Mongo.Config.create ~db:"anm" ~collection:"users" () in Lwt_unix.getaddrinfo config.Mongo.Config.host (string_of_int config.port) -numbers/protocol-numbers.xhtml Unix....
null
https://raw.githubusercontent.com/anmonteiro/ocaml-mongodb/535ae1b003b9c8a3844b92a78d2123881f2d404b/examples/simple.ml
ocaml
open Lwt.Infix module Client = Mongo_lwt_unix.Client type user = { name : string } [@@deriving bson] let example () = let config = Mongo.Config.create ~db:"anm" ~collection:"users" () in Lwt_unix.getaddrinfo config.Mongo.Config.host (string_of_int config.port) -numbers/protocol-numbers.xhtml Unix....
fbcf0f2e17f5f70179f112eb9c2dc884c5f9a36787f1ad9c9b4e673efa411350
spawnfest/eep49ers
erl_eval.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 1996 - 2018 . All Rights Reserved . %% Licensed under the Apache License , Version 2.0 ( the " License " ) ; %% you may not use this file except in compliance with the License. %% You may obtain a copy of the License at %% %% -2.0 %% %% Unless required by applic...
null
https://raw.githubusercontent.com/spawnfest/eep49ers/191098e12e2d4079a35aed7faf484d7710644014/lib/stdlib/src/erl_eval.erl
erlang
%CopyrightBegin% 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 l...
Copyright Ericsson AB 1996 - 2018 . All Rights Reserved . Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(erl_eval). An evaluator for Erlang abstract syntax . -export([exprs/2,exprs/3,exprs/4,expr/2,expr/3,expr/...
5d08a2416528841444704381b0c4f9810e6850de64bef72aaea618b7a9fa7f27
haskell-suite/base
Monad.hs
# LANGUAGE Trustworthy # # LANGUAGE CPP , NoImplicitPrelude # ----------------------------------------------------------------------------- -- | -- Module : Control.Monad Copyright : ( c ) The University of Glasgow 2001 -- License : BSD-style (see the file libraries/base/LICENSE) -- -- Maintainer :...
null
https://raw.githubusercontent.com/haskell-suite/base/1ee14681910c76d0a5a436c33ecf3289443e65ed/Control/Monad.hs
haskell
--------------------------------------------------------------------------- | Module : Control.Monad License : BSD-style (see the file libraries/base/LICENSE) Maintainer : Stability : provisional Portability : portable with some useful operations on monads. * Functor and monad classes * Fu...
# LANGUAGE Trustworthy # # LANGUAGE CPP , NoImplicitPrelude # Copyright : ( c ) The University of Glasgow 2001 The ' Functor ' , ' ' and ' MonadPlus ' classes , module Control.Monad ( Functor(fmap) , Monad((>>=), (>>), return, fail) , MonadPlus ( mzero , mplus )...
101b31074dde097b0bae2a9dc72fa9ee9015a0323a73ea11d63b0940b5ae508e
IvanIvanov/fp2013
accumulate.scm
(define (accumulate op initial items) (if (null? items) initial (op (car items) (accumulate op initial (cdr items)))))
null
https://raw.githubusercontent.com/IvanIvanov/fp2013/2ac1bb1102cb65e0ecbfa8d2fb3ca69953ae4ecf/lab1/homework4/accumulate.scm
scheme
(define (accumulate op initial items) (if (null? items) initial (op (car items) (accumulate op initial (cdr items)))))
341a80b764110e9e7655f0d222a5050f16b6f733b0c353b91227feb79611f5a5
lynaghk/jetty7-websockets-async
example.cljs
(ns com.keminglabs.jetty7-websockets-async.example (:require-macros [com.keminglabs.jetty7-websockets-async.example.macros :refer [p pp]] [cljs.core.async.macros :as m :refer [go]]) (:require [cljs.core.async :as async :refer [<! >! chan close! put! take! sliding-buffer ...
null
https://raw.githubusercontent.com/lynaghk/jetty7-websockets-async/ddfb01fb836e9403491afd45667efd86753f5e6e/example/src/cljs/com/keminglabs/jetty7_websockets_async/example.cljs
clojure
(ns com.keminglabs.jetty7-websockets-async.example (:require-macros [com.keminglabs.jetty7-websockets-async.example.macros :refer [p pp]] [cljs.core.async.macros :as m :refer [go]]) (:require [cljs.core.async :as async :refer [<! >! chan close! put! take! sliding-buffer ...
c3ecf93256f0593638e700632fac63919e19375f67ec38cfe88dc4f8b7e9df8e
ocaml-flambda/flambda-backend
flambda_to_fexpr.ml
open! Flambda.Import CR - someday mshinwell : share with Fexpr_to_flambda / move to let map_accum_left f env l = let next (acc, env) x = let y, env = f env x in y :: acc, env in let acc, env = List.fold_left next ([], env) l in List.rev acc, env module type Convertible_id = sig type t type fex...
null
https://raw.githubusercontent.com/ocaml-flambda/flambda-backend/e2711acd740fb85b2672c8c72e07d3558edd1b57/middle_end/flambda2/parser/flambda_to_fexpr.ml
ocaml
Unlikely but possible that, say, both x and x_1 are used; in this * case we'll end up with x_1_1 CR-soon lmaurer: Too much duplication with Name_map.bind Unlikely but possible that, say, both x and x_1 are used; in this * case we'll end up with x_1_1 We don't need the name map for non-local s...
open! Flambda.Import CR - someday mshinwell : share with Fexpr_to_flambda / move to let map_accum_left f env l = let next (acc, env) x = let y, env = f env x in y :: acc, env in let acc, env = List.fold_left next ([], env) l in List.rev acc, env module type Convertible_id = sig type t type fex...
2141772065c0f6a6d49f2626587c05e2a2a0b132da256eca3ab19e32ad31b378
elaforge/karya
Val_test.hs
Copyright 2013 -- This program is distributed under the terms of the GNU General Public -- License 3.0, see COPYING or -3.0.txt module Derive.C.Prelude.Val_test where import qualified Derive.Call.CallTest as CallTest import qualified Derive.DeriveT as DeriveT import qualified Derive.DeriveTest as DeriveTest import...
null
https://raw.githubusercontent.com/elaforge/karya/8ea15e6a5fb57e2f15f8c19836751e315f9c09f2/Derive/C/Prelude/Val_test.hs
haskell
This program is distributed under the terms of the GNU General Public License 3.0, see COPYING or -3.0.txt prev Within a note works though. next It's at the end of the ruler so it can't go forwards. Take the backwards distance instead. Whole step works even though there isn't a whole step left.
Copyright 2013 module Derive.C.Prelude.Val_test where import qualified Derive.Call.CallTest as CallTest import qualified Derive.DeriveT as DeriveT import qualified Derive.DeriveTest as DeriveTest import qualified Derive.Score as Score import qualified Perform.NN as NN import qualified Ui.Meter.Meter as Meter impo...
d8f78e4a7d4e5790bedac1c6cd866e6450b738f2723c86ff06ba6d9ff2059fcb
ralsei/graphite
lines.rkt
#lang racket/base (require data/ddict fancy-app pict (prefix-in plot: plot/no-gui) plot/utils racket/contract/base "aes.rkt" "renderer.rkt" "util.rkt") (provide (contract-out [lines (->* () (#:x-min (or/c rational? #f) ...
null
https://raw.githubusercontent.com/ralsei/graphite/9b3de31156543dd135e6286132a88a48af2b8298/graphite-lib/lines.rkt
racket
#lang racket/base (require data/ddict fancy-app pict (prefix-in plot: plot/no-gui) plot/utils racket/contract/base "aes.rkt" "renderer.rkt" "util.rkt") (provide (contract-out [lines (->* () (#:x-min (or/c rational? #f) ...
57afd88777ec6e87fca94537d026ce25d3cfced5f14007aadf899d386fe5f79e
untangled-web/untangled-spec
macros.clj
(ns untangled-spec.impl.macros (:require [untangled-spec.selectors :as sel])) (defn cljs-env? "" [env] (boolean (:ns env))) (defn if-cljs [env cljs clj] (if (cljs-env? env) cljs clj)) (defmacro try-report [block & body] (let [prefix (if-cljs &env "cljs.test" "clojure.test") do-report (symbol pr...
null
https://raw.githubusercontent.com/untangled-web/untangled-spec/0d44863f627ed7311677b438b88bd6d424249507/src/untangled_spec/impl/macros.clj
clojure
(ns untangled-spec.impl.macros (:require [untangled-spec.selectors :as sel])) (defn cljs-env? "" [env] (boolean (:ns env))) (defn if-cljs [env cljs clj] (if (cljs-env? env) cljs clj)) (defmacro try-report [block & body] (let [prefix (if-cljs &env "cljs.test" "clojure.test") do-report (symbol pr...
31eeb2436bdefbc58c4c8e04ddc80a85c68086d3e3f27a7a1ff6eb74ff335caa
Kalimehtar/gtk-cffi
main.lisp
;; -*- Mode: LISP; Syntax: COMMON-LISP; Package: emacs; -*- (in-package :emacs) (declaim (optimize safety debug)) (defvar *file*) (defvar *region*) (defvar *encoding*) (defun on-key-press (widget event &rest rest) (declare (ignore widget rest)) (let ((ret (when *entered-sequence* t))) (setf *entered-seque...
null
https://raw.githubusercontent.com/Kalimehtar/gtk-cffi/fbd8a40a2bbda29f81b1a95ed2530debfe2afe9b/cl-emacs/main.lisp
lisp
-*- Mode: LISP; Syntax: COMMON-LISP; Package: emacs; -*- filename fetched
(in-package :emacs) (declaim (optimize safety debug)) (defvar *file*) (defvar *region*) (defvar *encoding*) (defun on-key-press (widget event &rest rest) (declare (ignore widget rest)) (let ((ret (when *entered-sequence* t))) (setf *entered-sequence* (nconc *entered-sequence* (...
771cd88fafbd302885f2cfccc97847a99f9895502fa1157ee90e297cec540387
jvanbruegge/Megarecord
Main.hs
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE OverloadedLabels # # LANGUAGE TypeApplications # # LANGUAGE TypeFamilies # # LANGUAGE TypeOperators # # LANGUAGE UndecidableInstances # module Main where import Data.Kind.Row (type (&), type (:::), Empty) import Da...
null
https://raw.githubusercontent.com/jvanbruegge/Megarecord/4b62620a57edf4162d4ac07ec0f527d54872d010/app/Main.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE OverloadedLabels # # LANGUAGE TypeApplications # # LANGUAGE TypeFamilies # # LANGUAGE TypeOperators # # LANGUAGE UndecidableInstances # module Main where import Data.Kind.Row (type (&), type (:::), Empty) import Da...