_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
085a431ef02a69a9b47de0c83a7a998b3d34f070cdaed641f773ed3c58b852c9
synduce/Synduce
node_count_ensures_height.ml
let s0 = 0 let f0 x32 x33 = x33 + (x33 + 1) let rec target = function Nil -> s0 | Node(a, l, r) -> f0 a (target l)
null
https://raw.githubusercontent.com/synduce/Synduce/d453b04cfb507395908a270b1906f5ac34298d29/extras/solutions/constraints/balanced_tree/node_count_ensures_height.ml
ocaml
let s0 = 0 let f0 x32 x33 = x33 + (x33 + 1) let rec target = function Nil -> s0 | Node(a, l, r) -> f0 a (target l)
22253842cd38f2ccff5aaf3625a9b38b69d4e516a1661fa656853b6273b5931c
EFanZh/EOPL-Exercises
exercise-2.5.rkt
#lang eopl Exercise 2.5 [ ★ ] We can use any data structure for representing environments , if we can distinguish empty ;; environments from non-empty ones, and in which one can extract the pieces of a non-empty environment. Implement ;; environments using a representation in which the empty environment is represent...
null
https://raw.githubusercontent.com/EFanZh/EOPL-Exercises/11667f1e84a1a3e300c2182630b56db3e3d9246a/solutions/exercise-2.5.rkt
racket
environments from non-empty ones, and in which one can extract the pieces of a non-empty environment. Implement environments using a representation in which the empty environment is represented as the empty list, and in which extend-env builds an environment that looks like ┌───┬───┐ │ ╷ │ ╶─┼─►...
#lang eopl Exercise 2.5 [ ★ ] We can use any data structure for representing environments , if we can distinguish empty ┼ ─ ┴ ─ ─ ─ ┘ ┼ ─ ┴ ─ ┼ ─ ┘ ┌ ─ ─ ┘ ─ ─ ─ ┐ (define empty-env (lambda () '())) (define apply-env (lambda (env search-var) (let ([head (car env)...
489bfa2bf2d656497e907ac1d0065674287dd01eb2488824cb7d0e8720ae3047
haskell-mafia/tinfoil
Foreign.hs
# LANGUAGE NoImplicitPrelude # # LANGUAGE TemplateHaskell # module Test.IO.Tinfoil.Internal.Sodium.Foreign where import Disorder.Core.IO (testIO) import P import System.IO import Test.QuickCheck import Tinfoil.Internal.Sodium.Data import Tinfoil.Internal....
null
https://raw.githubusercontent.com/haskell-mafia/tinfoil/f46b2ea0b9984ac9a97073932b5584ce0a2e0554/test/Test/IO/Tinfoil/Internal/Sodium/Foreign.hs
haskell
# LANGUAGE NoImplicitPrelude # # LANGUAGE TemplateHaskell # module Test.IO.Tinfoil.Internal.Sodium.Foreign where import Disorder.Core.IO (testIO) import P import System.IO import Test.QuickCheck import Tinfoil.Internal.Sodium.Data import Tinfoil.Internal....
02c5d8a4515456c962457e73e280784c372a590f3791745e85f9a0f0bd9ac1da
ryukzak/nitta
SPI.hs
# LANGUAGE DuplicateRecordFields # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE QuasiQuotes # # LANGUAGE RecordWildCards # # LANGUAGE TypeFamilies # | Module : NITTA.Model . ProcessorUnits . IO.SPI Description : Copyright : ( c ) , 2019 License : : Stability : experimental Modul...
null
https://raw.githubusercontent.com/ryukzak/nitta/6d5cab0465ff5bcccfe419b8d8553266c530f7b7/src/NITTA/Model/ProcessorUnits/IO/SPI.hs
haskell
# LANGUAGE OverloadedStrings # FIXME: do not check output signals when we drop data
# LANGUAGE DuplicateRecordFields # # LANGUAGE QuasiQuotes # # LANGUAGE RecordWildCards # # LANGUAGE TypeFamilies # | Module : NITTA.Model . ProcessorUnits . IO.SPI Description : Copyright : ( c ) , 2019 License : : Stability : experimental Module : NITTA.Model.ProcessorUnits...
ddb70e894dfa9490241c6400c3929d1c49c9aedb365d50738af60cf3a4fbf23c
clash-lang/clash-compiler
Internal.hs
| Copyright : ( C ) 2019 , Myrtle Software Ltd License : BSD2 ( see the file LICENSE ) Maintainer : QBayLogic B.V. < > Verification Copyright : (C) 2019, Myrtle Software Ltd License : BSD2 (see the file LICENSE) Maintainer : QBayLogic B.V. <> Verification -} # LANGUAGE CPP # # LANGUAGE F...
null
https://raw.githubusercontent.com/clash-lang/clash-compiler/be7558062e2832c446b9dcf61be3852872b646bb/clash-prelude/src/Clash/Verification/Internal.hs
haskell
| Render target for HDL ^ Property Specification Language ^ SystemVerilog Assertions and suported by GHDL+SymbiYosys; | Internal version of 'Assertion'. ^ (Bootstrapping) signal of booleans ^ Boolean literal ^ Logical not ^ Logical and ^ Logical or ^ Logical implies ^ Moves start point of assertion /n/...
| Copyright : ( C ) 2019 , Myrtle Software Ltd License : BSD2 ( see the file LICENSE ) Maintainer : QBayLogic B.V. < > Verification Copyright : (C) 2019, Myrtle Software Ltd License : BSD2 (see the file LICENSE) Maintainer : QBayLogic B.V. <> Verification -} # LANGUAGE CPP # # LANGUAGE F...
9ee1780760a5708ead3b5c3ce2bf5a8b039e9bf27fe977eb70032b29e5b86b03
PDP-10/panda
newhash.lsp
(FILECREATED " 9-Mar-84 09:33:45" <ONCOCIN.FORMS>NEWHASH.LSP.6 24117 previous date: " 9-Mar-84 09:18:04" <ONCOCIN.FORMS>NEWHASH.LSP.5) (PRETTYCOMPRINT NEWHASHCOMS) (RPAQQ NEWHASHCOMS ((FNS * NEWHASHFNS) (FNS * NEWHASHSYSFNS) (FNS TESTHASH) (MACROS * NEWHASHMACROS) ...
null
https://raw.githubusercontent.com/PDP-10/panda/522301975c062914ea3d630a1daefde261ddf590/files/lispusers/newhash.lsp
lisp
(FILECREATED " 9-Mar-84 09:33:45" <ONCOCIN.FORMS>NEWHASH.LSP.6 24117 previous date: " 9-Mar-84 09:18:04" <ONCOCIN.FORMS>NEWHASH.LSP.5) (PRETTYCOMPRINT NEWHASHCOMS) (RPAQQ NEWHASHCOMS ((FNS * NEWHASHFNS) (FNS * NEWHASHSYSFNS) (FNS TESTHASH) (MACROS * NEWHASHMACROS) ...
872c0c7d34e7c2105531417b7b02249f0f13d78c2dd33adb224b79baa5c1c63f
ocaml-ppx/ppx_tools_versioned
ast_mapper_class_406.ml
open Migrate_parsetree.Ast_406 (* This file is part of the ppx_tools package. It is released *) under the terms of the MIT license ( see LICENSE file ) . Copyright 2013 and LexiFi (** Class-based customizable mapper *) open Parsetree open Asttypes open Ast_helper let map_fs...
null
https://raw.githubusercontent.com/ocaml-ppx/ppx_tools_versioned/00a0150cdabfa7f0dad2c5e0e6b32230d22295ca/ast_mapper_class_406.ml
ocaml
This file is part of the ppx_tools package. It is released * Class-based customizable mapper Type expressions for the core language Type expressions for the class language Type expressions for the module language Value expressions for the module language Value expressions for the core language Patterns...
open Migrate_parsetree.Ast_406 under the terms of the MIT license ( see LICENSE file ) . Copyright 2013 and LexiFi open Parsetree open Asttypes open Ast_helper let map_fst f (x, y) = (f x, y) let map_snd f (x, y) = (x, f y) let map_tuple f1 f2 (x, y) = (f1 x, f2 y) let map_tup...
1f2d410eab44ad5c449bfb6fa4832f771c50df527c60744050b7c40394a6bdd4
mransan/ocaml-protoc
pb_codegen_util.mli
(** Common utility functions for OCaml code generation *) val sp : ('a, unit, string) format -> 'a (** [sp x] same as sprintf but prefixed with new line *) val let_decl_of_and : 'a option -> string (** [let_decl_of_and and_] returns the function declaration ["let"] (when ?and_ is [None]), ["and"] otherwise. *) v...
null
https://raw.githubusercontent.com/mransan/ocaml-protoc/e43b509b9c4a06e419edba92a0d3f8e26b0a89ba/src/compilerlib/pb_codegen_util.mli
ocaml
* Common utility functions for OCaml code generation * [sp x] same as sprintf but prefixed with new line * [let_decl_of_and and_] returns the function declaration ["let"] (when ?and_ is [None]), ["and"] otherwise. * [caml_file_name_of_proto_file_name filename] returns the OCaml file name from the protobuf fi...
val sp : ('a, unit, string) format -> 'a val let_decl_of_and : 'a option -> string val string_of_record_field_type : ?module_prefix:string -> Pb_codegen_ocaml_type.record_field_type -> string val string_of_basic_type : ?for_pp:bool -> Pb_codegen_ocaml_type.basic_type -> string val string_of_field_type : ?for...
126e95baed8202b8271f191db834bebe409ac09d8ab49fb59de53aac459adf2a
thoughtbot/carnival
SitesSpec.hs
module Handler.SitesSpec ( main , spec ) where import TestImport import Language import Model.Site import Data.List (findIndex) import qualified Database.Persist as DB main :: IO () main = hspec spec spec :: Spec spec = withApp $ do describe "SitesR" $ do it "shows a list of sites for the cor...
null
https://raw.githubusercontent.com/thoughtbot/carnival/1cd4bd02ea6884b86020029257ab69ec3892a168/test/Handler/SitesSpec.hs
haskell
redirect redirect redirect redirect
module Handler.SitesSpec ( main , spec ) where import TestImport import Language import Model.Site import Data.List (findIndex) import qualified Database.Persist as DB main :: IO () main = hspec spec spec :: Spec spec = withApp $ do describe "SitesR" $ do it "shows a list of sites for the cor...
78b7983885471f746169f3a41f38161e9fe677ccac663a2a93b21da1e05fa023
falsetru/htdp
21.1.3.scm
; natural-f: (X Y -> Y) Y number X -> Y (define (natural-f f base n x) (cond [(zero? n) base] [else (f x (natural-f f base (sub1 n) x))])) (define (copy n obj) (natural-f cons empty n obj)) (define (n-adder n x) (natural-f + x n 1)) (define (n-multiplier n x) (natural-f + 0 n x)) (...
null
https://raw.githubusercontent.com/falsetru/htdp/4cdad3b999f19b89ff4fa7561839cbcbaad274df/21/21.1.3.scm
scheme
natural-f: (X Y -> Y) Y number X -> Y
(define (natural-f f base n x) (cond [(zero? n) base] [else (f x (natural-f f base (sub1 n) x))])) (define (copy n obj) (natural-f cons empty n obj)) (define (n-adder n x) (natural-f + x n 1)) (define (n-multiplier n x) (natural-f + 0 n x)) (require rackunit) (require rackunit/text...
bf6f3802fb4a3e15b60bef195bfc4bf0eb13efdbb73e397c8fa6b2f85b488a8b
tiensonqin/lymchat
invite.clj
(ns api.db.invite (:require [clojure.java.jdbc :as j] [api.db.util :refer [with-now]] [api.db.user :as user])) (defonce ^:private table "invites") (defn create "user-id want to be friend with invite-id." [db user-id invite-id] (try (j/insert! db table (with-now {:user_id user-id ...
null
https://raw.githubusercontent.com/tiensonqin/lymchat/824026607d30c12bc50afb06f677d1fa95ff1f2f/api/src/api/db/invite.clj
clojure
(ns api.db.invite (:require [clojure.java.jdbc :as j] [api.db.util :refer [with-now]] [api.db.user :as user])) (defonce ^:private table "invites") (defn create "user-id want to be friend with invite-id." [db user-id invite-id] (try (j/insert! db table (with-now {:user_id user-id ...
416ddc8fb2e109ed4f20b386726964be33d49c6060d4b91cb161cdbed2c5d945
gator1/jepsen
galera_test.clj
(ns jepsen.galera-test (:require [clojure.test :refer :all] [jepsen.core :refer [run!]] [jepsen.galera :refer :all] [jepsen.galera.dirty-reads :as dirty-reads])) (def version "7.4.7") ;(deftest sets-test' ; (is (:valid? (:results (run! (sets-test version)))))) ( deftest bank - ...
null
https://raw.githubusercontent.com/gator1/jepsen/1932cbd72cbc1f6c2a27abe0fe347ea989f0cfbb/galera/test/jepsen/galera_test.clj
clojure
(deftest sets-test' (is (:valid? (:results (run! (sets-test version))))))
(ns jepsen.galera-test (:require [clojure.test :refer :all] [jepsen.core :refer [run!]] [jepsen.galera :refer :all] [jepsen.galera.dirty-reads :as dirty-reads])) (def version "7.4.7") ( deftest bank - test ' ( is (: valid ? (: results ( run ! ( bank - test version 2 10 ) ) ) ...
c240586c4744b41f750ca6bfd0999312199eb3b012256829d1d005ec2148e9ff
AllAlgorithms/haskell
mergesort.hs
merge a [] = a merge [] b = b merge as@(ah:at) bs@(bh:bt) = if ah <= bh then ah:(merge at bs) else bh:(merge as bt) mergesort list | half == 0 = list | otherwise = let (a, b) = splitAt half list in merge (mergesort a) (mergesort b) where half = div (length list) 2 main = do print $ mergesort ...
null
https://raw.githubusercontent.com/AllAlgorithms/haskell/66611c3abad036db962d6d299dcb39c18b1b3cf8/algorithms/sorting/mergesort.hs
haskell
merge a [] = a merge [] b = b merge as@(ah:at) bs@(bh:bt) = if ah <= bh then ah:(merge at bs) else bh:(merge as bt) mergesort list | half == 0 = list | otherwise = let (a, b) = splitAt half list in merge (mergesort a) (mergesort b) where half = div (length list) 2 main = do print $ mergesort ...
1c01ad3b8c94161d1150af7cea636bd81487fb9f4ac289b06769cf286e70288c
facebook/pyre-check
classSummaryTest.ml
* Copyright ( c ) Meta Platforms , Inc. and affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in t...
null
https://raw.githubusercontent.com/facebook/pyre-check/10c375bea52db5d10b71cb5206fac7da9549eb0c/source/analysis/test/classSummaryTest.ml
ocaml
Test define field assigns. Implicit arguments in branches. `self` isn't special cased if a self parameter is passed into the function. Test class attributes. Simultaneous assignment Implicit attributes in tests. __slot__ attributes
* Copyright ( c ) Meta Platforms , Inc. and affiliates . * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree . * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in t...
ae59687dd5b0c2ecb239bd7bf1b107574bc772e47b7a4dee4b5900f11211eebf
abdulapopoola/SICPBook
Ex2.14.scm
#lang planet neil/sicp ;;helpers (define (make-interval a b) (cons a b)) (define (lower-bound interval) (car interval)) (define (upper-bound interval) (cdr interval)) (define (mul-interval x y) (let ((p1 (* (lower-bound x) (lower-bound y))) (p2 (* (lower-bound x) (upper-bound ...
null
https://raw.githubusercontent.com/abdulapopoola/SICPBook/c8a0228ebf66d9c1ddc5ef1fcc1d05d8684f090a/Chapter%202/2.1/Ex2.14.scm
scheme
helpers Different results
#lang planet neil/sicp (define (make-interval a b) (cons a b)) (define (lower-bound interval) (car interval)) (define (upper-bound interval) (cdr interval)) (define (mul-interval x y) (let ((p1 (* (lower-bound x) (lower-bound y))) (p2 (* (lower-bound x) (upper-bound y))) ...
a55ffed6d9a32554f6d9f9717bfc3894e1410cc2325522507dc8f765d70af266
reanimate/reanimate
Raster.hs
| Module : Reanimate . : Written by License : Unlicense Maintainer : Stability : experimental Portability : POSIX Tools for generating , manipulating , and embedding raster images . Module : Reanimate.Raster Copyright : Written by David Himmelstrup License : Unlicense...
null
https://raw.githubusercontent.com/reanimate/reanimate/d427ff5624d9ce1ce3f94e865bdd69f487bbaf4f/src/Reanimate/Raster.hs
haskell
:: Double -> Double -> FilePath -> SVG :: Hashable a => a -> SVG -> SVG :: Hashable a => a -> Width -> Height -> SVG -> FilePath :: PngSavable a => Image a -> SVG :: DynamicImage -> SVG :: Double -> Double -> LBS.ByteString -> SVG :: SVG -> DynamicImage :: Width -> Height -> SVG -> DynamicImage :: [String] -> ...
| Module : Reanimate . : Written by License : Unlicense Maintainer : Stability : experimental Portability : POSIX Tools for generating , manipulating , and embedding raster images . Module : Reanimate.Raster Copyright : Written by David Himmelstrup License : Unlicense...
b26f18d1a4d821ae38b1c3aa6a3440fd2e094139d1f1c3003302654f9fe6339e
fredrikt/yxa
url_param.erl
%%%------------------------------------------------------------------- File : url_param.erl @author < > %%% @doc This module handles parameters supplied in sip urls. %%% They must be unique - i.e. the same key can only occur %%% once. %%% %%% Note: keys and values are c...
null
https://raw.githubusercontent.com/fredrikt/yxa/85da46a999d083e6f00b5f156a634ca9be65645b/src/url_param.erl
erlang
------------------------------------------------------------------- @doc This module handles parameters supplied in sip urls. They must be unique - i.e. the same key can only occur once. Note: keys and values are currently stored as strings if standard values are repr...
File : url_param.erl @author < > but pattern matching and list : keysearch will be faster turn them all into atoms - as atoms are n't GCed ) @since 25 Oct 2004 by < > -module(url_param). -export([ to_norm/1, to_list/1, to_string_list/1, to_string/1, add/2, ad...
9824e99b859b7f327d7d56a9b10c3bb8616c1f1063ae205128009be9624fa6bf
nyu-acsys/drift
copy_intro.ml
USED : PEPM2013 as copy_intro USED: PEPM2013 as copy_intro *) let rec copy (x:int) = if x = 0 then 0 else 1 + copy (x - 1) let main_p (n:int) = assert (copy (copy n) = n) let main (w:unit) = let _ = main_p 100 in let _ = for i = 1 to 1000000 do main ( Random.int 1000 ) ...
null
https://raw.githubusercontent.com/nyu-acsys/drift/51a3160d74b761626180da4f7dd0bb950cfe40c0/tests/benchmarks_call/r_type/first/copy_intro.ml
ocaml
USED : PEPM2013 as copy_intro USED: PEPM2013 as copy_intro *) let rec copy (x:int) = if x = 0 then 0 else 1 + copy (x - 1) let main_p (n:int) = assert (copy (copy n) = n) let main (w:unit) = let _ = main_p 100 in let _ = for i = 1 to 1000000 do main ( Random.int 1000 ) ...
4a50504ca1e36ab4520e86d745d341fe5c273f5c70ec07427d4a51c953e84f6c
fyquah/hardcaml_zprize
load_sm.mli
* Sequence the loading of coefficients from DRAM into the parallel MTT cores . Inputs data into all parallel NTT cores . Runs multiple times during a pass . The ordering of data differs depending on the pass . Inputs data into all parallel NTT cores. Runs multiple times during a pass. The ordering...
null
https://raw.githubusercontent.com/fyquah/hardcaml_zprize/553b1be10ae9b977decbca850df6ee2d0595e7ff/zprize/ntt/hardcaml/src/load_sm.mli
ocaml
* Input data is valid * Start inputting a block of data. * Low while streaming. * Write address to internal RAM. * Write enable to internal RAM.
* Sequence the loading of coefficients from DRAM into the parallel MTT cores . Inputs data into all parallel NTT cores . Runs multiple times during a pass . The ordering of data differs depending on the pass . Inputs data into all parallel NTT cores. Runs multiple times during a pass. The ordering...
1ed3931668c9dbcd0002698c6eff09c3f0d76a31b71b84bbd25e36a81a7e0996
retro/keechma-next-realworld-app
home.cljs
(ns app.ui.pages.home (:require [keechma.next.helix.core :refer [with-keechma use-sub use-meta-sub dispatch call]] [keechma.next.helix.lib :refer [defnc]] [helix.core :as hx :refer [$ <> suspense]] [helix.dom :as d] ["react" :as react] ["react-dom" :as rdom]...
null
https://raw.githubusercontent.com/retro/keechma-next-realworld-app/47a14f4f3f6d56be229cd82f7806d7397e559ebe/src/app/ui/pages/home.cljs
clojure
(ns app.ui.pages.home (:require [keechma.next.helix.core :refer [with-keechma use-sub use-meta-sub dispatch call]] [keechma.next.helix.lib :refer [defnc]] [helix.core :as hx :refer [$ <> suspense]] [helix.dom :as d] ["react" :as react] ["react-dom" :as rdom]...
de4dd15d48ec04a869101ebfc583410e2b1e476bb23918c2548052cf5eed89a1
bsaleil/lc
etape1-lt2.scm
(let ((a 7) (b 3)) (println (< a b))) (let ((a -7) (b 3)) (println (< a b))) (let ((a 7) (b -3)) (println (< a b))) (let ((a -7) (b -3)) (println (< a b))) (let ((a 5) (b 5)) (println (< a b))) ;#f ;#t ;#f ;#t ;#f
null
https://raw.githubusercontent.com/bsaleil/lc/ee7867fd2bdbbe88924300e10b14ea717ee6434b/unit-tests/IFT3065/1/etape1-lt2.scm
scheme
#f #t #f #t #f
(let ((a 7) (b 3)) (println (< a b))) (let ((a -7) (b 3)) (println (< a b))) (let ((a 7) (b -3)) (println (< a b))) (let ((a -7) (b -3)) (println (< a b))) (let ((a 5) (b 5)) (println (< a b)))
9d723c8f6d4793a2f80cab413d4a897178414bdc871b3f9156ebbc0ad30423e6
anonymous-admin/anonymous
interpreter.erl
%%-------------------------------------------------------------------- @author ( C ) 2011 %% @doc interpreter.erl %% @end Created : 18 Nov 2011 by %%-------------------------------------------------------------------- -module(interpreter). -author('Sorush Arefipour'). -export([create_record/1, get_track...
null
https://raw.githubusercontent.com/anonymous-admin/anonymous/0d178f8f02dce74d5f76d78f81f70da9229a77cd/run%20Torrent%20client/interpreter.erl
erlang
-------------------------------------------------------------------- @doc interpreter.erl @end -------------------------------------------------------------------- ************************************************************************************************************ ****************************************...
@author ( C ) 2011 Created : 18 Nov 2011 by -module(interpreter). -author('Sorush Arefipour'). -export([create_record/1, get_tracker_response_info/1, init/1, handle_cast/2, handle_call/3, terminate/2]). -compile(export_all). -behaviour(gen_server). -include("defs.hrl"). @author start_link() -> ...
b5de794d96afcf604529facaa8602ed737db0f6da405deb96767241c052893fa
kupl/LearnML
original.ml
let rec iter ((n : int), (f : int -> int)) : int -> int = let rec compose (f : int -> int) (g : int -> int) (x : int) : int = f (g x) in if n = 0 then f else compose f (iter (n - 1, f)) let (_ : int) = iter (0, fun (x : int) -> 2 + x) 0 let (_ : int) = iter (1, fun (x : int) -> 2 + x) 0 let (_ : int) = iter (2,...
null
https://raw.githubusercontent.com/kupl/LearnML/c98ef2b95ef67e657b8158a2c504330e9cfb7700/result/cafe2/iter/sub34/original.ml
ocaml
let rec iter ((n : int), (f : int -> int)) : int -> int = let rec compose (f : int -> int) (g : int -> int) (x : int) : int = f (g x) in if n = 0 then f else compose f (iter (n - 1, f)) let (_ : int) = iter (0, fun (x : int) -> 2 + x) 0 let (_ : int) = iter (1, fun (x : int) -> 2 + x) 0 let (_ : int) = iter (2,...
a8944b7391a31789bfa2867011554b5414b5d6987d767dddcc7dab43f52b5c8f
FranklinChen/hugs98-plus-Sep2006
ALboolean.hs
-- #hide -------------------------------------------------------------------------------- -- | -- Module : Sound.OpenAL.AL.ALboolean Copyright : ( c ) 2003 - 2005 -- License : BSD-style (see the file libraries/OpenAL/LICENSE) -- -- Maintainer : -- Stability : provisional -- Portability : por...
null
https://raw.githubusercontent.com/FranklinChen/hugs98-plus-Sep2006/54ab69bd6313adbbed1d790b46aca2a0305ea67e/packages/OpenAL/Sound/OpenAL/AL/ALboolean.hs
haskell
#hide ------------------------------------------------------------------------------ | Module : Sound.OpenAL.AL.ALboolean License : BSD-style (see the file libraries/OpenAL/LICENSE) Maintainer : Stability : provisional Portability : portable This is a purely internal module for (un-)marshal...
Copyright : ( c ) 2003 - 2005 module Sound.OpenAL.AL.ALboolean ( marshalALboolean, unmarshalALboolean ) where import Sound.OpenAL.AL.BasicTypes ( ALboolean ) import Sound.OpenAL.Constants ( al_FALSE, al_TRUE ) marshalALboolean :: Bool -> ALboolean marshalALboolean False = al_FALSE marshalALboolean True ...
785f0e3685e677494157a41abdbb1a696a87c225fe83a2731dd023cf9a58f199
aggieben/weblocks
dropdown.lisp
(in-package :weblocks-test) ;;; Test dropdown-presentation render-view-field-value (deftest-html dropdown-presentation-render-view-field-value-1 (render-view-field-value nil (make-instance 'dropdown-presentation :choices (list *joe* *bob*)) (make-instance 'form-view-field :slot-n...
null
https://raw.githubusercontent.com/aggieben/weblocks/8d86be6a4fff8dde0b94181ba60d0dca2cbd9e25/test/views/types/presentations/dropdown.lisp
lisp
Test dropdown-presentation render-view-field-value
(in-package :weblocks-test) (deftest-html dropdown-presentation-render-view-field-value-1 (render-view-field-value nil (make-instance 'dropdown-presentation :choices (list *joe* *bob*)) (make-instance 'form-view-field :slot-name 'foo) (make-instance 'form-view) ni...
677dc2ce2560b284209687167d0a68953ba813581e254b9f128eabc53a64ff2a
pjotrp/guix
audio.scm
;;; GNU Guix --- Functional package management for GNU Copyright © 2015 < > Copyright © 2015 < > Copyright © 2015 < > Copyright © 2015 < > Copyright © 2015 < > ;;; ;;; This file is part of GNU Guix. ;;; GNU is free software ; you can redistribute it and/or modify it under the terms of ...
null
https://raw.githubusercontent.com/pjotrp/guix/96250294012c2f1520b67f12ea80bfd6b98075a2/gnu/packages/audio.scm
scheme
GNU Guix --- Functional package management for GNU This file is part of GNU Guix. you can redistribute it and/or modify it either version 3 of the License , or ( at your option) any later version. GNU Guix is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied wa...
Copyright © 2015 < > Copyright © 2015 < > Copyright © 2015 < > Copyright © 2015 < > Copyright © 2015 < > under the terms of the GNU General Public License as published by You should have received a copy of the GNU General Public License along with GNU . If not , see < / > . (defin...
9a985c2f7e0dd67ae14fbcd25595068ca2545b7634175711e5471e9cbe50de2a
thma/LtuPatternFactory
HigherOrder.hs
# LANGUAGE DeriveFoldable # module HigherOrder where import Prelude hiding (sum, product, map, filter) import Data . List ( unfoldr ) type Lookup key value = key -> Maybe value nada :: Lookup k v nada _ = Nothing abc :: Num v => Lookup String v abc "a" = Just 1 abc "b" = Just 2 abc "c" = Just 3 abc _ = Nothing ...
null
https://raw.githubusercontent.com/thma/LtuPatternFactory/f7be53c4660dde0302c7e69948ee1f1f3709d1a3/src/HigherOrder.hs
haskell
# LANGUAGE DeriveFoldable # module HigherOrder where import Prelude hiding (sum, product, map, filter) import Data . List ( unfoldr ) type Lookup key value = key -> Maybe value nada :: Lookup k v nada _ = Nothing abc :: Num v => Lookup String v abc "a" = Just 1 abc "b" = Just 2 abc "c" = Just 3 abc _ = Nothing ...
bf2ec56ebcfcdf7b14b95f0324b74c55f5867fb1a55257923f797cd85c3f01d5
UnkindPartition/monad-classes
Exec.hs
module Control.Monad.Classes.Exec ( MonadExec , exec , MonadExecN(..) , EffExec ) where import Control.Monad.Trans.Class import GHC.Prim (Proxy#, proxy#) import Control.Monad.Classes.Core import Control.Monad.Classes.Effects type instance CanDo IO (EffExec IO) = 'True class Monad m => MonadExecN (n :: Nat...
null
https://raw.githubusercontent.com/UnkindPartition/monad-classes/19e41e250615ad1121a958baed6c3081b0efb11b/Control/Monad/Classes/Exec.hs
haskell
| Lift an 'IO' action
module Control.Monad.Classes.Exec ( MonadExec , exec , MonadExecN(..) , EffExec ) where import Control.Monad.Trans.Class import GHC.Prim (Proxy#, proxy#) import Control.Monad.Classes.Core import Control.Monad.Classes.Effects type instance CanDo IO (EffExec IO) = 'True class Monad m => MonadExecN (n :: Nat...
3957c98ac35d0fa3768f9e64a1f5b280e74d91ba846746ad0ca90e1a3746b353
chiroptical/thinking-with-types
Lib.hs
{-# LANGUAGE DataKinds #-} # LANGUAGE FlexibleInstances # {-# LANGUAGE PolyKinds #-} {-# LANGUAGE ScopedTypeVariables #-} # LANGUAGE TypeApplications # {-# LANGUAGE TypeFamilies #-} # LANGUAGE TypeOperators # # LANGUAGE UndecidableInstances # module Lib where -- "%c%d%d...
null
https://raw.githubusercontent.com/chiroptical/thinking-with-types/781f90f1b08eb94ef3600c5b7da92dfaf9ea4285/Chapter9/src/Lib.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE PolyKinds # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # "%c%d%d" Char -> Int -> Int -> String "some number: %d" Int -> String \s -> "show number: " <> show s Referring to this as "printf operator" Given Int :<< ":" :<< Bool :<< "!" ...
# LANGUAGE FlexibleInstances # # LANGUAGE TypeApplications # # LANGUAGE TypeOperators # # LANGUAGE UndecidableInstances # module Lib where import Data.Kind ( Type ) import Data.Monoid ( (<>) ) import Data.Proxy ...
0777d8d873cb45b1e70b1756e3f0a186babe82219707dd0cc19fbae7b6b8857e
jgm/texmath
TeX.hs
{-# LANGUAGE OverloadedStrings #-} module Text.TeXMath.TeX (TeX(..), renderTeX, isControlSeq, escapeLaTeX) where import Data.Char (isLetter, isAlphaNum, isAscii) import qualified Data.Text as T | An intermediate representation of TeX math , ...
null
https://raw.githubusercontent.com/jgm/texmath/d9013d8ef61660be937ed769438058c92f459397/src/Text/TeXMath/TeX.hs
haskell
# LANGUAGE OverloadedStrings # No space before ^, _, or \limits, and no doubled up spaces
module Text.TeXMath.TeX (TeX(..), renderTeX, isControlSeq, escapeLaTeX) where import Data.Char (isLetter, isAlphaNum, isAscii) import qualified Data.Text as T | An intermediate representation of TeX math , to be used in rendering . data TeX ...
092a3b4f92833152f9fbd697a4b8eff94daa871ba495f061df8cc8858863bf7f
slyrus/mcclim-old
system.lisp
;;; -*- Mode: Lisp; Package: User -*- ;;; This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation ; either version 2 of the License , or ( at your option ) any later version . ;;; ;;; This libra...
null
https://raw.githubusercontent.com/slyrus/mcclim-old/354cdf73c1a4c70e619ccd7d390cb2f416b21c1a/Backends/CLX/system.lisp
lisp
-*- Mode: Lisp; Package: User -*- This library is free software; you can redistribute it and/or either This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU License along w...
modify it under the terms of the GNU Library General Public version 2 of the License , or ( at your option ) any later version . Library General Public License for more details . You should have received a copy of the GNU Library General Public Free Software Foundation , Inc. , 59 Temple Place - Suite 330 , ...
9ef4edc4e7b36a0b3e5ba199dae20db78774d67b1fded4ab19bf79c8dfb5bd2e
ocamllabs/ocaml-modular-implicits
b.ml
(***********************************************************************) (* *) (* OCaml *) (* *) ...
null
https://raw.githubusercontent.com/ocamllabs/ocaml-modular-implicits/92e45da5c8a4c2db8b2cd5be28a5bec2ac2181f1/testsuite/tests/lib-dynlink-native/b.ml
ocaml
********************************************************************* OCaml ...
, LexiFi Copyright 2007 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 . let () = print_endline "B is running";...
d314e0096b02ef3f2b4b9e54595c760101145bf60a100a4c21630f6c8a9dbe7b
prowdsponsor/fb
Action.hs
# LANGUAGE DeriveDataTypeable , FlexibleContexts , OverloadedStrings # module Facebook.Object.Action ( createAction , Action(..) ) where import Control.Arrow (first) import Control.Monad.Trans.Control (MonadBaseControl) import Data.Function (on) import Data.String (IsString(..)) import Data.Text (Text) impor...
null
https://raw.githubusercontent.com/prowdsponsor/fb/596f2633e017e1765c58a913949b4c4948a5455e/src/Facebook/Object/Action.hs
haskell
| Creates an Open Graph action on the user's timeline. Returns the 'Id' of the newly created action. For example: > now <- liftIO getCurrentTime > createAction "cook" > , "when" #= now ] > token ^ Action kind to be created. ^ Arguments of the action. ^ Optional app access token (o...
# LANGUAGE DeriveDataTypeable , FlexibleContexts , OverloadedStrings # module Facebook.Object.Action ( createAction , Action(..) ) where import Control.Arrow (first) import Control.Monad.Trans.Control (MonadBaseControl) import Data.Function (on) import Data.String (IsString(..)) import Data.Text (Text) impor...
2af1af1cc8d607284b596f2a4f50d4b29b2f3559e267594b9622c12cdd1aa895
SqrtMinusOne/channel-q
i3-balance-workspace.scm
(define-module (i3-balance-workspace) #:use-module (guix download) #:use-module (guix packages) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix build-system python) #:use-module (gnu packages python-xyz)) (define-public python-i3ipc (package (name "python-i3ipc") (version "2.2.1...
null
https://raw.githubusercontent.com/SqrtMinusOne/channel-q/5f97b36e9818acffd64a97f61f0aea2b38e62fbf/i3-balance-workspace.scm
scheme
No tests available
(define-module (i3-balance-workspace) #:use-module (guix download) #:use-module (guix packages) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix build-system python) #:use-module (gnu packages python-xyz)) (define-public python-i3ipc (package (name "python-i3ipc") (version "2.2.1...
1d329f98bd3fdb7a0c49a5a0b8bb3a4f575ccaa20b22edd96dc832f6f21e9315
jrm-code-project/LISP-Machine
config.lisp
-*- Mode : LISP ; Package : SYSTEM - INTERNALS ; Lowercase : T ; Base:8 ; : ZL -*- Copyright LISP Machine , Inc. 1984 ;; See filename "Copyright" for ;; licensing and release information. ;;;call this if you detect an error in a function that may be called early in lisp - reinitialize . In that case , the ca...
null
https://raw.githubusercontent.com/jrm-code-project/LISP-Machine/0a448d27f40761fafabe5775ffc550637be537b2/lambda/sys/config.lisp
lisp
Package : SYSTEM - INTERNALS ; Lowercase : T ; Base:8 ; : ZL -*- See filename "Copyright" for licensing and release information. call this if you detect an error in a function that may be called cause the machine to halt before entering the debugger, so the This says that the sharing disk driver is running, so o...
Copyright LISP Machine , Inc. 1984 early in lisp - reinitialize . In that case , the call to FERROR will print will at least tell you something about it first (defun config-ferror (condition &rest format-args) (print (list 'ferror condition format-args) cold-load-stream) (lexpr-funcall 'ferror condition forma...
b5cdae805360d2cf192cb3c04d3b081534f939b0a7c0192259dbeb116cd4cd73
MLstate/opalang
pass_DbSchemaGeneration.ml
Copyright © 2011 , 2012 MLstate This file is part of . is free software : you can redistribute it and/or modify it under the terms of the GNU Affero General Public License , version 3 , as published by the Free Software Foundation . is distributed in the hope that it will be us...
null
https://raw.githubusercontent.com/MLstate/opalang/424b369160ce693406cece6ac033d75d85f5df4f/compiler/qmlpasses/pass_DbSchemaGeneration.ml
ocaml
overriding db options display enforce output db_name -> file "--database", A.String (fun s -> try let (name, opt_string) = BaseString.split_char '@' s in let point = if name = "" then [] else [BaseString.remove_suffix ":" name] ...
Copyright © 2011 , 2012 MLstate This file is part of . is free software : you can redistribute it and/or modify it under the terms of the GNU Affero General Public License , version 3 , as published by the Free Software Foundation . is distributed in the hope that it will be us...
9dfd71ae255a04518af7c2e0aa131d84c51c9e09169ae1c0d171dadb5a3d9322
afiskon/erlang-http-proxy
http_proxy_sup.erl
-module(http_proxy_sup). -behaviour(supervisor). %% API -export([start_link/0]). %% Supervisor callbacks -export([init/1]). %% Helper macro for declaring children of supervisor -define(CHILD(I, Type), {I, {I, start_link, []}, permanent, 5000, Type, [I]}). %% =======================================================...
null
https://raw.githubusercontent.com/afiskon/erlang-http-proxy/081b641c914c822c4b77ba685f55a576686ca1fd/src/http_proxy_sup.erl
erlang
API Supervisor callbacks Helper macro for declaring children of supervisor =================================================================== API functions =================================================================== =================================================================== Supervisor callback...
-module(http_proxy_sup). -behaviour(supervisor). -export([start_link/0]). -export([init/1]). -define(CHILD(I, Type), {I, {I, start_link, []}, permanent, 5000, Type, [I]}). start_link() -> supervisor:start_link({local, ?MODULE}, ?MODULE, []). init([]) -> {ok, { {one_for_one, 5, 10}, [] ...
12e488f3a4b0d4cb37d0bc725147c66188c86a760e5c3199a864ce583832c7c8
RefactoringTools/HaRe
TiP.hs
module TiP where import HasBaseStruct import BaseSyntaxStruct import TI import TiLit(tcLit) import TiFields(tcFieldsPat) import import MUtils instance HasId i (PI i p) where ident = HsPId isId (HsPId x) = Just x isId _ = Nothing instance ( Fresh i , TypeId i , , i ( Typed i outp),HasLit outp ,...
null
https://raw.githubusercontent.com/RefactoringTools/HaRe/ef5dee64c38fb104e6e5676095946279fbce381c/old/tools/base/TI/TiP.hs
haskell
_ -> error ("pApp "++show p1)
module TiP where import HasBaseStruct import BaseSyntaxStruct import TI import TiLit(tcLit) import TiFields(tcFieldsPat) import import MUtils instance HasId i (PI i p) where ident = HsPId isId (HsPId x) = Just x isId _ = Nothing instance ( Fresh i , TypeId i , , i ( Typed i outp),HasLit outp ,...
aeb281ea61135e570ac940e420bdf415e898bec8576a666395f416b75a8fce6a
bos/rwh
divby4.hs
{-- snippet all --} ch20 / divby4.hs divBy :: Integral a => a -> [a] -> Maybe [a] divBy _ [] = return [] divBy _ (0:_) = fail "division by zero in divBy" divBy numerator (denom:xs) = do next <- divBy numerator xs return ((numerator `div` denom) : next) {-- /snippet all --}
null
https://raw.githubusercontent.com/bos/rwh/7fd1e467d54aef832f5476ebf5f4f6a898a895d1/examples/ch20/divby4.hs
haskell
- snippet all - - /snippet all -
ch20 / divby4.hs divBy :: Integral a => a -> [a] -> Maybe [a] divBy _ [] = return [] divBy _ (0:_) = fail "division by zero in divBy" divBy numerator (denom:xs) = do next <- divBy numerator xs return ((numerator `div` denom) : next)
99a068d7aecef14925cb0f66fa8cb34656cf21e7d0aaf281440d8abde8d2bc74
basho/riak_err
riak_err_monitor.erl
Copyright ( c ) 2010 Basho Technologies , Inc. All Rights Reserved . %% This file is provided to you under the Apache License , %% Version 2.0 (the "License"); you may not use this file except in compliance with the License . You may obtain %% a copy of the License at %% %% -2.0 %% %% Unless required by app...
null
https://raw.githubusercontent.com/basho/riak_err/60d9eba82951fe05cf4f75dd8045d56f0289d037/src/riak_err_monitor.erl
erlang
Version 2.0 (the "License"); you may not use this file a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. @doc Small server to monitor t...
Copyright ( c ) 2010 Basho Technologies , Inc. All Rights Reserved . This file is provided to you under the Apache License , except in compliance with the License . You may obtain software distributed under the License is distributed on an " AS IS " BASIS , WITHOUT WARRANTIES OR CONDITIONS OF ANY -modul...
3ff5c8fa75a427cf3813b9679cb27b965290f78504a97832e04774848f54a822
YoshikuniJujo/funpaala
addition.hs
import Data.Maybe (fromMaybe) import Text.Read (readMaybe) getInteger :: IO Integer getInteger = do inp <- getLine return . fromMaybe 0 $ readMaybe inp main :: IO () main = do putStrLn "Please input two number for add" n <- getInteger m <- getInteger putStrLn $ show (n + m)
null
https://raw.githubusercontent.com/YoshikuniJujo/funpaala/5366130826da0e6b1180992dfff94c4a634cda99/samples/39_learn_io/addition.hs
haskell
import Data.Maybe (fromMaybe) import Text.Read (readMaybe) getInteger :: IO Integer getInteger = do inp <- getLine return . fromMaybe 0 $ readMaybe inp main :: IO () main = do putStrLn "Please input two number for add" n <- getInteger m <- getInteger putStrLn $ show (n + m)
2664f18a4b8d1a3f90c7d3f90ef20e50932f73c1f24401359c0b6c575478edc0
braidchat/braid
search_test.clj
(ns braid.test.server.search-test (:require [clojure.test :refer :all] [braid.core.server.db :as db] [braid.chat.db.group :as group] [braid.chat.db.message :as message] [braid.chat.db.tag :as tag] [braid.chat.db.user :as user] [braid.search.server :as search] [braid.test.fixtures.db :refer [dr...
null
https://raw.githubusercontent.com/braidchat/braid/2e44eb6e77f1d203115f9b9c529bd865fa3d7302/test/braid/test/server/search_test.clj
clojure
(ns braid.test.server.search-test (:require [clojure.test :refer :all] [braid.core.server.db :as db] [braid.chat.db.group :as group] [braid.chat.db.message :as message] [braid.chat.db.tag :as tag] [braid.chat.db.user :as user] [braid.search.server :as search] [braid.test.fixtures.db :refer [dr...
7b3742f3208c53c746359b62946ee597f4408487cc40cdc9a1440acfd3e63c07
expipiplus1/vulkan
VK_AMD_shader_early_and_late_fragment_tests.hs
{-# language CPP #-} -- | = Name -- VK_AMD_shader_early_and_late_fragment_tests - device extension -- = = VK_AMD_shader_early_and_late_fragment_tests -- -- [__Name String__] -- @VK_AMD_shader_early_and_late_fragment_tests@ -- -- [__Extension Type__] -- Device extension -- -- [__Registered Extension Number__...
null
https://raw.githubusercontent.com/expipiplus1/vulkan/b1e33d1031779b4740c279c68879d05aee371659/src/Vulkan/Extensions/VK_AMD_shader_early_and_late_fragment_tests.hs
haskell
# language CPP # | = Name [__Name String__] @VK_AMD_shader_early_and_late_fragment_tests@ [__Extension Type__] Device extension [__Registered Extension Number__] [__Revision__] [__Extension and Version Dependencies__] [__Contact__] [__Extension Proposal__] <-Docs/tree/main/proposals/VK...
VK_AMD_shader_early_and_late_fragment_tests - device extension = = VK_AMD_shader_early_and_late_fragment_tests 322 1 - Requires support for Vulkan 1.0 - < -Docs/issues/new?body=[VK_AMD_shader_early_and_late_fragment_tests ] @tobski%0A*Here describe the issue or question you...
ab11d8c08e65e5a276922439f82baa039362a80d42f898023bff77167ca59037
greghendershott/vestige
expression.rkt
#lang racket/base (require (for-syntax racket/base) racket/format racket/match syntax/parse/define (only-in "log.rkt" log? log!) "data.rkt") (provide log-expression) (define-syntax-parser log-expression [(_ e:expr) #:with new-e (syntax/loc #'e (call...
null
https://raw.githubusercontent.com/greghendershott/vestige/ee7f0b35ba5e5d1a3e5ec90976c658bce24d0ba4/vestige-lib/vestige/private/logging/expression.rkt
racket
#lang racket/base (require (for-syntax racket/base) racket/format racket/match syntax/parse/define (only-in "log.rkt" log? log!) "data.rkt") (provide log-expression) (define-syntax-parser log-expression [(_ e:expr) #:with new-e (syntax/loc #'e (call...
9211ec3800e712a8a349cc442a0d14028a4094535c7bdcdf9161a8221f66b538
fulcrologic/fulcro-rad
debugging.cljc
(ns com.fulcrologic.rad.debugging "A ns containing helpers for debugging live components" (:require [clojure.string :as str] #?@(:clj [[com.fulcrologic.fulcro.dom-server :as dom :refer [div label input h2 table thead tr tbody td th]]] :cljs [["react-dom" :refer [createPortal]] [com.f...
null
https://raw.githubusercontent.com/fulcrologic/fulcro-rad/d2a40fdd7ca6ee0ec5fdb3897d5764bb6c5f7800/src/main/com/fulcrologic/rad/debugging.cljc
clojure
idents, not denormalized from form-props however, if you are using SUI, then
(ns com.fulcrologic.rad.debugging "A ns containing helpers for debugging live components" (:require [clojure.string :as str] #?@(:clj [[com.fulcrologic.fulcro.dom-server :as dom :refer [div label input h2 table thead tr tbody td th]]] :cljs [["react-dom" :refer [createPortal]] [com.f...
6b00c70506de237a714e5de66342c58c8ee47a32affbe0d8b8b66c155dee7b39
vouillon/osm
column.ml
OSM tools * Copyright ( C ) 2013 * * This program 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 , with linking exception ; * either version 2.1 of the License , or ( at your opti...
null
https://raw.githubusercontent.com/vouillon/osm/5b06ed6fc6c508b8187209628cf02129a119b50a/database/column.ml
ocaml
** ** ** ** let last = ref 0 in for j = j0 to j0 + chunk_size - 1 do let v = read_signed_varint a pos + !last in buf.(j) <- v; last := v done let last = ref 0 in for j = j0 to j0 + chunk_size - 1 do let v = read_signed_varint a pos + !last in buf.{j} <- v; last...
OSM tools * Copyright ( C ) 2013 * * This program 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 , with linking exception ; * either version 2.1 of the License , or ( at your opti...
f21642c595dfdcbdac7956387e5f1d83b71c292201d18c01cf3279f391db1a82
ddssff/refact-global-hse
SrcLoc.hs
-- | Utility functions for the haskell-src-exts type SrcLoc. # LANGUAGE BangPatterns , CPP , FlexibleInstances , PackageImports , ScopedTypeVariables , TemplateHaskell , UndecidableInstances # # OPTIONS_GHC -Wall -fno - warn - orphans # module SrcLoc * SpanInfo queries srcLoc , EndLoc(endLoc) -- * Loca...
null
https://raw.githubusercontent.com/ddssff/refact-global-hse/519a017009cae8aa1a3db1b46eb560d76bd9895d/tests/expected/decl9/SrcLoc.hs
haskell
| Utility functions for the haskell-src-exts type SrcLoc. * Location and span info for a piece of text * Split text at a location * Use span info to extract text (Annotated(ann), Module(..)) | Return a span that exactly covers the string s | Return the text before, within, and after a span This should not happe...
# LANGUAGE BangPatterns , CPP , FlexibleInstances , PackageImports , ScopedTypeVariables , TemplateHaskell , UndecidableInstances # # OPTIONS_GHC -Wall -fno - warn - orphans # module SrcLoc * SpanInfo queries srcLoc , EndLoc(endLoc) , spanOfText , endLocOfText , splitText , splits , spl...
e578f965e04edcade20e9ac192229eebf73d8ddfee0f4a75c15b3e4516a2a195
jacquev6/General
Tuples.ml
module Tuple2 = struct type ('a, 'b) t = 'a * 'b let make x y = (x, y) let get_0 (x, _) = x let get_1 (_, y) = y let flip (x, y) = (y, x) let compare (x, y) (x', y') ~compare_a ~compare_b = Compare.(match compare_a x x' with | LT -> LT | GT -> GT | EQ -> compare_b ...
null
https://raw.githubusercontent.com/jacquev6/General/5237123668e939c0cb83aa3e1c4756473336bc7e/src/Foundations/Tuples.ml
ocaml
module Tuple2 = struct type ('a, 'b) t = 'a * 'b let make x y = (x, y) let get_0 (x, _) = x let get_1 (_, y) = y let flip (x, y) = (y, x) let compare (x, y) (x', y') ~compare_a ~compare_b = Compare.(match compare_a x x' with | LT -> LT | GT -> GT | EQ -> compare_b ...
138aa8209190fe33ce7b1e5df9edc4a2d4e8555ccf89cda60a8e8af4df7e7e59
haskell-opengl/GLUT
TexGen.hs
TexGen.hs ( adapted from texgen.c which is ( c ) Silicon Graphics , Inc ) Copyright ( c ) 2002 - 2018 < > This file is part of HOpenGL and distributed under a BSD - style license See the file libraries / GLUT / LICENSE This program draws a texture mapped teapot with automatically generate...
null
https://raw.githubusercontent.com/haskell-opengl/GLUT/36207fa51e4c1ea1e5512aeaa373198a4a56cad0/examples/RedBook4/TexGen.hs
haskell
TexGen.hs ( adapted from texgen.c which is ( c ) Silicon Graphics , Inc ) Copyright ( c ) 2002 - 2018 < > This file is part of HOpenGL and distributed under a BSD - style license See the file libraries / GLUT / LICENSE This program draws a texture mapped teapot with automatically generate...
99e04984c8d86c5802f5290b58d0251c02ed1c77082e32e020e391524381ef9a
typedclojure/typedclojure
interop.clj
(ns clojure.core.typed.test.interop (:import (java.io File)) (:require [clojure.core.typed :as t])) (t/ann f File) (def f (File. "a")) (t/ann prt (t/U nil t/Str)) (def prt (.getParent ^File f)) (t/non-nil-return java.io.File/getName :all) (t/ann nme String) (def nme (.getName ^File f)) (t/ann Class->symbol [Cla...
null
https://raw.githubusercontent.com/typedclojure/typedclojure/5fd7cdf7941c6e7d1dd5df88bf44474fa35e1fca/typed/clj.checker/test/clojure/core/typed/test/interop.clj
clojure
(ns clojure.core.typed.test.interop (:import (java.io File)) (:require [clojure.core.typed :as t])) (t/ann f File) (def f (File. "a")) (t/ann prt (t/U nil t/Str)) (def prt (.getParent ^File f)) (t/non-nil-return java.io.File/getName :all) (t/ann nme String) (def nme (.getName ^File f)) (t/ann Class->symbol [Cla...
98bc4595237ede0ad1563de2f22a4b91812fd36226e285d5013c0ff0c1ecb776
AdaCore/why3
gnat_loc.mli
type context type simple_loc type region type loc = simple_loc list (* The type of locations. A location is a list of "simple" locations, and a simple location consists of file, line and column. *) val get_file : simple_loc -> string val get_line : simple_loc -> int val get_col : simple_loc -> int val explode : si...
null
https://raw.githubusercontent.com/AdaCore/why3/e0dc747dcbdbf58ddad668a234c7d05defc65cee/src/gnat/gnat_loc.mli
ocaml
The type of locations. A location is a list of "simple" locations, and a simple location consists of file, line and column. construct a location that consists of a single simple location with given file, line and column, and an optional context return the sloc of the original source check that a location i...
type context type simple_loc type region type loc = simple_loc list val get_file : simple_loc -> string val get_line : simple_loc -> int val get_col : simple_loc -> int val explode : simple_loc -> string * int * int val mk_loc : string -> int -> int -> context option -> loc val mk_loc_line : string -> int -> loc c...
a119ca77819ac8818d823901f3f10a35e3e0f2d599c59478af036dfd34965616
LaurentMazare/ocaml-dataframe
df_tests.ml
open Base open Dataframe open Df.R.Let_syntax let col_pi = "pi" let col_e1 = "e" let col_e2 = "sum_n 1/n!" let with_df ~f = let pi = Column.of_array N.int [| 3; 1; 4; 1; 5; 9; 2; 6; 5 |] in let e = Column.of_array N.float [| 2.; 7.; 1.; 8.; 2.; 8.; 1.; 8.; 2. |] in let df = Df.create_exn [ col_e1, P e; col_pi, ...
null
https://raw.githubusercontent.com/LaurentMazare/ocaml-dataframe/89bd3cb4035db505ac516303b04f4de7ffdff0be/src/tests/df_tests.ml
ocaml
open Base open Dataframe open Df.R.Let_syntax let col_pi = "pi" let col_e1 = "e" let col_e2 = "sum_n 1/n!" let with_df ~f = let pi = Column.of_array N.int [| 3; 1; 4; 1; 5; 9; 2; 6; 5 |] in let e = Column.of_array N.float [| 2.; 7.; 1.; 8.; 2.; 8.; 1.; 8.; 2. |] in let df = Df.create_exn [ col_e1, P e; col_pi, ...
a9a17dead812216fac21e14426b10ae3f09269d5a15cc5e8f57afe432d0ad468
chesseye/chesseye
dmov_map.mli
open Types type 'a t type key = dmove val empty : 'a t val find : key -> 'a t -> 'a val add : key -> 'a -> 'a list t -> 'a list t
null
https://raw.githubusercontent.com/chesseye/chesseye/23402e77292b1eb0758ecd61f30979166743c3b9/controller/dmov_map.mli
ocaml
open Types type 'a t type key = dmove val empty : 'a t val find : key -> 'a t -> 'a val add : key -> 'a -> 'a list t -> 'a list t
0f6ffb4c5020f39779668bc1428a9304abcc84069c2d96a9bf64ceb37d7e5cd8
jordanthayer/ocaml-search
gen_cost_function.ml
* Functions for normalizing costs . April 5 , 2011 Functions for normalizing costs. Christopher Wilt April 5, 2011 *) let make_cost_function ~max_cost_out ~min_cost_out ~max_cost_in ~min_cost_in = (** given the desired range, maps the specificed range linearly to the desired...
null
https://raw.githubusercontent.com/jordanthayer/ocaml-search/57cfc85417aa97ee5d8fbcdb84c333aae148175f/sliding_tiles/gen_cost_function.ml
ocaml
* given the desired range, maps the specificed range linearly to the desired output range.
* Functions for normalizing costs . April 5 , 2011 Functions for normalizing costs. Christopher Wilt April 5, 2011 *) let make_cost_function ~max_cost_out ~min_cost_out ~max_cost_in ~min_cost_in = assert (max_cost_out >= min_cost_out); assert (max_cost_in > min_cost_in); let ...
da6732671fc73487e1e4bfa6ceb0059009ea1ae9f1c67a8e16d85c8991ce580f
REPROSEC/dolev-yao-star
Lib_Exponentiation.ml
open Prims type 't exp = { one: 't ; fmul: 't -> 't -> 't ; lemma_one: unit ; lemma_fmul_assoc: unit ; lemma_fmul_comm: unit } let __proj__Mkexp__item__one : 't . 't exp -> 't = fun projectee -> match projectee with | { one; fmul; lemma_one; lemma_fmul_assoc; lemma_fmul_comm;_} -> one let __proj__...
null
https://raw.githubusercontent.com/REPROSEC/dolev-yao-star/d97a8dd4d07f2322437f186e4db6a1f4d5ee9230/concrete/hacl-star-snapshot/ml/Lib_Exponentiation.ml
ocaml
open Prims type 't exp = { one: 't ; fmul: 't -> 't -> 't ; lemma_one: unit ; lemma_fmul_assoc: unit ; lemma_fmul_comm: unit } let __proj__Mkexp__item__one : 't . 't exp -> 't = fun projectee -> match projectee with | { one; fmul; lemma_one; lemma_fmul_assoc; lemma_fmul_comm;_} -> one let __proj__...
16d9920adf445eef11e5768c21aac8f462fd8e5e2e7df034f61e60005fd2ab81
Mishio595/disml
client.ml
open Async include Dispatch type t = { sharder: Sharder.t } let start ?count ?compress ?(large=250) token = Client_options.token := token; Sharder.start ?count ?compress ~large_threshold:large () >>| fun sharder -> { sharder; } let set_status ?status ?kind ?name ?since ?url client = ...
null
https://raw.githubusercontent.com/Mishio595/disml/cbb1e47a6d358eace03790c07a1b85641f4ca366/lib/client.ml
ocaml
open Async include Dispatch type t = { sharder: Sharder.t } let start ?count ?compress ?(large=250) token = Client_options.token := token; Sharder.start ?count ?compress ~large_threshold:large () >>| fun sharder -> { sharder; } let set_status ?status ?kind ?name ?since ?url client = ...
6d83965e3500d6757df6e52c8d79ba284bbb2f2593d7b9ffdcbf2adc9beafe35
ocaml-sf/learn-ocaml-corpus
identity_compressor.ml
(* -------------------------------------------------------------------------- *) (* Building an alphabet out of a piece of text. *) let build_alphabet (text : text) : alphabet = let table = Hashtbl.create 256 in String.iter (fun symbol -> let freq = try Hashtbl.find table symbol with Not_f...
null
https://raw.githubusercontent.com/ocaml-sf/learn-ocaml-corpus/7dcf4d72b49863a3e37e41b3c3097aa4c6101a69/exercises/fpottier/huffman/wrong/identity_compressor.ml
ocaml
-------------------------------------------------------------------------- Building an alphabet out of a piece of text. -------------------------------------------------------------------------- Building encoding and decoding dictionaries out of an alphabet. The priority queue contains pairs of a tree and a fr...
let build_alphabet (text : text) : alphabet = let table = Hashtbl.create 256 in String.iter (fun symbol -> let freq = try Hashtbl.find table symbol with Not_found -> 0 in Hashtbl.replace table symbol (freq + 1) ) text; table module Q = BinomialQueue(struct type...
0634fc20c3a99ef2f313ecc0977d65a5dab2567c5b25b54b715e54581e73d65c
mirage/index
main.ml
open Crowbar module Fan = Index.Private.Fan module Int63 = Optint.Int63 let hash_size = 30 let entry_size = 56 let entry_sizeL = Int63.of_int entry_size let int_bound = 100_000_000 let bounded_int = map [ int ] (fun i -> abs i mod int_bound) let hash = map [ bytes ] Hashtbl.hash let hash_list = map [ list hash ] (List...
null
https://raw.githubusercontent.com/mirage/index/fe5e962534d192389484ecc63a25e4ab4668a2f0/test/fuzz/fan/main.ml
ocaml
open Crowbar module Fan = Index.Private.Fan module Int63 = Optint.Int63 let hash_size = 30 let entry_size = 56 let entry_sizeL = Int63.of_int entry_size let int_bound = 100_000_000 let bounded_int = map [ int ] (fun i -> abs i mod int_bound) let hash = map [ bytes ] Hashtbl.hash let hash_list = map [ list hash ] (List...
e6f4417eab1aed78aac0cbfa69287888351dd065110678adf0a1da36af52c929
jordwalke/rehp
jsoo_findlib_support.ml
Js_of_ocaml compiler * / * Copyright ( C ) 2015 Hugo Heuzard * * This program 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 , with linking exception ; * either version 2.1 of th...
null
https://raw.githubusercontent.com/jordwalke/rehp/f122b94f0a3f06410ddba59e3c9c603b33aadabf/compiler/findlib-support/jsoo_findlib_support.ml
ocaml
Js_of_ocaml compiler * / * Copyright ( C ) 2015 Hugo Heuzard * * This program 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 , with linking exception ; * either version 2.1 of th...
b53326a18eebc026bd499e8e27fb06af6eadb8496ee52fccf656aabd7fa8bd1b
zenspider/schemers
exercise.2.04.scm
#lang racket/base Exercise 2.4 : ;; Here is an alternative procedural representation of pairs. For this ;; representation, verify that `(car (cons x y))' yields `x' for any ;; objects `x' and `y'. (define (xcons x y) (lambda (m) (m x y))) (define (xcar z) (z (lambda (p q) p))) (xcar (xcons (xcons 'a 'b) 'c))...
null
https://raw.githubusercontent.com/zenspider/schemers/2939ca553ac79013a4c3aaaec812c1bad3933b16/sicp/ch_2/exercise.2.04.scm
scheme
Here is an alternative procedural representation of pairs. For this representation, verify that `(car (cons x y))' yields `x' for any objects `x' and `y'. What is the corresponding definition of `cdr'? (Hint: To verify that this works, make use of the substitution model of section
#lang racket/base Exercise 2.4 : (define (xcons x y) (lambda (m) (m x y))) (define (xcar z) (z (lambda (p q) p))) (xcar (xcons (xcons 'a 'b) 'c)) * Note 1 - 1 - 5 : : . ) (define (xcdr z) (z (lambda (p q) q))) (xcdr (xcons (xcons 'a 'b) 'c))
982e6a06efbb74def280e7bf6e3879b3b2ba13c86d66bf489e83ec4be528aa9e
prikhi/crypto-portfolio
EthereumGains.hs
# LANGUAGE NamedFieldPuns # module EthereumGains ( State , initial , getTransactions , updatePrice , view ) where import Brick import Control.Lens ((^.)) import Data.Maybe (mapMaybe) import qualified Brick.Widgets.Border as B import qualified Data.Map as Map import GainsTable import Types imp...
null
https://raw.githubusercontent.com/prikhi/crypto-portfolio/2b4722daa969b766434840bc53c888ad835234c6/src/EthereumGains.hs
haskell
| Build the Cache & Aggregates using the given Transactions. | Modify the ETH Currency Queues to Account for a new Transaction. Everything but Altcoin<->ETH trades are ignored & the (ETH / altcoin) ratio is used for the buy & sell prices. | Render the Ethereum Gains Table TODO: Show 1d/1w/1m % Change | Render t...
# LANGUAGE NamedFieldPuns # module EthereumGains ( State , initial , getTransactions , updatePrice , view ) where import Brick import Control.Lens ((^.)) import Data.Maybe (mapMaybe) import qualified Brick.Widgets.Border as B import qualified Data.Map as Map import GainsTable import Types imp...
8dc0a09297f4c125c2df3b88a9131c0777804bcc9f61d7d399eb00e2466b277d
yahoojapan/big3store
rbutil.erl
%% -*- Erlang -*- %% %% rbutil module %% 2013 - 2016 UP FAMNIT and Yahoo Japan Corporation %% @version 0.3 @since August , 2013 @author < > %% %% @doc Utility functions for rb and test related tools. %% -module(rbutil). -export([ rb_grep/1, rb_list/0, rb_list/1, rb_show/1, rb_filter_by_date/1, test...
null
https://raw.githubusercontent.com/yahoojapan/big3store/c4142395695a836fec60b7c202f9f12d46a8ed01/src/rbutil.erl
erlang
-*- Erlang -*- rbutil module @version 0.3 @doc Utility functions for rb and test related tools. ====================================================================== utility @doc test and halt. (to be called from command line) @doc Grep <A href="">report browser</A>'s log entries. For command...
2013 - 2016 UP FAMNIT and Yahoo Japan Corporation @since August , 2013 @author < > -module(rbutil). -export([ rb_grep/1, rb_list/0, rb_list/1, rb_show/1, rb_filter_by_date/1, test_halt/0, test_halt/1 ]). test_halt() -> M = [ glds, relation_element, asn, snapshot, ontsem ], O = [ verbose ],...
822ec8f6cdf496fe870f88505675a3c608a64e5b3b380dd5d493dba7de9ad178
unisonweb/unison
Function.hs
# LANGUAGE DataKinds # {-# LANGUAGE GADTs #-} # LANGUAGE RecordWildCards # # LANGUAGE UndecidableInstances # # LANGUAGE ViewPatterns # module Unison.Runtime.Foreign.Function ( ForeignFunc (..), ForeignConvention (..), mkForeign, ) where import Control.Concurrent (ThreadId) import Control.Concurrent.MVar (...
null
https://raw.githubusercontent.com/unisonweb/unison/cf278f9fb66ccb9436bf8a2eb4ab03fc7a92021d/parser-typechecker/src/Unison/Runtime/Foreign/Function.hs
haskell
# LANGUAGE GADTs # Foreign functions operating on stacks # OVERLAPPABLE # # OVERLAPPABLE #
# LANGUAGE DataKinds # # LANGUAGE RecordWildCards # # LANGUAGE UndecidableInstances # # LANGUAGE ViewPatterns # module Unison.Runtime.Foreign.Function ( ForeignFunc (..), ForeignConvention (..), mkForeign, ) where import Control.Concurrent (ThreadId) import Control.Concurrent.MVar (MVar) import Control.Co...
7cbc8e28cfbd154df7e2add05c3318aa59bc9d69eeb9473079fdb97ca288547c
ocaml-flambda/flambda-backend
includecore.ml
(**************************************************************************) (* *) (* OCaml *) (* *) ...
null
https://raw.githubusercontent.com/ocaml-flambda/flambda-backend/a73ceca4ea4f8afe4d9165726bdbf9db6241ead3/ocaml/typing/includecore.ml
ocaml
************************************************************************ OCaml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et the GNU Lesser General Public License version 2.1 , with the open Asttypes open Path open Types open Typedtree type position = Errortrace.position = First | Second ...
4a29619b510df34f0b055d51bd37e227f86c682336fc3c8ebc5cf46e425f21bf
ConsenSysMesh/Fae
RewardNametag.hs
import Blockchain.Fae.Contracts import Nametag body :: Reward -> FaeTX () body rwd = do nt <- getNametag rwd "Ryan Reich" deposit nt "self"
null
https://raw.githubusercontent.com/ConsenSysMesh/Fae/3ff023f70fa403e9cef80045907e415ccd88d7e8/documentation/tutorial/tutorial-2/RewardNametag.hs
haskell
import Blockchain.Fae.Contracts import Nametag body :: Reward -> FaeTX () body rwd = do nt <- getNametag rwd "Ryan Reich" deposit nt "self"
3f9b71a3798b34c3369933f202616ef55f0224227ba143b1dca205f8d7a1ffe7
DHSProgram/DHS-Indicators-SPSS
FP_USE.sps
* Encoding: windows-1252. * /***************************************************************************************************** Program: FP_USE.sps Purpose: Code contraceptive use indicators (ever and current use). Also source of method, brands, and information given. * Data inputs: IR dataset Data output...
null
https://raw.githubusercontent.com/DHSProgram/DHS-Indicators-SPSS/578e6d40eff9edebda7cf0db0d9a0a52a537d98c/Chap07_FP/FP_USE.sps
scheme
* Encoding: windows-1252. * /***************************************************************************************************** Program: FP_USE.sps Purpose: Code contraceptive use indicators (ever and current use). Also source of method, brands, and information given. * Data inputs: IR dataset Data output...
990e583de725d3fd541a44896143e70ef61e637874c5989dcf3b444d6966c165
awslabs/s2n-bignum
bignum_cmadd.ml
* Copyright Amazon.com , Inc. or its affiliates . All Rights Reserved . * SPDX - License - Identifier : Apache-2.0 OR ISC * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 OR ISC *) (* =================================================================...
null
https://raw.githubusercontent.com/awslabs/s2n-bignum/824c15f908d7a343af1b2f378cfedd36e880bdde/x86/proofs/bignum_cmadd.ml
ocaml
========================================================================= Multiply-accumulate of bignum by a single word. ========================================================================= *** print_literal_from_elf "x86/generic/bignum_cmadd.o";; *** PUSH (% rbx) SUB (% rdi) (...
* Copyright Amazon.com , Inc. or its affiliates . All Rights Reserved . * SPDX - License - Identifier : Apache-2.0 OR ISC * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 OR ISC *) let bignum_cmadd_mc = define_assert_from_elf "bignum_cmadd_mc" "...
11e2d6b08493f3d5e48f474180a56a4d3d4913cfe0a298825156c8ceee0fa666
JonyEpsilon/algebolic
expression_test.clj
; ; This file is part of algebolic. ; Copyright ( C ) 2014- , Imperial College , London , All rights reserved . ; Contributors : ; Released under the MIT license .. ; (ns algebolic.expression.expression-test (:use [clojure.test]) (:require [algebolic.expression.interpreter :as interpreter])) ;; * Helper f...
null
https://raw.githubusercontent.com/JonyEpsilon/algebolic/2872b2df9dc199f0c95deeb2cd85e50a2323e08a/test/algebolic/expression/expression_test.clj
clojure
This file is part of algebolic. * Helper functions * * Evaluation tests *
Copyright ( C ) 2014- , Imperial College , London , All rights reserved . Contributors : Released under the MIT license .. (ns algebolic.expression.expression-test (:use [clojure.test]) (:require [algebolic.expression.interpreter :as interpreter])) (defn approx-eq "Are two numbers nearly equal? The thr...
17598d1fd09da23b14d3de0c5a0cd177d4d904804ef8cfad706a78272655752e
travelping/ergw
k8s_tcp_dist.erl
Copyright 2021 , Travelping GmbH < > %% This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the License , or ( at your option ) any later version . -module(k8s_tcp_dist). ...
null
https://raw.githubusercontent.com/travelping/ergw/4de2ee6c73a00b88c7c9a52d1b229f3076463622/apps/k8s_dist/src/k8s_tcp_dist.erl
erlang
This program is free software; you can redistribute it and/or
Copyright 2021 , Travelping GmbH < > modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the License , or ( at your option ) any later version . -module(k8s_tcp_dist). -export([listen/1, accept/1, accept_connection/5, setup/5, clos...
c13c38540d40a956eaedffd938b1d6f9343ead6b4c15f0abb33ea52175100ca4
rfkm/zou
core_test.clj
(ns zou.framework.core-test (:require [clojure.test :as t] [midje.sweet :refer :all] [zou.component :as c] [zou.framework.bootstrap :as boot] [zou.framework.core :as sut])) (t/deftest boot-shutdown-test (fact (def core-var nil) (prerequisites (boot/make-...
null
https://raw.githubusercontent.com/rfkm/zou/228feefae3e008f56806589cb8019511981f7b01/framework/test/zou/framework/core_test.clj
clojure
The old instance bound to the var will be replaced with new one after stopping it
(ns zou.framework.core-test (:require [clojure.test :as t] [midje.sweet :refer :all] [zou.component :as c] [zou.framework.bootstrap :as boot] [zou.framework.core :as sut])) (t/deftest boot-shutdown-test (fact (def core-var nil) (prerequisites (boot/make-...
8d3e7fecdac29cfbb1dce14566183b9ee73161347ab842e4c3d3d10f204be2bf
aryx/xix
unzip.mli
s : version_control / unzip.mli * Unzip - inflate format decompression algorithm * Copyright ( C ) 2004 * Compliant with RFC 1950 and 1951 * * 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 ...
null
https://raw.githubusercontent.com/aryx/xix/60ce1bd9a3f923e0e8bb2192f8938a9aa49c739c/version_control/unzip.mli
ocaml
s: type [[Unzip.error_msg]] e: type [[Unzip.error_msg]] * wrap an input using "inflate" decompression algorithm. raises [Error] if an error occurs (this can only be caused by malformed input data). internals s: signature [[Unzip.inflate_data]] e: signature [[Unzip.inflate_data]]
s : version_control / unzip.mli * Unzip - inflate format decompression algorithm * Copyright ( C ) 2004 * Compliant with RFC 1950 and 1951 * * 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 ...
0ba7fb5437aacdb151a2c6965b2e7af2fb638568488fa223966e4e248a8cbd5d
uw-unsat/serval
shrd.rkt
#lang rosette (require "common.rkt") (provide shrd-r/m32-r32-imm8 shrd-r/m64-r64-imm8 shrd-r/m32-r32-cl shrd-r/m64-r64-cl) (define (interpret-shrd cpu dst src count) (define size (core:bv-size count)) (set! count (bvurem count (if (= size 64) (bv 64 size) (bv 32 size)))) (define v1 (cpu-gpr-ref cpu...
null
https://raw.githubusercontent.com/uw-unsat/serval/be11ecccf03f81b8bd0557acf8385a6a5d4f51ed/serval/x86/interp/shrd.rkt
racket
let's simply disallow such cases. AF is undefined. REX.W + 0F AC /r REX.W + 0F AD /r
#lang rosette (require "common.rkt") (provide shrd-r/m32-r32-imm8 shrd-r/m64-r64-imm8 shrd-r/m32-r32-cl shrd-r/m64-r64-cl) (define (interpret-shrd cpu dst src count) (define size (core:bv-size count)) (set! count (bvurem count (if (= size 64) (bv 64 size) (bv 32 size)))) (define v1 (cpu-gpr-ref cpu...
3abb255a9aac4053b1948ef9b0169036059840ac0174890edd6447e9d7d8be19
ermine-language/ermine
ParserTests.hs
module ParserTests ( parsingFileBasedTests , stdLibDir , main ) where import Control.Applicative import Control.Monad import Data.Either (isRight) import Data.Functor.Identity import qualified Data.HashMap.Strict as HM import qualified Data.HashSet as HS import Data.Traversable import Ermine.Console.Module imp...
null
https://raw.githubusercontent.com/ermine-language/ermine/bd58949ab56311be9e0d2506a900f3d77652566b/tests/unit-tests/ParserTests.hs
haskell
How someGraph should load. clean up the filename for the loader (remove the extension, and stdlib/Prelude/) TODO: probably want to have a stronger assertion that nice isRight... ,ParserTests.erminePreludeParsingTests
module ParserTests ( parsingFileBasedTests , stdLibDir , main ) where import Control.Applicative import Control.Monad import Data.Either (isRight) import Data.Functor.Identity import qualified Data.HashMap.Strict as HM import qualified Data.HashSet as HS import Data.Traversable import Ermine.Console.Module imp...
2390a2742ece3156edb842ad961c4b47b3d4666b731c7f26bbd89e259618643a
ocaml-batteries-team/batteries-included
bench_int.ml
cd .. & & / test_int.native -- external primitive_int_compare : int -> int -> int = "caml_int_compare" "noalloc" [@@warning "-3"] let std_compare = compare[@warning "-3"] let test_compare () = let length = 1000 in let input = Array.init length (fun _ -> BatRandom.(full_range_int (), full_range_int ())...
null
https://raw.githubusercontent.com/ocaml-batteries-team/batteries-included/e2fcc223ac79c456354be15b50d7fbc6825cb603/benchsuite/bench_int.ml
ocaml
this code actually mirrors an implementation that has been used as BatInt.compare
cd .. & & / test_int.native -- external primitive_int_compare : int -> int -> int = "caml_int_compare" "noalloc" [@@warning "-3"] let std_compare = compare[@warning "-3"] let test_compare () = let length = 1000 in let input = Array.init length (fun _ -> BatRandom.(full_range_int (), full_range_int ())...
b04bb8583b27f889de829e57ddef336112f8f78b37ca51994b938f065d360da6
videlalvaro/erlang-prime-sieve
primes_sieve.erl
%%%------------------------------------------------------------------- @author ( C ) 2014 , %%% @doc %%% %%% @end Created : 16 Feb 2014 by < > %%%------------------------------------------------------------------- -module(primes_sieve). -behaviour(gen_server). %% API -export([start/1]). -export([show_s...
null
https://raw.githubusercontent.com/videlalvaro/erlang-prime-sieve/80c0d7e2e3010eb0615cd3bcb93e4a865c7eb779/src/primes_sieve.erl
erlang
------------------------------------------------------------------- @doc @end ------------------------------------------------------------------- API gen_server callbacks =================================================================== API =================================================================== ---...
@author ( C ) 2014 , Created : 16 Feb 2014 by < > -module(primes_sieve). -behaviour(gen_server). -export([start/1]). -export([show_sieve/2]). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). -define(SERVER, ?MODULE). -record(state, {}). @spec s...
9536e30b6b2dd042c2f181195d3998542ef3197f7bb16e9654a45f7694448ad8
scalaris-team/scalaris
join_leave_SUITE.erl
2010 - 2013 Zuse Institute Berlin 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 di...
null
https://raw.githubusercontent.com/scalaris-team/scalaris/feb894d54e642bb3530e709e730156b0ecc1635f/test/join_leave_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 or implied. See the License for the specific language gov...
2010 - 2013 Zuse Institute Berlin Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , @author < > @doc Unit tests for src / dht_node_join.erl in combination with -module(join_leave_SUITE). -author(''). -vsn('$...
d7676cd232d0628b43bee11533042944eab3fd00ac3c2d65778e447b1be65679
mirage/irmin
logging.mli
* Copyright ( c ) 2022 Tarides < > * * Permission to use , copy , modify , and distribute this software for any * purpose with or without fee is hereby granted , provided that the above * copyright notice and this permission notice appear in all copies . * * THE SOFTWARE IS PROVIDED " AS IS " AND ...
null
https://raw.githubusercontent.com/mirage/irmin/abeee121a6db7b085b3c68af50ef24a8d8f9ed05/src/irmin/logging.mli
ocaml
* Copyright ( c ) 2022 Tarides < > * * Permission to use , copy , modify , and distribute this software for any * purpose with or without fee is hereby granted , provided that the above * copyright notice and this permission notice appear in all copies . * * THE SOFTWARE IS PROVIDED " AS IS " AND ...
239d8a506b39234670b79fac92d02de4001a94fe15753693e3e59f0e46b55904
ocharles/hadoom
Light.hs
module Light where import BasePrelude import Foreign (Storable(..), castPtr, nullPtr, plusPtr) import Foreign.C (CFloat) import Graphics.GL import Linear as L import Material import Util data LightShape = Omni | Spotlight (V3 CFloat) -- direction CFloat -- full radius CFloat ...
null
https://raw.githubusercontent.com/ocharles/hadoom/13d5ea590282cdbbd343fa4a3d9144d7a1bcf9fd/hadoom/Light.hs
haskell
direction full radius penumbra radius rotation matrix
module Light where import BasePrelude import Foreign (Storable(..), castPtr, nullPtr, plusPtr) import Foreign.C (CFloat) import Graphics.GL import Linear as L import Material import Util data LightShape = Omni deriving (Show) data Light = Light {lightPos :: V3 CFloat ,lightColor :: V3 CFloat ,l...
878b539e77c0497f511215a4c3bf49f247bb54c3236dba425bdc30a9c4c1b674
mbj/mhs
Types.hs
module MRIO.Log.Types where import Control.Concurrent (ThreadId) import Data.Time.Clock (UTCTime) import MPrelude data Message = Message { severity :: Severity , message :: Text , threadId :: ThreadId , time :: UTCTime } data Severity = Debug | Info | Warn | Error deriving stock (Show, Eq, O...
null
https://raw.githubusercontent.com/mbj/mhs/d7b24948a7a18f5ea1fa1e7992539f43aafc38d8/mrio-log/src/MRIO/Log/Types.hs
haskell
module MRIO.Log.Types where import Control.Concurrent (ThreadId) import Data.Time.Clock (UTCTime) import MPrelude data Message = Message { severity :: Severity , message :: Text , threadId :: ThreadId , time :: UTCTime } data Severity = Debug | Info | Warn | Error deriving stock (Show, Eq, O...
4f2ab906ee063ce6d1f718ffa7fad0b4a9f1a9947569b9c142a17d2d78bfc5df
jeapostrophe/opencl
utils.rkt
#lang racket (require opencl/c ffi/cvector ffi/unsafe/cvector ffi/unsafe) (provide cvector->vector) (provide init-cl) (provide init-cl-cps) (provide init-cl-build) (provide time-real) (provide print-array) (provide print-array:_cl_float) (provide fill-random:_cl_uint) (provide fill-random:_c...
null
https://raw.githubusercontent.com/jeapostrophe/opencl/f984050b0c02beb6df186d1d531c4a92a98df1a1/tests/opencl/samples/atiSamples/atiUtils/utils.rkt
racket
#lang racket (require opencl/c ffi/cvector ffi/unsafe/cvector ffi/unsafe) (provide cvector->vector) (provide init-cl) (provide init-cl-cps) (provide init-cl-build) (provide time-real) (provide print-array) (provide print-array:_cl_float) (provide fill-random:_cl_uint) (provide fill-random:_c...
b393f1450b0893acb1bb8f915b77eea012ab027b82675b26af268d64dc950352
jlongster/gambit-iphone-example
app4.scm
(include "obj-loader2.scm") (define mesh #f) (define (init) (let* ((fov 40.) (aspect (/ (UIView-width (current-view)) (UIView-height (current-view)))) (half-fov-y (/ fov aspect 2))) (glMatrixMode GL_PROJECTION) (glLoadIdentity) (perspective fov aspect 1. 1000.) ...
null
https://raw.githubusercontent.com/jlongster/gambit-iphone-example/e55d915180cb6c57312cbb683d81823ea455e14f/lib/apps/app4.scm
scheme
(make-vec3d 0. (sin half-fov-y) (cos half-fov-y))
(include "obj-loader2.scm") (define mesh #f) (define (init) (let* ((fov 40.) (aspect (/ (UIView-width (current-view)) (UIView-height (current-view)))) (half-fov-y (/ fov aspect 2))) (glMatrixMode GL_PROJECTION) (glLoadIdentity) (perspective fov aspect 1. 1000.) ...
e50489a2a86f75cea2098c6b0baa465a236c56b816439180fa5c03735a878db2
emil0r/reverie
module.clj
(ns reverie.specs.module (:require [clojure.spec.alpha :as spec] [reverie.specs.route])) (spec/def :reverie.module/name symbol?)
null
https://raw.githubusercontent.com/emil0r/reverie/a29c223b7326e6d5a5e0874d33c37ff2fa0dfd4d/reverie-core/src/reverie/specs/module.clj
clojure
(ns reverie.specs.module (:require [clojure.spec.alpha :as spec] [reverie.specs.route])) (spec/def :reverie.module/name symbol?)
b621b98c24b7747d050044f69b61689d8dd9511a0519648c2000857d99c7d370
Twinside/Juicy.Pixels
Metadata.hs
# LANGUAGE CPP # {-# LANGUAGE GADTs #-} {-# LANGUAGE OverloadedStrings #-} module Codec.Picture.Png.Internal.Metadata( extractMetadatas , encodeMetadatas ) where #if !MIN_VERSION_base(4,8,0) import Control.Applicative( (<$>), (<*>), pure ) import Data.M...
null
https://raw.githubusercontent.com/Twinside/Juicy.Pixels/ab41b84403699a7f4d290685e690fbaff42ed95f/src/Codec/Picture/Png/Internal/Metadata.hs
haskell
# LANGUAGE GADTs # # LANGUAGE OverloadedStrings # compression type
# LANGUAGE CPP # module Codec.Picture.Png.Internal.Metadata( extractMetadatas , encodeMetadatas ) where #if !MIN_VERSION_base(4,8,0) import Control.Applicative( (<$>), (<*>), pure ) import Data.Monoid( Monoid, mempty ) import Data.Foldable( foldMap ) #e...
c71702fd2a5ef025e00e56434a576340bbc65313c9da6a3dc4f9ff3823f41c21
ayakout/tcp_router
tcp_conf.erl
-module(tcp_conf). -export([load_balance/0]). -define(APP, tcp_router). load_balance() -> get_env(load_balance). get_env(Key) -> case application:get_env(tcp_router, load_balance) of {ok, Value} -> Value; undefined -> throw({undefined_config, Key}) end.
null
https://raw.githubusercontent.com/ayakout/tcp_router/57c23ca593890f8354ca958c87b7d0894f05601a/src/tcp_conf.erl
erlang
-module(tcp_conf). -export([load_balance/0]). -define(APP, tcp_router). load_balance() -> get_env(load_balance). get_env(Key) -> case application:get_env(tcp_router, load_balance) of {ok, Value} -> Value; undefined -> throw({undefined_config, Key}) end.
52ace17339ec2341b9dd44919dc5567dc9ca3c94a946a34db1ac77adb0dbb03c
alexandroid000/improv
KillResponse.hs
{-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE DeriveDataTypeable #-} # LANGUAGE DeriveGeneric # # LANGUAGE TemplateHaskell # module Ros.Turtlesim.KillResponse where import qualified Prelude as P import Prelude ((.), (+), (*)) import qualified Data.Typeable as T import Control.Applicative import Ros.Internal.RosBinary...
null
https://raw.githubusercontent.com/alexandroid000/improv/ef0f4a6a5f99a9c7ff3d25f50529417aba9f757c/roshask/msgs/Turtlesim/Ros/Turtlesim/KillResponse.hs
haskell
# LANGUAGE OverloadedStrings # # LANGUAGE DeriveDataTypeable #
# LANGUAGE DeriveGeneric # # LANGUAGE TemplateHaskell # module Ros.Turtlesim.KillResponse where import qualified Prelude as P import Prelude ((.), (+), (*)) import qualified Data.Typeable as T import Control.Applicative import Ros.Internal.RosBinary import Ros.Internal.Msg.MsgInfo import qualified GHC.Generics as G imp...
33d3ab440064eb2c6a543c25c2f406be59b394c66b3215a2b8701b678a910ed7
code-iai/asimov
project.clj
(defproject asimov "0.1.3-SNAPSHOT" :description "A clojure client library for the robot operating system ROS." :url "-iai/asimov" :license {:name "The MIT License" :url "-license.php"} :dependencies [[org.clojure/clojure "1.7.0"] [org.clojure/core.async "0.2.374"] ...
null
https://raw.githubusercontent.com/code-iai/asimov/51de61bcca31007f91ffa95345d241415ea8acf8/project.clj
clojure
(defproject asimov "0.1.3-SNAPSHOT" :description "A clojure client library for the robot operating system ROS." :url "-iai/asimov" :license {:name "The MIT License" :url "-license.php"} :dependencies [[org.clojure/clojure "1.7.0"] [org.clojure/core.async "0.2.374"] ...
a2e5e30dfe66d4b62a067c65f64b1ab8ff4e6bbea2214681e8aa38e83aaca6ee
rtrusso/scp
char.scm
(define test-case-number 0) (define-syntax test (syntax-rules () ((_ expression) (begin (set! test-case-number (+ test-case-number 1)) (display "case ") (display test-case-number) (display ": ") (newline) (display 'expression) ...
null
https://raw.githubusercontent.com/rtrusso/scp/2051e76df14bd36aef81aba519ffafa62b260f5c/src/tests/char.scm
scheme
(define test-case-number 0) (define-syntax test (syntax-rules () ((_ expression) (begin (set! test-case-number (+ test-case-number 1)) (display "case ") (display test-case-number) (display ": ") (newline) (display 'expression) ...
16e3a647da423d720449b3a491317c0a1aeaa69b64e35c947e28b7a875133570
haskell-repa/repa
Bytes.hs
| Conversions for " Data . ByteString " things . module Data.Repa.Convert.Format.Bytes (VarBytes (..)) where import Data.Repa.Convert.Internal.Format import Data.Repa.Convert.Internal.Packable import Data.Word import GHC.Exts import Prelude hiding (fail) import Data.ByteStrin...
null
https://raw.githubusercontent.com/haskell-repa/repa/c867025e99fd008f094a5b18ce4dabd29bed00ba/repa-convert/Data/Repa/Convert/Format/Bytes.hs
haskell
| Variable length sequence of bytes, represented as a `Data.ByteString`. Pointer to active bytes. Copy bytes from the bytestring to the destination buffer. # INLINE packer_VarBytes # Length of the input buffer. Scan through the input to see how long the result will be. Copy the desired bytes into a new buffer.
| Conversions for " Data . ByteString " things . module Data.Repa.Convert.Format.Bytes (VarBytes (..)) where import Data.Repa.Convert.Internal.Format import Data.Repa.Convert.Internal.Packable import Data.Word import GHC.Exts import Prelude hiding (fail) import Data.ByteStrin...
a45abbec25cfb267ba2374402d626a4b6df59646a7093294807cdfd5582bf220
Elzair/nazghul
chanticleer.scm
;;---------------------------------------------------------------------------- ;; Constants ;;---------------------------------------------------------------------------- ;;---------------------------------------------------------------------------- ;; Schedule ;; ;; The schedule below is for the place "Trigrave" ;;--...
null
https://raw.githubusercontent.com/Elzair/nazghul/8f3a45ed6289cd9f469c4ff618d39366f2fbc1d8/worlds/haxima-1.002/chanticleer.scm
scheme
---------------------------------------------------------------------------- Constants ---------------------------------------------------------------------------- ---------------------------------------------------------------------------- Schedule The schedule below is for the place "Trigrave" -------------------...
(kern-mk-sched 'sch_chant (list 0 0 trigrave-east-west-road "drunk") (list 2 0 trigrave-chants-bed "sleeping") (list 12 0 trigrave-tavern-hall "working") (list 23 0 trigrave-east-west-road "drunk") ) Quest...
ec014b16168a1a46c4c7ccc0a7ab47227a26b9e2a9f4fa26c25adac0cd1feab2
ghc/packages-containers
Internal.hs
# LANGUAGE CPP # {-# LANGUAGE BangPatterns #-} # LANGUAGE PatternGuards # #if __GLASGOW_HASKELL__ {-# LANGUAGE DeriveDataTypeable, StandaloneDeriving #-} #endif #if !defined(TESTING) && defined(__GLASGOW_HASKELL__) # LANGUAGE Trustworthy # #endif #if __GLASGOW_HASKELL__ >= 708 # LANGUAGE RoleAnnotations # # LANGUAGE Ty...
null
https://raw.githubusercontent.com/ghc/packages-containers/97fe43c54c5c8a9b93ecf5abd7509e8085b63d41/containers/src/Data/Set/Internal.hs
haskell
# LANGUAGE BangPatterns # # LANGUAGE DeriveDataTypeable, StandaloneDeriving # --------------------------------------------------------------------------- | Module : Data.Set.Internal License : BSD-style Maintainer : Portability : portable = WARNING This module is considered __internal__. The ...
# LANGUAGE CPP # # LANGUAGE PatternGuards # #if __GLASGOW_HASKELL__ #endif #if !defined(TESTING) && defined(__GLASGOW_HASKELL__) # LANGUAGE Trustworthy # #endif #if __GLASGOW_HASKELL__ >= 708 # LANGUAGE RoleAnnotations # # LANGUAGE TypeFamilies # #endif # OPTIONS_HADDOCK not - home # #include "containers.h" Copyri...
b531c4e6d680791d2ce5eec626c770c3cbf9187b5af88c0c49e646b471bbfed7
diku-dk/futhark
TypesTests.hs
module Language.Futhark.TypeChecker.TypesTests (tests) where import Data.Bifunctor (first) import Data.List (isInfixOf) import Data.Map qualified as M import Data.Text qualified as T import Futhark.FreshNames import Futhark.Util.Pretty (docText, prettyTextOneLine) import Language.Futhark import Language.Futhark.Semant...
null
https://raw.githubusercontent.com/diku-dk/futhark/bb18be7dd7967f317efa3218eeb5f0f3771e4d1f/unittests/Language/Futhark/TypeChecker/TypesTests.hs
haskell
We hack up an environment with some predefined type abbreviations for testing. This is all prettyString sensitive to the specific unique names, so we have to be careful! Some of these tests may be a bit fragile, in that they depend on internal renumbering, which can be arbitrary.
module Language.Futhark.TypeChecker.TypesTests (tests) where import Data.Bifunctor (first) import Data.List (isInfixOf) import Data.Map qualified as M import Data.Text qualified as T import Futhark.FreshNames import Futhark.Util.Pretty (docText, prettyTextOneLine) import Language.Futhark import Language.Futhark.Semant...
093ebf109ea250b36112927b5fede50811b9bca6204c8ca06b49a2c3babeba94
jmtd/hwadtools
Bits.hs
-- bits experiments module Bits( skill1_2 , skill3 , skill4_5 , ambush , multiplayer , not_dm , not_coop , friendly ) where import Data.Bits import Wad skill1_2 :: Bits a => a -> Bool skill1_2 a = testBit a 0 skill3 a = t...
null
https://raw.githubusercontent.com/jmtd/hwadtools/e5639a068edf8d88f3e560cbc3708593223e3109/Bits.hs
haskell
bits experiments boom mbf ---------------------------------------------------------------------------- test data MAP01 plasma
module Bits( skill1_2 , skill3 , skill4_5 , ambush , multiplayer , not_dm , not_coop , friendly ) where import Data.Bits import Wad skill1_2 :: Bits a => a -> Bool skill1_2 a = testBit a 0 skill3 a = testBit a 1 skill4_5 ...
96abb84c6763f8d8aa0d8b295b2c2f6e8af349b99d31db401acd0ce441b137ae
Xandaros/GithubNotify
Main.hs
{-# LANGUAGE OverloadedStrings #-} # LANGUAGE MultiParamTypeClasses # module Main where import Control.Applicative import Control.Concurrent (threadDelay) import Control.Exception import Control.Lens import Control.Monad import Control.Monad.Reader import Control.Monad.Trans import Control.Monad.Trans.Resource import ...
null
https://raw.githubusercontent.com/Xandaros/GithubNotify/82781af7d83a5d7e3c0026be39840daf4e1253c2/src/Main.hs
haskell
# LANGUAGE OverloadedStrings # fromJust *should* be safe TODO: Cleanup
# LANGUAGE MultiParamTypeClasses # module Main where import Control.Applicative import Control.Concurrent (threadDelay) import Control.Exception import Control.Lens import Control.Monad import Control.Monad.Reader import Control.Monad.Trans import Control.Monad.Trans.Resource import Data.Aeson import qualified Data.By...
a5167a7158d5271ac6774bc6c6c441b0471a116f5f07f31ee7130cf3a2177f15
input-output-hk/plutus
GenerateTypes.hs
{-# LANGUAGE OverloadedStrings #-} # LANGUAGE TupleSections # module PlutusCore.Generators.QuickCheck.GenerateTypes where import PlutusCore.Generators.QuickCheck.Builtin import PlutusCore.Generators.QuickCheck.Common import PlutusCore.Generators.QuickCheck.GenerateKinds () import PlutusCore.Generators.QuickCheck...
null
https://raw.githubusercontent.com/input-output-hk/plutus/867fd234301d28525404de839d9a3c8220cbea63/plutus-core/testlib/PlutusCore/Generators/QuickCheck/GenerateTypes.hs
haskell
# LANGUAGE OverloadedStrings # * Generators for well-kinded types | Generate "small" types at a given kind such as builtins, bound variables, bound datatypes, and lambda abstractions \ t0 ... tn. T There's always an atomic type of a given kind, hence the usage of 'deliver': we definitely have builtin types of kind...
# LANGUAGE TupleSections # module PlutusCore.Generators.QuickCheck.GenerateTypes where import PlutusCore.Generators.QuickCheck.Builtin import PlutusCore.Generators.QuickCheck.Common import PlutusCore.Generators.QuickCheck.GenerateKinds () import PlutusCore.Generators.QuickCheck.GenTm import PlutusCore.Builtin i...
e9aa717a7c6b86497aedf2c825f438be38f88f34d93c15f6216ea4dc04584439
facebook/duckling
Rules.hs
Copyright ( c ) 2016 - present , Facebook , Inc. -- All rights reserved. -- -- This source code is licensed under the BSD-style license found in the -- LICENSE file in the root directory of this source tree. {-# LANGUAGE OverloadedStrings #-} module Duckling.TimeGrain.NL.Rules ( rules ) where import Data.Text (...
null
https://raw.githubusercontent.com/facebook/duckling/72f45e8e2c7385f41f2f8b1f063e7b5daa6dca94/Duckling/TimeGrain/NL/Rules.hs
haskell
All rights reserved. This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree. # LANGUAGE OverloadedStrings #
Copyright ( c ) 2016 - present , Facebook , Inc. module Duckling.TimeGrain.NL.Rules ( rules ) where import Data.Text (Text) import Data.String import Prelude import Duckling.Dimensions.Types import Duckling.Types import qualified Duckling.TimeGrain.Types as TG grains :: [(Text, String, TG.Grain)] grains = [ (...
203fe20f61f17a5ec7b6c3bd6406836d450c6da4af16d6af42450a1500189daa
ucsd-progsys/nate
display.mli
(***********************************************************************) (* ocamlbuild *) (* *) , , projet Gallium , INRIA Rocquencourt (* ...
null
https://raw.githubusercontent.com/ucsd-progsys/nate/8b1267cd8b10283d8bc239d16a28c654a4cb8942/eval/sherrloc/easyocaml%2B%2B/ocamlbuild/display.mli
ocaml
********************************************************************* ocamlbuild ...
, , projet Gallium , INRIA Rocquencourt Copyright 2007 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 . $ I d : display.mli , v 1.1 2007/02/07 08:59:13 erta...
d77c16b74a6270dc9d24158f002baca1770c9a5453e829216b0ea32e1ca6e8ec
ftovagliari/ocamleditor
menu_project.ml
OCamlEditor Copyright ( C ) 2010 - 2014 This file is part of OCamlEditor . OCamlEditor is free software : you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3 of the License , or ( at y...
null
https://raw.githubusercontent.com/ftovagliari/ocamleditor/53284253cf7603b96051e7425e85a731f09abcd1/src/menu_project.ml
ocaml
Clean default target Compile Build Run current Clean... Build... Build with dependencies... Run... Compile file Targets Generate build script ~stock:`REFRESH Callback
OCamlEditor Copyright ( C ) 2010 - 2014 This file is part of OCamlEditor . OCamlEditor is free software : you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3 of the License , or ( at y...
6599f418bd5daa81074dfd90ebec433a96de067f63b99b9c790a1087b7295eaa
Clojure2D/clojure2d-examples
ch4_sphere.clj
(ns rt-in-weekend.ch4-sphere (:require [clojure2d.core :refer :all] [clojure2d.pixels :as p] [clojure2d.extra.utils :as u] [fastmath.vector :as v] [rt-in-weekend.ray :refer :all] [fastmath.core :as m]) (:import [fastmath.vector Vec3] [rt_in_week...
null
https://raw.githubusercontent.com/Clojure2D/clojure2d-examples/9de82f5ac0737b7e78e07a17cf03ac577d973817/src/rt_in_weekend/ch4_sphere.clj
clojure
(save img "results/rt-in-weekend/sphere.jpg")
(ns rt-in-weekend.ch4-sphere (:require [clojure2d.core :refer :all] [clojure2d.pixels :as p] [clojure2d.extra.utils :as u] [fastmath.vector :as v] [rt-in-weekend.ray :refer :all] [fastmath.core :as m]) (:import [fastmath.vector Vec3] [rt_in_week...
06fe3688ec389f778d46b647bd02ccf4b6349b51b4dd1da72a84d155cd7af639
babashka/neil
test.cljc
(ns babashka.neil.test (:require #?(:bb [babashka.deps :as deps]) [babashka.fs :as fs] [babashka.process :refer [shell]] [clojure.edn :as edn])) (def neil-test-spec {:dirs {:coerce []} :nses {:coerce []} :patterns {:coerce []} :vars {:coerce ...
null
https://raw.githubusercontent.com/babashka/neil/77288d4851802341798e001f5b837a0957de4cf1/src/babashka/neil/test.cljc
clojure
(ns babashka.neil.test (:require #?(:bb [babashka.deps :as deps]) [babashka.fs :as fs] [babashka.process :refer [shell]] [clojure.edn :as edn])) (def neil-test-spec {:dirs {:coerce []} :nses {:coerce []} :patterns {:coerce []} :vars {:coerce ...
63158108051f4f0ea7b2b9cf13b07bf0422de8266934c6b26be49514a616dc43
timothypratley/clojure-ebnf-grammar
parse.clj
(ns clojure-ebnf-grammar.parse (:require [instaparse.core :as insta] [clojure.java.io :as io])) (insta/defparser parse-clojure (io/resource "clojure.ebnf") :auto-whitespace :comma)
null
https://raw.githubusercontent.com/timothypratley/clojure-ebnf-grammar/1dae59a3514ca7d2468310a6ce3ee63ba0508f60/src/clojure_ebnf_grammar/parse.clj
clojure
(ns clojure-ebnf-grammar.parse (:require [instaparse.core :as insta] [clojure.java.io :as io])) (insta/defparser parse-clojure (io/resource "clojure.ebnf") :auto-whitespace :comma)