_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
cc638e3b2066e4b5cf9c7cfeb35a42044c702b1c794ce1c3ae1595dfe330e26c
drewolson/aoc-hs
Day05.hs
module Aoc.Year2021.Day05 ( part1, part2, ) where import Aoc.Parser (Parser, intP, runParser) import Data.Map qualified as M import Data.MultiSet (MultiSet) import Data.MultiSet qualified as MS import Text.Megaparsec (sepEndBy1) import Text.Megaparsec.Char (char, newline, string) type Point = (Int, Int) type...
null
https://raw.githubusercontent.com/drewolson/aoc-hs/b0f06843e1f7d8c2af1da582e59a72d8f2bb73bf/aoc-year2021/src/Aoc/Year2021/Day05.hs
haskell
module Aoc.Year2021.Day05 ( part1, part2, ) where import Aoc.Parser (Parser, intP, runParser) import Data.Map qualified as M import Data.MultiSet (MultiSet) import Data.MultiSet qualified as MS import Text.Megaparsec (sepEndBy1) import Text.Megaparsec.Char (char, newline, string) type Point = (Int, Int) type...
3a3e1dce6f339d7eef19ce76a9fcbf337db21889ed37c54e154e9718d4fb7754
craigl64/clim-ccl
hpgl-tests.lisp
-*- Mode : LISP ; Syntax : Common - lisp ; Package : hpgl - clim ; Base : 10 ; Lowercase : Yes -*- (in-package :clim-user) (defmethod invoke-with-output-to-printer-stream ((type (eql :hpgl)) stream continuation) (hpgl-clim:with-output-to-hpgl-stream (*standard-output* stream) (funcall continuation))) (defme...
null
https://raw.githubusercontent.com/craigl64/clim-ccl/301efbd770745b429f2b00b4e8ca6624de9d9ea9/test/hpgl-tests.lisp
lisp
Syntax : Common - lisp ; Package : hpgl - clim ; Base : 10 ; Lowercase : Yes -*-
(in-package :clim-user) (defmethod invoke-with-output-to-printer-stream ((type (eql :hpgl)) stream continuation) (hpgl-clim:with-output-to-hpgl-stream (*standard-output* stream) (funcall continuation))) (defmethod invoke-with-pipe-to-printer ((type (eql :hpgl)) continuation) (with-open-stream (printe...
281bee2d1b4898c7e53dd34635e1ea2c6fa0322051e73744816f256c70d2d7c6
GrammaticalFramework/gf-core
Concrete.hs
# LANGUAGE PatternGuards # module GF.Compile.TypeCheck.Concrete( checkLType, inferLType, computeLType, ppType ) where GHC 8.4.1 clash with Text . PrettyPrint import GF.Infra.CheckM import GF.Data.Operations import GF.Grammar import GF.Grammar.Lookup import GF.Grammar.Predef import GF.Grammar.PatternMatch import GF....
null
https://raw.githubusercontent.com/GrammaticalFramework/gf-core/f2e52d6f2c2bc90febceebdea0268b40ea37476c/src/compiler/GF/Compile/TypeCheck/Concrete.hs
haskell
-- shouldn't be needed -- shouldn't be needed - is this necessary to test? never needed to compute! locking to be removed AR 20/6/2009 the underlying algorithms - ?? tries to guess: good in oper type inference -- PInt k : _ -> return $ Ints $ max [i | PInt i <- pts'] old , caused issue 68 - removed irritatin...
# LANGUAGE PatternGuards # module GF.Compile.TypeCheck.Concrete( checkLType, inferLType, computeLType, ppType ) where GHC 8.4.1 clash with Text . PrettyPrint import GF.Infra.CheckM import GF.Data.Operations import GF.Grammar import GF.Grammar.Lookup import GF.Grammar.Predef import GF.Grammar.PatternMatch import GF....
ec5de72fcd2826e1df7d2c3a33253597a59c2d509492a8309e90b7fd52da38b4
Eelis/cxxdraft-htmlgen
Load14882.hs
# OPTIONS_GHC -fno - warn - tabs # # LANGUAGE OverloadedStrings , ScopedTypeVariables , RecordWildCards , ViewPatterns , LambdaCase , TupleSections , NamedFieldPuns , FlexibleInstances , FlexibleContexts , RankNTypes , MultiParamTypeClasses , FunctionalDependencies , UndecidableIn...
null
https://raw.githubusercontent.com/Eelis/cxxdraft-htmlgen/f56f1c583b6a78865e5958cc932a508a85588155/Load14882.hs
haskell
Since we treat definitions like sections (and generate pages for them), we need don't link to the page for the preceding section. Replaces \pnum with \pnum{file}{line} force eval before we leave the dir
# OPTIONS_GHC -fno - warn - tabs # # LANGUAGE OverloadedStrings , ScopedTypeVariables , RecordWildCards , ViewPatterns , LambdaCase , TupleSections , NamedFieldPuns , FlexibleInstances , FlexibleContexts , RankNTypes , MultiParamTypeClasses , FunctionalDependencies , UndecidableIn...
f6841ee77ae019a55ea5032e781839f6b8f5e5eaa59021cbd12b084e2ee71527
RichiH/git-annex
ResolveMerge.hs
git - annex command - - Copyright 2014 < > - - Licensed under the GNU GPL version 3 or higher . - - Copyright 2014 Joey Hess <> - - Licensed under the GNU GPL version 3 or higher. -} module Command.ResolveMerge where import Command import qualified Git import Git.Sha import qualified Git.Bran...
null
https://raw.githubusercontent.com/RichiH/git-annex/bbcad2b0af8cd9264d0cb86e6ca126ae626171f3/Command/ResolveMerge.hs
haskell
git - annex command - - Copyright 2014 < > - - Licensed under the GNU GPL version 3 or higher . - - Copyright 2014 Joey Hess <> - - Licensed under the GNU GPL version 3 or higher. -} module Command.ResolveMerge where import Command import qualified Git import Git.Sha import qualified Git.Bran...
f549abdf36ecbc87ca283f1ff539cf80652efb3e20974cef427aa19fef766c7f
master/ejabberd
mod_service_log.erl
%%%---------------------------------------------------------------------- File : Author : < > %%% Purpose : Copy user messages to logger service Created : 24 Aug 2003 by < > %%% %%% ejabberd , Copyright ( C ) 2002 - 2012 ProcessOne %%% %%% This program is free software; you can redistribute it a...
null
https://raw.githubusercontent.com/master/ejabberd/9c31874d5a9d1852ece1b8ae70dd4b7e5eef7cf7/src/mod_service_log.erl
erlang
---------------------------------------------------------------------- Purpose : Copy user messages to logger service This program is free software; you can redistribute it and/or License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WAR...
File : Author : < > Created : 24 Aug 2003 by < > ejabberd , Copyright ( C ) 2002 - 2012 ProcessOne modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the You should have received a copy of the GNU General Public Li...
517224832ade5b9b7026f9b073da46d773eda3208ec9b8a871ab94f5c5d7d031
binaryage/chromex
document_scan.clj
(ns chromex.ext.document-scan "Use the chrome.documentScan API to discover and retrieve images from attached paper document scanners. * available since Chrome 44 * " (:refer-clojure :only [defmacro defn apply declare meta let partial]) (:require [chromex.wrapgen :refer [gen-wrap-helper]] ...
null
https://raw.githubusercontent.com/binaryage/chromex/33834ba5dd4f4238a3c51f99caa0416f30c308c5/src/exts/chromex/ext/document_scan.clj
clojure
-- convenience ------------------------------------------------------------------------------------------------------------ --------------------------------------------------------------------------------------------------------------------------- -- API TABLE --------------------------------------------------------...
(ns chromex.ext.document-scan "Use the chrome.documentScan API to discover and retrieve images from attached paper document scanners. * available since Chrome 44 * " (:refer-clojure :only [defmacro defn apply declare meta let partial]) (:require [chromex.wrapgen :refer [gen-wrap-helper]] ...
f8235cb6f9aadf6f3b4e7feeca69f60d324660d6ef4d5ce4ab9605f692173683
astrada/ocaml-extjs
ext_data_writer_Writer.mli
* Base Writer class used by most subclasses of Ext.d ... { % < p > Base Writer class used by most subclasses of < a href="#!/api / Ext.data.proxy . Server " rel="Ext.data.proxy . Server " class="docClass">Ext.data.proxy . Server</a > . This class is responsible for taking a set of < a href="#!/api / Ext.data ....
null
https://raw.githubusercontent.com/astrada/ocaml-extjs/77df630a75fb84667ee953f218c9ce375b3e7484/lib/ext_data_writer_Writer.mli
ocaml
* {% <p>This is used for each field of type date in the model to format the value before it is sent to the server.</p> %} * [of_configs c] casts a config object [c] to an instance of class [t] * [to_configs o] casts instance [o] of class [t] to a config object
* Base Writer class used by most subclasses of Ext.d ... { % < p > Base Writer class used by most subclasses of < a href="#!/api / Ext.data.proxy . Server " rel="Ext.data.proxy . Server " class="docClass">Ext.data.proxy . Server</a > . This class is responsible for taking a set of < a href="#!/api / Ext.data ....
0ef04b7ea95c03b65b981e8eaea88c497b2238aa92d1cf95307dba66aded5d78
marcoonroad/nocoiner
encryption.ml
module String = Core.String module AES = Nocrypto.Cipher_block.AES.CBC let __kdf key = let aes_salt = Entropy.min_bits (32 * 8) in let mac_salt = Entropy.max_bits (32 * 8) in let aes_key = Hardening.kdf ~size:32l ~salt:aes_salt key in let mac_key = Hardening.kdf ~size:32l ~salt:mac_salt key in (aes_key, mac_...
null
https://raw.githubusercontent.com/marcoonroad/nocoiner/d067785ee7ce7a8480b7bd5d4f8d28d2c3fc49cb/lib/encryption.ml
ocaml
module String = Core.String module AES = Nocrypto.Cipher_block.AES.CBC let __kdf key = let aes_salt = Entropy.min_bits (32 * 8) in let mac_salt = Entropy.max_bits (32 * 8) in let aes_key = Hardening.kdf ~size:32l ~salt:aes_salt key in let mac_key = Hardening.kdf ~size:32l ~salt:mac_salt key in (aes_key, mac_...
4f67e90c86c3e27c54737ac5a3f74cd44a7699657b97898dce1ba75f7798eca4
huangz1990/SICP-answers
p46-fixed-point.scm
;;; p46-fixed-point.scm (define tolerance 0.00001) (define (fixed-point f first-guess) (define (close-enough? v1 v2) (< (abs (- v1 v2)) tolerance)) (define (try guess) (let ((next (f guess))) (if (close-enough? guess next) next (try next)))) (try...
null
https://raw.githubusercontent.com/huangz1990/SICP-answers/15e3475003ef10eb738cf93c1932277bc56bacbe/chp1/code/p46-fixed-point.scm
scheme
p46-fixed-point.scm
(define tolerance 0.00001) (define (fixed-point f first-guess) (define (close-enough? v1 v2) (< (abs (- v1 v2)) tolerance)) (define (try guess) (let ((next (f guess))) (if (close-enough? guess next) next (try next)))) (try first-guess))
95a1d5c906e976b23f373dd8d20ddb6c7b9d490f75c3b3d171842c5395a7c747
abcdw/rde
version-control.scm
(define-module (rde features version-control) #:use-module (rde features) #:use-module (rde features predicates) #:use-module (rde packages) #:use-module (gnu home-services version-control) #:use-module (gnu home services) #:use-module (gnu services) #:use-module (gnu packages version-control) #:use-mod...
null
https://raw.githubusercontent.com/abcdw/rde/5b8605f421d0b8a9569e43cb6f7e651e7a8f7218/src/rde/features/version-control.scm
scheme
should make a conflict scope smaller, but guile-git fails if this option is set. histogram should be smarter about diff generation.
(define-module (rde features version-control) #:use-module (rde features) #:use-module (rde features predicates) #:use-module (rde packages) #:use-module (gnu home-services version-control) #:use-module (gnu home services) #:use-module (gnu services) #:use-module (gnu packages version-control) #:use-mod...
108816af8502ecefc13ee59af3d5832f11d9e489bb1168b41049ab501ee18eea
exercism/common-lisp
example.lisp
(defpackage :rail-fence-cipher (:use :cl) (:export :encode :decode)) (in-package :rail-fence-cipher) (defstruct post letter row column) (defun make-fence (seq-length rails) "Function make-fence will output a list of structs of type post, which will come to represent a character and its coordinates i...
null
https://raw.githubusercontent.com/exercism/common-lisp/57bb317e68ca75f41666ce3c62066a9c13e0314a/exercises/practice/rail-fence-cipher/.meta/example.lisp
lisp
row = i mod r, else... row = r - (i mod r)
(defpackage :rail-fence-cipher (:use :cl) (:export :encode :decode)) (in-package :rail-fence-cipher) (defstruct post letter row column) (defun make-fence (seq-length rails) "Function make-fence will output a list of structs of type post, which will come to represent a character and its coordinates i...
4b71a94626f3728330f3569f91796afd380ac59740095c81b06c771a8f7510b5
kappelmann/engaging-large-scale-functional-programming
Exercise02.hs
module Exercise02 where import Data.List(sort) import Test.QuickCheck startupRevenue1 :: [Int] -> Int startupRevenue1 [] = 0 startupRevenue1 list = maximum (map (getPrices sortedL) list) where sortedL = sort list getPrices :: [Int] -> Int -> Int getPrices [] _ = 0 getPrices (x:xs) price ...
null
https://raw.githubusercontent.com/kappelmann/engaging-large-scale-functional-programming/8ed2c056fbd611f1531230648497cb5436d489e4/resources/contest/example_data/02/uploads/l3bkuch3n/Exercise02.hs
haskell
???? ^^
module Exercise02 where import Data.List(sort) import Test.QuickCheck startupRevenue1 :: [Int] -> Int startupRevenue1 [] = 0 startupRevenue1 list = maximum (map (getPrices sortedL) list) where sortedL = sort list getPrices :: [Int] -> Int -> Int getPrices [] _ = 0 getPrices (x:xs) price ...
a869ef7ec025e933a3824efcd62ae477fbe8ab8289f26b5c4888f7e017e7a1b1
TorXakis/TorXakis
All.hs
TorXakis - Model Based Testing Copyright ( c ) 2015 - 2017 TNO and Radboud University See LICENSE at root directory of this repository . TorXakis - Model Based Testing Copyright (c) 2015-2017 TNO and Radboud University See LICENSE at root directory of this repository. -} module Benchmarks.All (allExamples, all...
null
https://raw.githubusercontent.com/TorXakis/TorXakis/038463824b3d358df6b6b3ff08732335b7dbdb53/test/sqatt/src/Benchmarks/All.hs
haskell
TorXakis - Model Based Testing Copyright ( c ) 2015 - 2017 TNO and Radboud University See LICENSE at root directory of this repository . TorXakis - Model Based Testing Copyright (c) 2015-2017 TNO and Radboud University See LICENSE at root directory of this repository. -} module Benchmarks.All (allExamples, all...
e8df8a2b21070babc532dfd481d0dc06e8edb77bcaa7c510294470abecd36c1e
haroldcarr/learn-haskell-coq-ml-etc
C03.hs
Created : 2014 Feb by . Last Modified : 2014 Jul 02 ( We d ) by . Created : 2014 Feb by Harold Carr. Last Modified : 2014 Jul 02 (Wed) 06:51:59 by Harold Carr. -} # LANGUAGE LambdaCase # {-# LANGUAGE ParallelListComp #-} # LANGUAGE RecordWildCards ...
null
https://raw.githubusercontent.com/haroldcarr/learn-haskell-coq-ml-etc/b4e83ec7c7af730de688b7376497b9f49dc24a0e/haskell/book/2014-Alejandro_Serrano_Mena-Beginning_Haskell/old/code/src/C03.hs
haskell
# LANGUAGE ParallelListComp # # LANGUAGE ViewPatterns # ---------------------------------------------------------------------------- ---------------------------------------------------------------------------- ---------------------------------------------------------------------------- smart constructors and vie...
Created : 2014 Feb by . Last Modified : 2014 Jul 02 ( We d ) by . Created : 2014 Feb by Harold Carr. Last Modified : 2014 Jul 02 (Wed) 06:51:59 by Harold Carr. -} # LANGUAGE LambdaCase # # LANGUAGE RecordWildCards # # LANGUAGE TransformListComp # ...
bd7c9755eb2218004c21d21ede50d4b90115ca3ec42d80cfed4cc8fa69f9809b
psholtz/MIT-SICP
exercise1-27.scm
;; Exercise 1.27 ;; Demonstrate that the numbers really do fool the Fermat test . That is , ;; write a procedure that takes an integer n and tests whether a^n congruent to a mod n for every a < n , and try the procedure on the given Charmichael numbers . ;; Charmichael numbers : 561 1105 1729 2465 2821 6601 ;...
null
https://raw.githubusercontent.com/psholtz/MIT-SICP/01e9b722ac5008e26f386624849117ca8fa80906/Section-1.2/mit-scheme/exercise1-27.scm
scheme
write a procedure that takes an integer n and tests whether a^n congruent to +++++++++++++++++++++++++++++++++++++++ Procedures to support normal prime test +++++++++++++++++++++++++++++++++++++++ +++++++++++++++++++++++++++++++++ +++++++++++++++++++++++++++++++++ We can write some simple "unit tests" to...
Exercise 1.27 Demonstrate that the numbers really do fool the Fermat test . That is , a mod n for every a < n , and try the procedure on the given Charmichael numbers . Charmichael numbers : 561 1105 1729 2465 2821 6601 (define (smallest-divisor n) (if (divides? 2 n) 2 (find-divisor n 3))) (def...
eb5ae6dc241ed4b1a73c0cc6fa1d7ad740b5a3391fdacfac347ce97da5f9eb25
ahrefs/atd
test_polymorphic_wrap_j.expected.ml
(* Auto-generated from "test_polymorphic_wrap.atd" *) [@@@ocaml.warning "-27-32-33-35-39"] type 'a t = 'a Array_wrap.t let write__a_list write__a = ( Atdgen_runtime.Oj_run.write_list ( write__a ) ) let string_of__a_list write__a ?(len = 1024) x = let ob = Buffer.create len in write__a_list write__a ob x; ...
null
https://raw.githubusercontent.com/ahrefs/atd/1f2b3bcc54d14159a5e25e9b23b5c9bed163721c/atdgen/test/test_polymorphic_wrap_j.expected.ml
ocaml
Auto-generated from "test_polymorphic_wrap.atd"
[@@@ocaml.warning "-27-32-33-35-39"] type 'a t = 'a Array_wrap.t let write__a_list write__a = ( Atdgen_runtime.Oj_run.write_list ( write__a ) ) let string_of__a_list write__a ?(len = 1024) x = let ob = Buffer.create len in write__a_list write__a ob x; Buffer.contents ob let read__a_list read__a = ( At...
9db307357dc4e73d8654519644c7bfab6b492adf16c632952f004634760b4c29
b0-system/b0
test_base64.ml
--------------------------------------------------------------------------- Copyright ( c ) 2019 The b0 programmers . All rights reserved . Distributed under the ISC license , see terms at the end of the file . --------------------------------------------------------------------------- Copyright (c) 20...
null
https://raw.githubusercontent.com/b0-system/b0/cbe12b8a55da6b50ab01ed058b339dbed3cfe894/test/test_base64.ml
ocaml
--------------------------------------------------------------------------- Copyright ( c ) 2019 The b0 programmers . All rights reserved . Distributed under the ISC license , see terms at the end of the file . --------------------------------------------------------------------------- Copyright (c) 20...
c6b3eeae2a367f81e1e77766cc435136201bf67a716e86f1ace8f4577352f1a4
foreverbell/project-euler-solutions
7.hs
import Common.Numbers.Primes (primes') main = print (primes' !! 10000)
null
https://raw.githubusercontent.com/foreverbell/project-euler-solutions/c0bf2746aafce9be510892814e2d03e20738bf2b/src/7.hs
haskell
import Common.Numbers.Primes (primes') main = print (primes' !! 10000)
4b685535f0555ca0a90d4567e33e4ec48c870fa7a71eaf2f62788df36356674b
nitrogen/NitrogenProject.com
basic_auth_callback_mod.erl
%%%------------------------------------------------------------------- @author < > ( C ) 2010 , %%% @doc %%% %%% @end Created : 2 Jun 2010 by < > %%%------------------------------------------------------------------- -module(basic_auth_callback_mod). -include_lib ("nitrogen_core/include/wf.hrl"). %...
null
https://raw.githubusercontent.com/nitrogen/NitrogenProject.com/b4b3a0dbe17394608d2ee6eaa089e3ece1285075/src/basic_auth_callback_mod.erl
erlang
------------------------------------------------------------------- @doc @end ------------------------------------------------------------------- API =================================================================== API =================================================================== -------------------------...
@author < > ( C ) 2010 , Created : 2 Jun 2010 by < > -module(basic_auth_callback_mod). -include_lib ("nitrogen_core/include/wf.hrl"). -export([ realm/0, is_protected/1, is_authenticated/2, authenticate/3 ]). realm() -> "Protected Area". is_protected(_Page) -> false. ...
5d3895ffc35fbd2049364f26aa309949c983fc0c44687a9164604c235fe3bdcb
gowthamk/ocaml-irmin
test_merge8.ml
original = | | q1 = q2 = |5||6| q1 = |5| q2 = |5||6| *) module U = struct let string_of_list f l = "[ " ^ List.fold_left (fun a b -> a ^ (f b) ^ "; ") "" l ^ "]" let print_header h = Printf.printf "%s" ("\n" ^ h ^ "\n") end (* Queue *) let _ = U.print_header "Heap8"; let module Atom = stru...
null
https://raw.githubusercontent.com/gowthamk/ocaml-irmin/54775f6c3012e87d2d0308f37a2ec7b27477e887/heap_leftist/mem/test_merge8.ml
ocaml
Queue
original = | | q1 = q2 = |5||6| q1 = |5| q2 = |5||6| *) module U = struct let string_of_list f l = "[ " ^ List.fold_left (fun a b -> a ^ (f b) ^ "; ") "" l ^ "]" let print_header h = Printf.printf "%s" ("\n" ^ h ^ "\n") end let _ = U.print_header "Heap8"; let module Atom = struct type t ...
7c94201a3cf9895271b7b791513bbb47fbdf18a516a4b08472f90e3d0f3ed6e8
haskell-tools/haskell-tools
FlexibleContextsChecker.hs
module Language.Haskell.Tools.Refactor.Builtin.ExtensionOrganizer.Checkers.FlexibleContextsChecker where import TcType (tcSplitNestedSigmaTys, checkValidClsArgs) import Type hiding (Type(..)) import PrelNames (eqTyConName, eqTyConKey) import Unique (hasKey) import qualified Name as GHC import qualified GHC import Dat...
null
https://raw.githubusercontent.com/haskell-tools/haskell-tools/b1189ab4f63b29bbf1aa14af4557850064931e32/src/builtin-refactorings/Language/Haskell/Tools/Refactor/Builtin/ExtensionOrganizer/Checkers/FlexibleContextsChecker.hs
haskell
If the constraint is of form a ~ b, then we dont need to check Returns False if a lookup inside is not succesful. false positive results. Separates the type into its head and its arguments. then we remove all implicit predicates, and partition the types into predicate types and theta types. We don't need type eq...
module Language.Haskell.Tools.Refactor.Builtin.ExtensionOrganizer.Checkers.FlexibleContextsChecker where import TcType (tcSplitNestedSigmaTys, checkValidClsArgs) import Type hiding (Type(..)) import PrelNames (eqTyConName, eqTyConKey) import Unique (hasKey) import qualified Name as GHC import qualified GHC import Dat...
a10ea3d023ded2d23f7b2a5fd22e576af98928fc8ff55924477de5999201061d
robert-stuttaford/bridge
ui.cljs
(ns bridge.person.ui (:require [bridge.person.spec :as person.spec] bridge.person.ui.edit-profile [bridge.ui.ajax :as ui.ajax] [bridge.ui.base :as ui.base] [bridge.ui.component.edit-field :as ui.edit-field] [bridge.ui.spec :as ui.spec] [re-frame....
null
https://raw.githubusercontent.com/robert-stuttaford/bridge/867d81354457c600cc5c25917de267a8e267c853/src/bridge/person/ui.cljs
clojure
db edit-profile
(ns bridge.person.ui (:require [bridge.person.spec :as person.spec] bridge.person.ui.edit-profile [bridge.ui.ajax :as ui.ajax] [bridge.ui.base :as ui.base] [bridge.ui.component.edit-field :as ui.edit-field] [bridge.ui.spec :as ui.spec] [re-frame....
a6257019cb502499179c6be4c9a3d149537815652c88a52e1467852f2a260f1e
typelead/eta
tcfail157.hs
# LANGUAGE MultiParamTypeClasses , FunctionalDependencies , FlexibleInstances # FlexibleInstances #-} NB : * no * UndecidableInstances This one ( due to ) made 6.4.1 go into a loop in the typechecker , despite the lack of UndecidableInstances -- -- The example corresponds to a type f...
null
https://raw.githubusercontent.com/typelead/eta/97ee2251bbc52294efbf60fa4342ce6f52c0d25c/tests/suite/typecheck/fail/tcfail157.hs
haskell
The example corresponds to a type function (realized as a class E with functional dependencies) in the context of an instance. The function in question is class E m a b | m a -> b instance E m (() -> ()) (m ()) We see that the result of the function, "m ()" is smaller (in the number of constructors)...
# LANGUAGE MultiParamTypeClasses , FunctionalDependencies , FlexibleInstances # FlexibleInstances #-} NB : * no * UndecidableInstances This one ( due to ) made 6.4.1 go into a loop in the typechecker , despite the lack of UndecidableInstances free in at least one of the arguments ....
8651a7bf7bc869ef43aebe4e18ffc6135cf38aec64cd3736d309b8dfb6f2dd1a
processone/fast_yaml
fast_yaml_app.erl
%%%---------------------------------------------------------------------- %%% File : fast_yaml_app.erl Author : < > %%% Purpose : YAML parser application Created : 7 Aug 2013 by < > %%% %%% Copyright ( C ) 2002 - 2023 ProcessOne , SARL . All Rights Reserved . %%% Licensed under the Apache License , V...
null
https://raw.githubusercontent.com/processone/fast_yaml/8d7084aa40ae4bcec8980d4707b70eb1af6f33fc/src/fast_yaml_app.erl
erlang
---------------------------------------------------------------------- File : fast_yaml_app.erl Purpose : YAML parser application 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, sof...
Author : < > Created : 7 Aug 2013 by < > Copyright ( C ) 2002 - 2023 ProcessOne , SARL . 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(fast_yaml_app). -behaviour(application). ...
c68d0cd1cd7cceea452f37699aaf3bb628ff84224d6cfdd3bdeeae326cc27c2d
wingo/fibers
web-hello.scm
(use-modules (web server)) (define (handler request body) (values '((content-type . (text/plain))) "Hello, World!")) (run-server handler 'fibers)
null
https://raw.githubusercontent.com/wingo/fibers/44d17e64e581fb281bae1390f74c762ecf089b58/examples/web-hello.scm
scheme
(use-modules (web server)) (define (handler request body) (values '((content-type . (text/plain))) "Hello, World!")) (run-server handler 'fibers)
885b7d0511b66049bf731246f9362174e0aa27dcca62f349c954b4ec78b53bc4
schell/odin
Core.hs
module Odin.Core ( module O , module L , module E , module GC -- * Useful everyday exports , MonadIO , lift , use , fix , void , when , unless , forM , forM_ , foldM , foldM_ -- * SDL stuff , module KeyCodes , module Enum , MouseButton(..) , InputMotion(..) ) where import ...
null
https://raw.githubusercontent.com/schell/odin/97ae1610a7abd19aa150bc7dfc132082d88ca9ea/src/Odin/Core.hs
haskell
* Useful everyday exports * SDL stuff
module Odin.Core ( module O , module L , module E , module GC , MonadIO , lift , use , fix , void , when , unless , forM , forM_ , foldM , foldM_ , module KeyCodes , module Enum , MouseButton(..) , InputMotion(..) ) where import Control.Lens import Control.Mo...
651f02216bda7cc18b3c27057b192b0592758f7a06c7d58c0e8a6199053ae6b9
serefayar/ayatori
core_test.clj
(ns ayatori.ring.core-test (:require [ayatori.ring.core :as core] [clojure.test :as t :refer [deftest is testing]] [reitit.ring :as ring] [reitit.core :as r] [clojure.spec.alpha :as s] [clj-http.client :as client])) (def router-fixture (ring/router ["/...
null
https://raw.githubusercontent.com/serefayar/ayatori/dbe171681e7f3fe574e3026577b94ca18d4beaff/components/ring_middleware/test/ayatori/ring/core_test.clj
clojure
(ns ayatori.ring.core-test (:require [ayatori.ring.core :as core] [clojure.test :as t :refer [deftest is testing]] [reitit.ring :as ring] [reitit.core :as r] [clojure.spec.alpha :as s] [clj-http.client :as client])) (def router-fixture (ring/router ["/...
ab8e11007088bff3b4c465708ed74f63b5df05d1a1ae4147a51718ca142bd0ba
serperu/secer
vigenere_ok.erl
Erlang implementation of Vigenère cipher % Code from Rosetta Code % #Erlang -module(vigenere_ok). -export([encrypt/2, decrypt/2, from_pos/1, to_pos/1, encrypt/2]). -import(lists, [append/2, filter/2, map/2, zipwith/3]). % Utility functions for character tests and conversions isupper([C|_]) -> isupper(C); isupper(C...
null
https://raw.githubusercontent.com/serperu/secer/ffe2f9602356c34c9465c44534c82cc758b809b5/benchmarks/vigenere/vigenere_ok.erl
erlang
Code from Rosetta Code #Erlang Utility functions for character tests and conversions modulo function that normalizes into positive range for positive divisor convert letter to position in alphabet (A=0,B=1,...,Y=24,Z=25). convert position in alphabet back to letter encode the given letter given the single-letter...
Erlang implementation of Vigenère cipher -module(vigenere_ok). -export([encrypt/2, decrypt/2, from_pos/1, to_pos/1, encrypt/2]). -import(lists, [append/2, filter/2, map/2, zipwith/3]). isupper([C|_]) -> isupper(C); isupper(C) -> (C >= $A) and (C =< $Z). islower([C|_]) -> islower(C); islower(C) -> (C >= $...
0f8ef8ad403bde27349541408a640581f49af498a213b5bf41ab124d2956e10a
sealchain-project/sealchain
Check.hs
{-# LANGUAGE DataKinds #-} {-# LANGUAGE LambdaCase #-} # LANGUAGE MultiParamTypeClasses # # LANGUAGE NamedFieldPuns # # LANGUAGE OverloadedStrings # {-# LANGUAGE PatternSynonyms #-} # LANGUAGE RecordWildCards # {-# LANGUAGE ScopedTypeVariables #-} # LANGUAGE TupleSecti...
null
https://raw.githubusercontent.com/sealchain-project/sealchain/e97b4bac865fb147979cb14723a12c716a62e51e/pact/src/Pact/Analyze/Check.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE LambdaCase # # LANGUAGE PatternSynonyms # # LANGUAGE ScopedTypeVariables # | Entrypoint for symbolic analysis of Pact programs -- for checking that functions obey properties and maintain invariants. always return 'False' in these cases. -- Assumes s...
# LANGUAGE MultiParamTypeClasses # # LANGUAGE NamedFieldPuns # # LANGUAGE OverloadedStrings # # LANGUAGE RecordWildCards # # LANGUAGE TupleSections # # LANGUAGE TypeApplications # module Pact.Analyze.Check ( verifyModule , renderVerifiedModule , verifyCheck , describeCheckFai...
cabe6a82a54f5434a15c50ec6f6a1d1f2a38c3136d56915a3ca9da7fee0fda00
facebook/flow
documentSymbolProvider.ml
* Copyright ( c ) Meta Platforms , Inc. and affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in t...
null
https://raw.githubusercontent.com/facebook/flow/741104e69c43057ebd32804dd6bcc1b5e97548ea/src/lsp/documentSymbolProvider.ml
ocaml
* Copyright ( c ) Meta Platforms , Inc. and affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in t...
acc3336f96ed831a6064a26ea1e7c215ca4dcf8ddfcc91f46601560a3977b0b2
rtrusso/scp
fastset.scm
;; sasm/fastset.scm ;; ;; This was originally a relatively "fast" set primitives in terms of ;; arbitrary-precision bitwise integer arithmetic. ;; ;; However, the arbitrary-precision bitwise integer arithmetic was ;; part of a specific and now defunct scheme implementation that is no ;; longer a good dependency....
null
https://raw.githubusercontent.com/rtrusso/scp/2051e76df14bd36aef81aba519ffafa62b260f5c/src/sasm/fastset.scm
scheme
sasm/fastset.scm This was originally a relatively "fast" set primitives in terms of arbitrary-precision bitwise integer arithmetic. However, the arbitrary-precision bitwise integer arithmetic was part of a specific and now defunct scheme implementation that is no longer a good dependency. Therefore the c...
(define (fastset-importer symbolic-set) (let ((len (length symbolic-set))) (vector (lambda () (make-string len #\0)) (lambda (symbol) (let ((match (member symbol symbolic-set))) (if (not match) (error "Unrecognized symbol -- fastset" symbol symbolic-set)) ...
15eb9070fee4751bd35807e89113fd01ead0bcc69d58bb16dfffca167eeb5ace
purescript/purescript
IntCompare.hs
-- | -- Graph-based solver for comparing type-level numbers with respect to -- reflexivity, symmetry, and transitivity properties. -- module Language.PureScript.TypeChecker.Entailment.IntCompare where import Protolude import qualified Data.Graph as G import qualified Data.Map as M import qualified Language.PureScrip...
null
https://raw.githubusercontent.com/purescript/purescript/5f6a6659391563cdec3c41ac6a4b2ff5263d0f68/src/Language/PureScript/TypeChecker/Entailment/IntCompare.hs
haskell
| Graph-based solver for comparing type-level numbers with respect to reflexivity, symmetry, and transitivity properties. Commentary: In essence, this solver builds a directed graph using the provided context, which is then used to determine the relationship between Given the context [a < b, b < c], we can in...
module Language.PureScript.TypeChecker.Entailment.IntCompare where import Protolude import qualified Data.Graph as G import qualified Data.Map as M import qualified Language.PureScript.Names as P import qualified Language.PureScript.Types as P import qualified Language.PureScript.Constants.Prim as P data Relation a...
e74528668207bfade62aba1877cf1c0b7124fe55d21cf8d2dc0602fe74556caf
hasktorch/hasktorch
Main.hs
# LANGUAGE DeriveGeneric # # LANGUAGE ExtendedDefaultRules # # LANGUAGE LambdaCase # # LANGUAGE MultiParamTypeClasses # # LANGUAGE RecordWildCards # module Main where import qualified Codec.Picture as I import Control.Monad (foldM) import System.Environment (getArgs) import Torch hiding (load) import Torch.NN import ...
null
https://raw.githubusercontent.com/hasktorch/hasktorch/8fa4d2a6cdb7f144484f7d24d8d4924fb0faecd2/examples/load-torchscript/Main.hs
haskell
# LANGUAGE DeriveGeneric # # LANGUAGE ExtendedDefaultRules # # LANGUAGE LambdaCase # # LANGUAGE MultiParamTypeClasses # # LANGUAGE RecordWildCards # module Main where import qualified Codec.Picture as I import Control.Monad (foldM) import System.Environment (getArgs) import Torch hiding (load) import Torch.NN import ...
9cad1b38b39e6b0cfdea1937b80fbef764f91ccc480ff8af6fff96363346ca7f
tezos/tezos-mirror
sc_rollup_inbox_storage.ml
(*****************************************************************************) (* *) (* Open Source License *) Copyright ( c ) 2022 Nomadic Labs < > Copyright ( c ) 2022 ...
null
https://raw.githubusercontent.com/tezos/tezos-mirror/6cce98810919826c01005f2ffbd02a2302aa91bb/src/proto_alpha/lib_protocol/sc_rollup_inbox_storage.ml
ocaml
*************************************************************************** Open Source License Permission is h...
Copyright ( c ) 2022 Nomadic Labs < > Copyright ( c ) 2022 TriliTech < > to deal in the Software without restriction , including without limitation and/or sell copies of the Software , and to permit persons to whom the THE SOFTWARE IS PROVIDED " AS IS " , WITHOU...
763f174ab52c84ba25b3c162b0d30f560bfde312a27fc6b4b828349d323ca9dd
lspitzner/brittany
Test10.hs
func :: lkasdlkjalsdjlakjsdlkjasldkjalskdjlkajsd -> (lakjsdlkjasldkj -> lakjsdlkjasldkj)
null
https://raw.githubusercontent.com/lspitzner/brittany/a15eed5f3608bf1fa7084fcf008c6ecb79542562/data/Test10.hs
haskell
func :: lkasdlkjalsdjlakjsdlkjasldkjalskdjlkajsd -> (lakjsdlkjasldkj -> lakjsdlkjasldkj)
7f3661cb07fe3e7b6ed64c80eb141f91e43d1b2ecb6fcd09e6e73454b3dd9360
kieranbrowne/clojure-tensorflow
optimizers.clj
(ns clojure-tensorflow.optimizers (:require [clojure-tensorflow.gradients :refer [gradients apply-gradients relevant-variables]] [clojure-tensorflow.ops :as tf])) (defn gradient-descent "The very simplest optimizer." [cost-fn & arguments] (let [{l-rate :learning-rate weights :weights} ...
null
https://raw.githubusercontent.com/kieranbrowne/clojure-tensorflow/a1771cda9e108c8575da7addbe4fe55283c5149b/src/clojure_tensorflow/optimizers.clj
clojure
(ns clojure-tensorflow.optimizers (:require [clojure-tensorflow.gradients :refer [gradients apply-gradients relevant-variables]] [clojure-tensorflow.ops :as tf])) (defn gradient-descent "The very simplest optimizer." [cost-fn & arguments] (let [{l-rate :learning-rate weights :weights} ...
58624a4a5a82ab5becfac82a9979c32c8ab3b9a5d4783ab36283a0c9f1a8819f
stevebleazard/ocaml-jsonxt
strict_stream.ml
module Lexxer = Compliant_lexxer.Make(Strict.Compliance) module Parser_stream = Parser_stream.Make(Strict.Compliance) include Reader_stream.Make (Lexxer) (Parser_stream) include Writer_stream.Make(Strict.Compliance)
null
https://raw.githubusercontent.com/stevebleazard/ocaml-jsonxt/fe982b6087dd76ca003d8fbc19ae9a519f54b828/lib/strict_stream.ml
ocaml
module Lexxer = Compliant_lexxer.Make(Strict.Compliance) module Parser_stream = Parser_stream.Make(Strict.Compliance) include Reader_stream.Make (Lexxer) (Parser_stream) include Writer_stream.Make(Strict.Compliance)
57db9fb3c2dfe6a1e0c53995947f41bb38ff5d8d455cf483e3b43ebbf1f20156
MinaProtocol/mina
snarky_tests.ml
(* this is ugly, but [Core_kernel.String] doesn't have a [trim] function *) let trim = String.trim open Core_kernel instantiate snarky for Vesta module Impl = Snarky_backendless.Snark.Run.Make (struct include Kimchi_backend.Pasta.Vesta_based_plonk module Inner_curve = Kimchi_backend.Pasta.Pasta.Pallas end) (*...
null
https://raw.githubusercontent.com/MinaProtocol/mina/b4cc63cba9928f5f8044a20279e581af85a21f7a/src/lib/crypto/snarky_tests/snarky_tests.ml
ocaml
this is ugly, but [Core_kernel.String] doesn't have a [trim] function helpers monadic API tests * Both the monadic and imperative API will produce the same circuit hash. circuit-focused tests * This function tests all the possible combinations for the range gates. try to generate witness TODO: it'd be nice...
let trim = String.trim open Core_kernel instantiate snarky for Vesta module Impl = Snarky_backendless.Snark.Run.Make (struct include Kimchi_backend.Pasta.Vesta_based_plonk module Inner_curve = Kimchi_backend.Pasta.Pasta.Pallas end) let compare_with obtained filepath = let (_ : int) = Sys.command "tree" in ...
f4cc184c1d088a0bd83e5708aefcb3c24d910ce128f173de3862978779b15a71
tsoding/HyperNerd
Functor.hs
module HyperNerd.Functor where reflect :: Functor f => (f (a -> b) -> a) -> f (a -> b) -> f b reflect r f = ($ r f) <$> f
null
https://raw.githubusercontent.com/tsoding/HyperNerd/5322580483c5c05179bc455a6f94566d398bccdf/src/HyperNerd/Functor.hs
haskell
module HyperNerd.Functor where reflect :: Functor f => (f (a -> b) -> a) -> f (a -> b) -> f b reflect r f = ($ r f) <$> f
48a31e355412760b27ac27b0f2725cc9449421a599b94d9638d0bb0a1917c2fc
camllight/camllight
io.mli
(* Buffered input and output *) type in_channel;; type out_channel;; (* The abstract types of input channels and output channels. *) exception End_of_file (* Raised when an operation cannot complete, because the end of the file has been reached. *) ;; value stdin : in_channel and std_in :...
null
https://raw.githubusercontent.com/camllight/camllight/0cc537de0846393322058dbb26449427bfc76786/windows/src/lib/io.mli
ocaml
Buffered input and output The abstract types of input channels and output channels. Raised when an operation cannot complete, because the end of the file has been reached. Flush all pending writes on [std_out] and [std_err], and terminate the process, returning the given status code to ...
type in_channel;; type out_channel;; exception End_of_file ;; value stdin : in_channel and std_in : in_channel and stdout : out_channel and std_out : out_channel and stderr : out_channel and std_err : out_channel The standard input , standard output , and standard error output for the process...
01a170c30b4cdabf3b528131b90ae1425da32c3e4e52f294425bd93ee10aa0a1
dbuenzli/vg
vgr_pdf.ml
--------------------------------------------------------------------------- Copyright ( c ) 2013 The vg programmers . All rights reserved . Distributed under the ISC license , see terms at the end of the file . --------------------------------------------------------------------------- Copyright (c) 20...
null
https://raw.githubusercontent.com/dbuenzli/vg/2d0cd56636a17280fe938ecaafc6402383dca1f3/src/vgr_pdf.ml
ocaml
Unsafe string byte manipulations. If you don't believe the author's invariants, replacing with safe versions makes everything safe in the module. He won't be upset. Constants and convenience functions. U+0028 U+0029 U+005C U+000D Fonts name Render state PDF object ids. current transform with ...
--------------------------------------------------------------------------- Copyright ( c ) 2013 The vg programmers . All rights reserved . Distributed under the ISC license , see terms at the end of the file . --------------------------------------------------------------------------- Copyright (c) 20...
6b6e30dbb0a876eccd30d1ee062d1cf72307ac3e329bf8f0b4aad99d25b8fa76
JHU-PL-Lab/jaylang
enc-zip_map2.ml
let rec loop x = loop x let rec zip x y = if x=0 then if y=0 then x else assert false else if y=0 then assert false else 1 + zip (x-1) (y-1) let rec map x = if x=0 then x else 1+ map (x-1) let main n = assert(map (zip n n)=n)
null
https://raw.githubusercontent.com/JHU-PL-Lab/jaylang/484b3876986a515fb57b11768a1b3b50418cde0c/benchmark/cases/mochi_origin/mochi/enc-zip_map2.ml
ocaml
let rec loop x = loop x let rec zip x y = if x=0 then if y=0 then x else assert false else if y=0 then assert false else 1 + zip (x-1) (y-1) let rec map x = if x=0 then x else 1+ map (x-1) let main n = assert(map (zip n n)=n)
c282f3211cfe3e120a4949bee06515027a8914c36c147e194b5a143ce96ea291
endobson/racket-llvm
references.rkt
#lang racket/base (require racket/contract unstable/contract "convertible.rkt" "memory.rkt" "types.rkt" "indexed-types.rkt" "memory.rkt" "parameters.rkt" "predicates.rkt") (provide (contract-out (llvm:reference? predicate/c) (llvm:reference (-> llvm-any-pointer/c llvm:reference?)) (llvm:refe...
null
https://raw.githubusercontent.com/endobson/racket-llvm/3eb557b0fe4bddfdfce8e8f4659d218535daa061/private/simple/references.rkt
racket
#lang racket/base (require racket/contract unstable/contract "convertible.rkt" "memory.rkt" "types.rkt" "indexed-types.rkt" "memory.rkt" "parameters.rkt" "predicates.rkt") (provide (contract-out (llvm:reference? predicate/c) (llvm:reference (-> llvm-any-pointer/c llvm:reference?)) (llvm:refe...
b52039f69c206e6a0107ba7570d0775e91393001f0ce95251a2f325e62e3768f
zwizwa/rai
stream-syntax.rkt
#lang racket/base ;; Stream processing DSL surface syntax. ;; See stream.rkt for Racket #lang interface ;; ;; The word "syntax" is context dependent and can refer to: ;; ;; - DSL syntax : abstract syntax (AS) implemented as lambda ;; expressions parameterized by semantics. ;; ;; - Surface syntax: Scheme macros used ...
null
https://raw.githubusercontent.com/zwizwa/rai/6bcacb7da4172971816027fd88a0209adbd60e30/stream-syntax.rkt
racket
Stream processing DSL surface syntax. See stream.rkt for Racket #lang interface The word "syntax" is context dependent and can refer to: - DSL syntax : abstract syntax (AS) implemented as lambda expressions parameterized by semantics. - Surface syntax: Scheme macros used for syntactic sugaring. The Scheme ...
#lang racket/base where one interpretation can shed light on properties of another . (require racket/stxparam "tools.rkt" "type.rkt" (for-syntax racket/base racket/pretty "tools.rkt")) (provide (all-defined-out)) first argument in any abstraction ` ai - ...
5059199355383c7e7e743685082a2d7dd41fab10431b9a508eeefa7b6c087c04
onedata/op-worker
op_worker_app.erl
%%%-------------------------------------------------------------------- @author ( C ) 2014 ACK CYFRONET AGH This software is released under the MIT license cited in ' LICENSE.txt ' . %%% @end %%%-------------------------------------------------------------------- %%% @doc It is the main module of application...
null
https://raw.githubusercontent.com/onedata/op-worker/b09f05b6928121cec4d6b41ce8037fe056e6b4b3/src/op_worker_app.erl
erlang
-------------------------------------------------------------------- @end -------------------------------------------------------------------- @doc It is the main module of application. It lunches supervisor which then initializes appropriate components of node. @end ------------------------------------------------...
@author ( C ) 2014 ACK CYFRONET AGH This software is released under the MIT license cited in ' LICENSE.txt ' . -module(op_worker_app). -author("Michal Wrzeszcz"). -behaviour(application). -include("global_definitions.hrl"). -include_lib("ctool/include/logging.hrl"). -export([start/2, stop/1]). -spec sta...
6169237743736efe29e654f57f6f46c02369c6b82d2df0ca9201431c6fa08bc0
thi-ng/geom
gyroid.clj
(ns thi.ng.geom.examples.voxel.gyroid (:require [thi.ng.geom.core :as g] [thi.ng.geom.vector :refer [vec3]] [thi.ng.geom.voxel.svo :as svo] [thi.ng.geom.voxel.isosurface :as iso] [thi.ng.geom.mesh.io :as mio] [thi.ng.math.core :as m] [clojure.java.io :as io])) (def res (double 1/8)) (def wall 0....
null
https://raw.githubusercontent.com/thi-ng/geom/85783a1f87670c5821473298fa0b491bd40c3028/examples/voxel/gyroid.clj
clojure
(ns thi.ng.geom.examples.voxel.gyroid (:require [thi.ng.geom.core :as g] [thi.ng.geom.vector :refer [vec3]] [thi.ng.geom.voxel.svo :as svo] [thi.ng.geom.voxel.isosurface :as iso] [thi.ng.geom.mesh.io :as mio] [thi.ng.math.core :as m] [clojure.java.io :as io])) (def res (double 1/8)) (def wall 0....
760feaa0dcf90f07d390de287e50c3a8e5ca0416f3cee6c81b6417cd47d7c453
expipiplus1/vulkan
XR_KHR_composition_layer_color_scale_bias.hs
{-# language CPP #-} -- | = Name -- -- XR_KHR_composition_layer_color_scale_bias - instance extension -- -- = Specification -- -- See -- <#XR_KHR_composition_layer_color_scale_bias XR_KHR_composition_layer_color_scale_bias> -- in the main specification for complete information. -- -- = Registered Extension Number -- ...
null
https://raw.githubusercontent.com/expipiplus1/vulkan/b1e33d1031779b4740c279c68879d05aee371659/openxr/src/OpenXR/Extensions/XR_KHR_composition_layer_color_scale_bias.hs
haskell
# language CPP # | = Name XR_KHR_composition_layer_color_scale_bias - instance extension = Specification See <#XR_KHR_composition_layer_color_scale_bias XR_KHR_composition_layer_color_scale_bias> in the main specification for complete information. = Registered Extension Number = Revision = Extension a...
35 5 - Requires OpenXR 1.0 < #XR_KHR_composition_layer_color_scale_bias OpenXR Specification > module OpenXR.Extensions.XR_KHR_composition_layer_color_scale_bias ( CompositionLayerColorScaleBiasKHR(..) , KHR_composition_layer_color_scale_bi...
b24d5edd5e32465ad69207baa85c1cd1318191eb61da3bd6698fe6d701785941
srijan-paul/bark
Main.hs
import Bark.FrontMatter (Token (..), parseFromTokens, parseString, tokenize) import Bark.Internal.IOUtil (tryReadFile) import Data.Text (pack) import Test.HUnit (Assertion, Test (..), assertEqual, runTestTT, runTestTTAndExit, runTestText, (~=?)) import Text.Mustache.Types (Value (..)) tokenizerTests :: [Test] tokenize...
null
https://raw.githubusercontent.com/srijan-paul/bark/de4c4136591fe37affa1ee08ae265ff2968e20ff/test/Main.hs
haskell
that I could come up with was to stringize them with `show` and compare with expected values. Haxskel :)
import Bark.FrontMatter (Token (..), parseFromTokens, parseString, tokenize) import Bark.Internal.IOUtil (tryReadFile) import Data.Text (pack) import Test.HUnit (Assertion, Test (..), assertEqual, runTestTT, runTestTTAndExit, runTestText, (~=?)) import Text.Mustache.Types (Value (..)) tokenizerTests :: [Test] tokenize...
fd0c5122ce27309f99fd04de9a98f445503c3f009ede146f24dc11a58a2dab5e
sjl/temperance
1-parsing.lisp
(in-package :temperance) ;;;; .-,--. ;;;; '|__/ ,-. ,-. ,-. . ,-. ,-. ;;;; ,| ,-| | `-. | | | | | ;;;; `' `-^ ' `-' ' ' ' `-| ;;;; ,| ;;;; `' ; todo functor -> fname (defstruct node) (defstruct (top-level-node (:include node)) (functor nil :type sy...
null
https://raw.githubusercontent.com/sjl/temperance/f7e68f46b7afaeecf643c009eb2e130500556e31/src/compiler/1-parsing.lisp
lisp
.-,--. '|__/ ,-. ,-. ,-. . ,-. ,-. ,| ,-| | `-. | | | | | `' `-^ ' `-' ' ' ' `-| ,| `' todo functor -> fname The register allocated to store this node. The register that actually holds the variable (NOT the argument register).
(in-package :temperance) (defstruct node) (defstruct (top-level-node (:include node)) (functor nil :type symbol) (arity 0 :type arity) (arguments nil :type list)) (defstruct (vanilla-node (:include node) (:conc-name node-)) (register nil :type (or null register))) (defstruct (st...
c784514847ad6745e7b22790f90e222c496dc485f4e532c4adb0cb88b1853ef6
janestreet/universe
ascii_table_kernel_intf.ml
open! Core_kernel module Attr = Ansi_kernel.Attr module Align = struct type t = | Left | Right | Center end module type Ascii_table_kernel = sig module Attr = Attr module Align = Align module Display : sig type t (** Default--cells can be multi-line. *) val short_box : t (** Put...
null
https://raw.githubusercontent.com/janestreet/universe/b6cb56fdae83f5d55f9c809f1c2a2b50ea213126/textutils/ascii_table/kernel/ascii_table_kernel_intf.ml
ocaml
* Default--cells can be multi-line. * Puts --- between entries. * Trails off with ... if necessary. * No lines. * Draw lines only under column titles. * creates a column given the header and the to-string function Default: left Default: `Yes * like create, except that the to_string function must provide a lis...
open! Core_kernel module Attr = Ansi_kernel.Attr module Align = struct type t = | Left | Right | Center end module type Ascii_table_kernel = sig module Attr = Attr module Align = Align module Display : sig type t val short_box : t val tall_box : t val line : t val blank : ...
912a7309d2e8d5357cc30049c9b6e76b2f201a9893e68b3cd4e7ba042834657f
clojure/jvm.tools.analyzer
docstring.clj
Copyright ( c ) and contributors . All rights reserved . ; The use and distribution terms for this software are covered by the ; Eclipse Public License 1.0 (-1.0.php) ; which can be found in the file epl-v10.html at the root of this distribution. ; By using this software in any fashion, you are agreeing t...
null
https://raw.githubusercontent.com/clojure/jvm.tools.analyzer/15ca8ddc5f966c3cb964b17171803ec367fa5861/src/main/clojure/clojure/jvm/tools/analyzer/examples/docstring.clj
clojure
The use and distribution terms for this software are covered by the Eclipse Public License 1.0 (-1.0.php) which can be found in the file epl-v10.html at the root of this distribution. By using this software in any fashion, you are agreeing to be bound by the terms of this license. You must not remove ...
Copyright ( c ) and contributors . All rights reserved . (ns clojure.jvm.tools.analyzer.examples.docstring "Warns on suspected misplaced docstrings in function definitions. Entry point `find-and-check-defs`" (:require [clojure.jvm.tools.analyzer :as analyze])) (defn check-def [exp] (when (= :fn-expr (->...
3d1f81332aeeb2c17999c81888b8ad50e1689557d1d414dfeafff9f9042c986c
baconpaul/composition-kit
logical_to_physical.clj
(ns composition-kit.music-lib.logical-to-physical (:require [composition-kit.music-lib.midi-util :as midi]) (:require [composition-kit.music-lib.tempo :as tempo]) (:require [composition-kit.events.physical-sequence :as ps]) (:require [composition-kit.events.transport-window :as tw]) (:require [composition-kit...
null
https://raw.githubusercontent.com/baconpaul/composition-kit/fce0addb74a9c30ba06e051d3bca51c5a2b0ce6f/src/composition_kit/music_lib/logical_to_physical.clj
clojure
Here we project through the clock and the instrument to a set of actual midi functions which will play the music to the midi ports specified at the time and volumen needed, including the various control and pitch commands. This is basically a massive reduce statement on a big switch based on item type which then do...
(ns composition-kit.music-lib.logical-to-physical (:require [composition-kit.music-lib.midi-util :as midi]) (:require [composition-kit.music-lib.tempo :as tempo]) (:require [composition-kit.events.physical-sequence :as ps]) (:require [composition-kit.events.transport-window :as tw]) (:require [composition-kit...
3c8b4e38c6cd7e3712d36adff0d0f7fca4e14bfdb7756006edc34ab0e09a5a87
RBornat/jape
draw.ml
Copyright ( C ) 2003 - 19 This file is part of the proof engine , which is part of . 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 ver...
null
https://raw.githubusercontent.com/RBornat/jape/ff6949f411ffb7449b235e1a64b138cf0044b026/distrib/camlengine/draw.ml
ocaml
could be Japeserver.class__, if I played it right ... width of the lines (box, selection) we draw consolereport["leading ", string_of_int leading, "; thickness ", string_of_int r]; note fixed alignment, so don't use for folded/multiline texts let (rf, rs) = fontNstring_of_reason r in textinfo_of_string rf (J...
Copyright ( C ) 2003 - 19 This file is part of the proof engine , which is part of . 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 ver...
13303fe4e8e523e943703b6b25de82367792c630d503dbc29f66b9660c421d7c
onedata/op-worker
provider_middleware_plugin.erl
%%%------------------------------------------------------------------- @author ( C ) 2019 - 2021 ACK CYFRONET AGH This software is released under the MIT license cited in ' LICENSE.txt ' . %%% @end %%%------------------------------------------------------------------- %%% @doc %%% This module handles middlew...
null
https://raw.githubusercontent.com/onedata/op-worker/57579e74cfb93981c55e620af9bf9772ee0a991f/src/middleware/plugins/provider_middleware_plugin.erl
erlang
------------------------------------------------------------------- @end ------------------------------------------------------------------- @doc This module handles middleware operations (create, get, update, delete) corresponding to provider aspects such as e.g. instance or configuration. @end ------------------...
@author ( C ) 2019 - 2021 ACK CYFRONET AGH This software is released under the MIT license cited in ' LICENSE.txt ' . -module(provider_middleware_plugin). -author("Bartosz Walkowicz"). -behaviour(middleware_router). -behaviour(middleware_handler). -include("middleware/middleware.hrl"). -include("modules/rt...
344f2e974de38541b97fca05ed1ae9064cdedfb5c45011504292fbe84a706f91
clojure-interop/java-jdk
BadAttributeValueExpException.clj
(ns javax.management.BadAttributeValueExpException "Thrown when an invalid MBean attribute is passed to a query constructing method. This exception is used internally by JMX during the evaluation of a query. User code does not usually see it." (:refer-clojure :only [require comment defn ->]) (:import [jav...
null
https://raw.githubusercontent.com/clojure-interop/java-jdk/8d7a223e0f9a0965eb0332fad595cf7649d9d96e/javax.management/src/javax/management/BadAttributeValueExpException.clj
clojure
(ns javax.management.BadAttributeValueExpException "Thrown when an invalid MBean attribute is passed to a query constructing method. This exception is used internally by JMX during the evaluation of a query. User code does not usually see it." (:refer-clojure :only [require comment defn ->]) (:import [jav...
b86803f38cd32405b97672a110a82904ad74850ef453b174bd646e702c96affa
larcenists/larceny
conflicts.scm
;;; Tests for name conflicts among standard libraries. ;;; ;;; Known conflicts: ;;; ;;; bytevector-copy! (unresolvable; requires renaming) ;;; define - record - type ( resolved by allowing both R7RS and R6RS syntax ) ;;; error (resolved by heuristic overloading) map ...
null
https://raw.githubusercontent.com/larcenists/larceny/fef550c7d3923deb7a5a1ccd5a628e54cf231c75/test/R7RS/conflicts.scm
scheme
Tests for name conflicts among standard libraries. Known conflicts: bytevector-copy! (unresolvable; requires renaming) error (resolved by heuristic overloading) remove (unresolvable; requires renaming) string-hash (deprecated version takes optional argumen...
define - record - type ( resolved by allowing both R7RS and R6RS syntax ) map ( resolved by using extended semantics ) for - each ( resolved by using extended semantics ) finite ? ( resolved by using extended semantics ) infinite ? ...
dbc70d7186ae5d168327f571a77f5c6a2a7e1433ef16d2d70c514e23c4964167
sellout/haskerwaul
Left.hs
# language GADTSyntax , TypeApplications , UndecidableInstances # , TypeApplications , UndecidableInstances #-} module Haskerwaul.Extension.Kan.Left ( module Haskerwaul.Extension.Kan.Left ) where import Data.Constraint ((\\)) import Haskerwaul.Functor imp...
null
https://raw.githubusercontent.com/sellout/haskerwaul/cf54bd7ce5bf4f3d1fd0d9d991dc733785b66a73/src/Haskerwaul/Extension/Kan/Left.hs
haskell
| __NB__: This implementation, moreso than `Haskerwaul.Extension.Kan.Right.RightKanExtension`, illustrates why f C -> D p| /` C' arrow other than @->@ in the last position, and that is a morphism = references - [nLab](+extension) - [Wikipedia]()
# language GADTSyntax , TypeApplications , UndecidableInstances # , TypeApplications , UndecidableInstances #-} module Haskerwaul.Extension.Kan.Left ( module Haskerwaul.Extension.Kan.Left ) where import Data.Constraint ((\\)) import Haskerwaul.Functor imp...
2ed5a974d439110697b27418654a6f0d0714edf395f4cb47b2060ca7a2fcf6e1
mauny/the-functional-approach-to-programming
queue.ml
#open "circular_list";; (* +enqueue+ *) let enqueue x = fun Emptyqueue -> Queue (mk_circular_list x) | (Queue ln) -> Queue (insert_tail x ln);; (* +enqueue+ *) (* +dequeue+ *) let dequeue = fun Emptyqueue -> failwith "dequeue: queue is empty" | (Queue ln) -> if ln.next == ln then (Empty...
null
https://raw.githubusercontent.com/mauny/the-functional-approach-to-programming/1ec8bed5d33d3a67bbd67d09afb3f5c3c8978838/cl-75/Imper/queue.ml
ocaml
+enqueue+ +enqueue+ +dequeue+ +dequeue+
#open "circular_list";; let enqueue x = fun Emptyqueue -> Queue (mk_circular_list x) | (Queue ln) -> Queue (insert_tail x ln);; let dequeue = fun Emptyqueue -> failwith "dequeue: queue is empty" | (Queue ln) -> if ln.next == ln then (Emptyqueue,ln.info) else let x =...
625481adaa0e1d069d36e7135d136f06fe8108df845eb66576f6500118584be2
cuddlefishie/chambo
Syntax.hs
module Syntax where import Data.Bifunctor import Data.List import qualified Data.Map as M import Data.Maybe newtype File = File [Item] newtype Item = IFunction Function deriving (Show, Eq) data Function = Function { funName :: String , funArgs :: [(String, Type)] ...
null
https://raw.githubusercontent.com/cuddlefishie/chambo/efd8c622c8b9a7a6488a8ab9ad44df83e16615f6/src/Syntax.hs
haskell
module Syntax where import Data.Bifunctor import Data.List import qualified Data.Map as M import Data.Maybe newtype File = File [Item] newtype Item = IFunction Function deriving (Show, Eq) data Function = Function { funName :: String , funArgs :: [(String, Type)] ...
6079213576750599b81975f8b78a43b4213b40181c76b70f9b7b01cc62834d1b
threatgrid/clj-momo
map.cljc
(ns clj-momo.lib.map (:require [clojure.set :as set])) (defn rmerge [& vals] (if (every? map? vals) (apply merge-with rmerge vals) (last vals))) ;; from -can-i-get-the-nested-keys-of-a-map-in-clojure (defn keys-in [m] (if (map? m) (vec (mapcat (fn [[k v]] (let [sub (keys-in v) ...
null
https://raw.githubusercontent.com/threatgrid/clj-momo/7bc0a411593eee4a939b6a3d0f628413518e09e2/src/clj_momo/lib/map.cljc
clojure
from -can-i-get-the-nested-keys-of-a-map-in-clojure
(ns clj-momo.lib.map (:require [clojure.set :as set])) (defn rmerge [& vals] (if (every? map? vals) (apply merge-with rmerge vals) (last vals))) (defn keys-in [m] (if (map? m) (vec (mapcat (fn [[k v]] (let [sub (keys-in v) nested (map #(into [k] %) (remove ...
ed05cdc68cc20f541ad1a1d522a4cf16db2c4960ee4027ec50ed1d2238545681
open-telemetry/opentelemetry-erlang
otel_otlp_logs.erl
%%%------------------------------------------------------------------------ Copyright 2022 , OpenTelemetry Authors 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 %% %% Unl...
null
https://raw.githubusercontent.com/open-telemetry/opentelemetry-erlang/f5084c16201cac2aaaabe089fb000acc6ac622fc/apps/opentelemetry_experimental/src/otel_otlp_logs.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 o...
Copyright 2022 , OpenTelemetry Authors Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(otel_otlp_logs). -export([to_proto/3]). -ifdef(TEST). -export([to_proto_by_instrumentation_scope/2]). -endif. -include_lib("k...
b6126fc380e21f812774f5725cbe21d3dd2c531d066eb351d0059407ecb7a3ea
finnishtransportagency/harja
yha_paikkauskomponentti.clj
(ns harja.palvelin.integraatiot.yha.yha-paikkauskomponentti (:require [com.stuartsierra.component :as component] [hiccup.core :refer [html]] [taoensso.timbre :as log] [harja.palvelin.integraatiot.integraatiotapahtuma :as integraatiotapahtuma] [harja.palvelin.integraatio...
null
https://raw.githubusercontent.com/finnishtransportagency/harja/222ecd9907e2a34364f8bf7bb4a1035939b039f6/src/clj/harja/palvelin/integraatiot/yha/yha_paikkauskomponentti.clj
clojure
(ns harja.palvelin.integraatiot.yha.yha-paikkauskomponentti (:require [com.stuartsierra.component :as component] [hiccup.core :refer [html]] [taoensso.timbre :as log] [harja.palvelin.integraatiot.integraatiotapahtuma :as integraatiotapahtuma] [harja.palvelin.integraatio...
f8f1bdd8bc6718e0eb98ee5c6b5cd754571611fc8e28b780a639c93e0f5e193f
manu291/dypgen
global_data.ml
let () = print_endline " Counting the number of reductions with data Priorities: pi<p*<p+ Grammar: S -> E E(pi) -> int E(p+) -> E(<=p+) + E(<p+) E(p*) -> E(<=p*) * E(<p*) " let lexbuf = Dyp.from_channel (Global_data_parser.pp ()) stdin let _ = try while true do (Dyp.flush_input lexbuf; try ...
null
https://raw.githubusercontent.com/manu291/dypgen/59d11b4c70b8d0971348ca6913839ff1fb4f9b5f/demos/global_data/global_data.ml
ocaml
let () = print_endline " Counting the number of reductions with data Priorities: pi<p*<p+ Grammar: S -> E E(pi) -> int E(p+) -> E(<=p+) + E(<p+) E(p*) -> E(<=p*) * E(<p*) " let lexbuf = Dyp.from_channel (Global_data_parser.pp ()) stdin let _ = try while true do (Dyp.flush_input lexbuf; try ...
ea820b81c6c7244197e05aa089e3bd6598c391f632897dd8454f029aac0cad06
danieljharvey/nix-mate
CreateNixFile.hs
module NixMate.Actions.CreateNixFile ( createNixFile, createDerivation, savePackageNix, ) where import Data.Coerce import qualified Data.List as L import Data.Set as S import NixMate.Types.Config ( Config (..), Dependency (..), ProjectName (..), Rev (..), Sha256 (..), ShellPath (..), ...
null
https://raw.githubusercontent.com/danieljharvey/nix-mate/0197b8517319a4ad4c9cb489579a6ed36ad9aec1/src/NixMate/Actions/CreateNixFile.hs
haskell
create shell.nix file from our config
module NixMate.Actions.CreateNixFile ( createNixFile, createDerivation, savePackageNix, ) where import Data.Coerce import qualified Data.List as L import Data.Set as S import NixMate.Types.Config ( Config (..), Dependency (..), ProjectName (..), Rev (..), Sha256 (..), ShellPath (..), ...
51b3d1b56d79c71eb4017b68398f444da365c6e5c435831b9303966e9274f572
tnelson/Forge
url.rkt
#lang racket/base (require net/url) (provide ws-url? wss-url?) (define (ws-url? x) (and (url? x) (or (equal? (url-scheme x) "ws") (equal? (url-scheme x) "wss")))) (define (wss-url? x) (and (url? x) (equal? (url-scheme x) "wss")))
null
https://raw.githubusercontent.com/tnelson/Forge/1687cba0ebdb598c29c51845d43c98a459d0588f/forge/racket-rfc6455/net/rfc6455/url.rkt
racket
#lang racket/base (require net/url) (provide ws-url? wss-url?) (define (ws-url? x) (and (url? x) (or (equal? (url-scheme x) "ws") (equal? (url-scheme x) "wss")))) (define (wss-url? x) (and (url? x) (equal? (url-scheme x) "wss")))
8fc7a3ce9b4db0b896492961edcf2e78eba26878939d0ce178a423cb0566e3b0
ekmett/unboxed
DoubleRep.hs
{-# Language DataKinds #-} module DoubleRep where import GHC.Types type Rep = 'DoubleRep
null
https://raw.githubusercontent.com/ekmett/unboxed/e4c6ca80fb8946b1abfe595ba1c36587a33931db/internal/DoubleRep.hs
haskell
# Language DataKinds #
module DoubleRep where import GHC.Types type Rep = 'DoubleRep
4994369a1fe96420aa5e1a7f088ae9412b71971549152b6a97ec89c4d3e101b9
ivankelly/gambit
_system#.scm
;;;============================================================================ File : " _ system#.scm " , Time - stamp : < 2007 - 05 - 27 22:03:58 feeley > Copyright ( c ) 1994 - 2007 by , All Rights Reserved . ;;;============================================================================ ;;; Representation...
null
https://raw.githubusercontent.com/ivankelly/gambit/7377246988d0982ceeb10f4249e96badf3ff9a8f/lib/_system%23.scm
scheme
============================================================================ ============================================================================ Representation of exceptions. ---------------------------------------------------------------------------- Define type checking macros. ----------------------------...
File : " _ system#.scm " , Time - stamp : < 2007 - 05 - 27 22:03:58 feeley > Copyright ( c ) 1994 - 2007 by , All Rights Reserved . (define-library-type-of-exception invalid-hash-number-exception id: 3b7674e5-a6d8-11d9-930c-00039301ba52 constructor: #f opaque: (procedure unprintable: read-only:) (...
1ce5b5d01028c89388ff37745b90dbe7656bf3d429efb8753d1eadcbd424817a
cloudamqp/rabbitmq-vshovel
rabbit_vshovel_config.erl
The contents of this file are subject to the Mozilla Public License Version 1.1 ( the " License " ) ; you may not use this file except in %% compliance with the License. You may obtain a copy of the License %% at / %% Software distributed under the License is distributed on an " AS IS " %% basis, WITHOUT WA...
null
https://raw.githubusercontent.com/cloudamqp/rabbitmq-vshovel/c439a10efdc518eb930dcccdd0a7334f1ca859ce/src/rabbit_vshovel_config.erl
erlang
compliance with the License. You may obtain a copy of the License at / basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. ensures that any defaults that have been applied to a parsed shovel, are wr...
The contents of this file are subject to the Mozilla Public License Version 1.1 ( the " License " ) ; you may not use this file except in Software distributed under the License is distributed on an " AS IS " The Original Code is RabbitMQ . The Initial Developer of the Original Code is GoPivotal , Inc. ...
11c311ebeb314d59efc4b2b7155910c4377f599b074297d4a37618829eb4a626
runtimeverification/haskell-backend
Registry.hs
module Test.Kore.Rewrite.Axiom.Registry ( test_functionRegistry, ) where import Data.Default qualified as Default import Data.Map.Strict qualified as Map import Data.Text ( Text, ) import Kore.Attribute.Owise qualified as Attribute import Kore.Attribute.Priority ( defaultPriority, owisePriority, ) im...
null
https://raw.githubusercontent.com/runtimeverification/haskell-backend/93a705112305a2d7e084e98dca93ec33e0d661d5/kore/test/Test/Kore/Rewrite/Axiom/Registry.hs
haskell
module Test.Kore.Rewrite.Axiom.Registry ( test_functionRegistry, ) where import Data.Default qualified as Default import Data.Map.Strict qualified as Map import Data.Text ( Text, ) import Kore.Attribute.Owise qualified as Attribute import Kore.Attribute.Priority ( defaultPriority, owisePriority, ) im...
ba54403a02bae100623f19c2fdbcbdb7a1f2e599e54c133c8ab1c8c0dff9f575
Dasudian/DSDIN
wormhole_fsm_SUITE.erl
-module(wormhole_fsm_SUITE). -export([ all/0 , groups/0 , suite/0 , init_per_suite/1 , end_per_suite/1 , init_per_group/2 , end_per_group/2 ]). %% test case exports -export([ create_channel/1 , upd_transfer/1 , deposit/1 ...
null
https://raw.githubusercontent.com/Dasudian/DSDIN/b27a437d8deecae68613604fffcbb9804a6f1729/apps/wormhole/test/wormhole_fsm_SUITE.erl
erlang
test case exports =================================================================== Test state =================================================================== wild guess dynamic key negotiation
-module(wormhole_fsm_SUITE). -export([ all/0 , groups/0 , suite/0 , init_per_suite/1 , end_per_suite/1 , init_per_group/2 , end_per_group/2 ]). -export([ create_channel/1 , upd_transfer/1 , deposit/1 , withdraw/1 ...
1fad2d14f18e0e1765c663888157a368b3aa57a0a473de229fbc98ba0515c78d
ghc/ghc
Rules.hs
module Rules (buildRules, oracleRules, packageTargets, topLevelTargets , toolArgsTarget ) where import qualified Data.Set as Set import qualified Hadrian.Oracles.ArgsHash import qualified Hadrian.Oracles.Cabal.Rules import qualified Hadrian.Oracles.DirectoryContents import qualified Hadrian.Oracles.Path ...
null
https://raw.githubusercontent.com/ghc/ghc/99aca26b652603bc62953157a48e419f737d352d/hadrian/src/Rules.hs
haskell
by default, respecting the 'finalStage' flag. Why we need wrappers: . either the package database config file for libraries or the programPath for programs. However this still does not support multiple targets, where a cabal package has a library /and/ a program. TODO: Get rid of the @includeGhciLib@ hack. | Re...
module Rules (buildRules, oracleRules, packageTargets, topLevelTargets , toolArgsTarget ) where import qualified Data.Set as Set import qualified Hadrian.Oracles.ArgsHash import qualified Hadrian.Oracles.Cabal.Rules import qualified Hadrian.Oracles.DirectoryContents import qualified Hadrian.Oracles.Path ...
eee511e20456f54baa62013008b17dea2b40044dcc4789cffdf2d929ecae8de7
landakram/kiwi-desktop
tests.cljs
(ns kiwi.tests)
null
https://raw.githubusercontent.com/landakram/kiwi-desktop/cc7d0a5f28430f39d43dffb26850183601fd28f9/test/cljs/kiwi/tests.cljs
clojure
(ns kiwi.tests)
71bb2327aa36c403521932477024b5ede610f47b72b65b32fb2aab1b58ab9e8c
apinf/proxy42
vegur_lookup_service_middleware.erl
Copyright ( c ) 2013 - 2015 , Heroku Inc < > . %%% 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,...
null
https://raw.githubusercontent.com/apinf/proxy42/01b483b711881391e8306bf64b83b4df9d0bc832/apps/vegur/src/vegur_lookup_service_middleware.erl
erlang
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 and the following disclaimer. * Redistributions...
Copyright ( c ) 2013 - 2015 , Heroku Inc < > . " AS IS " AND ANY EXPRESS OR IMPLIED WARRANTIES , INCLUDING , BUT NOT OWNER OR ANY DIRECT , INDIRECT , INCIDENTAL , SPECIAL , EXEMPLARY , OR CONSEQUENTIAL DAMAGES ( INCLUDING , BUT NOT LIMITED TO , PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES ; LOSS OF USE , ...
dbc88c72137e10a987f64617115079ab3aef028e20a8530f821ea07766217c67
williamleferrand/accretio
dinners_with_friends.ml
(* * dinners with friends * * this playbook organizes dinners for a group of friends, asking them for * advice and booking restaurants * * * *) open Lwt open Printf open CalendarLib open Api open Eliom_content.Html5 open Eliom_content.Html5.D open Message_parsers open Toolbox open Ys_uid let _ = Calen...
null
https://raw.githubusercontent.com/williamleferrand/accretio/394f855e9c2a6a18f0c2da35058d5a01aacf6586/playbooks/dinners_with_friends.ml
ocaml
* dinners with friends * * this playbook organizes dinners for a group of friends, asking them for * advice and booking restaurants * * * (* local parameters some helpers ************************************************************** the stages ***********************************************************...
open Lwt open Printf open CalendarLib open Api open Eliom_content.Html5 open Eliom_content.Html5.D open Message_parsers open Toolbox open Ys_uid let _ = CalendarLib.Time_Zone.change (CalendarLib.Time_Zone.UTC_Plus (-8)) let author = "" let name = "Dinners with friends" let description = "This playbook organi...
60deb9d112ab22c9ed936a0b1830a35a812b5d845b107eb8c83afb94c6895efe
anurudhp/CPHaskell
b.hs
{-# LANGUAGE Safe #-} import safe Control.Arrow ((>>>)) main :: IO () main = interact $ lines >>> drop 1 >>> map (words >>> map read) >>> solve >>> show solve :: [[Int]] -> Int solve [vs, cs] = sum . filter (> 0) $ zipWith (-) vs cs
null
https://raw.githubusercontent.com/anurudhp/CPHaskell/01ae8dde6aab4f6ddfebd122ded0b42779dd16f1/contests/atcoder/abc125/b.hs
haskell
# LANGUAGE Safe #
import safe Control.Arrow ((>>>)) main :: IO () main = interact $ lines >>> drop 1 >>> map (words >>> map read) >>> solve >>> show solve :: [[Int]] -> Int solve [vs, cs] = sum . filter (> 0) $ zipWith (-) vs cs
9ca41234c36a2b33bfe8b31513d4a8a223faf2a19bee14063ac9e377c1e66951
jgm/hscommonmark
Spec.hs
{-# LANGUAGE OverloadedStrings #-} import Test.Tasty import Test.Tasty.HUnit import Test.Tasty.QuickCheck import Data.Text.Arbitrary () import CommonMark.Lexer import CommonMark.Types import CommonMark.BlockParser import CommonMark.InlineParser import Data.Tree import Data.Tree.Zipper import qualified Data.Text as Text...
null
https://raw.githubusercontent.com/jgm/hscommonmark/6820c48f0179a5c9c1b7ef973330ca0ff90b3dc0/test/Spec.hs
haskell
# LANGUAGE OverloadedStrings #
import Test.Tasty import Test.Tasty.HUnit import Test.Tasty.QuickCheck import Data.Text.Arbitrary () import CommonMark.Lexer import CommonMark.Types import CommonMark.BlockParser import CommonMark.InlineParser import Data.Tree import Data.Tree.Zipper import qualified Data.Text as Text main :: IO () main = defaultMain ...
8c2d021355060d3fd6fabffc3f81674f78d27f27590bb97267a278135ba9bd08
esl/MongooseIM
mongoose_disco.erl
%%% @doc This module is responsible for running disco_* hooks that collect information %%% for service discovery. It also contains helpers for direct construction of XML elements %%% representing the advertised services. -module(mongoose_disco). %% Hooks wrappers -export([get_local_identity/5, get_sm_identit...
null
https://raw.githubusercontent.com/esl/MongooseIM/dda03c16c83f5ea9f5c9b87c3b36c989813b9250/src/mongoose_disco.erl
erlang
@doc This module is responsible for running disco_* hooks that collect information for service discovery. It also contains helpers for direct construction of XML elements representing the advertised services. Hooks wrappers XML construction helpers Hook wrapper API Helper API XML construction API This is neede...
-module(mongoose_disco). -export([get_local_identity/5, get_sm_identity/5, get_local_items/5, get_sm_items/5, get_local_features/5, get_sm_features/5, get_muc_features/6, get_info/4]). Helpers used by hook handlers for Acc manipulation -export([add_ide...
aff8cd5380d89cf94f55a8401d20806517c084447af8ea0b5157619433e58bbf
eryx67/vk-api-example
Actions.hs
{-# LANGUAGE DeriveAnyClass #-} # LANGUAGE DeriveGeneric # # LANGUAGE FlexibleInstances # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE RecordWildCards # # LANGUAGE TemplateHaskell # {-# LANGUAGE TypeFamilies #-} -- | module VK.App.Actions (VKAction(..) , module Exp) where imp...
null
https://raw.githubusercontent.com/eryx67/vk-api-example/4ce634e2f72cf0ab6ef3b80387ad489de9d8c0ee/src/VK/App/Actions.hs
haskell
# LANGUAGE DeriveAnyClass # # LANGUAGE OverloadedStrings # # LANGUAGE TypeFamilies # |
# LANGUAGE DeriveGeneric # # LANGUAGE FlexibleInstances # # LANGUAGE RecordWildCards # # LANGUAGE TemplateHaskell # module VK.App.Actions (VKAction(..) , module Exp) where import Control.DeepSeq import qualified Data.Text as T import Data.Typeable ...
f3864307c3bbf927c733854a8afef11096a3ff3f55946e1e534b3470aa410848
icicle-lang/icicle-ambiata
Annot.hs
# LANGUAGE NoImplicitPrelude # | Annotation fiddles for Avalanche programs . module Icicle.Avalanche.Annot ( eraseAnnotP, eraseAnnotX, eraseAnnotS , reannotP, reannotX, reannotS ) where import Icicle.Avalanche.Program import Icicle.Avalanche.Statement.Statement -- Re-exported as well as used import Icicle.Com...
null
https://raw.githubusercontent.com/icicle-lang/icicle-ambiata/9b9cc45a75f66603007e4db7e5f3ba908cae2df2/icicle-compiler/src/Icicle/Avalanche/Annot.hs
haskell
Re-exported as well as used
# LANGUAGE NoImplicitPrelude # | Annotation fiddles for Avalanche programs . module Icicle.Avalanche.Annot ( eraseAnnotP, eraseAnnotX, eraseAnnotS , reannotP, reannotX, reannotS ) where import Icicle.Avalanche.Program import Icicle.Avalanche.Statement.Statement import Icicle.Common.Exp.Compounds (reannotX, er...
f1ddc688f21a43699ddd9a6d4d472629394c4c9d5a6e87aaed33fc2021ece34f
rabbitmq/ra
ra_props_SUITE.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 ( c ) 2017 - 2022 VMware , Inc. or its affiliates . All rights reserved . %% -module(ra_props_SUITE). -compile(export_all). -i...
null
https://raw.githubusercontent.com/rabbitmq/ra/72439a5c25f6cf9e8d2a26b21fe456f94df516d4/test/ra_props_SUITE.erl
erlang
just here to silence unused warning this test mixes associative with non-associative operations to tests that all nodes apply operations in the same order set cluster to ct:pal("Result ~p ~p ~p Expected ~p Initial ~p", assert all nodes have the same final state don't print the '.'s on new lines
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 ( c ) 2017 - 2022 VMware , Inc. or its affiliates . All rights reserved . -module(ra_props_SUITE). -compile(export_all). -include...
3c4c10e33e07b5632e0734d007ae17837292551804c33fa37ea7f5fd6e074db6
green-labs/res_tailwindcss
util.ml
let rec find_project_root dir = let bsconfig = "bsconfig.json" in match Filename.concat dir bsconfig |> Sys.file_exists with | true -> Ok dir | false -> let parent = dir |> Filename.dirname in if String.equal parent dir then Error "can't find the project root" else find_project_root parent
null
https://raw.githubusercontent.com/green-labs/res_tailwindcss/277cf2fd847a7ad7f9199bf45809b16419cb8322/src/util.ml
ocaml
let rec find_project_root dir = let bsconfig = "bsconfig.json" in match Filename.concat dir bsconfig |> Sys.file_exists with | true -> Ok dir | false -> let parent = dir |> Filename.dirname in if String.equal parent dir then Error "can't find the project root" else find_project_root parent
89b62d69a0182163d55bc4b75bcc6aa6a1d47645d9020f75a1e3a3c87af72d2c
jpmonettas/hansel
api.clj
(ns hansel.api (:require [hansel.instrument.forms :as inst-forms] [hansel.instrument.namespaces :as inst-ns] [hansel.instrument.utils :as inst-utils] [hansel.utils :as utils :refer [log log-error]] [hansel.instrument.runtime :as rt])) (defn instrument-form "Given a...
null
https://raw.githubusercontent.com/jpmonettas/hansel/c9efa9800e869a5ab084a13b61b9c124a8bac3a3/src/hansel/api.clj
clojure
walk over code s-expressions save the var meta from the symbol. Some times they will not be the same, like in the case of using potemkin/import-vars restore the var meta always skip clojure.core on deep instrumentation always skip cljs.core on deep instrumentation
(ns hansel.api (:require [hansel.instrument.forms :as inst-forms] [hansel.instrument.namespaces :as inst-ns] [hansel.instrument.utils :as inst-utils] [hansel.utils :as utils :refer [log log-error]] [hansel.instrument.runtime :as rt])) (defn instrument-form "Given a...
835ee6a70bf4e0629e2487030fa4122f67a2e88085f0a5fd438a7bd86d096f13
TyOverby/mono
value.ml
open! Core open! Import module Constant_id = Unique_id.Int () type _ without_position = | Constant : 'a * Constant_id.t -> 'a without_position | Incr : 'a Incr.t -> 'a without_position | Named : 'a Type_equal.Id.t -> 'a without_position | Both : 'a t * 'b t -> ('a * 'b) without_position | Cutoff : { t ...
null
https://raw.githubusercontent.com/TyOverby/mono/7666c0328d194bf9a569fb65babc0486f2aaa40d/vendor/janestreet-bonsai/src/value.ml
ocaml
open! Core open! Import module Constant_id = Unique_id.Int () type _ without_position = | Constant : 'a * Constant_id.t -> 'a without_position | Incr : 'a Incr.t -> 'a without_position | Named : 'a Type_equal.Id.t -> 'a without_position | Both : 'a t * 'b t -> ('a * 'b) without_position | Cutoff : { t ...
d2f3b97ff7bee861f56a99f2c5a7fc8b5081a4c9bc9fe49ab68a190618c366c1
scheme-live/live
output.scm
((a . "b"))
null
https://raw.githubusercontent.com/scheme-live/live/4c7c9d80f2fcf80692614e10935fa66be69e3708/live/json/data/n-object-trailing-comment-open/output.scm
scheme
((a . "b"))
4a1ee0b4e4ba0b14b583f13688f65d0ea25342d9964ab1c998869c26aaadfca4
bi7s/CVEs
aaaaa.ml
⿈򪪪
null
https://raw.githubusercontent.com/bi7s/CVEs/bff6f4aa5a09d38c2d2baeede6954d038621dce6/CVE-2019-16294/aaaaa.ml
ocaml
⿈򪪪
fb7342807c53786a598b3bff9349ed9971f6ed1491cc3396b59b497b0efd2dc2
jordanthayer/ocaml-search
user_paths.ml
(** Info on the user's paths to things. *) let instance_root = "./group/data/" (* must end in '/' *) (** The root directory for instances. *) let user_root_tab = [ * This is an associated list of ( username * data_root ) tuples . It uses $ USER to find the current user name and lookup the user 's ...
null
https://raw.githubusercontent.com/jordanthayer/ocaml-search/57cfc85417aa97ee5d8fbcdb84c333aae148175f/user_paths/user_paths.ml
ocaml
* Info on the user's paths to things. must end in '/' * The root directory for instances. * Look up the user's root in the table... expands ~ into the user's home directory. * Look up the user's root in the table... expands ~ into the user's home directory. * Identical to get user, but does not fail w...
let user_root_tab = [ * This is an associated list of ( username * data_root ) tuples . It uses $ USER to find the current user name and lookup the user 's data root ( where datafiles will be stored when the user performs runs ) . If you want to have data stored in an RDB as a resul...
ee1c8df7967c3414cb4478518dc694b42eb169f12af3649b9363e8cc158b2539
turion/rhine
Schedule.hs
| This module supplies a general purpose monad transformer that adds a syntactical " delay " , or " waiting " side effect . This allows for universal and deterministic scheduling of clocks that implement their waiting actions in ' ScheduleT ' . See ' FRP.Rhine . Schedule . Trans ' for more details . This...
null
https://raw.githubusercontent.com/turion/rhine/f997c3593f65361461f62b474661501a5b8ef879/rhine/src/Control/Monad/Schedule.hs
haskell
base transformers free | A functor implementing a syntactical "waiting" action. * 'diff' represents the duration to wait. * 'a' is the encapsulated value. | The side effect that waits for a specified amount. | Supply a semantic meaning to 'Wait'. For every occurrence of @Wait diff@ in the @ScheduleT diff m a...
| This module supplies a general purpose monad transformer that adds a syntactical " delay " , or " waiting " side effect . This allows for universal and deterministic scheduling of clocks that implement their waiting actions in ' ScheduleT ' . See ' FRP.Rhine . Schedule . Trans ' for more details . This...
3b9e59e3747442dd92851467ce64dfdeebd51e31395d2198f0b9578af22fda32
facebookarchive/lex-pass
TaskPool.hs
module TaskPool where import Control.Exception import Control.Concurrent import Control.Monad import Prelude hiding (catch) type TaskChan a = Chan (Maybe (IO a)) worker :: TaskChan a -> Chan () -> IO () worker q doneChan = do taskMb <- readChan q case taskMb of Nothing -> writeChan doneChan () Just task ...
null
https://raw.githubusercontent.com/facebookarchive/lex-pass/dcfa9560a95f2c1344e15493dabcc1645b1ca5e8/src/TaskPool.hs
haskell
module TaskPool where import Control.Exception import Control.Concurrent import Control.Monad import Prelude hiding (catch) type TaskChan a = Chan (Maybe (IO a)) worker :: TaskChan a -> Chan () -> IO () worker q doneChan = do taskMb <- readChan q case taskMb of Nothing -> writeChan doneChan () Just task ...
c25f2c497d7a8b10f2df8bc506f1551b6409919a6b83f64c08173769dccd1cff
fpco/inline-c
Parse.hs
# LANGUAGE CPP # {-# LANGUAGE ConstraintKinds #-} {-# LANGUAGE DeriveDataTypeable #-} # LANGUAGE DeriveFoldable # # LANGUAGE DeriveFunctor # {-# LANGUAGE DeriveTraversable #-} # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # {-# LANG...
null
https://raw.githubusercontent.com/fpco/inline-c/ab1a2d9369d694c5980c09fe3352550121b5ef8f/inline-c/src/Language/C/Types/Parse.hs
haskell
# LANGUAGE ConstraintKinds # # LANGUAGE DeriveDataTypeable # # LANGUAGE DeriveTraversable # # LANGUAGE OverloadedStrings # # LANGUAGE RankNTypes # * Array sizes can only be @*@, @n@ (where n is a positive integer), @x@ * @_Bool@, @_Complex@, and @_Imaginary@ are not present. * Untyped parameter lists (pre-K&R C) ...
# LANGUAGE CPP # # LANGUAGE DeriveFoldable # # LANGUAGE DeriveFunctor # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # # LANGUAGE ScopedTypeVariables # | A parser for C99 declarations . Currently , the parser has the following l...
5220fa59c3deac70d908501ac3cfe49b2003554627ec6ec1bda55ba0b57c8793
input-output-hk/cardano-ledger
Utxow.hs
{-# LANGUAGE ConstraintKinds #-} # LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # # LANGUAGE DerivingStrategies # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE LambdaCase # # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RankNTypes #-} # LANGUAGE ScopedTypeV...
null
https://raw.githubusercontent.com/input-output-hk/cardano-ledger/b9aa1ad1728c0ceeca62657ec94d6d099896c052/eras/shelley/impl/src/Cardano/Ledger/Shelley/Rules/Utxow.hs
haskell
# LANGUAGE ConstraintKinds # # LANGUAGE OverloadedStrings # # LANGUAGE RankNTypes # * Individual validation steps ========================================= witnesses which failed in verifiedWits function witnesses which were needed and not supplied missing scripts failed scripts hash of the full metadata hash o...
# LANGUAGE DataKinds # # LANGUAGE DeriveGeneric # # LANGUAGE DerivingStrategies # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE LambdaCase # # LANGUAGE MultiParamTypeClasses # # LANGUAGE ScopedTypeVariables # # LANGUAGE StandaloneDeriving # # LANGUAGE TypeApplications # # LANGUAGE TypeFamilies...
d87843f6b64c23990fdf77f95a40518e53605610af049fa50cfad899f8220217
naoto-ogawa/h-xproto-mysql
JSON.hs
| module : DataBase . MySQLX.JSON description : JSON copyright : ( c ) , 2017 license : mit maintainer : stability : experimental portability : module : DataBase.MySQLX.JSON description : JSON copyright : (c) naoto ogawa, 2017 license : mit maintainer : stability ...
null
https://raw.githubusercontent.com/naoto-ogawa/h-xproto-mysql/1eacd6486c99b849016bf088788cb8d8b166f964/src/DataBase/MySQLX/JSON.hs
haskell
general, standard library generated library protocol buffer library my library ----------------------------------------------------------------------------- ----------------------------------------------------------------------------- Left (f::Float) -> expr f | JSON Object modification parser. | Insert f...
| module : DataBase . MySQLX.JSON description : JSON copyright : ( c ) , 2017 license : mit maintainer : stability : experimental portability : module : DataBase.MySQLX.JSON description : JSON copyright : (c) naoto ogawa, 2017 license : mit maintainer : stability ...
9b97f656d017e32308a1d34b6d4e93fb5691e7c9e76db3c072785397dbca0389
dnadales/sandbox
TestDSLExceptions.hs
# LANGUAGE FlexibleContexts # # LANGUAGE DeriveFunctor # -- | What if we want to stop the interpreter as soon as an error occurs? module TestDSLExceptions where import Control.Monad.Free import Control.Monad.State.Lazy hiding (put) import Control.Monad.Trans.Either type Elem = String...
null
https://raw.githubusercontent.com/dnadales/sandbox/401c4f0fac5f8044fb6e2e443bacddce6f135b4b/free-monads/src/TestDSLExceptions.hs
haskell
| What if we want to stop the interpreter as soon as an error occurs? | A simple language to put elements into a bag, and count the number of them. Notice that in principle exceptions should not be part of the domain language, since putting an element on a bag should always succeed (we could assume we drop eleme...
# LANGUAGE FlexibleContexts # # LANGUAGE DeriveFunctor # module TestDSLExceptions where import Control.Monad.Free import Control.Monad.State.Lazy hiding (put) import Control.Monad.Trans.Either type Elem = String data TestF r = Put Elem r | Count Elem (Int -> r) deriving Functor t...
d67a6ed0fe41cd8a68ab12d9dd2f98823099e193e2ae4d8cb839720e130bec0e
fourmolu/fourmolu
backticks-lhs-four-out.hs
x `op1` (Just 0) = True op1 x (Just _) = False op1 x Nothing = undefined op2 1 y = False x `op2` y = True
null
https://raw.githubusercontent.com/fourmolu/fourmolu/1f8903a92c8d5001dc1ec8ecfd4a04a3b61c3283/data/examples/declaration/value/function/backticks-lhs-four-out.hs
haskell
x `op1` (Just 0) = True op1 x (Just _) = False op1 x Nothing = undefined op2 1 y = False x `op2` y = True
613ed10308e968c5efe39333da0cafc1cf1dc00d895986c1b5ad004f80120248
aowens-21/racket-formatting
formatting-info-collector.rkt
#lang racket/base (require custom-syntax-format) (provide get-formatting-info) (define (get-formatting-info expanded-stx/exn path the-source orig-cust) (cond [(syntax? expanded-stx/exn) (define loc-info-map (build-loc-info-map expanded-stx/exn)) (vector (syntax-source expande...
null
https://raw.githubusercontent.com/aowens-21/racket-formatting/40cea4b6136b7a329386c73c90cf9f4a4cd0cfdd/custom-syntax-format-plugin/formatting-info-collector.rkt
racket
#lang racket/base (require custom-syntax-format) (provide get-formatting-info) (define (get-formatting-info expanded-stx/exn path the-source orig-cust) (cond [(syntax? expanded-stx/exn) (define loc-info-map (build-loc-info-map expanded-stx/exn)) (vector (syntax-source expande...
e27013b0045359a6236172f3f1126bba3fb4cb328c4d226a3f2c89b1fbfce3dc
monadbobo/ocaml-core
core_sexp.mli
open Interfaces open Sexplib include Sexpable with type t := Sexp.t include Stringable with type t := Sexp.t include Binable with type t := Sexp.t include Sexp_intf.S val of_int_style : [ `Underscores | `No_underscores ] ref (** [no_raise] is the identity, but by using ['a no_raise] in a sexpable type, the resu...
null
https://raw.githubusercontent.com/monadbobo/ocaml-core/9c1c06e7a1af7e15b6019a325d7dbdbd4cdb4020/base/core/lib/core_sexp.mli
ocaml
* [no_raise] is the identity, but by using ['a no_raise] in a sexpable type, the resulting use [sexp_of_no_raise] protects the conversion of ['a] to a sexp so that if it fails, one gets a sexp with an error message about the failure, rather than an exception being raised. The resulting [no_raise_of_sex...
open Interfaces open Sexplib include Sexpable with type t := Sexp.t include Stringable with type t := Sexp.t include Binable with type t := Sexp.t include Sexp_intf.S val of_int_style : [ `Underscores | `No_underscores ] ref type 'a no_raise = 'a with bin_io, sexp Please refer to the documentation in base / sex...
5657e4ede3937c8d067025e7bac89b29007eb29b301ec20616f8ee29df27ca67
compiling-to-categories/concat
OkType.hs
# LANGUAGE CPP # # LANGUAGE UndecidableInstances # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # OPTIONS_GHC -Wall # { - # OPTIONS_GHC -Wno - unused - imports # - } -- TEMP #define TESTING #ifdef TESTING {-# OPTIONS_GHC -Wno-unused-top-binds #-} # OPTIONS_GHC -Wno - missing - signatures # #endif ...
null
https://raw.githubusercontent.com/compiling-to-categories/concat/49e554856576245f583dfd2484e5f7c19f688028/plugin/src/ConCat/OkType.hs
haskell
TEMP # OPTIONS_GHC -Wno-unused-top-binds # | Determine whether the plugin can handle a type. Used in ConCat.Plugin.
# LANGUAGE CPP # # LANGUAGE UndecidableInstances # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # OPTIONS_GHC -Wall # #define TESTING #ifdef TESTING # OPTIONS_GHC -Wno - missing - signatures # #endif module ConCat.OkType (OkType) where import GHC.TypeLits (KnownNat) import Data.Finite (Finite) imp...
9436eb10bafa8baee576e1bf2cb28bf5433bab1ce5cfacc99883878a13ebc8ff
programaker-project/Programaker-Core
automate_rest_api_services_root.erl
%%% @doc %%% REST endpoint to manage knowledge collections. %%% @end -module(automate_rest_api_services_root). -export([init/2]). -export([ allowed_methods/2 , options/2 , is_authorized/2 , content_types_provided/2 , resource_exists/2 ]). -export([ to_json/2 ]). -inclu...
null
https://raw.githubusercontent.com/programaker-project/Programaker-Core/ef10fc6d2a228b2096b121170c421f5c29f9f270/backend/apps/automate_rest_api/src/automate_rest_api_services_root.erl
erlang
@doc REST endpoint to manage knowledge collections. @end CORS Authentication Don't do authentication if it's just asking for options Non matching username GET handler
-module(automate_rest_api_services_root). -export([init/2]). -export([ allowed_methods/2 , options/2 , is_authorized/2 , content_types_provided/2 , resource_exists/2 ]). -export([ to_json/2 ]). -include("./records.hrl"). -record(state, { username :: binary() }). -spe...
564f22c5fa8e90026296e194033d525e50f95d9a1d22038ec482ed19c4b51f8c
OCamlPro/freeton_wallet
commandMultisigTransfer.ml
(**************************************************************************) (* *) Copyright ( c ) 2021 OCamlPro SAS (* *) (* All right...
null
https://raw.githubusercontent.com/OCamlPro/freeton_wallet/b97877379e51d96cb3544141d386d502348cfca9/src/freeton_wallet_lib/commandMultisigTransfer.ml
ocaml
************************************************************************ All rights reserved. This file is distributed u...
Copyright ( c ) 2021 OCamlPro SAS Public License version 2.1 , with the special exception on linking open Ez_file.V1 open Ezcmd.V2 open EZCMD.TYPES open Types let send_transfer ~account ?src ~dst ~amount ?(bounce=false) ?(args=[]) ?(wait=false) ?(send=false) ?subs...
86d7d3541d14fbf2c18b6f774c9d90d4fe10f777c3d1605e2eb61abd7945cf77
hexlet-codebattle/battle_asserts
excel_sheet_column_title.clj
(ns battle-asserts.issues.excel-sheet-column-title (:require [clojure.test.check.generators :as gen])) (def level :easy) (def tags ["excel"]) (def description {:en "Given a positive integer, return its corresponding column title as it appears in an Excel sheet. For example: 1 -> A, 2 -> B, 3 -> C, ..., 2...
null
https://raw.githubusercontent.com/hexlet-codebattle/battle_asserts/9dfe09e2ab64651047e02dc7ec6ef395b0754ce5/src/battle_asserts/issues/excel_sheet_column_title.clj
clojure
(ns battle-asserts.issues.excel-sheet-column-title (:require [clojure.test.check.generators :as gen])) (def level :easy) (def tags ["excel"]) (def description {:en "Given a positive integer, return its corresponding column title as it appears in an Excel sheet. For example: 1 -> A, 2 -> B, 3 -> C, ..., 2...