_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
abfc76b99b86f5f3c6b168afca2f74ad086f30010cbed18c0f927f1387a2d653
michaelklishin/neocons
batch.clj
Copyright ( c ) 2011 - 2015 , , and The ClojureWerkz Team ;; ;; 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 agreei...
null
https://raw.githubusercontent.com/michaelklishin/neocons/30f30e95686a01f7a34082600bc1221877c2acbd/src/clojure/clojurewerkz/neocons/rest/batch.clj
clojure
The use and distribution terms for this software are covered by the 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 this notice, or any other, from this software. A...
Copyright ( c ) 2011 - 2015 , , and The ClojureWerkz Team Eclipse Public License 1.0 ( -1.0.php ) (ns clojurewerkz.neocons.rest.batch "Batch operation execution" (:require [clojurewerkz.neocons.rest :as rest] [clojurewerkz.neocons.rest.records :as rec] [cheshire.core ...
1e8b625f10a7217eecbd6b37300b9f2105afbf40a2e2bd8c766cc45c7c8d9abe
unclebob/AdventOfCode2020
core_spec.clj
(ns day5.core-spec (:require [speclj.core :refer :all] [day5.core :refer :all])) (describe "decode seat id" (it "decodes" (should= 127 (seat-id "BBBBBBB")) (should= 81 (seat-id "BLBLFLR")) (should= 357 (seat-id "FBFBBFFRLR")))) (describe "solutions" (it "solved#1" (should= 922 (solve...
null
https://raw.githubusercontent.com/unclebob/AdventOfCode2020/fc4ba9ad042cbcc48dfa5947373ab46b750d89e5/day5/spec/day5/core_spec.clj
clojure
(ns day5.core-spec (:require [speclj.core :refer :all] [day5.core :refer :all])) (describe "decode seat id" (it "decodes" (should= 127 (seat-id "BBBBBBB")) (should= 81 (seat-id "BLBLFLR")) (should= 357 (seat-id "FBFBBFFRLR")))) (describe "solutions" (it "solved#1" (should= 922 (solve...
429e97b9da7c95184943da90a10f7a84243c25c415fea9ee4cb582f372190539
abdulapopoola/SICPBook
Ex2.01.scm
#lang planet neil/sicp (define (numer x) (car x)) (define (denom x) (cdr x)) XNOR is true when x and y have the same sign (define (xnor x y) (or (and x y) (and (not x) (not y)))) (define (make-rat n d) (let ((abs-n (abs n)) (abs-d (abs d))) (if (xnor (positive? n) (positive?...
null
https://raw.githubusercontent.com/abdulapopoola/SICPBook/c8a0228ebf66d9c1ddc5ef1fcc1d05d8684f090a/Chapter%202/2.1/Ex2.01.scm
scheme
#lang planet neil/sicp (define (numer x) (car x)) (define (denom x) (cdr x)) XNOR is true when x and y have the same sign (define (xnor x y) (or (and x y) (and (not x) (not y)))) (define (make-rat n d) (let ((abs-n (abs n)) (abs-d (abs d))) (if (xnor (positive? n) (positive?...
3c5fe2f6fa62d1425b758b506b88ebbf987c3f5d0ebb7e3e2f036affa9dc5982
Mishio595/disml
disml.ml
* { 2 Dis.ml - An OCaml library for interfacing with the Discord API } { 3 Example } { [ open Async open Core open Disml open Models ( * Create a function to handle message_create . {2 Dis.ml - An OCaml library for interfacing with the Discord API} {3 Example} ...
null
https://raw.githubusercontent.com/Mishio595/disml/cbb1e47a6d358eace03790c07a1b85641f4ca366/lib/disml.ml
ocaml
Create a function to handle message_create. Register the event handler Start the client. It's recommended to load the token from an env var or other config file. * Caching module. {!Cache.cache} is an {{!Async.Mvar.Read_write.t}Mvar}, which is always filled, containing an immutable cache record to allow for safe,...
* { 2 Dis.ml - An OCaml library for interfacing with the Discord API } { 3 Example } { [ open Async open Core open Disml open Models ( * Create a function to handle message_create . {2 Dis.ml - An OCaml library for interfacing with the Discord API} {3 Example} ...
f295a0fb5b5a6e457666922d324181208c8dbd4aa0f078dd5a073dcd52a1b7bc
brevis-us/brevis
cone.clj
(ns us.brevis.shape.cone (:import [us.brevis BrShape]) (:require [brevis-utils.parameters :as parameters]) (:use [us.brevis vector] [us.brevis.shape.core])) (defn create-cone "Create a cone object." ([] (create-cone 1 1)) ([length base] (let [result (BrShape/createCone length base (parameters...
null
https://raw.githubusercontent.com/brevis-us/brevis/de51c173279e82cca6d5990010144167050358a3/src/main/clojure/us/brevis/shape/cone.clj
clojure
(ns us.brevis.shape.cone (:import [us.brevis BrShape]) (:require [brevis-utils.parameters :as parameters]) (:use [us.brevis vector] [us.brevis.shape.core])) (defn create-cone "Create a cone object." ([] (create-cone 1 1)) ([length base] (let [result (BrShape/createCone length base (parameters...
7d5078ac44ab41ccd96ad68e66d92690f18dcc9c927030668340c66e416247df
shenxs/about-scheme
transhcan.rkt
#lang racket (call/cc (lambda (k) (* 5 4))) (call/cc (lambda (k) (* 5 (k 4)))) ;;a list of number --> a number (define (prducrt ls) (call/cc (lambda (break) (let f ([ls ls]) (cond [(empty? ls) 1] [(= (first ls) 0) (break 0)] [else (* (f...
null
https://raw.githubusercontent.com/shenxs/about-scheme/d458776a62cb0bbcbfbb2a044ed18b849f26fd0f/TSPL/transhcan.rkt
racket
a list of number --> a number 好像明白一点什么叫延续了 从列表取出一个任务来执行 (start)
#lang racket (call/cc (lambda (k) (* 5 4))) (call/cc (lambda (k) (* 5 (k 4)))) (define (prducrt ls) (call/cc (lambda (break) (let f ([ls ls]) (cond [(empty? ls) 1] [(= (first ls) 0) (break 0)] [else (* (first ls) (f (rest ls)))]))))) (...
0deb576ee2c94112982c4ea743b5fa7fa9f277092e0d9aab49011899e8529eac
autolwe/autolwe
ParserTools.ml
(* * Useful functions for parsers and error messages *) open Abbrevs (* Use this in your lexer *) exception LexerError of string exception ParserError type parse_error = { pe_char_start : int ; pe_char_end : int ; pe_line_start : int ; pe_line_char_start : int ; pe_line_char_end : int ...
null
https://raw.githubusercontent.com/autolwe/autolwe/3452c3dae06fc8e9815d94133fdeb8f3b8315f32/src/Util/ParserTools.ml
ocaml
* Useful functions for parsers and error messages Use this in your lexer
open Abbrevs exception LexerError of string exception ParserError type parse_error = { pe_char_start : int ; pe_char_end : int ; pe_line_start : int ; pe_line_char_start : int ; pe_line_char_end : int ; pe_line : string ; pe_msg : string } exception ParseErro...
630b3efbdaf9b40d55128f5cdf62bb52861c0291ee18d56cb3fe3e25718e1cb4
1Jajen1/Brokkr
BlockState.hs
# LANGUAGE TemplateHaskell # # LANGUAGE PatternSynonyms # # LANGUAGE ViewPatterns # # LANGUAGE AllowAmbiguousTypes # # LANGUAGE DataKinds # {-# LANGUAGE GADTs #-} # OPTIONS_GHC -Wno - incomplete - patterns -Wno - missing - export - lists -Wno - unused - local - binds # --{-# OPTIONS_GHC -ddump-simpl -dsuppress-all #-} ...
null
https://raw.githubusercontent.com/1Jajen1/Brokkr/1c93519fdc3490091205e8499ed04cd1fee66192/data/src/Block/Internal/BlockState.hs
haskell
# LANGUAGE GADTs # {-# OPTIONS_GHC -ddump-simpl -dsuppress-all #-} TODO Generate better show instance Aux types TODO Autogen some of these. Especially the boolean equivalents Or at least autogent the instances, that should not be hard! We do no bounds checking here as these values always come from the pattern synon...
# LANGUAGE TemplateHaskell # # LANGUAGE PatternSynonyms # # LANGUAGE ViewPatterns # # LANGUAGE AllowAmbiguousTypes # # LANGUAGE DataKinds # # OPTIONS_GHC -Wno - incomplete - patterns -Wno - missing - export - lists -Wno - unused - local - binds # module Block.Internal.BlockState where import Block.Internal.TH import D...
42e6017c3887b368bac757330c32d36d66a29e58a098df0fc965ea6f4eba106c
gfngfn/SATySFi
imageInfo.mli
open MyUtil open LengthInterface type bbox = float * float * float * float type key val initialize : unit -> unit val add_pdf : abs_path -> int -> key val add_image : abs_path -> key val get_height_from_width : key -> length -> length val get_ratio : key -> length -> length -> float * float val get_xobject_dic...
null
https://raw.githubusercontent.com/gfngfn/SATySFi/9dbd61df0ab05943b3394830c371e927df45251a/src/backend/imageInfo.mli
ocaml
open MyUtil open LengthInterface type bbox = float * float * float * float type key val initialize : unit -> unit val add_pdf : abs_path -> int -> key val add_image : abs_path -> key val get_height_from_width : key -> length -> length val get_ratio : key -> length -> length -> float * float val get_xobject_dic...
369768195670dc9a3c3ae20a9a19dc1692a7d953517169477f39687cc44d6130
ocaml/opam-file-format
legacy.ml
(* This "program" is used to verify that the library is linkable - see #40 *) let file = OpamParser.FullPos.file "../opam-file-format.opam" in Printf.printf "Successfully loaded %s\n" file.OpamParserTypes.FullPos.file_name
null
https://raw.githubusercontent.com/ocaml/opam-file-format/d99af5e8f3b917770b3c8d29f55d865fcab3b899/tests/legacy/legacy.ml
ocaml
This "program" is used to verify that the library is linkable - see #40
let file = OpamParser.FullPos.file "../opam-file-format.opam" in Printf.printf "Successfully loaded %s\n" file.OpamParserTypes.FullPos.file_name
a52554cf82bf58cd7b28e49ebd4e3de240074579c06243abb6228645a40d3c54
project-fifo/vmwebadm
core.cljs
(ns server.core (:use-macros [clojure.core.match.js :only [match]]) (:use [server.utils :only [clj->js prn-js prn]]) (:require [server.routes :as routes] [server.http :as http] [clojure.string :as c.s] [cljs.nodejs :as node] [server.storage :as storage])) (def http...
null
https://raw.githubusercontent.com/project-fifo/vmwebadm/55d83bbc0ac6db8ea1d784c73d91bf4f228fa04a/src/server/core.cljs
clojure
(ns server.core (:use-macros [clojure.core.match.js :only [match]]) (:use [server.utils :only [clj->js prn-js prn]]) (:require [server.routes :as routes] [server.http :as http] [clojure.string :as c.s] [cljs.nodejs :as node] [server.storage :as storage])) (def http...
21e7e90208feefe2a9e6b3a717505a4221d8a9637dffb87bfef3cd21077a2d80
lmdexpr/ocaml_jvm
attribute_info.ml
open Ubytes.Reader type t_exception = { start_pc : U16.t ; end_pc : U16.t ; handler_pc : U16.t ; catch_type : U16.t } type t_line_number = { start_pc : U16.t ; line_number : U16.t } type t_code = { max_stack : int ; max_locals : int ; code : int array ; exception_table : t_exception array }...
null
https://raw.githubusercontent.com/lmdexpr/ocaml_jvm/549271581f6fd894059cb0769757099bee0bfa97/src/classfile/attribute_info.ml
ocaml
open Ubytes.Reader type t_exception = { start_pc : U16.t ; end_pc : U16.t ; handler_pc : U16.t ; catch_type : U16.t } type t_line_number = { start_pc : U16.t ; line_number : U16.t } type t_code = { max_stack : int ; max_locals : int ; code : int array ; exception_table : t_exception array }...
71be11176de0dd669f83349953b1a02d03e2fd51821cdae80eefbe082d484282
freizl/dive-into-haskell
tutorial1.hs
Informatics 1 - Functional Programming -- Tutorial 1 -- Due : the tutorial of week 3 ( 4/5 Oct. ) import Data.Char import Data.List import Test.QuickCheck 1 . -- List-comprehension version halveEvens :: [Int] -> [Int] halveEvens xs = [ x `div` 2 | x <- xs, isEven x] isEven :: Int -> Bool isEven x = x `mod`...
null
https://raw.githubusercontent.com/freizl/dive-into-haskell/b18a6bfe212db6c3a5d707b4a640170b8bcf9330/lectures/informatics1-FP/2011-haisheng/tutorial1/tutorial1.hs
haskell
Tutorial 1 List-comprehension version Recursive version Mutual test List-comprehension version NOTES: `&&` is not necessary here. [x | x <- xs, lo <= x, x <= hi] Recursive version Mutual test List-comprehension version Recursive version NOTES: inner function is not necessary. Mutual test Helper function ...
Informatics 1 - Functional Programming Due : the tutorial of week 3 ( 4/5 Oct. ) import Data.Char import Data.List import Test.QuickCheck 1 . halveEvens :: [Int] -> [Int] halveEvens xs = [ x `div` 2 | x <- xs, isEven x] isEven :: Int -> Bool isEven x = x `mod` 2 == 0 halveEvensRec :: [Int] -> [Int] halveE...
43d4c10af89c4feec09729c21be46500fb28367a5764e2607aba1e666ea5af1f
sellout/haskerwaul
Under.hs
module Haskerwaul.Category.Under ( module Haskerwaul.Category.Under -- * extended modules , module Haskerwaul.Category.Over ) where import Haskerwaul.Category.Over import Haskerwaul.Category.Opposite | In our representation of an under ( or coslice ) category _ _ x / c _ _ , the -- objects are /represente...
null
https://raw.githubusercontent.com/sellout/haskerwaul/cf54bd7ce5bf4f3d1fd0d9d991dc733785b66a73/src/Haskerwaul/Category/Under.hs
haskell
* extended modules objects are /represented by/ the objects of the underlying category, but the terms are still all morphisms. = references - [nLab](+category) - [Wikipedia](#Coslice_category)
module Haskerwaul.Category.Under ( module Haskerwaul.Category.Under , module Haskerwaul.Category.Over ) where import Haskerwaul.Category.Over import Haskerwaul.Category.Opposite | In our representation of an under ( or coslice ) category _ _ x / c _ _ , the type Under c = Over (Op c)
541c605d552e4149278db6f39596127a4aa5aa1eaf75865d80184363b41d03f6
dwayne/eopl3
interpreter.rkt
#lang eopl (require "./env.rkt") (require "./parser.rkt") (provide ;; Expressed Values num-val bool-val list-val ;; Interpreter run) (define (run s) (let ([init-env (extend-env 'i (num-val 1) (extend-env 'v (num-val 5) (extend-env ...
null
https://raw.githubusercontent.com/dwayne/eopl3/9d5fdb2a8dafac3bc48852d49cda8b83e7a825cf/solutions/05-ch5/interpreters/racket/CONTINUATION-PASSING-5.7/interpreter.rkt
racket
Expressed Values Interpreter Continuations It uses a procedural representation. (bool-val #t) (bool-val #f))) This can be simplified to: Cont x ExpVal -> FinalAnswer Procedure ADT Values ExpVal = Int + Bool + Proc + List[EvalVal]
#lang eopl (require "./env.rkt") (require "./parser.rkt") (provide num-val bool-val list-val run) (define (run s) (let ([init-env (extend-env 'i (num-val 1) (extend-env 'v (num-val 5) (extend-env 'x (num-val 10) ...
4f476ab2cad0dbafa4aa3cc14b9384e5f9ad0196c44fb2ec4f62224e80b48510
helium/packet-purchaser
pp_udp_worker.erl
-module(pp_udp_worker). -behavior(gen_server). -include("packet_purchaser.hrl"). -include("semtech_udp.hrl"). %% ------------------------------------------------------------------ %% API Function Exports %% ------------------------------------------------------------------ -export([ start_link/1, push_data/4...
null
https://raw.githubusercontent.com/helium/packet-purchaser/51fd632e19953beaba7a01bcbe3748a399fb3161/src/pp_udp_worker.erl
erlang
------------------------------------------------------------------ API Function Exports ------------------------------------------------------------------ ------------------------------------------------------------------ ------------------------------------------------------------------ -------------------------...
-module(pp_udp_worker). -behavior(gen_server). -include("packet_purchaser.hrl"). -include("semtech_udp.hrl"). -export([ start_link/1, push_data/4, push_data/5, update_address/2 ]). gen_server Function Exports -export([ init/1, handle_call/3, handle_cast/2, handle_info/2, termin...
0c51415ddf52fbfde0861c7bb77de96281e1fb23feee3faefc06ebef403e77f7
xxyzz/SICP
Exercise_2_12.rkt
#lang racket/base (define (make-interval a b) (cons a b)) (define (upper-bound interval) (max (car interval) (cdr interval))) (define (lower-bound interval) (min (car interval) (cdr interval))) (define (make-center-percent c p) (let ([tolerance (* c (/ p 100))]) (make-interval (- c tolerance) (+...
null
https://raw.githubusercontent.com/xxyzz/SICP/e26aea1c58fd896297dbf5406f7fcd32bb4f8f78/2_Building_Abstractions_with_Data/2.1_Introduction_to_Data_Abstraction/Exercise_2_12.rkt
racket
#lang racket/base (define (make-interval a b) (cons a b)) (define (upper-bound interval) (max (car interval) (cdr interval))) (define (lower-bound interval) (min (car interval) (cdr interval))) (define (make-center-percent c p) (let ([tolerance (* c (/ p 100))]) (make-interval (- c tolerance) (+...
4311d37059a32dc5417aa9c336a3fd2fb571dcd595a9b9c877853ee14c9ee4f2
MaskRay/99-problems-ocaml
66.ml
type 'a tree = Leaf | Branch of 'a * 'a tree * 'a tree let rec pad x y = match x, y with | [], y | y, [] -> y | x::xs, y::ys -> x :: pad xs ys let rec maximum = function | [x] -> x | h::t -> max h (maximum t) let rec max_sum = function | [], _ | _, [] -> 0 | a::b, c::d -> max (a+c) (max_sum (b, d)) let ...
null
https://raw.githubusercontent.com/MaskRay/99-problems-ocaml/652604f13ba7a73eee06d359b4db549b49ec9bb3/61-70/66.ml
ocaml
type 'a tree = Leaf | Branch of 'a * 'a tree * 'a tree let rec pad x y = match x, y with | [], y | y, [] -> y | x::xs, y::ys -> x :: pad xs ys let rec maximum = function | [x] -> x | h::t -> max h (maximum t) let rec max_sum = function | [], _ | _, [] -> 0 | a::b, c::d -> max (a+c) (max_sum (b, d)) let ...
72e4694052463813f096ce815e4313cb3436142b304ed661a380288a663447af
uw-unsat/leanette-popl22-artifact
synthesis.rkt
#lang rosette (require racket/require (multi-in "../../frameworks/alglave" ("models.rkt" "framework.rkt")) "../../litmus/litmus.rkt" (only-in "../../ocelot/ocelot.rkt" ast->datum simplify) (only-in "../../memsynth/synth.rkt" synth-tests-used)) (provide run-synthesis-experiment) ;; ...
null
https://raw.githubusercontent.com/uw-unsat/leanette-popl22-artifact/80fea2519e61b45a283fbf7903acdf6d5528dbe7/rosette-benchmarks-3/memsynth/case-studies/synthesis/synthesis.rkt
racket
Takes as input the name of a reference memory model (used for litmus-test-allowed?), a list of litmus tests, and a memory model sketch. synth takes as input a list of (test, outcome) pairs Run the synthesis engine Verify the solution
#lang rosette (require racket/require (multi-in "../../frameworks/alglave" ("models.rkt" "framework.rkt")) "../../litmus/litmus.rkt" (only-in "../../ocelot/ocelot.rkt" ast->datum simplify) (only-in "../../memsynth/synth.rkt" synth-tests-used)) (provide run-synthesis-experiment) R...
6809ae29e8fe8ce211115fed80d06cad239b28ecd73b357fcc179ccb35500499
oisdk/monus-weighted-search
SubsetSum.hs
-- | Module : MonusWeightedSearch . Examples . SubsetSum Copyright : ( c ) Kidney 2021 -- Maintainer : -- Stability : experimental -- Portability : non-portable -- An implementation of shortest subset sum ( the Inclusion - Exclusion method ) -- using the 'Heap' monad. module MonusWeightedSearch.Ex...
null
https://raw.githubusercontent.com/oisdk/monus-weighted-search/f2f3fdeb6ddcc555477df6d23d3ef0031017ca86/src/MonusWeightedSearch/Examples/SubsetSum.hs
haskell
| Maintainer : Stability : experimental Portability : non-portable using the 'Heap' monad. | A weight for the inclusion or exclusion of an element. This lets us weight the computation by number of elements included, and therefore optimise for the fewest. [-4,3,6]
Module : MonusWeightedSearch . Examples . SubsetSum Copyright : ( c ) Kidney 2021 An implementation of shortest subset sum ( the Inclusion - Exclusion method ) module MonusWeightedSearch.Examples.SubsetSum where import Control.Monad.Heap import Data.Monus.Dist import Control.Monad.Writer import Data....
438e823151036683045bb02a3e9127603c02709d56343626d03383dc6b60e116
chaoxu/fancy-walks
119.hs
{-# OPTIONS_GHC -O2 #-} import Data.List import Data . Int minusOrd :: Ord a => [a] -> [a] -> [a] minusOrd a@(x:xs) b@(y:ys) = case compare x y of EQ -> minusOrd xs ys LT -> x : minusOrd xs b GT -> minusOrd a ys minusOrd xs _ = xs unionOrd :: Ord a => [a] -> [a] -> [a] unionOrd a@(x:xs) b@(y:ys) = case c...
null
https://raw.githubusercontent.com/chaoxu/fancy-walks/952fcc345883181144131f839aa61e36f488998d/projecteuler.net/119.hs
haskell
# OPTIONS_GHC -O2 #
import Data.List import Data . Int minusOrd :: Ord a => [a] -> [a] -> [a] minusOrd a@(x:xs) b@(y:ys) = case compare x y of EQ -> minusOrd xs ys LT -> x : minusOrd xs b GT -> minusOrd a ys minusOrd xs _ = xs unionOrd :: Ord a => [a] -> [a] -> [a] unionOrd a@(x:xs) b@(y:ys) = case compare x y of EQ -> ...
c86767a35bd56d8a3a37c186b928fad8b8c8423840bd2248f39fbfedcf912a4b
ds-wizard/engine-backend
ServerConfigJM.hs
module Registry.Model.Config.ServerConfigJM where import Control.Monad import Data.Aeson import Registry.Model.Config.ServerConfig import Registry.Model.Config.ServerConfigDM import Shared.Model.Config.EnvironmentJM () import Shared.Model.Config.ServerConfigDM import Shared.Model.Config.ServerConfigJM () instance Fr...
null
https://raw.githubusercontent.com/ds-wizard/engine-backend/12717256cde8d20020e30cd55dc3ef00fef9362a/engine-registry/src/Registry/Model/Config/ServerConfigJM.hs
haskell
module Registry.Model.Config.ServerConfigJM where import Control.Monad import Data.Aeson import Registry.Model.Config.ServerConfig import Registry.Model.Config.ServerConfigDM import Shared.Model.Config.EnvironmentJM () import Shared.Model.Config.ServerConfigDM import Shared.Model.Config.ServerConfigJM () instance Fr...
a5ae7a45ab9f80d65ff60efbfc20ae77104af86387d8929b12273d97d52ca217
Toeplitz/haskell
Well.hs
Parsing checkshot data exported from Petrel -- -- module Well where import Text.ParserCombinators.Parsec data Well = Well { wellX :: Float , wellY :: Float , wellZ :: Float , wellTWT :: Float , wellMD :: Float , wellNam...
null
https://raw.githubusercontent.com/Toeplitz/haskell/b686aff73033db5f77b7bc2ddc7478a4311f69d9/Well.hs
haskell
wellParse :: String -> IO () wellParse input = case parse wellLine "(test)" input of Left err -> [] Right res -> res
Parsing checkshot data exported from Petrel module Well where import Text.ParserCombinators.Parsec data Well = Well { wellX :: Float , wellY :: Float , wellZ :: Float , wellTWT :: Float , wellMD :: Float , wellName :: S...
ab0f5ff698c9502feca854e2ebbc312ce291d8cba036c83ded6e1701cbd4e523
ntestoc3/burp-clj
helper_test.clj
(ns burp-clj.helper-test (:require [burp-clj.helper :refer :all] [clojure.test :refer :all])) (deftest http-req-resp-test (testing "get-full-host" (is (= "" (get-full-host {:host "bing.com" :port 80 :protocol "http"}))) (is (= "...
null
https://raw.githubusercontent.com/ntestoc3/burp-clj/436802d34fb77e183cf513ba767e3310d96f6946/test/burp_clj/helper_test.clj
clojure
(ns burp-clj.helper-test (:require [burp-clj.helper :refer :all] [clojure.test :refer :all])) (deftest http-req-resp-test (testing "get-full-host" (is (= "" (get-full-host {:host "bing.com" :port 80 :protocol "http"}))) (is (= "...
3af8d14ecb2b6574ffd66ee349925e5ca5ce8995a80b434e5bfc4e81e999928e
DaMSL/K3
Operator.hs
# LANGUAGE ScopedTypeVariables # {-# LANGUAGE NoMonoLocalBinds #-} module Language.K3.Parser.Operator where import Control.Applicative import Text.Parser.Combinators import Text.Parser.Expression hiding ( buildExpressionParser ) import Language.K3.Core.Annotation import Language.K3.Core.Expression import qualified L...
null
https://raw.githubusercontent.com/DaMSL/K3/51749157844e76ae79dba619116fc5ad9d685643/src/Language/K3/Parser/Operator.hs
haskell
# LANGUAGE NoMonoLocalBinds # This applies a bugfix for detecting ambiguous operators. ambiguous :: Parsing m => forall c d. String -> m c -> m d ambiguousRight :: forall a. m a ambiguousLeft :: forall a. m a ambiguousNon :: forall a. m a
# LANGUAGE ScopedTypeVariables # module Language.K3.Parser.Operator where import Control.Applicative import Text.Parser.Combinators import Text.Parser.Expression hiding ( buildExpressionParser ) import Language.K3.Core.Annotation import Language.K3.Core.Expression import qualified Language.K3.Core.Constructor.Expres...
3c80e203d61c9cca180d4bbe892294a2a9435c5f8ff2107167880e0d1d2dac98
Mbodin/murder-generator
attribute.mli
(** odule Attribute Describes the player and contact attributes used thorough this development. *) (** A signature for the various attribute/constructor structures. This signature is used in particular for the player attributes and the contact attributes. *) module type Attribute = sig (** The type of a...
null
https://raw.githubusercontent.com/Mbodin/murder-generator/2024a924ffb4ee12d1b7119b699346b21e098892/src/attribute.mli
ocaml
* odule Attribute Describes the player and contact attributes used thorough this development. * A signature for the various attribute/constructor structures. This signature is used in particular for the player attributes and the contact attributes. * The type of attributes. * The type of constructors. * V...
module type Attribute = sig type attribute type constructor type constructor_map val empty_constructor_map : constructor_map val attribute_name : constructor_map -> attribute -> string option val constructor_name : constructor_map -> constructor -> string option val constructor_attri...
bebaa932d1c05a89ac797ee0e9a3ae6d453584000c97d42a21f5f65d157d7741
jacquev6/DrawGrammar
Lex.ml
open General.Abbr let unescape s = @todo Use General . String.replace_all when it 's implemented s |> Str.split ~sep:"\\ " |> StrLi.join ~sep:" " |> Str.split ~sep:"\\-" |> StrLi.join ~sep:"-"
null
https://raw.githubusercontent.com/jacquev6/DrawGrammar/ee056a086ca0d8b18889fa06883287fda84807c3/src/Lex.ml
ocaml
open General.Abbr let unescape s = @todo Use General . String.replace_all when it 's implemented s |> Str.split ~sep:"\\ " |> StrLi.join ~sep:" " |> Str.split ~sep:"\\-" |> StrLi.join ~sep:"-"
eb640c092b351240611daefa505036c71c66b0e3a6f1608357b5be93699d02b8
leonoel/missionary
sem_test.cljc
(ns missionary.sem-test (:require [lolcat.core :as lc] [lolcat.lib :as l] [missionary.core :as m] [clojure.test :as t]) (:import [missionary Cancelled])) (lc/defword release [id & events] [(l/dup) (l/change get id) (apply lc/call 0 events) (l/lose)]) (lc/defword acquire [id lock...
null
https://raw.githubusercontent.com/leonoel/missionary/848903be20d8c301462c2f5d9d4ef29b2d50b158/test/missionary/sem_test.cljc
clojure
(ns missionary.sem-test (:require [lolcat.core :as lc] [lolcat.lib :as l] [missionary.core :as m] [clojure.test :as t]) (:import [missionary Cancelled])) (lc/defword release [id & events] [(l/dup) (l/change get id) (apply lc/call 0 events) (l/lose)]) (lc/defword acquire [id lock...
1a2c4cf26fa66c20b8a565cb2aef29b41337680b52ed7bb88a8307f4683fbbfb
locusmath/locus
object.clj
(ns locus.order.join-semilattice.element.object (:require [locus.set.logic.core.set :refer :all] [locus.set.logic.limit.product :refer :all] [locus.con.core.setpart :refer :all] [locus.set.mapping.general.core.object :refer :all] [locus.set.logic.structure.protocols :re...
null
https://raw.githubusercontent.com/locusmath/locus/fb6068bd78977b51fd3c5783545a5f9986e4235c/src/clojure/locus/order/join_semilattice/element/object.clj
clojure
An object of a thin category having all binary coproducts Coproducts of objects in join semilattices Ontology of join semilattice elements
(ns locus.order.join-semilattice.element.object (:require [locus.set.logic.core.set :refer :all] [locus.set.logic.limit.product :refer :all] [locus.con.core.setpart :refer :all] [locus.set.mapping.general.core.object :refer :all] [locus.set.logic.structure.protocols :re...
4ec0bfb003f4c2a2559a4f199a85c0018593af31083dfa2e6d89fbb1c9787b1c
adamschoenemann/clofrp
Type.hs
# LANGUAGE DeriveFunctor # # LANGUAGE NamedFieldPuns # # LANGUAGE LambdaCase # {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE TypeSynonymInstances #-} # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE GADTs #-} # LANGUAGE ViewPatterns # # LANGUAGE Dupl...
null
https://raw.githubusercontent.com/adamschoenemann/clofrp/c26f86aec2cdb8fa7fd317acd13f7d77af984bd3/library/CloFRP/AST/Type.hs
haskell
# LANGUAGE OverloadedStrings # # LANGUAGE TypeSynonymInstances # # LANGUAGE DeriveDataTypeable # # LANGUAGE GADTs # # LANGUAGE RankNTypes # # LANGUAGE DeriveAnyClass # x α^ A -> B ∀(α : χ). A Fix F ⟨A₁,...,Aₙ⟩ ⊳k A deriving instance Show a => Show (Type' a s) alphaEquiv :: Type a s -> Type b s -> Bool alphaEq...
# LANGUAGE DeriveFunctor # # LANGUAGE NamedFieldPuns # # LANGUAGE LambdaCase # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE ViewPatterns # # LANGUAGE DuplicateRecordFields # # LANGUAGE DataKinds # # LANGUAGE KindSignatures # # LANGUAGE ExistentialQuantification # # LANGUAGE AllowAmbigu...
f2d4816be620356a0217adcb53424eaa6fe57b36113591ee0ae99311dd73cbae
replikativ/datahike
integration_test.cljc
(ns ^:no-doc datahike.integration-test "This namespace is the minimum test a Datahike backend needs to pass for compatibility assessment." (:require [datahike.api :as d] #?(:clj [clojure.test :refer :all] :cljs [cljs.test :refer :all :include-macros true]))) (defn integration-test-fixtur...
null
https://raw.githubusercontent.com/replikativ/datahike/7566d7c66b29f825e0f7b0dd6669f8faca6a0c39/src/datahike/integration_test.cljc
clojure
lets add some data and wait for the transaction search the data add new entity data using a hash map if you want to work with queries like in you may use a hashmap query the history of the data database should exist clean up the database if it is not needed any more database should not exist
(ns ^:no-doc datahike.integration-test "This namespace is the minimum test a Datahike backend needs to pass for compatibility assessment." (:require [datahike.api :as d] #?(:clj [clojure.test :refer :all] :cljs [cljs.test :refer :all :include-macros true]))) (defn integration-test-fixtur...
0684e5a05f2ba26a0aad6ef81441a51f177267914ffca45510cf78adf83d9efc
rcook/aws-via-haskell
LambdaImports.hs
module LambdaImports ( _ResourceConflictException , _ResourceNotFoundException , FunctionCode , Runtime(..) , createFunction , deleteFunction , fcFunctionName , fcZipFile , functionCode , invoke , irsPayload , lambda , listFunctions , lfrsFunctions ) where im...
null
https://raw.githubusercontent.com/rcook/aws-via-haskell/3ca6167307abb0628cfe4c9ca4545657b0f41494/lambda/LambdaImports.hs
haskell
module LambdaImports ( _ResourceConflictException , _ResourceNotFoundException , FunctionCode , Runtime(..) , createFunction , deleteFunction , fcFunctionName , fcZipFile , functionCode , invoke , irsPayload , lambda , listFunctions , lfrsFunctions ) where im...
fd86363c847007497b099e404b4056e73d5aa41329e8b90a576aac5a3bbbebb3
err0r500/realworld-app-simple-haskell
User.hs
module Adapter.Storage.InMem.User where import qualified Data.Has as DH import qualified Data.UUID as UUID import qualified Domain.User as D import RIO import qualified RIO.Map as Map import qualified Usecase.Interactor as UC type InMemory r m = (DH.Has (TVar Store) r, MonadReader r m, MonadIO m) data User = User ...
null
https://raw.githubusercontent.com/err0r500/realworld-app-simple-haskell/20ec982256ec890f0c77b572eccef987cd3799bf/src/Adapter/Storage/InMem/User.hs
haskell
module Adapter.Storage.InMem.User where import qualified Data.Has as DH import qualified Data.UUID as UUID import qualified Domain.User as D import RIO import qualified RIO.Map as Map import qualified Usecase.Interactor as UC type InMemory r m = (DH.Has (TVar Store) r, MonadReader r m, MonadIO m) data User = User ...
098c31babd615807386f5425906d82c4922127823ffca76bc60e189d1d855674
spawngrid/htoad
blocktrans_extractor.erl
-module(blocktrans_extractor). -export([extract/1]). extract(Path) when is_list(Path) -> {ok, Contents} = file:read_file(Path), extract(Contents); extract(Contents) when is_binary(Contents) -> case erlydtl_compiler:parse(Contents) of {ok, ParseTree} -> Blocks = process_tree(ParseTree)...
null
https://raw.githubusercontent.com/spawngrid/htoad/f0c7dfbd911b29fb0c406b7c26606f553af11194/deps/erlydtl/src/i18n/blocktrans_extractor.erl
erlang
<-- where all the action happens
-module(blocktrans_extractor). -export([extract/1]). extract(Path) when is_list(Path) -> {ok, Contents} = file:read_file(Path), extract(Contents); extract(Contents) when is_binary(Contents) -> case erlydtl_compiler:parse(Contents) of {ok, ParseTree} -> Blocks = process_tree(ParseTree)...
288580eec4691ba468c1246f5fbdb83c363ba7063b26a0a1922d2dd84c43ca57
rafaeldelboni/graphmosphere
percent_encode.clj
(ns graphmosphere.percent-encode (:require [clojure.string :as string])) (set! *warn-on-reflection* true) (def ^:private reserved-characters-regex #"[ !#$%&'()*+,/:;=?@\[\]]") (defn ^:private char->percent-encode "Percent-encoding a reserved character involves converting the character to its corresponding byte...
null
https://raw.githubusercontent.com/rafaeldelboni/graphmosphere/764904ee60674c5d5cbc83cb26d70c0bc5579385/src/graphmosphere/percent_encode.clj
clojure
(ns graphmosphere.percent-encode (:require [clojure.string :as string])) (set! *warn-on-reflection* true) (def ^:private reserved-characters-regex #"[ !#$%&'()*+,/:;=?@\[\]]") (defn ^:private char->percent-encode "Percent-encoding a reserved character involves converting the character to its corresponding byte...
36f87870ca9a5135e2b9b23dfee060b92d015a7807b8dec9fdbfb668a3fb4282
jordanthayer/ocaml-search
tpl_aseps_algs.ml
open Tpl_search_reg (******** A*-epsilon ****) let aseps wt d p l = let root, expand, goal_p, hd_close = Tpl_regression.init_aseps d p in Aseps.a_star_eps ~limit:l root goal_p expand hd_close wt let aseps_old wt d p l = let root, expand, goal_p, hd_close = Tpl_regression.init_aseps d p in Aseps.a_...
null
https://raw.githubusercontent.com/jordanthayer/ocaml-search/57cfc85417aa97ee5d8fbcdb84c333aae148175f/tplan/tpl_aseps_algs.ml
ocaml
******* A*-epsilon *** * f^ then f
open Tpl_search_reg let aseps wt d p l = let root, expand, goal_p, hd_close = Tpl_regression.init_aseps d p in Aseps.a_star_eps ~limit:l root goal_p expand hd_close wt let aseps_old wt d p l = let root, expand, goal_p, hd_close = Tpl_regression.init_aseps d p in Aseps.a_star_eps_old ~limit:l root ...
b2a6c8bf8f70e62b146504ba64e05d94c1211ce231ce3561fa4ad73e7b939c0b
amnh/PCG
TRead.hs
---------------------------------------------------------------------------- -- | Module : File . Format . TNT.Command . Copyright : ( c ) 2015 - 2021 Ward Wheeler -- License : BSD-style -- -- Maintainer : -- Stability : provisional -- Portability : portable -- Parser for the TREAD comma...
null
https://raw.githubusercontent.com/amnh/PCG/9341efe0ec2053302c22b4466157d0a24ed18154/lib/file-parsers/src/File/Format/TNT/Command/TRead.hs
haskell
-------------------------------------------------------------------------- | License : BSD-style Maintainer : Stability : provisional Portability : portable No validation currently takes place. --------------------------------------------------------------------------- | Parses an TREAD command. C...
Module : File . Format . TNT.Command . Copyright : ( c ) 2015 - 2021 Ward Wheeler Parser for the TREAD command specifying how to read a forests of trees . # LANGUAGE FlexibleContexts # # LANGUAGE TypeFamilies # module File.Format.TNT.Command.TRead ( treadCommand , treadHeader , treadLea...
44947fe5ac8d74be3765b3aa337f23bccab55e305d5f285044acb68eb18a0995
joelmccracken/reddup
Trackable.hs
{-# LANGUAGE OverloadedStrings #-} module Trackable where import Prelude hiding (FilePath, concat) import qualified Turtle as Tu import qualified ShellUtil import qualified Config as C import qualified Handler as H import qualified Handler.Git as HG import qualified Reddup as R import Trackable.Data import Trackable...
null
https://raw.githubusercontent.com/joelmccracken/reddup/1bce9371d79c410b30b91c10bf040777260777ad/src/Trackable.hs
haskell
# LANGUAGE OverloadedStrings #
module Trackable where import Prelude hiding (FilePath, concat) import qualified Turtle as Tu import qualified ShellUtil import qualified Config as C import qualified Handler as H import qualified Handler.Git as HG import qualified Reddup as R import Trackable.Data import Trackable.Util import Control.Monad.Reader ...
d79de3450efe58b6ee2c7bb231ef0996a1bbdc84d47b7d82a6e8dd22d4a05388
elizabethsiegle/reddit-slack-bot
APIKey.hs
# LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # {-#LANGUAGE OverloadedStrings #-} # LANGUAGE ViewPatterns # module Twilio.APIKey ( -- * Resource APIKey(..) , APIKeySID , Twilio.APIKey.get ) where import Control.Applicative import Control.Monad import Control.Monad.Catch import Data.Aeson...
null
https://raw.githubusercontent.com/elizabethsiegle/reddit-slack-bot/a52ab60dcaae8e16bee8cdba22fce627157a42d8/twilio-haskell-move-to-stack/src/Twilio/APIKey.hs
haskell
#LANGUAGE OverloadedStrings # * Resource
# LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE ViewPatterns # module Twilio.APIKey APIKey(..) , APIKeySID , Twilio.APIKey.get ) where import Control.Applicative import Control.Monad import Control.Monad.Catch import Data.Aeson import Data.Monoid import Data.Text (Text) import D...
571ae6f1b22f7727acde058a77ceccf5ffa600bfd75d29a393b84f52ba6be7c9
CIFASIS/QuickFuzz
Regex.hs
# LANGUAGE FlexibleInstances # # LANGUAGE IncoherentInstances # # LANGUAGE TemplateHaskell # module Test.QuickFuzz.Gen.Base.Regex where import Control.DeepSeq import Data.Default import Data.Char (chr) import Data.List (intersperse, partition, subsequences) import Data.Set (Set) import qualified Data.Set as S...
null
https://raw.githubusercontent.com/CIFASIS/QuickFuzz/a1c69f028b0960c002cb83e8145f039ecc0e0a23/src/Test/QuickFuzz/Gen/Base/Regex.hs
haskell
| PGroup' PatternIndex (Maybe PatternIndex) Pattern -- used in longest match non-greedy wrapper (for ?+*{} followed by ?) | PPossessive indicates the pattern can only find the longest match possessive modifier (for ?+*{} followed by +) Any character (newline?) at all Square bracketed things Inverted ...
# LANGUAGE FlexibleInstances # # LANGUAGE IncoherentInstances # # LANGUAGE TemplateHaskell # module Test.QuickFuzz.Gen.Base.Regex where import Control.DeepSeq import Data.Default import Data.Char (chr) import Data.List (intersperse, partition, subsequences) import Data.Set (Set) import qualified Data.Set as S...
4aba719f43a0cbc8bc48e9313705e9eb33c97324aa0fc8e656d13fe9e3e19c3a
danielecapo/sfont
type1.rkt
#lang racket (require "writepfa.rkt" "ufopfa.rkt") (provide (all-from-out "writepfa.rkt") (all-from-out "ufopfa.rkt"))
null
https://raw.githubusercontent.com/danielecapo/sfont/c854f9734f15f4c7cd4b98e041b8c961faa3eef2/sfont/export/type1.rkt
racket
#lang racket (require "writepfa.rkt" "ufopfa.rkt") (provide (all-from-out "writepfa.rkt") (all-from-out "ufopfa.rkt"))
600cba90ce0f7d426dfea86b37c22d0ec9117c4530ed7316621425c60c3b3c25
iu-parfunc/lvars
UtilInternal.hs
| A module with helper functions that are used elsewhere in the LVish repository . module Data.UtilInternal ( traverseWithKey_, Traverse_(..) ) where import Control.Applicative (Const(..), Applicative, pure, (*>)) import Control.Monad (void) import ...
null
https://raw.githubusercontent.com/iu-parfunc/lvars/78e73c96a929aa75aa4f991d42b2f677849e433a/src/lvish/Data/UtilInternal.hs
haskell
------------------------------------------------------------------------------ Helper code. ------------------------------------------------------------------------------ Avoids O(N) allocation when traversing for side-effect. Since the Applicative used is Const (newtype Const m a = Const m), the structure is never...
| A module with helper functions that are used elsewhere in the LVish repository . module Data.UtilInternal ( traverseWithKey_, Traverse_(..) ) where import Control.Applicative (Const(..), Applicative, pure, (*>)) import Control.Monad (void) import ...
2b8e9f0a9cab1b9878f8f6612dafe8223fd8800d1495059844af411ddebfd00a
andreasabel/helf
LocallyNamelessSyntax.hs
# LANGUAGE DeriveFunctor # -- stuff taken from HerBruijnVal module LocallyNamelessSyntax (BTm(..), DBIndex(..), Annotation(..), toLocallyNameless, fromLocallyNameless) where import Data.Map (Map) import qualified Data.Map as Map import Abstract as A import Util import Value -- * de Bruijn Terms newtype Annotation ...
null
https://raw.githubusercontent.com/andreasabel/helf/52bc10751f5dac7338adcb085553ba8157692420/src/LocallyNamelessSyntax.hs
haskell
stuff taken from HerBruijnVal * de Bruijn Terms names are only used for quoting bound variable: de Bruijn index free variable: name name irrelevant for execution these are lambdas, but not counted note that it does NOT matter whether or not n already had been a key before!
# LANGUAGE DeriveFunctor # module LocallyNamelessSyntax (BTm(..), DBIndex(..), Annotation(..), toLocallyNameless, fromLocallyNameless) where import Data.Map (Map) import qualified Data.Map as Map import Abstract as A import Util import Value newtype Annotation a = Annotation { annotation :: a } deriving (Show, F...
c8f8a49929061501f55b0b94ec7e6da3aabfb99248fd9971026a7dbf1f8ba905
dbuenzli/topkg
browse.mli
--------------------------------------------------------------------------- Copyright ( c ) 2016 . All rights reserved . Distributed under the ISC license , see terms at the end of the file . % % NAME%% % % --------------------------------------------------------------------------- Copyright (c) ...
null
https://raw.githubusercontent.com/dbuenzli/topkg/ea1e0981a18ce4160ec21e8a73f67cb748059671/src-bin/browse.mli
ocaml
* The [browse] command.
--------------------------------------------------------------------------- Copyright ( c ) 2016 . All rights reserved . Distributed under the ISC license , see terms at the end of the file . % % NAME%% % % --------------------------------------------------------------------------- Copyright (c) ...
3c6f4cf0cee38ecdd63452434778830650982484734bf00b4317ec6e164e7cb5
GaloisInc/daedalus
test.hs
#!/usr/bin/env runhaskell {-# Language BlockArguments #-} {-# Language ImplicitParams #-} {-# Language ConstraintKinds #-} module Main where import Text.Read(readMaybe) import Data.Maybe import Data.List import Data.Char import Control.Monad(filterM,forM) import Control.Exception(SomeException(..),catch) import System...
null
https://raw.githubusercontent.com/GaloisInc/daedalus/7dcbf6a240dedd8473bb18c47dd7e1ed2268afeb/test-all-ways/test.hs
haskell
# Language BlockArguments # # Language ImplicitParams # # Language ConstraintKinds # ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ Compilation ----------------------------------------------------------------...
#!/usr/bin/env runhaskell module Main where import Text.Read(readMaybe) import Data.Maybe import Data.List import Data.Char import Control.Monad(filterM,forM) import Control.Exception(SomeException(..),catch) import System.FilePath import System.Process import System.Directory import System.Environment import System.I...
172bad6130ce9d1cc5776356f2ba71be45a256206aace95748d429026d2f028e
kfl/adventofcode_2022
day14.hs
# LANGUAGE LambdaCase # module Main where import qualified Data.Char as C import qualified Data.List as L import qualified Data.List.Split as S import Text.ParserCombinators.ReadP import Control.Monad (forM_) import Data.Ix import qualified Data.Array as A import Data.Array ((!)) test = map parse [ "498,4 -> 498,6...
null
https://raw.githubusercontent.com/kfl/adventofcode_2022/82a7cb39c600b6228bd6d1e643acdc8b9cc1b961/day14/day14.hs
haskell
# LANGUAGE LambdaCase # module Main where import qualified Data.Char as C import qualified Data.List as L import qualified Data.List.Split as S import Text.ParserCombinators.ReadP import Control.Monad (forM_) import Data.Ix import qualified Data.Array as A import Data.Array ((!)) test = map parse [ "498,4 -> 498,6...
5f7ffe33126f2b7a0d478197bb850fff7dc3f98dd235c2001cad6dd56488aa7a
taylorwood/lein-native-image
project.clj
(defproject http-api "0.1.0-SNAPSHOT" :dependencies [[org.clojure/clojure "1.9.0"] [http-kit "2.3.0"] [ring/ring-core "1.6.3"] [ring/ring-json "0.4.0"] [compojure "1.6.1"] [clj-http-lite "0.3.0"] [hickory "0.7.1"]] ...
null
https://raw.githubusercontent.com/taylorwood/lein-native-image/4c45d7a0ee2de91955f1b0515cd32ac50e782ba1/examples/http-api/project.clj
clojure
ignore native-image build errors
(defproject http-api "0.1.0-SNAPSHOT" :dependencies [[org.clojure/clojure "1.9.0"] [http-kit "2.3.0"] [ring/ring-core "1.6.3"] [ring/ring-json "0.4.0"] [compojure "1.6.1"] [clj-http-lite "0.3.0"] [hickory "0.7.1"]] ...
d80cf2179af4bf519ac05d6d80b71095e91f801834fb604bc04a75f9581674ac
hamidreza-s/Tecipe
tecipe_listener_sup.erl
-module(tecipe_listener_sup). -behaviour(supervisor). -export([start_link/4]). -export([init/1]). -include("tecipe.hrl"). start_link(Ref, Port, Handler, ListenerRec) -> Name = ListenerRec#tecipe_listener.listener_name, supervisor:start_link({local, Name}, ?MODULE, [Ref, Port, Handler, ListenerRec]). init([...
null
https://raw.githubusercontent.com/hamidreza-s/Tecipe/bcafcafec4c9c5981e6b89537808f3c9e94ea290/src/tecipe_listener_sup.erl
erlang
-module(tecipe_listener_sup). -behaviour(supervisor). -export([start_link/4]). -export([init/1]). -include("tecipe.hrl"). start_link(Ref, Port, Handler, ListenerRec) -> Name = ListenerRec#tecipe_listener.listener_name, supervisor:start_link({local, Name}, ?MODULE, [Ref, Port, Handler, ListenerRec]). init([...
cc811ec806c66f7fe8154f9c659fc70ebfae489d4ee40eae5114f54d8c5c2faf
junjihashimoto/th-cas
Base.hs
{-#LANGUAGE OverloadedStrings#-} module Algebra.CAS.Base where import Data.String import Data.List(nub) -- | Mathematical constant expression data Const = ^ Zero ^ One | CI Integer -- ^ Integer ^ Faction = CF numer denom | CR Double -- ^ Real Number deriving (Eq,Show,Read) instance Ord Const where compar...
null
https://raw.githubusercontent.com/junjihashimoto/th-cas/8fa179cf39c72c14dda4d77d824d31b32ad86dc0/Algebra/CAS/Base.hs
haskell
#LANGUAGE OverloadedStrings# | Mathematical constant expression ^ Integer ^ Real Number | Mathematical expression ^ Constant value ^ Pi ^ Imaginary Number ^ Constant variable which is used to deal variable(V Name) as constant value ^ Variable ^ Special Functions (sin, cos, exp and etc..) | try simplification...
module Algebra.CAS.Base where import Data.String import Data.List(nub) data Const = ^ Zero ^ One ^ Faction = CF numer denom deriving (Eq,Show,Read) instance Ord Const where compare Zero Zero = EQ compare Zero One = LT compare Zero (CI a) = compare 0 a compare Zero (CF a b) = compare 0 (a*b) compare...
4b045de34dbf3c1bb87c5cabe217c27fe1187c50fab71e05ac82efef022c66d0
juspay/atlas
Main.hs
| Copyright 2022 Juspay Technologies Pvt Ltd Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not use this file except in compliance with the License . You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing , software dis...
null
https://raw.githubusercontent.com/juspay/atlas/e64b227dc17887fb01c2554db21c08284d18a806/app/mock-parking-bpp/server/Main.hs
haskell
| Copyright 2022 Juspay Technologies Pvt Ltd Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not use this file except in compliance with the License . You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing , software dis...
883ff587042c698d950f010dd3c8766d39e47b26f644e56962d7b05e5b465993
exercism/babashka
allergies_test.clj
(ns allergies-test (:require [clojure.test :refer [deftest is]] allergies)) (deftest no-allergies-at-all (is (= [] (allergies/allergies 0)))) (deftest allergic-to-just-eggs (is (= [:eggs] (allergies/allergies 1)))) (deftest allergic-to-just-peanuts (is (= [:peanuts] (allergies/allergies 2)))) (d...
null
https://raw.githubusercontent.com/exercism/babashka/707356c52e08490e66cb1b2e63e4f4439d91cf08/exercises/practice/allergies/test/allergies_test.clj
clojure
(ns allergies-test (:require [clojure.test :refer [deftest is]] allergies)) (deftest no-allergies-at-all (is (= [] (allergies/allergies 0)))) (deftest allergic-to-just-eggs (is (= [:eggs] (allergies/allergies 1)))) (deftest allergic-to-just-peanuts (is (= [:peanuts] (allergies/allergies 2)))) (d...
0420759e97052574f67bdcaa3dabb102442eda96742544902e2c9f291c6b3c5b
timothypratley/leaderboardx
devcards.cljs
(ns dev.devcards (:require [algopop.leaderboardx.app.views.common :as common] [algopop.leaderboardx.app.views.assess :as assess] [devcards.core :as dc :refer-macros [defcard]] [reagent.core :as reagent])) (enable-console-print!) (defcard "# Test")
null
https://raw.githubusercontent.com/timothypratley/leaderboardx/ad1719b3bb49fb7ab495ed833f1a451ebb3aec4d/env/dev/cljs/dev/devcards.cljs
clojure
(ns dev.devcards (:require [algopop.leaderboardx.app.views.common :as common] [algopop.leaderboardx.app.views.assess :as assess] [devcards.core :as dc :refer-macros [defcard]] [reagent.core :as reagent])) (enable-console-print!) (defcard "# Test")
d2e51cfad5e4cae5e44d4d058d6aee822453178fb4943f00353a27009632fa9a
RefactoringTools/HaRe
InfixIn3AST.hs
module InfixIn3 where data Inf a b = Nil | a :* b data Try = C1 Try2 data Try2 = C2 [Int] data T = MkT [a] f :: (Inf [Int] (Either Int Int)) -> [Int] f Nil = [] f ((a :* b@(Left b_1))) = a f ((a :* b@(Right b_1))) = a f ((a :* b)) = a h :: (Inf [Int] (Either Int Int)) -> [Int] h Nil = [] h ((a@[] :* b)) =...
null
https://raw.githubusercontent.com/RefactoringTools/HaRe/ef5dee64c38fb104e6e5676095946279fbce381c/old/testing/subIntroPattern/InfixIn3AST.hs
haskell
module InfixIn3 where data Inf a b = Nil | a :* b data Try = C1 Try2 data Try2 = C2 [Int] data T = MkT [a] f :: (Inf [Int] (Either Int Int)) -> [Int] f Nil = [] f ((a :* b@(Left b_1))) = a f ((a :* b@(Right b_1))) = a f ((a :* b)) = a h :: (Inf [Int] (Either Int Int)) -> [Int] h Nil = [] h ((a@[] :* b)) =...
87cde71c0511c83173521961f4b662b36cbc25eca99fdcfab44b2296fbeb941e
lambdaisland/kaocha
spec_test_check_test.clj
(ns kaocha.plugin.alpha.spec-test-check-test (:require [clojure.spec.test.alpha] [clojure.test :refer [deftest testing is]] [clojure.tools.cli :as cli] [kaocha.plugin :as plugin] [matcher-combinators.test] [kaocha.plugin.alpha.spec-test-check :as spec-test-c...
null
https://raw.githubusercontent.com/lambdaisland/kaocha/8f18babb732b21e7fb2231e44be4d972c7ab22bc/test/unit/kaocha/plugin/alpha/spec_test_check_test.clj
clojure
(ns kaocha.plugin.alpha.spec-test-check-test (:require [clojure.spec.test.alpha] [clojure.test :refer [deftest testing is]] [clojure.tools.cli :as cli] [kaocha.plugin :as plugin] [matcher-combinators.test] [kaocha.plugin.alpha.spec-test-check :as spec-test-c...
ebb33a7b4f9518e7f902b6cd07a6b19d48ae464d181c4d8fa48b71b548a08ad7
nodfur/os
wisp.lisp
;; > (defun foo (x) x) ;; '(set-symbol-function foo (lambda (x) x)) (set-symbol-function (quote defun) (macro (name params body) (cons (quote set-symbol-function) (cons name (cons (cons (quote lambda) (cons params (cons body nil))) n...
null
https://raw.githubusercontent.com/nodfur/os/00fd7f3f76fa53938720789969d60217368f7dd7/wisp/wisp.lisp
lisp
> (defun foo (x) x) '(set-symbol-function foo (lambda (x) x))
(set-symbol-function (quote defun) (macro (name params body) (cons (quote set-symbol-function) (cons name (cons (cons (quote lambda) (cons params (cons body nil))) nil)))))
d3483737601a855f28cb26bef3ec10b4a859460a55debbc106f755f301b47d02
google-research/dex-lang
AbstractSyntax.hs
Copyright 2022 Google LLC -- -- Use of this source code is governed by a BSD-style -- license that can be found in the LICENSE file or at -- -source/licenses/bsd The parser is written in two distinct stages : - concrete syntax parsing using ( in ConcreteSyntax.hs ) -- - conversion of concrete syntax to abstrac...
null
https://raw.githubusercontent.com/google-research/dex-lang/c5a39c808c1ed19521517efea7e888ac8ad644e7/src/lib/AbstractSyntax.hs
haskell
Use of this source code is governed by a BSD-style license that can be found in the LICENSE file or at -source/licenses/bsd - conversion of concrete syntax to abstract syntax (this file). syntax deals with grouping (including keywords, primitives, and operator precedence), and the abstract syntax makes sure tha...
Copyright 2022 Google LLC The parser is written in two distinct stages : - concrete syntax parsing using ( in ConcreteSyntax.hs ) We separate these two stages to separate concerns : the concrete 4 + * 3 def foo ( x + y ) = 4 reader of should be able to know which substrings of input are the cons...
2c06e201f38ab6a41253baffac1ac5ec40b8729c55f5b5c71c566f44e93c5faa
lspitzner/brittany
Test495.hs
-- brittany { lconfig_columnAlignMode: { tag: ColumnAlignModeDisabled }, lconfig_indentPolicy: IndentPolicyLeft } func = let foo = True b = False in return ()
null
https://raw.githubusercontent.com/lspitzner/brittany/a15eed5f3608bf1fa7084fcf008c6ecb79542562/data/Test495.hs
haskell
brittany { lconfig_columnAlignMode: { tag: ColumnAlignModeDisabled }, lconfig_indentPolicy: IndentPolicyLeft }
func = let foo = True b = False in return ()
b5035ff6bd2b07cac25b67b44e3c1b1603261e537a70050865a17b331883eb32
evilbinary/scheme-lib
bytenumb.scm
" bytenumb.scm " Byte integer and IEEE floating - point conversions . Copyright ( C ) 2003 ; ;Permission to copy this software, to modify it, to redistribute it, ;to distribute modified versions, and to use it for any purpose is ;granted, subject to the following restrictions and understandings. ; 1 . Any copy ...
null
https://raw.githubusercontent.com/evilbinary/scheme-lib/6df491c1f616929caa4e6569fa44e04df7a356a7/packages/slib/bytenumb.scm
scheme
Permission to copy this software, to modify it, to redistribute it, to distribute modified versions, and to use it for any purpose is granted, subject to the following restrictions and understandings. in full. this software will be error-free, and I am under no obligation to provide any services, by way of maintenan...
" bytenumb.scm " Byte integer and IEEE floating - point conversions . Copyright ( C ) 2003 1 . Any copy made of this software must include this copyright notice 2 . I have made no warranty or representation that the operation of 3 . In conjunction with products arising from the use of this (require 'byte) ...
82d07f81a60ba6e95142cc30c769388f30f43658463bb7b76228e730f1655a67
quil-lang/quilc
stabilizer.lisp
;;;; stabilizer.lisp ;;;; Authors : , (in-package #:cl-quil.clifford) ;;; Most of this is from or inspired by -ph/0406196.pdf ;;; ;;; Gottesman's paper is also helpful ;;; -ph/9807006.pdf ...but BEWARE HIS PIQUANT ;;; QUBIT NOTATION!! Correct qubit ordering is very important. Pay ;;; attention to which qubits ...
null
https://raw.githubusercontent.com/quil-lang/quilc/3f3260aaa65cdde25a4f9c0027959e37ceef9d64/src/clifford/stabilizer.lisp
lisp
stabilizer.lisp Most of this is from or inspired by -ph/0406196.pdf Gottesman's paper is also helpful -ph/9807006.pdf ...but BEWARE HIS PIQUANT QUBIT NOTATION!! Correct qubit ordering is very important. Pay attention to which qubits are least/most significant and how they are ordered in the code with respect ...
Authors : , (in-package #:cl-quil.clifford) (deftype tableau-index () '(integer 0 (#.array-total-size-limit))) (deftype tableau () In all , this is a ( 2N + 1 ) x ( 2N + 1 ) square matrix of bits . Rows N to 2N - 1 are " stabilizer generators " Row 2N is for scratch space , as suggested by the et al ...
eb4437556bf5f7bf9565311699e3269a5a14b511f225bc9502fdb38fbc0916d5
ocaml-sf/learn-ocaml-corpus
test.ml
open Printf let iter = List.iter let map = List.map module T = Test_lib module R = Report type report = R.t (* Determinism. *) let () = Random.init 0 (* The auto-grader. *) (* -------------------------------------------------------------------------- *) (* Some of the code below should move to separate library files...
null
https://raw.githubusercontent.com/ocaml-sf/learn-ocaml-corpus/7dcf4d72b49863a3e37e41b3c3097aa4c6101a69/exercises/fpottier/huffman/test.ml
ocaml
Determinism. The auto-grader. -------------------------------------------------------------------------- Some of the code below should move to separate library files. -------------------------------------------------------------------------- Miscellaneous. --------------------------------------------------...
open Printf let iter = List.iter let map = List.map module T = Test_lib module R = Report type report = R.t let () = Random.init 0 let postincrement c = let n = !c in c := n + 1; n type requirement = Infinity is encoded as [ max_int ] . let infinity : requirement = max_int let (++) (x : require...
97b36081a2f86882dadb257fe406ae9dd07f506299c473c9a8ac5e5557bf7ede
i-am-tom/haskell-exercises
KindSignatures.hs
# LANGUAGE FlexibleInstances # {-# LANGUAGE KindSignatures #-} 3 , in which our heroes discover which they can help us. We'll see -} where {- we need them, and where they're just good documentation.. -} --- We are , hopefully , familiar with the notion of /types/ : @3@ is a value of type @Int@ , @Nothin...
null
https://raw.githubusercontent.com/i-am-tom/haskell-exercises/bdf8160fb7a09d577e1871ae29124b2041b3c079/03-KindSignatures/src/KindSignatures.hs
haskell
# LANGUAGE KindSignatures # we need them, and where they're just good documentation.. - Type = (*) This is a good habit to adopt, as '*' is going to be deprecated soon, in favour of the more explicit and (hopefully) clear 'Type'. Now, we know all sorts of things of kind 'Type': Which extension did we nee...
# LANGUAGE FlexibleInstances # 3 , in which our heroes discover We are , hopefully , familiar with the notion of /types/ : @3@ is a value of type @Int@ , @Nothing@ is a value of @Maybe ( IO String)@ , and so on . However , there is also a notion of types /for types/ : kinds . In our standard , eve...
fe8b98bea1d68642c9a58d782cfb06ccf899688360508367b82d9f48572cb1f9
mojombo/ernie
ernie_config.erl
-module(ernie_config). -export([load/1]). load(ConfigFile) -> {ok, Configs} = file:consult(ConfigFile), Configs2 = lists:map((fun load_single/1), Configs), {ok, Configs2}. load_single(Config) -> case proplists:get_value(type, Config) of native -> verify(native, Config), CodePaths = proplists:g...
null
https://raw.githubusercontent.com/mojombo/ernie/a21664e668038291bdbe42684d46cb112242aa7b/elib/ernie_config.erl
erlang
-module(ernie_config). -export([load/1]). load(ConfigFile) -> {ok, Configs} = file:consult(ConfigFile), Configs2 = lists:map((fun load_single/1), Configs), {ok, Configs2}. load_single(Config) -> case proplists:get_value(type, Config) of native -> verify(native, Config), CodePaths = proplists:g...
6b705daa4cb08dec06f406a9e661ed078970eb9d76f5edad68e5a2ad9b07080c
haskell-suite/haskell-src-exts
TySplice4.hs
# LANGUAGE TemplateHaskell # x = [d| f :: a -> Int f x = 1 |] y = [d| f2 :: a -> Int; f2 x = 1 |]
null
https://raw.githubusercontent.com/haskell-suite/haskell-src-exts/84a4930e0e5c051b7d9efd20ef7c822d5fc1c33b/tests/examples/TySplice4.hs
haskell
# LANGUAGE TemplateHaskell # x = [d| f :: a -> Int f x = 1 |] y = [d| f2 :: a -> Int; f2 x = 1 |]
c48d21e5e8260fe52311170574727676742c59aa928072a328cb8df0c202e802
Kappa-Dev/KappaTools
common_args.mli
(******************************************************************************) (* _ __ * The Kappa Language *) | |/ / * Copyright 2010 - 2020 CNRS - Harvard Medical School - INRIA - IRIF (* | ' / ********************************************************************...
null
https://raw.githubusercontent.com/Kappa-Dev/KappaTools/eef2337e8688018eda47ccc838aea809cae68de7/core/cli/common_args.mli
ocaml
**************************************************************************** _ __ * The Kappa Language | ' / ******************************************************************** | . \ * This file is distributed under the terms of the |_|\_\ * GN...
| |/ / * Copyright 2010 - 2020 CNRS - Harvard Medical School - INRIA - IRIF val data_set: Superarg.category val output: Superarg.category val semantics: Superarg.category val integration_settings: Superarg.category val model_reduction: Superarg.category val static_analysis: Superarg.category val debug_mode: Supera...
d691b40b3e4e42530defe4f9a93aef874fd4e91132b4dbdc9cc5be57f7e6ffca
solita/mnt-teet
enum_values.clj
(ns teet.migration.enum-values (:require [datomic.client.api :as d])) (defn remove-old-task-types [conn] (let [types (d/q '[:find (pull ?e [*]) :where [?e :enum/attribute :task/type]] (d/db conn))] (d/transact conn {:tx-data (for [[{id :db/id}] types] ...
null
https://raw.githubusercontent.com/solita/mnt-teet/7a5124975ce1c7f3e7a7c55fe23257ca3f7b6411/app/backend/src/clj/teet/migration/enum_values.clj
clojure
(ns teet.migration.enum-values (:require [datomic.client.api :as d])) (defn remove-old-task-types [conn] (let [types (d/q '[:find (pull ?e [*]) :where [?e :enum/attribute :task/type]] (d/db conn))] (d/transact conn {:tx-data (for [[{id :db/id}] types] ...
c9d1c15cfb850a81ed9a69f368fdba7a5b72c88e293923ab0027764edd37dfaa
ppaml-op3/insomnia
Racket.hs
-- | AST for a fragment of Racket. At this level of detail we don't -- worry about certain forms being macros. # LANGUAGE DeriveDataTypeable , DeriveGeneric # module Gambling.Racket where import Data.Typeable (Typeable) import GHC.Generics (Generic) import Unbound.Generics.LocallyNameless import Insomnia.Common.Lit...
null
https://raw.githubusercontent.com/ppaml-op3/insomnia/5fc6eb1d554e8853d2fc929a957c7edce9e8867d/src/Gambling/Racket.hs
haskell
| AST for a fragment of Racket. At this level of detail we don't worry about certain forms being macros. term pattern pattern term pattern term Racket calls these "internal definition contexts" and uses the metavar /body/ pattern no definition, just a bare expression pattern term term pattern pattern...
# LANGUAGE DeriveDataTypeable , DeriveGeneric # module Gambling.Racket where import Data.Typeable (Typeable) import GHC.Generics (Generic) import Unbound.Generics.LocallyNameless import Insomnia.Common.Literal type Var = Name Expr data Expr = Var Var | StringLit String | QuoteSymbol String | Literal Litera...
93bf393968326b6c6f36374fbfd8936dc1d4d965be3758f1ddbb1fe846c6ca5e
yzh44yzh/practical_erlang
ping_handler.erl
-module(ping_handler). -behaviour(cowboy_handler). -export([init/2]). init(Req0, State) -> Headers = #{ <<"content-type">> => <<"text/html">> }, Body = << "<h1>Hello from Cowboy</h1>" "<p>This is ping_handler</p>" >>, Req1 = cowboy_req:reply(200, Headers, Body, Req0), {...
null
https://raw.githubusercontent.com/yzh44yzh/practical_erlang/c9eec8cf44e152bf50d9bc6d5cb87fee4764f609/17_web_server/ws/apps/ws/src/handlers/ping_handler.erl
erlang
-module(ping_handler). -behaviour(cowboy_handler). -export([init/2]). init(Req0, State) -> Headers = #{ <<"content-type">> => <<"text/html">> }, Body = << "<h1>Hello from Cowboy</h1>" "<p>This is ping_handler</p>" >>, Req1 = cowboy_req:reply(200, Headers, Body, Req0), {...
f63df39592e8e919ee9a753d00696b76cbf18120693f4078cbd82db88b621977
project-oak/hafnium-verification
Language.mli
* Copyright ( c ) Facebook , Inc. and its affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the ...
null
https://raw.githubusercontent.com/project-oak/hafnium-verification/6071eff162148e4d25a0fedaea003addac242ace/experiments/ownership-inference/infer/infer/src/base/Language.mli
ocaml
* Copyright ( c ) Facebook , Inc. and its affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the ...
24aec84659c15bf564bbbe27181a23d1266dc6fc0363ac06321cf3a7a13d5504
Swirrl/cubiql
dataset.clj
(ns cubiql.schema.mapping.dataset (:require [cubiql.util :as util] [cubiql.vocabulary :refer [qb:measureType]])) (def uri :uri) (def schema :schema) (def dimensions :dimensions) (def measures :measures) (defn description [dataset-mapping] ;;TODO: add dataset description to mapping! "") (defn compon...
null
https://raw.githubusercontent.com/Swirrl/cubiql/67efdc51750b9ac4fd1cdfbcddfb80398189807f/src/cubiql/schema/mapping/dataset.clj
clojure
TODO: add dataset description to mapping!
(ns cubiql.schema.mapping.dataset (:require [cubiql.util :as util] [cubiql.vocabulary :refer [qb:measureType]])) (def uri :uri) (def schema :schema) (def dimensions :dimensions) (def measures :measures) (defn description [dataset-mapping] "") (defn components [dataset-mapping] (concat (dimensions d...
dd120988fecb0fdc12e9370619cec48eef872230a1b6e4e7ca07fdde67d145b7
Ptival/chick
Chick.hs
module PrettyPrinting.Chick () where import PrettyPrinting.Chick.Binder () import PrettyPrinting.Chick.Constructor () import PrettyPrinting . . Declaration ( ) import PrettyPrinting.Chick.Definition () import PrettyPrinting.Chick.DefinitionObjectKind () import PrettyPrinting.Chick.GlobalDeclaration () import PrettyPr...
null
https://raw.githubusercontent.com/Ptival/chick/a5ce39a842ff72348f1c9cea303997d5300163e2/backend/lib/PrettyPrinting/Chick.hs
haskell
module PrettyPrinting.Chick () where import PrettyPrinting.Chick.Binder () import PrettyPrinting.Chick.Constructor () import PrettyPrinting . . Declaration ( ) import PrettyPrinting.Chick.Definition () import PrettyPrinting.Chick.DefinitionObjectKind () import PrettyPrinting.Chick.GlobalDeclaration () import PrettyPr...
27bce5e2d8966e946050fc7e89454c0a42f857d94090aa44787b89168d27ac51
dcSpark/fracada
Emulator.hs
{-# LANGUAGE DataKinds #-} {-# LANGUAGE DeriveAnyClass #-} # LANGUAGE DeriveGeneric # {-# LANGUAGE FlexibleContexts #-} # LANGUAGE NoImplicitPrelude # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE ScopedTypeVariables # # LANGUAGE TemplateHaskell # # LANGUAGE TypeApplications # # L...
null
https://raw.githubusercontent.com/dcSpark/fracada/8da585575313b1c8e4fc8d30dcaf21d11ad6197c/exe/Emulator.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE DeriveAnyClass # # LANGUAGE FlexibleContexts # # LANGUAGE OverloadedStrings # # LANGUAGE TypeOperators # # LANGUAGE NumericUnderscores #
# LANGUAGE DeriveGeneric # # LANGUAGE NoImplicitPrelude # # LANGUAGE ScopedTypeVariables # # LANGUAGE TemplateHaskell # # LANGUAGE TypeApplications # # LANGUAGE TypeFamilies # import Prelude (IO, (<>)) import PlutusTx.Prelude hiding (Semigroup(..), u...
f7ee6ffb74bb24ade41b296d2de5f64e30e4db44b420e8001ee5a16b1f93bea2
stumpwm/stumpwm-contrib
package.lisp
package.lisp (defpackage #:swm-emacs (:use #:cl :stumpwm))
null
https://raw.githubusercontent.com/stumpwm/stumpwm-contrib/a7dc1c663d04e6c73a4772c8a6ad56a34381096a/util/swm-emacs/package.lisp
lisp
package.lisp (defpackage #:swm-emacs (:use #:cl :stumpwm))
ef898fb96fb9773f28aa3f305d408da98bcab69ebcde457a84c77e6fd7c3ac77
nanocaml/nanocaml
pass_typeck_tests.ml
open OUnit2 open Migrate_parsetree open Ast_405.Parsetree open Ast_405.Ast_helper let test_L0 = Parsing_tests.test_L0 let test_L0_a = Parsing_tests.test_L0_a let tt = "pass_typeck" >::: let open Nanocaml.Pass in let open Nanocaml.Lang in let module TC = Nanocaml.Pass_typeck in let loc = !default_loc...
null
https://raw.githubusercontent.com/nanocaml/nanocaml/c856268dc8986bd9fb739c8cd6b972052997a30c/test/pass_typeck_tests.ml
ocaml
x [@r] ==> x [@r a] x [@r] ==> (_ [@r a], _) [@l] as x
open OUnit2 open Migrate_parsetree open Ast_405.Parsetree open Ast_405.Ast_helper let test_L0 = Parsing_tests.test_L0 let test_L0_a = Parsing_tests.test_L0_a let tt = "pass_typeck" >::: let open Nanocaml.Pass in let open Nanocaml.Lang in let module TC = Nanocaml.Pass_typeck in let loc = !default_loc...
926660d398b440178959342b2082f560d9957fa4234d8e9d1e3b5b142deb1a65
portkey-cloud/aws-clj-sdk
_2016-06-27.clj
(ns portkey.aws.rekognition.-2016-06-27 (:require [portkey.aws])) (def endpoints '{"ap-northeast-1" {:credential-scope {:service "rekognition", :region "ap-northeast-1"}, :ssl-common-name "rekognition.ap-northeast-1.amazonaws.com", :endpoint "-northeast-1.amazonaws.com", :signature-version :v4}, ...
null
https://raw.githubusercontent.com/portkey-cloud/aws-clj-sdk/10623a5c86bd56c8b312f56b76ae5ff52c26a945/src/portkey/aws/rekognition/_2016-06-27.clj
clojure
(ns portkey.aws.rekognition.-2016-06-27 (:require [portkey.aws])) (def endpoints '{"ap-northeast-1" {:credential-scope {:service "rekognition", :region "ap-northeast-1"}, :ssl-common-name "rekognition.ap-northeast-1.amazonaws.com", :endpoint "-northeast-1.amazonaws.com", :signature-version :v4}, ...
83487f6c7c24f253c8901db6af7a2fbcc1545fa60bc9ca5e19bd79c766fed8b4
ghc/ghc
Equality.hs
{-# LANGUAGE DataKinds #-} # LANGUAGE FlexibleInstances # {-# LANGUAGE GADTs #-} # LANGUAGE MultiParamTypeClasses # # LANGUAGE NoImplicitPrelude # # LANGUAGE PolyKinds # {-# LANGUAGE RankNTypes #-} {-# LANGUAGE StandaloneDeriving ...
null
https://raw.githubusercontent.com/ghc/ghc/37cfe3c0f4fb16189bbe3bb735f758cd6e3d9157/libraries/base/Data/Type/Equality.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE GADTs # # LANGUAGE RankNTypes # # LANGUAGE StandaloneDeriving # # LANGUAGE Trustworthy # # LANGUAGE TypeFamilies # # LANGUAGE TypeOperators # ------------------------------------------------------...
# LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE NoImplicitPrelude # # LANGUAGE PolyKinds # # LANGUAGE StandaloneKindSignatures # # LANGUAGE UndecidableInstances # of type @(a ' : ~ : ' b)@ produces a proof that @a ' ~ ' b@. module Data.Type.Equ...
6efebae21697fc30f2a6ead3cc4732fcce4ea650babcbe7485cb48ab2a5271c3
project-oak/hafnium-verification
PhysEqual.mli
* Copyright ( c ) Facebook , Inc. and its affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the ...
null
https://raw.githubusercontent.com/project-oak/hafnium-verification/6071eff162148e4d25a0fedaea003addac242ace/experiments/ownership-inference/infer/infer/src/istd/PhysEqual.mli
ocaml
* Copyright ( c ) Facebook , Inc. and its affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the ...
b2b161a4f0752f3dd93d4a59cb493baaf98c5e1ed268b69d11ea9a47b377de78
pqwy/lru
test.ml
Copyright ( c ) 2016 . All rights reserved . See LICENSE.md See LICENSE.md *) let id x = x let (%) f g x = f (g x) module I = struct type t = int let compare (a: int) b = compare a b let equal (a: int) b = a = b let hash (i: int) = Hashtbl.hash i let weight _ = 1 end let sort_uniq_r (type a) c...
null
https://raw.githubusercontent.com/pqwy/lru/b88a102bcb14c900c4233c47202678e948181009/test/test.ml
ocaml
Copyright ( c ) 2016 . All rights reserved . See LICENSE.md See LICENSE.md *) let id x = x let (%) f g x = f (g x) module I = struct type t = int let compare (a: int) b = compare a b let equal (a: int) b = a = b let hash (i: int) = Hashtbl.hash i let weight _ = 1 end let sort_uniq_r (type a) c...
6fcd410b222b42d98e463169dd93794ab4609efcd289f8cff153478ba6666a34
int-index/kalium
Pattern.hs
# LANGUAGE FlexibleContexts # module Kalium.Nucleus.Vector.Pattern where import qualified Data.Set as S import Control.Monad.Writer import Kalium.Prelude import Kalium.Nucleus.Vector.Program patBound :: Pattern -> Set Name patBound = \case PWildCard -> mempty PUnit -> mempty PAccess name _ -> S.singleto...
null
https://raw.githubusercontent.com/int-index/kalium/0653b4229001880322acf3016de595360de726ec/src/Kalium/Nucleus/Vector/Pattern.hs
haskell
# LANGUAGE FlexibleContexts # module Kalium.Nucleus.Vector.Pattern where import qualified Data.Set as S import Control.Monad.Writer import Kalium.Prelude import Kalium.Nucleus.Vector.Program patBound :: Pattern -> Set Name patBound = \case PWildCard -> mempty PUnit -> mempty PAccess name _ -> S.singleto...
9c638fbc459fdfe04f7d1387502bbbd7daa34638feb516c20fbb12d3416cdfae
weavejester/build
tasks.clj
(ns weavejester.build.tasks (:refer-clojure :exclude [test]) (:require [babashka.fs :as fs] [babashka.pods :as pods] [babashka.tasks :as bb] [weavejester.build.project :as p])) (defn- run-clojure [deps ns args] (apply bb/clojure "-Sdeps" (pr-str {:deps deps}) "-M" "-m" (str ns...
null
https://raw.githubusercontent.com/weavejester/build/8974b24113e4a4a9fa10656d14f61d8cb05a7392/src/weavejester/build/tasks.clj
clojure
(ns weavejester.build.tasks (:refer-clojure :exclude [test]) (:require [babashka.fs :as fs] [babashka.pods :as pods] [babashka.tasks :as bb] [weavejester.build.project :as p])) (defn- run-clojure [deps ns args] (apply bb/clojure "-Sdeps" (pr-str {:deps deps}) "-M" "-m" (str ns...
42cc67731332a523bb2724ca376134e7514f9e26ceadba5fc3c3a1e4e2e30afc
diasbruno/language-js
Spec.hs
module Main where import Control.Monad (when) import System.Exit import Test.Hspec import Test.Hspec.Runner import Test.Helpers import Test.MemberExpression import Test.AssignmentAndOperation import Test.Variables import Test.If import Test.Try import Test.Switch import Test.Functions import Test.Classes import Test.I...
null
https://raw.githubusercontent.com/diasbruno/language-js/c986bb904e717fa8dd84f52473440ea726a275be/t/Spec.hs
haskell
module Main where import Control.Monad (when) import System.Exit import Test.Hspec import Test.Hspec.Runner import Test.Helpers import Test.MemberExpression import Test.AssignmentAndOperation import Test.Variables import Test.If import Test.Try import Test.Switch import Test.Functions import Test.Classes import Test.I...
5bfb37b05c3fda1f768e12352d6fca15c95a925d0cf094164076d972cf83fd54
dcavar/schemeNLP
countbigrams1.scm
":"; exec mzscheme -r $0 "$@" ;;; ---------------------------------------------------- ;;; Filename: countbigrams1.ss Author : < > ;;; ( C ) 2006 by ;;; ;;; This code is published under the restrictive GPL! ;;; Please find the text of the GPL here: ;;; ;;; ;;; It is free for use, change, etc. as long as ...
null
https://raw.githubusercontent.com/dcavar/schemeNLP/daa0ddcc4fa67fe00dcf6054c4d30d11a00b2f7f/src/countbigrams1.scm
scheme
exec mzscheme -r $0 "$@" ---------------------------------------------------- Filename: countbigrams1.ss This code is published under the restrictive GPL! Please find the text of the GPL here: It is free for use, change, etc. as long as the copyright note above is included in any modified version of the co...
Author : < > ( C ) 2006 by 1 . The text file is loaded into memory . 2 . The text is tokenized , i.e. converted into a list of tokens . 3 . Two adjacent tokens are placed into a hash - table as keys , the value 4 . The hash - table is converted into a list of key - value tuples . 5 . The key - va...
b96e69a24dcdb6ec6734ba5387da18999957cd26794158853fa943197fcf1a84
semilin/layoup
Rspace_Rollin.lisp
(MAKE-LAYOUT :NAME "Rspace_Rollin" :MATRIX (APPLY #'KEY-MATRIX 'NIL) :SHIFT-MATRIX NIL :KEYBOARD NIL)
null
https://raw.githubusercontent.com/semilin/layoup/27ec9ba9a9388cd944ac46206d10424e3ab45499/data/layouts/Rspace_Rollin.lisp
lisp
(MAKE-LAYOUT :NAME "Rspace_Rollin" :MATRIX (APPLY #'KEY-MATRIX 'NIL) :SHIFT-MATRIX NIL :KEYBOARD NIL)
2348c89c5ccabab9237c87a6e55cf0a82bfccdab87a5f43c5ac1b0d3955556b4
mhuebert/maria
live_layout.cljs
(ns maria.pages.live-layout (:require [chia.view :as v] [maria.views.floating.tooltip :as tooltip] [chia.db :as d] [maria.commands.which-key :as which-key] [maria.repl-specials] [cljs.core.match :refer-macros [match]] [maria.views.floating.float-...
null
https://raw.githubusercontent.com/mhuebert/maria/15586564796bc9273ace3101b21662d0c66b4d22/editor/src/maria/pages/live_layout.cljs
clojure
normalize encoding... bidi leaves route params in a partially decoded state
(ns maria.pages.live-layout (:require [chia.view :as v] [maria.views.floating.tooltip :as tooltip] [chia.db :as d] [maria.commands.which-key :as which-key] [maria.repl-specials] [cljs.core.match :refer-macros [match]] [maria.views.floating.float-...
ed2750de04aea1681375b3c8c30f5e074bac4b5c388cd53947a1573c7347de68
csabahruska/jhc-components
CPUTime.hs
module CPUTime ( getCPUTime, cpuTimePrecision ) where import System.CPUTime
null
https://raw.githubusercontent.com/csabahruska/jhc-components/a7dace481d017f5a83fbfc062bdd2d099133adf1/lib/haskell98/CPUTime.hs
haskell
module CPUTime ( getCPUTime, cpuTimePrecision ) where import System.CPUTime
a0118ae38e4315377b24de1eaf1330dd2942bad354248cbcdbffe39d83044469
camlspotter/ocaml-zippy-tutorial-in-japanese
w7.ml
class c = object method m = print_endline "hello" end class c' = object inherit c < = Warning 7 end Warning 7 : the method m is overridden .
null
https://raw.githubusercontent.com/camlspotter/ocaml-zippy-tutorial-in-japanese/c6aeabc08b6e2289a0e66c5b94a89c6723d88a6a/t/warnings/w7.ml
ocaml
class c = object method m = print_endline "hello" end class c' = object inherit c < = Warning 7 end Warning 7 : the method m is overridden .
2c19d3bfdaef404e4c5d431e18b2e8329df207856bc932c0dbd277df23ace2ba
cdfa/frugel
Event.hs
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE RecordWildCards # # LANGUAGE TemplateHaskell # # LANGUAGE TypeFamilies # # LANGUAGE UndecidableInstances # module Frugel.Web.Event where import Data.Aeson.Types import Frugel import Fruge...
null
https://raw.githubusercontent.com/cdfa/frugel/d412673d8925a6f9eaad4e043cbd8fa46ed50aa2/app/Frugel/Web/Event.hs
haskell
Left and right also allowed with Alt, because pressing/releasing Alt repeatedly while navigating is annoying | -US/docs/Web/Events/keydown
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE RecordWildCards # # LANGUAGE TemplateHaskell # # LANGUAGE TypeFamilies # # LANGUAGE UndecidableInstances # module Frugel.Web.Event where import Data.Aeson.Types import Frugel import Fruge...
3e49a044b8ab9cdf3dee8b130b75725d1c143e86664a22f41d97b79ef4a15246
malcolmreynolds/GSLL
error-functions.lisp
;; Error functions , Mon Mar 20 2006 - 22:31 Time - stamp : < 2008 - 10 - 23 22:50:45EDT error-functions.lisp > $ Id$ (in-package :gsl) (defmfun erf (x) "gsl_sf_erf_e" ((x :double) (ret sf-result)) "The error function erf(x), where erf(x) = (2/\sqrt(\pi)) \int_0^x dt \exp(-t^2).") (defmfun erfc (x) ...
null
https://raw.githubusercontent.com/malcolmreynolds/GSLL/2f722f12f1d08e1b9550a46e2a22adba8e1e52c4/special-functions/error-functions.lisp
lisp
Error functions
, Mon Mar 20 2006 - 22:31 Time - stamp : < 2008 - 10 - 23 22:50:45EDT error-functions.lisp > $ Id$ (in-package :gsl) (defmfun erf (x) "gsl_sf_erf_e" ((x :double) (ret sf-result)) "The error function erf(x), where erf(x) = (2/\sqrt(\pi)) \int_0^x dt \exp(-t^2).") (defmfun erfc (x) "gsl_sf_erfc_e" (...
a6e57a084f94f5f9f83955c8b4c3c9fb35137a8f4f2ef5d45785bfb4ddcce3c8
Cipherwraith/hblog
Input.hs
module Input where import Config import Types import qualified Data.Text.Lazy as T import qualified Data.Text.Lazy.IO as T import System.Directory import Data.List import Control.Applicative import System.FilePath import Data.Char import Text.Pandoc getPostList :: IO [FilePath] getPostList = map (postsDirectory </>) ...
null
https://raw.githubusercontent.com/Cipherwraith/hblog/f92d96a60e301302c8a0e46fd68ee1e1810eb031/Input.hs
haskell
module Input where import Config import Types import qualified Data.Text.Lazy as T import qualified Data.Text.Lazy.IO as T import System.Directory import Data.List import Control.Applicative import System.FilePath import Data.Char import Text.Pandoc getPostList :: IO [FilePath] getPostList = map (postsDirectory </>) ...
447f3cf0f757b9739c2a74aa8cd1c7208e87f578d953fd551d731684c896db34
andrewmcloud/consimilo
text_processing.clj
(ns consimilo.text-processing (:require [opennlp.nlp :as nlp] [pantomime.extract :as extract] [clojure.java.io :as io] [clojure.string :as s] [clojure.tools.logging :as log])) (def ^:private tokenize (nlp/make-tokenizer (io/resource "en-token.bin"))) (def ^:private sto...
null
https://raw.githubusercontent.com/andrewmcloud/consimilo/db96c1695248c3486e1d23de5589b39f0e0bd49f/src/consimilo/text_processing.clj
clojure
Not currently used
(ns consimilo.text-processing (:require [opennlp.nlp :as nlp] [pantomime.extract :as extract] [clojure.java.io :as io] [clojure.string :as s] [clojure.tools.logging :as log])) (def ^:private tokenize (nlp/make-tokenizer (io/resource "en-token.bin"))) (def ^:private sto...
7fc3cec0378e7af4c6903f5d5f258e35cd8e9810d983b641fde57ed4bbb9fc00
foreverbell/project-euler-solutions
Matrix.hs
modified from -Diaz/matrix for my specific use . module Common.Matrix.Matrix ( Matrix, rows, cols, fmap, (!), (!.), getElem, safeGet, unsafeGet, getRow, getCol, fromList, toList, fromLists, toLists, create, zero, identity, scalar, add, subtract, multiply, power ) where im...
null
https://raw.githubusercontent.com/foreverbell/project-euler-solutions/c0bf2746aafce9be510892814e2d03e20738bf2b/lib/Common/Matrix/Matrix.hs
haskell
# UNPACK # # UNPACK # # INLINE (!) # # INLINE (!.) #
modified from -Diaz/matrix for my specific use . module Common.Matrix.Matrix ( Matrix, rows, cols, fmap, (!), (!.), getElem, safeGet, unsafeGet, getRow, getCol, fromList, toList, fromLists, toLists, create, zero, identity, scalar, add, subtract, multiply, power ) where im...
8baf4c2d267a274be537e0b866f246082f9aa36d2f362a58471263748eeaaa48
nuprl/gradual-typing-performance
array-struct-unsafe-build-array.rkt
#lang typed/racket/base (provide unsafe-build-array) ;; ----------------------------------------------------------------------------- (require "type-aliases.rkt" "data-array-adapted.rkt" (only-in racket/fixnum fx+ fx*) benchmark-util) (require/typed/check "array-utils-check-array-shape.rkt...
null
https://raw.githubusercontent.com/nuprl/gradual-typing-performance/35442b3221299a9cadba6810573007736b0d65d4/experimental/micro/synth/typed/array-struct-unsafe-build-array.rkt
racket
----------------------------------------------------------------------------- ============================================================================= This box's contents get replaced when the array we're constructing is made strict, so that the array stops referencing f. If we didn't do this, long chains of a...
#lang typed/racket/base (provide unsafe-build-array) (require "type-aliases.rkt" "data-array-adapted.rkt" (only-in racket/fixnum fx+ fx*) benchmark-util) (require/typed/check "array-utils-check-array-shape.rkt" [check-array-shape (-> (Vectorof Integer) (-> Nothing) Indexes)]) (require/ty...
6ab60662fb5e9634e39eb8ba4bc1b0a4fc0db46b28c8862fed85c8824262fb30
google/proto-lens
Wire.hs
| Module defining the individual base wire types ( e.g. VarInt , Fixed64 ) . -- -- They are used to represent the @unknownFields@ within the proto message. -- -- Upstream docs: -- <-buffers/docs/encoding#structure> {-# LANGUAGE BangPatterns #-} # LANGUAGE CPP # # LANGUAGE GeneralizedNewtypeDeriving # module Data.Prot...
null
https://raw.githubusercontent.com/google/proto-lens/081815877430afc1db669ca5e4edde1558b5fd9d/proto-lens/src/Data/ProtoLens/Encoding/Wire.hs
haskell
They are used to represent the @unknownFields@ within the proto message. Upstream docs: <-buffers/docs/encoding#structure> # LANGUAGE BangPatterns # | A tag that identifies a particular field of the message when converting to/from the wire format. | The encoding of some unknown field on the wire. | A pair of a...
| Module defining the individual base wire types ( e.g. VarInt , Fixed64 ) . # LANGUAGE CPP # # LANGUAGE GeneralizedNewtypeDeriving # module Data.ProtoLens.Encoding.Wire ( Tag(..) , TaggedValue(..) , WireValue(..) , FieldSet , splitTypeAndTag , joinTypeAndTag , parseFieldSet , buildFie...
3f8a78b136f570624ec6733625d9ebddfb2f903d160c3c81836cf6ae10e2964f
input-output-hk/plutus-apps
Utils.hs
{-# LANGUAGE DataKinds #-} # LANGUAGE DerivingStrategies # # LANGUAGE LambdaCase # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE TypeApplications # module Plutus.Blockfrost.Utils where import Data.Maybe (fromJust, fromMaybe) import Data.Proxy (Proxy (..)) import Data.String import Data.Text (Tex...
null
https://raw.githubusercontent.com/input-output-hk/plutus-apps/e8688b8f86a92b285e7d93eb418ccc314ad41bf9/pab-blockfrost/src/Plutus/Blockfrost/Utils.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE OverloadedStrings # the functions "to", "from" and "interval" includes the parameters inside the validity range, meanwhile
# LANGUAGE DerivingStrategies # # LANGUAGE LambdaCase # # LANGUAGE TypeApplications # module Plutus.Blockfrost.Utils where import Data.Maybe (fromJust, fromMaybe) import Data.Proxy (Proxy (..)) import Data.String import Data.Text (Text, pack, unpack) import Data.Text qualified as Text (drop, take) import ...
d88fcb9e41398dbd6905cdf66bb272897c6f1f2d3f97c520cb043c4a9bf080a6
tact-lang/tact-obsolete
discriminator.ml
open Base module Make = functor (Config : Config.T) -> struct open Lang_types.Make (Config) module LocalDiscriminators = struct type t = unit open struct let get_discr_from_attrs attrs = List.find_map attrs ~f:(fun {attribute_ident; attribute_exprs} -> match ...
null
https://raw.githubusercontent.com/tact-lang/tact-obsolete/3ae7046c654048ccc7c77db85fdf5e07df557a2f/lib/discriminator.ml
ocaml
open Base module Make = functor (Config : Config.T) -> struct open Lang_types.Make (Config) module LocalDiscriminators = struct type t = unit open struct let get_discr_from_attrs attrs = List.find_map attrs ~f:(fun {attribute_ident; attribute_exprs} -> match ...
4fd28c06217a7166d5080d1937f66cc7e597935d11ca3b2751336e9d73069370
gregr/experiments
map-map-cps.rkt
#lang racket (define (map f xs) (if (null? xs) '() (let ((a (f (car xs))) (d (map f (cdr xs)))) (cons a d)))) (define (map/k k f xs) (if (null? xs) (k '()) (f (lambda (a) (map/k (lambda (d) (k (cons a d))) f (cdr xs))) (car xs)))) (define (+1 x) (+ ...
null
https://raw.githubusercontent.com/gregr/experiments/cd4c7953f45102539081077bbd6195cf834ba2fa/supercompilation/map-map-cps.rkt
racket
direct style ;; * lower let binding to use site (safe to pass +1, which is pure) * ; * float pure binding *
#lang racket (define (map f xs) (if (null? xs) '() (let ((a (f (car xs))) (d (map f (cdr xs)))) (cons a d)))) (define (map/k k f xs) (if (null? xs) (k '()) (f (lambda (a) (map/k (lambda (d) (k (cons a d))) f (cdr xs))) (car xs)))) (define (+1 x) (+ ...
bc514d83de1783e88fce41e9a6202496e99ce8671351b5ba6489d5245bba519f
halgari/naiad
nodes.clj
(ns naiad.nodes (:require [clojure.core :as clj] [naiad.graph :refer [add-node! gen-id id? *graph* ports INode]] [naiad.backends.csp :as csp] [clojure.core.async :refer [go <! >! close! thread] :as async])) (defmacro process [{:keys [blocking-io] :...
null
https://raw.githubusercontent.com/halgari/naiad/c47bc6f9d2e8e4222bd7820fa404d9ceebfc8e22/src/naiad/nodes.clj
clojure
(ns naiad.nodes (:require [clojure.core :as clj] [naiad.graph :refer [add-node! gen-id id? *graph* ports INode]] [naiad.backends.csp :as csp] [clojure.core.async :refer [go <! >! close! thread] :as async])) (defmacro process [{:keys [blocking-io] :...
b546a3816c933bbd41517851bf69731f04470eaa1c27815360b43818934fe7f5
ryanpbrewster/haskell
P099.hs
module TestData.P099 (txt) where txt = unlines [ "519432 525806" , "632382 518061" , "78864 613712" , "466580 530130" , "780495 510032" , "525895 525320" , "15991 714883" , "960290 502358" , "760018 511029" , "166800 575487" , "210884 564478" , "555151 523163" , "681146 515199" , "563395 ...
null
https://raw.githubusercontent.com/ryanpbrewster/haskell/6edd0afe234008a48b4871032dedfd143ca6e412/project-euler/tests/TestData/P099.hs
haskell
module TestData.P099 (txt) where txt = unlines [ "519432 525806" , "632382 518061" , "78864 613712" , "466580 530130" , "780495 510032" , "525895 525320" , "15991 714883" , "960290 502358" , "760018 511029" , "166800 575487" , "210884 564478" , "555151 523163" , "681146 515199" , "563395 ...
f20f7bc3b9327c99f9795703ef4694cf74141fd952904b9a714ef33a0f956afb
OCamlPro/ocplib-json-typed
json_repr_browser.ml
This file is part of Learn - OCaml . * * Copyright ( C ) 2016 OCamlPro . * * Learn - OCaml is free software : you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as * published by the Free Software Foundation , either version 3 of the * License , or...
null
https://raw.githubusercontent.com/OCamlPro/ocplib-json-typed/0d9e9cde74c7c50aa6d053990b46f5930c80de54/src/json_repr_browser.ml
ocaml
Not for the faint of heart. Oh yeah!
This file is part of Learn - OCaml . * * Copyright ( C ) 2016 OCamlPro . * * Learn - OCaml is free software : you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as * published by the Free Software Foundation , either version 3 of the * License , or...
01a69bffc70606fd666f1ee2b4ae6be47f418f96e5fa612df85cf7ac78c84081
onedata/op-worker
atm_task_execution_status.erl
%%%------------------------------------------------------------------- @author ( C ) 2021 - 2022 ACK CYFRONET AGH This software is released under the MIT license cited in ' LICENSE.txt ' . %%% @end %%%------------------------------------------------------------------- %%% @doc %%% This module contains functi...
null
https://raw.githubusercontent.com/onedata/op-worker/c3e0d43fb99da2f1e87f184d463a3119e5995538/src/modules/automation/task/atm_task_execution_status.erl
erlang
------------------------------------------------------------------- @end ------------------------------------------------------------------- @doc This module contains functions that handle atm task execution status transitions according (with some exceptions described below) to following state machine: ...
@author ( C ) 2021 - 2022 ACK CYFRONET AGH This software is released under the MIT license cited in ' LICENSE.txt ' . Task transition to STOPPING status when execution is halted and not all items were processed . from ACTIVE to stopped status can be done during one update operation ) - although 1 * - f...
d6985997825250b1843afd9e4bc53e2a1a8d14f71554d421b9b3db5a1106a292
racket/compatibility
zip.rkt
#lang racket/base ;; deprecated library, see `file/zip` (require file/zip) (provide (all-from-out file/zip))
null
https://raw.githubusercontent.com/racket/compatibility/492030dac6f095045ce8a13dca75204dd5f34e32/compatibility-lib/mzlib/zip.rkt
racket
deprecated library, see `file/zip`
#lang racket/base (require file/zip) (provide (all-from-out file/zip))