_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
1ac7c97c3cdf238d5ee438f475c2fa1d71614063c6ea4032791812268ce987f9
dannywillems/RML
action.ml
exception Undefined_action of string type t = Eval | Subtype | Typing let t_of_string = function | "eval" -> Eval | "subtype" -> Subtype | "typing" -> Typing | s -> raise (Undefined_action s) let available = ["subtype"; "typing"]
null
https://raw.githubusercontent.com/dannywillems/RML/6f34748a4ea0b44037519d67200850acf6067481/src/action.ml
ocaml
exception Undefined_action of string type t = Eval | Subtype | Typing let t_of_string = function | "eval" -> Eval | "subtype" -> Subtype | "typing" -> Typing | s -> raise (Undefined_action s) let available = ["subtype"; "typing"]
dac244c6cc47a51fbba36a2abfb780b74ceae5a48a4652f76e7b9bd0e4583595
unnohideyuki/bunny
sample237.hs
f :: Int -> Either Int [Char] f 0 = Left 0 f 1 = Left 2 f 2 = Right "abc" f _ = Right "abcd" main = do print $ f 0 print $ f 1 print $ f 2 print $ f 3 print $ f 0 == f 0 print $ f 0 <= f 1 print $ f 0 <= f 2 print $ f 2 <= f 2 print $ f 2 <= f 3
null
https://raw.githubusercontent.com/unnohideyuki/bunny/501856ff48f14b252b674585f25a2bf3801cb185/compiler/test/samples/sample237.hs
haskell
f :: Int -> Either Int [Char] f 0 = Left 0 f 1 = Left 2 f 2 = Right "abc" f _ = Right "abcd" main = do print $ f 0 print $ f 1 print $ f 2 print $ f 3 print $ f 0 == f 0 print $ f 0 <= f 1 print $ f 0 <= f 2 print $ f 2 <= f 2 print $ f 2 <= f 3
63c1f11867c2d08dd495199b38fe1d2d2a2c638a473b9872e1a8d1c96e13faf4
RyanHope/ACT-R
paired-learning.lisp
(defvar *response* nil) (defvar *response-time* nil) (defvar *model-doing-task* nil) (defvar *pairs* '(("bank" "0") ("card" "1") ("dart" "2") ("face" "3") ("game" "4") ("hand" "5") ("jack" "6") ("king" "7") ("lamb" "8") ("mask" "9") ("neck" "0") ("pipe" "1") ("quip" "2") ("rope" "3"...
null
https://raw.githubusercontent.com/RyanHope/ACT-R/c65f3fe7057da0476281ad869c7963c84c0ad735/tutorial/unit7/paired-learning.lisp
lisp
return the list of scores
(defvar *response* nil) (defvar *response-time* nil) (defvar *model-doing-task* nil) (defvar *pairs* '(("bank" "0") ("card" "1") ("dart" "2") ("face" "3") ("game" "4") ("hand" "5") ("jack" "6") ("king" "7") ("lamb" "8") ("mask" "9") ("neck" "0") ("pipe" "1") ("quip" "2") ("rope" "3"...
27c56af2cfc8497c483ba67631b72a68d249747f8680094cf00e0adaa37085a9
nponeccop/HNC
Code.hs
# OPTIONS_GHC -fno - warn - unused - matches # module Code ( C ( .. ) , St ( .. ) , eval0 , res ) where module SPL.Code (C (..), St (..), eval, res) where import qualified Data.Map as M import SPL.Types -- eval eval a@(CF n) e = a eval a@(CNum n) e = a eval a@(CStr s) e = a eval a@(CBool n) e = a eval a@(CList l) e ...
null
https://raw.githubusercontent.com/nponeccop/HNC/d8447009a04c56ae2cba4c7c179e39384085ea00/SPL/Code.hs
haskell
eval reduce apply put struct where other eval a@(CL c R) e = eval c (putp ["_f"] [a] e)
# OPTIONS_GHC -fno - warn - unused - matches # module Code ( C ( .. ) , St ( .. ) , eval0 , res ) where module SPL.Code (C (..), St (..), eval, res) where import qualified Data.Map as M import SPL.Types eval a@(CF n) e = a eval a@(CNum n) e = a eval a@(CStr s) e = a eval a@(CBool n) e = a eval a@(CList l) e = a eval...
5c67c1cbf322053a879bc80b83f201ac531db005a25fe34207daa6e2c9e9deb7
hpyhacking/openpoker
protocol.erl
-module(protocol). -export([read/1, write/1]). -export([loop/2]). -export([id_to_player/1, id_to_game/1]). -import(pickle, [ pickle/2, unpickle/2, wrap/2, tuple/1, record/2, byte/0, short/0, int/0, list/2, binary/1, string/0]). -include("openpoker.hrl"). -define(int, int()). -define(byte, byte()). -define(s...
null
https://raw.githubusercontent.com/hpyhacking/openpoker/643193c94f34096cdcfcd610bdb1f18e7bf1e45e/src/protocol.erl
erlang
扑克牌使用short类型,占16位,通过位运算得到 高8位代表扑克数值大小,低8位代表扑克的花色类型 private AUTO GENERATE - Don't edit manual read binary to protocol record write protocol record to binary
-module(protocol). -export([read/1, write/1]). -export([loop/2]). -export([id_to_player/1, id_to_game/1]). -import(pickle, [ pickle/2, unpickle/2, wrap/2, tuple/1, record/2, byte/0, short/0, int/0, list/2, binary/1, string/0]). -include("openpoker.hrl"). -define(int, int()). -define(byte, byte()). -define(s...
18d38321a5328a12456eb2bdad8c37d32948b8481741526966a3530dfe480ff6
haskell-tools/haskell-tools
ExplicitTypeApplication.hs
# LANGUAGE TypeApplications # module Type.ExplicitTypeApplication where quad :: a -> b -> c -> d -> (a, b, c, d) quad w x y z = (w, x, y, z) foo = quad @Bool @_ @Int False 'c' 17 "Hello!"
null
https://raw.githubusercontent.com/haskell-tools/haskell-tools/b1189ab4f63b29bbf1aa14af4557850064931e32/src/refactor/examples/Type/ExplicitTypeApplication.hs
haskell
# LANGUAGE TypeApplications # module Type.ExplicitTypeApplication where quad :: a -> b -> c -> d -> (a, b, c, d) quad w x y z = (w, x, y, z) foo = quad @Bool @_ @Int False 'c' 17 "Hello!"
a8ac83fe6480cbb768fb03dd363460dd1f6d639467c4bbf189b32722b60a59e2
day8/re-com
simple_v_table.cljs
(ns re-demo.simple-v-table (:require-macros [re-com.core :refer []]) (:require [re-com.core :refer [at h-box gap v-box p line horizontal-tabs]] [re-com.simple-v-table :refer [simple-v-table-parts-desc simple-v-table-args-desc]] [re-...
null
https://raw.githubusercontent.com/day8/re-com/28351d751ff71ab88cad9f1f70ea7a664ace683c/src/re_demo/simple_v_table.cljs
clojure
(ns re-demo.simple-v-table (:require-macros [re-com.core :refer []]) (:require [re-com.core :refer [at h-box gap v-box p line horizontal-tabs]] [re-com.simple-v-table :refer [simple-v-table-parts-desc simple-v-table-args-desc]] [re-...
1e591efe7bedc2de3ba0f8b67c04131a55248d65cba2024b2e8e858bfc1b0237
WhatsApp/eqwalizer
map.erl
Copyright ( c ) Meta Platforms , Inc. and affiliates . All rights reserved . %%% This source code is licensed under the Apache 2.0 license found in %%% the LICENSE file in the root directory of this source tree. -module(map). -eqwalizer_unchecked([]). -export_type([map_/2]). -export([empty/0, get/2, ...
null
https://raw.githubusercontent.com/WhatsApp/eqwalizer/9935940d71ef65c7bf7a9dfad77d89c0006c288e/eqwalizer/test_projects/elm_core/src/map.erl
erlang
the LICENSE file in the root directory of this source tree.
Copyright ( c ) Meta Platforms , Inc. and affiliates . All rights reserved . This source code is licensed under the Apache 2.0 license found in -module(map). -eqwalizer_unchecked([]). -export_type([map_/2]). -export([empty/0, get/2, member/2, size/1, is_empty/1, inse...
692a21af212fa8353a1235bfc44fb341b7472f6db6047fbb9786090fbf1b7558
jiangpengnju/htdp2e
a-glimpse-at-parsing.rkt
The first three lines of this file were inserted by . They record metadata ;; about the language level of this file in a form that our tools can easily process. #reader(lib "htdp-intermediate-lambda-reader.ss" "lang")((modname a-glimpse-at-parsing) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constru...
null
https://raw.githubusercontent.com/jiangpengnju/htdp2e/d41555519fbb378330f75c88141f72b00a9ab1d3/generative-recursion/variations-on-the-theme/a-glimpse-at-parsing.rkt
racket
about the language level of this file in a form that our tools can easily process. – '() – (cons 1String File) interpretation: "\n" represents the newline character A Line is [List-of 1String] File -> [List-of Line] converts a file into a list of lines File -> Line File -> File
The first three lines of this file were inserted by . They record metadata #reader(lib "htdp-intermediate-lambda-reader.ss" "lang")((modname a-glimpse-at-parsing) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #f #t none #f () #f))) A File is one of : – ( cons " \n " ...
ef9371bbbd5e4c8473ceaa4aff6dfc2c635c4fa65c06695af45b8573e53df610
ghc/packages-Cabal
Async.hs
{-# LANGUAGE CPP #-} {-# LANGUAGE DeriveDataTypeable #-} | ' Async ' , yet using ' MVar 's . -- -- Adopted from @async@ library Copyright ( c ) 2012 , -- Licensed under BSD-3-Clause -- @since 3.2.0.0 -- module Distribution.Compat.Async ( AsyncM, withAsync, waitCatch, wait, asyncThread...
null
https://raw.githubusercontent.com/ghc/packages-Cabal/6f22f2a789fa23edb210a2591d74ea6a5f767872/Cabal/Distribution/Compat/Async.hs
haskell
# LANGUAGE CPP # # LANGUAGE DeriveDataTypeable # Adopted from @async@ library Licensed under BSD-3-Clause # UNPACK # ^ Returns the 'ThreadId' of the thread running the given 'Async'. | Spawn an asynchronous action in a separate thread, and pass its @Async@ handle to the supplied function. When ...
| ' Async ' , yet using ' MVar 's . Copyright ( c ) 2012 , @since 3.2.0.0 module Distribution.Compat.Async ( AsyncM, withAsync, waitCatch, wait, asyncThreadId, cancel, uninterruptibleCancel, AsyncCancelled (..), * extras withAsyncNF, ) where import Control.Concurrent (ThreadId, ...
c6748355e23db9bcf9daa0e7d8a05865f77de176d5b0737ffd87027291f663e9
rudymatela/tankode
chaserIII.hs
import Tankode.Basic import Data.Maybe (isJust) import Debug.Trace ident :: Id ident = Id { name = "chaser" , trackColour = "magenta1" , bodyColour = "magenta3" , gunColour = "grey7" , radarColour = "grey1" , bulletColour = "grey9" , scanColour = "magenta1" } data State = State { seenEnemy ...
null
https://raw.githubusercontent.com/rudymatela/tankode/299ec6f78a9a18a8fc902be911a556d0497c30e1/haskell/eg/chaserIII.hs
haskell
import Tankode.Basic import Data.Maybe (isJust) import Debug.Trace ident :: Id ident = Id { name = "chaser" , trackColour = "magenta1" , bodyColour = "magenta3" , gunColour = "grey7" , radarColour = "grey1" , bulletColour = "grey9" , scanColour = "magenta1" } data State = State { seenEnemy ...
21e1f0fe8ca31541ba8e9cc1e77c425d9b6a35be1636d9dbba8f3342463ed72d
SimulaVR/godot-haskell
PacketPeerGDNative.hs
# LANGUAGE DerivingStrategies , GeneralizedNewtypeDeriving , TypeFamilies , TypeOperators , FlexibleContexts , DataKinds , MultiParamTypeClasses # TypeFamilies, TypeOperators, FlexibleContexts, DataKinds, MultiParamTypeClasses #-} module Godot.Core.PacketPeerGDNative () where import Data.Coerce import Forei...
null
https://raw.githubusercontent.com/SimulaVR/godot-haskell/e8f2c45f1b9cc2f0586ebdc9ec6002c8c2d384ae/src/Godot/Core/PacketPeerGDNative.hs
haskell
# LANGUAGE DerivingStrategies , GeneralizedNewtypeDeriving , TypeFamilies , TypeOperators , FlexibleContexts , DataKinds , MultiParamTypeClasses # TypeFamilies, TypeOperators, FlexibleContexts, DataKinds, MultiParamTypeClasses #-} module Godot.Core.PacketPeerGDNative () where import Data.Coerce import Forei...
6cfc6435fac80a5068bee6bacf71640df817d31056d180aaa1edbdd834ba7461
jjtolton/rocinante
events.cljs
(ns {{base}}.lib.events (:require [{{base}}.lib.utils :as utils] [{{base}}.lib.events.init :as init] [{{base}}.lib.events.notify :as notify] [{{base}}.lib.events.items :as items] [{{base}}.lib.events.data :as data])) (defmulti event utils/event-type) (defmethod event ...
null
https://raw.githubusercontent.com/jjtolton/rocinante/625b1c5309b7f01d9f48af8d4df8f55b1ee97158/src/clj/new/rocinante/src/cljs/base/lib/events.cljs
clojure
(ns {{base}}.lib.events (:require [{{base}}.lib.utils :as utils] [{{base}}.lib.events.init :as init] [{{base}}.lib.events.notify :as notify] [{{base}}.lib.events.items :as items] [{{base}}.lib.events.data :as data])) (defmulti event utils/event-type) (defmethod event ...
fe3f80a1f61208d36fbc412ea601cb059cf6b582bd5a6edfccc67237756108ee
brownplt/pyret-docs
sets.js.rkt
#lang scribble/base @(require "../../scribble-api.rkt") @docmodule["sets"]{ @; Unknown: PLEASE DOCUMENT @ignore[(list "set" "list-set" "tree-set" "empty-list-set" "empty-tree-set")] @section[#:tag "sets_Functions"]{Functions} @function["list-to-list-set"] @function["list-to-tree-set"] }
null
https://raw.githubusercontent.com/brownplt/pyret-docs/a7aad4c6432e6863b3a3a7a6adb4aedfc6c7ca0d/src/trove/sets.js.rkt
racket
Unknown: PLEASE DOCUMENT
#lang scribble/base @(require "../../scribble-api.rkt") @docmodule["sets"]{ @ignore[(list "set" "list-set" "tree-set" "empty-list-set" "empty-tree-set")] @section[#:tag "sets_Functions"]{Functions} @function["list-to-list-set"] @function["list-to-tree-set"] }
837006d1e4431d942f1e70ecfc2b8df6f152f32b8ad3ffa53a56c12b80c35384
marijnh/Postmodern
package.lisp
-*- Mode : LISP ; Syntax : Ansi - Common - Lisp ; Base : 10 ; Package : CL - USER ; -*- (defpackage :postmodern (:use #-postmodern-use-mop :common-lisp #+postmodern-use-mop :closer-common-lisp :s-sql :cl-postgres) (:nicknames :pomo) #+postmodern-use-mop (:export #:dao-class #:dao-exists-p ...
null
https://raw.githubusercontent.com/marijnh/Postmodern/3c636d5c30d663c7bb8b99d0b0191a8f3f93a49f/postmodern/package.lisp
lisp
Syntax : Ansi - Common - Lisp ; Base : 10 ; Package : CL - USER ; -*- Prepared Statement Functions Reduced S-SQL interface Condition type from cl-postgres Utility Functions columns constraints database-management extensions functions indices keys roles deprecated schemas sequences tables tablespaces ...
(defpackage :postmodern (:use #-postmodern-use-mop :common-lisp #+postmodern-use-mop :closer-common-lisp :s-sql :cl-postgres) (:nicknames :pomo) #+postmodern-use-mop (:export #:dao-class #:dao-exists-p #:dao-keys #:query-dao #:select-dao #:get-dao #:fetch-defaults #:do-query-dao #:do-s...
2f8f75839455fc44c6b7455a1f0826427f8c1455540e44c51b55cfd1268784b3
ruanpienaar/goanna
goanna_api.erl
-module (goanna_api). -compile({no_auto_import,[nodes/0]}). Control Api -export([ start/0, stop/0, add_node/2, add_node/3, add_node_callbacks/2, add_node_callbacks/3, remove_node/1, remove_goanna_node/1, remove_goanna_callbacks/1, nodes/0, update_default_trace_options/1, ...
null
https://raw.githubusercontent.com/ruanpienaar/goanna/52d75566fd6f9760fbdebe53b2ca3c82fdb44e01/src/goanna_api.erl
erlang
trace_modules/1, recv_trace/2, Traces ------------------------------------------------------------------------ ------------------------------------------------------------------------ ------------------------------------------------------------------------ API TODO: implement file TYPE TODO: check callbacks if p...
-module (goanna_api). -compile({no_auto_import,[nodes/0]}). Control Api -export([ start/0, stop/0, add_node/2, add_node/3, add_node_callbacks/2, add_node_callbacks/3, remove_node/1, remove_goanna_node/1, remove_goanna_callbacks/1, nodes/0, update_default_trace_options/1, ...
dea072793a98fefc7cd77a6a1e8cfde1cd2082a4c47ef3fdd2cbded307c11bb5
patricoferris/ocaml-multicore-monorepo
caqti_async.mli
Copyright ( C ) 2014 - -2019 < > * * This library is free software ; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation , either version 3 of the License , or ( at your * option ) any later version , w...
null
https://raw.githubusercontent.com/patricoferris/ocaml-multicore-monorepo/22b441e6727bc303950b3b37c8fbc024c748fe55/duniverse/ocaml-caqti/lib-async/caqti_async.mli
ocaml
* Connector for Async.
Copyright ( C ) 2014 - -2019 < > * * This library is free software ; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation , either version 3 of the License , or ( at your * option ) any later version , w...
908e6cc3a3df037e4d4f1ea67a8ae53456107396b8fbcaf3a114268f5ebacd70
incjung/cl-swagger-codegen
cal-api-client.lisp
(ql:quickload "drakma") (ql:quickload "cl-json") (defun rest-call (host url-path &key params content basic-authorization (method :get) (accept "application/json") (content-type "application/json")) "call http-request with basic params and ...
null
https://raw.githubusercontent.com/incjung/cl-swagger-codegen/23bd1d2e895cccb5a87b5a2a2798e404798e1527/example/cal-api-client.lisp
lisp
Creates a secondary calendar. * path-url : /calendars Returns metadata for a calendar. * path-url : /calendars/{calendarId} Returns the rules in the access control list for the calendar. * path-url : /calendars/{calendarId}/acl Creates an access control rule. * path-url : /calendars/{calendarId}/acl W...
(ql:quickload "drakma") (ql:quickload "cl-json") (defun rest-call (host url-path &key params content basic-authorization (method :get) (accept "application/json") (content-type "application/json")) "call http-request with basic params and ...
40d63ef0b220d165cf8497dd7a641bd2aa19649a3f4c0b716195a19923475241
seanomlor/programming-in-haskell
seqn.hs
seqn :: Monad m => [m a] -> m [a] seqn [] = return [] seqn (act:acts) = do x <- act xs <- seqn acts return (x : xs)
null
https://raw.githubusercontent.com/seanomlor/programming-in-haskell/e05142e6709eeba2e95cf86f376a32c9e629df88/01-introduction/seqn.hs
haskell
seqn :: Monad m => [m a] -> m [a] seqn [] = return [] seqn (act:acts) = do x <- act xs <- seqn acts return (x : xs)
552dfe02447ac1121947b16d1d81bf5635fbb9f85906236e906409fb811b0635
composewell/streamly
MkType.hs
# LANGUAGE TemplateHaskell # # LANGUAGE QuasiQuotes # -- | Module : Streamly . Internal . Data . Stream . MkType Copyright : ( c ) 2022 Composewell Technologies -- License : BSD-3-Clause -- Maintainer : -- Stability : experimental Portability : GHC -- module Streamly.Internal.Data.Stream.MkType ...
null
https://raw.githubusercontent.com/composewell/streamly/8629a0e806f5eea87d23650c540aa04176f25c43/src/Streamly/Internal/Data/Stream/MkType.hs
haskell
| License : BSD-3-Clause Maintainer : Stability : experimental * Imports for Examples $setup * Re-exports ------------------------------------------------------------------------------ Imports ------------------------------------------------------------------------------ $setup >>> :m ---------------...
# LANGUAGE TemplateHaskell # # LANGUAGE QuasiQuotes # Module : Streamly . Internal . Data . Stream . MkType Copyright : ( c ) 2022 Composewell Technologies Portability : GHC module Streamly.Internal.Data.Stream.MkType ( * Template mkZipType , mkCrossType , MonadIO(..) , Monad...
adfaec34fb6b9447ddc7aea7fa6d5510385a4658d9d6acc69bd3d47a9c1c57ad
exercism/racket
atbash-cipher-test.rkt
#lang racket/base Tests adapted from canonical-data.json v1.2.0 (require "atbash-cipher.rkt") (module+ test (require rackunit rackunit/text-ui) (run-tests (test-suite "atbash-cipher encode tests" (test-equal? "encode yes" (encode "yes") "...
null
https://raw.githubusercontent.com/exercism/racket/4110268ed331b1b4dac8888550f05d0dacb1865b/exercises/practice/atbash-cipher/atbash-cipher-test.rkt
racket
#lang racket/base Tests adapted from canonical-data.json v1.2.0 (require "atbash-cipher.rkt") (module+ test (require rackunit rackunit/text-ui) (run-tests (test-suite "atbash-cipher encode tests" (test-equal? "encode yes" (encode "yes") "...
b0bd00dce240ca7aa7372706cc9bcea253e4fdf54a6534faeb138a7ab4e1615c
OCADml/ppx_deriving_cad
ppx_deriving_scad_test.ml
open Base open OCADml open OSCADml type vec_pair = { reg : V3.t ; unit : V3.t [@cad.unit] } [@@deriving cad] type with_ignored = { vector : V3.t ; ignored : int [@cad.ignore] } [@@deriving cad] module ScadVec : sig type t = { scad : Scad.d3 ; vec_pair : vec_pair } [@@deriving cad] end = s...
null
https://raw.githubusercontent.com/OCADml/ppx_deriving_cad/6dc3a2a248ef8a9f1e70ba5a69d470ef7c082b4e/test/ppx_deriving_scad_test.ml
ocaml
aliased to avoid generating option map expression (test map function finding)
open Base open OCADml open OSCADml type vec_pair = { reg : V3.t ; unit : V3.t [@cad.unit] } [@@deriving cad] type with_ignored = { vector : V3.t ; ignored : int [@cad.ignore] } [@@deriving cad] module ScadVec : sig type t = { scad : Scad.d3 ; vec_pair : vec_pair } [@@deriving cad] end = s...
d15cc403ca26b8e3212b945f50de23390a17f3bffc3dd816e5ece3fcb51cbe0e
jacekschae/learn-reitit-course-files
test_system.clj
(ns cheffy.test-system (:require [clojure.test :refer :all] [integrant.repl.state :as state] [ring.mock.request :as mock] [muuntaja.core :as m] [cheffy.auth0 :as auth0] [clj-http.client :as http])) (defn get-test-token [email] (->> {:content-type :json ...
null
https://raw.githubusercontent.com/jacekschae/learn-reitit-course-files/c13a8eb622a371ad719d3d9023f1b4eff9392e4c/increments/52-list-messages/test/cheffy/test_system.clj
clojure
(ns cheffy.test-system (:require [clojure.test :refer :all] [integrant.repl.state :as state] [ring.mock.request :as mock] [muuntaja.core :as m] [cheffy.auth0 :as auth0] [clj-http.client :as http])) (defn get-test-token [email] (->> {:content-type :json ...
39013f34ce28defaf36d97c53c3b3e66213f7b9d88746b8efe0cbafeffba9583
chef/chef-server
chef_object_default_callbacks.erl
-*- erlang - indent - level : 4;indent - tabs - mode : nil ; fill - column : 92-*- %% ex: ts=4 sw=4 et @author < > Copyright 2015 Chef Software , Inc. All Rights Reserved . %% This file is provided to you under the Apache License , %% Version 2.0 (the "License"); you may not use this file except in complia...
null
https://raw.githubusercontent.com/chef/chef-server/6d31841ecd73d984d819244add7ad6ebac284323/src/oc_erchef/apps/chef_objects/src/chef_object_default_callbacks.erl
erlang
ex: ts=4 sw=4 et Version 2.0 (the "License"); you may not use this file a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. We detect if...
-*- erlang - indent - level : 4;indent - tabs - mode : nil ; fill - column : 92-*- @author < > Copyright 2015 Chef Software , Inc. All Rights Reserved . This file is provided to you under the Apache License , except in compliance with the License . You may obtain software distributed under the License ...
ca4767882503f243dc81ec9e89c2fb625402d38d61fc0f1b43af426d452713fe
tud-fop/vanda-haskell
Earley_WSA.hs
----------------------------------------------------------------------------- -- | Copyright : ( c ) 2010 -- License : BSD-style -- Maintainer : < > -- Stability : unknown -- Portability : portable -- This module computes ' Hypergraph ' out of a ' Hypergraph ' and a ' WSA ' . The resultin...
null
https://raw.githubusercontent.com/tud-fop/vanda-haskell/3214966361b6dbf178155950c94423eee7f9453e/library/Vanda/Algorithms/Earley/Earley_WSA.hs
haskell
--------------------------------------------------------------------------- | License : BSD-style Stability : unknown Portability : portable This implementation uses the Early and the Bar-Hille algorithm. Variables in a production should start with 0. The list of nonterminals belonging to the variabl...
Copyright : ( c ) 2010 Maintainer : < > This module computes ' Hypergraph ' out of a ' Hypergraph ' and a ' WSA ' . The resulting ' Hypergraph ' will only recognize the given word . The input ' Hypergraph ' represents a synchronous contet - free grammar . module Vanda.Algorithms.Earley.Earley_...
bd25043943f44df75de074c50a13356fabbc4d10f857098e0e612a0534ab44a5
heraldry/heraldicon
router.cljs
(ns heraldicon.frontend.router (:require [clojure.string :as str] [heraldicon.frontend.account :as account] [heraldicon.frontend.contact :as contact] [heraldicon.frontend.home :as home] [heraldicon.frontend.library.arms.details :as library.arms.details] [heraldicon.frontend.library.arms.list :as lib...
null
https://raw.githubusercontent.com/heraldry/heraldicon/54e003614cf2c14cda496ef36358059ba78275b0/src/heraldicon/frontend/router.cljs
clojure
(ns heraldicon.frontend.router (:require [clojure.string :as str] [heraldicon.frontend.account :as account] [heraldicon.frontend.contact :as contact] [heraldicon.frontend.home :as home] [heraldicon.frontend.library.arms.details :as library.arms.details] [heraldicon.frontend.library.arms.list :as lib...
c48b482ba20949bc9714c9e0aa14a2e5a209aab1009923233719edf4e3592c4a
GaloisInc/daedalus
PathCondition.hs
# LANGUAGE DeriveGeneric # {-# LANGUAGE OverloadedStrings #-} module Talos.Strategy.PathCondition ( -- * Path Variables PathVar(..) , pathVarToSExpr -- * Path condition type , PathConditionInfo(..) , PathCondition(..) , PathConditionCaseInfo(..) -- * Operations , insertCase, insertChoice -- * Pre...
null
https://raw.githubusercontent.com/GaloisInc/daedalus/c7f2a6702157a699f88f2a374541dc3b64e106e8/talos/src/Talos/Strategy/PathCondition.hs
haskell
# LANGUAGE OverloadedStrings # * Path Variables * Path condition type * Operations * Predicates * Semantics ^ Case match path conditions. ^ We call these out separately as it is easy to figure out if the This is an optimisation, so an unsat guards may still be returned. ----------------------------------------...
# LANGUAGE DeriveGeneric # module Talos.Strategy.PathCondition PathVar(..) , pathVarToSExpr , PathConditionInfo(..) , PathCondition(..) , PathConditionCaseInfo(..) , insertCase, insertChoice , isInfeasible , isFeasibleMaybe , pcciSatisfied * Converstion to SExpr , toSExpr ) where import ...
8efab7d58045d124ec15d6720d11b9c9ff0e0d797d87a039a0e72bf7fb5cf3ce
bobzhang/fan
fGramDef.ml
open Astf let pp_print_loc _f _loc = () let pp_print_string = StdFan.pp_print_string let pp_print_vid' = Objs.pp_print_vid' let pp_print_vid = Objs.pp_print_vid let pp_print_alident = Objs.pp_print_alident let pp_print_ant = Objs.pp_print_ant class mapbase = object method loc (x : loc) = x method string (x :...
null
https://raw.githubusercontent.com/bobzhang/fan/7ed527d96c5a006da43d3813f32ad8a5baa31b7f/src/cold/fGramDef.ml
ocaml
open Astf let pp_print_loc _f _loc = () let pp_print_string = StdFan.pp_print_string let pp_print_vid' = Objs.pp_print_vid' let pp_print_vid = Objs.pp_print_vid let pp_print_alident = Objs.pp_print_alident let pp_print_ant = Objs.pp_print_ant class mapbase = object method loc (x : loc) = x method string (x :...
b66bc881a98de3b73d28fe404fe760e31dedb3aa0f7d8c11079af72e4f7c012a
evturn/haskellbook
ListyInstances.hs
module ListyInstances where import Data.Monoid import Listy instance Monoid (Listy a) where mempty = Listy [] mappend (Listy l) (Listy l') = Listy $ mappend l l'
null
https://raw.githubusercontent.com/evturn/haskellbook/3d310d0ddd4221ffc5b9fd7ec6476b2a0731274a/15/15.10-orphan-instance/ListyInstances.hs
haskell
module ListyInstances where import Data.Monoid import Listy instance Monoid (Listy a) where mempty = Listy [] mappend (Listy l) (Listy l') = Listy $ mappend l l'
5674a7122382c0e10393c0cc64280bdaa30da45a6780748052b2349cb2113665
Haskell-OpenAPI-Code-Generator/Stripe-Haskell-Library
GetProductsId.hs
{-# LANGUAGE ExplicitForAll #-} {-# LANGUAGE MultiWayIf #-} CHANGE WITH CAUTION : This is a generated code file generated by -OpenAPI-Code-Generator/Haskell-OpenAPI-Client-Code-Generator . {-# LANGUAGE OverloadedStrings #-} -- | Contains the different functions to run the operation getProductsId module StripeAPI.Ope...
null
https://raw.githubusercontent.com/Haskell-OpenAPI-Code-Generator/Stripe-Haskell-Library/ba4401f083ff054f8da68c741f762407919de42f/src/StripeAPI/Operations/GetProductsId.hs
haskell
# LANGUAGE ExplicitForAll # # LANGUAGE MultiWayIf # # LANGUAGE OverloadedStrings # | Contains the different functions to run the operation getProductsId | > GET /v1/products/{id} | Contains all available parameters of this operation (query and path parameters) | Monadic computation which returns the result of the ...
CHANGE WITH CAUTION : This is a generated code file generated by -OpenAPI-Code-Generator/Haskell-OpenAPI-Client-Code-Generator . module StripeAPI.Operations.GetProductsId where import qualified Control.Monad.Fail import qualified Control.Monad.Trans.Reader import qualified Data.Aeson import qualified Data.Aeson as ...
c0f67a4b8720ab39e65292444623776663ce47cfdf7cd77207881cb087557551
juxt/jig
project.clj
Copyright © 2013 , JUXT LTD . 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 to be b...
null
https://raw.githubusercontent.com/juxt/jig/3997887e5a56faadb1b48eccecbc7034b3d31e41/console/extensions/system-browser/project.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. ...
Copyright © 2013 , JUXT LTD . All Rights Reserved . Eclipse Public License 1.0 ( -1.0.php ) (load-file "project-header.clj") (def version (get-version)) (defproject jig.console/system-browser version :description "FIXME: write description" :url "" :license {:name "Eclipse Public License" :url "...
2655080515a4d079c86b3b1dd5bdf650f05b17df3568d645075c2a50497b7b27
BioHaskell/hPDB
ParseListRecord.hs
# LANGUAGE ScopedTypeVariables , NoMonomorphismRestriction , OverloadedStrings # | Parsing of records that contain simple list of values : KEYWDS , AUTHOR , MDLTYP , EXPDTA . module Bio.PDB.EventParser.ParseListRecord(parseKEYWDS,parseAUTHOR,parseMDLTYP,parseEXPDTA) where import Prelude hiding (String) import qua...
null
https://raw.githubusercontent.com/BioHaskell/hPDB/5be747e2f2c57370b498f4c11f9f1887fdab0418/Bio/PDB/EventParser/ParseListRecord.hs
haskell
Output data structure Helper methods | String type used all over the library. ------------- {{{ List containing records -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- } | Parses a record that contains...
# LANGUAGE ScopedTypeVariables , NoMonomorphismRestriction , OverloadedStrings # | Parsing of records that contain simple list of values : KEYWDS , AUTHOR , MDLTYP , EXPDTA . module Bio.PDB.EventParser.ParseListRecord(parseKEYWDS,parseAUTHOR,parseMDLTYP,parseEXPDTA) where import Prelude hiding (String) import qua...
82846deeaa78078e70aef4fb5c6162298b3230c29eb52047242d3f5881157ec3
GaloisInc/semmc
Special.hs
# LANGUAGE DataKinds # # LANGUAGE ImplicitParams # module SemMC.Architecture.PPC.Base.Special ( baseSpecial ) where import Prelude hiding ( concat ) import SemMC.DSL import SemMC.Architecture.PPC.Base.Core baseSpecial :: (?bitSize :: BitSize) => SemM 'Top () baseSpecial = do defineOpcodeWithIP "MTSPR" $ do ...
null
https://raw.githubusercontent.com/GaloisInc/semmc/4dc4439720b3b0de8812a68f8156dc89da76da57/semmc-ppc/src/SemMC/Architecture/PPC/Base/Special.hs
haskell
Check the number of bits set in the field ; if it is 1 , then we set that -- field. Otherwise, we are undefined. This is the mask we use to extract a new value from the source register
# LANGUAGE DataKinds # # LANGUAGE ImplicitParams # module SemMC.Architecture.PPC.Base.Special ( baseSpecial ) where import Prelude hiding ( concat ) import SemMC.DSL import SemMC.Architecture.PPC.Base.Core baseSpecial :: (?bitSize :: BitSize) => SemM 'Top () baseSpecial = do defineOpcodeWithIP "MTSPR" $ do ...
b376322acc6e5c6bf2b15867ddc7b9939ee674f6e9c357a45285926851c0d14a
BJTerry/mailchimp
Lists.hs
-- | -- Implements the \"lists\" section of the Mailchimp JSON API. -- module Web.Mailchimp.Lists ( -- * Mailchimp API Methods abuseReports , listActivity , batchSubscribe , batchUnsubscribe , clients , growthHistory , interestGroupAdd , interestGroupDelete , interestGroupUpdate , interestGro...
null
https://raw.githubusercontent.com/BJTerry/mailchimp/40ead48cf0e16c17dfaad63d4d74990c1cc79ae6/Web/Mailchimp/Lists.hs
haskell
| Implements the \"lists\" section of the Mailchimp JSON API. * Mailchimp API Methods * Parameter types * Result types | Represents an individual mailing list | The type of e-mail your user will receive | Subscribes a user to the given list. See <> for details. Example Usage: ^ The list to subscr...
module Web.Mailchimp.Lists ( abuseReports , listActivity , batchSubscribe , batchUnsubscribe , clients , growthHistory , interestGroupAdd , interestGroupDelete , interestGroupUpdate , interestGroupingAdd , interestGroupingDelete , interestGroupingUpdate , interestGroupings , listInfo ...
2c09eae81bd29416e28ccf3df3878691415d633f9284f877eba50fe32df122e0
morphismtech/squeal
Encode.hs
| Module : Squeal . PostgreSQL.Session . Encode Description : encoding of statement parameters Copyright : ( c ) , 2019 Maintainer : Stability : experimental encoding of statement parameters Module: Squeal.PostgreSQL.Session.Encode Description: encoding of statement parameters Copyright: (c) Eitan Cha...
null
https://raw.githubusercontent.com/morphismtech/squeal/37dd814d652a5ac03bccb6d75a622eeab7ff5b92/squeal-postgresql/src/Squeal/PostgreSQL/Session/Encode.hs
haskell
* Encode Parameters * Encoding Classes $setup | A `ToPG` constraint gives an encoding of a Haskell `Type` into into the binary format of a PostgreSQL `PGType`. | >>> :set -XTypeApplications -XDataKinds >>> runReaderT (toPG @'[] False) conn "\NUL" >>> runReaderT (toPG @'[] (0 :: Int16)) conn "\NUL\NUL" "\NU...
| Module : Squeal . PostgreSQL.Session . Encode Description : encoding of statement parameters Copyright : ( c ) , 2019 Maintainer : Stability : experimental encoding of statement parameters Module: Squeal.PostgreSQL.Session.Encode Description: encoding of statement parameters Copyright: (c) Eitan Cha...
8f0089b907e2d4ea189b92fa3098e9b1ebd1489bee1184ccb70323c4c7205fdc
tweag/ormolu
overly-indented.hs
tagCloudField :: String -- ^ Destination key -> Double -- ^ Smallest font size, in percent -> Double -- ^ Biggest font size, in percent -> Tags -- ^ Input tags -> Context a -- ^ Context...
null
https://raw.githubusercontent.com/tweag/ormolu/34bdf62429768f24b70d0f8ba7730fc4d8ae73ba/data/examples/other/overly-indented.hs
haskell
^ Destination key ^ Smallest font size, in percent ^ Biggest font size, in percent ^ Input tags ^ Context
tagCloudField :: String -> Double -> Double -> Tags -> Context a
f6fcbb8ef8ee95de37c99a2b6e9196d6ba13f0df4a75ac03cd687c1e2608c10f
nuty/vela
dispatcher.rkt
#lang racket/base (require racket/list racket/string racket/class web-server/http/request-structs web-server/servlet/servlet-structs (only-in web-server/servlet url->string) "context.rkt") (define (request->route-key req routers static-path static-url) (let* ([req-full-path (url->string (request-u...
null
https://raw.githubusercontent.com/nuty/vela/5998a2cf7101a9b98d91fce11c4c1d86f0f5a274/vela-lib/vela/dispatcher.rkt
racket
is static file url not handler url
#lang racket/base (require racket/list racket/string racket/class web-server/http/request-structs web-server/servlet/servlet-structs (only-in web-server/servlet url->string) "context.rkt") (define (request->route-key req routers static-path static-url) (let* ([req-full-path (url->string (request-u...
ac80ab990ea598a1ce639af21c3b7c1f444ac5d493c3c3c6e4c2fca3c531a1e9
kongo2002/statser
statser_listeners_parent.erl
Copyright 2017 - 2018 % Licensed under the Apache License , Version 2.0 ( the " License " ) ; % you may not use this file except in compliance with the License. % You may obtain a copy of the License at % % -2.0 % % Unless required by applicable law or agreed to in writing, software distributed under the Li...
null
https://raw.githubusercontent.com/kongo2002/statser/1cb0498f56c97d8a010b979c5163dd2750064e98/src/statser_listeners_parent.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 or implied. See the License for the specific language governing perm...
Copyright 2017 - 2018 Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(statser_listeners_parent). -behaviour(gen_server). -include("statser.hrl"). -export([start_link/1, start_listener/1]). -export([i...
d5e5a6353af02281df4007d409ab2303362834f658c84d59becd018d4c9e6afc
lemmaandrew/CodingBatHaskell
maxSpan.hs
From Consider the leftmost and righmost appearances of some value in an array . We 'll say that the \"span\ " is the number of elements between the two inclusive . A single value has a span of 1 . Returns the largest span found in the given array . ( Efficiency is not a priority . ) Consider the leftmost a...
null
https://raw.githubusercontent.com/lemmaandrew/CodingBatHaskell/d839118be02e1867504206657a0664fd79d04736/CodingBat/Array-3/maxSpan.hs
haskell
From Consider the leftmost and righmost appearances of some value in an array . We 'll say that the \"span\ " is the number of elements between the two inclusive . A single value has a span of 1 . Returns the largest span found in the given array . ( Efficiency is not a priority . ) Consider the leftmost a...
5eddc8b529b20905a64fa3e5e28be6bf79418db03ad05e6c3ce2d9f10e83d39b
fdopen/depext-cygwinports
cygwin.ml
let (|>) v f = f v exception Error of string type mingw_arch = | Mingw32 | Mingw64 type pkg = | Mingw of string | System of string type config = { cygwin_root: string; cygwin_arch: string; mingw_arch: mingw_arch; mirror_cygports: string; mirror_cygwin: string; } let re_newline = Str.regexp "\\([\...
null
https://raw.githubusercontent.com/fdopen/depext-cygwinports/b5fcee7057d48aec7a627f0e34a81e618088ae2c/cygwin.ml
ocaml
"-K" ; winpath key ;
let (|>) v f = f v exception Error of string type mingw_arch = | Mingw32 | Mingw64 type pkg = | Mingw of string | System of string type config = { cygwin_root: string; cygwin_arch: string; mingw_arch: mingw_arch; mirror_cygports: string; mirror_cygwin: string; } let re_newline = Str.regexp "\\([\...
5405be4bd2c7f1694b285d8f923518cf68a5af946500b10a24771feb8bb8f5b8
georgegarrington/Syphon
Util.hs
module AST.Util where import AST.Expression {- Given a function expression and the list of expressions that it is applied to obtained from parsing, turn them into an application data type -} --COULD PROBABLY DO WITH CHANGING LATER applicationify :: [Expr] -> Expr applicationify exprs = helper $ reverse $ exprs wher...
null
https://raw.githubusercontent.com/georgegarrington/Syphon/402a326b482e3ce627a15b651b3097c2e09e8a53/src/AST/Util.hs
haskell
Given a function expression and the list of expressions that it is applied to obtained from parsing, turn them into an application data type COULD PROBABLY DO WITH CHANGING LATER MAKE THIS NICER
module AST.Util where import AST.Expression applicationify :: [Expr] -> Expr applicationify exprs = helper $ reverse $ exprs where helper [fstArg, fun] = App fun fstArg helper (back:reversed) = App (helper reversed) back helper _ = error "I think you tried write a function expression without any arguments!\nC...
6d2a988f9d036c7ae5f264b9e5eba6ef3a95a6b18f99d25d9b621da2701f8a00
wireapp/wire-server
Internal.hs
-- This file is part of the Wire Server implementation. -- Copyright ( C ) 2022 Wire Swiss GmbH < > -- -- This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License...
null
https://raw.githubusercontent.com/wireapp/wire-server/ce4ecea4ac4894db1dcb3b5079fd9eff3ab726f4/services/galley/src/Galley/API/Internal.hs
haskell
This file is part of the Wire Server implementation. This program is free software: you can redistribute it and/or modify it under later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTI...
Copyright ( C ) 2022 Wire Swiss GmbH < > the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or ( at your option ) any You should have received a copy of the GNU Affero General Public License along module Galley.API.Internal ( i...
d089d3cb96440f780e06f01ff74cde44a85f33c97812d58279dd770c38b12c32
bsaleil/lc
dderiv.scm.scm
;;------------------------------------------------------------------------------ Macros (##define-macro (def-macro form . body) `(##define-macro ,form (let () ,@body))) (def-macro (FLOATvector-const . lst) `',(list->vector lst)) (def-macro (FLOATvector? x) `(vector? ,x)) (def-macro (FLOATvector . lst...
null
https://raw.githubusercontent.com/bsaleil/lc/ee7867fd2bdbbe88924300e10b14ea717ee6434b/tools/benchtimes/resultVMIL-lc-gsc-lc/LCnaive/dderiv.scm.scm
scheme
------------------------------------------------------------------------------ ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ Gabriel benchmarks C benchmarks Other benchmarks DDERIV -- Table-driven symboli...
Macros (##define-macro (def-macro form . body) `(##define-macro ,form (let () ,@body))) (def-macro (FLOATvector-const . lst) `',(list->vector lst)) (def-macro (FLOATvector? x) `(vector? ,x)) (def-macro (FLOATvector . lst) `(vector ,@lst)) (def-macro (FLOATmake-vector n . init) `(make-vector ,...
34fbe0a08e7af1a57a654e0ccaf9689ee58bcc67b98d5cafe88302d13f2d76b2
richmit/mjrcalc
use-char.lisp
;; -*- Mode:Lisp; Syntax:ANSI-Common-LISP; Coding:us-ascii-unix; fill-column:158 -*- ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; ;; @file use-char.lisp @author < > ;; @brief Charact...
null
https://raw.githubusercontent.com/richmit/mjrcalc/96f66d030034754e7d3421688ff201f4f1db4833/use-char.lisp
lisp
-*- Mode:Lisp; Syntax:ANSI-Common-LISP; Coding:us-ascii-unix; fill-column:158 -*- @file use-char.lisp @brief Character (ASCII & EBCIDIC) tools.@EOL@EOL @std Common Lisp @see tst-char.lisp Redistribution and use in source and binary forms, with or without modification, are permitted provid...
@author < > @parblock Copyright ( c ) 1998,2008,2011,2013,2015 , < > All rights reserved . 1 . Redistributions of source code must retain the above copyright notice , this list of conditions , and the following disclaimer . 2 . Redistributions in binary form must reproduce the above copyrigh...
9dcfecb2b06d584c3907d9c1b6df52f1324b82dad597ae883a7b2d71da277460
polymeris/cljs-aws
ssm.cljs
(ns cljs-aws.ssm (:require [cljs-aws.base.requests]) (:require-macros [cljs-aws.base.service :refer [defservice]])) (defservice "SSM" "ssm-2014-11-06.min.json")
null
https://raw.githubusercontent.com/polymeris/cljs-aws/3326e7c4db4dfc36dcb80770610c14c8a7fd0d66/src/cljs_aws/ssm.cljs
clojure
(ns cljs-aws.ssm (:require [cljs-aws.base.requests]) (:require-macros [cljs-aws.base.service :refer [defservice]])) (defservice "SSM" "ssm-2014-11-06.min.json")
d1b7cdd0db94a099c66767faee4f491811a4c7a5c10bc21372aa1ba7ee1d8bd1
TyOverby/mono
hello.ml
print_endline "Hello, world!"
null
https://raw.githubusercontent.com/TyOverby/mono/7666c0328d194bf9a569fb65babc0486f2aaa40d/vendor/janestreet-spawn/test/exe/hello.ml
ocaml
print_endline "Hello, world!"
3428533494fddbc085f1d531ba01cf71d3efd3f9fb6a41eeb5943c5da0d74805
IvanIvanov/fp2013
solution.scm
(define (filter pred l) (let loop ((sequence l) (filtered '())) (cond ((null? sequence) filtered) ((pred (car sequence)) (loop (cdr sequence) (append filtered (list (car sequence))))) (else (loop (cdr sequence) filtered))))) (define (inc x) (+ x 1)) (define (dec x) ...
null
https://raw.githubusercontent.com/IvanIvanov/fp2013/2ac1bb1102cb65e0ecbfa8d2fb3ca69953ae4ecf/lab4/homeworks/05/solution.scm
scheme
(define (filter pred l) (let loop ((sequence l) (filtered '())) (cond ((null? sequence) filtered) ((pred (car sequence)) (loop (cdr sequence) (append filtered (list (car sequence))))) (else (loop (cdr sequence) filtered))))) (define (inc x) (+ x 1)) (define (dec x) ...
ceff4ed38331f213f29ac935d9e4ac406d323182da00f2cd69bcf80d08814e1c
sgbj/MaximaSharp
dlasq6.lisp
;;; Compiled by f2cl version: ( " f2cl1.l , v 2edcbd958861 2012/05/30 03:34:52 toy $ " " f2cl2.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ " " f2cl3.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ " " f2cl4.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ " " f2cl5.l , v 3fe93de3be82 2012/05/06 02:17:14 toy ...
null
https://raw.githubusercontent.com/sgbj/MaximaSharp/75067d7e045b9ed50883b5eb09803b4c8f391059/Test/bin/Debug/Maxima-5.30.0/share/maxima/5.30.0/share/lapack/lapack/dlasq6.lisp
lisp
Compiled by f2cl version: Using Lisp CMU Common Lisp 20d (20D Unicode) Options: ((:prune-labels nil) (:auto-save t) (:relaxed-array-decls t) (:coerce-assigns :as-needed) (:array-type ':array) (:array-slicing t) (:declare-common nil) (:float-format double-float))
( " f2cl1.l , v 2edcbd958861 2012/05/30 03:34:52 toy $ " " f2cl2.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ " " f2cl3.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ " " f2cl4.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ " " f2cl5.l , v 3fe93de3be82 2012/05/06 02:17:14 toy $ " " f2cl6.l , v 1d5cbacbb...
f3b5873afca1a3231fe0b0ad1f20b01f1db4fd543255b98ebbadabf192e559a4
dcastro/haskell-flatbuffers
Display.hs
# LANGUAGE FlexibleInstances # module FlatBuffers.Internal.Compiler.Display where import Data.Int import qualified Data.List as List import Data.List.NonEmpty ( NonEmpty ) import qualified Data.List.NonEmpty as NE import qualified Data.Text as T import Data.Word -- | M...
null
https://raw.githubusercontent.com/dcastro/haskell-flatbuffers/cea6a75109de109ae906741ee73cbb0f356a8e0d/src/FlatBuffers/Internal/Compiler/Display.hs
haskell
| Maps a value of type @a@ into a string that can be displayed to the user. # OVERLAPPING #
# LANGUAGE FlexibleInstances # module FlatBuffers.Internal.Compiler.Display where import Data.Int import qualified Data.List as List import Data.List.NonEmpty ( NonEmpty ) import qualified Data.List.NonEmpty as NE import qualified Data.Text as T import Data.Word class ...
b2ed25b3009c53566aae6b8df597dfa07f7ab606334fb05c96f8c54702581977
skanev/playground
63.scm
SICP exercise 4.63 ; The following data base ( see Genesis 4 ) traces the genealogy of the descendants of back to , by way of : ; ( son ) ( son ) ( son ) ( son ) ( son ) ( son ) ( wife ) ( son ) ( son ) ; Formulate rules such as " If S is the son of F , and F is the son of...
null
https://raw.githubusercontent.com/skanev/playground/d88e53a7f277b35041c2f709771a0b96f993b310/scheme/sicp/04/63.scm
scheme
is the grandson of G" and "If W is the wife of M, and S is the son of W, then S is the son of M" (which was supposedly more true in biblical times the grandsons of . ( See exercise 4.69 for some rules to deduce more complicated relationships.)
SICP exercise 4.63 The following data base ( see Genesis 4 ) traces the genealogy of the descendants of back to , by way of : ( son ) ( son ) ( son ) ( son ) ( son ) ( son ) ( wife ) ( son ) ( son ) Formulate rules such as " If S is the son of F , and F is the son of G , t...
0166739957bf404b58b0de12bd12515da2ae8c20ae51256ae7772b9f5942731b
macchiato-framework/macchiato-template
app.cljs
(ns {{project-ns}}.app (:require [doo.runner :refer-macros [doo-tests]] [{{project-ns}}.core-test])) (doo-tests '{{project-ns}}.core-test)
null
https://raw.githubusercontent.com/macchiato-framework/macchiato-template/fff6f0cc640b43933d1e94c85a0b393e89cbe14d/resources/leiningen/new/macchiato/env/test/app.cljs
clojure
(ns {{project-ns}}.app (:require [doo.runner :refer-macros [doo-tests]] [{{project-ns}}.core-test])) (doo-tests '{{project-ns}}.core-test)
44db610850812b901f083b82de3376201d7c369c05e20a1afd1817baaee5e114
lmj/lparallel
suite.lisp
Copyright ( c ) 2011 - 2012 , . 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 li...
null
https://raw.githubusercontent.com/lmj/lparallel/9c11f40018155a472c540b63684049acc9b36e15/bench/suite.lisp
lisp
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary...
Copyright ( c ) 2011 - 2012 , . All rights reserved . " AS IS " AND ANY EXPRESS OR IMPLIED WARRANTIES , INCLUDING , BUT NOT HOLDER OR FOR ANY DIRECT , INDIRECT , INCIDENTAL , SPECIAL , EXEMPLARY , OR CONSEQUENTIAL DAMAGES ( INCLUDING , BUT NOT THEORY OF LIABILITY , WHETHER IN CONTRACT , STRICT LIABILITY...
70cb324b622427ea0cf63c0532d94ac342477f8124bfaab417b3d3aa49ff25fe
fishcakez/sbroker
sbroker_statem_statem.erl
%%------------------------------------------------------------------- %% Copyright ( c ) 2015 , < > %% This file is provided to you under the Apache License , %% Version 2.0 (the "License"); you may not use this file %% except in compliance with the License. You may obtain %% a copy of the License at %% %% -2.0 ...
null
https://raw.githubusercontent.com/fishcakez/sbroker/10f7e3970d0a296fbf08b1d1a94c88979a7deb5e/test/sbroker_statem_statem.erl
erlang
------------------------------------------------------------------- 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, KIND, either express or implied. See the Lic...
Copyright ( c ) 2015 , < > This file is provided to you under the Apache License , software distributed under the License is distributed on an " AS IS " BASIS , WITHOUT WARRANTIES OR CONDITIONS OF ANY -module(sbroker_statem_statem). -include_lib("proper/include/proper.hrl"). -export([module/0]). -export([a...
4415238bc9eb076c417bef9d8f4ec32edc27a01da34c349f0a0e675bcab4406c
kronkltd/jiksnu
referrant.clj
(ns jiksnu.referrant) (defonce this (ref {})) (defonce that (ref {})) (defn get-this [k] ;; (timbre/debugf "getting this %s" k) (get @this k)) (defn set-this [k v] ;; (timbre/debugf "setting this %s to %s" k (prn-str v)) (dosync (alter this assoc k v))) (defn get-that [k] ;; (timbre/debugf "getti...
null
https://raw.githubusercontent.com/kronkltd/jiksnu/8c91e9b1fddcc0224b028e573f7c3ca2f227e516/src/jiksnu/referrant.clj
clojure
(timbre/debugf "getting this %s" k) (timbre/debugf "setting this %s to %s" k (prn-str v)) (timbre/debugf "getting that %s" k) (timbre/debugf "setting that %s to %s" k (prn-str v))
(ns jiksnu.referrant) (defonce this (ref {})) (defonce that (ref {})) (defn get-this [k] (get @this k)) (defn set-this [k v] (dosync (alter this assoc k v))) (defn get-that [k] (get @that k)) (defn set-that [k v] (dosync (alter that assoc k v)))
5b1ed72b827d4b4c2d61950391559e28add2bf30eb2f9f80494a5c9fe48911cd
nuprl/gradual-typing-performance
type-env-ext.rkt
#lang racket/base (require typed-racket/utils/utils (prefix-in ce: test-engine/racket-tests) (for-syntax racket/base syntax/parse (utils tc-utils) (env init-envs) (except-in (rep filter-rep object-rep type-rep) make-arr) (rename-in (types abbrev numer...
null
https://raw.githubusercontent.com/nuprl/gradual-typing-performance/35442b3221299a9cadba6810573007736b0d65d4/pre-benchmark/ecoop/htdp-lib/typed/test-engine/type-env-ext.rkt
racket
test* insert-test builder check-values-expected check-values-within check-values-error check-range-values-expected check-member-of-values-expected
#lang racket/base (require typed-racket/utils/utils (prefix-in ce: test-engine/racket-tests) (for-syntax racket/base syntax/parse (utils tc-utils) (env init-envs) (except-in (rep filter-rep object-rep type-rep) make-arr) (rename-in (types abbrev numer...
64661587cd0eec52a3a90dc6690787b920cd4034ca2f681f6f12134d3b04053e
igrishaev/book-sessions
server_better.clj
(ns book.systems.mount.server-better (:require [mount.core :as mount :refer [defstate]] [ring.adapter.jetty :refer [run-jetty]] [book.systems.mount.config :refer [config]]) (:import org.eclipse.jetty.server.Server)) ;; config added ;; noop added (defn app [request] {:status 200 :headers {"con...
null
https://raw.githubusercontent.com/igrishaev/book-sessions/c62af1230e91b8ab9e4e456798e894d1b4145dfc/src/book/systems/mount/server_better.clj
clojure
config added noop added !!!
(ns book.systems.mount.server-better (:require [mount.core :as mount :refer [defstate]] [ring.adapter.jetty :refer [run-jetty]] [book.systems.mount.config :refer [config]]) (:import org.eclipse.jetty.server.Server)) (defn app [request] {:status 200 :headers {"content-type" "text/plain"} :b...
ca2f0c510d969cbad9c738224ace469781504ecc8171222097f987824df677dc
cblp/crdt
Counter.hs
# LANGUAGE FlexibleInstances # # LANGUAGE LambdaCase # # LANGUAGE MultiParamTypeClasses # # LANGUAGE TypeFamilies # module CRDT.Cm.Counter ( Counter (..) ) where import CRDT.Cm (CausalOrd (..), CmRDT (..)) data Counter a = Increment | Decrement deriving (Bounded, Enum, Eq, Show) instance (Num ...
null
https://raw.githubusercontent.com/cblp/crdt/175d7ee7df66de1f013ee167ac31719752e0c20b/crdt/lib/CRDT/Cm/Counter.hs
haskell
| Empty order, allowing arbitrary reordering
# LANGUAGE FlexibleInstances # # LANGUAGE LambdaCase # # LANGUAGE MultiParamTypeClasses # # LANGUAGE TypeFamilies # module CRDT.Cm.Counter ( Counter (..) ) where import CRDT.Cm (CausalOrd (..), CmRDT (..)) data Counter a = Increment | Decrement deriving (Bounded, Enum, Eq, Show) instance (Num ...
bdff76fb9e264a4a7212f22c6442555f8885489e2c91f512f00e5591ad0488c4
freuk/obandit
plugin.ml
let mathjax_header = "<script type=\"text/x-mathjax-config\">\n\ MathJax.Hub.Config({\n\ tex2jax:{\ inlineMath: [ ['$','$'], ['\\\\(','\\\\)'] ],\ displayMath: [ ['$$','$$'], ['\\\\[','\\\\]'] ]\ },\ TeX:{\ Macros: {\ argmax: '\\\\mathop{\\\\rm arg\\\\,max}\\\\limits',\ }\ }\...
null
https://raw.githubusercontent.com/freuk/obandit/0d8222c9e8dbb4b7f324290121bc45892620c783/doc/plugin.ml
ocaml
destructively modifies [header]
let mathjax_header = "<script type=\"text/x-mathjax-config\">\n\ MathJax.Hub.Config({\n\ tex2jax:{\ inlineMath: [ ['$','$'], ['\\\\(','\\\\)'] ],\ displayMath: [ ['$$','$$'], ['\\\\[','\\\\]'] ]\ },\ TeX:{\ Macros: {\ argmax: '\\\\mathop{\\\\rm arg\\\\,max}\\\\limits',\ }\ }\...
0bf8ddb559b5b828d04d8f8a96d87b884e05bdecffea9adb2adf5ed9af213dda
kendroe/CoqRewriter
derive.mli
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * REWRITELIB * * derive.mli * ...
null
https://raw.githubusercontent.com/kendroe/CoqRewriter/ddf5dc2ea51105d5a2dc87c99f0d364cf2b8ebf5/plugin/src/derive.mli
ocaml
require "exp.sml" ; require "env.sml" ;
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * REWRITELIB * * derive.mli * ...
fd8c28f7fe162f6cce07cfa87675f6ba0f38fc73e776249887d1deaed1f1082b
fpco/schoolofhaskell
Types.hs
module Types where import Control.Concurrent.STM (TChan) import Control.Lens (makeLenses, makePrisms, makeWrapped) import Data.IORef (IORef) import Data.Text (Text) import Data.Typeable (Typeable) import Data.Vector (Vector) import IdeSession.Types.Public import JavaScript.Ace (Editor, Range, MarkerId) import JavaScri...
null
https://raw.githubusercontent.com/fpco/schoolofhaskell/171454d255f57bb9ab82974625501e964c8c9b96/soh-client/src/Types.hs
haskell
| The application state. Ideally, this would entirely consist of pure data. However, for simplicity and efficiency it also contains some references to mutable javascript objects. These fields, currently those which involve 'Unmanaged' and 'Backend', are mutated on initialization, and otherwise always point to ...
module Types where import Control.Concurrent.STM (TChan) import Control.Lens (makeLenses, makePrisms, makeWrapped) import Data.IORef (IORef) import Data.Text (Text) import Data.Typeable (Typeable) import Data.Vector (Vector) import IdeSession.Types.Public import JavaScript.Ace (Editor, Range, MarkerId) import JavaScri...
e65bf9de160dd77e404d0ba24e519bd19708d335842f2e18cd1a7d60b0f3c757
bhauman/cljs-test-display
core.clj
(ns cljs-test-display.core (:require [clojure.java.io :as io])) (defmacro css [] (slurp (io/resource "public/com/bhauman/cljs-test-display/css/style.css")))
null
https://raw.githubusercontent.com/bhauman/cljs-test-display/727a08d298b1ce380de4c8f0145254b95eb957cd/src/cljs_test_display/core.clj
clojure
(ns cljs-test-display.core (:require [clojure.java.io :as io])) (defmacro css [] (slurp (io/resource "public/com/bhauman/cljs-test-display/css/style.css")))
57f95f50269f62beee6834494fada9601e53793a4ac9eee8a04dd0cb94a33f74
unifydb/unifydb
memory.clj
(ns unifydb.messagequeue.memory (:require [manifold.bus :as bus] [manifold.deferred :as d] [manifold.stream :as s] [unifydb.messagequeue :as q])) (defn group-key "Returns the keyword that identifies the group designated by `queue` and `group-id` in (:groups @state)." [qu...
null
https://raw.githubusercontent.com/unifydb/unifydb/10dd5a5663e0d4db94cd71ee3c8e1784f86ff052/src/unifydb/messagequeue/memory.clj
clojure
(ns unifydb.messagequeue.memory (:require [manifold.bus :as bus] [manifold.deferred :as d] [manifold.stream :as s] [unifydb.messagequeue :as q])) (defn group-key "Returns the keyword that identifies the group designated by `queue` and `group-id` in (:groups @state)." [qu...
5dc5a867f5e0b02c5cd383333c45aa659f6caec75ee83e48420e59931e5e0466
Ejhfast/Proof-Search
ProofSearch.hs
module ProofSearch where import Prelude import List import Debug.Trace import qualified Data.Map as Map import ProofTypes import ProofParse import ProofFuncs sub_depth_level = 12 -- Search depth for subexpressions --test for consisent substitutions consistent_subs :: [(Stmt String, Stmt String)] -> [(Stmt String, Stm...
null
https://raw.githubusercontent.com/Ejhfast/Proof-Search/45557c7ffb0337a414fb6b0be07610abb96c2551/ProofSearch.hs
haskell
Search depth for subexpressions test for consisent substitutions (e == e1 && f /= f1) || try to match a statement to a rule condition, return mapping of substitutions hack for unary operations inconsistent substitutions not the same operator should not a Free in statements Replace free variables in a statement as ...
module ProofSearch where import Prelude import List import Debug.Trace import qualified Data.Map as Map import ProofTypes import ProofParse import ProofFuncs consistent_subs :: [(Stmt String, Stmt String)] -> [(Stmt String, Stmt String)] -> Bool consistent_subs lhs rhs = if (sum bad_matches) == 0 then True else False...
b9f30bc267161a7a7e0eb83eb06b3c2faac2819d8b72528f5a96cd35594bdb2a
pascal-knodel/haskell-craft
E'8'21.hs
-- -- -- ----------------- Exercise 8.21 . ----------------- -- -- -- module E'8'21 where import B'C'8 ( Tournament ) import E'8''2 ( tournamentOutcome ) showTournament :: Tournament -> String showTournament tournament = "Game:\n\n" ++ showTournament' tournament ++ "\n" ++ "Score, player 1: " ++...
null
https://raw.githubusercontent.com/pascal-knodel/haskell-craft/c03d6eb857abd8b4785b6de075b094ec3653c968/Chapter%208/E'8'21.hs
haskell
--------------- --------------- Game: P S R R P S R R P S R R P S R R P S R R
Exercise 8.21 . module E'8'21 where import B'C'8 ( Tournament ) import E'8''2 ( tournamentOutcome ) showTournament :: Tournament -> String showTournament tournament = "Game:\n\n" ++ showTournament' tournament ++ "\n" ++ "Score, player 1: " ++ score_1 ++ "\n" ++ " \" \" 2: " ++ score...
8a6b780b5748111b131e00545783f9414ac24f0f06567d80ca03d9c64aeff3bc
ronxin/stolzen
ex3.7.scm
#lang scheme (require rackunit) (define (make-account balance password) (define passwords (list password)) (define (withdraw amount) (if (>= balance amount) (begin (set! balance (- balance amount)) balance) "Insufficient funds" ) ) ...
null
https://raw.githubusercontent.com/ronxin/stolzen/bb13d0a7deea53b65253bb4b61aaf2abe4467f0d/sicp/chapter3/3.1/ex3.7.scm
scheme
#lang scheme (require rackunit) (define (make-account balance password) (define passwords (list password)) (define (withdraw amount) (if (>= balance amount) (begin (set! balance (- balance amount)) balance) "Insufficient funds" ) ) ...
0f224ca5fd948f139c23d9e860bebbddece9364440a3e86dfde10d44730e48e2
haskell-compat/base-compat
TypeDiffSpec.hs
module TypeDiffSpec (main, spec) where import Test.Hspec import Data.Map (fromList) import Language.Haskell.Exts.Simple.Parser import TypeDiff main :: IO () main = hspec spec spec :: Spec spec = do describe "sigMap" $ do it "creates mapping from function names to type s...
null
https://raw.githubusercontent.com/haskell-compat/base-compat/847aa35c4142f529525ffc645cd035ddb23ce8ee/typediff/test/TypeDiffSpec.hs
haskell
module TypeDiffSpec (main, spec) where import Test.Hspec import Data.Map (fromList) import Language.Haskell.Exts.Simple.Parser import TypeDiff main :: IO () main = hspec spec spec :: Spec spec = do describe "sigMap" $ do it "creates mapping from function names to type s...
22d70e154ab3374ca2451fd2b7bbccb5ad8bf59fb4acb3235480ff2bd2450911
input-output-hk/cardano-ledger
Mirror.hs
# LANGUAGE LambdaCase # module Test.Cardano.Mirror ( mainnetEpochFiles, ) where import Cardano.Prelude import System.Directory (doesDirectoryExist, getDirectoryContents) import System.Environment (lookupEnv) import System.FilePath (isExtensionOf, (</>)) -- Failing here (with 'exitFailure') is fine because this fun...
null
https://raw.githubusercontent.com/input-output-hk/cardano-ledger/31c0bb1f5e78e40b83adfd1a916e69f47fdc9835/eras/byron/ledger/impl/test/Test/Cardano/Mirror.hs
haskell
Failing here (with 'exitFailure') is fine because this function is only ever
# LANGUAGE LambdaCase # module Test.Cardano.Mirror ( mainnetEpochFiles, ) where import Cardano.Prelude import System.Directory (doesDirectoryExist, getDirectoryContents) import System.Environment (lookupEnv) import System.FilePath (isExtensionOf, (</>)) used to test . It is never used in production code . main...
0fb7d0574c8dc9ef79b82fbfb51cbdb4c0685e416a3e6c1bb9b54693035fe6e9
facebook/infer
JsonReports.ml
* Copyright ( c ) 2009 - 2013 , Monoidics ltd . * Copyright ( c ) Facebook , Inc. and its affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) 2009-2013, Monoidics ltd. * Copyright (c) Facebook, In...
null
https://raw.githubusercontent.com/facebook/infer/ec1467a4ec971b2a1f616efd97e0f8f302449e91/infer/src/integration/JsonReports.ml
ocaml
end error description with a dot Removing the line,column, line and column in lambda's name (e.g. test::lambda.cpp:10:15::operator()), and infer temporary variable (e.g., n$67) information from the error message as well as the index of the annonymmous class to make the hash invariant ...
* Copyright ( c ) 2009 - 2013 , Monoidics ltd . * Copyright ( c ) Facebook , Inc. and its affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) 2009-2013, Monoidics ltd. * Copyright (c) Facebook, In...
f811b4d8e4fa7002f3dff378a7821a5f20bfcf75e61b8da38841f7b2293479fa
liquidz/misaki
2011-01-01-post1.html.clj
; @layout post ; @title Pagination ; @tag tag3 (h1 (:page site)) (p "Pagination setting.") ##CLJ :index-template-regexp #"^index\.html\.clj$" :posts-per-page 2 :page-filename-format "page$(page)/$(filename)" CLJ
null
https://raw.githubusercontent.com/liquidz/misaki/b8104e632058e3b3da4487513d10e666e5914ec9/samples/blog/template/posts/2011-01-01-post1.html.clj
clojure
@layout post @title Pagination @tag tag3
(h1 (:page site)) (p "Pagination setting.") ##CLJ :index-template-regexp #"^index\.html\.clj$" :posts-per-page 2 :page-filename-format "page$(page)/$(filename)" CLJ
acaae4ad7a844c7f7beb382b44eff236294c3c9d16d63548f40c7fcdfa9b8d13
janestreet/async_parallel
channel.mli
(** A [Channel.t] is a bi-directional communication channel for communicating to a [Hub.t]. Channels are portable across processes. A channel can be sent to another process, either explicitly or by being in a closure and it will continue to work. *) open! Core open! Async open! Import type ('to_hub, 'from_h...
null
https://raw.githubusercontent.com/janestreet/async_parallel/b2ef6ad95279260e2b9889e539bec87c40a13f34/src/channel.mli
ocaml
* A [Channel.t] is a bi-directional communication channel for communicating to a [Hub.t]. Channels are portable across processes. A channel can be sent to another process, either explicitly or by being in a closure and it will continue to work. * [create] is type-unsafe, and should not be used by user code. ...
open! Core open! Async open! Import type ('to_hub, 'from_hub) t val create : ?buffer_age_limit:[ `At_most of Time.Span.t | `Unlimited ] -> addr:Unix.Inet_addr.t * int -> unit -> (_, _) t Deferred.t val close : (_ , _ ) t -> unit Deferred.t val read : (_ , 'b) t -> 'b Deferred.t val read_full : (_ ,...
ffe6dbaf36ff7fcca6262f26a67c85556ddfce6c93330ed8dc25219f3c3d0f92
jrm-code-project/LISP-Machine
gauge.lisp
-*- Mode : LISP ; Package : TV ; : CL ; -*- Author : (defflavor basic-gauge ((last-value 0) last-bottom-x last-bottom-y last-top-x last-top-y internal-computer ) ...
null
https://raw.githubusercontent.com/jrm-code-project/LISP-Machine/0a448d27f40761fafabe5775ffc550637be537b2/lambda/examples/gauge.lisp
lisp
Package : TV ; : CL ; -*- Mapping The mapping function gets called on the new needle value whenever a :set-value message is sent. It is expected to produce a number between Some useful mapping functions. Probe This mixin gives you the :update message which will call the probe function The probe function is a...
Author : (defflavor basic-gauge ((last-value 0) last-bottom-x last-bottom-y last-top-x last-top-y internal-computer ) (process-mixin stream-mix...
cb6e0e8e29f3b4dd17066bb7db571f9aeb888627de508091a6dcfa8d9b0d9169
kowainik/tomland
TOML.hs
{-# LANGUAGE DeriveAnyClass #-} | Module : Toml . Type . TOML Copyright : ( c ) 2018 - 2022 Kowainik SPDX - License - Identifier : MPL-2.0 Maintainer : < > Stability : Stable Portability : Portable Type of TOML AST . This is ...
null
https://raw.githubusercontent.com/kowainik/tomland/561aefdbcf177498c06e6c6fcee2b3fe299b3af6/src/Toml/Type/TOML.hs
haskell
# LANGUAGE DeriveAnyClass # # INLINE (<>) #
| Module : Toml . Type . TOML Copyright : ( c ) 2018 - 2022 Kowainik SPDX - License - Identifier : MPL-2.0 Maintainer : < > Stability : Stable Portability : Portable Type of TOML AST . This is intermediate representation of T...
026174981ee97e1fdc36b226d16023e0e6dba7640ecab3a594278072965a96a5
foreverbell/project-euler-solutions
506.hs
# LANGUAGE TemplateHaskell , MultiParamTypeClasses , TypeFamilies # import qualified Common.Matrix.Matrix as M import Common.NumMod.MkNumMod mkNumMod True 123454321 type Zn = Int123454321 initial = [1, 2, 3, 4, 32, 123, 43, 2123, 432, 1234, 32123, 43212, 34321, 23432, 123432] suffix = [234321, 343212, 432...
null
https://raw.githubusercontent.com/foreverbell/project-euler-solutions/c0bf2746aafce9be510892814e2d03e20738bf2b/src/506.hs
haskell
# LANGUAGE TemplateHaskell , MultiParamTypeClasses , TypeFamilies # import qualified Common.Matrix.Matrix as M import Common.NumMod.MkNumMod mkNumMod True 123454321 type Zn = Int123454321 initial = [1, 2, 3, 4, 32, 123, 43, 2123, 432, 1234, 32123, 43212, 34321, 23432, 123432] suffix = [234321, 343212, 432...
8939c957747dedb836d171074be2c5dafa9121a62e1dd870e2caa1a025cc863b
hsyl20/haskus-system
Mode.hs
# LANGUAGE RecordWildCards # # LANGUAGE DataKinds # # LANGUAGE TypeApplications # -- | Display mode (resolution, refresh rate, etc.) module Haskus.System.Linux.Graphics.Mode ( Mode(..) , ModeType(..) , ModeTypes , ModeFlag(..) , ModeFlags -- * Low level , fromStructMode , toStructMode ) wher...
null
https://raw.githubusercontent.com/hsyl20/haskus-system/2f389c6ecae5b0180b464ddef51e36f6e567d690/haskus-system/src/lib/Haskus/System/Linux/Graphics/Mode.hs
haskell
| Display mode (resolution, refresh rate, etc.) * Low level | Display mode
# LANGUAGE RecordWildCards # # LANGUAGE DataKinds # # LANGUAGE TypeApplications # module Haskus.System.Linux.Graphics.Mode ( Mode(..) , ModeType(..) , ModeTypes , ModeFlag(..) , ModeFlags , fromStructMode , toStructMode ) where import Haskus.Format.Binary.BitField import Haskus.Format.Binary.E...
2e04e790e0aa58a0324af8fe3410a102fb506185a357af688c4a0764f1114dd5
fstamour/breeze
setup-quicklisp.lisp
(load "quicklisp.lisp") (quicklisp-quickstart:install) (ql-util:without-prompting (ql:add-to-init-file))
null
https://raw.githubusercontent.com/fstamour/breeze/7c0e49ec2bdd536b2177d010e40a09b32d856cf9/scripts/setup-quicklisp.lisp
lisp
(load "quicklisp.lisp") (quicklisp-quickstart:install) (ql-util:without-prompting (ql:add-to-init-file))
c2ca336d2c0c0de20bd47d10bb428f8018c2005db2289353af28a22e725fe6fe
PeterDWhite/Osker
Test11.hs
Copyright ( c ) , 2003 Copyright ( c ) OHSU , 2003 module Main where --Haskell imports import Monad -- Test imports import TestSupport Braid imports import qualified BraidExternal as B import qualified BraidInternal as BI -- Channel imports import qualified OskerChan as C The hub of the level 1 braid -- Th...
null
https://raw.githubusercontent.com/PeterDWhite/Osker/301e1185f7c08c62c2929171cc0469a159ea802f/Braid/Test11.hs
haskell
Haskell imports Test imports Channel imports This is not a lifted thread.
Copyright ( c ) , 2003 Copyright ( c ) OHSU , 2003 module Main where import Monad import TestSupport Braid imports import qualified BraidExternal as B import qualified BraidInternal as BI import qualified OskerChan as C The hub of the level 1 braid hubl1 :: Int -> B.Braid Gs Ls () hubl1 loops = do { tid ...
39fab41cc9507ba7062a02ae6bcc6946d81e7202e545486ff537d8a0e3e79c79
LightAndLight/cbpv
Printer.hs
# language GADTs # # language LambdaCase # module Printer where import Data.Foldable (fold) import Data.List (intersperse) import Data.Maybe (fromMaybe) import Text.PrettyPrint.ANSI.Leijen (Doc) import qualified Text.PrettyPrint.ANSI.Leijen as Pretty import qualified Data.List.NonEmpty as NonEmpty import qualified Da...
null
https://raw.githubusercontent.com/LightAndLight/cbpv/8c54deb312eb873c8e21e886aef42e515f9a93e5/src/Printer.hs
haskell
# language GADTs # # language LambdaCase # module Printer where import Data.Foldable (fold) import Data.List (intersperse) import Data.Maybe (fromMaybe) import Text.PrettyPrint.ANSI.Leijen (Doc) import qualified Text.PrettyPrint.ANSI.Leijen as Pretty import qualified Data.List.NonEmpty as NonEmpty import qualified Da...
c5ebc6db4dc6cbc912ac7d8855f4aa9015982c398ce846846a3f0b6f824b62c9
emqx/emqx
emqx_stomp_heartbeat_SUITE.erl
%%-------------------------------------------------------------------- Copyright ( c ) 2020 - 2023 EMQ Technologies Co. , Ltd. All Rights Reserved . %% Licensed under the Apache License , Version 2.0 ( the " License " ) ; %% you may not use this file except in compliance with the License. %% You may obtain a copy o...
null
https://raw.githubusercontent.com/emqx/emqx/dbc10c2eed3df314586c7b9ac6292083204f1f68/apps/emqx_gateway/test/emqx_stomp_heartbeat_SUITE.erl
erlang
-------------------------------------------------------------------- you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express ...
Copyright ( c ) 2020 - 2023 EMQ Technologies Co. , Ltd. All Rights Reserved . Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(emqx_stomp_heartbeat_SUITE). -compile(export_all). -compile(nowarn_export_all). all() ...
8d4f906b508e6b63d27caca9af66c342d066117ba36ef3f242c476e81c61e084
nuprl/gradual-typing-performance
info.rkt
#lang info (define name "HtDP/2e Teachpacks") (define test-omit-paths '("uchat/chatter.rkt" "uchat/server.rkt")) (define test-responsibles '(("image.rkt" robby) (all matthias)))
null
https://raw.githubusercontent.com/nuprl/gradual-typing-performance/35442b3221299a9cadba6810573007736b0d65d4/pre-benchmark/ecoop/htdp-lib/2htdp/info.rkt
racket
#lang info (define name "HtDP/2e Teachpacks") (define test-omit-paths '("uchat/chatter.rkt" "uchat/server.rkt")) (define test-responsibles '(("image.rkt" robby) (all matthias)))
18435205aa43992073dc2e4a5138c115f0e83d29efb0305b9a1d7be9d0dc85ed
rtoy/ansi-cl-tests
pop.lsp
;-*- Mode: Lisp -*- Author : Created : Sat Apr 19 22:27:18 2003 ;;;; Contains: Tests of POP (in-package :cl-test) (compile-and-load "cons-aux.lsp") (deftest pop.1 (let ((x (copy-tree '(a b c)))) (let ((y (pop x))) (list x y))) ((b c) a)) (deftest pop.2 (let ((x nil)) (let ((y (pop...
null
https://raw.githubusercontent.com/rtoy/ansi-cl-tests/9708f3977220c46def29f43bb237e97d62033c1d/pop.lsp
lisp
-*- Mode: Lisp -*- Contains: Tests of POP Test that explicit calls to macroexpand in subforms are done in the correct environment Confirm argument is executed just once. Need to add tests of POP vs. various accessors
Author : Created : Sat Apr 19 22:27:18 2003 (in-package :cl-test) (compile-and-load "cons-aux.lsp") (deftest pop.1 (let ((x (copy-tree '(a b c)))) (let ((y (pop x))) (list x y))) ((b c) a)) (deftest pop.2 (let ((x nil)) (let ((y (pop x))) (list x y))) (nil nil)) (deftest pop...
bd5fc4ba6b0c6623aa60e1cbe96f3cca15308a0aefa6457e254eb81216e0e0a0
egri-nagy/kigen
subsgps.clj
(use '[criterium.core]) (use '[clojure.data.int-map :as i]) (use '[orbit.core :as orbit]) (use '[kigen.multab :as multab]) (use '[kigen.transf :as t]) (def mtS5 (multab/multab (t/sgp-by-gens (t/symmetric-gens 5)) t/mul)) (println "Single S5") (binding [criterium.core/*sample-count* 2] (bench ...
null
https://raw.githubusercontent.com/egri-nagy/kigen/5248499fab9d8af05d7d0b07626d0676dfe580c9/experiments/REDUCERS/subsgps.clj
clojure
(use '[criterium.core]) (use '[clojure.data.int-map :as i]) (use '[orbit.core :as orbit]) (use '[kigen.multab :as multab]) (use '[kigen.transf :as t]) (def mtS5 (multab/multab (t/sgp-by-gens (t/symmetric-gens 5)) t/mul)) (println "Single S5") (binding [criterium.core/*sample-count* 2] (bench ...
560fac5f855aee46f11f234202eaf18888565be2c59d32cae78ba5427136a96b
janestreet/core
percent.mli
* A scale factor , not bounded between 0 % and 100 % , represented as a float . open! Import open Std_internal (** Exposing that this is a float allows for more optimization. E.g. compiler can optimize some local refs and not box them. *) type t = private float [@@deriving globalize, hash, typerep] * [ of_string...
null
https://raw.githubusercontent.com/janestreet/core/f382131ccdcb4a8cd21ebf9a49fa42dcf8183de6/core/src/percent.mli
ocaml
* Exposing that this is a float allows for more optimization. E.g. compiler can optimize some local refs and not box them. * Equivalent to [Stable.V3.to_string] * The value [nan] cannot be represented as an [Option.t] * [apply t x] multiplies the percent [t] by [x], returning a float. * [scale t x] scales the p...
* A scale factor , not bounded between 0 % and 100 % , represented as a float . open! Import open Std_internal type t = private float [@@deriving globalize, hash, typerep] * [ of_string ] and [ t_of_sexp ] disallow [ nan ] , [ inf ] , etc . Furthermore , they round to 6 significant digits . They are equiva...
d3ef4102f9950bf34a333c8dce19c11f275ebb315e663943e31ac8c08f2b94b3
awakesecurity/spectacle
SimpleClock.hs
# LANGUAGE OverloadedLabels # module Specifications.SimpleClock where import Language.Spectacle ( Action, ActionType (ActionWF), Fairness (WeakFair), Modality (Always, Infinitely), Specification (Specification), Temporal, TemporalType (PropG, PropGF), interaction, modelcheck, pla...
null
https://raw.githubusercontent.com/awakesecurity/spectacle/70501d0dc8b7fbefe1b52afff405c65e663fbf4e/test/integration/Specifications/SimpleClock.hs
haskell
--------------------------------------------------------------------------------------------------------------------- ---------------------------------------------------------------------------------------------------------------------
# LANGUAGE OverloadedLabels # module Specifications.SimpleClock where import Language.Spectacle ( Action, ActionType (ActionWF), Fairness (WeakFair), Modality (Always, Infinitely), Specification (Specification), Temporal, TemporalType (PropG, PropGF), interaction, modelcheck, pla...
e48ee9ad8935f46aeb7e6ceace43c5b7f1ea51987c7a2e088698df4047d31aa6
ryanpbrewster/haskell
P206Test.hs
module Problems.P206Test ( case_206_main ) where import Problems.P206 import Test.Tasty.Discover (Assertion, (@?=)) case_206_main :: Assertion case_206_main = solve @?= "233168"
null
https://raw.githubusercontent.com/ryanpbrewster/haskell/6edd0afe234008a48b4871032dedfd143ca6e412/project-euler/tests/Problems/P206Test.hs
haskell
module Problems.P206Test ( case_206_main ) where import Problems.P206 import Test.Tasty.Discover (Assertion, (@?=)) case_206_main :: Assertion case_206_main = solve @?= "233168"
1b543e96db0a2178a248f69f3d5cec8eb3b4d75e969218d6b74b0b2b40162633
acl2/acl2
bvsx-rules@useless-runes.lsp
(BVAND-OF-BVSX-LOW-ARG2 (2414 16 (:REWRITE BVAND-WITH-MASK-BETTER)) (2382 15 (:DEFINITION LOGMASKP)) (1392 50 (:DEFINITION EXPT)) (1278 36 (:LINEAR INTEGER-LENGTH-BOUND)) (594 14 (:DEFINITION EXPT2$INLINE)) (438 18 (:REWRITE EQUAL-OF-+-WHEN-NEGATIVE-CONSTANT)) (422 212 (:TYPE-PRESCRIPTION RATIONALP-EXPT-TYPE-PRE...
null
https://raw.githubusercontent.com/acl2/acl2/f64742cc6d41c35f9d3f94e154cd5fd409105d34/books/kestrel/bv/.sys/bvsx-rules%40useless-runes.lsp
lisp
(BVAND-OF-BVSX-LOW-ARG2 (2414 16 (:REWRITE BVAND-WITH-MASK-BETTER)) (2382 15 (:DEFINITION LOGMASKP)) (1392 50 (:DEFINITION EXPT)) (1278 36 (:LINEAR INTEGER-LENGTH-BOUND)) (594 14 (:DEFINITION EXPT2$INLINE)) (438 18 (:REWRITE EQUAL-OF-+-WHEN-NEGATIVE-CONSTANT)) (422 212 (:TYPE-PRESCRIPTION RATIONALP-EXPT-TYPE-PRE...
1bda8071f89290d707201a3a080e8dfd131b064f2a76d5193b0cb4573ee5fa53
Mikolaj/horde-ad
MnistData.hs
{-# LANGUAGE DataKinds, KindSignatures #-} # OPTIONS_GHC -Wno - missing - export - lists # | Parsing and pre - processing MNIST data . module MnistData where import Prelude import Codec.Compression.GZip (decompress) import Control.Arrow (first) import Data.Array.Internal (valueOf) impo...
null
https://raw.githubusercontent.com/Mikolaj/horde-ad/cde1a874e381bfeeb4740f532f751993a11f964d/example/MnistData.hs
haskell
# LANGUAGE DataKinds, KindSignatures # is an integer label and a picture (the same vector as below). to the label instead of performing a dot product with scaling. Our library makes this easy to express and gradients compute fine. However, the goal of the exercise it to implement the same Also, loss computation is...
# OPTIONS_GHC -Wno - missing - export - lists # | Parsing and pre - processing MNIST data . module MnistData where import Prelude import Codec.Compression.GZip (decompress) import Control.Arrow (first) import Data.Array.Internal (valueOf) import qualified Data.Array.Shaped as OSB impor...
ad43be2e14356e9592e82da89c40e5e03e260b5a4d000d1fa7bf08734252f784
gebi/jungerl
ce_poll.erl
%%% BEGIN ce_poll.erl %%% %%% %%% ce - Miscellaneous Programming Support Libraries for Erlang/OTP %%% Copyright (c)2003 Cat's Eye Technologies. All rights reserved. %%% %%% Redistribution and use in source and binary forms, with or without %%% modification, are permitted provided that the following conditions %%% are ...
null
https://raw.githubusercontent.com/gebi/jungerl/8f5c102295dbe903f47d79fd64714b7de17026ec/lib/ce/src/ce_poll.erl
erlang
BEGIN ce_poll.erl %%% ce - Miscellaneous Programming Support Libraries for Erlang/OTP Copyright (c)2003 Cat's Eye Technologies. 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...
Neither the name of Cat 's Eye Technologies nor the names of its CONTRIBUTORS ` ` AS IS '' AND ANY EXPRESS OR IMPLIED WARRANTIES , DISCLAIMED . IN NO EVENT SHALL THE REGENTS OR LIABLE FOR ANY DIRECT , INDIRECT , INCIDENTAL , SPECIAL , EXEMPLARY , PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES ; LOSS OF USE ,...
8163294c57776f279653bd44dcd928101a5aa5ee319a247cb255ebc2089e2857
bkirwi/ethereum-haskell
Prelude.hs
# LANGUAGE DeriveFunctor # # LANGUAGE GeneralizedNewtypeDeriving # module Ethereum.Prelude ( Word4, word4to8, packWord8, fstWord4, sndWord4, word4toInt, unpackWord4s , ByteString, Word8, Map , DB, insertDB, lookupDB, runDB , encodeInt, decodeInt , module X ) where import Control.Monad.Free import Data.Bits...
null
https://raw.githubusercontent.com/bkirwi/ethereum-haskell/ee995281bad4eed488c174bd8982ed174cfe26af/src/Ethereum/Prelude.hs
haskell
Collapses a series of puts and gets down to the monad of your choice ^ The 'put' function for our desired monad ^ The 'get' function for the same monad ^ The puts and gets to execute
# LANGUAGE DeriveFunctor # # LANGUAGE GeneralizedNewtypeDeriving # module Ethereum.Prelude ( Word4, word4to8, packWord8, fstWord4, sndWord4, word4toInt, unpackWord4s , ByteString, Word8, Map , DB, insertDB, lookupDB, runDB , encodeInt, decodeInt , module X ) where import Control.Monad.Free import Data.Bits...
c545b94d81dd84430b8dd92a3d353cb585cd99f24599508dd9579f872aa252af
johnstonskj/rml-core
data.rkt
#lang racket/base ;; ;; Racket Machine Learning - Core. ;; ~ 2018 . ;; ;; ---------- Requirements (require rackunit racket/string math/statistics ; --------- rml/data rml/not-implemented "data-sets.rkt") ;; ---------- Test Fixtures ;; ---------- Internal pro...
null
https://raw.githubusercontent.com/johnstonskj/rml-core/8f3ca8b47e552911054f2aa12b296dbf40dad637/rml/test/data.rkt
racket
Racket Machine Learning - Core. ---------- Requirements --------- ---------- Test Fixtures ---------- Internal procedures ---------- Test Cases TODO: feature-vector: fail on bad partition index
#lang racket/base ~ 2018 . (require rackunit racket/string math/statistics rml/data rml/not-implemented "data-sets.rkt") (test-case "supported-formats: includes core formats" (check-not-false (member 'csv supported-formats)) (check-not-false (member 'json sup...
a481f87d0eedd138e803c10e101d0a5263bd66625626a47b2762d1b56f07c80d
wireapp/wire-server
WS.hs
# LANGUAGE GeneralizedNewtypeDeriving # -- This file is part of the Wire Server implementation. -- Copyright ( C ) 2022 Wire Swiss GmbH < > -- -- This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Fou...
null
https://raw.githubusercontent.com/wireapp/wire-server/2ca54494da92106b4babfda1d0b23b72a2405d70/services/cannon/src/Cannon/WS.hs
haskell
This file is part of the Wire Server implementation. This program is free software: you can redistribute it and/or modify it under later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTI...
# LANGUAGE GeneralizedNewtypeDeriving # Copyright ( C ) 2022 Wire Swiss GmbH < > the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or ( at your option ) any You should have received a copy of the GNU Affero General Public Licens...
89f4563c6a450045175c7e51724a2361152dac296ac5a6af9e3898457c18a62a
alekcz/fire
socket.clj
(ns fire.socket (:require [fire.utils :as u] [fire.auth :as auth] [gniazdo.core :as ws] [clojure.core.async :as async] [clojure.java.io :as io] [clojure.string :as str] [clj-uuid :as uuid]) (:refer-clojure :exclude [read]) (...
null
https://raw.githubusercontent.com/alekcz/fire/812398e36c02c244fb59dd1d20575204185c7f0e/src/fire/socket.clj
clojure
Inferred from -js-sdk/blob/master/packages/database/src/core/PersistentConnection.ts#L176 aligned to firebase-js-sdk data control Does not work with localhost
(ns fire.socket (:require [fire.utils :as u] [fire.auth :as auth] [gniazdo.core :as ws] [clojure.core.async :as async] [clojure.java.io :as io] [clojure.string :as str] [clj-uuid :as uuid]) (:refer-clojure :exclude [read]) (...
8bd9a3b0612caab65ba112708ef060ea024a463e174f99bb93444f29386b5cf3
greghendershott/vestige
info.rkt
#lang info (define collection 'multi) (define deps '(["base" #:version "7.8"])) (define build-deps '("rackunit-lib")) (define test-omit-paths '("vestige/example/")) (define clean '("compiled")) (define pkg-desc "implementation part of \"vestige\"")
null
https://raw.githubusercontent.com/greghendershott/vestige/ee7f0b35ba5e5d1a3e5ec90976c658bce24d0ba4/vestige-lib/info.rkt
racket
#lang info (define collection 'multi) (define deps '(["base" #:version "7.8"])) (define build-deps '("rackunit-lib")) (define test-omit-paths '("vestige/example/")) (define clean '("compiled")) (define pkg-desc "implementation part of \"vestige\"")
67efcb9fec2db2f168008b6ee038b36e1cff7abcc089722c5a018be5ce53ef4c
turnbullpress/aom-code
slack.clj
(ns examplecom.etc.slack (:require [riemann.slack :refer :all])) (def credentials {:account "examplecom", :token "123ABC123ABC"}) (defn slack-format "Format our Slack message" [event] (str "Service " (:service event) " on host " (:host event) " is in state " (:state event) ".\n" "See :3000/dashboard/scri...
null
https://raw.githubusercontent.com/turnbullpress/aom-code/2c016cab87d81bcd1f04ab41b6824798eb09e780/10/riemann/examplecom/etc/slack.clj
clojure
(ns examplecom.etc.slack (:require [riemann.slack :refer :all])) (def credentials {:account "examplecom", :token "123ABC123ABC"}) (defn slack-format "Format our Slack message" [event] (str "Service " (:service event) " on host " (:host event) " is in state " (:state event) ".\n" "See :3000/dashboard/scri...
a9719e4d55d7f8143695ea98708f76f71ac436c8896f602dde715342a67d3a8a
janestreet/vcaml
runtime.ml
open Core module type Nvim_id = sig type t = private int [@@deriving sexp_of] include Comparable.S_plain with type t := t include Hashable.S_plain with type t := t include Msgpack.Msgpackable with type t := t module Or_current : sig type nonrec t = | Current | Id of t [@@deriving sexp_o...
null
https://raw.githubusercontent.com/janestreet/vcaml/7a53ff24276ddc3085a9b0b72b1053a6db6936cf/nvim_internal/runtime.ml
ocaml
open Core module type Nvim_id = sig type t = private int [@@deriving sexp_of] include Comparable.S_plain with type t := t include Hashable.S_plain with type t := t include Msgpack.Msgpackable with type t := t module Or_current : sig type nonrec t = | Current | Id of t [@@deriving sexp_o...
4bcea6cc0ca9071258838eb7dad995fea57208bb56270f1ee32e1fbe1c0a8069
NalaGinrut/artanis
db.scm
-*- indent - tabs - mode : nil ; coding : utf-8 -*- ;; Copyright (C) 2013,2014,2015,2017,2018 " Mu Lei " known as " NalaGinrut " < > Artanis is free software : you can redistribute it and/or modify it under the terms of the GNU General Public License and GNU Lesser General Public License publishe...
null
https://raw.githubusercontent.com/NalaGinrut/artanis/3412d6eb5b46fde71b0965598ba085bacc2a6c12/artanis/db.scm
scheme
coding : utf-8 -*- Copyright (C) 2013,2014,2015,2017,2018 any later version. but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License and GNU Lesser General Public License for more details. and GNU Lesser Gener...
" Mu Lei " known as " NalaGinrut " < > Artanis is free software : you can redistribute it and/or modify it under the terms of the GNU General Public License and GNU Lesser General Public License published by the Free Software Foundation , either version 3 of the License , or ( at your option ) A...
93d6e25e7e327bc400b753f502a9387e36cc853e63d94e70f8398cafbba31a1b
DeathKing/Hit-DataStructure-On-Scheme
interest-table.scm
;;; SIMPLE BANK INTEREST TABLE ;;; ;;; AUTHOR: DeathKing<dk#hit.edu.cn> LICENSE : HIT / MIT (load-option 'format) (define *type:fixed* 'fixed) ; fixed deposit by installments (define *type:lump-sum* 'lump-sum) ; lump-sum deposit and withdrawal (define *type:optional* 'optional) ; time/current optional deposi...
null
https://raw.githubusercontent.com/DeathKing/Hit-DataStructure-On-Scheme/11677e3c6053d6c5b37cf0509885f74ab5c2bab9/application1/interest-table.scm
scheme
SIMPLE BANK INTEREST TABLE AUTHOR: DeathKing<dk#hit.edu.cn> fixed deposit by installments lump-sum deposit and withdrawal time/current optional deposit ref: www.ccb.com/cn/personal/interest/rmbdeposit.html
LICENSE : HIT / MIT (load-option 'format) (define (make-interest-table) (list 'table '())) (define (make-interest-item type time rate) (list 'item type time rate)) (define (interest-terms table) (list-ref table 1)) (define (interest-ref table index) (list-ref (interest-terms table) index)) (define (ite...
e734ab978a60d5979cc7b36487c9666a5cffd3f334dea0d5ef9dfff61b6ca5cb
wireless-net/erlang-nommu
wxGBSizerItem.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 2008 - 2013 . All Rights Reserved . %% The contents of this file are subject to the Erlang Public License , Version 1.1 , ( the " License " ) ; you may not use this file except in %% compliance with the License. You should have received a copy of the %% Erlang Publi...
null
https://raw.githubusercontent.com/wireless-net/erlang-nommu/79f32f81418e022d8ad8e0e447deaea407289926/lib/wx/src/gen/wxGBSizerItem.erl
erlang
%CopyrightBegin% compliance with the License. You should have received a copy of the Erlang Public License along with this software. If not, it can be retrieved online at /. basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitatio...
Copyright Ericsson AB 2008 - 2013 . All Rights Reserved . The contents of this file are subject to the Erlang Public License , Version 1.1 , ( the " License " ) ; you may not use this file except in Software distributed under the License is distributed on an " AS IS " -module(wxGBSizerItem). -include("wxe.hrl...
ce591b92ab8aea033cd8de625f87b9e926c8260439d5831d6f1a694d9dc079fa
DataHaskell/dh-core
Utils.hs
{-# language TypeFamilies #-} module Core.Numeric.Statistics.Classification.Utils where import qualified Data . Foldable as F ( , foldl ' , toList ) import qualified Data.IntSet as SI -- import qualified Data.Set as S import qualified Data.IntMap.Strict as IM import System.Random.MWC import System.Random.MWC.Distr...
null
https://raw.githubusercontent.com/DataHaskell/dh-core/2beb8740f27fa9683db70eb8d8424ee6c75d3e91/dh-core/src/Core/Numeric/Statistics/Classification/Utils.hs
haskell
# language TypeFamilies # import qualified Data.Set as S import Numeric.Classification.Exceptions * Bootstrap | Non-parametric bootstrap ^ Number of samples ^ Number of bootstrap resamples ^ Dataset * | Sample with replacement | Sample without replacement : return a list of at most M unique random samples fr...
module Core.Numeric.Statistics.Classification.Utils where import qualified Data . Foldable as F ( , foldl ' , toList ) import qualified Data.IntSet as SI import qualified Data.IntMap.Strict as IM import System.Random.MWC import System.Random.MWC.Distributions import Control.Monad.Primitive import Control.Monad (f...
4f306a0fe9033b5d4d697eafe9b692b2f1a30d6eef4028a7f243c091e0dd78c5
bmeurer/ocamljit2
output.ml
(***********************************************************************) (* *) (* Objective Caml *) (* *) , projet ...
null
https://raw.githubusercontent.com/bmeurer/ocamljit2/ef06db5c688c1160acc1de1f63c29473bcd0055c/testsuite/tests/tool-lexyacc/output.ml
ocaml
********************************************************************* Objective Caml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et en Automatique . All rights reserved . This file is distributed under the terms of the Q Public License version 1.0 . $ Id$ Generating a DFA as a set of...
ede8a2102b91341344c215210b615984109ac0e1fcdd5077c14848e44a3c3e60
theiceshelf/trunk
index.cljs
(ns app.renderer.views.index (:require [app.renderer.components :as component] [app.renderer.events :as events :refer [|>]] [app.renderer.subs :as subs :refer [<|]] [app.renderer.views.article :as article] [app.renderer.views.article-create :as article-create] [app.renderer.views.article-list :as ar...
null
https://raw.githubusercontent.com/theiceshelf/trunk/b6010097c223f4ba5db7065bbd7305441c54441d/src/app/renderer/views/index.cljs
clojure
fixed pos things (when u/debug? [debug])
(ns app.renderer.views.index (:require [app.renderer.components :as component] [app.renderer.events :as events :refer [|>]] [app.renderer.subs :as subs :refer [<|]] [app.renderer.views.article :as article] [app.renderer.views.article-create :as article-create] [app.renderer.views.article-list :as ar...