_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
cf01046778fbdcaf1e86b545c2cdbff06b748f27f844d8d4614dee407fad6c6a
unnohideyuki/Tiger-in-Haskell
Graph.hs
module Graph where import qualified Data.Map as Map import Data.List newtype Node = Node Int deriving (Eq, Ord, Show) data Graph = Graph { get_nnodes :: Int , get_adjacency :: Map.Map (Int, Int) Bool } deriving (Eq, Show) newGraph :: Graph newGraph = G...
null
https://raw.githubusercontent.com/unnohideyuki/Tiger-in-Haskell/69fc976e64bfe7abfa842d7179e06eae740d36b9/chap10_11/src/Graph.hs
haskell
module Graph where import qualified Data.Map as Map import Data.List newtype Node = Node Int deriving (Eq, Ord, Show) data Graph = Graph { get_nnodes :: Int , get_adjacency :: Map.Map (Int, Int) Bool } deriving (Eq, Show) newGraph :: Graph newGraph = G...
73682ed83c5648893edfa61bafb24669cf665b88c28c7e3ff92fd7d21a6f2454
Netflix/PigPen
parquet.clj
;; ;; Copyright 2014 - 2015 Netflix , Inc. ;; 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 ...
null
https://raw.githubusercontent.com/Netflix/PigPen/18d461d9b2ee6c1bb7eee7324889d32757fc7513/pigpen-parquet/src/main/clojure/pigpen/parquet.clj
clojure
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 speci...
Copyright 2014 - 2015 Netflix , Inc. distributed under the License is distributed on an " AS IS " BASIS , (ns pigpen.parquet "Functions for reading and writing parquet data and for creating parquet schemas. Start with `load-parquet` and `store-parquet`. See: / Note: These are currently only supported ...
6e5d65b02a0cdea425cf4f6c3ca4860d2a3ab42fd223a91e5941ddb52a226587
clojure-interop/java-jdk
MultiScrollPaneUI.clj
(ns javax.swing.plaf.multi.MultiScrollPaneUI "A multiplexing UI used to combine ScrollPaneUIs. This file was automatically generated by AutoMulti." (:refer-clojure :only [require comment defn ->]) (:import [javax.swing.plaf.multi MultiScrollPaneUI])) (defn ->multi-scroll-pane-ui "Constructor." (^MultiScro...
null
https://raw.githubusercontent.com/clojure-interop/java-jdk/8d7a223e0f9a0965eb0332fad595cf7649d9d96e/javax.swing/src/javax/swing/plaf/multi/MultiScrollPaneUI.clj
clojure
(ns javax.swing.plaf.multi.MultiScrollPaneUI "A multiplexing UI used to combine ScrollPaneUIs. This file was automatically generated by AutoMulti." (:refer-clojure :only [require comment defn ->]) (:import [javax.swing.plaf.multi MultiScrollPaneUI])) (defn ->multi-scroll-pane-ui "Constructor." (^MultiScro...
fbdb8ae2776c8db7d71d237ac2ba1aca7f086e4cf43a7c558238e89ae5642198
emil0r/reverie
middleware.clj
(ns reverie.helpers.middleware) (defn create-handler [handlers routes] (reduce (fn [current new] (if (nil? new) current (let [[new & args] new] (apply new current args)))) routes handlers)) (defn wrap-response-with-handlers-helper [] (fn...
null
https://raw.githubusercontent.com/emil0r/reverie/a29c223b7326e6d5a5e0874d33c37ff2fa0dfd4d/reverie-core/src/reverie/helpers/middleware.clj
clojure
(ns reverie.helpers.middleware) (defn create-handler [handlers routes] (reduce (fn [current new] (if (nil? new) current (let [[new & args] new] (apply new current args)))) routes handlers)) (defn wrap-response-with-handlers-helper [] (fn...
0cbb1675f8b35c9cd569abdefeac1ec3a39a77e46ad706465986e2148e873a80
zotonic/zotonic
zotonic_cmd_createdb.erl
%%%------------------------------------------------------------------- %%% @author Blaise 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 l...
null
https://raw.githubusercontent.com/zotonic/zotonic/852f627c28adf6e5212e8ad5383d4af3a2f25e3f/apps/zotonic_launcher/src/command/zotonic_cmd_createdb.erl
erlang
------------------------------------------------------------------- @author Blaise 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, eith...
Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , Created : 13 . Dec 2017 7:44 PM -module(zotonic_cmd_createdb). -author("Blaise"). -export([info/0, run/1]). info() -> "Create the PostgreSQL database and schema for a site...
85d1784687487f77b25af44082b9a9d9500c4ea90f3ab284baf3a3e42f1126d3
lifecheq/re-auth0
config.cljs
(ns re-auth0-example.config) (def debug? ^boolean goog.DEBUG)
null
https://raw.githubusercontent.com/lifecheq/re-auth0/1293bdbbcb8eef948c3bb4177b51604f4791bc19/example/src/re_auth0_example/config.cljs
clojure
(ns re-auth0-example.config) (def debug? ^boolean goog.DEBUG)
2cab8d00331e694770133bd69e4df9ac085005f179552c0406e848c1c76c1c7c
david-christiansen/todo-list
syntax-info.rkt
#lang racket/base (require syntax/srcloc) (provide (struct-out loc-info) source-location-loc partial-source-location-loc) (struct loc-info (source position span) #:prefab) (define (source-location-loc stx) (loc-info (source-location-source stx) (source-location-position stx) ...
null
https://raw.githubusercontent.com/david-christiansen/todo-list/589e9c8f58f4684eae64d3254bdbad0b1bcaae39/private/syntax-info.rkt
racket
#lang racket/base (require syntax/srcloc) (provide (struct-out loc-info) source-location-loc partial-source-location-loc) (struct loc-info (source position span) #:prefab) (define (source-location-loc stx) (loc-info (source-location-source stx) (source-location-position stx) ...
b2e24e0c4178711dc7bea716095bcbbd49fb4b628495b1c9f02c4460d39e75ce
galdor/tungsten
text-reporter.lisp
(in-package :test) (defclass text-reporter (reporter) ((stream :type stream :initarg :stream :accessor text-reporter-stream))) (defun make-text-reporter (&key (stream *standard-output*)) (make-instance 'text-reporter :stream stream)) (defmethod report-tests-start ((reporter text-reporter) tests) (w...
null
https://raw.githubusercontent.com/galdor/tungsten/5d6e71fb89af32ab3994c5b2daf8b902a5447447/tungsten-test/src/text-reporter.lisp
lisp
(in-package :test) (defclass text-reporter (reporter) ((stream :type stream :initarg :stream :accessor text-reporter-stream))) (defun make-text-reporter (&key (stream *standard-output*)) (make-instance 'text-reporter :stream stream)) (defmethod report-tests-start ((reporter text-reporter) tests) (w...
9ca649eddf86f19736fbd8b753be75a4d25ac5b91ebc5f80e49ab00c44788b6c
blindglobe/common-lisp-stat
lstypes.lisp
;;; -*- mode: lisp -*- Copyright ( c ) 2005 - -2008 , by < > ;;; See COPYRIGHT file for any additional restrictions (BSD license). Since 1991 , ANSI was finally finished . Edited for ANSI Common Lisp . (in-package :lisp-stat-types) ;;; Type Checking Functions ;;; (Moved out of lsbasics.lsp, placed there by ...
null
https://raw.githubusercontent.com/blindglobe/common-lisp-stat/0c657e10a4ee7e8d4ef3737f8c2d4e62abace2d8/src/basics/lstypes.lisp
lisp
-*- mode: lisp -*- See COPYRIGHT file for any additional restrictions (BSD license). Type Checking Functions (Moved out of lsbasics.lsp, placed there by initial design). NIL otherwise." seq rather than list, allows for vector?
Copyright ( c ) 2005 - -2008 , by < > Since 1991 , ANSI was finally finished . Edited for ANSI Common Lisp . (in-package :lisp-stat-types) (defun fixnump (x) "Args: (x) (declare (inline typep)) (typep x 'fixnum)) (defun check-nonneg-fixnum (x) "Ensure that x or all elts of x are non-negative fixn...
172ed2c8a495b9511aa1571c0f961101fd25ac807fc8edc43ab9999dc8e5a3a1
lambduli/minilog
Main.hs
module Main where import Data.List ( foldl', intercalate ) import Data.List.Extra ( trim ) import Data.Map.Strict qualified as Map import Data.Set qualified as Set import System.IO ( hFlush, stdout, openFile, IOMode(ReadMode), hGetContents ) import Term ( Term(..), Struct(..), Predicate(..), Goal(..) ) import Eva...
null
https://raw.githubusercontent.com/lambduli/minilog/a1b9d7fabba0b38db4707295fe6ca3efa6785c57/app/Main.hs
haskell
putStrLn "I have no idea what that's supposed to mean. I am gonna backtrack anyway." TODO: wait for the interaction to know whether to attempt backtracking. another function would do that for me. that would allow me to sort of re-charge the state Maybe it is not misleading. Maybe keeping the step's pattern ...
module Main where import Data.List ( foldl', intercalate ) import Data.List.Extra ( trim ) import Data.Map.Strict qualified as Map import Data.Set qualified as Set import System.IO ( hFlush, stdout, openFile, IOMode(ReadMode), hGetContents ) import Term ( Term(..), Struct(..), Predicate(..), Goal(..) ) import Eva...
6d2641efa9e0b8f43f78d7344483b6757967de92d9774d7566af75d80b32fb2a
wesen/ruinwesen
blog.lisp
(in-package :ruinwesen) (enable-interpol-syntax) (define-persistent-class rw-blog-article (blog-article) ((short :update :initform nil))) (defmethod rss-item-description ((article rw-blog-article)) (format nil "~A~%~A" (rw-blog-article-short article) (if (article-text article) (article-text article) ...
null
https://raw.githubusercontent.com/wesen/ruinwesen/9f3ccea85425cf46b57e76144b3114ca342bad0f/ruinwesen/src/blog.lisp
lisp
(in-package :ruinwesen) (enable-interpol-syntax) (define-persistent-class rw-blog-article (blog-article) ((short :update :initform nil))) (defmethod rss-item-description ((article rw-blog-article)) (format nil "~A~%~A" (rw-blog-article-short article) (if (article-text article) (article-text article) ...
cd25845b549da1670945a73a15aa703b0dd24d23e41b5490ef5f466ab8f66c8f
coco-team/lustrec
sf_sem.ml
type backend = GenLus | GenImp (* Model choice *) let model_name = ref "simple" let models = [(module Model_simple : Datatype.MODEL_T); (module Model_stopwatch : Datatype.MODEL_T); (* (module Model_medium : Datatype.MODEL_T)*) ] let get_model_name m = let module M = (val m : Datatype.MODEL_T) ...
null
https://raw.githubusercontent.com/coco-team/lustrec/b21f9820df97e661633cd4418fdab68a6c6ca67d/src/tools/stateflow/sf_sem.ml
ocaml
Model choice (module Model_medium : Datatype.MODEL_T) Backend selection Main "-eval", Arg.Int set_trace_run_mode, "execute the model on trace <int>"; "-eval-mode", Arg.String set_eval_mode, "select evaluator: cps"; Could be changed Could be changed Local Variables: compile-command: "make -C ../.. lus...
type backend = GenLus | GenImp let model_name = ref "simple" let models = [(module Model_simple : Datatype.MODEL_T); (module Model_stopwatch : Datatype.MODEL_T); ] let get_model_name m = let module M = (val m : Datatype.MODEL_T) in M.name let set_model name = if List.exists (fun n -> get_model_nam...
c0c74c978cedddf49b3029f732d3bec1fa19b32788a2584adcacebf7690b00cd
ocsigen/tyxml
xml_print.mli
TyXML * * Copyright ( C ) 2008 , * Copyright ( C ) 2011 , * * 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 ...
null
https://raw.githubusercontent.com/ocsigen/tyxml/8551b673857fdc1defebe7c502ffcb920f04009e/lib/xml_print.mli
ocaml
* Printing utilities. This module contains various encoding functions that can be used with {!Tyxml.Html.pp} and {!Tyxml.Svg.pp}. It also contains functors to create printers for your own XML data structure. * {2 Encoding functions} * Same as [normalize] plus some extra work : It encode '<' , '>'...
TyXML * * Copyright ( C ) 2008 , * Copyright ( C ) 2011 , * * 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 ...
1eecf5a3ac75386f8503c80a28eecd0f8f32621197f1f4a212ab6e217e1f770b
brendanhay/amazonka
DeleteDomain.hs
# LANGUAGE DeriveGeneric # # LANGUAGE DuplicateRecordFields # # LANGUAGE NamedFieldPuns # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE RecordWildCards # {-# LANGUAGE StrictData #-} # LANGUAGE TypeFamilies # # LANGUAGE NoImplicitPrelude # # OPTIONS_GHC -fno - warn - unused - binds # # OPTIONS_GHC -fno - warn - unused -...
null
https://raw.githubusercontent.com/brendanhay/amazonka/09f52b75d2cfdff221b439280d3279d22690d6a6/lib/services/amazonka-voice-id/gen/Amazonka/VoiceId/DeleteDomain.hs
haskell
# LANGUAGE OverloadedStrings # # LANGUAGE StrictData # | Stability : auto-generated * Creating a Request * Request Lenses * Destructuring the Response | /See:/ 'newDeleteDomain' smart constructor. | The identifier of the domain you want to delete. | Create a value of 'DeleteDomain' with all optional fields ...
# LANGUAGE DeriveGeneric # # LANGUAGE DuplicateRecordFields # # LANGUAGE NamedFieldPuns # # LANGUAGE RecordWildCards # # LANGUAGE TypeFamilies # # LANGUAGE NoImplicitPrelude # # OPTIONS_GHC -fno - warn - unused - binds # # OPTIONS_GHC -fno - warn - unused - imports # # OPTIONS_GHC -fno - warn - unused - matches # De...
31a2d10c54f3983104c8bf4661b87aa9e1d6c729aa8d04edbcdb7cb68cc2c0bc
verystable/warframe-autobuilder
PhysicalDamageMods.hs
# LANGUAGE NoImplicitPrelude # {-# LANGUAGE OverloadedStrings #-} -- | Module : Builder . Mods . ShotgunMods . PhysicalDamageMods -- Maintainer : -- Stability : experimental -- -- Contains function that modify physical damage, applicable on primary (shotguns) weapons. module Builder.Mods.ShotgunMods.Physi...
null
https://raw.githubusercontent.com/verystable/warframe-autobuilder/015e0bb6812711ea27071816d054cbaa1c65770b/src/Builder/Mods/ShotgunMods/PhysicalDamageMods.hs
haskell
# LANGUAGE OverloadedStrings # | Maintainer : Stability : experimental Contains function that modify physical damage, applicable on primary (shotguns) weapons. | Accelerated Blast [+60% Fire Rate, +60% Puncture Damage] | Breach Loader [+120% Puncture Damage] | Flechette [+30% Puncture Damage] | Sweeping Se...
# LANGUAGE NoImplicitPrelude # Module : Builder . Mods . ShotgunMods . PhysicalDamageMods module Builder.Mods.ShotgunMods.PhysicalDamageMods where import ClassyPrelude import Control.Lens ( (^.) ) import GenericFunctions.GenericFunctions import Types....
480e53ef91dddb2f258d52b7cd797ecc635e60b339f7aba5b8dc609bc0d77ee7
nanit/kubernetes-custom-hpa
reconciler.clj
(ns custom-hpa.control-loop.reconciler (:require [clj-time.core :as time] [custom-hpa.helpers.env :refer [int-env double-env]] [custom-hpa.control-loop.common :refer [scale-up scale-down scale-type]] [custom-hpa.control-loop.status :as status] [taoensso.timbre :as ...
null
https://raw.githubusercontent.com/nanit/kubernetes-custom-hpa/e6f07f271336c3ede1e8cdfcf426f639469c2f33/app/src/custom_hpa/control_loop/reconciler.clj
clojure
(ns custom-hpa.control-loop.reconciler (:require [clj-time.core :as time] [custom-hpa.helpers.env :refer [int-env double-env]] [custom-hpa.control-loop.common :refer [scale-up scale-down scale-type]] [custom-hpa.control-loop.status :as status] [taoensso.timbre :as ...
1ba9264535c8ca05ddfcbc730afb8fe35bd176f07f8ccc6de01883358057f742
synrc/nitro
element_month.erl
-module(element_month). -author('Vladimir Galunshchikov'). -include_lib("nitro/include/nitro.hrl"). -include_lib("nitro/include/event.hrl"). -compile(export_all). render_element(Record) when Record#month.show_if==false -> [<<>>]; render_element(Record) -> Id = case Record#month.postback of [] -> Record#mon...
null
https://raw.githubusercontent.com/synrc/nitro/753b543626add2c014584546ec50870808a2eb90/src/elements/input/element_month.erl
erlang
global spec
-module(element_month). -author('Vladimir Galunshchikov'). -include_lib("nitro/include/nitro.hrl"). -include_lib("nitro/include/event.hrl"). -compile(export_all). render_element(Record) when Record#month.show_if==false -> [<<>>]; render_element(Record) -> Id = case Record#month.postback of [] -> Record#mon...
dbe4b9650c5798be249f41462ffa9d2a0d5bec517a1fde26794e6ad332e379d8
skanev/playground
45.scm
SICP exercise 1.45 ; ; We saw in section 1.3.3 that attempting to compute square roots by naively ; finding a fixed point of x ↦ x/y does not converge, and that this can be ; fixed by average damping. The same method works for finding cube roots as ; fixed points of the average-damped y ↦ x/y². Unfortunatelly, the pr...
null
https://raw.githubusercontent.com/skanev/playground/d88e53a7f277b35041c2f709771a0b96f993b310/scheme/sicp/01/45.scm
scheme
We saw in section 1.3.3 that attempting to compute square roots by naively finding a fixed point of x ↦ x/y does not converge, and that this can be fixed by average damping. The same method works for finding cube roots as fixed points of the average-damped y ↦ x/y². Unfortunatelly, the process does fixed-point se...
SICP exercise 1.45 not work for fourth roots — a single average damp is not enough to make a repeated procedure of exercise 1.43 . Assume that any arithmetic operations (define (nth-root n x) (fixed-point-of-transform (lambda (y) (/ x (expt y (- n 1)))) (repeated average-damp (ceil...
f8beb6a5dfd6b0aabb9c8cebc43969dd7997e2f66a64d7cd65a8638ba6b33aea
ubf/ubf
contract_driver.erl
%%% The MIT License %%% Copyright ( C ) 2011 - 2016 by < > Copyright ( C ) 2002 by %%% %%% Permission is hereby granted, free of charge, to any person obtaining a copy %%% of this software and associated documentation files (the "Software"), to deal in the Software without restriction , including without li...
null
https://raw.githubusercontent.com/ubf/ubf/c876f684fbd4959548ace1eb1cfc91941f93d377/src/contract_driver.erl
erlang
The MIT License Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal to use, copy, modify, merge, publish, distribute, sublicense, and/or sell furnished to do so, subject to the following conditions: The above...
Copyright ( C ) 2011 - 2016 by < > Copyright ( C ) 2002 by in the Software without restriction , including without limitation the rights copies of the Software , and to permit persons to whom the Software is all copies or substantial portions of the Software . THE SOFTWARE IS PROVIDED " AS IS " , WITH...
6fce66ec314d56e4f499536b3a6c6de050457587fed00e7d44f10b14cc4077ec
TyOverby/mono
regions.ml
Copyright ( c ) 2019 . All rights reserved . See LICENSE.md . See LICENSE.md. *) (* Demonstrates how to change attributes of parts of an image. *) open Notty open Notty.Infix open Common let htake x w i = let w0 = I.width i in I.hcrop x (w0 - x - w) i let vtake y h i = let h0 = I.height i in I.vcrop y (...
null
https://raw.githubusercontent.com/TyOverby/mono/94225736a93457d5c9aeed399c4ae1a08b239fd5/vendor/pqwy-notty/examples/regions.ml
ocaml
Demonstrates how to change attributes of parts of an image.
Copyright ( c ) 2019 . All rights reserved . See LICENSE.md . See LICENSE.md. *) open Notty open Notty.Infix open Common let htake x w i = let w0 = I.width i in I.hcrop x (w0 - x - w) i let vtake y h i = let h0 = I.height i in I.vcrop y (h0 - y - h) i let hedit x w f i = htake 0 x i <|> f (htake x w ...
abab88778507e8c81b7a9d841248d5f761b859465d14dd120ba38f76f5132d55
ott-lang/ott
grammar_typecheck.mli
(**************************************************************************) (* Ott *) (* *) , Computer Laboratory , University of Cambridge , project , I...
null
https://raw.githubusercontent.com/ott-lang/ott/29ac9ef84967686da35b9b42608b3aec3539a689/src/grammar_typecheck.mli
ocaml
************************************************************************ Ott ...
, Computer Laboratory , University of Cambridge , project , INRIA Rocquencourt Copyright 2005 - 2010 1 . Redistributions of source code must retain the above copyright 2 . Redistributions in binary form must reproduce the ...
5afaa9c78f1889462effb7e1ac241eb680ee625e40978e2dd2797678a178a293
schnef/hkdf
hkdf.erl
-module(hkdf). -export([derive_secrets/2, derive_secrets/3, derive_secrets/4, derive_secrets/5, extract/2, extract/3, expand/3, expand/4, max_length/1]). -ifdef(TEST). -include_lib("eunit/include/eunit.hrl"). -endif. -type hash_algorithm() :: md5 | sha | sha224 | sha256 | sha384 | sha512. -type salt() :: iodata()....
null
https://raw.githubusercontent.com/schnef/hkdf/be49665dcc482660eae48047faa207c1e946371e/src/hkdf.erl
erlang
desired output length L in bytes, using the sha256 hmac function as a default. @doc expand/3 "expands" the key PRK from the extract stage into L additional pseudorandom keys. Number of iterations to go
-module(hkdf). -export([derive_secrets/2, derive_secrets/3, derive_secrets/4, derive_secrets/5, extract/2, extract/3, expand/3, expand/4, max_length/1]). -ifdef(TEST). -include_lib("eunit/include/eunit.hrl"). -endif. -type hash_algorithm() :: md5 | sha | sha224 | sha256 | sha384 | sha512. -type salt() :: iodata()....
cf2269ada8cba4ed62cc7c65bd1beb9f047cbdfcb5210f0d6b5d42fd23afb71d
FlowForwarding/LINC-Switch
linc_oe.erl
-module(linc_oe). -export([initialize/1, terminate/0, get_optical_peer_pid/2, add_mapping_ofp_to_optical_port/3, is_port_optical/2]). -define(OPTICAL_LINKS_ETS, optical_ports). -define(OFP_TO_OPTICAL_PORT_ETS, ofp_ports_to_optical_ports). %%%------------------------------------------------------------------...
null
https://raw.githubusercontent.com/FlowForwarding/LINC-Switch/9c28e7c8677c03440a62023292dd700fef0c3420/apps/linc/src/linc_oe.erl
erlang
-------------------------------------------------------------------- API functions -------------------------------------------------------------------- -------------------------------------------------------------------- --------------------------------------------------------------------
-module(linc_oe). -export([initialize/1, terminate/0, get_optical_peer_pid/2, add_mapping_ofp_to_optical_port/3, is_port_optical/2]). -define(OPTICAL_LINKS_ETS, optical_ports). -define(OFP_TO_OPTICAL_PORT_ETS, ofp_ports_to_optical_ports). initialize(Links) -> init_optical_links_ets(Links), init_ofp...
6881b1e4418e822f86e88e0e7a4a04ee31795fcdc1e62d313eaac4a5d69ffb28
Eonblast/Trinity
genserver_SUITE.erl
%%%------------------------------------------------------------------- %%% File : eonbeam/dev/3/f_genservertest/test/genserver_SUITE.erl Descr : complete skeleton of a Common Test test suite Author : Source : Erlang docs ' small suite sample ' www.erlang.org/doc/apps/common_test/examp...
null
https://raw.githubusercontent.com/Eonblast/Trinity/15bcc0fa0997d7dd360f1542493e63208645bd88/f_genservertest/test/genserver_SUITE.erl
erlang
------------------------------------------------------------------- File : eonbeam/dev/3/f_genservertest/test/genserver_SUITE.erl Adapted : 06/19/2011 hd ------------------------------------------------------------------- Run: eonbeam/dev/3/f_genservertest/2_common_test.sh ------------------------------------...
Descr : complete skeleton of a Common Test test suite Author : Source : Erlang docs ' small suite sample ' www.erlang.org/doc/apps/common_test/example_chapter.html Or : ct_run -pa . -dir test ( from eonbeam / dev/3 / f_genservertest ) -module(genserver_SUITE). -compile(export_all). -in...
7b160ab3b218fa6264cedf98906efe283abefccbe90cb14482ecb2b4fe13a069
thicksteadTHpp/Obvius
glfw-nk-screen-8-bit.lisp
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; File: gl-obv-8-bit.lisp Author : , [ THO ] Description : 8 - bit screen specific stuff Creation Date : 1993 , 2019 ;;; ---------------------------------------------------------------- Object - Based Vision and Image ...
null
https://raw.githubusercontent.com/thicksteadTHpp/Obvius/9a91673609def033539c9ebaf098e8f11eb0df6e/obvius_eye/glfw-nk-screen-8-bit.lisp
lisp
File: gl-obv-8-bit.lisp ---------------------------------------------------------------- allowed (e.g. for gray it would be 0-255, for color it would be 0-255 for R/G/B separately). depth of the screen gray-depth of the screen number of gray levels gamma ramp number of bits of red/green/blue to be dit...
Author : , [ THO ] Description : 8 - bit screen specific stuff Creation Date : 1993 , 2019 Object - Based Vision and Image Understanding System ( OBVIUS ) , Copyright 1988 , Vision Science Group , Media Laboratory , Massachusetts Institute of Technology . (in-package :obvius)...
a4ee270ea0675f38777c4847005b9ff4077ddb7690f2ef24bc8f210732b2cfe2
haskoin/haskoin-store
WebCommonSpec.hs
# LANGUAGE ExistentialQuantification # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE RecordWildCards # # OPTIONS_GHC -fno - warn - orphans # module Haskoin.Store.WebCommonSpec ( spec, ) where import Control.Monad (forM_) import Data.Proxy import Data.St...
null
https://raw.githubusercontent.com/haskoin/haskoin-store/381ab5088c3addf4445ce5ff1428d736ec858bca/data/test/Haskoin/Store/WebCommonSpec.hs
haskell
# LANGUAGE OverloadedStrings #
# LANGUAGE ExistentialQuantification # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # # LANGUAGE RecordWildCards # # OPTIONS_GHC -fno - warn - orphans # module Haskoin.Store.WebCommonSpec ( spec, ) where import Control.Monad (forM_) import Data.Proxy import Data.String.Conversions (cs) import Data.W...
88f8699c3609556822419df9c3216b4d0f7cfe66385710807f5f946793e33dbc
clojure-interop/google-cloud-clients
StorageOptions$DefaultStorageFactory.clj
(ns com.google.cloud.storage.StorageOptions$DefaultStorageFactory (:refer-clojure :only [require comment defn ->]) (:import [com.google.cloud.storage StorageOptions$DefaultStorageFactory])) (defn ->default-storage-factory "Constructor." (^StorageOptions$DefaultStorageFactory [] (new StorageOptions$DefaultS...
null
https://raw.githubusercontent.com/clojure-interop/google-cloud-clients/80852d0496057c22f9cdc86d6f9ffc0fa3cd7904/com.google.cloud.storage/src/com/google/cloud/storage/StorageOptions%24DefaultStorageFactory.clj
clojure
(ns com.google.cloud.storage.StorageOptions$DefaultStorageFactory (:refer-clojure :only [require comment defn ->]) (:import [com.google.cloud.storage StorageOptions$DefaultStorageFactory])) (defn ->default-storage-factory "Constructor." (^StorageOptions$DefaultStorageFactory [] (new StorageOptions$DefaultS...
f5e949c04d1aa47f0343fe5bf654e97fca4f038e916803a998687bcfb171056d
sebashack/servantRestfulAPI
User.hs
{-# LANGUAGE EmptyDataDecls #-} # LANGUAGE FlexibleContexts # {-# LANGUAGE GADTs #-} # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE QuasiQuotes #-} {-# LANGUAGE TemplateH...
null
https://raw.githubusercontent.com/sebashack/servantRestfulAPI/e625535d196acefaff4f5bf03108816be668fe4d/libs/Schemas/SQL/User.hs
haskell
# LANGUAGE EmptyDataDecls # # LANGUAGE GADTs # # LANGUAGE OverloadedStrings # # LANGUAGE QuasiQuotes # # LANGUAGE TemplateHaskell # An state which tells us if this is Blocked Admin. Hashed password. Hashed recovery code. mediumblob
# LANGUAGE FlexibleContexts # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE MultiParamTypeClasses # # LANGUAGE TypeFamilies # module Schemas.SQL.User where import Configs.MySQL import HelperLibs.MySQL.ActionRunner import Schemas.SQL.DbTypes import Data.ByteString (ByteString) im...
f9fb060c25aa94fec43890a375335246a3e6b1590a9d706a92968a94311d05e3
keera-studios/haskell-titan
Main.hs
-- | This is the main program with which the graphical app is launched. -- Copyright : ( C ) Keera Studios Ltd , 2018 -- License : GPL-3 Maintainer : module Main where -- Internal imports import Controller -- |The app starts here. Here we simply call the controller, which -- takes control from now on. m...
null
https://raw.githubusercontent.com/keera-studios/haskell-titan/958ddd2b468af00db46004a683c1c7aebe81526c/titan/src/Main.hs
haskell
| This is the main program with which the graphical app is launched. License : GPL-3 Internal imports |The app starts here. Here we simply call the controller, which takes control from now on.
Copyright : ( C ) Keera Studios Ltd , 2018 Maintainer : module Main where import Controller main :: IO () main = startController
ee7eeb15465f46ef2536f07190ed54a1a3f52d2656ec59a4e8d380bc02c17a5a
w3ntao/sicp-solution
2-33.rkt
#lang racket (define nil '()) (define (accumulate op initial sequence) (if (null? sequence) initial (op (car sequence) (accumulate op initial (cdr sequence))))) (define (new-map p sequence) (accumulate (lambda (x y) (cons (p x ) y)) nil sequence)) (define (new-a...
null
https://raw.githubusercontent.com/w3ntao/sicp-solution/00be3a7b4da50bb266f8a2db521a24e9f8c156be/chap-2/2-33.rkt
racket
(test-it (car (car (list 0))))
#lang racket (define nil '()) (define (accumulate op initial sequence) (if (null? sequence) initial (op (car sequence) (accumulate op initial (cdr sequence))))) (define (new-map p sequence) (accumulate (lambda (x y) (cons (p x ) y)) nil sequence)) (define (new-a...
60cb72c09104ade51bba11eaea8fc1feac78908ae6519a1488304dc999f26470
pveber/biotk
list1.ml
open Core type 'a t = Cons of 'a * 'a list let init n ~f = if n < 1 then invalid_arg "Non_empty_list should be at least of length 1" ; Cons (f 0, List.init (n - 1) ~f:(fun i -> f (i + 1))) let cons h t = Cons (h, t) let fold (Cons (h, t)) ~init ~f = List.fold t ~f ~init:(f init h) let map (Cons (h, t)) ~f = ...
null
https://raw.githubusercontent.com/pveber/biotk/0906a650a324f020c9caa3377233ac3a1f217921/lib/list1.ml
ocaml
open Core type 'a t = Cons of 'a * 'a list let init n ~f = if n < 1 then invalid_arg "Non_empty_list should be at least of length 1" ; Cons (f 0, List.init (n - 1) ~f:(fun i -> f (i + 1))) let cons h t = Cons (h, t) let fold (Cons (h, t)) ~init ~f = List.fold t ~f ~init:(f init h) let map (Cons (h, t)) ~f = ...
ca7c48421a6863487855209af78c6f9e20441726ae9b1f773ea197d568969cdd
opencog/opencog
pln-actions.scm
;; PLN actions (use-modules (srfi srfi-1)) (use-modules (opencog)) (use-modules (opencog ghost)) (use-modules (opencog nlp)) (use-modules (opencog nlp chatbot-psi)) (use-modules (opencog nlp sureal)) (use-modules (opencog logger)) (use-modules (opencog pln)) ;; return atom.tv.s^2*atom.tv.c (define (higest-tv-fitness a...
null
https://raw.githubusercontent.com/opencog/opencog/53f2c2c8e26160e3321b399250afb0e3dbc64d4c/opencog/ghost/procedures/pln-actions.scm
scheme
PLN actions return atom.tv.s^2*atom.tv.c (cog-logger-info "higest-tv-fitness(~a) = ~a" atom res) Select the semantic with highest strength*confidence given a list of semantics Turn (Implication P Q) into (Word "people") (Set (Evaluation Q (List (Concept "people"))) (Inherita...
(use-modules (srfi srfi-1)) (use-modules (opencog)) (use-modules (opencog ghost)) (use-modules (opencog nlp)) (use-modules (opencog nlp chatbot-psi)) (use-modules (opencog nlp sureal)) (use-modules (opencog logger)) (use-modules (opencog pln)) (define (higest-tv-fitness atom) (let* ((tv-s (cog-mean atom)) (...
c16d8a9443bd89ecb61737d7b88c8cc5ea6d5b4e989fbfcf07c455718253f591
WormBase/wormbase_rest
regulation.clj
(ns rest-api.classes.expression-cluster.widgets.regulation (:require [rest-api.formatters.object :as obj :refer [pack-obj]] [rest-api.classes.generic-fields :as generic])) (defn regulated-by-molecule [ec] {:data (when-let [molecules (:expression-cluster/regulated-by-molecule ec)] (map pack-obj m...
null
https://raw.githubusercontent.com/WormBase/wormbase_rest/e51026f35b87d96260b62ddb5458a81ee911bf3a/src/rest_api/classes/expression_cluster/widgets/regulation.clj
clojure
(ns rest-api.classes.expression-cluster.widgets.regulation (:require [rest-api.formatters.object :as obj :refer [pack-obj]] [rest-api.classes.generic-fields :as generic])) (defn regulated-by-molecule [ec] {:data (when-let [molecules (:expression-cluster/regulated-by-molecule ec)] (map pack-obj m...
170be6b1a925242ba51c6c93f9eddd9222de1187dffb267a52371022861098f2
BinaryAnalysisPlatform/bap
test_stream.ml
open OUnit2 open Core_kernel[@@warning "-D"] open Bap_future.Std let magic_value = 42 let values = [0;1;2;3;4;5;6;7] let assert_false fail_id v = assert_bool fail_id (not v) let make_iota () = let start = ref 0 in fun () -> let v = !start in start := Int.succ !start; v let is_even x = x mod 2 = 0 ...
null
https://raw.githubusercontent.com/BinaryAnalysisPlatform/bap/253afc171bbfd0fe1b34f6442795dbf4b1798348/lib_test/bap_future/test_stream.ml
ocaml
open OUnit2 open Core_kernel[@@warning "-D"] open Bap_future.Std let magic_value = 42 let values = [0;1;2;3;4;5;6;7] let assert_false fail_id v = assert_bool fail_id (not v) let make_iota () = let start = ref 0 in fun () -> let v = !start in start := Int.succ !start; v let is_even x = x mod 2 = 0 ...
e607523a50efeb4f29b39586f7f13440ebfa39513d848b2feffbe116ce5ab3b7
mediocregopher/chdl
core.clj
(ns chdl.gamma.core "Useful functions" (require [chdl.alpha.literal :as lit] [chdl.alpha.expr :as expr] [chdl.alpha.proto :as proto] [chdl.beta.math :as math] [chdl.beta.comp :as comp] [chdl.gamma.types :as t] [chdl.gamma.function :as cfn])) (defn raw-bit-value? [value chdl-symbol] {...
null
https://raw.githubusercontent.com/mediocregopher/chdl/b48b33e9215a84fbcdfa3f15446efc092c86d079/src/chdl/gamma/core.clj
clojure
(ns chdl.gamma.core "Useful functions" (require [chdl.alpha.literal :as lit] [chdl.alpha.expr :as expr] [chdl.alpha.proto :as proto] [chdl.beta.math :as math] [chdl.beta.comp :as comp] [chdl.gamma.types :as t] [chdl.gamma.function :as cfn])) (defn raw-bit-value? [value chdl-symbol] {...
7e9629492768e77097af6b805921c14f332794469748fbceea9a149de8ab766b
chaoxu/mgccl-haskell
rna.hs
import Rosalind main :: IO () main = do c <- getLine print $ dnaToRna c
null
https://raw.githubusercontent.com/chaoxu/mgccl-haskell/bb03e39ae43f410bd2a673ac2b438929ab8ef7a1/rosalind/rna.hs
haskell
import Rosalind main :: IO () main = do c <- getLine print $ dnaToRna c
6255f5f14e6bfc70d1dba512ce9c087a086dd86cb2db08b3a49222d2418faa11
rybern/mstan
GraphServer.hs
{-# LANGUAGE OverloadedStrings #-} module GraphServer (GraphServerOptions (..) , GraphServerDirectoryOptions (..) , defaultGraphServerOptions , defaultDirOptions , WSServerOptions (..) , runGraphServer) where import System.FilePath import Data.Text ( Tex...
null
https://raw.githubusercontent.com/rybern/mstan/7f171ccff268a86ff3782efba352ed06b653c8de/mstan-server/GraphServer.hs
haskell
# LANGUAGE OverloadedStrings # , ("i_source", quote $ i1) , ("i_target", quote $ i2)
module GraphServer (GraphServerOptions (..) , GraphServerDirectoryOptions (..) , defaultGraphServerOptions , defaultDirOptions , WSServerOptions (..) , runGraphServer) where import System.FilePath import Data.Text ( Text ) import qualified Data.Text ...
530fb124c690e9eb510a7c676a1838f6d7fa906f31ffd69a944990bd974b1805
camlp5/camlp5
warnings.mli
(***********************************************************************) (* *) (* OCaml *) (* *) Pierre Weis...
null
https://raw.githubusercontent.com/camlp5/camlp5/15e03f56f55b2856dafe7dd3ca232799069f5dda/ocaml_stuff/4.00.0/utils/warnings.mli
ocaml
********************************************************************* OCaml ...
Pierre Weis & & Damien Doligez , INRIA Rocquencourt Copyright 1998 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 . open Format type t = 1 ...
824acc8be18237e4f4a07a1902d5636d7889b22a5bac50a1224f6196b579b982
dmjio/stripe
Recipient.hs
# LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE OverloadedStrings # # LANGUAGE TypeFamilies # ------------------------------------------- -- | -- Module : Web.Stripe.Recipient Copyright : ( c ) , 2014 -- Maintainer : -- Stability : experimental -- Portabi...
null
https://raw.githubusercontent.com/dmjio/stripe/967334629933fcb55247eb3270c7801c05d6bf61/stripe-core/src/Web/Stripe/Recipient.hs
haskell
----------------------------------------- | Module : Web.Stripe.Recipient Maintainer : Stability : experimental Portability : POSIX @ main :: IO () main = do result <- stripe config $ Individual case result of Right recipient -> print recipient Left stripeErro...
# LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # # LANGUAGE OverloadedStrings # # LANGUAGE TypeFamilies # Copyright : ( c ) , 2014 < https:/\/\stripe.com / docs / api#recipients > { -\ # LANGUAGE OverloadedStrings \#- } import Web . Stripe import Web . Stripe . Recipi...
9f46dd25a989d006c97c1d0ee3644610bd7e4ebd7c5488b804e88cbf55f775a8
potatosalad/erlang-jose
jose_jwe_enc_aes_props.erl
-*- mode : erlang ; tab - width : 4 ; indent - tabs - mode : 1 ; st - rulers : [ 70 ] -*- %% vim: ts=4 sw=4 ft=erlang noet -module(jose_jwe_enc_aes_props). -include_lib("proper/include/proper.hrl"). % -compile(export_all). base64url_binary() -> ?LET(Binary, binary(), jose_jwa_base64url:encode(Binary)). binar...
null
https://raw.githubusercontent.com/potatosalad/erlang-jose/43d3db467f909bbc932bd663ddcb1af93180dfd3/test/property_test/jose_jwe_enc_aes_props.erl
erlang
vim: ts=4 sw=4 ft=erlang noet -compile(export_all).
-*- mode : erlang ; tab - width : 4 ; indent - tabs - mode : 1 ; st - rulers : [ 70 ] -*- -module(jose_jwe_enc_aes_props). -include_lib("proper/include/proper.hrl"). base64url_binary() -> ?LET(Binary, binary(), jose_jwa_base64url:encode(Binary)). binary_map() -> ?LET(List, list({base64url_binary(), base64...
f0b27014ac91624b01e00e319ef6dcb75b1b7c4c45a8e12cc1458020477a0f9e
coq/coq
richpp.ml
(************************************************************************) (* * The Coq Proof Assistant / The Coq Development Team *) v * Copyright INRIA , CNRS and contributors < O _ _ _ , , * ( see version control and CREDITS file for authors & dates ) \VV/ * * *...
null
https://raw.githubusercontent.com/coq/coq/37e820c1bd5d321cff65285ab7e162b554126d61/ide/coqide/protocol/richpp.ml
ocaml
********************************************************************** * The Coq Proof Assistant / The Coq Development Team // * This file is distributed under the terms of the * (see LICENSE file for the text of the license) ************************************...
v * Copyright INRIA , CNRS and contributors < O _ _ _ , , * ( see version control and CREDITS file for authors & dates ) \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * GNU Lesser Gener...
6162ba7c1545ecd806d63ff6d82b83cf9181acb889b5ecde043be6034beeee44
marianoguerra/efe
cornercases.erl
-module(cornercases). -export([varnames/12, atoms/0, chars/0, calls/3, calls/0, long_calc/0, binops/0, instant_call/0, lc_no_gen/0, module_macro/0, uppercase_funs/2, fun_no_args_when/1, 'substring-after'/0, call_call/0, escape_str_interpolation/0, printable_chars/0, wrap_stmt/1, loc...
null
https://raw.githubusercontent.com/marianoguerra/efe/a8e748c98a5a32ef2338416232463b2e34a2d061/samples/cornercases.erl
erlang
on_load is private duplicated import elixir for needs a generator, add a dummy `_ <- [nil]` generator xerl_xpath_pred
-module(cornercases). -export([varnames/12, atoms/0, chars/0, calls/3, calls/0, long_calc/0, binops/0, instant_call/0, lc_no_gen/0, module_macro/0, uppercase_funs/2, fun_no_args_when/1, 'substring-after'/0, call_call/0, escape_str_interpolation/0, printable_chars/0, wrap_stmt/1, loc...
b96bd50290e3c8b86139a035889c0fd5cf8dd5d876c2d45b038c79f121c9c6ff
janestreet/base
t.ml
(** This module defines various abstract interfaces that are convenient when one needs a module that matches a bare signature with just a type. This sometimes occurs in functor arguments and in interfaces. *) open! Import module type T = sig type t end module type T1 = sig type 'a t end module type T2 =...
null
https://raw.githubusercontent.com/janestreet/base/221b085f3fcd77597f8245b4d73de3970b238e71/src/t.ml
ocaml
* This module defines various abstract interfaces that are convenient when one needs a module that matches a bare signature with just a type. This sometimes occurs in functor arguments and in interfaces.
open! Import module type T = sig type t end module type T1 = sig type 'a t end module type T2 = sig type ('a, 'b) t end module type T3 = sig type ('a, 'b, 'c) t end
e8c615746371989201e602b625e63c0ac55304d5d7fa15467f0673c2f1e99651
MyDataFlow/ttalk-server
lager_app.erl
Copyright ( c ) 2011 - 2012 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...
null
https://raw.githubusercontent.com/MyDataFlow/ttalk-server/07a60d5d74cd86aedd1f19c922d9d3abf2ebf28d/deps/lager/src/lager_app.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 Lager's application modul...
Copyright ( c ) 2011 - 2012 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 ...
ae86f611534b99003fc56ab9d1304d235bedf66e19e74dac1047b29c85219f23
ArulselvanMadhavan/mini_dalle
lwthttp.mli
val http_get_and_follow : Uri.t -> string -> (Cohttp.Response.t * Cohttp_lwt.Body.t) Lwt.t
null
https://raw.githubusercontent.com/ArulselvanMadhavan/mini_dalle/a805022b9c6744d7aebcb1fa957cff8d6044013f/lib/lwthttp.mli
ocaml
val http_get_and_follow : Uri.t -> string -> (Cohttp.Response.t * Cohttp_lwt.Body.t) Lwt.t
d76731aff1285f7cb81c7ffa8dc78403884305c148346aae1be0b63c9d8d39fa
runtimeverification/haskell-backend
Variable.hs
| Module : . Simplify . Variable Description : Tools for Variable pattern simplification . Copyright : ( c ) Runtime Verification , 2018 - 2021 License : BSD-3 - Clause Maintainer : Stability : experimental Portability : portable Module : Kore.Simplify.Variable Description : ...
null
https://raw.githubusercontent.com/runtimeverification/haskell-backend/b06757e252ee01fdd5ab8f07de2910711997d845/kore/src/Kore/Simplify/Variable.hs
haskell
| 'simplify' simplifies a 'Variable' pattern, which means returning an or containing a term made of that variable.
| Module : . Simplify . Variable Description : Tools for Variable pattern simplification . Copyright : ( c ) Runtime Verification , 2018 - 2021 License : BSD-3 - Clause Maintainer : Stability : experimental Portability : portable Module : Kore.Simplify.Variable Description : ...
b4e326b11d6a77f415232aef993e73bb16257db8621a1f3a9c8b22aae0ce09ac
input-output-hk/ouroboros-network
CRC.hs
# LANGUAGE BangPatterns # {-# LANGUAGE DeriveGeneric #-} # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE ScopedTypeVariables # | Support for CRC module Ouroboros.Consensus.Storage.FS.CRC ( -- * Wrap digest functionality CRC (..) , computeCRC , initCRC , updateCRC ...
null
https://raw.githubusercontent.com/input-output-hk/ouroboros-network/c82309f403e99d916a76bb4d96d6812fb0a9db81/ouroboros-consensus/src/Ouroboros/Consensus/Storage/FS/CRC.hs
haskell
# LANGUAGE DeriveGeneric # * Wrap digest functionality ------------------------------------------------------------------------------ Wrap functionality from digest ------------------------------------------------------------------------------ ------------------------------------------------------------...
# LANGUAGE BangPatterns # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE ScopedTypeVariables # | Support for CRC module Ouroboros.Consensus.Storage.FS.CRC ( CRC (..) , computeCRC , initCRC , updateCRC * File system functions with CRC functionality , hGetAllAtCRC , hGetExact...
a3c0de108e2613d7457332c87884d66479410b4670835429aec5e8239abf7d4a
charlieg/Sparser
v+v-objects1.lisp
;;; -*- Mode:LISP; Syntax:Common-Lisp; Package:(SPARSER LISP) -*- copyright ( c ) 1998 - 2005 -- all rights reserved extensions copyright ( c ) 2007 - 2008 BBNT Solutions LLC . All Rights Reserved $ Id:$ ;;; ;;; File: "v+v objects" ;;; Module: "objects;model:lattice-points:" version : 1.1 July 2...
null
https://raw.githubusercontent.com/charlieg/Sparser/b9bb7d01d2e40f783f3214fc104062db3d15e608/Sparser/code/s/objects/model/lattice-points/v%2Bv-objects1.lisp
lisp
-*- Mode:LISP; Syntax:Common-Lisp; Package:(SPARSER LISP) -*- File: "v+v objects" Module: "objects;model:lattice-points:" variable. into the structure file. --------- printer --------- ----------------- pseudo resource ----------------- stub for a resource ------ find ------ ------ make ------ ...
copyright ( c ) 1998 - 2005 -- all rights reserved extensions copyright ( c ) 2007 - 2008 BBNT Solutions LLC . All Rights Reserved $ Id:$ version : 1.1 July 2007 initiated 3/7/98 . Populated 7/9 . 1/31/99 aded Value / var / v+v . Added Bind - v+v 2/14 . Added a global trap into value / var / v+v...
b92b0fc3d0626aeda0e7b3d350b802d03b59d75390a3c83aa1296a0adbb8917e
re-ops/re-cog
project.clj
(defproject re-cog "0.6.6" :description "Re-cog is a set of serializable functions including provisioning resources, system facts and commonly used remotely executable functions" :url "-ops/re-cog" :license {:name "Apache License, Version 2.0" :url "-2.0.html"} :dependencies [ [org.clojure/clojure "1.10.1"...
null
https://raw.githubusercontent.com/re-ops/re-cog/04dbbab79777e2ee6ac6e7b6b7dcfd39886295e8/project.clj
clojure
serialization fs utilities checksumming templating logging common utilities and shared functions clojure to bash repl planning CLI in memory datalog configuration yaml resources
(defproject re-cog "0.6.6" :description "Re-cog is a set of serializable functions including provisioning resources, system facts and commonly used remotely executable functions" :url "-ops/re-cog" :license {:name "Apache License, Version 2.0" :url "-2.0.html"} :dependencies [ [org.clojure/clojure "1.10.1"...
020b331742bbb4b4135d055c7a5b77f065368d869537aa8b759a63502bbe5e24
goblint/analyzer
privPrecCompareUtil.ml
open GoblintCil open PrecCompareUtil module LV = struct include Printable.Prod (CilType.Location) (Basetype.Variables) let name () = "location variables" type marshal = t let pretty () (l, v) = Pretty.dprintf "%a %a" CilType.Location.pretty l Basetype.Variables.pretty v let to_location = fst end module Util...
null
https://raw.githubusercontent.com/goblint/analyzer/001833e63f2495a755d7b51ee37db61ce0af5004/src/util/privPrecCompareUtil.ml
ocaml
open GoblintCil open PrecCompareUtil module LV = struct include Printable.Prod (CilType.Location) (Basetype.Variables) let name () = "location variables" type marshal = t let pretty () (l, v) = Pretty.dprintf "%a %a" CilType.Location.pretty l Basetype.Variables.pretty v let to_location = fst end module Util...
d5d5522881fc99c0adec16209344176a8404167aac87f26c5c7603b1977ac25d
MarcFontaine/stm32hs
MachineInterfaceSTLinkUSB.hs
---------------------------------------------------------------------------- -- | -- Module : STM32.MachineInterfaceSTLinkUSB Copyright : ( c ) 2017 -- License : BSD3 -- Maintainer : -- Stability : experimental Portability : GHC - only -- -- STM32.MachineInterfaceSTLinkUSB is the (in...
null
https://raw.githubusercontent.com/MarcFontaine/stm32hs/d7afeb8f9d83e01c76003f4b199b45044bd4e383/STM32-Zombie/src/STM32/MachineInterfaceSTLinkUSB.hs
haskell
-------------------------------------------------------------------------- | Module : STM32.MachineInterfaceSTLinkUSB License : BSD3 Stability : experimental STM32.MachineInterfaceSTLinkUSB is the (internal) All communication runs through these function. The main driver for ST-Link USB dongles ...
Copyright : ( c ) 2017 Maintainer : Portability : GHC - only API for communication with the STM32Fxxx boards module STM32.MachineInterfaceSTLinkUSB ( MI ,runMI ,initMI ,STM32.MachineInterfaceSTLinkUSB.resetHalt if i remember right hardware implements poke_w16 as 2 poke_w8 that is ver...
83c2bb3faa33c8de2894644e91fca50fc5ee0789440343cfee0e733b588862e1
threatgrid/ctia
static_auth_test.clj
(ns ctia.http.handler.static-auth-test (:require [ctia.domain.entities :refer [schema-version]] [ctia.test-helpers [core :as helpers :refer [POST GET]] [es :as es-helpers]] [clojure.test :refer [deftest is testing use-fixtures]] [ctim.domain.id :as id] ...
null
https://raw.githubusercontent.com/threatgrid/ctia/e92263ff7a021335c6a4990602f6b12159aa566e/test/ctia/http/handler/static_auth_test.clj
clojure
(ns ctia.http.handler.static-auth-test (:require [ctia.domain.entities :refer [schema-version]] [ctia.test-helpers [core :as helpers :refer [POST GET]] [es :as es-helpers]] [clojure.test :refer [deftest is testing use-fixtures]] [ctim.domain.id :as id] ...
c9ee8957e62853e2da5f8708c7dd589a07ccb42bc1be0a88f95c12fd23cc8a69
yfyf/pierl
pierl.erl
%%% This module models asynchronous pi-calculus with %%% channels that are: %%% * buffered %%% * preserve FIFO order (this, combined with the previous %%% point implies that they are _queues_) %%% * owned, there's a single process owning a channel and they %%% need to be explicitly delegated to transfer ownership %...
null
https://raw.githubusercontent.com/yfyf/pierl/8592a12ed89e70e9e9f5c1d1b73da31a5d923630/src/pierl.erl
erlang
This module models asynchronous pi-calculus with channels that are: * buffered * preserve FIFO order (this, combined with the previous point implies that they are _queues_) * owned, there's a single process owning a channel and they need to be explicitly delegated to transfer ownership Moreover, it is exte...
-module(pierl). -include("pierl.hrl"). -define(PI_MSG_TAG, $m). -define(TAG_MSG(Chan, Msg), {?PI_MSG_TAG, {Chan, Msg}}). -define(REC_CASE(Chan, ContF), ?TAG_MSG(Chan, NS__Msg) -> io:format(user, "[debug] [chan: ~200p] (recv) msg: ~200p~n", [Chan, NS__Msg]), ContF(NS__Msg) ). -define(...
e2bfa4e8a9166a3c8db18f54a285952db9d2db01e0cc10f3a107dc96aa8eed21
zerokarmaleft/tapl-haskell
Parser.hs
module Fullsimple.Parser where import Debug.Trace import Data.Functor.Identity import Data.List import Fullsimple.Context import Fullsimple.Terms import Fullsimple.Types import Text.Parsec import qualified Text.Parsec.Expr as Expr import qualified Text.Pars...
null
https://raw.githubusercontent.com/zerokarmaleft/tapl-haskell/7fced6ab1d3d4a7bbe905902ee0443b4c535c306/fullsimple/src/Fullsimple/Parser.hs
haskell
Term Expressions Type Expressions
module Fullsimple.Parser where import Debug.Trace import Data.Functor.Identity import Data.List import Fullsimple.Context import Fullsimple.Terms import Fullsimple.Types import Text.Parsec import qualified Text.Parsec.Expr as Expr import qualified Text.Pars...
7816822ab906344b3c84529b2427a9cdda35a8a806e23896edc0a9214d6fea65
ta0kira/zeolite
CompilerError.hs
----------------------------------------------------------------------------- Copyright 2019 - 2021 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 applic...
null
https://raw.githubusercontent.com/ta0kira/zeolite/9e3cfdc8e147dbcc0e1e3403c37ed5177e5e9283/src/Base/CompilerError.hs
haskell
--------------------------------------------------------------------------- --------------------------------------------------------------------------- --------------------------------------------------------------------------- -} # LANGUAGE Safe # For fixed x, if f y x succeeds for some y then x is removed.
Copyright 2019 - 2021 under the Apache License , Version 2.0 ( the " License " ) ; you may not use this file except in compliance with the License . You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing , software distributed under the License is di...
bb24015873b13a3c1625d88c7cedc291e46634975ca45b3a826abab6260a5972
kqr/gists
hashtester.hs
{-# LANGUAGE BangPatterns #-} module Main where import Data.List (foldl') import Control.Applicative ((<$>)) import Data.Set (Set, size, empty, insert) import Data.Char (ord) import Data.Bits (shiftL, xor) --------------------------------------------------- -- Parameters that might be interesting to change fn = "...
null
https://raw.githubusercontent.com/kqr/gists/b0b5ab2a6af0f939a9e24165959bb362281ce897/numerical-analysis/hashtester.hs
haskell
# LANGUAGE BangPatterns # ------------------------------------------------- Parameters that might be interesting to change ------------------------------------------------- ------------------------------------------------- Space for so much activities! (hash functions) Reference word-wise xor hash function. Reaaaall...
module Main where import Data.List (foldl') import Control.Applicative ((<$>)) import Data.Set (Set, size, empty, insert) import Data.Char (ord) import Data.Bits (shiftL, xor) fn = "cropus.txt" hashSize = 2 usedHasher = xorHasher hashSize xorHasher bytes = fst . foldl' combine (0, 0) where combine (acc...
8f795f0d67dfddbbbdd4f0a97dee081ddc4bd170b21f8d4856750c6128c5f716
tamasjung/maker
async.clj
(ns maker.async (:require [clojure.core.async :as a] [maker.core :as m])) (defn to-promise-chan [v] (doto (a/promise-chan) (a/put! v))) (defn pipe-to-promise-chan [ch] (let [res (a/promise-chan)] (a/pipe ch res) res)) (defn promise-chan-flag? [goal-var] (-> goal-var meta ::promise-c...
null
https://raw.githubusercontent.com/tamasjung/maker/756c54d3c34ad7b7ed0ba9862b3f0db600796870/src/maker/async.clj
clojure
TBD: NOT USED ATM
(ns maker.async (:require [clojure.core.async :as a] [maker.core :as m])) (defn to-promise-chan [v] (doto (a/promise-chan) (a/put! v))) (defn pipe-to-promise-chan [ch] (let [res (a/promise-chan)] (a/pipe ch res) res)) (defn promise-chan-flag? [goal-var] (-> goal-var meta ::promise-c...
65ff1fbb18d758a904484ce7dc5e5452131cb0f1564de6be1fef63084729e947
mput/sicp-solutions
2_60.rkt
#lang racket Solution for exercise 2_60 . (provide adjoin-set union-set) (define (adjoin-set elm set) (cons elm set)) (define (union-set set1 set2) (append set1 set2))
null
https://raw.githubusercontent.com/mput/sicp-solutions/fe12ad2b6f17c99978c8fe04b2495005986b8496/solutions/2_60.rkt
racket
#lang racket Solution for exercise 2_60 . (provide adjoin-set union-set) (define (adjoin-set elm set) (cons elm set)) (define (union-set set1 set2) (append set1 set2))
0c23ef14fdf9a27aa9e608b053724d5a39f6cbc01b07b6011891d602944a73d6
Dasudian/DSDIN
utils_mp_trees_tests.erl
%%%============================================================================= ( C ) 2018 , Dasudian Technologies %%% @doc Unit tests for Merkle Patricia Trees %%% @end %%%============================================================================= -module(utils_mp_trees_tests). -include_lib("eunit/include/...
null
https://raw.githubusercontent.com/Dasudian/DSDIN/b27a437d8deecae68613604fffcbb9804a6f1729/apps/utils/test/utils_mp_trees_tests.erl
erlang
============================================================================= @doc @end ============================================================================= For internal functional db ============================================================================= Basic tests =================================...
( C ) 2018 , Dasudian Technologies Unit tests for Merkle Patricia Trees -module(utils_mp_trees_tests). -include_lib("eunit/include/eunit.hrl"). -export([ dict_db_commit/2 , dict_db_get/2 , dict_db_put/3 ]). basic_test_() -> [ {"Put", fun test_put/0} , {"Lookup", fun test_look...
c818967d8c9cdc0d97cb025b31a6668d8f071fdf5e55fb03fc0d0c4965a55018
haskell/cabal
License.hs
{-# LANGUAGE DeriveDataTypeable #-} # LANGUAGE DeriveGeneric # module Distribution.SPDX.License ( License (..), ) where import Prelude () import Distribution.Compat.Prelude import Distribution.Pretty import Distribution.Parsec import Distribution.SPDX.LicenseExpression import qualified Distribution.Compat.Ch...
null
https://raw.githubusercontent.com/haskell/cabal/0abbe37187f708e0a5daac8d388167f72ca0db7e/Cabal-syntax/src/Distribution/SPDX/License.hs
haskell
# LANGUAGE DeriveDataTypeable # | Declared license. Old 'License' can be migrated using following rules: The package may not be legally modified or redistributed by anyone but the rightsholder. * @OtherLicense@ can be converted to 'LicenseRef' pointing to the file in the package. * @PublicDomain@ isn...
# LANGUAGE DeriveGeneric # module Distribution.SPDX.License ( License (..), ) where import Prelude () import Distribution.Compat.Prelude import Distribution.Pretty import Distribution.Parsec import Distribution.SPDX.LicenseExpression import qualified Distribution.Compat.CharParsing as P import qualified Text...
c273aa25b9665b8dc8ed7f2497594d56350ca9334097795f0f4170e4f444546c
rigidus/rigidus.ru
html.lisp
;; [[file:doc.org::*DSL для построения HTML][html]] (in-package :rigidus) (defun stringify (&rest things) "Like concatenate but prints all of its arguments." (format nil "~{~A~}" things)) (in-package :rigidus) (defun rn () (string #\Newline)) (defun idx (idx) (make-string (* 2 idx) :initial-element #\Space))...
null
https://raw.githubusercontent.com/rigidus/rigidus.ru/34fe088f5c3d22243b49cf97f376c8f3c1243dff/src/html.lisp
lisp
[[file:doc.org::*DSL для построения HTML][html]] (t expr)) html ends here
(in-package :rigidus) (defun stringify (&rest things) "Like concatenate but prints all of its arguments." (format nil "~{~A~}" things)) (in-package :rigidus) (defun rn () (string #\Newline)) (defun idx (idx) (make-string (* 2 idx) :initial-element #\Space)) (in-package :rigidus) (defvar *ps-html-empty-tag-a...
7389c2511ce1442e1a6c383ad824dd8ffa330de225c59d8ee2fd569461e02f91
eareese/htdp-exercises
081-time-seconds.rkt
#lang htdp/bsl (define-struct time [hours minutes seconds]) ; Time -> Number ; interpretation the number of seconds that have passed since midnight at a given Time (check-expect (time->seconds (make-time 12 30 2)) 45002) (define (time->seconds t) (+ (* 60 60 (time-hours t)) (* 60 (time-minutes t)) (time-...
null
https://raw.githubusercontent.com/eareese/htdp-exercises/a85ff3111d459dda0e94d9b463d01a09accbf9bf/part01-fixed-size-data/081-time-seconds.rkt
racket
Time -> Number interpretation the number of seconds that have passed since
#lang htdp/bsl (define-struct time [hours minutes seconds]) midnight at a given Time (check-expect (time->seconds (make-time 12 30 2)) 45002) (define (time->seconds t) (+ (* 60 60 (time-hours t)) (* 60 (time-minutes t)) (time-seconds t)))
24688e6197e800dc55f1897c38706c570deebce17de01910929113d4c963690d
Killeroid/PushCalc
core.clj
(ns Calculator.core (:require [clojush] [clojure.contrib.math]) (:use [clojush] [clojure.contrib.math])) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Editing ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (in-ns 'clojush) (def push-types '(:exec :integer :float :code :boolean :auxiliary :tag :zip :string :...
null
https://raw.githubusercontent.com/Killeroid/PushCalc/68ea1ba84ba8c4c012b57274237412b77530511e/src/Calculator/core.clj
clojure
Back to calc namespace String instructions Symbol instructions (define-registered symbol_call (caller :symbol)) Fitness function helper functions The list of buttons on calc integer_yank integer_yankdup integer_shove integer_stackdepth integer_fromfloat integer_rand boolean_yank boolean_fromfloat boolea...
(ns Calculator.core (:require [clojush] [clojure.contrib.math]) (:use [clojush] [clojure.contrib.math])) Editing (in-ns 'clojush) (def push-types '(:exec :integer :float :code :boolean :auxiliary :tag :zip :string :symbol)) (define-push-state-structure) (defn recognize-literal "If thin...
30e2faaa1a0033a7158138688c74636439e042234523684215a2312a57524577
theodormoroianu/SecondYearCourses
mWriterL.hs
--- Monada Writer newtype WriterLS a = Writer { runWriter :: (a, [String]) } instance Monad WriterLS where return va = Writer (va, []) ma >>= k = let (va, log1) = runWriter ma (vb, log2) = runWriter (k va) in Writer (vb, log1 ++ log2) instance Applicative...
null
https://raw.githubusercontent.com/theodormoroianu/SecondYearCourses/99185b0e97119135e7301c2c7be0f07ae7258006/FLP/laborator/lab3/mWriterL.hs
haskell
- Monada Writer ordinea in care afiseaza logurile
newtype WriterLS a = Writer { runWriter :: (a, [String]) } instance Monad WriterLS where return va = Writer (va, []) ma >>= k = let (va, log1) = runWriter ma (vb, log2) = runWriter (k va) in Writer (vb, log1 ++ log2) instance Applicative WriterLS where ...
b5de2684b00e10119b4d7e57db66495d029ff21f376745628550431cc9f39110
imdea-software/leap
test_genset.ml
(***********************************************************************) (* *) LEAP (* *) , IMDEA ...
null
https://raw.githubusercontent.com/imdea-software/leap/5f946163c0f80ff9162db605a75b7ce2e27926ef/src/tests/test_genset.ml
ocaml
********************************************************************* ...
LEAP , IMDEA Software Institute Copyright 2011 IMDEA Software Institute Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not use this file except in compl...
88fd04c90b4f4224068382dceeb9e005a550cb879c5cc596f0febb88abe18815
serokell/edna
Orphans.hs
SPDX - FileCopyrightText : 2021 > -- SPDX - License - Identifier : AGPL-3.0 - or - later # OPTIONS_GHC -fno - warn - orphans # -- | Orphan instances for types from other packages -- needed only in tests. module Test.Orphans () where import Universum import Data.Aeson.TH (deriveFromJSON) import Edna.Dashboar...
null
https://raw.githubusercontent.com/serokell/edna/9a559cd77797f1312981c34cd4d8be130e52d093/backend/test/Test/Orphans.hs
haskell
| Orphan instances for types from other packages needed only in tests. in tests we want to do incomplete pattern-matching sometimes and @MonadFail@ is needed for that. Instances to allow use of `servant-quickcheck`.
SPDX - FileCopyrightText : 2021 > SPDX - License - Identifier : AGPL-3.0 - or - later # OPTIONS_GHC -fno - warn - orphans # module Test.Orphans () where import Universum import Data.Aeson.TH (deriveFromJSON) import Edna.Dashboard.Web.Types (ExperimentFileBlob(..), ExperimentMetadata(..), ExperimentResp(.....
acb28a00cfbe418b302068cf9c54dac3ae589babe69fe51b184507848d06787b
mbj/stratosphere
CampaignHookProperty.hs
module Stratosphere.Pinpoint.Campaign.CampaignHookProperty ( CampaignHookProperty(..), mkCampaignHookProperty ) where import qualified Data.Aeson as JSON import qualified Stratosphere.Prelude as Prelude import Stratosphere.Property import Stratosphere.ResourceProperties import Stratosphere.Value data Campai...
null
https://raw.githubusercontent.com/mbj/stratosphere/c70f301715425247efcda29af4f3fcf7ec04aa2f/services/pinpoint/gen/Stratosphere/Pinpoint/Campaign/CampaignHookProperty.hs
haskell
module Stratosphere.Pinpoint.Campaign.CampaignHookProperty ( CampaignHookProperty(..), mkCampaignHookProperty ) where import qualified Data.Aeson as JSON import qualified Stratosphere.Prelude as Prelude import Stratosphere.Property import Stratosphere.ResourceProperties import Stratosphere.Value data Campai...
a1489354e14ca28dd97a450df160ceb5b38a5b28388f747aa2e27995a9831754
batterseapower/supercompilation-by-evaluation
TreeFlip-NoLiterals.hs
#include "../Prelude.hs" data Tree a = Leaf a | Branch (Tree a) (Tree a) eq'Int = (==) :: Int -> Int -> Bool plus'Int = (+) :: Int -> Int -> Int subtract'Int = (-) :: Int -> Int -> Int multiply'Int = (*) :: Int -> Int -> Int
null
https://raw.githubusercontent.com/batterseapower/supercompilation-by-evaluation/daeb3e12ca8319a5144dd48a763cf7e7825a1999/examples/peter/TreeFlip-NoLiterals.hs
haskell
#include "../Prelude.hs" data Tree a = Leaf a | Branch (Tree a) (Tree a) eq'Int = (==) :: Int -> Int -> Bool plus'Int = (+) :: Int -> Int -> Int subtract'Int = (-) :: Int -> Int -> Int multiply'Int = (*) :: Int -> Int -> Int
375cc9c72683ce7d5a29a096a09b2563a3fa730c551165f724457c4057146f6c
Mayvenn/storefront
legal.cljc
(ns ui.legal (:require [storefront.components.ui :as ui] [storefront.component :as c :refer [defcomponent]] [storefront.platform.component-utils :as utils] [storefront.platform.messages :refer [handle-message]] [storefront.keypaths :as keypaths] [storefront....
null
https://raw.githubusercontent.com/Mayvenn/storefront/31e0ecc22e60709e3720101981d3960f1bc0735e/src-cljc/ui/legal.cljc
clojure
chances, you probably want to use opt-in-section TODO(jeff): seems like a good use for spice.maps/with, but some compile error occurs when importing that namespace TODO(jeff): seems like a good use for spice.maps/with, but some compile error occurs when importing that namespace
(ns ui.legal (:require [storefront.components.ui :as ui] [storefront.component :as c :refer [defcomponent]] [storefront.platform.component-utils :as utils] [storefront.platform.messages :refer [handle-message]] [storefront.keypaths :as keypaths] [storefront....
26ee5a3527477f7308c329b6c25e5cc4c1fdb6f417041a2cea8e815102a118d5
ragkousism/Guix-on-Hurd
attr.scm
;;; GNU Guix --- Functional package management for GNU Copyright © 2012 < > Copyright © 2012 , 2013 , 2016 < > ;;; ;;; This file is part of GNU Guix. ;;; GNU is free software ; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software F...
null
https://raw.githubusercontent.com/ragkousism/Guix-on-Hurd/e951bb2c0c4961dc6ac2bda8f331b9c4cee0da95/gnu/packages/attr.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 © 2012 < > Copyright © 2012 , 2013 , 2016 < > 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 < / > . (define-module (gnu packages attr) #:use-module (guix licenses) #:use-...
7548a47fb5bc89c4e7b8f27e0f27b3c3713101ad4c0f5966cbf76cc8aba9d3fc
RedPRL/algaett
Pi.ml
open RuleKit let pi ~name ~cbase ~cfam : T.check = Quantifier.quantifier ~name ~cbase ~cfam S.pi let vir_pi ~name ~cbase ~cfam : T.check = Quantifier.vir_quantifier ~name ~cbase ~cfam S.vir_pi let lam ~name ~cbnd : T.check = T.Check.rule @@ fun goal -> match goal.tp with | D.Pi (base, fam) | D.VirPi (base,...
null
https://raw.githubusercontent.com/RedPRL/algaett/ac9fd3082b504e0eb8dfd43e82b40722b63afbfd/src/refiner/rules/Pi.ml
ocaml
open RuleKit let pi ~name ~cbase ~cfam : T.check = Quantifier.quantifier ~name ~cbase ~cfam S.pi let vir_pi ~name ~cbase ~cfam : T.check = Quantifier.vir_quantifier ~name ~cbase ~cfam S.vir_pi let lam ~name ~cbnd : T.check = T.Check.rule @@ fun goal -> match goal.tp with | D.Pi (base, fam) | D.VirPi (base,...
79951f6092f54b2e79694314ea54aa3f867296e01b7ac8eabf3f87cc50abfb28
djblue/portal
default_visualizer.clj
(ns examples.default-visualizer (:require [clojure.core.protocols :refer [nav]] [clojure.string :as str])) (defn nav-dep-anno-tree [coll _ v] (let [{:keys [deps-map]} (meta coll)] (with-meta [:div "Depends on " (str/join ", " (map str (get deps-map v)))] {:portal.viewer/default :portal...
null
https://raw.githubusercontent.com/djblue/portal/9110dabd9fb0f05c1fbb54f4b5981e82fc9ed644/src/examples/default_visualizer.clj
clojure
(ns examples.default-visualizer (:require [clojure.core.protocols :refer [nav]] [clojure.string :as str])) (defn nav-dep-anno-tree [coll _ v] (let [{:keys [deps-map]} (meta coll)] (with-meta [:div "Depends on " (str/join ", " (map str (get deps-map v)))] {:portal.viewer/default :portal...
40475296f9bda39b0fa934b0346b5802d1c97e879c53c8be81bfd5a53228d1fd
jeffshrager/biobike
frame-creation.lisp
-*- Package : aframes ; mode : lisp ; base : 10 ; Syntax : Common - Lisp ; -*- (in-package :aframes) ;;; +=========================================================================+ | Copyright ( c ) 2002 , 2003 , 2004 JP , , | ;;; | ...
null
https://raw.githubusercontent.com/jeffshrager/biobike/5313ec1fe8e82c21430d645e848ecc0386436f57/BioLisp/Sframes/frame-creation.lisp
lisp
mode : lisp ; base : 10 ; Syntax : Common - Lisp ; -*- +=========================================================================+ | | | Permission is hereby granted, free of charge, to any person obtaining | | a copy of this software and as...
(in-package :aframes) | Copyright ( c ) 2002 , 2003 , 2004 JP , , | | " Software " ) , to deal in the Software without restriction , including | | distribute , sublicense , and/or sell copies of the Software , and to | | permit persons to whom the Software is furnished to do so , subject t...
6b008d24b8bbf9fcc53274fbf4817aaa5284a407e90d7e2378d068fdb3169883
mu-chaco/ReWire
ToCrust.hs
# LANGUAGE ScopedTypeVariables , FlexibleContexts , OverloadedStrings # {-# LANGUAGE Safe #-} module ReWire.Crust.ToCrust (toCrust, extendWithGlobs, getImps) where import ReWire.Annotation hiding (ann) import ReWire.Error import ReWire.Crust.Fixity import ReWire.Crust.Rename hiding (Module) import ReWire.Crust.Syntax ...
null
https://raw.githubusercontent.com/mu-chaco/ReWire/b04686a4cd6cb36ca9976a4b6c42bc195ce69462/src/ReWire/Crust/ToCrust.hs
haskell
# LANGUAGE Safe # | An intermediate form for exports. TODO(chathhorn): get rid of it. ExportWith: Type name, ctors TODO(chathhorn): I don't know what it means for a wildcard to appear in the middle of an export list. I guess this doesn't need to be in the monad, really, but whatever... --adam Not sure what the bo...
# LANGUAGE ScopedTypeVariables , FlexibleContexts , OverloadedStrings # module ReWire.Crust.ToCrust (toCrust, extendWithGlobs, getImps) where import ReWire.Annotation hiding (ann) import ReWire.Error import ReWire.Crust.Fixity import ReWire.Crust.Rename hiding (Module) import ReWire.Crust.Syntax ((|->)) import ReWire....
c5746ea38b25dc922f3a3280f1a0df7d75017f5c32e963e297b6de81f9ad7c1e
esb-lwb/lwb
truthtable.clj
lwb Logic WorkBench -- Propositional Logic ; Examples: Truth tables Copyright ( c ) 2016 , THM . All rights reserved . ; The use and distribution terms for this software are covered by the Eclipse Public License 1.0 ( -1.0.php ) . ; By using this software in any fashion, you are agreeing to be bound by ; the t...
null
https://raw.githubusercontent.com/esb-lwb/lwb/bba51ada7f7316341733d37b0dc4848c4891ef3a/src/lwb/prop/examples/truthtable.clj
clojure
Examples: Truth tables The use and distribution terms for this software are covered by the By using this software in any fashion, you are agreeing to be bound by the terms of this license. | P | Q | :result | |---+---+---------| | T | T | T | | T | F | F | | F | T | T | | F | F | T | ...
lwb Logic WorkBench -- Propositional Logic Copyright ( c ) 2016 , THM . All rights reserved . Eclipse Public License 1.0 ( -1.0.php ) . (ns lwb.prop.examples.truthtable (:require [lwb.prop :refer :all]) (:require [lwb.prop.sat :refer [valid? sat?]])) (def phi '(and (impl (and P Q S) P) (impl (and P S) Q)...
93ced7c1d746793717d18ea4597d8ff2d4d5a67b3290bb43513f1ea300d4a8c7
quoll/asami
planner.cljc
(ns ^{:doc "Namespace for functions that plan queries" :author "Paula Gearon"} asami.planner #?(:clj (:refer-clojure :exclude [eval])) (:require [clojure.set :as set] [clojure.string :as str] [zuko.schema :refer [EPVPattern Pattern EvalPattern Var vartest? ...
null
https://raw.githubusercontent.com/quoll/asami/c1bd83b8e48894382b7276f7d5609e3285544f2b/src/asami/planner.cljc
clojure
Bindings are when predefined data is given to the query these take the form of a sequence of binding values and the column names in metadata fixed bindings, or a mathing pattern for an index, or a binding expression patterns contains metadata and pattern does not only use this pattern when it matches what has bee...
(ns ^{:doc "Namespace for functions that plan queries" :author "Paula Gearon"} asami.planner #?(:clj (:refer-clojure :exclude [eval])) (:require [clojure.set :as set] [clojure.string :as str] [zuko.schema :refer [EPVPattern Pattern EvalPattern Var vartest? ...
35007d4e8a377aa3509924ed4e3b5a427edd65f8e1901b8b05522abf04057eae
dgtized/shimmers
minimum_spanning_tree_test.cljc
(ns shimmers.algorithm.minimum-spanning-tree-test (:require [clojure.test :as t :refer [deftest is] :include-macros true] [shimmers.algorithm.minimum-spanning-tree :as sut] [thi.ng.geom.vector :as gv])) (deftest kruskals (is (= [[:a :b] [:b :c] [:c :d]] (sut/kruskal [:a :b :c :d] [[:a :b] [:b :c]...
null
https://raw.githubusercontent.com/dgtized/shimmers/57288e7faa60d9e04e2c515ef93c7016864b0d53/test/shimmers/algorithm/minimum_spanning_tree_test.cljc
clojure
(ns shimmers.algorithm.minimum-spanning-tree-test (:require [clojure.test :as t :refer [deftest is] :include-macros true] [shimmers.algorithm.minimum-spanning-tree :as sut] [thi.ng.geom.vector :as gv])) (deftest kruskals (is (= [[:a :b] [:b :c] [:c :d]] (sut/kruskal [:a :b :c :d] [[:a :b] [:b :c]...
ffaa52d392fc7f047b76721d7ff3bb59a3ed011c71a3e23d73fe3b8dd2b4447b
earl-ducaine/cl-garnet
aggrelists.lisp
-*- Mode : LISP ; Syntax : Common - Lisp ; Package : OPAL ; Base : 10 -*- ; ; ; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; The Garnet User Interface Development Environment . ; ; ; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; This code was wr...
null
https://raw.githubusercontent.com/earl-ducaine/cl-garnet/f0095848513ba69c370ed1dc51ee01f0bb4dd108/src/aggregadgets/aggrelists.lisp
lisp
Syntax : Common - Lisp ; Package : OPAL ; Base : 10 -*- ; ; ; ; ; This code was written as part of the Garnet project at ;;; ; ; ; ; please contact to be put on the mailing list. ;;; and customizable horizontal or vertical layout, generation of items according to a prototype, and can be used with...
AGGRELISTS . This subclass of aggregates allow the easy creation of list - type objects , such as menus . Aggrelists features automatic May , 1993 : A new version of Aggrelists by and . (in-package "OPAL") (eval-when (:execute :load-toplevel :compile-toplevel) (export '(aggrelist null-...
472e3cb672c95361ec75f855adc94be7c7aba3026950f1737eb3bc9ef60913a2
mwotton/squealgen
DBSpec.hs
{-# LANGUAGE DeriveAnyClass #-} # LANGUAGE DerivingStrategies # {-# LANGUAGE DerivingVia #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE ScopedTypeVariables #-} # LANGUAGE UndecidableInstances # # LANGUAGE GeneralizedNewtypeDeriving # module Domains.DBSpec where import Data.Int impo...
null
https://raw.githubusercontent.com/mwotton/squealgen/859ba8c8dcbd9394b1c063244a4728f4efa5465d/test/Domains/DBSpec.hs
haskell
# LANGUAGE DeriveAnyClass # # LANGUAGE DerivingVia # # LANGUAGE OverloadedStrings # # LANGUAGE ScopedTypeVariables #
# LANGUAGE DerivingStrategies # # LANGUAGE UndecidableInstances # # LANGUAGE GeneralizedNewtypeDeriving # module Domains.DBSpec where import Data.Int import DBHelpers (runSession) import Domains.Public import qualified Generics.SOP as SOP import qualified GHC.Generics ...
d9381140a7722c283b74f9f54829d074e75d34bc155cbaea3ef25b48bea11f5d
adityaathalye/sicp
ch2-1-1-rational-math.scm
Ch . 2.1.1 Introduction to data abstraction : ; Example: Arithmetic operations for rational numbers ; Using "wishful thinking", the powerful strategy of synthesis, we ; define a skeleton of procedures that will help us construct ; a rational number and select its numerator and denominator... ; (define (make-rat n ...
null
https://raw.githubusercontent.com/adityaathalye/sicp/c8b62c366dade1d5101238a32267dab177808105/ch2-1-1-rational-math.scm
scheme
Example: Arithmetic operations for rational numbers Using "wishful thinking", the powerful strategy of synthesis, we define a skeleton of procedures that will help us construct a rational number and select its numerator and denominator... (define (make-rat n d) ; Should create a rational number ) (define (nume...
Ch . 2.1.1 Introduction to data abstraction : (define (add-rat x y) (make-rat (+ (* (numer x) (denom y)) (* (numer y) (denom x))) (* (denom x) (denom y)))) (define (sub-rat x y) (make-rat (- (* (numer x) (denom y)) (* (numer y) ...
9107e0d9c60f5a99f45d4c985366daefd8790fd9122048694f71344c475da104
relaypro-open/imetrics
imetrics_http_server.erl
-module(imetrics_http_server). -behaviour(gen_server). -define(SERVER, ?MODULE). %% ------------------------------------------------------------------ %% API Function Exports %% ------------------------------------------------------------------ -export([start_link/0, cowboy_pid/0, await/1, port/0]). %% -------------...
null
https://raw.githubusercontent.com/relaypro-open/imetrics/b3b9e0c14c83d8750d4c95b93462f482db9fdc49/src/imetrics_http_server.erl
erlang
------------------------------------------------------------------ API Function Exports ------------------------------------------------------------------ ------------------------------------------------------------------ ------------------------------------------------------------------ -------------------------...
-module(imetrics_http_server). -behaviour(gen_server). -define(SERVER, ?MODULE). -export([start_link/0, cowboy_pid/0, await/1, port/0]). gen_server Function Exports -export([ init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3 ]). -record(state, {cowboy_pid, po...
c9ec95817eb2864e665598cd25c8ced86004a1b365ff50f6798bf4e1767687b9
erlang/otp
gl_gen_erl.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 2008 - 2022 . All Rights Reserved . %% Licensed under the Apache License , Version 2.0 ( the " License " ) ; %% you may not use this file except in compliance with the License. %% You may obtain a copy of the License at %% %% -2.0 %% %% Unless required by applicab...
null
https://raw.githubusercontent.com/erlang/otp/407994faba213b66cbc2f76ab4aaf69bafd10474/lib/wx/api_gen/gl_gen_erl.erl
erlang
%CopyrightBegin% you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific lan...
Copyright Ericsson AB 2008 - 2022 . All Rights Reserved . Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , Author : Created : 18 Apr 2007 by -module(gl_gen_erl). -include("gl_gen.hrl"). -compile([export_all...
69398b1d8e4044e91f151f6e1a89f751411ca143d3414bac46fe90ddcb2cb677
fission-codes/fission
Verbose.hs
module Fission.CLI.Parser.Verbose ( parser , module Fission.CLI.Parser.Verbose.Types ) where import Options.Applicative import Fission.Prelude import Fission.CLI.Parser.Verbose.Types parser :: Parser VerboseFlag parser = fmap VerboseFlag . switch $ mconcat [ help "Detailed ...
null
https://raw.githubusercontent.com/fission-codes/fission/11d14b729ccebfd69499a534445fb072ac3433a3/fission-cli/library/Fission/CLI/Parser/Verbose.hs
haskell
--------
module Fission.CLI.Parser.Verbose ( parser , module Fission.CLI.Parser.Verbose.Types ) where import Options.Applicative import Fission.Prelude import Fission.CLI.Parser.Verbose.Types parser :: Parser VerboseFlag parser = fmap VerboseFlag . switch $ mconcat [ help "Detailed ...
b6ecf0791343e2d57cd541020243c5cb2970673c543e7e66423748634b9da8aa
sschwarzer/racket-glossary
fix-svgs.rkt
#lang racket/base (require racket/file racket/format racket/function racket/match racket/string xml xml/path) ; Return `#t` if the XML `document` needs fixing. Otherwise return `#f`. See ; `fix-svg` on what "fixing" means. ; ; To keep things simple, check only the style information. If we don't find it,...
null
https://raw.githubusercontent.com/sschwarzer/racket-glossary/8dd644fca0923274b3393d23e654560edf76b1b8/fix-svgs.rkt
racket
Return `#t` if the XML `document` needs fixing. Otherwise return `#f`. See `fix-svg` on what "fixing" means. To keep things simple, check only the style information. If we don't find it, assume we both need to add the style information and change the `stroke` attributes. For `prefers-color-scheme` to be applied,...
#lang racket/base (require racket/file racket/format racket/function racket/match racket/string xml xml/path) (define (needs-fixing? document) (define document-xexpr (xml->xexpr (document-element document))) (define style-element (se-path* '(svg defs style) document-xexpr)) (not style-elem...
9fe680005d1791191bba97a59132f02f0ee12454a8822d1e4b83302bacd2babd
esl/MongooseIM
service_deps_SUITE.erl
-module(service_deps_SUITE). -compile([export_all, nowarn_export_all]). -include_lib("eunit/include/eunit.hrl"). -import(mongoose_service_deps, [resolve_deps/1, sort_deps/1]). all() -> [ no_dependencies, dependency, dependency_chain, dependency_dag, fails_on_dependency_cycle, preser...
null
https://raw.githubusercontent.com/esl/MongooseIM/6fcb515c89da075a23eb093577a15563b167c002/test/service_deps_SUITE.erl
erlang
Test cases Helpers
-module(service_deps_SUITE). -compile([export_all, nowarn_export_all]). -include_lib("eunit/include/eunit.hrl"). -import(mongoose_service_deps, [resolve_deps/1, sort_deps/1]). all() -> [ no_dependencies, dependency, dependency_chain, dependency_dag, fails_on_dependency_cycle, preser...
82b8895fc7a9ba9156d679cd3a3726262af80b775c3fa7baa12f69c2cb72425d
babashka/nbb
honeysql.cljs
(ns example (:require ["sqlite$default" :refer [open]] ["sqlite3$default" :as sqlite] [honey.sql :as sql] [promesa.core :as p])) (p/let [db (open #js {:filename ":memory:" :driver sqlite/Database})] (.run db (first (sql/format {:create-table :lorem ...
null
https://raw.githubusercontent.com/babashka/nbb/4d06aa142a5fb5baac48a8ad8e611d672f779b5f/examples/sqlite/honeysql.cljs
clojure
(ns example (:require ["sqlite$default" :refer [open]] ["sqlite3$default" :as sqlite] [honey.sql :as sql] [promesa.core :as p])) (p/let [db (open #js {:filename ":memory:" :driver sqlite/Database})] (.run db (first (sql/format {:create-table :lorem ...
e2f63f8fa79fbf5e5e558627464eed709f5272b9d09e4d98725284272d22a5a2
samedhi/firemore
config.cljs
(ns firemore.config (:require [clojure.string :as string] [goog.object :as goog.object])) (def TIMESTAMP :firemore/timestamp) (def NO_DOCUMENT :firemore/no-document) (def LOADING :firemore/loading) (def default-firebase-config {:api-key "AIzaSyAEEGdlXMkrxbF-OWbsDffCSKMogeiRvfA" :project-id "inferno-...
null
https://raw.githubusercontent.com/samedhi/firemore/8a1829efbe9cbed367f1d49d0e92e01c5aa20ad5/src/firemore/config.cljs
clojure
(ns firemore.config (:require [clojure.string :as string] [goog.object :as goog.object])) (def TIMESTAMP :firemore/timestamp) (def NO_DOCUMENT :firemore/no-document) (def LOADING :firemore/loading) (def default-firebase-config {:api-key "AIzaSyAEEGdlXMkrxbF-OWbsDffCSKMogeiRvfA" :project-id "inferno-...
54aac2a1121979ffd9d3e885f0b8d8f201c220f3042668e4aa41bc7d32ff92ca
TrustInSoft/tis-kernel
annotations.mli
(**************************************************************************) (* *) This file is part of . (* *) is a fork of Frama - C. Al...
null
https://raw.githubusercontent.com/TrustInSoft/tis-kernel/748d28baba90c03c0f5f4654d2e7bb47dfbe4e7d/src/kernel_services/ast_data/annotations.mli
ocaml
************************************************************************ ...
This file is part of . is a fork of Frama - C. All the differences are : Copyright ( C ) 2016 - 2017 is released under GPLv2 This file is part of Frama - C. Copyright ( C ) 2007 - 2015 ...
d69aa85b61c5f3b4235bfac30c91e272890ffd5466e49e1ee4ba1de860f5ee41
racket/gui
menu.rkt
#lang scheme/unit (require mzlib/class "sig.rkt" "../preferences.rkt" mred/mred-sig) (import mred^) (export framework:menu^) (define can-restore<%> (interface (selectable-menu-item<%>) restore-keybinding)) (define can-restore-mixin (mixin (selectable-men...
null
https://raw.githubusercontent.com/racket/gui/d1fef7a43a482c0fdd5672be9a6e713f16d8be5c/gui-lib/framework/private/menu.rkt
racket
#lang scheme/unit (require mzlib/class "sig.rkt" "../preferences.rkt" mred/mred-sig) (import mred^) (export framework:menu^) (define can-restore<%> (interface (selectable-menu-item<%>) restore-keybinding)) (define can-restore-mixin (mixin (selectable-men...
42e5fa36ea9bcb0f5a499ea35cd7b807c33898d678281cabf30ba588bb87b5e0
Elzair/nazghul
henry.scm
;;---------------------------------------------------------------------------- ;; Constants ;;---------------------------------------------------------------------------- ;;---------------------------------------------------------------------------- ;; Schedule ;; In Oparine . ;;------------------------------------...
null
https://raw.githubusercontent.com/Elzair/nazghul/8f3a45ed6289cd9f469c4ff618d39366f2fbc1d8/worlds/haxima-1.002/henry.scm
scheme
---------------------------------------------------------------------------- Constants ---------------------------------------------------------------------------- ---------------------------------------------------------------------------- Schedule ------------------------------------------------------------------...
In Oparine . (kern-mk-sched 'sch_henry (list 0 0 bilge-water-bed "sleeping") (list 8 0 bilge-water-counter "working") (list 23 0 bilge-water-bed "sleeping") ) (define (henry-mk) nil) Henry is a one - handed tavern - keeper , doing trade in ...
976e34aab400e36f803fd1d1d27262953184681c5d54ef98219ee57c95ea346d
mfikes/coal-mine
problem_33.cljc
(ns coal-mine.problem-33 (:require [coal-mine.checks :refer [defcheck-33] :rename {defcheck-33 defcheck}] [clojure.test])) (defcheck solution-10121f9 (fn ras[s n] (if (empty? s) '() (concat (repeat n (first s)) (ras (rest s) n))))) (defcheck solution-1032f9e3 (fn [l,t] (mapcat #(repe...
null
https://raw.githubusercontent.com/mfikes/coal-mine/0961d085b37f4e59489a8cf6a2b8fef0a698d8fb/src/coal_mine/problem_33.cljc
clojure
(fn silly-dup [[x & xs] cnt] (if x []))
(ns coal-mine.problem-33 (:require [coal-mine.checks :refer [defcheck-33] :rename {defcheck-33 defcheck}] [clojure.test])) (defcheck solution-10121f9 (fn ras[s n] (if (empty? s) '() (concat (repeat n (first s)) (ras (rest s) n))))) (defcheck solution-1032f9e3 (fn [l,t] (mapcat #(repe...
20212edca16fae9f0a01883d4657a5a529f7a78bc173408a6dfa8acb03c082d9
thheller/shadow-cljsjs
p5.cljs
(ns cljsjs.p5 (:require ["p5" :as p5])) (js/goog.exportSymbol "p5" p5)
null
https://raw.githubusercontent.com/thheller/shadow-cljsjs/eaf350d29d45adb85c0753dff77e276e7925a744/src/main/cljsjs/p5.cljs
clojure
(ns cljsjs.p5 (:require ["p5" :as p5])) (js/goog.exportSymbol "p5" p5)
9bb1bdcf20ecb272202f24dd024000d008c47fbdfb915f8f1c57aaa4eb447233
elaforge/karya
Note.hs
Copyright 2013 -- This program is distributed under the terms of the GNU General Public -- License 3.0, see COPYING or -3.0.txt -- | Basic calls for note tracks. module Derive.C.Prelude.Note ( library , c_note, transformed_note, note_call , Config(..), use_attributes, no_duration_attributes , Gener...
null
https://raw.githubusercontent.com/elaforge/karya/8ea15e6a5fb57e2f15f8c19836751e315f9c09f2/Derive/C/Prelude/Note.hs
haskell
This program is distributed under the terms of the GNU General Public License 3.0, see COPYING or -3.0.txt | Basic calls for note tracks. | This is mostly useful for tests when I need some call that makes a note and takes arguments. * note | Create a standard note call with a transformer applied. | Create a not...
Copyright 2013 module Derive.C.Prelude.Note ( library , c_note, transformed_note, note_call , Config(..), use_attributes, no_duration_attributes , GenerateNote , default_note, default_note_integrate , note_flags , adjust_duration , min_duration ) where import qualified Data.Either a...
55552ce3c652ad3bdeff16af5bde7c4eed4ce356174515fef6f955e6ac81fabd
phadej/language-pts
Equality.hs
#ifdef LANGUAGE_PTS_HAS_EQUALITY #ifdef LANGUAGE_PTS_HAS_BOOL #ifdef LANGUAGE_PTS_HAS_NAT #ifdef LANGUAGE_PTS_HAS_SIGMA #ifdef LANGUAGE_PTS_HAS_PROP #define EQUALITY_EXAMPLES # LANGUAGE OverloadedStrings , ScopedTypeVariables # #endif #endif #endif #endif #endif module Language.PTS.Examples.Equality ( #ifdef EQUALITY_E...
null
https://raw.githubusercontent.com/phadej/language-pts/761e5b92b14506b75164bd3162487df2d7fbfa93/src/Language/PTS/Examples/Equality.hs
haskell
| 1 . Non - dependent elimination : if ----------------------------------- -- = λ r b t f → 𝔹-elim (λ _ → r) t f b -- 2 . Negation , not ------------------- -- λ» :define not : 𝔹 → 𝔹 = λ b → if 𝔹 b false true -- λ» :example not ↪ λ b → 𝔹-elim (λ _ → 𝔹) false true b : 𝔹 → 𝔹 -- λ» :e...
#ifdef LANGUAGE_PTS_HAS_EQUALITY #ifdef LANGUAGE_PTS_HAS_BOOL #ifdef LANGUAGE_PTS_HAS_NAT #ifdef LANGUAGE_PTS_HAS_SIGMA #ifdef LANGUAGE_PTS_HAS_PROP #define EQUALITY_EXAMPLES # LANGUAGE OverloadedStrings , ScopedTypeVariables # #endif #endif #endif #endif #endif module Language.PTS.Examples.Equality ( #ifdef EQUALITY_E...
2fc4ce466d06d15b12103ae852b5230b1500e6251d310137bbf5999f6f03e5e0
lambdacube3d/lambdacube-compiler
TestData.hs
-- generated file, do not modify! 2016 - 02 - 12T16:05:13.383716000000Z {-# LANGUAGE OverloadedStrings, RecordWildCards #-} module TestData where import Data.Int import Data.Word import Data.Map import Data.Vector (Vector(..)) import LambdaCube.Linear import Data.Text import Data.Aeson hiding (Value,Bool) import D...
null
https://raw.githubusercontent.com/lambdacube3d/lambdacube-compiler/ca8d65a210a8801c8358fc29a9ead427afc9fce4/backendtest/TestData.hs
haskell
generated file, do not modify! # LANGUAGE OverloadedStrings, RecordWildCards #
2016 - 02 - 12T16:05:13.383716000000Z module TestData where import Data.Int import Data.Word import Data.Map import Data.Vector (Vector(..)) import LambdaCube.Linear import Data.Text import Data.Aeson hiding (Value,Bool) import Data.Aeson.Types hiding (Value,Bool) import Control.Monad import LambdaCube.IR import ...
1061c0df2ed530f1405b30af3898f7a66f2e193600e5362d50ce60b2bc4e2b3e
dgiot/dgiot
emqx_os_mon_SUITE.erl
%%-------------------------------------------------------------------- Copyright ( c ) 2019 - 2022 EMQ Technologies Co. , Ltd. All Rights Reserved . %% Licensed under the Apache License , Version 2.0 ( the " License " ) ; %% you may not use this file except in compliance with the License. %% You may obtain a copy o...
null
https://raw.githubusercontent.com/dgiot/dgiot/c601555e45f38d02aafc308b18a9e28c543b6f2c/test/emqx_os_mon_SUITE.erl
erlang
-------------------------------------------------------------------- you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express ...
Copyright ( c ) 2019 - 2022 EMQ Technologies Co. , Ltd. All Rights Reserved . Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(emqx_os_mon_SUITE). -compile(export_all). -compile(nowarn_export_all). -include_lib("e...
b3617ff07d74f284dade05b9fb8c007683ea0a7ae53f635c06c9912170c1ad41
rmloveland/scheme48-0.53
pacman.scm
Copyright ( c ) 1993 - 1999 by and . See file COPYING . PACkage - manipulation comMANds (add-sentinel! package-system-sentinel) (define (set-environment-for-commands! p) (set-interaction-environment! p) ;; (set-command-level-env! (command-level) p) ) (define user-environment (user-context-accessor...
null
https://raw.githubusercontent.com/rmloveland/scheme48-0.53/1ae4531fac7150bd2af42d124da9b50dd1b89ec1/scheme/env/pacman.scm
scheme
(set-command-level-env! (command-level) p) unstable? Returns promise of (eval . env) load-package (check-structure s) ,user goes to the user initial environment. Configuration package (should there be ,load-config as well?) ,exec goes to the exec initial environment. -------------------- Main entry point, wi...
Copyright ( c ) 1993 - 1999 by and . See file COPYING . PACkage - manipulation comMANds (add-sentinel! package-system-sentinel) (define (set-environment-for-commands! p) (set-interaction-environment! p) ) (define user-environment (user-context-accessor 'user-environment interaction-environment)) (de...
bc4267c5077d0ca75e7a34ce8a400eb89221edccd0eb18775e4edc0d608cf86e
racket/racket7
submodule.rkt
#lang racket/base (require "../eval/reflect.rkt") (provide extract-requested-submodule) (define (extract-requested-submodule m expected-module) (define (drop-submodules m) (module-compiled-submodules (module-compiled-submodules m #f null) #t null))...
null
https://raw.githubusercontent.com/racket/racket7/5dbb62c6bbec198b4a790f1dc08fef0c45c2e32b/racket/src/expander/run/submodule.rkt
racket
#lang racket/base (require "../eval/reflect.rkt") (provide extract-requested-submodule) (define (extract-requested-submodule m expected-module) (define (drop-submodules m) (module-compiled-submodules (module-compiled-submodules m #f null) #t null))...
260963e10abd8c857e5357e0a0c535e347b67922ea7e157afae1d0f538eef609
pippijn/mlwidgets
ncurses_t.ml
let run () = let open Ncurses in let win = initscr () in let y, x = getmaxyx win in Printf.printf "(%d, %d)\n" x y; mvwaddstr win 0 0 "a"; mvwaddstr win (y - 1) 0 "b"; mvwaddstr win 0 (x - 1) "c"; try mvwaddstr win (y - 1) (x - 1) "d" with Failure "mvwaddstr" -> (); refresh (); Unix.sleep 3; ...
null
https://raw.githubusercontent.com/pippijn/mlwidgets/0255a0c9543ca27cbcf5367051050bd8d17009ce/testsuite/widget/ncurses_t.ml
ocaml
let run () = let open Ncurses in let win = initscr () in let y, x = getmaxyx win in Printf.printf "(%d, %d)\n" x y; mvwaddstr win 0 0 "a"; mvwaddstr win (y - 1) 0 "b"; mvwaddstr win 0 (x - 1) "c"; try mvwaddstr win (y - 1) (x - 1) "d" with Failure "mvwaddstr" -> (); refresh (); Unix.sleep 3; ...
863d99498c4c7f62492e7a74a5f19cd98b526099dcaf274abc190b5d2eff8f39
mnieper/unsyntax
rib.scm
Copyright © ( 2020 ) . This file is part of Unsyntax . ;; Permission is hereby granted, free of charge, to any person ;; obtaining a copy of this software and associated documentation files ( the " Software " ) , to deal in the Software without restriction , ;; including without limitation the rights to use...
null
https://raw.githubusercontent.com/mnieper/unsyntax/144772eeef4a812dd79515b67010d33ad2e7e890/src/unsyntax/rib.scm
scheme
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files including without limitation the rights to use, copy, modify, merge, subject to the following conditions: The above copyright notice and this permission notice (including the next parag...
Copyright © ( 2020 ) . This file is part of Unsyntax . ( the " Software " ) , to deal in the Software without restriction , publish , distribute , sublicense , and/or sell copies of the Software , and to permit persons to whom the Software is furnished to do so , portions of the Software . THE SOF...