_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
5f69edb113d6a5a1a36991b238ab737456c358a78ff8a1632b9c7fb3fe6cbb45
brendanhay/terrafomo
Types.hs
-- This module was auto-generated. If it is modified, it will not be overwritten. -- | Module : . Local . Types Copyright : ( c ) 2017 - 2018 License : Mozilla Public License , v. 2.0 . Maintainer : < brendan.g.hay+ > -- Stability : auto-generated Portability : non - portable ( GHC ext...
null
https://raw.githubusercontent.com/brendanhay/terrafomo/387a0e9341fb9cd5543ef8332dea126f50f1070e/provider/terrafomo-builtins/src/Terrafomo/Local/Types.hs
haskell
This module was auto-generated. If it is modified, it will not be overwritten. | Stability : auto-generated import Formatting (Format, (%))
Module : . Local . Types Copyright : ( c ) 2017 - 2018 License : Mozilla Public License , v. 2.0 . Maintainer : < brendan.g.hay+ > Portability : non - portable ( GHC extensions ) module Terrafomo.Local.Types where import Data . Text ( Text ) import Terrafomo import Terrafomo . ...
ab6aba14a2420f8677ca7347ee18d75675dec675cd8f01593f20a78736199687
agrafix/superevent
Types.hs
{-# LANGUAGE StrictData #-} # LANGUAGE MultiParamTypeClasses # # LANGUAGE FunctionalDependencies # # LANGUAGE GeneralizedNewtypeDeriving # module SuperEvent.Store.Types where import Data.Aeson import Data.Conduit import Data.Hashable import Data.Int import Data.Text (Text) import Data.Time import Data.UUID (UUID) impo...
null
https://raw.githubusercontent.com/agrafix/superevent/c56c60c1cc0c55ea21e19c7892aa67051d07f050/src/SuperEvent/Store/Types.hs
haskell
# LANGUAGE StrictData #
# LANGUAGE MultiParamTypeClasses # # LANGUAGE FunctionalDependencies # # LANGUAGE GeneralizedNewtypeDeriving # module SuperEvent.Store.Types where import Data.Aeson import Data.Conduit import Data.Hashable import Data.Int import Data.Text (Text) import Data.Time import Data.UUID (UUID) import Data.Vector (Vector) new...
15104817ebabc42772625477a9f2b65f6e2dac79b159eab35b3fbc427691c4f5
TrustInSoft/tis-kernel
per_stmt_slevel.mli
(**************************************************************************) (* *) This file is part of . (* *) is a fork of Frama - C. Al...
null
https://raw.githubusercontent.com/TrustInSoft/tis-kernel/748d28baba90c03c0f5f4654d2e7bb47dfbe4e7d/src/plugins/value/slevel/per_stmt_slevel.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 Frama - C. Copyright ( C ) 2007 - 2015 ...
bf49b5683e89efa2cb692b4795d2a1c81a0793fc5940794204fb17b155057a75
ermine-language/ermine
Matching.hs
{-# LANGUAGE MultiWayIf #-} {-# LANGUAGE RankNTypes #-} # LANGUAGE DeriveFunctor # # LANGUAGE PatternGuards # # LANGUAGE TupleSections # # LANGUAGE DeriveFoldable # # LANGUAGE KindSignatures # # LANGUAGE TemplateHaskell # # LANGUAGE ParallelListComp # {-# LANGUAGE DeriveTraversable #-} # LANGUAGE FlexibleInstances # {-...
null
https://raw.githubusercontent.com/ermine-language/ermine/bd58949ab56311be9e0d2506a900f3d77652566b/src/Ermine/Pattern/Matching.hs
haskell
# LANGUAGE MultiWayIf # # LANGUAGE RankNTypes # # LANGUAGE DeriveTraversable # # LANGUAGE OverloadedStrings # ------------------------------------------------------------------ | Stability : experimental Portability: non-portable ------------------------------------------------------------------ * Matching * Com...
# LANGUAGE DeriveFunctor # # LANGUAGE PatternGuards # # LANGUAGE TupleSections # # LANGUAGE DeriveFoldable # # LANGUAGE KindSignatures # # LANGUAGE TemplateHaskell # # LANGUAGE ParallelListComp # # LANGUAGE FlexibleInstances # # LANGUAGE ScopedTypeVariables # # LANGUAGE MultiParamTypeClasses # # LANGUAGE FunctionalDepe...
7bad401a8c5a0222b0c2d2773c0a8c83c12bcb5a757b72fdad11a4755bf18495
scrintal/heroicons-reagent
circle_stack.cljs
(ns com.scrintal.heroicons.mini.circle-stack) (defn render [] [:svg {:xmlns "" :viewBox "0 0 20 20" :fill "currentColor" :aria-hidden "true"} [:path {:fillRule "evenodd" :d "M10 1c3.866 0 7 1.79 7 4s-3.134 4-7 4-7-1.79-7-4 3.134-4 7-4zm5.694 8.13c.464-...
null
https://raw.githubusercontent.com/scrintal/heroicons-reagent/572f51d2466697ec4d38813663ee2588960365b6/src/com/scrintal/heroicons/mini/circle_stack.cljs
clojure
(ns com.scrintal.heroicons.mini.circle-stack) (defn render [] [:svg {:xmlns "" :viewBox "0 0 20 20" :fill "currentColor" :aria-hidden "true"} [:path {:fillRule "evenodd" :d "M10 1c3.866 0 7 1.79 7 4s-3.134 4-7 4-7-1.79-7-4 3.134-4 7-4zm5.694 8.13c.464-...
4dfeaf5dcf46fba8d436bae59be3dd4b193ee224e7bd791c6090f810712e8137
brendanhay/gogol
GetIamPolicy.hs
# LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # # LANGUAGE DerivingStrategies # # LANGUAGE DuplicateRecordFields # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE PatternSynonyms # # LANGUAGE RecordWildCards # {-# LANGUAGE St...
null
https://raw.githubusercontent.com/brendanhay/gogol/fffd4d98a1996d0ffd4cf64545c5e8af9c976cda/lib/services/gogol-storage/gen/Gogol/Storage/Objects/GetIamPolicy.hs
haskell
# LANGUAGE OverloadedStrings # # LANGUAGE StrictData # | Stability : auto-generated /See:/ </ Cloud Storage JSON API Reference> for @storage.objects.getIamPolicy@. * Resource ** Constructing a Request | A resource alias for @storage.objects.getIamPolicy@ method which the /See:/ 'newStorageObjectsGetIamPolic...
# LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # # LANGUAGE DerivingStrategies # # LANGUAGE DuplicateRecordFields # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # # LANGUAGE PatternSynonyms # # LANGUAGE RecordWildCards # # LANGUAGE TypeFamilies # # LANGUAGE TypeOperators...
1996db5e667359908d421ad1ed571757137b8550e167657958da3adc7435d2c5
opencog/learn
connector-merge-tricon.scm
; ; connector-merge-tricon.scm Unit test for merging of Connectors - two single connectors ; 3 - cluster ; Tests merging of three words into a single word - class . ; The focus here is to make sure that that when the words to ; be merged also appear in Connectors, that those are merged ; correctly, too. This trigge...
null
https://raw.githubusercontent.com/opencog/learn/e00a803620491a7df4fc0d6b3dda2879a9dcb8cb/tests/merge/connector-merge-tricon.scm
scheme
connector-merge-tricon.scm 3 - cluster The focus here is to make sure that that when the words to be merged also appear in Connectors, that those are merged correctly, too. This triggers some extra merge logic, beyond the basic case. --------------------------------------------------------------- to the clu...
Tests merging of three words into a single word - class . Created May 2021 (use-modules (opencog) (opencog matrix)) (use-modules (opencog nlp)) (use-modules (opencog learn)) (use-modules (opencog test-runner)) (use-modules (srfi srfi-64)) (opencog-test-runner) (load "connector-setup.scm") (load "connector-data....
175fd10883fabef492a2d382f486c53fcd6e7bc4ca84595433ab6e06b3ade9fd
cmr-exchange/cmr-client
graph.clj
(ns cmr.client.graph "The Clojure implementation of the CMR graph client." (:require [cmr.client.base.impl :as base-impl] [cmr.client.base.protocol :as base-api] [cmr.client.common.util :as util] [cmr.client.http.core :as http] [cmr.client.graph.impl :as impl] [cmr.client.graph.protocol :as api] ...
null
https://raw.githubusercontent.com/cmr-exchange/cmr-client/0b4dd4114e3b5ed28fc5b57db0f8dcd8773c1c14/src/clj/cmr/client/graph.clj
clojure
Protocols &tc. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Implementation ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ; ;
(ns cmr.client.graph "The Clojure implementation of the CMR graph client." (:require [cmr.client.base.impl :as base-impl] [cmr.client.base.protocol :as base-api] [cmr.client.common.util :as util] [cmr.client.http.core :as http] [cmr.client.graph.impl :as impl] [cmr.client.graph.protocol :as api] ...
b762a07c5376e76ff6312903fda97b178a1defe48fc1ad17dc2b195b4485bdb7
yesodweb/persistent
PersistWithSpec.hs
# LANGUAGE DataKinds # {-# LANGUAGE GADTs #-} # LANGUAGE DerivingStrategies # # LANGUAGE ExistentialQuantification # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE QuasiQuotes # # LANGUAGE StandaloneDeriving # # LAN...
null
https://raw.githubusercontent.com/yesodweb/persistent/c2751f5d491877a5218cd9ad90944b6744917e59/persistent/test/Database/Persist/TH/PersistWithSpec.hs
haskell
# LANGUAGE GADTs # # LANGUAGE OverloadedStrings #
# LANGUAGE DataKinds # # LANGUAGE DerivingStrategies # # LANGUAGE ExistentialQuantification # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # # LANGUAGE QuasiQuotes # # LANGUAGE StandaloneDeriving # # LANGUAGE TemplateHaskell # # LANGUAGE TypeApplications # # LA...
5b56214f5c9105e18b204764f201958aa1307ac441b6f5ab60122999891eabf4
OCADml/OSCADml
debug.mli
open OCADml (** [show_path2 f path] Return a union of 3d shapes provided by placing shapes (computed by applying [f] to the index) at each point along [path]. *) val show_path2 : (int -> Scad.d3) -> Path2.t -> Scad.d3 (** [show_path3 f path] Return a union of 3d shapes provided by placing shapes (comput...
null
https://raw.githubusercontent.com/OCADml/OSCADml/d2f64a3f6454ff37a3c725b619c6a89252af789d/lib/debug.mli
ocaml
* [show_path2 f path] Return a union of 3d shapes provided by placing shapes (computed by applying [f] to the index) at each point along [path]. * [show_path3 f path] Return a union of 3d shapes provided by placing shapes (computed by applying [f] to the index) at each point along [path]. * [show_me...
open OCADml val show_path2 : (int -> Scad.d3) -> Path2.t -> Scad.d3 val show_path3 : (int -> Scad.d3) -> Path3.t -> Scad.d3 val show_mesh : (int -> Scad.d3) -> Mesh.t -> Scad.d3
ca9ccd27121df09fb1be009c42ac6d3764ac4fb78f7e5f18aa67012eca7bacc4
travelping/eradius
eradius_counter_aggregator.erl
-module(eradius_counter_aggregator). -behaviour(gen_server). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). -export([start_link/0, reset/0, pull/0, read/0]). -include("eradius_lib.hrl"). -define(INIT_HB, 1000). -define(INTERVAL_HB, 5000). -record(state, { me ...
null
https://raw.githubusercontent.com/travelping/eradius/bac1a92f547ac4f8e009e9052f28c430b6f9b82d/src/eradius_counter_aggregator.erl
erlang
@doc read counters ------------------------------------------------------------------------------------------ -- gen_server Callbacks -- unused callbacks ------------------------------------------------------------------------------------------ -- helper functions
-module(eradius_counter_aggregator). -behaviour(gen_server). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). -export([start_link/0, reset/0, pull/0, read/0]). -include("eradius_lib.hrl"). -define(INIT_HB, 1000). -define(INTERVAL_HB, 5000). -record(state, { me ...
19383aa10c56960a5cafba162b1f702057057cbcac6254efad7a9c92f8cdd2c1
basho/riak_test
ts_cluster_select_pass_2.erl
%% ------------------------------------------------------------------- %% Copyright ( c ) 2015 Basho Technologies , Inc. %% 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 Li...
null
https://raw.githubusercontent.com/basho/riak_test/8170137b283061ba94bc85bf42575021e26c929d/tests/ts_cluster_select_pass_2.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 permissio...
Copyright ( c ) 2015 Basho Technologies , Inc. 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 -module(ts_cluster_select_pass_...
fbf297df5d9023ccd823e5abf12ae3f2563a1383bc46d96dbfeb7232a33dbdb7
erlang/otp
diameter_gen_tcp_SUITE.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 2014 - 2023 . 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 applicab...
null
https://raw.githubusercontent.com/erlang/otp/2b397d7e5580480dc32fa9751db95f4b89ff029e/lib/diameter/test/diameter_gen_tcp_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 lan...
Copyright Ericsson AB 2014 - 2023 . 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(diameter_gen_tcp_SUITE). -export([run/0, run/1]). -export([suite/0, all/0, sen...
4e2af8df665e8229a49df4eb99772e1ffcfde061f3e1960e970f9b25f07014b6
benrady/specific
test_double_spec.clj
(ns specific.test-double-spec (:require [clojure.spec.alpha :as spec] [specific [matchers :as matchers] [sample :as sample]]) (:use [clojure.test] [specific.report-stub] [specific.test-double])) (defn no-spec []) (defn no-ret [a]) (spec/fdef no-ret ...
null
https://raw.githubusercontent.com/benrady/specific/e1b790f2be2d577e49817472177bcc0136a2545a/test/specific/test_double_spec.clj
clojure
Can handle functions with partial specs
(ns specific.test-double-spec (:require [clojure.spec.alpha :as spec] [specific [matchers :as matchers] [sample :as sample]]) (:use [clojure.test] [specific.report-stub] [specific.test-double])) (defn no-spec []) (defn no-ret [a]) (spec/fdef no-ret ...
5f0c5e0304cc7a49bb920746880f1a4d9338b8d78852f46bb78669e2b5e72f57
archambaultv/sexpresso
Spec.hs
module Main where import Test.Tasty import SExpr_Unittests import Parse_Unittests import Print_Unittests import SchemeR5RS_Unittests main :: IO () main = defaultMain tests tests :: TestTree tests = testGroup "tests" [sexpTestTree, parseTestTree, printTestTree, r5rsTestTree]
null
https://raw.githubusercontent.com/archambaultv/sexpresso/b252fe2b3d7703d62cf0d65579949960f83cd7ef/test/Spec.hs
haskell
module Main where import Test.Tasty import SExpr_Unittests import Parse_Unittests import Print_Unittests import SchemeR5RS_Unittests main :: IO () main = defaultMain tests tests :: TestTree tests = testGroup "tests" [sexpTestTree, parseTestTree, printTestTree, r5rsTestTree]
d7a5f5cea7e47b2f3d4192a702e90abc2f493333a3e544bf851c6356efa701c6
serperu/secer
secer_proper3.erl
-module(secer_proper3). -export([proper_based/0]). proper_based() -> PoisRels = rele1(), ExecFun = funs(), % try register(cuterIn , spawn(secer_trace , init , [ ] ) ) , register(tracer,spawn(secer_trace,init,[])), [{Old,New}|_] = PoisRels, FileOld = atom_to_list(element(1,Old)), FileNew = atom_to...
null
https://raw.githubusercontent.com/serperu/secer/ffe2f9602356c34c9465c44534c82cc758b809b5/src/secer_proper3.erl
erlang
try 0 -> ModTmp1 = list_to_atom(filename:basename(FileOld,".erl")++"Tmp"), execute_input(ModTmp1,ModTmp2,FunName,[],CMode); Inputs = {ok, Fd} = file:open(?TMP_PATH++"cuter.txt", [write]), Self = self(), Ref = make_ref(), spawn(fun() -> Self ! {cover_compilation(FileOld),Ref} end), receive {_,Ref} ...
-module(secer_proper3). -export([proper_based/0]). proper_based() -> PoisRels = rele1(), ExecFun = funs(), register(cuterIn , spawn(secer_trace , init , [ ] ) ) , register(tracer,spawn(secer_trace,init,[])), [{Old,New}|_] = PoisRels, FileOld = atom_to_list(element(1,Old)), FileNew = atom_to_list(el...
22d378bff786ca80ea2b3c4ab39263c4e2959fee0c24ea9e99a4950325a518f3
S8A/htdp-exercises
ex278.rkt
The first three lines of this file were inserted by . They record metadata ;; about the language level of this file in a form that our tools can easily process. #reader(lib "htdp-intermediate-reader.ss" "lang")((modname ex278) (read-case-sensitive #t) (teachpacks ((lib "batch-io.rkt" "teachpack" "2htdp") (lib "unive...
null
https://raw.githubusercontent.com/S8A/htdp-exercises/578e49834a9513f29ef81b7589b28081c5e0b69f/ex278.rkt
racket
about the language level of this file in a form that our tools can easily process. Graphical constants width in base units A Direction is one of the following: A Worm is a structure: (make-worm Direction [NEList-of Posn]) interpretation combines direction in which the worm is moving with the positions of its ...
The first three lines of this file were inserted by . They record metadata #reader(lib "htdp-intermediate-reader.ss" "lang")((modname ex278) (read-case-sensitive #t) (teachpacks ((lib "batch-io.rkt" "teachpack" "2htdp") (lib "universe.rkt" "teachpack" "2htdp") (lib "image.rkt" "teachpack" "2htdp"))) (htdp-settings #...
c21d5a2e86d0dfd6f77787817ff11fab89c3883af7959b1929a73afdc6adab50
tomgr/libcspm
ValuePrettyPrinter.hs
# LANGUAGE FlexibleContexts , FlexibleInstances , IncoherentInstances , MultiParamTypeClasses , ScopedTypeVariables , TypeSynonymInstances , UndecidableInstances # MultiParamTypeClasses, ScopedTypeVariables, TypeSynonymInstances, UndecidableInstances #-} module CSPM.Evaluator.ValuePrettyPrinter ( ...
null
https://raw.githubusercontent.com/tomgr/libcspm/24d1b41954191a16e3b5e388e35f5ba0915d671e/src/CSPM/Evaluator/ValuePrettyPrinter.hs
haskell
Compression unsucesful TODO: select whichever binds more TODO: select whichever binds more Try and compress Compression succesful | Pretty prints the given process and all processes that it depends upon.
# LANGUAGE FlexibleContexts , FlexibleInstances , IncoherentInstances , MultiParamTypeClasses , ScopedTypeVariables , TypeSynonymInstances , UndecidableInstances # MultiParamTypeClasses, ScopedTypeVariables, TypeSynonymInstances, UndecidableInstances #-} module CSPM.Evaluator.ValuePrettyPrinter ( ...
6080c0afd5ada481c47cf243303593dda66ce31e90c0e37f66ba2bdb734ab246
charlescearl/DeepRacket
test-tensoradd.rkt
#lang typed/racket (require typed/rackunit typed/rackunit/text-ui) (require "cudnn-api.rkt") (require "cuda-api.rkt") (require "mem-utils.rkt") (require "cudnn-tensor.rkt") (require math/array) (define add-tests (test-suite "Test addition of tensors" (test-case "Check addition of two tensors" (let* ...
null
https://raw.githubusercontent.com/charlescearl/DeepRacket/767560aab5c56c03e951e005b5b983b435afe7eb/test-tensoradd.rkt
racket
Copy Host to GPU Do we need workspace? Do we need reserve space? Check everything tensor-b is now 2.0 Copy Host to GPU Do we need workspace? Do we need reserve space? (cudaDeviceSynchronize) (cudaDeviceSynchronize) Check everything tensor-b is now 2.0 (cudaDeviceSynchronize)
#lang typed/racket (require typed/rackunit typed/rackunit/text-ui) (require "cudnn-api.rkt") (require "cuda-api.rkt") (require "mem-utils.rkt") (require "cudnn-tensor.rkt") (require math/array) (define add-tests (test-suite "Test addition of tensors" (test-case "Check addition of two tensors" (let* ...
4c28413a6b89e3325dc2554a6ad079a421b7e5f186c595b38cd3d9265c5ed2c4
jonsterling/dreamtt
Reader.mli
(** This module contains the interface and functors for access and scoped updates of local state. *) (** The operations of a reader monad *) module type Ops = sig type 'a m type local val read : local m val locally : (local -> local) -> 'a m -> 'a m end (** The reader monad transformer interface. *) module t...
null
https://raw.githubusercontent.com/jonsterling/dreamtt/aa30a57ca869e91a295e586773a892c6601b5ddb/basis/Reader.mli
ocaml
* This module contains the interface and functors for access and scoped updates of local state. * The operations of a reader monad * The reader monad transformer interface. * The reader monad, i.e. the instance of the transformer at the identity monad.
module type Ops = sig type 'a m type local val read : local m val locally : (local -> local) -> 'a m -> 'a m end module type T = sig include Monad.Trans include Ops with type 'a m := 'a m val read : local m val locally : (local -> local) -> 'a m -> 'a m val reader : (local -> 'a n) -> 'a m val ...
878cfd7f2fcf2b86f32b7d2fd7f4de642ece01e216aaa66bc05b2aa0b5b0ea61
dafny-lang/xdsmith
normalize.rkt
Copyright Amazon.com , Inc. or its affiliates . All Rights Reserved . SPDX - License - Identifier : MIT ;; This module provides functions to normalize outputs from each backends #lang racket (provide normalize-cs normalize-go normalize-java normalize-js) (define readtable/fundamental ...
null
https://raw.githubusercontent.com/dafny-lang/xdsmith/ce04008226ec8357b7aa68a0bd962011c5b8cfb3/xdsmith/normalize.rkt
racket
This module provides functions to normalize outputs from each backends don't treat ; as comment read argument types read return type one exists already ; another because we insert it ourselves normalize multiset and map
Copyright Amazon.com , Inc. or its affiliates . All Rights Reserved . SPDX - License - Identifier : MIT #lang racket (provide normalize-cs normalize-go normalize-java normalize-js) (define readtable/fundamental (make-readtable #f # \a # f #\" #\a #f #\' #\a #f #\| #\...
eeb95e5135866863958b607b851c551390d162baab61865e180c52012cef2704
dparis/gen-phzr
key.cljs
(ns phzr.key (:require [phzr.impl.utils.core :refer [clj->phaser phaser->clj]] [phzr.impl.extend :as ex] [cljsjs.phaser])) (defn ->Key "If you need more fine-grained control over the handling of specific keys you can create and use Phaser.Key objects. Parameters: * game (Phaser.Game)...
null
https://raw.githubusercontent.com/dparis/gen-phzr/e4c7b272e225ac343718dc15fc84f5f0dce68023/out/key.cljs
clojure
a hard reset will."
(ns phzr.key (:require [phzr.impl.utils.core :refer [clj->phaser phaser->clj]] [phzr.impl.extend :as ex] [cljsjs.phaser])) (defn ->Key "If you need more fine-grained control over the handling of specific keys you can create and use Phaser.Key objects. Parameters: * game (Phaser.Game)...
7eed56661af881795893a79893db432e434381bca03a72e9c31249960c03e3f7
chenyukang/eopl
proc-lang.scm
( load - relative " .. /libs / init.scm " ) ( load - relative " .. /libs / environments.scm " ) (define the-lexical-spec '((whitespace (whitespace) skip) (comment ("%" (arbno (not #\newline))) skip) (identifier (letter (arbno (or letter digit "_" "-" "?"))) symbol) (number (digit (arbno digit))...
null
https://raw.githubusercontent.com/chenyukang/eopl/0406ff23b993bfe020294fa70d2597b1ce4f9b78/ch3/base/proc-lang.scm
scheme
sllgen boilerplate ;;;;;;;;;;;;;;;; ; ; proc? : SchemeVal -> Bool procedure : Var * Exp * Env -> Proc an expressed value is either a number, a boolean or a procval. extractors: expval->num : ExpVal -> Int expval->bool : ExpVal -> Bool expval->proc : ExpVal -> Proc the interpreter ;;;;;;;;;;;;;;;;
( load - relative " .. /libs / init.scm " ) ( load - relative " .. /libs / environments.scm " ) (define the-lexical-spec '((whitespace (whitespace) skip) (comment ("%" (arbno (not #\newline))) skip) (identifier (letter (arbno (or letter digit "_" "-" "?"))) symbol) (number (digit (arbno digit))...
67a9d111b839dc6e8fa8ba4add29cc068bbbf534f5453f9d33b757469ae55b5f
g000001/tagger
corpus-protocol.lisp
-*- Package : TDB ; Syntax : Common - Lisp ; Mode : Lisp ; Base : 10 -*- Copyright ( c ) 1989 -- 1994 by Xerox Corporation (cl:in-package :tdb) (eval-when (compile eval load) (use-package :cl-extensions)) (eval-when (compile eval load) (export '(corpus initialize-corpus open-corpus update-corpus close-corpus ...
null
https://raw.githubusercontent.com/g000001/tagger/a4e0650c55aba44250871b96e2220e1b4953c6ab/orig/src/corpus/corpus-protocol.lisp
lisp
Syntax : Common - Lisp ; Mode : Lisp ; Base : 10 -*- corpus protocol A corpus is a collection of documents identified by a unique integer id. essential methods Function is called with arg id for every valid id in corpus The iteration can be bounded by specifying start and/or end ids. containing the contents of d...
Copyright ( c ) 1989 -- 1994 by Xerox Corporation (cl:in-package :tdb) (eval-when (compile eval load) (use-package :cl-extensions)) (eval-when (compile eval load) (export '(corpus initialize-corpus open-corpus update-corpus close-corpus open-doc close-doc byte28 doc-title display-doc match-doc-...
9d84f7a93d46eeffdd2f399e54d3df859d7b6f7cc7ee77ab60fe0fc40a57a4ed
LLazarek/mutate
main.rkt
#lang racket/base (require "define.rkt" "quick.rkt") (provide (all-from-out "define.rkt") (all-from-out "quick.rkt"))
null
https://raw.githubusercontent.com/LLazarek/mutate/297eae74e1969e21ee24382a63165af37631690a/mutate-lib/main.rkt
racket
#lang racket/base (require "define.rkt" "quick.rkt") (provide (all-from-out "define.rkt") (all-from-out "quick.rkt"))
1b1d55e956ecadb798c9f959493cd478e1be9736a3c0e250c618eda9b31c68ee
fosskers/kanji
nanq-site.hs
{-# LANGUAGE OverloadedStrings #-} # LANGUAGE FlexibleInstances # # LANGUAGE TypeOperators # # LANGUAGE DataKinds # module Main where import qualified Data.Text as T import Lucid import Network.Wai import Network.Wai.Handler.Warp import Pages.About import Pages.Base i...
null
https://raw.githubusercontent.com/fosskers/kanji/93dd7d16d1a3690db36ca0ffbeb21e05083c42ea/nanq-site/nanq-site.hs
haskell
# LANGUAGE OverloadedStrings # - | All endpoints for our server.
# LANGUAGE FlexibleInstances # # LANGUAGE TypeOperators # # LANGUAGE DataKinds # module Main where import qualified Data.Text as T import Lucid import Network.Wai import Network.Wai.Handler.Warp import Pages.About import Pages.Base import Pages.Analysis impo...
a4a1fb780524d81b3492eaa9093f3cca259179f6d21ea1139f7e54991d6251d5
clojure-interop/aws-api
Md5Utils.clj
(ns com.amazonaws.util.Md5Utils "Utility methods for computing MD5 sums." (:refer-clojure :only [require comment defn ->]) (:import [com.amazonaws.util Md5Utils])) (defn ->md-5-utils "Constructor." (^Md5Utils [] (new Md5Utils ))) (defn *compute-md-5-hash "Computes the MD5 hash of the data in the given...
null
https://raw.githubusercontent.com/clojure-interop/aws-api/59249b43d3bfaff0a79f5f4f8b7bc22518a3bf14/com.amazonaws.util/src/com/amazonaws/util/Md5Utils.clj
clojure
(ns com.amazonaws.util.Md5Utils "Utility methods for computing MD5 sums." (:refer-clojure :only [require comment defn ->]) (:import [com.amazonaws.util Md5Utils])) (defn ->md-5-utils "Constructor." (^Md5Utils [] (new Md5Utils ))) (defn *compute-md-5-hash "Computes the MD5 hash of the data in the given...
362416c9aed4c6242064dedf155f536a4fc8d4f92d3943d2f85c5034a2b57b17
pink-gorilla/ui-gorilla
video.cljs
(ns ui.video (:require ["react-player" :as rp])) (defn ^{:category :ui} video "plays Youtube videos usage: [:p/player {:url url :playing false}] for more config options, see: -player " [props] [:> rp/default props]) ; {:url url :playing true}
null
https://raw.githubusercontent.com/pink-gorilla/ui-gorilla/3cc408b398d30a8e54c15f863fbabece9f036209/src/ui/video.cljs
clojure
{:url url :playing true}
(ns ui.video (:require ["react-player" :as rp])) (defn ^{:category :ui} video "plays Youtube videos usage: [:p/player {:url url :playing false}] for more config options, see: -player " [props]
93f1d0cb5f99b36c994f1ed795389f3363a30446552df52c921aef21a1cc650b
int-index/slay
Gtk.hs
{-# OPTIONS -Wno-type-defaults #-} # LANGUAGE OverloadedLabels # module Slay.Gtk ( example ) where import Control.Monad.IO.Class import Data.Fixed import Numeric.NonNegative import Numeric.Natural import Data.IORef import Data.Word import Data.Foldable import Data.List.NonEmpty as NonEmpty import Lens.Micro.Plat...
null
https://raw.githubusercontent.com/int-index/slay/1c9d39b8cb4f32f0b4778677c21ebb85cc1cddf7/gtk/src/Slay/Gtk.hs
haskell
# OPTIONS -Wno-type-defaults # invariant: appStateCollageRender = mkCollageRender label the GUI thread
# LANGUAGE OverloadedLabels # module Slay.Gtk ( example ) where import Control.Monad.IO.Class import Data.Fixed import Numeric.NonNegative import Numeric.Natural import Data.IORef import Data.Word import Data.Foldable import Data.List.NonEmpty as NonEmpty import Lens.Micro.Platform import Data.Text (Text) import...
d365e63d157f625194afeb5f0692524a22b540a42aba8aece166127e73dcf619
basho/riak_api
riak_api_pb_server.erl
%% ------------------------------------------------------------------- %% %% riak_kv_pb_socket: service protocol buffer clients %% Copyright ( c ) 2007 - 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 ...
null
https://raw.githubusercontent.com/basho/riak_api/41f4b72d6a946c710e1523fd69b5b8deb5b57153/src/riak_api_pb_server.erl
erlang
------------------------------------------------------------------- riak_kv_pb_socket: service protocol buffer clients 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 L...
Copyright ( c ) 2007 - 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 ...
a7117a7265e021d0a99b5fe04be641dc5e48fc3ad61d072d92c0cbb30a38b601
racket/redex
test-util.rkt
#lang racket (require "common.rkt" redex) (provide (all-defined-out)) (define (num n) (if (zero? n) `("0") `("S" ,(num (sub1 n))))) (define (lst l) (if (empty? l) `("nil") `("cons" ,(first l) ,(lst (rest l))))) (define (:let name named-expr body) `((λ (,name) ,body) ,named-expr)) ...
null
https://raw.githubusercontent.com/racket/redex/4c2dc96d90cedeb08ec1850575079b952c5ad396/redex-examples/redex/examples/cont-mark-transform/test-util.rkt
racket
#lang racket (require "common.rkt" redex) (provide (all-defined-out)) (define (num n) (if (zero? n) `("0") `("S" ,(num (sub1 n))))) (define (lst l) (if (empty? l) `("nil") `("cons" ,(first l) ,(lst (rest l))))) (define (:let name named-expr body) `((λ (,name) ,body) ,named-expr)) ...
83e3cd6f82551f00791dd7de7550f8dd934e98bb43f33544796dbf013ca21035
cljfx/cljfx
category_axis.clj
(ns cljfx.fx.category-axis "Part of a public API" (:require [cljfx.composite :as composite] [cljfx.lifecycle :as lifecycle] [cljfx.fx.axis :as fx.axis]) (:import [javafx.scene.chart CategoryAxis])) (set! *warn-on-reflection* true) (def props (merge fx.axis/props (composite/prop...
null
https://raw.githubusercontent.com/cljfx/cljfx/543f7409290051e9444771d2cd86dadeb8cdce33/src/cljfx/fx/category_axis.clj
clojure
(ns cljfx.fx.category-axis "Part of a public API" (:require [cljfx.composite :as composite] [cljfx.lifecycle :as lifecycle] [cljfx.fx.axis :as fx.axis]) (:import [javafx.scene.chart CategoryAxis])) (set! *warn-on-reflection* true) (def props (merge fx.axis/props (composite/prop...
843b1f4b291ffbd7c4a34f91b622a07064e0f23b8f493aec014fd5c92c610467
mhkoji/Senn
read.lisp
in - dict , int - str , (defpackage :hachee.kkc.impl.mirror.read (:use :cl) (:export :read-kkc-dir :read-kkc-paths) (:local-nicknames (:int-str :hachee.kkc.impl.mirror.int-str))) (in-package :hachee.kkc.impl.mirror.read) (defun read-int-str (path) (let ((str->int (make-hash-table :test #'equal))...
null
https://raw.githubusercontent.com/mhkoji/Senn/0701d380f437aa4b48e2fba89bcd3d25587e4d0b/hachee/src/kkc/impl/mirror/read.lisp
lisp
strが"UT"以外の未知語の場合、int-str:to-intがUTを返して 本来のUTのcostが上書きされてしまうのを防ぐ。 読み込むデータが不整合になっている。
in - dict , int - str , (defpackage :hachee.kkc.impl.mirror.read (:use :cl) (:export :read-kkc-dir :read-kkc-paths) (:local-nicknames (:int-str :hachee.kkc.impl.mirror.int-str))) (in-package :hachee.kkc.impl.mirror.read) (defun read-int-str (path) (let ((str->int (make-hash-table :test #'equal))...
d7432512e19a25ed6409f984dffbf62f87021aec8e0dafce9a70a2c598147cb9
dawn-lang/dawn-phase1
Utils.hs
Copyright ( c ) 2021 -- This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. module Language.Dawn.Phase1.Utils ( checkType', fromExprSeq, fromShorthandFnType, inferNormType', ...
null
https://raw.githubusercontent.com/dawn-lang/dawn-phase1/fb2a3c8d93b73b8f771c03c537fc0ab2ead7210c/src/Language/Dawn/Phase1/Utils.hs
haskell
> o)) ----------------- Type Checking -- ----------------- ------------------- Type Validation -- ------------------- Tfn is not allowed in TCons args -------------------- Polymorphic Rank -- -------------------- Tfn is not allowed in TCons args
Copyright ( c ) 2021 This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. module Language.Dawn.Phase1.Utils ( checkType', fromExprSeq, fromShorthandFnType, inferNormType', i...
aac53b9d014de07ef87ce79fe67e931e7ba979f40dafd003c2d0dd7ea662bf67
fukamachi/rove
stream.lisp
(in-package #:cl-user) (defpackage #:rove/misc/stream (:use #:cl #:trivial-gray-streams) (:export #:make-indent-stream #:stream-indent-level #:with-indent)) (in-package #:rove/misc/stream) (defclass indent-stream (trivial-gray-stream-mixin fundamental-characte...
null
https://raw.githubusercontent.com/fukamachi/rove/bbc7b8e3e300266b44780fc926aee2962e649392/misc/stream.lisp
lisp
(in-package #:cl-user) (defpackage #:rove/misc/stream (:use #:cl #:trivial-gray-streams) (:export #:make-indent-stream #:stream-indent-level #:with-indent)) (in-package #:rove/misc/stream) (defclass indent-stream (trivial-gray-stream-mixin fundamental-characte...
6317d9b59ac3a06d2a9302bee53e1a80ad9a7cf89d81e6682e44ad5dc789fcf1
LexiFi/gen_js_api
test_bindings.mli
The gen_js_api is released under the terms of an MIT - like license . (* See the attached LICENSE file. *) Copyright 2015 by LexiFi . * Some ad hoc code to illustrate and test various aspects of gen_js_api of gen_j...
null
https://raw.githubusercontent.com/LexiFi/gen_js_api/9587818121be11593ed389bc87b85547b6ea402c/examples/test/test_bindings.mli
ocaml
See the attached LICENSE file.
The gen_js_api is released under the terms of an MIT - like license . Copyright 2015 by LexiFi . * Some ad hoc code to illustrate and test various aspects of gen_js_api of gen_js_api *) [@@@js.implem [@@@ocaml.warning "-22"]] module Element : sig typ...
12402859bb4d511f885ce74e5073d7bc40d932440365b2ba4b040867e0cf0880
nojb/llvm-min-caml
matmul-flat.ml
let rec loop3 i k j a b c = if k < 0 then () else (c.(i).(j) <- c.(i).(j) +. a.(i).(k) *. b.(k).(j); loop3 i (k - 1) j a b c) in let rec loop2 i m j a b c = if j < 0 then () else (loop3 i (m - 1) j a b c; loop2 i m (j - 1) a b c) in let rec loop1 i m n a b c = if i < 0 then () else (loop2 i m (n - 1) ...
null
https://raw.githubusercontent.com/nojb/llvm-min-caml/68703b905f8292cb2e20b41bbd90cfea85ca2a19/test/matmul-flat.ml
ocaml
let rec loop3 i k j a b c = if k < 0 then () else (c.(i).(j) <- c.(i).(j) +. a.(i).(k) *. b.(k).(j); loop3 i (k - 1) j a b c) in let rec loop2 i m j a b c = if j < 0 then () else (loop3 i (m - 1) j a b c; loop2 i m (j - 1) a b c) in let rec loop1 i m n a b c = if i < 0 then () else (loop2 i m (n - 1) ...
2ffa877416befabe5568b99f6f14654980d89001f36a959b4eab04065bf7daf9
zen-lang/zen-lsp
completion_test.clj
#!/usr/bin/env bb (require '[babashka.deps :as deps] '[babashka.process :as p] '[clojure.java.io :as io] '[cheshire.core :as json]) (def id (atom 0)) (defn next-id! [] (swap! id inc)) (defn ^:private content-length [json] (+ 1 (.length json))) (let [proc (deps/clojure ["-M" "-m" "zen-...
null
https://raw.githubusercontent.com/zen-lang/zen-lsp/07c8352ac7394608d28dba2091006de529f6dafe/server/completion_test.clj
clojure
#!/usr/bin/env bb (require '[babashka.deps :as deps] '[babashka.process :as p] '[clojure.java.io :as io] '[cheshire.core :as json]) (def id (atom 0)) (defn next-id! [] (swap! id inc)) (defn ^:private content-length [json] (+ 1 (.length json))) (let [proc (deps/clojure ["-M" "-m" "zen-...
1c04dabf20dcd9ab72d5ddc8796b7f41e62202b978803b179c50d3691cd1dcf5
wlitwin/graphv
safeFloat.ml
let safe_binop op a b = let c = op a b in if Float.is_nan c then ( failwith "NAN!" ); c let ( -. ) = safe_binop (-.) let ( +. ) = safe_binop (+.) let ( *. ) = safe_binop ( *.) let ( /. ) = safe_binop (/.)
null
https://raw.githubusercontent.com/wlitwin/graphv/d0a09575c5ff5ee3727c222dd6130d22e4cf62d9/gles2/core/safeFloat.ml
ocaml
let safe_binop op a b = let c = op a b in if Float.is_nan c then ( failwith "NAN!" ); c let ( -. ) = safe_binop (-.) let ( +. ) = safe_binop (+.) let ( *. ) = safe_binop ( *.) let ( /. ) = safe_binop (/.)
33ae260c65456d323a5d4bbb04699df5c1218d166b9c812173c29d39777adb79
exercism/common-lisp
example.lisp
(defpackage :etl (:use :common-lisp) (:export :transform)) (in-package :etl) (defun transform (data) (let ((old-kvs (loop for k being each hash-keys in data for v being each hash-values in data collecting (list k v)))) (reduce #'(lambda (h kv) (l...
null
https://raw.githubusercontent.com/exercism/common-lisp/381f6195175667454bdb499000c8cbc65bc7158c/exercises/practice/etl/.meta/example.lisp
lisp
(defpackage :etl (:use :common-lisp) (:export :transform)) (in-package :etl) (defun transform (data) (let ((old-kvs (loop for k being each hash-keys in data for v being each hash-values in data collecting (list k v)))) (reduce #'(lambda (h kv) (l...
e4c65369cc0a2cf45a3ed308134ac40eb32f3545ab4bc450e3db94f81fa326bc
titola/incudine
util.lisp
Copyright ( c ) 2013 - 2022 ;;; ;;; This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the License , or ;;; (at your option) any later version. ;;; ;;; This program is distri...
null
https://raw.githubusercontent.com/titola/incudine/950d604153b7d7693e43baa4f6981e6922105739/src/vug/util.lisp
lisp
This program is free software; you can redistribute it and/or modify either version 2 of the License , or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR...
Copyright ( c ) 2013 - 2022 it under the terms of the GNU General Public License as published by You should have received a copy of the GNU General Public License Foundation , Inc. , 51 Franklin St , Fifth Floor , Boston , MA 02110 - 1301 USA (in-package :incudine.vug) (eval-when (:compile-toplevel :loa...
9bc025afeca8ad0982d46b389275a3096a0a351892756d78512586550094f627
lemmih/lhc
BinTree.hs
module Main where import LHC.Prim import LHC.Prelude data Tree = Leaf | Branch Tree Tree make :: Int -> Tree make 0 = Leaf make n = Branch (make (n-1)) (make (n-1)) check :: Tree -> Int check Leaf = 1 check (Branch l r) = 3 + check l + check r main :: IO () main = dup (make 24) dup a = act a a act :: Tree -> Tre...
null
https://raw.githubusercontent.com/lemmih/lhc/53bfa57b9b7275b7737dcf9dd620533d0261be66/examples/BinTree.hs
haskell
module Main where import LHC.Prim import LHC.Prelude data Tree = Leaf | Branch Tree Tree make :: Int -> Tree make 0 = Leaf make n = Branch (make (n-1)) (make (n-1)) check :: Tree -> Int check Leaf = 1 check (Branch l r) = 3 + check l + check r main :: IO () main = dup (make 24) dup a = act a a act :: Tree -> Tre...
9931d7b69da0044f250b4105022a28df88799c13e4e920e7a9ae16e1adb53846
YoEight/lambda-database-experiment
Prelude.hs
# LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE ScopedTypeVariables # {-# LANGUAGE UndecidableInstances #-} ---------------------------------------------------------------------...
null
https://raw.githubusercontent.com/YoEight/lambda-database-experiment/da4fab8bd358fb8fb78412c805d6f5bc05854432/lambda-prelude/library/Lambda/Prelude.hs
haskell
# LANGUAGE OverloadedStrings # # LANGUAGE UndecidableInstances # ------------------------------------------------------------------------------ | Module : Lambda.Prelude License : (see the file LICENSE) Stability : provisional Portability : non-portable --------------------------------------------...
# LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # # LANGUAGE ScopedTypeVariables # Copyright : ( C ) 2017 Maintainer : < > module Lambda.Prelude ( module ClassyPrelude , module Data.String.Interpolate.IsString , module System...
891a16c8cddb835d7afc13fa03fa1558a0ae23a3c126184d97b9df042c232c2d
mirage/ocaml-vchan
vchan_lwt_unix.ml
* Copyright ( c ) 2014 Citrix Systems Inc * * Permission to use , copy , modify , and distribute this software for any * purpose with or without fee is hereby granted , provided that the above * copyright notice and this permission notice appear in all copies . * * THE SOFTWARE IS PROVIDED " AS IS ...
null
https://raw.githubusercontent.com/mirage/ocaml-vchan/cb116c1d79b97f1271189924ddbee73fa5a49456/lwt/vchan_lwt_unix.ml
ocaml
Last buffer from vchan
* Copyright ( c ) 2014 Citrix Systems Inc * * Permission to use , copy , modify , and distribute this software for any * purpose with or without fee is hereby granted , provided that the above * copyright notice and this permission notice appear in all copies . * * THE SOFTWARE IS PROVIDED " AS IS ...
b5b41d6f5fa3b855b05e0c5927dcf16f2a81afea90fff107cf2af3cbc475ed87
tamarin-prover/tamarin-prover
Positions.hs
# LANGUAGE ViewPatterns # # OPTIONS_GHC -fno - warn - incomplete - patterns # -- spurious warnings for view patterns -- | Copyright : ( c ) 2010 - 12 -- License : GPL v3 (see LICENSE) -- Maintainer : < > -- -- Positions and replacement in terms. module Term.Positions where import Term.VTerm import...
null
https://raw.githubusercontent.com/tamarin-prover/tamarin-prover/c78c7afd3b93b52dd4d2884952ec0fc273832a0d/lib/term/src/Term/Positions.hs
haskell
spurious warnings for view patterns | License : GPL v3 (see LICENSE) Positions and replacement in terms. -------------------------------------------------------------------- | A position in a term is a list of integers. | @t `atPos` p@ returns the subterm of term @t@ at position @p@. The standard notatio...
# LANGUAGE ViewPatterns # # OPTIONS_GHC -fno - warn - incomplete - patterns # Copyright : ( c ) 2010 - 12 Maintainer : < > module Term.Positions where import Term.VTerm import Safe Positions , subterm access , subterm replacement type Position = [Int] @t1*(t2* .. (tk-1*tk) .. atPos :: Ord a =>...
231983851921a60f185ca9ee29b20814dd236a9680c1a2cd518770079f5abeb0
geranazavr555/hi
Main.hs
module Main where import System.Console.Haskeline import HW3.Evaluator (eval) import HW3.Parser (parse) import HW3.Pretty (prettyValue) import Text.Megaparsec.Error (errorBundlePretty) main :: IO () main = runInputT defaultSettings loop where loop :: InputT IO () loop = do line <- getInput...
null
https://raw.githubusercontent.com/geranazavr555/hi/02c6f7550fd0f7979397392c41385f929ac9d9ca/hw3/app/Main.hs
haskell
outputStrLn $ "DEBUG> " ++ (show parsed)
module Main where import System.Console.Haskeline import HW3.Evaluator (eval) import HW3.Parser (parse) import HW3.Pretty (prettyValue) import Text.Megaparsec.Error (errorBundlePretty) main :: IO () main = runInputT defaultSettings loop where loop :: InputT IO () loop = do line <- getInput...
ea11d34d973329b6b1b597fe4c7b78381243a868b1c60758ab2a89d390835a34
janestreet/bonsai
style.ml
open! Core include [%css stylesheet {| * { box-sizing: border-box; font-family: sans-serif; } .pre_for_display { height: 50px; } .primary { background-color: rgb(30,30,30); color: rgb(240, 240, 240); } .resizable_using_css { background-color: rgb(30,30,30); ...
null
https://raw.githubusercontent.com/janestreet/bonsai/34430405574a4de68835f1010c22f9ac18dfffb6/examples/element_size_util/style.ml
ocaml
open! Core include [%css stylesheet {| * { box-sizing: border-box; font-family: sans-serif; } .pre_for_display { height: 50px; } .primary { background-color: rgb(30,30,30); color: rgb(240, 240, 240); } .resizable_using_css { background-color: rgb(30,30,30); ...
5a4a39d05b800969bc57bd66a2a3e6abbf93b8b9ebb4bfbcd0c839d5c9184f59
sru-systems/protobuf-simple
DoubleList.hs
-- Generated by protobuf-simple. DO NOT EDIT! module Types.DoubleList where import Control.Applicative ((<$>)) import Prelude () import qualified Data.ProtoBufInt as PB newtype DoubleList = DoubleList { value :: PB.Seq PB.Double } deriving (PB.Show, PB.Eq, PB.Ord) instance PB.Default DoubleList where defaultVa...
null
https://raw.githubusercontent.com/sru-systems/protobuf-simple/ee0f26b6a8588ed9f105bc9ee72c38943133ed4d/test/Types/DoubleList.hs
haskell
Generated by protobuf-simple. DO NOT EDIT!
module Types.DoubleList where import Control.Applicative ((<$>)) import Prelude () import qualified Data.ProtoBufInt as PB newtype DoubleList = DoubleList { value :: PB.Seq PB.Double } deriving (PB.Show, PB.Eq, PB.Ord) instance PB.Default DoubleList where defaultVal = DoubleList { value = PB.defaultVal ...
f7004cf6b707a9d25a0b9fce4a09455d1240817f8f7a6b1b5470825a5d9b3d4d
haskell-rewriting/term-rewriting
Utils.hs
-- This file is part of the 'term-rewriting' library. It is licensed under an MIT license . See the accompanying ' LICENSE ' file for details . -- Authors : module Data.Rewriting.Utils ( dropCommonPrefix, ) where | @dropCommonPrefix xs ys@ removes the common prefix of @xs@ and @ys@ and -- returns the rema...
null
https://raw.githubusercontent.com/haskell-rewriting/term-rewriting/d01ee419f9fd3c2011d37b6417326a9373d5ee9c/src/Data/Rewriting/Utils.hs
haskell
This file is part of the 'term-rewriting' library. It is licensed returns the remaining lists as a pair. >>>dropCommonPrefix [1,2,3] [1,2,4,1]
under an MIT license . See the accompanying ' LICENSE ' file for details . Authors : module Data.Rewriting.Utils ( dropCommonPrefix, ) where | @dropCommonPrefix xs ys@ removes the common prefix of @xs@ and @ys@ and ( [ 3 ] , [ 4,1 ] ) dropCommonPrefix :: Ord a => [a] -> [a] -> ([a], [a]) dropCommonPrefi...
c8db2a0ba9ba13df8dfbcea2e7fb93ec78c691662665dcd76f2185107423b8b2
JanHenryNystrom/jhn_stdlib
mustache.erl
%%============================================================================== Copyright 2017 - 2021 Jan < > %% 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 %% %% U...
null
https://raw.githubusercontent.com/JanHenryNystrom/jhn_stdlib/ffe3d8a58db28a4b0e270597fef7aa599dff9647/src/mustache.erl
erlang
============================================================================== you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either ex...
Copyright 2017 - 2021 Jan < > Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , @author < > ( C ) 2017 - 2021 , < > -module(mustache). -copyright('Jan Henry Nystrom <>'). -export([render/2, render/3]). -typ...
24e96cdddf8a8a4993c983d1c630804f07c31ffe216c140bb7188c31000d11e1
byulparan/cl-collider
FFT.lisp
(in-package #:sc) (defmacro def-pv-chain-ugen (name args &body body) `(progn (defun ,(car name) ,args (let ((new (lambda (cls &rest inputs) (apply #'ugen-new ,(second name) :control cls #'identity :bipolar inputs)))) ,@body)) (export ',(car name) :sc))) (defun fft (buffer &optional (in 0.0) ...
null
https://raw.githubusercontent.com/byulparan/cl-collider/1ad7f59c36acb61987e65973b77c5deb180285b1/ugens/FFT.lisp
lisp
(in-package #:sc) (defmacro def-pv-chain-ugen (name args &body body) `(progn (defun ,(car name) ,args (let ((new (lambda (cls &rest inputs) (apply #'ugen-new ,(second name) :control cls #'identity :bipolar inputs)))) ,@body)) (export ',(car name) :sc))) (defun fft (buffer &optional (in 0.0) ...
37f1c9e88bdf024df35883dce32de888a7c214d1fb1f10e0679298b08f9c5259
snowleopard/alga
AdjacencyMap.hs
----------------------------------------------------------------------------- -- | -- Module : Algebra.Graph.Acyclic.AdjacencyMap Copyright : ( c ) 2016 - 2022 License : MIT ( see the file LICENSE ) -- Maintainer : -- Stability : experimental -- -- __Alga__ is a library for algebraic construction and ...
null
https://raw.githubusercontent.com/snowleopard/alga/399b5dc538a2496b67f9322dc7247e06a4ec326b/src/Algebra/Graph/Acyclic/AdjacencyMap.hs
haskell
--------------------------------------------------------------------------- | Module : Algebra.Graph.Acyclic.AdjacencyMap Maintainer : Stability : experimental __Alga__ is a library for algebraic construction and manipulation of graphs the motivation behind the library, the underlying theory, and implement...
Copyright : ( c ) 2016 - 2022 License : MIT ( see the file LICENSE ) in Haskell . See < -paper this paper > for This module defines the ' AdjacencyMap ' data type and for acyclic graphs , as " Algebra . Graph . AdjacencyMap " , this module can be imported qualified : import qualified Algebra . Graph...
6c30bdbe540354efeadc56a9358289e1c282fbe0f32a6335805074a0f2553271
softwarelanguageslab/maf
R5RS_various_inc-1.scm
; Changes: * removed : 0 * added : 1 * swaps : 0 ; * negated predicates: 0 ; * swapped branches: 0 ; * calls to id fun: 0 (letrec ((inc (lambda (x) (<change> () (+ x 1)) (+ x 1)))) (inc (inc 2)))
null
https://raw.githubusercontent.com/softwarelanguageslab/maf/11acedf56b9bf0c8e55ddb6aea754b6766d8bb40/test/changes/scheme/generated/R5RS_various_inc-1.scm
scheme
Changes: * negated predicates: 0 * swapped branches: 0 * calls to id fun: 0
* removed : 0 * added : 1 * swaps : 0 (letrec ((inc (lambda (x) (<change> () (+ x 1)) (+ x 1)))) (inc (inc 2)))
de3d8505ce2fc33d28b5095dd5bb97fca79bd69c53f76ae85051e1d9562d7279
aptmcl/rosetta
autocad-server.rkt
#lang typed/racket/base/no-check (require (for-syntax racket/base)) (require (except-in "autocad-server/backend.rkt" division translating)) (provide (all-from-out "autocad-server/backend.rkt")) (require racket/include) (include "base/macros.rkc")
null
https://raw.githubusercontent.com/aptmcl/rosetta/38aeafd730f93edaec7474106e84dae6d8bc1261/autocad-server.rkt
racket
#lang typed/racket/base/no-check (require (for-syntax racket/base)) (require (except-in "autocad-server/backend.rkt" division translating)) (provide (all-from-out "autocad-server/backend.rkt")) (require racket/include) (include "base/macros.rkc")
fea7bdaf154af90eb95cb2cb289658d46dbc68f86f322a49ed2ad60f5492a83c
dgiot/dgiot
emqx_pd_SUITE.erl
%%-------------------------------------------------------------------- Copyright ( c ) 2018 - 2022 EMQ Technologies Co. , Ltd. 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 o...
null
https://raw.githubusercontent.com/dgiot/dgiot/c601555e45f38d02aafc308b18a9e28c543b6f2c/test/emqx_pd_SUITE.erl
erlang
-------------------------------------------------------------------- you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express ...
Copyright ( c ) 2018 - 2022 EMQ Technologies Co. , Ltd. 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(emqx_pd_SUITE). -compile(export_all). -compile(nowarn_export_all). -include_lib("eunit...
9e56a18afec817e07688a25f85f1adf98e26557e2db6d0e50b577b6dfd8331b0
err0r500/realworld-app-simple-haskell
RegisterUser.hs
module Adapter.Http.Servant.RegisterUser where import qualified Adapter.Http.Lib as Lib import qualified Debug.Trace as Debug import RIO import Servant (err422, err500) import qualified Usecase.Interactor as UC import qualified Usecase.UserRegistration as UC registerUser :: (MonadThrow m, MonadIO m, UC.Logger m) => U...
null
https://raw.githubusercontent.com/err0r500/realworld-app-simple-haskell/20ec982256ec890f0c77b572eccef987cd3799bf/src/Adapter/Http/Servant/RegisterUser.hs
haskell
module Adapter.Http.Servant.RegisterUser where import qualified Adapter.Http.Lib as Lib import qualified Debug.Trace as Debug import RIO import Servant (err422, err500) import qualified Usecase.Interactor as UC import qualified Usecase.UserRegistration as UC registerUser :: (MonadThrow m, MonadIO m, UC.Logger m) => U...
835cf1d2a1852c00393f27630e58c78e9bca8f872810dc95b8e1bb8105b2c3c2
helvm/helma
NumberSpec.hs
module HelVM.HelMA.Automata.LazyK.NumberSpec (spec) where import HelVM.HelMA.Automata.LazyK.InputEncoder import HelVM.HelMA.Automata.LazyK.Automaton import HelVM.HelMA.Automata.LazyK.Reducer import HelVM.HelIO.Control.Safe import HelVM.Expectations import ...
null
https://raw.githubusercontent.com/helvm/helma/ca7f0c7fe08b5d6614875319d8d14110395f038a/hs/test/HelVM/HelMA/Automata/LazyK/NumberSpec.hs
haskell
module HelVM.HelMA.Automata.LazyK.NumberSpec (spec) where import HelVM.HelMA.Automata.LazyK.InputEncoder import HelVM.HelMA.Automata.LazyK.Automaton import HelVM.HelMA.Automata.LazyK.Reducer import HelVM.HelIO.Control.Safe import HelVM.Expectations import ...
0e197e87b82eb71f9bf02137d04c914b6dc6c629a4545e369d8225e31b561431
Daniel-Diaz/processing
twist.hs
{-# LANGUAGE OverloadedStrings #-} import Graphics.Web.Processing.Simple main :: IO () main = renderFile "twist.pde" theScript theScript :: ProcScript theScript = animateFigure Nothing Nothing 50 (Color 0 0 0 255) drawFunction drawFunction :: Proc_Int -> Figure drawFunction n = let t = intToFloat n * 0.03 ...
null
https://raw.githubusercontent.com/Daniel-Diaz/processing/f7e6661e533abf7a8d47abd273b0a8ab61eb47ad/examples/twist.hs
haskell
# LANGUAGE OverloadedStrings #
import Graphics.Web.Processing.Simple main :: IO () main = renderFile "twist.pde" theScript theScript :: ProcScript theScript = animateFigure Nothing Nothing 50 (Color 0 0 0 255) drawFunction drawFunction :: Proc_Int -> Figure drawFunction n = let t = intToFloat n * 0.03 r = 100 in Circle (r * sin t, r ...
6d0aa4dfdda493e918327f743f6afa467c3de096d7c1d212619e24709c20d86f
SonarQubeCommunity/sonar-erlang
erlcount.erl
-module(erlcount). -behaviour(application). -export([start/2]). -export([stop/1]). start(normal, _Args) -> erlcount_sup:start_link(). stop(_State) -> ok.
null
https://raw.githubusercontent.com/SonarQubeCommunity/sonar-erlang/279eb7ccd84787c1c0cfd34b9a07981eb20183e3/its/plugin/projects/metrics/src/erlcount.erl
erlang
-module(erlcount). -behaviour(application). -export([start/2]). -export([stop/1]). start(normal, _Args) -> erlcount_sup:start_link(). stop(_State) -> ok.
2d0cfa417793002a2e206797982828fe420dedee2d2ac05b92dbb71dde9f3308
Chris00/mesh
mesh.ml
File : mesh.ml Copyright ( C ) 2006- < > WWW : / This library is free software ; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2.1 or later as published by the Free Software Foundation , with the special exception on lin...
null
https://raw.githubusercontent.com/Chris00/mesh/a998a3d898b0013517a5f7f6078791b61e6a0fe2/src/mesh.ml
ocaml
Local Variables: End:
File : mesh.ml Copyright ( C ) 2006- < > WWW : / This library is free software ; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2.1 or later as published by the Free Software Foundation , with the special exception on lin...
ceb89f351ca6edc4d69ad852c7b0e97928ce7d8f9c2c4b93507632bff1c16a61
astynax/hemmet
Tree.hs
# LANGUAGE FlexibleInstances # # LANGUAGE StandaloneDeriving # module Hemmet.FileTree.Tree where import Hemmet.Tree type FileTree = Tree FileTreePayload data FileTreePayload a = File | Directory [a] deriving instance Eq a => Eq (FileTreePayload a) deriving instance Show a => Show (FileTreePayload a) instance...
null
https://raw.githubusercontent.com/astynax/hemmet/0ee76cc4ffca5726f8a70ab78ae8473232b96ee3/src/Hemmet/FileTree/Tree.hs
haskell
# LANGUAGE FlexibleInstances # # LANGUAGE StandaloneDeriving # module Hemmet.FileTree.Tree where import Hemmet.Tree type FileTree = Tree FileTreePayload data FileTreePayload a = File | Directory [a] deriving instance Eq a => Eq (FileTreePayload a) deriving instance Show a => Show (FileTreePayload a) instance...
63760e5778b4f93f782d3053209738f158abb33ead362bd3948234bbd7ad284d
eggsyntax/reconstructorepl
redef.clj
(ns reconstructorepl.redef "An alternate strategy: instead of using a custom REPL, use custom versions of def and defn which record the defining form as metadata on the var." (:require [reconstructorepl.core :as r] [clojure.core :as c])) If we 're using def ' and ' , forms are stored in metadata ....
null
https://raw.githubusercontent.com/eggsyntax/reconstructorepl/aadea5b0b24cb8fb5cf5210664932bbec22f05e0/src/reconstructorepl/redef.clj
clojure
(println name# ":" form#) (println "f:" form#) TODO not working? throwing stack overflow on (def m 3) (def n (inc m)) We have to handle form# differently than we did in def', because def (println "n:" name#) (println "f:" form#)
(ns reconstructorepl.redef "An alternate strategy: instead of using a custom REPL, use custom versions of def and defn which record the defining form as metadata on the var." (:require [reconstructorepl.core :as r] [clojure.core :as c])) If we 're using def ' and ' , forms are stored in metadata ....
9ef8f157ba182396dbcc38f73e27b208e884564900804b60479178c405c234e7
mbutterick/beautiful-racket
quicklang.rkt
#lang br (require (for-syntax racket/list sugar/debug)) (provide (except-out (all-from-out br) #%module-begin) (rename-out [quicklang-mb #%module-begin]) (for-syntax (all-from-out sugar/debug))) (define-macro (quicklang-mb . EXPRS) #'(#%module-begin (provide #%top #%app #%datum #%top-interacti...
null
https://raw.githubusercontent.com/mbutterick/beautiful-racket/f0e2cb5b325733b3f9cbd554cc7d2bb236af9ee9/beautiful-racket-lib/br/quicklang.rkt
racket
Use wrap-reader on the whole-module read function that would be exported by the reader module, not the single-expression read function like at:read-syntax that you deal with within syntax/module-reader or normal use.
#lang br (require (for-syntax racket/list sugar/debug)) (provide (except-out (all-from-out br) #%module-begin) (rename-out [quicklang-mb #%module-begin]) (for-syntax (all-from-out sugar/debug))) (define-macro (quicklang-mb . EXPRS) #'(#%module-begin (provide #%top #%app #%datum #%top-interacti...
acee982ad8f0ae3e68544da86547593da5c1176d36e55a952ca4b33b76671635
hopv/MoCHi
extraParamInfer.ml
open Syntax open Type open Term_util let origWithExparam = ref (make_int 0) let exCoefficients = ref [] let to_string_CoeffInfos coeffsMap = let f = subst_map (List.map (Util.Pair.map_snd make_int) coeffsMap) in let g v = Id.name @@ var_of_term v in let h = function | {desc = Const (Int n)} -> string_of_i...
null
https://raw.githubusercontent.com/hopv/MoCHi/b0ac0d626d64b1e3c779d8e98cb232121cc3196a/src/extraParamInfer.ml
ocaml
??? | n -> make_letrec [(List.nth !nthCoefficient n), [], make_var (List.nth !nthCoefficient n)] (tmp (n-1))
open Syntax open Type open Term_util let origWithExparam = ref (make_int 0) let exCoefficients = ref [] let to_string_CoeffInfos coeffsMap = let f = subst_map (List.map (Util.Pair.map_snd make_int) coeffsMap) in let g v = Id.name @@ var_of_term v in let h = function | {desc = Const (Int n)} -> string_of_i...
c4c49c61e8f5f06b63031cf64e041b0f65c4480bf61a7c16775e2f9014c8cfb8
vikram/lisplibraries
graphics-state.lisp
Copyright ( c ) 2007 , All Rights Reserved ;;; ;;; Redistribution and use in source and binary forms, with or without ;;; modification, are permitted provided that the following conditions ;;; are met: ;;; ;;; * Redistributions of source code must retain the above copyright ;;; notice, this list of conditions...
null
https://raw.githubusercontent.com/vikram/lisplibraries/105e3ef2d165275eb78f36f5090c9e2cdd0754dd/site/vecto-1.1/graphics-state.lisp
lisp
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form ...
Copyright ( c ) 2007 , All Rights Reserved DIRECT , INDIRECT , INCIDENTAL , SPECIAL , EXEMPLARY , OR CONSEQUENTIAL INTERRUPTION ) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY , $ I d : graphics - state.lisp , v 1.15 2007/10/01 02:24:44 xach Exp $ (in-package #:vecto) (defconstant +png-channels+ 4) (defcons...
8ff7ec81701ca54a8ede488240bb775488ab1c222c68d77255868802c585a4a6
drewr/postal
project.clj
(defproject com.draines/postal "3.0.0-SNAPSHOT" :description "Clojure support for Internet email" :url "" :license {:name "MIT" :url "" :distribution :repo :comments "Use at your own risk"} :deploy-repositories [["releases" :clojars]] :dependencies [[commons-codec "1.9"] ...
null
https://raw.githubusercontent.com/drewr/postal/7606a66c10b66abd3476c6f4c828fb4b87d3792d/project.clj
clojure
(defproject com.draines/postal "3.0.0-SNAPSHOT" :description "Clojure support for Internet email" :url "" :license {:name "MIT" :url "" :distribution :repo :comments "Use at your own risk"} :deploy-repositories [["releases" :clojars]] :dependencies [[commons-codec "1.9"] ...
53d7f5ea47dfb8acc88319dfd3cdb759fb518fcfc6572f3ec9adf93742afad8a
o1-labs/ocamlbyexample
hello2.ml
let () = Core.printf "%s\n" "hello world" open Core let () = printf "%s\n" "hello world"
null
https://raw.githubusercontent.com/o1-labs/ocamlbyexample/80dcd0d937bbae0a65e7ca3fb325cf724cbb6ebe/book/chapters/basics/hello-world/hello2.ml
ocaml
let () = Core.printf "%s\n" "hello world" open Core let () = printf "%s\n" "hello world"
a5a71bbedd041eea6ef914d5f88073c6c8fb1707024e19866e73e8865472fe0a
lispbuilder/lispbuilder
regex.lisp
-*- Mode : LISP ; Syntax : COMMON - LISP ; Package : LISPBUILDER - REGEX ; Base : 10 -*- (in-package :LISPBUILDER-REGEX) ; ; Rewrite to use parse-tree functions. ; Separate optimization from parsing. ; Add separate canonicalization and rewrite passes. ; ; Partly because I'm about to allow the caller to manipulate ...
null
https://raw.githubusercontent.com/lispbuilder/lispbuilder/589b3c6d552bbec4b520f61388117d6c7b3de5ab/lispbuilder-regex/regex.lisp
lisp
Syntax : COMMON - LISP ; Package : LISPBUILDER - REGEX ; Base : 10 -*- Rewrite to use parse-tree functions. Separate optimization from parsing. Add separate canonicalization and rewrite passes. Partly because I'm about to allow the caller to manipulate the parse trees himself, so I can't depend on the parse tr...
(in-package :LISPBUILDER-REGEX) pass 1 . Lexical analysis pass 2 . Parsing pass 3 . parse tree ( needed because we allow pass 4 . Instruction selection ( fast - xxx ops ) pass 5 . CPS conversion to tuple list . pass 6 . Code ( closure ) generation . pass 7 . Linking ( resolve target labels to functio...
e2ee9981423712bee9e03e9d319a5e8d490ed1ee74d9474456c1f826e518cc4c
haskell/lsp
Utils.hs
{-# LANGUAGE RankNTypes #-} {-# LANGUAGE TemplateHaskell #-} # LANGUAGE LambdaCase # -- | Internal helpers for generating definitions module Language.LSP.Types.Utils ( rdrop , makeSingletonFromJSON , makeRegHelper , makeExtendingDatatype , lspOptions , lspOptionsU...
null
https://raw.githubusercontent.com/haskell/lsp/dce30c9d345f63921cf9cf5045e1dcd753e4fe34/lsp-types/src/Language/LSP/Types/Utils.hs
haskell
# LANGUAGE RankNTypes # # LANGUAGE TemplateHaskell # | Internal helpers for generating definitions --------------------------------------------------------------------- instances for each constructor return type by invoking the FromJSON instance for the wrapper and unwrapping e.g. makeE...
# LANGUAGE LambdaCase # module Language.LSP.Types.Utils ( rdrop , makeSingletonFromJSON , makeRegHelper , makeExtendingDatatype , lspOptions , lspOptionsUntagged ) where import Control.Monad import Data.Aeson import Data.List import Language.Haskell.TH rdrop :: Int -> [a] -> [a] rdrop ...
649ae4c0a13d7352c7dfad4eb4084dfb9a95c2c38a140e78dc456614785fdb58
Ptival/chick
GlobalEnvironment.hs
module Diff.GlobalEnvironment ( Diff, findGlobalDeclarationDiff, findGlobalIndDiff, patch, ) where import qualified Diff.GlobalDeclaration as ΔGD import qualified Diff.Inductive as ΔI import qualified Diff.List as ΔL import Inductive.Inductive (Inductive (inductiveName)) import Language (Language (Chic...
null
https://raw.githubusercontent.com/Ptival/chick/5f21b154acbc04f6572692ad1d592a50c37a638e/backend/lib/Diff/GlobalEnvironment.hs
haskell
annotation has to be Raw because of inductives TODO: need to decide whether this find inductives or not, so far no? trace (printf "δe: %s" (prettyStr δe)) v' == v v' == v modified
module Diff.GlobalEnvironment ( Diff, findGlobalDeclarationDiff, findGlobalIndDiff, patch, ) where import qualified Diff.GlobalDeclaration as ΔGD import qualified Diff.Inductive as ΔI import qualified Diff.List as ΔL import Inductive.Inductive (Inductive (inductiveName)) import Language (Language (Chic...
46e554d19b74067487b7fcd1ea20ebfc6343e99a2ea71341edd92f830936d3f7
AccelerateHS/accelerate-examples
World.hs
module Common.World ( World(..), advanceBodies, advanceWorld ) where import Common.Type import Common.Body import Data.Array.Accelerate as A import Data.Array.Accelerate.Linear.Vector data World = World { worldBodies :: !(Vector Body) -- ^ Bodies in the simulati...
null
https://raw.githubusercontent.com/AccelerateHS/accelerate-examples/a973ee423b5eadda6ef2e2504d2383f625e49821/examples/n-body/Common/World.hs
haskell
^ Bodies in the simulation # UNPACK # ^ Number of steps taken in the simulation so far # UNPACK # ^ Current simulation time | Move bodies under the influence of acceleration ^ Function to compute accelerations at each point ^ Time step ^ Bodies Calculate the accelerations on each body. Apply the accelerations...
module Common.World ( World(..), advanceBodies, advanceWorld ) where import Common.Type import Common.Body import Data.Array.Accelerate as A import Data.Array.Accelerate.Linear.Vector data World = World { } advanceBodies -> Acc (Vector Body) advanceBodies calcAccels timeStep bodi...
fb6816b40e5100320ef21d744956cfc3387fb1d472e094aef4d93139b1097aea
mkhan45/RustScript2
block.ml
open Base open Stdio open Printf open Rustscript.Run open Util let () = let ss, state = test_state () |> run_file (test_file "block.rsc") in assert_equal_expressions "a + b" "20" ss state; assert_equal_expressions "f(10, 5, 3)" "28" ss state; assert_equal_expressions "c" (Int.to_string (5 + (...
null
https://raw.githubusercontent.com/mkhan45/RustScript2/a8d004981714e81d8aad10b07549b2ab0b99bef5/test/block.ml
ocaml
open Base open Stdio open Printf open Rustscript.Run open Util let () = let ss, state = test_state () |> run_file (test_file "block.rsc") in assert_equal_expressions "a + b" "20" ss state; assert_equal_expressions "f(10, 5, 3)" "28" ss state; assert_equal_expressions "c" (Int.to_string (5 + (...
9b3945e00f9b263c38879033fee3bdd60c8ec619adcf4dfc3a1338cc732ade7b
cram-code/cram_core
utils.lisp
(in-package :crs) (defun prolog-type-p (variable type) (alexandria:ignore-some-conditions (simple-error) (typep variable type))) (defun query-var (var function query &rest args) "Executes `function' with `query' as its first parameter and `args' as additional parameters and returns the value of `var' in th...
null
https://raw.githubusercontent.com/cram-code/cram_core/984046abe2ec9e25b63e52007ed3b857c3d9a13c/cram_reasoning/src/utils.lisp
lisp
(in-package :crs) (defun prolog-type-p (variable type) (alexandria:ignore-some-conditions (simple-error) (typep variable type))) (defun query-var (var function query &rest args) "Executes `function' with `query' as its first parameter and `args' as additional parameters and returns the value of `var' in th...
c3db734f87756d13a5804cd8e60bd5d6275e3446359da5e593e123db8eb7dc6c
alexandergunnarson/quantum
driver.cljc
(ns quantum.test.apis.twitter.driver (:require [quantum.apis.twitter.driver :as ns])) (defn test:login! [driver username password])
null
https://raw.githubusercontent.com/alexandergunnarson/quantum/0c655af439734709566110949f9f2f482e468509/test/quantum/test/apis/twitter/driver.cljc
clojure
(ns quantum.test.apis.twitter.driver (:require [quantum.apis.twitter.driver :as ns])) (defn test:login! [driver username password])
165e7e1336f413b13dce15643315d130588f190bea1f67fd6722cd9e38a1ae21
LeventErkok/sbv
ArithNoSolver.hs
----------------------------------------------------------------------------- -- | -- Module : TestSuite.Basics.ArithNoSolver Copyright : ( c ) -- License : BSD3 -- Maintainer: -- Stability : experimental -- -- Test suite for basic concrete arithmetic, i.e., testing all -- the constant folding based arithmeti...
null
https://raw.githubusercontent.com/LeventErkok/sbv/45c6f3acaafb42715eb24995813150e5e23d0971/SBVTestSuite/TestSuite/Basics/ArithNoSolver.hs
haskell
--------------------------------------------------------------------------- | Module : TestSuite.Basics.ArithNoSolver License : BSD3 Maintainer: Stability : experimental Test suite for basic concrete arithmetic, i.e., testing all the constant folding based arithmetic implementation in SBV ----------------...
Copyright : ( c ) # LANGUAGE TupleSections # module TestSuite.Basics.ArithNoSolver(tests) where import Data.SBV.Internals import Utils.SBVTestFramework import Data.Maybe (fromJust, isJust, fromMaybe) import Data.List (genericIndex, isInfixOf, isPrefixOf, isSuffixOf, genericTake, genericDrop, genericLen...
d498702393f57595c2bc6ea747ec78e40276785838b248a8a3d3127e94084a2b
DSiSc/why3
decl.ml
(********************************************************************) (* *) The Why3 Verification Platform / The Why3 Development Team Copyright 2010 - 2018 -- Inria - CNRS - Paris - Sud University (* ...
null
https://raw.githubusercontent.com/DSiSc/why3/8ba9c2287224b53075adc51544bc377bc8ea5c75/src/core/decl.ml
ocaml
****************************************************************** This software is distributed under the terms of the GNU Lesser on linking described in file LICENSE. ...
The Why3 Verification Platform / The Why3 Development Team Copyright 2010 - 2018 -- Inria - CNRS - Paris - Sud University General Public License version 2.1 , with the special exception open Wstdlib open Ident open Ty open Term type constructor = lsymbol * lsymbol option list type data_de...
e9c9416d29cb52b06992d3756e56f92d5a5ee565cf650ebf733a50f03664feda
morpheusgraphql/morpheus-graphql
Selection.hs
{-# LANGUAGE OverloadedStrings #-} # LANGUAGE RecordWildCards # # LANGUAGE ScopedTypeVariables # # LANGUAGE NoImplicitPrelude # module Data.Morpheus.Parsing.Request.Selection ( parseSelectionSet, parseFragmentDefinition, ) where -- MORPHEUS import Data.Morpheus.Parsing.Internal.Arguments ( maybeArguments...
null
https://raw.githubusercontent.com/morpheusgraphql/morpheus-graphql/7b93de9028e597111b680201c2b87321c3bb7459/morpheus-graphql-core/src/Data/Morpheus/Parsing/Request/Selection.hs
haskell
# LANGUAGE OverloadedStrings # Selection Sets : -spec/June2018/#sec-Selection-Sets { Selection(list) } Selection: Field Field Alias(opt) Name Arguments(opt) Directives(opt) SelectionSet(opt) Fragments: -spec/June2018/#sec-Language.Fragments FragmentName : Name ...FragmentName Directives(opt) ...
# LANGUAGE RecordWildCards # # LANGUAGE ScopedTypeVariables # # LANGUAGE NoImplicitPrelude # module Data.Morpheus.Parsing.Request.Selection ( parseSelectionSet, parseFragmentDefinition, ) where MORPHEUS import Data.Morpheus.Parsing.Internal.Arguments ( maybeArguments, ) import Data.Morpheus.Parsing.Int...
00d02461fc4dff60bd7c548caef4b941fbbcd1f6d8b5b1411d3a0a39aaa30da4
manuel-serrano/bigloo
exit.scm
;*=====================================================================*/ * serrano / prgm / project / bigloo / / comptime / Expand / exit.scm * / ;* ------------------------------------------------------------- */ * Author : * / * Creation : ...
null
https://raw.githubusercontent.com/manuel-serrano/bigloo/bd53a11ef760ee53a5e33ec01228b66bd5190124/comptime/Expand/exit.scm
scheme
*=====================================================================*/ * ------------------------------------------------------------- */ * ------------------------------------------------------------- */ * The macro expansion of the `exit' machinery. */ *===========================...
* serrano / prgm / project / bigloo / / comptime / Expand / exit.scm * / * Author : * / * Creation : Fri Apr 21 15:03:35 1995 * / * Last change : Thu Sep 16 14:03:04 2021 ( serrano ) * / * Copyrigh...
7ea0dcdc4634670edc7dc111a1d37f6ed17500f3f2a8d093a6d30b0e4387a308
johnstonskj/simple-oauth2
tokens.rkt
#lang racket/base ;; ;; simple-oauth2 - oauth2/storage/tokens. ;; Simple OAuth2 client and server implementation ;; Copyright ( c ) 2019 ( ) . ;; Racket Style Guide: -lang.org/style/index.html (require racket/contract) (provide get-services-for-user get-token set-token! save-tokens ...
null
https://raw.githubusercontent.com/johnstonskj/simple-oauth2/b8cb40511f64dcb274e17957e6fc9ab4c8a6cbea/storage/tokens.rkt
racket
simple-oauth2 - oauth2/storage/tokens. Simple OAuth2 client and server implementation Racket Style Guide: -lang.org/style/index.html ---------- Requirements ---------- Internal types ---------- Implementation (hash/c token-name? (hash/c application-name? auth-code?)) ---------- Startup procedures
#lang racket/base Copyright ( c ) 2019 ( ) . (require racket/contract) (provide get-services-for-user get-token set-token! save-tokens load-tokens) (require racket/list oauth2 oauth2/storage/config oauth2/private/logging oauth2/private/pr...
bddf72c0e3ad87dd27fd39184db5e529cd47454dc002196d181f77fb751017c8
input-output-hk/plutus-apps
Server.hs
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # {-# LANGUAGE MonoLocalBinds #-} {-# LANGUAGE RankNTypes #-} # LANGUAGE TypeApplications # {-# LANGUAGE TypeOperators #-} module Plutus.ChainIndex.Server( serveChainIndexQueryServer, serveChainIndex) where import Control.Monad ((>=>)) impor...
null
https://raw.githubusercontent.com/input-output-hk/plutus-apps/7f5a094deb113512e21a9cc122500721dbc4b1f9/plutus-chain-index-core/src/Plutus/ChainIndex/Server.hs
haskell
# LANGUAGE MonoLocalBinds # # LANGUAGE RankNTypes # # LANGUAGE TypeOperators # ^ Port
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # # LANGUAGE TypeApplications # module Plutus.ChainIndex.Server( serveChainIndexQueryServer, serveChainIndex) where import Control.Monad ((>=>)) import Control.Monad.Except qualified as E import Control.Monad.Freer (Eff, Member, type (~>)) import Contr...
86a4448e3e048764dbdbbdd35916b3db4c8f1d32d31e705d4c0164518a0cb287
Smoltbob/Caml-Est-Belle
letrec3.ml
let rec f g = g 1 2 in let rec h a b = a + b in print_int (f h)
null
https://raw.githubusercontent.com/Smoltbob/Caml-Est-Belle/3d6f53d4e8e01bbae57a0a402b7c0f02f4ed767c/tests/typechecking/valid/letrec3.ml
ocaml
let rec f g = g 1 2 in let rec h a b = a + b in print_int (f h)
342c2a14eb0ebdad39e5840b6ed7aade3783111e26f9c41b3453cb92feb8b2cd
rabbitmq/khepri
helpers.erl
This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. %% Copyright © 2022 - 2023 VMware , Inc. or its affiliates . All rights reserved . %% -module(helpers). -include_lib("stdlib/include/asser...
null
https://raw.githubusercontent.com/rabbitmq/khepri/3527362ad9f59cff36231eb4e7b34dc066aa0f50/test/helpers.erl
erlang
For internal use only. open in Ra? @doc Returns the value of executing the given `Fun' and any log messages produced while executing it, concatenated into a binary. @doc Returns the logger messages produced while executing the given `Fun' concatenated into a binary. Implements the `log/2' callback for logger h...
This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. Copyright © 2022 - 2023 VMware , Inc. or its affiliates . All rights reserved . -module(helpers). -include_lib("stdlib/include/assert.hrl"...
3065421e3b4c5e07d0f0fb6ffd5a58b1ff6200f7a64771dea407c624cac4881b
hoon0612/Lisp-in-OCaml
environment.ml
open Types;; type fn_type1 = (s_exp -> s_exp) and fn_type2 = (s_exp -> s_exp -> s_exp) and fn_typeN = (s_exp -> s_exp) and fn_binding = (* NormalType1 of fn_type1 | NormalType2 of fn_type2*) | NormalTypeN of fn_typeN (*| SpecialType1 of fn_type1 | SpecialType2 of fn_type2 *) | SpecialTypeN of fn_typeN ;; Symbol...
null
https://raw.githubusercontent.com/hoon0612/Lisp-in-OCaml/498ace173018af8f7772b3db803872e76b5902cf/environment.ml
ocaml
NormalType1 of fn_type1 | NormalType2 of fn_type2 | SpecialType1 of fn_type1 | SpecialType2 of fn_type2
open Types;; type fn_type1 = (s_exp -> s_exp) and fn_type2 = (s_exp -> s_exp -> s_exp) and fn_typeN = (s_exp -> s_exp) and fn_binding = | NormalTypeN of fn_typeN | SpecialTypeN of fn_typeN ;; Symbol for SymbolTable module Symbol = struct type t = string Pervasives.compare returns 0 if x is equal to y ...
7d86756b7c724b995efd0aa4c9e830dd552044fc84e94d8eb5276dd4535a48bd
IC3Hydra/Hydra
Spec.hs
import Test.QuickCheck.Gen import Test.Tasty import Test.Tasty.HUnit import Test.Tasty.QuickCheck as QC import Test . Tasty . SmallCheck as SC import qualified Data.ByteString as ByteString import Data.List import Data.Ord import Da...
null
https://raw.githubusercontent.com/IC3Hydra/Hydra/ba42d62108bb1a374bc2e2290d6535c22062b2d3/hydra/instrumenter/test/Spec.hs
haskell
import Test.QuickCheck.Gen import Test.Tasty import Test.Tasty.HUnit import Test.Tasty.QuickCheck as QC import Test . Tasty . SmallCheck as SC import qualified Data.ByteString as ByteString import Data.List import Data.Ord import Da...
713584e391698283845d7610c0c4c25ca93f140e5251c31ec9ade0a9acf1ce47
mfikes/fifth-postulate
ns499.cljs
(ns fifth-postulate.ns499) (defn solve-for01 [xs v] (for [ndx0 (range 0 (- (count xs) 3)) ndx1 (range (inc ndx0) (- (count xs) 2)) ndx2 (range (inc ndx1) (- (count xs) 1)) ndx3 (range (inc ndx2) (count xs)) :when (= v (+ (xs ndx0) (xs ndx1) (xs ndx2) (xs ndx3)))] (list (x...
null
https://raw.githubusercontent.com/mfikes/fifth-postulate/22cfd5f8c2b4a2dead1c15a96295bfeb4dba235e/src/fifth_postulate/ns499.cljs
clojure
(ns fifth-postulate.ns499) (defn solve-for01 [xs v] (for [ndx0 (range 0 (- (count xs) 3)) ndx1 (range (inc ndx0) (- (count xs) 2)) ndx2 (range (inc ndx1) (- (count xs) 1)) ndx3 (range (inc ndx2) (count xs)) :when (= v (+ (xs ndx0) (xs ndx1) (xs ndx2) (xs ndx3)))] (list (x...
480eaaea1f98b8e6cff71b303f046c9ed6ad7b2cbd4f930e14864bbe1032e719
haroldcarr/simple-blockchain
GCoinSpec.hs
module GCoinSpec where import Test.Hspec ------------------------------------------------------------------------------ import GCoin spec :: Spec spec = do testCreateCoin testVerifyCreatedCoin testTransferCoin testIsValidCoin testIsValidCoinBase isValidCoinForTest addToChainForTest empty...
null
https://raw.githubusercontent.com/haroldcarr/simple-blockchain/61efe0ed7301ac61dc1acbf099618c57aa6472ee/test/GCoinSpec.hs
haskell
----------------------------------------------------------------------------
module GCoinSpec where import Test.Hspec import GCoin spec :: Spec spec = do testCreateCoin testVerifyCreatedCoin testTransferCoin testIsValidCoin testIsValidCoinBase isValidCoinForTest addToChainForTest emptyChainForTest
916070e0f441f31771ad793e78ebafff1d0d72a6216fa4ad6e0b283ccc1e0380
let-def/menhir
front.ml
(**************************************************************************) (* *) Menhir (* *) , INRIA Ro...
null
https://raw.githubusercontent.com/let-def/menhir/e8ba7bef219acd355798072c42abbd11335ecf09/src/front.ml
ocaml
************************************************************************ et en Automatique. All rig...
Menhir , INRIA Rocquencourt , PPS , Université Paris Diderot Copyright 2005 - 2008 Institut National de Recherche en Informatique under the terms of the Q Public License versi...
93303067ee4bbb31ddf4f3cc750674561a14f61858c2af293e024b94d8d36d43
Eventuria/demonstration-gsd
CommandSpec.hs
# LANGUAGE QuasiQuotes # # LANGUAGE InstanceSigs , TypeApplications # module Eventuria.Libraries.CQRS.Write.Serialization.CommandSpec (main, spec) where import Test.Hspec import Test.QuickCheck import Data.Aeson import Eventuria.Libraries.CQRS.Write.Serialization.PropertyTesting.Command () import Eventuria.Librar...
null
https://raw.githubusercontent.com/Eventuria/demonstration-gsd/5c7692b310086bc172d3fd4e1eaf09ae51ea468f/test/Eventuria/Libraries/CQRS/Write/Serialization/CommandSpec.hs
haskell
# LANGUAGE QuasiQuotes # # LANGUAGE InstanceSigs , TypeApplications # module Eventuria.Libraries.CQRS.Write.Serialization.CommandSpec (main, spec) where import Test.Hspec import Test.QuickCheck import Data.Aeson import Eventuria.Libraries.CQRS.Write.Serialization.PropertyTesting.Command () import Eventuria.Librar...
3b968cd03f57557960ecfd4ea854a6b81c65deb3bb802316751a8922fa9f902f
apauley/hledger-flow
DocHelpers.hs
{-# LANGUAGE OverloadedStrings #-} module Hledger.Flow.DocHelpers where import qualified Data.Text as T (Text) import qualified Turtle as Turtle (Line, format, l) import Turtle ((%)) docURL :: Turtle.Line -> T.Text docURL = Turtle.format ("-flow#"%Turtle.l)
null
https://raw.githubusercontent.com/apauley/hledger-flow/b1d86dbd111cbacbace769fb4d4596b647951fc7/src/Hledger/Flow/DocHelpers.hs
haskell
# LANGUAGE OverloadedStrings #
module Hledger.Flow.DocHelpers where import qualified Data.Text as T (Text) import qualified Turtle as Turtle (Line, format, l) import Turtle ((%)) docURL :: Turtle.Line -> T.Text docURL = Turtle.format ("-flow#"%Turtle.l)
28e99a1688be1296bd4de46073e3f1f556656ca7324d1dd094fb553cd0ea6506
mistupv/cauder
auto.erl
-module(auto). -export([main/0]). main() -> self() ! hello, receive hello -> ok; _ -> not_ok end.
null
https://raw.githubusercontent.com/mistupv/cauder/ff4955cca4b0aa6ae9d682e9f0532be188a5cc16/examples/auto.erl
erlang
-module(auto). -export([main/0]). main() -> self() ! hello, receive hello -> ok; _ -> not_ok end.
6eab1609f6098500e6b157c54e5f5ce6d9b463cac3f9869efe4c6dc9b0e6a311
mallipeddi/erlpop
epop_client.erl
-module(epop_client). -author("Harish Mallipeddi <>"). %%%--------------------------------------------------------------------- %%% File : epop_client.erl Created : 10 Sep 2008 by %%% Function: POP3 client (with SSL support) %%% ==================================================================== The contents ...
null
https://raw.githubusercontent.com/mallipeddi/erlpop/782cf13219edfbb63a07c2428fe2ed3db98ac73f/src/epop_client.erl
erlang
--------------------------------------------------------------------- File : epop_client.erl Function: POP3 client (with SSL support) ==================================================================== except in compliance with the License. You may obtain a copy of the License at basis, WITHOUT WARRANTY OF ...
-module(epop_client). -author("Harish Mallipeddi <>"). Created : 10 Sep 2008 by The contents of this file are subject to the Erlang Public License License , Version 1.1 , ( the " License " ) ; you may not use this file Software distributed under the License is distributed on an " AS IS " The Original Code i...
1e0b62bdb55c790cac154f0f3413442476ca59276ce66c97ca08fd1ebcd0f5d5
RefactoringTools/HaRe
WhereIn1_AstOut.hs
module WhereIn1 where sumSquares x y = ((sq pow) x) + ((sq pow) y) where pow = 2 sq pow 0 = 0 sq pow z = z ^ pow anotherFun 0 y = sq y where sq x = x ^ 2
null
https://raw.githubusercontent.com/RefactoringTools/HaRe/ef5dee64c38fb104e6e5676095946279fbce381c/old/testing/liftOneLevel/WhereIn1_AstOut.hs
haskell
module WhereIn1 where sumSquares x y = ((sq pow) x) + ((sq pow) y) where pow = 2 sq pow 0 = 0 sq pow z = z ^ pow anotherFun 0 y = sq y where sq x = x ^ 2
2b6b6c57d231a3f41378778e1b4de243b93ff926040e468d377b6a1d4b96950d
stchang/parsack
info.rkt
#lang setup/infotab
null
https://raw.githubusercontent.com/stchang/parsack/57b21873e8e3eb7ffbdfa253251c3c27a66723b1/parsack-lib/parsack/info.rkt
racket
#lang setup/infotab
9e58a13b709471c8abb8df15940a60586e7158105c35afcf2de98d5ad2d155aa
kmi/irs
aktive-portal-ontology2.lisp
Mode : Lisp ; Package : File created in WebOnto (in-package "OCML") (in-ontology aktive-portal-ontology2)
null
https://raw.githubusercontent.com/kmi/irs/e1b8d696f61c6b6878c0e92d993ed549fee6e7dd/ontologies/domains/aktive-portal-ontology2/aktive-portal-ontology2.lisp
lisp
Package :
File created in WebOnto (in-package "OCML") (in-ontology aktive-portal-ontology2)
b8a69ba68ae607100e2d9acc4fb0a260142a45af7e1a33adff65e646783bc28b
ucsd-progsys/liquidhaskell
Bag.hs
module Language.Haskell.Liquid.Bag where import qualified Data.Map as M @ embed Data . Map . Map as @ @ measure : : Int - > Bag a @ {-@ measure Map_union :: Bag a -> Bag a -> Bag a @-} @ measure Map_select : : Data . Map . Map k v - > k - > v ...
null
https://raw.githubusercontent.com/ucsd-progsys/liquidhaskell/5e9347ac719e0ca192b05ccde74617d0cbb05a85/liquid-prelude/src/Language/Haskell/Liquid/Bag.hs
haskell
@ measure Map_union :: Bag a -> Bag a -> Bag a @ if I just write measure fromList the measure definition is not imported @ assume empty :: {v:Bag k | v = Map_default 0} @ @ fromList :: (Ord k) => xs:[k] -> {v:Bag k | v == fromList xs } @
module Language.Haskell.Liquid.Bag where import qualified Data.Map as M @ embed Data . Map . Map as @ @ measure : : Int - > Bag a @ @ measure Map_select : : Data . Map . Map k v - > k - > v @ @ measure : : Data . Map . Map k v - > k - > v - > D...
0ad6f439db68bc3b810afca05acf10580b658fe0263369504c2e75895b07fa0e
rightfold/open-browser
Main.hs
module Main ( main ) where import Web.Browser (openBrowser) main :: IO () main = openBrowser "/" >>= print
null
https://raw.githubusercontent.com/rightfold/open-browser/1c862a6dc5943cdfe5860a743b9f545584156436/example/Main.hs
haskell
module Main ( main ) where import Web.Browser (openBrowser) main :: IO () main = openBrowser "/" >>= print
bfaa0080ed14c6970216e3edc1206f3231aef24952738ea88b44510156a4594a
finnishtransportagency/harja
toimenpideajat_test.clj
(ns harja.palvelin.raportointi.toimenpideajat-test (:require [clojure.test :refer :all] [harja.palvelin.komponentit.tietokanta :as tietokanta] [harja.palvelin.palvelut.toimenpidekoodit :refer :all] [harja.palvelin.palvelut.urakat :refer :all] [harja.testi :refer :all] ...
null
https://raw.githubusercontent.com/finnishtransportagency/harja/488b1e096f0611e175221d74ba4f2ffed6bea8f1/test/clj/harja/palvelin/raportointi/toimenpideajat_test.clj
clojure
(ns harja.palvelin.raportointi.toimenpideajat-test (:require [clojure.test :refer :all] [harja.palvelin.komponentit.tietokanta :as tietokanta] [harja.palvelin.palvelut.toimenpidekoodit :refer :all] [harja.palvelin.palvelut.urakat :refer :all] [harja.testi :refer :all] ...
b308c443393dae4479c5147468975e74b4b271544a998cfbb805994d2e59f2a5
HaskellForCats/HaskellForCats
warpFunctorQ.hs
# LANGUAGE OverloadedStrings # {-# LANGUAGE QuasiQuotes #-} {-# LANGUAGE TemplateHaskell #-} # LANGUAGE TypeFamilies # { - # LANGUAGE OverloadedStrings , QuasiQuotes , TemplateHaskell , TypeFamilies # - } -- -ddump-splices import Blaze . ByteString . Builder ( Builder , fromB...
null
https://raw.githubusercontent.com/HaskellForCats/HaskellForCats/2d7a15c0cdaa262c157bbf37af6e72067bc279bc/WarpFunctorOne/warpFunctorQ.hs
haskell
# LANGUAGE QuasiQuotes # # LANGUAGE TemplateHaskell # -ddump-splices import Text.Blaze.Html.Renderer.Utf8 (renderHtmlBuilder)
# LANGUAGE OverloadedStrings # # LANGUAGE TypeFamilies # { - # LANGUAGE OverloadedStrings , QuasiQuotes , TemplateHaskell , TypeFamilies # - } import Blaze . ByteString . Builder ( Builder , fromByteString ) import Network . ( status200 ) import Network . ( Application , ...
3db6853b591a8baa2b808c6b1d50b3d505cd769d9d6ab8325ec3d8b57a66ad07
Soostone/instrument
Counter.hs
{-# LANGUAGE BangPatterns #-} # LANGUAGE TypeApplications # module Instrument.Counter ( Counter, newCounter, readCounter, resetCounter, add, increment, ) where ------------------------------------------------------------------------------- import Data.IORef import qualified Data.Atomics.Counte...
null
https://raw.githubusercontent.com/Soostone/instrument/9be4002ddd035b960f2f7439e876e268308db89c/instrument/src/Instrument/Counter.hs
haskell
# LANGUAGE BangPatterns # ----------------------------------------------------------------------------- ----------------------------------------------------------------------------- ----------------------------------------------------------------------------- ------------------------------------------------------------...
# LANGUAGE TypeApplications # module Instrument.Counter ( Counter, newCounter, readCounter, resetCounter, add, increment, ) where import Data.IORef import qualified Data.Atomics.Counter as A data Counter = Counter {_atomicCounter :: A.AtomicCounter, _lastResetValue :: IORef Int} newCounter :...
93a16b856bca5deb9269e371e259a4aef72ff60a8bd69a18142055d22040f21f
oriansj/mes-m2
srfi-16.scm
GNU --- Maxwell Equations of Software Copyright ( C ) 2001 , 2002 , 2006 Free Software Foundation , Inc. ;;; This file is part of GNU . ;;; GNU is free software ; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; eith...
null
https://raw.githubusercontent.com/oriansj/mes-m2/b44fbc976ae334252de4eb82a57c361a195f2194/mes/module/srfi/srfi-16.scm
scheme
you can redistribute it and/or modify it either version 3 of the License , or ( at your option) any later version. WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. From Guile-1.8 srfi-16.scm ...
GNU --- Maxwell Equations of Software Copyright ( C ) 2001 , 2002 , 2006 Free Software Foundation , Inc. This file is part of GNU . under the terms of the GNU General Public License as published by GNU is distributed in the hope that it will be useful , but You should have received a copy of the GNU Gene...