_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
c7561748a3e77e9f12702515a538a0a3e6ce7c3e4b5228480da34067ad615764
mattmundell/nightshade
final.lisp
Finalization based on weak pointers . (in-package "EXTENSIONS") (export '(finalize cancel-finalization)) #[ Finalization Finalization provides a "hook" that is triggered when the garbage collector reclaims an object. It is usually used to recover non-Lisp resources that were allocated to implement the finalized ...
null
https://raw.githubusercontent.com/mattmundell/nightshade/d8abd7bd3424b95b70bed599e0cfe033e15299e0/src/code/final.lisp
lisp
We check to make sure object isn't nil because if there are any broken weak pointers, their value will show up as nil. Therefore, they would be deleted from the list, but not finalized. Broken weak pointers shouldn't be left in the list, but why take chances?
Finalization based on weak pointers . (in-package "EXTENSIONS") (export '(finalize cancel-finalization)) #[ Finalization Finalization provides a "hook" that is triggered when the garbage collector reclaims an object. It is usually used to recover non-Lisp resources that were allocated to implement the finalized ...
e8b3f682d877f7305a3256597d996fba7e8f49bc5e071a0fbbebeca85f4427bf
colefichter/lox
color.erl
-module(color). -export([black/1, blackb/1, red/1, redb/1, green/1, greenb/1, blue/1, blueb/1]). -export([yellow/1, yellowb/1, magenta/1, magentab/1, cyan/1, cyanb/1, white/1, whiteb/1]). -export([on_black/1, on_red/1, on_green/1, on_blue/1, on_yellow/1, on_magenta/1, on_cyan/1, on_white/1]). -export([rgb/2, on_rgb/2])...
null
https://raw.githubusercontent.com/colefichter/lox/6a71e5a40d0f2007841bb05242035fd532310809/src/color.erl
erlang
-module(color). -export([black/1, blackb/1, red/1, redb/1, green/1, greenb/1, blue/1, blueb/1]). -export([yellow/1, yellowb/1, magenta/1, magentab/1, cyan/1, cyanb/1, white/1, whiteb/1]). -export([on_black/1, on_red/1, on_green/1, on_blue/1, on_yellow/1, on_magenta/1, on_cyan/1, on_white/1]). -export([rgb/2, on_rgb/2])...
6a100b588dffbd430b13cc168e04cfe3bb2b5e15f6318ef4c0e7bcb8557d189e
xtdb/core2
pgwire.clj
(ns core2.pgwire "Defines a postgres wire protocol (pgwire) server for xtdb. Start with (serve node) Stop with (.close server) or (stop-all)" (:require [clojure.data.json :as json] [clojure.set :as set] [clojure.string :as str] [clojure.tools.logging :as log] [co...
null
https://raw.githubusercontent.com/xtdb/core2/3adeb391ca4dd73a3f79faba8024289376597d23/pgwire-server/src/main/clojure/core2/pgwire.clj
clojure
references -flow.html -message-formats.html unchecked math is unnecessary (and perhaps dangerous) for this ns Server Represents a single postgres server on a particular port the server does not own the lifecycle of its associated node Server lifecycle new -> starting -> running -> draining -> cleaning-u...
(ns core2.pgwire "Defines a postgres wire protocol (pgwire) server for xtdb. Start with (serve node) Stop with (.close server) or (stop-all)" (:require [clojure.data.json :as json] [clojure.set :as set] [clojure.string :as str] [clojure.tools.logging :as log] [co...
6874bb19269c91399964fddd0030a0528bb3dc11b8500cf190843d4053a5658f
isovector/dynahaskell
Stuff.hs
{-# LANGUAGE ConstraintKinds #-} module UI.Stuff where import Brick hiding (loc) import qualified Brick.Main as M import qualified Brick.Types as T import Brick.Widgets.Edit import Control.Lens hiding (holes) import Data.Bifunctor import Data.Foldable import ...
null
https://raw.githubusercontent.com/isovector/dynahaskell/50819888fa118e123f45d98d3d135e611f4b0c35/src/UI/Stuff.hs
haskell
# LANGUAGE ConstraintKinds # >) :: a -> b -> (a, b) >) = (,) >
module UI.Stuff where import Brick hiding (loc) import qualified Brick.Main as M import qualified Brick.Types as T import Brick.Widgets.Edit import Control.Lens hiding (holes) import Data.Bifunctor import Data.Foldable import Data.Maybe import GHC ...
53cc5e11445b674e2a14aba1206d487466e4832d7fa86e50b7f6d13ac651e569
uw-unsat/serval
load-store-register.rkt
#lang rosette (require "common.rkt") (provide strb strh str32 str64 ldrb ldrh ldr32 ldr64) (define (decode size Rm option S Rn Rt) (define scale (bitvector->natural size)) (when (bveq (bit 1 option) (bv #b0 1)) (undefined)) (define extend_type (decode-reg-extend option)) (define shift (if (bveq ...
null
https://raw.githubusercontent.com/uw-unsat/serval/be11ecccf03f81b8bd0557acf8385a6a5d4f51ed/serval/arm64/interp/load-store-register.rkt
racket
#lang rosette (require "common.rkt") (provide strb strh str32 str64 ldrb ldrh ldr32 ldr64) (define (decode size Rm option S Rn Rt) (define scale (bitvector->natural size)) (when (bveq (bit 1 option) (bv #b0 1)) (undefined)) (define extend_type (decode-reg-extend option)) (define shift (if (bveq ...
38ce204a67fa7a9840a775f570485501a099e863383f66206c1e3a9b10e39270
basho/riak_kv
riak_kv_overflow_queue.erl
%% ------------------------------------------------------------------- %% %% riak_kv_overflow_queue: A version of queue which overflows to disk %% 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 obtai...
null
https://raw.githubusercontent.com/basho/riak_kv/0a5f60faeb11a59ce15acf249c9464f58853c609/src/riak_kv_overflow_queue.erl
erlang
------------------------------------------------------------------- riak_kv_overflow_queue: A version of queue which overflows to disk 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 impl...
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 -module(riak_kv_overflow_queue). -ifdef(TEST). -include_lib("eunit/include/e...
5dfbd176ac5593aea03d68a505bf06f6977c6be50c03cdee58555056cc5651e8
richhickey/clojure-contrib
test_repl_utils.clj
(ns clojure.contrib.test-repl-utils (:use clojure.test clojure.contrib.repl-utils)) (deftest test-apropos (testing "with a regular expression" (is (= '[defmacro] (apropos #"^defmacro$"))) (is (some '#{defmacro} (apropos #"def.acr."))) (is (= [] (apropos #"nothing-has-this-name")))) (testing "wit...
null
https://raw.githubusercontent.com/richhickey/clojure-contrib/40b960bba41ba02811ef0e2c632d721eb199649f/src/test/clojure/clojure/contrib/test_repl_utils.clj
clojure
(ns clojure.contrib.test-repl-utils (:use clojure.test clojure.contrib.repl-utils)) (deftest test-apropos (testing "with a regular expression" (is (= '[defmacro] (apropos #"^defmacro$"))) (is (some '#{defmacro} (apropos #"def.acr."))) (is (= [] (apropos #"nothing-has-this-name")))) (testing "wit...
7cab5cd50c1f152cd9c15a89b7e09b51de5ad945fb4b45f81d343b26fc608acd
skanev/playground
15-tests.scm
(require rackunit rackunit/text-ui) (require eopl) (load-relative "../15.scm") (define eopl-1.15-tests (test-suite "Tests for EOPL exercise 1.15" (check-equal? (duple 2 3) '(3 3)) (check-equal? (duple 4 '(ha ha)) '((ha ha) (ha ha) (ha ha) (ha ha))) (check-equal? (...
null
https://raw.githubusercontent.com/skanev/playground/d88e53a7f277b35041c2f709771a0b96f993b310/scheme/eopl/01/tests/15-tests.scm
scheme
(require rackunit rackunit/text-ui) (require eopl) (load-relative "../15.scm") (define eopl-1.15-tests (test-suite "Tests for EOPL exercise 1.15" (check-equal? (duple 2 3) '(3 3)) (check-equal? (duple 4 '(ha ha)) '((ha ha) (ha ha) (ha ha) (ha ha))) (check-equal? (...
2907184dc64519d62c37137cf3f5087498c3c0cae45b41e94e22daab960f5a61
ocaml-multicore/ocaml-tsan
arch.mli
# 2 "asmcomp/arm64/arch.mli" (**************************************************************************) (* *) (* OCaml *) (* ...
null
https://raw.githubusercontent.com/ocaml-multicore/ocaml-tsan/f54002470cc6ab780963cc81b11a85a820a40819/asmcomp/arm64/arch.mli
ocaml
************************************************************************ OCaml ...
# 2 "asmcomp/arm64/arch.mli" , projet Gallium , INRIA Rocquencourt , University of Siegen Copyright 2013 Institut National de Recherche en Informatique et Copyright 2012 . the GNU Lesser General Pub...
1a6225db922bfe47bd84d85369fd7077f41a22b3c1f544119b70334464f26ad1
janestreet/ppx_expect
matcher.ml
open Base open Expect_test_common let bprintf = Printf.bprintf module Saved_output = struct type t = | One of string | Many_distinct of string list let of_nonempty_list_exn outputs = let _, rev_deduped_preserving_order = List.fold outputs ~init:(Set.empty (module String), []) ...
null
https://raw.githubusercontent.com/janestreet/ppx_expect/0b69e7469f38c91979f3a78aa894b0a1768cdaaf/matcher/matcher.ml
ocaml
In the order of the file If we need to remove an [%%expect.uncaught_exn] node, start by adjusting the end position of the test. Unfortunately, the OCaml parser doesn't give us the location of the whole extension point, so we have to find the square brackets ourselves :( handled above
open Base open Expect_test_common let bprintf = Printf.bprintf module Saved_output = struct type t = | One of string | Many_distinct of string list let of_nonempty_list_exn outputs = let _, rev_deduped_preserving_order = List.fold outputs ~init:(Set.empty (module String), []) ...
8403c9b748cf6e2a676b66ce1a945f50676fc190b84124bc8bf6fe7287e53f1f
zeromq/chumak
chumak_router.erl
This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. @doc ZeroMQ Router Pattern for Erlang %% This pattern implement Router especification %% from: :28/REQREP#toc6 -module(chumak_router). -be...
null
https://raw.githubusercontent.com/zeromq/chumak/1fe17f2b9d2a55a7b0e7d1911e9b207727758daf/src/chumak_router.erl
erlang
from: :28/REQREP#toc6 loadbalancers based on identity This function will never called, because use incoming_queue property if there is a waiter reply directly
This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. @doc ZeroMQ Router Pattern for Erlang This pattern implement Router especification -module(chumak_router). -behaviour(chumak_pattern). -in...
b09401084b2e1b43a0da9d4779eb6959bd50c499c58e798661995ac4470c1495
clash-lang/clash-compiler
SymbiYosys.hs
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE TemplateHaskellQuotes #-} module SymbiYosys where import Clash.Class.Counter import Clash.Prelude import Clash.Verification (RenderAs (YosysFormal), assert, checkI, ...
null
https://raw.githubusercontent.com/clash-lang/clash-compiler/be7558062e2832c446b9dcf61be3852872b646bb/tests/shouldwork/Verification/SymbiYosys.hs
haskell
# LANGUAGE OverloadedStrings # # LANGUAGE TemplateHaskellQuotes #
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # module SymbiYosys where import Clash.Class.Counter import Clash.Prelude import Clash.Verification (RenderAs (YosysFormal), assert, checkI, cover, eventually) topEntity :: Clock System -> Reset Sy...
41660c1bb335d34148b08d2208e4e4b2aa89e9dd640b21469c4802bbc12f41e2
jrm-code-project/LISP-Machine
fs.lisp
-*- Mode : Lisp ; Package : User ; Base : 8 -*- (make-system 'imicro :noconfirm) (defpackage "MOBY-FILE-SYSTEM" :nicknames ("MFS" "MOBY-FILE") :size 1000.) (DEFSYSTEM MOBY-FILE (:NAME "Moby-File") (:NICKNAMES "MOBY-FILE-SYSTEM") ;this must come before short-name to win! (:SHORT-NAME "MFS") (:PATH...
null
https://raw.githubusercontent.com/jrm-code-project/LISP-Machine/0a448d27f40761fafabe5775ffc550637be537b2/lambda/mfile/fs.lisp
lisp
Package : User ; Base : 8 -*- this must come before short-name to win! (:NAME "FILE-Server") (:PATHNAME-DEFAULT "SYS: FILE;") (:PATCHABLE NIL "Server") (:NOT-IN-DISK-LABEL) (:PACKAGE FILE-SYSTEM) (:COMPILE-LOAD ("SERVER"))) (LOOP FOR SYSTEM IN SYSTEMS DO (SETQ SYSTEM (SI:FIND-SYSTEM-NAMED SYSTEM))...
(make-system 'imicro :noconfirm) (defpackage "MOBY-FILE-SYSTEM" :nicknames ("MFS" "MOBY-FILE") :size 1000.) (DEFSYSTEM MOBY-FILE (:NAME "Moby-File") (:SHORT-NAME "MFS") (:PATHNAME-DEFAULT "DJ: MFILE;") (: PATCHABLE NIL " MFS " ) (:NOT-IN-DISK-LABEL) (: PACKAGE MOBY - FILE - SYSTEM ) (:MODULE DEFS...
664ae051e5927ab81c21acd455e27ac1d19fc3581d70a4ee180006e61e386138
wizardpb/functional-vaadin
core_test.clj
;; Copyright 2016 Prajna Inc. All Rights Reserved . ;; ;; This work is licensed under the Eclipse Public License v1.0 - -v10.html ;; Distrubition and use must be done under the terms of this license ;; (ns functional-vaadin.core-test (:use [clojure.test] [functional-vaadin.thread-vars] [functional-...
null
https://raw.githubusercontent.com/wizardpb/functional-vaadin/eccd121b1a4c28ec73ad452fa3d1ce3c6e78d401/test/functional_vaadin/core_test.clj
clojure
This work is licensed under the Eclipse Public License v1.0 - -v10.html Distrubition and use must be done under the terms of this license Auto set of caption (table-column "Col1") (table-column "Col3")
Copyright 2016 Prajna Inc. All Rights Reserved . (ns functional-vaadin.core-test (:use [clojure.test] [functional-vaadin.thread-vars] [functional-vaadin.core] [functional-vaadin.build-support] [functional-vaadin.data-binding] [functional-vaadin.utils] ) (:import (c...
b1804f32b7c5147aa103a5c42cfc30b9291755509a84b331f537565b3a91bc97
tsurucapital/euphoria
Event.hs
{-# LANGUAGE BangPatterns #-} # LANGUAGE CPP # {-# LANGUAGE DeriveDataTypeable #-} # LANGUAGE DeriveFunctor # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE MultiParamTypeClasses # # OPTIONS_GHC -Wall # #if __GLASGOW_HASKELL__ <= 706 # LANGUAGE DoRec # #else # LANGUAGE RecursiveDo # #end...
null
https://raw.githubusercontent.com/tsurucapital/euphoria/15ddb49ddc79d62970a0163fe8d77789254db202/FRP/Euphoria/Event.hs
haskell
# LANGUAGE BangPatterns # # LANGUAGE DeriveDataTypeable # The API is largely inspired by reactive-banana. * Events ** Creation ** Sampling ** State accumulation | With these functions, any input event occurrence will affect the output immediately, without any delays. ** Filtering and other list-like operations ...
# LANGUAGE CPP # # LANGUAGE DeriveFunctor # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE MultiParamTypeClasses # # OPTIONS_GHC -Wall # #if __GLASGOW_HASKELL__ <= 706 # LANGUAGE DoRec # #else # LANGUAGE RecursiveDo # #endif | Event / discrete layer constructed on top of Elerea . modu...
7d2b29b6f46ba9dfcf8e9f40a92d067646fc2ec3eaeb3aa6d22ece6e0d8e3586
andgate/type-theory-compiler
Namecheck.hs
# LANGUAGE ConstraintKinds , LambdaCase , ViewPatterns , FlexibleContexts , , OverloadedStrings # , LambdaCase , ViewPatterns , FlexibleContexts , GeneralizedNewtypeDeriving , OverloadedS...
null
https://raw.githubusercontent.com/andgate/type-theory-compiler/a404f085d19a19b16ae8c26616707dc46707ea10/stlc/src/Language/STLC/Namecheck.hs
haskell
- Namecheck Environment - Namecheck Errors Namecheck requires some global name sets and a module to check on lol check member names you doofus
# LANGUAGE ConstraintKinds , LambdaCase , ViewPatterns , FlexibleContexts , , OverloadedStrings # , LambdaCase , ViewPatterns , FlexibleContexts , GeneralizedNewtypeDeriving , OverloadedS...
02816eac1def48c7db4d25c121319bfa9a72ec3ac9caaf220f611ea1da48ac7c
softlab-ntua/bencherl
dialyzer_succ_typings.erl
-*- erlang - indent - level : 2 -*- %%----------------------------------------------------------------------- %% %CopyrightBegin% %% Copyright Ericsson AB 2006 - 2012 . All Rights Reserved . %% The contents of this file are subject to the Erlang Public License , Version 1.1 , ( the " License " ) ; you may not u...
null
https://raw.githubusercontent.com/softlab-ntua/bencherl/317bdbf348def0b2f9ed32cb6621e21083b7e0ca/app/dialyzer/src/dialyzer_succ_typings.erl
erlang
----------------------------------------------------------------------- %CopyrightBegin% compliance with the License. You should have received a copy of the Erlang Public License along with this software. If not, it can be retrieved online at /. basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. Se...
-*- erlang - indent - level : 2 -*- Copyright Ericsson AB 2006 - 2012 . All Rights Reserved . The contents of this file are subject to the Erlang Public License , Version 1.1 , ( the " License " ) ; you may not use this file except in Software distributed under the License is distributed on an " AS IS " Au...
78ec91ccd57e9fbe049be03e9872170434bda4998b88b459dbe37fae6ff76490
lolepezy/rpki-prover
ParseSpec.hs
# LANGUAGE LambdaCase # {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE QuasiQuotes #-} {-# LANGUAGE RecordWildCards #-} module RPKI.RRDP.ParseSpec where import Data.ByteString.Short as BSS import RPKI.Domain import RPKI.RRDP.Parse import RP...
null
https://raw.githubusercontent.com/lolepezy/rpki-prover/e1d03b060f063efdb8bd9063d9d59f8f61be1b20/test/src/RPKI/RRDP/ParseSpec.hs
haskell
# LANGUAGE OverloadedStrings # # LANGUAGE QuasiQuotes # # LANGUAGE RecordWildCards #
# LANGUAGE LambdaCase # module RPKI.RRDP.ParseSpec where import Data.ByteString.Short as BSS import RPKI.Domain import RPKI.RRDP.Parse import RPKI.RRDP.Types import Test.QuickCheck.Arbitrary.Generic import Test.QuickCheck.Monadic impo...
04f5423cefdec4d96c42f48bc2e65f59be23daece6495db7361b816e23f6f845
WormBase/wormbase_rest
expression.clj
(ns rest-api.classes.gene.widgets.expression (:require [rest-api.classes.generic-fields :as generic] [rest-api.classes.gene.expression :as expression])) (def widget {:name generic/name-field :expressed_in expression/expressed-in :expressed_during expression/expressed-during :subcellular_localization...
null
https://raw.githubusercontent.com/WormBase/wormbase_rest/e51026f35b87d96260b62ddb5458a81ee911bf3a/src/rest_api/classes/gene/widgets/expression.clj
clojure
(ns rest-api.classes.gene.widgets.expression (:require [rest-api.classes.generic-fields :as generic] [rest-api.classes.gene.expression :as expression])) (def widget {:name generic/name-field :expressed_in expression/expressed-in :expressed_during expression/expressed-during :subcellular_localization...
32199b471cda9be246dbd66ba37181296f0344ad55c2634a7cb08f97af7f70df
kmi/irs
json-serialisation.lisp
(in-package #:ocml) (in-ontology json) ;;Here we define the functionality of converting from a JSON string to an OCML - ised representation of that string , and then back again . ;{{{ TO-JSON (defun to-json-toplevel (ocml) Returns a JSON string from the OCML - ised JSON representation (json:bind-custom-vars ...
null
https://raw.githubusercontent.com/kmi/irs/e1b8d696f61c6b6878c0e92d993ed549fee6e7dd/ontologies/domains/json/json-serialisation.lisp
lisp
Here we define the functionality of converting from a JSON string to {{{ TO-JSON Good idea to treat JSON arrays as Lisp vectors representation }}} {{{ FROM-JSON Good idea to treat JSON arrays as Lisp vectors since string is a type of vector since NIL (which is used for 'false') is also of type list into "KEY-STRING"....
(in-package #:ocml) (in-ontology json) an OCML - ised representation of that string , and then back again . (defun to-json-toplevel (ocml) Returns a JSON string from the OCML - ised JSON representation (json:bind-custom-vars (:array-type 'VECTOR) (json:encode-json-to-string (to-json ocml)))) (defun t...
f9c70d86a3d3c9b41b95e8e56f313b86c98532ca94febf9b33e86d9d0e8e791a
fumieval/mason
json-weigh.hs
module Main where import qualified Fast as F import qualified Bstr as B import qualified Mason as M import Control.Concurrent import Control.DeepSeq import Data.Aeson (decode', encode) import qualified Data.ByteString.Lazy as L import System.IO import Weigh main :: IO () main = do Just json <- decode' <$> L.readFile...
null
https://raw.githubusercontent.com/fumieval/mason/09e3d6aab64ded54380270be2af3db31b432bcc1/benchmarks/aeson/json-weigh.hs
haskell
module Main where import qualified Fast as F import qualified Bstr as B import qualified Mason as M import Control.Concurrent import Control.DeepSeq import Data.Aeson (decode', encode) import qualified Data.ByteString.Lazy as L import System.IO import Weigh main :: IO () main = do Just json <- decode' <$> L.readFile...
9bafe63f258bc7879456efa0176391cd2fb1bb96d0f7172542ab70ff38a13f7f
NorfairKing/smos
Main.hs
module Main where import Smos.Notify main :: IO () main = smosNotify
null
https://raw.githubusercontent.com/NorfairKing/smos/f72b26c2e66ab4f3ec879a1bedc6c0e8eeb18a01/smos-notify/app/Main.hs
haskell
module Main where import Smos.Notify main :: IO () main = smosNotify
744bd9607516767eaebd50485028ebe7c02a935b45d6c3f7dbb57701d81edb7a
lambdamikel/VISCO
LoadMe.lisp
;;; -*- Mode: LISP; Syntax: Common-Lisp; Package: CL-USER -*- (in-package :cl-user) (let ((current-dir (directory-namestring (truename *loading-file-source-file*)))) (setf (logical-pathname-translations "defsystem") (list (list "**;*.*.*" (full-pathname ...
null
https://raw.githubusercontent.com/lambdamikel/VISCO/836d325b5c6037517470835c635b3063446d3d8a/src/LoadMe.lisp
lisp
-*- Mode: LISP; Syntax: Common-Lisp; Package: CL-USER -*-
(in-package :cl-user) (let ((current-dir (directory-namestring (truename *loading-file-source-file*)))) (setf (logical-pathname-translations "defsystem") (list (list "**;*.*.*" (full-pathname (concatenate 'string ...
7e40c81cfe56a73e51cfabd5ed3d7d88526578f8d4f6c5b4ace0900169e7c75f
ariesteam/aries
utils.clj
Copyright 2010 ;;; ;;; This file is part of clj-misc. ;;; ;;; clj-misc is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3 of the License , ;;; or (at your option) any later version. ;;; ;;; ...
null
https://raw.githubusercontent.com/ariesteam/aries/b3fafd4640f4e7950fff3791bc4ea4c06ee4dcdf/plugins/org.integratedmodelling.aries.core/bindings/clojure/clj_misc/utils.clj
clojure
This file is part of clj-misc. clj-misc is free software: you can redistribute it and/or modify or (at your option) any later version. clj-misc is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ...
Copyright 2010 it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3 of the License , You should have received a copy of the GNU General Public License (ns clj-misc.utils (:import (java.util HashMap))) (def p partial) (def & comp) (defn thrus...
8eef9edda51df5f1fc2f1aecf333cb9736d11745176eba3a3864d2c9f4c109d9
gsdlab/clafer
ResolverType.hs
# LANGUAGE NamedFieldPuns , FlexibleInstances , FlexibleContexts , Copyright ( C ) 2012 - 2017 , , < > 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 restricti...
null
https://raw.githubusercontent.com/gsdlab/clafer/a30a645ae1e4fc793851e53446d220924038873a/src/Language/Clafer/Intermediate/ResolverType.hs
haskell
What "this" refers to The next path is a child of curPath (or Nothing) Extra declarations | Type inference and checking ^ Phase one: only process references Phase one: only process references Case 1: Use the sident all not top-level identifiers must be in a path Case 1: Use the sident arg1s' <- resolveTPExp a...
# LANGUAGE NamedFieldPuns , FlexibleInstances , FlexibleContexts , Copyright ( C ) 2012 - 2017 , , < > 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 restricti...
39e0f85c064d2a13028438151c0ad1d4494a4136d5ee48b7803c241bcf991374
Hans-Halverson/myte
asm_utils.ml
let any_dump_asm () = Opts.dump_virtual_asm () || Opts.dump_asm () || Opts.dump_full_asm ()
null
https://raw.githubusercontent.com/Hans-Halverson/myte/c293d1b619e803f9b5a5d79cf13a6a771bd16940/src/asm/asm_utils.ml
ocaml
let any_dump_asm () = Opts.dump_virtual_asm () || Opts.dump_asm () || Opts.dump_full_asm ()
44770b916024e4aec2a5c975624a8b1257603073f4bf8b9a02801a69d2503f3d
basho/machi
machi_flu1_client.erl
%% ------------------------------------------------------------------- %% Copyright ( c ) 2007 - 2015 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...
null
https://raw.githubusercontent.com/basho/machi/e87bd59a9777d805b00f9e9981467eb28e28390c/src/machi_flu1_client.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 permissio...
Copyright ( c ) 2007 - 2015 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 ...
e3d89bd71ad2982d57c63dc472392f5cad5860d7a4c4290aa0f817be2ab8cb73
Palmik/wai-sockjs
Application.hs
# LANGUAGE FlexibleContexts # module Network.Sock.Types.Application ( Application(..) , ApplicationSettings(..) ) where ------------------------------------------------------------------------------ import qualified Data.Conduit as C (Source, Sink) import qualified Data.ByteString.Lazy as BL (ByteString) im...
null
https://raw.githubusercontent.com/Palmik/wai-sockjs/d1037cb00450a362b7e593a76d6257d06ecb2405/src/Network/Sock/Types/Application.hs
haskell
---------------------------------------------------------------------------- ---------------------------------------------------------------------------- ----------------------------------------------------------------------------
# LANGUAGE FlexibleContexts # module Network.Sock.Types.Application ( Application(..) , ApplicationSettings(..) ) where import qualified Data.Conduit as C (Source, Sink) import qualified Data.ByteString.Lazy as BL (ByteString) import qualified Data.Text as TS (Text) import Network.Sock....
ea56b5166ec3b3b8f5f7665d1de3166bae47eac284dda83e16e98fea3af9d8b4
tsoding/kgbotka
Asciify.hs
{-# LANGUAGE OverloadedStrings #-} # LANGUAGE QuasiQuotes # module KGBotka.Asciify ( asciifyUrl ) where import Control.Applicative import Control.Monad.Trans.Class import Control.Monad.Trans.Except import Control.Monad.Trans.Maybe import qualified Data.ByteString.Lazy as BS import Data.Maybe import qualified Data...
null
https://raw.githubusercontent.com/tsoding/kgbotka/67278a93611b0abe4e07df7967559884263147aa/src/KGBotka/Asciify.hs
haskell
# LANGUAGE OverloadedStrings # NOTE: `Nothing` from `fromCache` indicates the cache miss. We set the error to empty string because `ExceptT` expects exceptions to error of `fromCache` to empty string we don't disturb the error of `fromUrl` and `cacheImage`
# LANGUAGE QuasiQuotes # module KGBotka.Asciify ( asciifyUrl ) where import Control.Applicative import Control.Monad.Trans.Class import Control.Monad.Trans.Except import Control.Monad.Trans.Maybe import qualified Data.ByteString.Lazy as BS import Data.Maybe import qualified Data.Text as T import Database.SQLite.S...
ef0f6d5f993047bd401df477f79af224f92ed4b9b677967f0bbb42cc8aa61528
THISISDINOSAUR/Anatomy
expander.rkt
#lang br/quicklang (provide (matching-identifiers-out #rx"^a-" (all-defined-out)) (all-from-out "a-functions.rkt" "a-maths.rkt" "a-definitions.rkt" "a-render.rkt")) (require "../structs/point.rkt" "../structs/polygon-tree.rkt" ...
null
https://raw.githubusercontent.com/THISISDINOSAUR/Anatomy/883aa140c41cd375575a2944bda79608c660935b/expander/expander.rkt
racket
#lang br/quicklang (provide (matching-identifiers-out #rx"^a-" (all-defined-out)) (all-from-out "a-functions.rkt" "a-maths.rkt" "a-definitions.rkt" "a-render.rkt")) (require "../structs/point.rkt" "../structs/polygon-tree.rkt" ...
e75c7387144859c5ac2ec45c8e5bb2926a39b7c23da4fedfe2c074c0089e67e0
mhuebert/re-view
test_helpers.clj
(ns re-db.test-helpers) (defmacro throws [& body] (let [message (when (string? (last body)) (last body)) body (cond-> body message (drop-last))] (cond-> `(~'cljs.test/is (~'thrown? ~'js/Error ~@body)) message (concat (list message)))))
null
https://raw.githubusercontent.com/mhuebert/re-view/ba38cd09b78b3c6db6a2983f3e2cf1bd6294564f/re_db/test/re_db/test_helpers.clj
clojure
(ns re-db.test-helpers) (defmacro throws [& body] (let [message (when (string? (last body)) (last body)) body (cond-> body message (drop-last))] (cond-> `(~'cljs.test/is (~'thrown? ~'js/Error ~@body)) message (concat (list message)))))
ed3ebfc60d268cd626adce72ffbe11355b7abc4a993b798504ebbba34c7dde8c
emil0r/reverie
auth.clj
(ns reverie.test.auth (:require [com.stuartsierra.component :as component] [noir.session :as session] [noir.cookies :as cookies] [reverie.auth :as auth :refer [with-access with-authorize]] [reverie.database :as db] [reverie.nsloader] [reverie.tes...
null
https://raw.githubusercontent.com/emil0r/reverie/a29c223b7326e6d5a5e0874d33c37ff2fa0dfd4d/reverie-test/test/reverie/test/auth.clj
clojure
(ns reverie.test.auth (:require [com.stuartsierra.component :as component] [noir.session :as session] [noir.cookies :as cookies] [reverie.auth :as auth :refer [with-access with-authorize]] [reverie.database :as db] [reverie.nsloader] [reverie.tes...
87e97fce9477e87504e2768bf030a52ba2f0a4b1ffa4e538ba36d49b89c42350
interactive-ssr/issr-server
websocket.lisp
(in-package #:issr.server) (defvar *show-errors-to-client* nil "When non-nil, errors after the initial connection can be seen in console.error.") (defun make-ws-message (host port show-errors redis-host redis-port redis-pass) (lambda (socket message) (if (str:starts-with-p "id:" message) ;; first conn...
null
https://raw.githubusercontent.com/interactive-ssr/issr-server/e828e3ea6c6a711f27ceee5a80d3646a89473768/src/websocket.lisp
lisp
first connection giving parameters to update page wait for disconnect hook to be done
(in-package #:issr.server) (defvar *show-errors-to-client* nil "When non-nil, errors after the initial connection can be seen in console.error.") (defun make-ws-message (host port show-errors redis-host redis-port redis-pass) (lambda (socket message) (if (str:starts-with-p "id:" message) (let* ((id (s...
e1c78304fd0308275f6bba1a259093d028cc6897fa3a3f90f07dc158ad133116
PacktPublishing/Haskell-High-Performance-Programming
ivar-testing.hs
import Control.Monad.Par f :: (NFData a, NFData b) => a -> b -> (a, b) f c1 c2 = runPar $ do i1 <- new i2 <- new fork $ put i1 c1 fork $ put i2 c2 r1 <- get i1 r2 <- get i2 return (r1, r2) main = print $ runPar $ do iv <- new put iv (0 :: Int) put iv 1 ...
null
https://raw.githubusercontent.com/PacktPublishing/Haskell-High-Performance-Programming/2b1bfdb8102129be41e8d79c7e9caf12100c5556/Chapter05/ivar-testing.hs
haskell
import Control.Monad.Par f :: (NFData a, NFData b) => a -> b -> (a, b) f c1 c2 = runPar $ do i1 <- new i2 <- new fork $ put i1 c1 fork $ put i2 c2 r1 <- get i1 r2 <- get i2 return (r1, r2) main = print $ runPar $ do iv <- new put iv (0 :: Int) put iv 1 ...
fb546739434d3cbabc22c0dc4bf7627ed364a9b885249ab70e8485b4be2ff76a
brendanhay/amazonka
Internal.hs
-- | -- Module : Test.Amazonka.WorkMail.Internal Copyright : ( c ) 2013 - 2023 License : Mozilla Public License , v. 2.0 . Maintainer : < brendan.g.hay+ > -- Stability : auto-generated Portability : non - portable ( GHC extensions ) module Test.Amazonka.WorkMail.Internal where
null
https://raw.githubusercontent.com/brendanhay/amazonka/09f52b75d2cfdff221b439280d3279d22690d6a6/lib/services/amazonka-workmail/test/Test/Amazonka/WorkMail/Internal.hs
haskell
| Module : Test.Amazonka.WorkMail.Internal Stability : auto-generated
Copyright : ( c ) 2013 - 2023 License : Mozilla Public License , v. 2.0 . Maintainer : < brendan.g.hay+ > Portability : non - portable ( GHC extensions ) module Test.Amazonka.WorkMail.Internal where
ced3b3c8c02f21a138ce6b3cf1f5cc136b0565688143e44ce60c05c94d65349b
cojna/iota
BellmanFord.hs
module Data.Graph.BellmanFord where import Control.Monad import qualified Data.Vector.Unboxed as U import qualified Data.Vector.Unboxed.Mutable as UM import My.Prelude (rep) type Vertex = Int | Bellman - Ford O(VE ) dist[n ] = = is unreachable dist[v ] = = v in negative cycle dist[n] == maxBound ...
null
https://raw.githubusercontent.com/cojna/iota/6d2ad5b71b1b50bca9136d6ed84f80a0b7713d7c/src/Data/Graph/BellmanFord.hs
haskell
module Data.Graph.BellmanFord where import Control.Monad import qualified Data.Vector.Unboxed as U import qualified Data.Vector.Unboxed.Mutable as UM import My.Prelude (rep) type Vertex = Int | Bellman - Ford O(VE ) dist[n ] = = is unreachable dist[v ] = = v in negative cycle dist[n] == maxBound ...
45605babbf2b6486f9c2ddbb1490c3df7bfe563e24c0ae2366fafd69bffca29b
PJK/haskell-pattern-matching
Prime.hs
f :: Int -> Int f x | 5 > 1 && isPrime 2 = 1
null
https://raw.githubusercontent.com/PJK/haskell-pattern-matching/7ef4a45731beba92ee01614ae563df65be36e8ba/data/exact/Prime.hs
haskell
f :: Int -> Int f x | 5 > 1 && isPrime 2 = 1
808e67ab88de5f1b43ad19032aaf60ec93f2909300e746ef1e431584b9fb1f08
viebel/klipse-app
common.cljs
(ns klipse.ui.editors.common (:require-macros [gadjett.core :refer [dbg]]) (:require [klipse.ui.editors.editor :as editor] [klipse.utils :refer [url-parameters create-url-with-input debounce]])) (defn display-url-with-input [base-url value] (doto (create-url-with-input base-url value) print js/...
null
https://raw.githubusercontent.com/viebel/klipse-app/46809aaf4dd9bc89aae3bd81110125f81cbd11a4/src/klipse/ui/editors/common.cljs
clojure
(ns klipse.ui.editors.common (:require-macros [gadjett.core :refer [dbg]]) (:require [klipse.ui.editors.editor :as editor] [klipse.utils :refer [url-parameters create-url-with-input debounce]])) (defn display-url-with-input [base-url value] (doto (create-url-with-input base-url value) print js/...
4f07fddc8b97820d022bcb84c0ad8ed1caecd8877af85b01ada9aca9c97f73f3
jiangpengnju/htdp2e
ex12.rkt
The first three lines of this file were inserted by . They record metadata ;; about the language level of this file in a form that our tools can easily process. #reader(lib "htdp-advanced-reader.ss" "lang")((modname ex12) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #t #...
null
https://raw.githubusercontent.com/jiangpengnju/htdp2e/d41555519fbb378330f75c88141f72b00a9ab1d3/fixed-size-data/arithmetic/ex12.rkt
racket
about the language level of this file in a form that our tools can easily process. Now relax, eat, sleep, and then tackle the next chapter. OK~...
The first three lines of this file were inserted by . They record metadata #reader(lib "htdp-advanced-reader.ss" "lang")((modname ex12) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #t #t none #f () #f)))
ee5fc0282c046afc492d3a6dc27aebf96952bd66f6aa64b69f2800ec153ed8e7
t-sin/inquisitor
external-format.lisp
(in-package :cl-user) (defpackage :inquisitor.external-format (:use :cl) (:export :%make-external-format :make-external-format) (:import-from :inquisitor.names :dependent-name)) (in-package :inquisitor.external-format) (defun make-external-format (enc eol &rest args &key (type :impl) &...
null
https://raw.githubusercontent.com/t-sin/inquisitor/423fa9bdd4a68a6ae517b18406d81491409ccae8/src/external-format.lisp
lisp
(in-package :cl-user) (defpackage :inquisitor.external-format (:use :cl) (:export :%make-external-format :make-external-format) (:import-from :inquisitor.names :dependent-name)) (in-package :inquisitor.external-format) (defun make-external-format (enc eol &rest args &key (type :impl) &...
c0a058df03b1f89ece6408bc8b7af79ff780302d26aba1fd67e20fc40462decc
ethercrow/opentelemetry-haskell
Metrics_Internal.hs
# LANGUAGE DataKinds # {-# LANGUAGE GADTs #-} # LANGUAGE KindSignatures # # LANGUAGE StandaloneDeriving # -- | -- This is an internal module . The public interface is re - exported by " OpenTelemetry . Eventlog " -- -- This module implements the instruments of the metrics portion of the OpenTelemetry API . It is r...
null
https://raw.githubusercontent.com/ethercrow/opentelemetry-haskell/33cb21735da555d4ef9c144a26f26bd1ca4a160a/opentelemetry/src/OpenTelemetry/Metrics_Internal.hs
haskell
# LANGUAGE GADTs # | This module implements the instruments of the metrics portion of the used by importing that. The way to use the 'Instrument' type is throught the 'add', 'record' or 'observe' functions (depending on the instrument type) which capture metrics on a given instrument. Usage: @ aCounter :...
# LANGUAGE DataKinds # # LANGUAGE KindSignatures # # LANGUAGE StandaloneDeriving # This is an internal module . The public interface is re - exported by " OpenTelemetry . Eventlog " OpenTelemetry API . It is reexported by " OpenTelemetry . Eventlog " and should be import OpenTelemetry . Eventlog aCounter = Cou...
05b206415df9037ff1aa56b5e751f9c992a0baf5524ae89be0d38a088d79c1bd
qitab/ace.core
sequence.lisp
Copyright 2020 Google LLC ;;; Use of this source code is governed by an MIT - style ;;; license that can be found in the LICENSE file or at ;;; . Utilities related to general sequences . ;;; (ace.core:defpackage* #:ace.core.sequence (:use #:common-lisp) (:export ;; TODO(czak): Those may be interesting wh...
null
https://raw.githubusercontent.com/qitab/ace.core/e6eb21ff67b0c5eaec21c9b543b6dce18d7c8e6d/sequence.lisp
lisp
license that can be found in the LICENSE file or at . TODO(czak): Those may be interesting when defined for generic sequences. #:length= #:partition #:nconcf
Copyright 2020 Google LLC Use of this source code is governed by an MIT - style Utilities related to general sequences . (ace.core:defpackage* #:ace.core.sequence (:use #:common-lisp) (:export # : # : appendf # : # : # : #:removef #:removef-if #:removef-if-not #:deletef #:delete...
0ef53cb91ec0b6e1a5db9d360433dd50e87421809708e7d7dfe76540e56afb3d
typeable/generic-arbitrary
LimitationDemo.hs
module LimitationDemo where import Control.DeepSeq import GHC.Generics (Generic) import Test.QuickCheck import Test.QuickCheck.Arbitrary.Generic -- As you can see, we have this instance generated, but it will definitely lead -- to generating an infinite ter...
null
https://raw.githubusercontent.com/typeable/generic-arbitrary/c43267f0a1ae6659130f269452420c89db06d1a4/test/LimitationDemo.hs
haskell
As you can see, we have this instance generated, but it will definitely lead to generating an infinite term (and the only term). The recursion detection doesn't work here To force the instance realy be generated haha
module LimitationDemo where import Control.DeepSeq import GHC.Generics (Generic) import Test.QuickCheck import Test.QuickCheck.Arbitrary.Generic data R1 = R1 R2 deriving (Eq, Ord, Show, Generic) deriving anyclass NFData #if MIN_VERSION_QuickCheck(2, 14,...
7c21255548d70fd41b07be524cfda1293a361d95c2180335a8509ad8baadf5c5
SaswatPadhi/LoopInvGen
Synthesizer.ml
open Core_kernel open Exceptions open Utils module Config = struct type cost_attr = Height | Size type t = { cost_limit : int ; cost_attribute : cost_attr ; logic : Logic.t ; max_expressiveness_level : int ; order : int -> int -> float ; } let default : t = { cost_limit = 32 ; co...
null
https://raw.githubusercontent.com/SaswatPadhi/LoopInvGen/6ac90265b11431c9477dfbd33e3e3380234c0499/src/Synthesizer.ml
ocaml
open Core_kernel open Exceptions open Utils module Config = struct type cost_attr = Height | Size type t = { cost_limit : int ; cost_attribute : cost_attr ; logic : Logic.t ; max_expressiveness_level : int ; order : int -> int -> float ; } let default : t = { cost_limit = 32 ; co...
0dfb21f35650aee11f59a2f7821a3fa9bec9da583d786b4a629bda7c29f3cc9d
janestreet/jsonaf
type.ml
type t = [ `Null | `False | `True | `String of string | `Number of string | `Object of (string * t) list | `Array of t list ] constraint t = string Expert.t
null
https://raw.githubusercontent.com/janestreet/jsonaf/9f8226165a329db47119f751d02449f2751d87c9/kernel/src/type.ml
ocaml
type t = [ `Null | `False | `True | `String of string | `Number of string | `Object of (string * t) list | `Array of t list ] constraint t = string Expert.t
2923fcf22b1831926395c9ed0c99601597a6a2b063059d34f490efe2ea5bc514
esl/MongooseIM
auth_internal_SUITE.erl
-module(auth_internal_SUITE). -compile([export_all, nowarn_export_all]). -include_lib("eunit/include/eunit.hrl"). -include("scram.hrl"). all() -> [passwords_as_records_are_still_supported, passwords_in_plain_can_be_converted_to_scram]. init_per_suite(C) -> application:ensure_all_started(jid), ok = m...
null
https://raw.githubusercontent.com/esl/MongooseIM/6e3409c9b785c1005ae62dafa67064776be85281/test/auth_internal_SUITE.erl
erlang
when we read the password via ejabberd_auth_internal:get_password/3 then new map with sha key is returned even though in db there is old record stored with plain text password and password in the old record format when the migration function is run then plain text passwords are converted to new map with sha and ...
-module(auth_internal_SUITE). -compile([export_all, nowarn_export_all]). -include_lib("eunit/include/eunit.hrl"). -include("scram.hrl"). all() -> [passwords_as_records_are_still_supported, passwords_in_plain_can_be_converted_to_scram]. init_per_suite(C) -> application:ensure_all_started(jid), ok = m...
2e09e10cf8e941a885f00df7ac82fa8da01670f7d7d91df4a8be3e916f820365
ygrek/mldonkey
gui_rooms.ml
Copyright 2001 , 2002 b8_bavard , b8_fee_carabine , This file is part of mldonkey . mldonkey is free software ; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the License , or ...
null
https://raw.githubusercontent.com/ygrek/mldonkey/333868a12bb6cd25fed49391dd2c3a767741cb51/src/gtk/newgui/gui_rooms.ml
ocaml
* GUI for the lists of files. method rooms = data try to get the user name to put some color: ???? Username of what ? ServerMessage is a message sent from the server, not from a user !!! Maybe automatic selection is not that good ?: ; match opened_rooms#rooms with [room] -> opened_rooms#...
Copyright 2001 , 2002 b8_bavard , b8_fee_carabine , This file is part of mldonkey . mldonkey is free software ; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the License , or ...
2eb0982a13be925567f184712176fa6959d5560af682d167f5f5518502479498
rabbitmq/rabbitmq-mqtt
Elixir.RabbitMQ.CLI.Ctl.Commands.ListMqttConnectionsCommand.erl
This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. %% Copyright ( c ) 2007 - 2020 VMware , Inc. or its affiliates . All rights reserved . -module('Elixir.RabbitMQ.CLI.Ctl.Commands.ListMqttCo...
null
https://raw.githubusercontent.com/rabbitmq/rabbitmq-mqtt/817971bfec4461630a2ef7e27d4fa9f4c4fb8ff9/src/Elixir.RabbitMQ.CLI.Ctl.Commands.ListMqttConnectionsCommand.erl
erlang
a node uses the Raft-based collector to list connections, which knows about all connections in the cluster so no need to reach out to all the nodes
This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. Copyright ( c ) 2007 - 2020 VMware , Inc. or its affiliates . All rights reserved . -module('Elixir.RabbitMQ.CLI.Ctl.Commands.ListMqttConne...
4d450f935af521aae8ca19092d4045d15f0f454fcf7ee8bbe714b4818fbd91a0
CindyLinz/Haskell.js
Parse.hs
module Parse ( getAllModules , prettyPrintAllModules ) where import Language.Haskell.Exts.Annotated import Language.Haskell.Exts.Pretty import qualified Data.Map.Strict as M import System.IO import System.FilePath import Control.Exception moduleImports :: Module l -> [String] moduleImports (Module _ _ _ imports...
null
https://raw.githubusercontent.com/CindyLinz/Haskell.js/78429a49181a15f6bdae426f17bdae722ad17141/trans/src/Parse.hs
haskell
module Parse ( getAllModules , prettyPrintAllModules ) where import Language.Haskell.Exts.Annotated import Language.Haskell.Exts.Pretty import qualified Data.Map.Strict as M import System.IO import System.FilePath import Control.Exception moduleImports :: Module l -> [String] moduleImports (Module _ _ _ imports...
6d85ca17bd3def6000dbd5ac5024068d5daca11806b1f75a9dc7fcb045bdadea
dgrnbrg/piplin
protocols.clj
(ns piplin.protocols) (defprotocol ITyped "Things with types in piplin implement this." (typeof [this] "Return type obj for this obj.") (value [this] "Return the value of this") (pipinst? [this] "Returns true if this is an instance of the type (as opposed to a symbolic rep...
null
https://raw.githubusercontent.com/dgrnbrg/piplin/01f3ac72ccc904b7789dfd6e46277c179e11002c/src/piplin/protocols.clj
clojure
(ns piplin.protocols) (defprotocol ITyped "Things with types in piplin implement this." (typeof [this] "Return type obj for this obj.") (value [this] "Return the value of this") (pipinst? [this] "Returns true if this is an instance of the type (as opposed to a symbolic rep...
6dec41203a86d76619420243f0d2e1a862d30728057d5e75586347402556964a
rmloveland/scheme48-0.53
no-gc-package-defs.scm
Copyright ( c ) 1993 - 1999 by and . See file COPYING . These are used to compile the VM separately from the GC . It has new definitions of the heap and GC structures with all of the values defined ; as externals. (define-structure allocation allocation-interface (open prescheme) (begin (define s4...
null
https://raw.githubusercontent.com/rmloveland/scheme48-0.53/1ae4531fac7150bd2af42d124da9b50dd1b89ec1/scheme/vm/no-gc-package-defs.scm
scheme
as externals. macro make type checker happy about KEY
Copyright ( c ) 1993 - 1999 by and . See file COPYING . These are used to compile the VM separately from the GC . It has new definitions of the heap and GC structures with all of the values defined (define-structure allocation allocation-interface (open prescheme) (begin (define s48-available? ...
bb4f03d8fd13df7104a7732053208cf2cf8a9c115ae691e9533331ce079d1921
martijnbastiaan/doctest-parallel
ModuleB.hs
module BugfixImportHierarchical.ModuleB (fib) where -- | > > > fib 10 55 > > > fib 5 5 fib :: Integer -> Integer fib 0 = 0 fib 1 = 1 fib n = fib (n - 1) + fib (n - 2)
null
https://raw.githubusercontent.com/martijnbastiaan/doctest-parallel/f70d6a1c946cc0ada88571b90a39a7cd4d065452/test/integration/BugfixImportHierarchical/ModuleB.hs
haskell
|
module BugfixImportHierarchical.ModuleB (fib) where > > > fib 10 55 > > > fib 5 5 fib :: Integer -> Integer fib 0 = 0 fib 1 = 1 fib n = fib (n - 1) + fib (n - 2)
1f0b19912b5f30a7a587252a1a8e910e3951f6c4f56cad95ffe535fb497c5a2d
paurkedal/iplogic
iplogic_address.mli
Copyright ( C ) 2012 - -2017 Petter A. Urkedal < > * * This program is free software : you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation , either version 3 of the License , or * ( at your option ) any later ver...
null
https://raw.githubusercontent.com/paurkedal/iplogic/7c56b5c55c03a681381fafb80220a5c0eba9f212/lib/iplogic_address.mli
ocaml
Copyright ( C ) 2012 - -2017 Petter A. Urkedal < > * * This program is free software : you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation , either version 3 of the License , or * ( at your option ) any later ver...
ed3fa97ec6bf40bbf92775d1a963dffa92169ff8814f30b4219594a7765e4b98
rorra/rorracasts_erlang
compresion.erl
-module(compresion). -compile(export_all). map(F, Lista) -> [F(X) || X <- Lista]. ordenar([Pivote|Cola]) -> ordenar([X || X <- Cola, X < Pivote]) ++ [Pivote] ++ ordenar([X || X <- Cola, X >= Pivote]); ordenar([]) -> [].
null
https://raw.githubusercontent.com/rorra/rorracasts_erlang/c50d20abe3f1a65001576734caedae90f36e3ecd/003-funs-iteracion-listas-por-compresion/compresion.erl
erlang
-module(compresion). -compile(export_all). map(F, Lista) -> [F(X) || X <- Lista]. ordenar([Pivote|Cola]) -> ordenar([X || X <- Cola, X < Pivote]) ++ [Pivote] ++ ordenar([X || X <- Cola, X >= Pivote]); ordenar([]) -> [].
be710bda7bd526288ed4d1d7ec89c4e1d5bd0b68c734381b9b8e5001915384d8
glguy/advent2015
Day4.hs
module Main where import Control.Monad (replicateM) import Data.Binary.Get (runGet, getWord32le) import Data.Bits ((.|.), (.&.), complement, rotateL, xor) import Data.ByteString.Builder (Builder, toLazyByteString, lazyByteString, word8, word32LE, word64LE) import...
null
https://raw.githubusercontent.com/glguy/advent2015/e59b93c41363be85eb7f11396db5c95e79e485ad/Day4.hs
haskell
| Find the smallest, positive integer that has the specified and a ASCII, base-10 representation of the number. ^ player key ^ number to hash > md5 "" d41d8cd98f00b204e9800998ecf8427e > md5 "The quick brown fox jumps over the lazy dog." | Pad out an input string to be suitable for breaking into is added tha...
module Main where import Control.Monad (replicateM) import Data.Binary.Get (runGet, getWord32le) import Data.Bits ((.|.), (.&.), complement, rotateL, xor) import Data.ByteString.Builder (Builder, toLazyByteString, lazyByteString, word8, word32LE, word64LE) import...
0e0c7d48c716b8825bed77356145372b548e9dabcc287f666d7bc4447af1706c
axelarge/advent-of-code
day04_test.clj
(ns advent-of-code.y2017.day04-test (:require [clojure.test :refer :all] [advent-of-code.y2017.day04 :refer :all])) (deftest test-solve1 (is (= (solve1 "aa bb cc dd ee") 1)) (is (= (solve1 "aa bb cc dd aa") 0)) (is (= (solve1 "aa bb cc dd aaa") 1)) (is (= (solve1 input) 455))) (deftest test-solv...
null
https://raw.githubusercontent.com/axelarge/advent-of-code/4c62a53ef71605780a22cf8219029453d8e1b977/test/advent_of_code/y2017/day04_test.clj
clojure
(ns advent-of-code.y2017.day04-test (:require [clojure.test :refer :all] [advent-of-code.y2017.day04 :refer :all])) (deftest test-solve1 (is (= (solve1 "aa bb cc dd ee") 1)) (is (= (solve1 "aa bb cc dd aa") 0)) (is (= (solve1 "aa bb cc dd aaa") 1)) (is (= (solve1 input) 455))) (deftest test-solv...
35f8a66e58e4b4729708214d3b77ba7c53a725e318504a373e6ce5ff40089666
input-output-hk/project-icarus-importer
Util.hs
-- | Useful functions for testing scenarios. # LANGUAGE TypeApplications # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # {-# LANGUAGE OverloadedStrings #-} module Test.Pos.Wallet.Web.Util ( -- * Block utils wpGenBlocks , wpGenBlock ...
null
https://raw.githubusercontent.com/input-output-hk/project-icarus-importer/36342f277bcb7f1902e677a02d1ce93e4cf224f0/wallet/test/Test/Pos/Wallet/Web/Util.hs
haskell
| Useful functions for testing scenarios. # LANGUAGE OverloadedStrings # * Block utils * Wallet utils -------------------------------------------------------------------------- Block utils -------------------------------------------------------------------------- ----------------------------------------------------...
# LANGUAGE TypeApplications # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE FlexibleContexts # # LANGUAGE FlexibleInstances # module Test.Pos.Wallet.Web.Util ( wpGenBlocks , wpGenBlock , importWallets , importSomeWallets , importSingleWallet , mostlyEmptyPassph...
4803c1a62df92feab0e72c35fd9ac2854f769d611f6a3f3893a074208eddc534
google/hrepl
ProtoLib.hs
module ProtoLib where import Data.ProtoLens import Proto.Hrepl.Tests.Test test :: Test test = defMessage
null
https://raw.githubusercontent.com/google/hrepl/2648a55cc38407c5b60a3a086217e2d827ca6cb6/hrepl/tests/ProtoLib.hs
haskell
module ProtoLib where import Data.ProtoLens import Proto.Hrepl.Tests.Test test :: Test test = defMessage
1ebc7b3a4a676c62e1f627a05bc6aaf9cf69d9c1064122e0db49fae435076f4b
arthur-adjedj/proof_assistant
lexer_stored.ml
# 1 "C:\Users\aarth\IdeaProjects\Theorem_prover\pr_assistant\proof_store\lexer_stored.mll" open Parser_stored (* The type token is defined in parser.mli *) exception Eof # 7 "C:\Users\aarth\IdeaProjects\Theorem_prover\pr_assistant\proof_store\lexer_stored.ml" let __ocaml_lex_ta...
null
https://raw.githubusercontent.com/arthur-adjedj/proof_assistant/a47ae2e1012e77ed810de0f8c99a957571ad5c27/pr_assistant/proof_store/lexer_stored.ml
ocaml
The type token is defined in parser.mli
# 1 "C:\Users\aarth\IdeaProjects\Theorem_prover\pr_assistant\proof_store\lexer_stored.mll" exception Eof # 7 "C:\Users\aarth\IdeaProjects\Theorem_prover\pr_assistant\proof_store\lexer_stored.ml" let __ocaml_lex_tables = { Lexing.lex_base = "\000\000\244\255\245\255\246\255\000\000\249\25...
bd115a9847b772c94900a5380da7cb755841b204fd091c4709f40022c688b808
chiroptical/book-of-monads
Lib.hs
# LANGUAGE LambdaCase # # LANGUAGE MonadComprehensions # module Lib where import Control.Monad (replicateM, replicateM_) import Control.Monad.IO.Class (liftIO) import Control.Monad.Trans.State data Person = Person { personName :: String , personAge ::...
null
https://raw.githubusercontent.com/chiroptical/book-of-monads/c2eff1c67a8958b28cfd2001d652f8b68e7c84df/chapter2/src/Lib.hs
haskell
get the internal state of the monad x <- get -- x :: s update the internal state of the monad put x, x :: s incrCounter, gets the integer maintaining the state, store the incremented integer, return the result
# LANGUAGE LambdaCase # # LANGUAGE MonadComprehensions # module Lib where import Control.Monad (replicateM, replicateM_) import Control.Monad.IO.Class (liftIO) import Control.Monad.Trans.State data Person = Person { personName :: String , personAge ::...
4598bc554f1464d895ce679d736b704b0dce89ab5f25169fbcf5c837f96eebaa
auser/alice
mochiweb.erl
@author < > 2007 Mochi Media , Inc. @doc Start and stop the MochiWeb server . -module(mochiweb). -author(''). -export([start/0, stop/0]). -export([new_request/1, new_response/1]). -export([all_loaded/0, all_loaded/1, reload/0]). -export([test/0]). @spec start ( ) - > ok @doc Start the MochiWeb server ...
null
https://raw.githubusercontent.com/auser/alice/e0f867071ede99f451d09053608bd6719c72d1c9/deps/mochiweb/src/mochiweb.erl
erlang
@doc Return a mochiweb_request data structure. this case probably doesn't "exist". Request-URI is "*" @doc Return a mochiweb_response data structure. Internal API
@author < > 2007 Mochi Media , Inc. @doc Start and stop the MochiWeb server . -module(mochiweb). -author(''). -export([start/0, stop/0]). -export([new_request/1, new_response/1]). -export([all_loaded/0, all_loaded/1, reload/0]). -export([test/0]). @spec start ( ) - > ok @doc Start the MochiWeb server ...
9c23aaaf4c5d30df00b3bfaea0012246d9dbcb6a2a360b98b52ba54f1db583db
adamgundry/inch
Wires.hs
# OPTIONS_GHC -F -pgmF inch # # LANGUAGE RankNTypes , GADTs , KindSignatures , ScopedTypeVariables , NPlusKPatterns # NPlusKPatterns #-} module Wires where import Vectors -- A value of type Wire m a n b represents a process that consumes m -- inputs of type a and delivers n outputs of ty...
null
https://raw.githubusercontent.com/adamgundry/inch/86e10993b59851b4dfb0f037564e9d9228e5ad7f/examples/Wires.hs
haskell
A value of type Wire m a n b represents a process that consumes m inputs of type a and delivers n outputs of type b. Given a vector of inputs, we can run it to produce a vector of outputs "Vertical" composition of wires Some basic combinators and logic gates Half and full adders Converting from multiple wires to...
# OPTIONS_GHC -F -pgmF inch # # LANGUAGE RankNTypes , GADTs , KindSignatures , ScopedTypeVariables , NPlusKPatterns # NPlusKPatterns #-} module Wires where import Vectors data Wire :: Nat -> * -> Nat -> * -> * where Stop :: Wire 0 a 0 b Say :: forall (m n :: Nat) a b . ...
0e94fbf05c0a0bee9dfd061da9ea3cd4ab777fd79e21840b01a0a8fe11c03cf7
keithj/cl-genomic
fjoin.lisp
;;; Copyright ( c ) 2009 - 2011 . All rights reserved . ;;; ;;; This file is part of cl-genomic. ;;; ;;; This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3 of the License , or ;...
null
https://raw.githubusercontent.com/keithj/cl-genomic/d160199c2b369df97afd3fded16b1ade507b80dd/src/fjoin.lisp
lisp
This file is part of cl-genomic. This program is free software: you can redistribute it and/or modify (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR P...
Copyright ( c ) 2009 - 2011 . All rights reserved . it under the terms of the GNU General Public License as published by the Free Software Foundation , either version 3 of the License , or You should have received a copy of the GNU General Public License (in-package :bio-sequence) (defparameter *sentinel* (...
13bc2a24eba177ef2d1dfb99cb06c5bed4b3cff196957a16038dffaa48126859
CLowcay/hgbc
Counter.hs
# LANGUAGE RecordWildCards # module Machine.GBC.Primitive.Counter ( Counter, new, get, reload, update, ) where import Control.Monad.IO.Class (MonadIO (..)) import Data.Bits (Bits (..)) import Machine.GBC.Primitive.UnboxedRef (UnboxedRef, newUnboxedRef, readUnboxedRef, writeUnboxedRef) | A reloa...
null
https://raw.githubusercontent.com/CLowcay/hgbc/76a8cf91f3c3b160eadf019bc8fc75ef07601c2f/core/src/Machine/GBC/Primitive/Counter.hs
haskell
# INLINE reload # # INLINE get #
# LANGUAGE RecordWildCards # module Machine.GBC.Primitive.Counter ( Counter, new, get, reload, update, ) where import Control.Monad.IO.Class (MonadIO (..)) import Data.Bits (Bits (..)) import Machine.GBC.Primitive.UnboxedRef (UnboxedRef, newUnboxedRef, readUnboxedRef, writeUnboxedRef) | A reloa...
850a4bff61dbf7554b1a0370a466d5ebd3dce1bc6b484558e1c9decdf9e71547
input-output-hk/cardano-sl
Gen.hs
module Test.Pos.Util.Gen ( genMillisecond , genHashMap , genHashSet ) where import Universum import qualified Data.HashMap.Strict as HM import qualified Data.HashSet as HS import Data.Time.Units (Millisecond, fromMicroseconds) import Hedgehog import quali...
null
https://raw.githubusercontent.com/input-output-hk/cardano-sl/1499214d93767b703b9599369a431e67d83f10a2/util/test/Test/Pos/Util/Gen.hs
haskell
module Test.Pos.Util.Gen ( genMillisecond , genHashMap , genHashSet ) where import Universum import qualified Data.HashMap.Strict as HM import qualified Data.HashSet as HS import Data.Time.Units (Millisecond, fromMicroseconds) import Hedgehog import quali...
5c7754cbea77b73e2bc8219841b53020cf9bb480892973604ac38fdf85642d4e
retrogradeorbit/moonhenge
moon.cljs
(ns moonhenge.moon (:require [moonhenge.assets :as assets] [moonhenge.boid :as boid] [infinitelives.pixi.canvas :as c] [infinitelives.pixi.events :as e] [infinitelives.pixi.resources :as r] [infinitelives.pixi.texture :as t] [infinitelives.pixi.s...
null
https://raw.githubusercontent.com/retrogradeorbit/moonhenge/3228e2f50a90abecddf01e2aedd1d30c0a588b93/src/moonhenge/moon.cljs
clojure
bring in some druids wait for the druids to finish arriving kill the druid go-threads
(ns moonhenge.moon (:require [moonhenge.assets :as assets] [moonhenge.boid :as boid] [infinitelives.pixi.canvas :as c] [infinitelives.pixi.events :as e] [infinitelives.pixi.resources :as r] [infinitelives.pixi.texture :as t] [infinitelives.pixi.s...
6f32a16ffac18f5cf299c18a28f642cc93b2e766743293f45bdc9be3a19ec4ce
quchen/prettyprinter
TreeRenderingTutorial.hs
module Data.Text.Prettyprint.Doc.Render.Tutorials.TreeRenderingTutorial {-# DEPRECATED "Use \"Prettyprinter.Render.Tutorials.TreeRenderingTutorial\" instead." #-} ( module Prettyprinter.Render.Tutorials.TreeRenderingTutorial ) where import Prettyprinter.Render.Tutorials.TreeRenderingTutorial
null
https://raw.githubusercontent.com/quchen/prettyprinter/880f41eac31edfac71d2d66d338e6cfdae4f3715/prettyprinter/src/Data/Text/Prettyprint/Doc/Render/Tutorials/TreeRenderingTutorial.hs
haskell
# DEPRECATED "Use \"Prettyprinter.Render.Tutorials.TreeRenderingTutorial\" instead." #
module Prettyprinter.Render.Tutorials.TreeRenderingTutorial ) where import Prettyprinter.Render.Tutorials.TreeRenderingTutorial
53f47d76c599f23974a5a5a030c8223e4c32c716db19f551600da7f6923d5b2b
vikram/lisplibraries
illustrations.lisp
$ I d : illustrations.lisp , v 1.6 2007/10/01 16:24:10 xach Exp $ (defpackage #:vecto-illustrations (:use #:cl #:vecto)) (in-package #:vecto-illustrations) (defun x (point) (car point)) (defun y (point) (cdr point)) (defun annotated-path (&rest points) (with-graphics-state (set-rgb-stroke 0.5 0.5 0.5...
null
https://raw.githubusercontent.com/vikram/lisplibraries/105e3ef2d165275eb78f36f5090c9e2cdd0754dd/site/vecto-1.1/doc/illustrations.lisp
lisp
$ I d : illustrations.lisp , v 1.6 2007/10/01 16:24:10 xach Exp $ (defpackage #:vecto-illustrations (:use #:cl #:vecto)) (in-package #:vecto-illustrations) (defun x (point) (car point)) (defun y (point) (cdr point)) (defun annotated-path (&rest points) (with-graphics-state (set-rgb-stroke 0.5 0.5 0.5...
591745900cb05bfdc62df0852b3ec8a5bd445e1c74c6d13103031e563d9ff633
pouyakary/Nota
Negation.hs
module Language.BackEnd.Evaluator.Nodes.Negation ( evalNegation ) where -- ─── IMPORTS ──────────────────────────────────────────────────────────────────── import Data.List import Data.Map ( Map ) import qualified Data.Map as Map import Language.BackEnd.Evaluator.Types import ...
null
https://raw.githubusercontent.com/pouyakary/Nota/d5e29eca7ea34d72835a9708977fa33c030393d1/source/Language/BackEnd/Evaluator/Nodes/Negation.hs
haskell
─── IMPORTS ──────────────────────────────────────────────────────────────────── ────────────────────────────────────────────────────────────────────────────────
module Language.BackEnd.Evaluator.Nodes.Negation ( evalNegation ) where import Data.List import Data.Map ( Map ) import qualified Data.Map as Map import Language.BackEnd.Evaluator.Types import Language.FrontEnd.AST import Model ─ ─ ─ NEGATION ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ...
5a72a6fca1650b3cfe09d6cea6cbdc779a25d5dde4b8f699e98622af47aeae89
clj-commons/rewrite-clj
apply_import_vars.clj
;; Run via clojure -X: ;; invoked by apply_import_vars.clj bb script (ns lread.apply-import-vars (:require [clojure.java.io :as io] [clojure.string :as string] [io.aviso.ansi :as ansi] [malli.core :as m] [malli.error :as me] [malli.util :as mu] ...
null
https://raw.githubusercontent.com/clj-commons/rewrite-clj/ced60309613a2672b4adc0532948d496a0778d77/script/lread/apply_import_vars.clj
clojure
Run via clojure -X: invoked by apply_import_vars.clj bb script use internal nses instead of exported nses, we are generating exported nses. to load coercions mimic what parser does TODO: this escaping seems too awkward entry points for clojure tools cli for -X calls
(ns lread.apply-import-vars (:require [clojure.java.io :as io] [clojure.string :as string] [io.aviso.ansi :as ansi] [malli.core :as m] [malli.error :as me] [malli.util :as mu] [rewrite-clj.custom-zipper.core :as zraw] [rewrite-clj.no...
5bbeecea70709930690011516c6e4e52a0f2e650b53e5156fafdf8f34bf06e53
Eonblast/Scalaxis
scalaris.erl
2007 - 2011 Zuse Institute Berlin Licensed under the Apache License , Version 2.0 ( the " License " ) ; % you may not use this file except in compliance with the License. % You may obtain a copy of the License at % % -2.0 % % Unless required by applicable law or agreed to in writing, software di...
null
https://raw.githubusercontent.com/Eonblast/Scalaxis/10287d11428e627dca8c41c818745763b9f7e8d4/src/scalaris.erl
erlang
you may not use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language gov...
2007 - 2011 Zuse Institute Berlin Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , @author < > -module(scalaris). -author(''). -vsn('$Id$'). -include("scalaris.hrl"). functions called by Erlangs init module ,...
9705c76b51892cf96b56eaa3b49c52259cda8cdc985e1ca25fcac30860263bc3
ocramz/petsc-hs
Common.hs
----------------------------------------------------------------------------- -- | -- Module : Numerical.PETSc.Internal.Storable.Common Copyright : ( c ) 2015 -- License : LGPL3 Maintainer : zocca . . gmail . com -- Stability : experimental -- | common adapters for -- ------------------...
null
https://raw.githubusercontent.com/ocramz/petsc-hs/d74a468da0dbc867d2ea25f280c7892cc54add48/src/Numerical/PETSc/Internal/Storable/Common.hs
haskell
--------------------------------------------------------------------------- | Module : Numerical.PETSc.Internal.Storable.Common License : LGPL3 Stability : experimental --------------------------------------------------------------------------- -- e.g. liftVectorF1_ = liftF1_ vecGetVector vecRest...
Copyright : ( c ) 2015 Maintainer : zocca . . gmail . com | common adapters for module Numerical.PETSc.Internal.Storable.Common where import Data.Functor import Control.Applicative import Control.Monad import Foreign.C.Types import Foreign.Ptr import Foreign.Storable import qualified Data.Vector.G...
150307d1bdef9b3493464856336fd5539f9d728f59713c91932d3f80e9f476f6
marcoonroad/subtype-refinement
subtype_refinement.ml
module type IValue = sig type t val value : t end module type IConstraint = sig type t val where : t -> bool end module type Subtype = sig type super type t = private super exception FailedDownCast of super val upcast : t -> super val downcast : super -> t end module Refine (Constraint : ...
null
https://raw.githubusercontent.com/marcoonroad/subtype-refinement/9ba4e0ccb238e832519b555295ce1bed3dbfeebc/lib/subtype_refinement.ml
ocaml
END
module type IValue = sig type t val value : t end module type IConstraint = sig type t val where : t -> bool end module type Subtype = sig type super type t = private super exception FailedDownCast of super val upcast : t -> super val downcast : super -> t end module Refine (Constraint : ...
a89255480feaa5b002050414a02f4c5ac825785b0b071d96d1901e32adfc7208
jwaldmann/haskell-obdd
MM0916.hs
-- | /~efriedma/mathmagic/0916.html -- On an N×N chessboard, when we place Q queens, -- what is the maximum number of squares -- that can be attacked exactly A times? # language LambdaCase # import Prelude hiding ((&&),(||),not,and,or) import qualified Prelude as P import OBDD import OBDD.Linopt import Data.Ix (...
null
https://raw.githubusercontent.com/jwaldmann/haskell-obdd/537f710bc3eb6d06370659fd8c79f4da94554aeb/examples/MM0916.hs
haskell
| /~efriedma/mathmagic/0916.html On an N×N chessboard, when we place Q queens, what is the maximum number of squares that can be attacked exactly A times?
# language LambdaCase # import Prelude hiding ((&&),(||),not,and,or) import qualified Prelude as P import OBDD import OBDD.Linopt import Data.Ix (inRange) import qualified Data.Array as A import Control.Monad ( guard ) import System.Environment ( getArgs ) import Data.List (sort) import qualified Data.Map.Strict as...
909a7c354af2f5fceab0199b18e4d1c884cc1a30330700a390d7534a5b981c16
amperity/dialog
print_test.clj
(ns dialog.output.print-test (:require [clojure.test :refer [deftest testing is]] [dialog.output.print :as print]) (:import java.io.StringWriter)) (deftest event-writing (testing "bad args" (is (thrown? IllegalArgumentException (print/writer {:stream :bad})))) (testing "default stdou...
null
https://raw.githubusercontent.com/amperity/dialog/078d297e0ac4f35f0db6e652b770121f60cee5de/test/dialog/output/print_test.clj
clojure
(ns dialog.output.print-test (:require [clojure.test :refer [deftest testing is]] [dialog.output.print :as print]) (:import java.io.StringWriter)) (deftest event-writing (testing "bad args" (is (thrown? IllegalArgumentException (print/writer {:stream :bad})))) (testing "default stdou...
1a60b962f8483ad84d6d3c4dcc0aaaa4bd5d21af5414c8b8cf6e2d26e7be578a
tlaplus/tlapm
print.ml
Copyright 2004 INRIA open Expr;; open Mlproof;; open Namespace;; open Printf;; type output = Buff of Buffer.t | Chan of out_channel;; let mybuf = Buffer.create 100;; let mychan = ref stdout;; let flush () = Buffer.output_buffer !mychan mybuf; Buffer.clear mybuf;; let printf = ();; (* FIXME DEBUG *) let oprin...
null
https://raw.githubusercontent.com/tlaplus/tlapm/b82e2fd049c5bc1b14508ae16890666c6928975f/zenon/print.ml
ocaml
FIXME DEBUG ... ... ...
Copyright 2004 INRIA open Expr;; open Mlproof;; open Namespace;; open Printf;; type output = Buff of Buffer.t | Chan of out_channel;; let mybuf = Buffer.create 100;; let mychan = ref stdout;; let flush () = Buffer.output_buffer !mychan mybuf; Buffer.clear mybuf;; match o with | Chan c -> flush (); ...
dcaca561b76ff224d16c91346d23406d32d693afe449d9ff1e677446ebbca88b
mswift42/themecreator
core.cljs
(ns ^:figwheel-hooks app.core (:require [goog.dom :as gdom] [reagent.core :as reagent :refer [atom]] [app.app :as app])) (defn get-app-element [] (gdom/getElement "app")) (defn mount [el] (app/init)) (defn mount-app-element [] (when-let [el (get-app-element)] (mount el))) ;; conditionally s...
null
https://raw.githubusercontent.com/mswift42/themecreator/b2b5d2e9b24572122aa43688d4376b62d6dda638/app.core/src/app/core.cljs
clojure
conditionally start your application based on the presence of an "app" element this is particularly helpful for testing this ns without launching the app specify reload hook with ^;after-load metadata optionally touch your app-state to force rerendering depending on your application (swap! app-state update-in [:_...
(ns ^:figwheel-hooks app.core (:require [goog.dom :as gdom] [reagent.core :as reagent :refer [atom]] [app.app :as app])) (defn get-app-element [] (gdom/getElement "app")) (defn mount [el] (app/init)) (defn mount-app-element [] (when-let [el (get-app-element)] (mount el))) (mount-app-element...
a2da6759e696c409c9345f71600d4ddd12e38c5c82bbf9860e5d5c1aa30ca9ad
wireless-net/erlang-nommu
erl_comment_scan.erl
%% ===================================================================== %% This library is free software; you can redistribute it and/or modify %% it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation ; either version 2 of the %% License, or (at your option) any lat...
null
https://raw.githubusercontent.com/wireless-net/erlang-nommu/79f32f81418e022d8ad8e0e447deaea407289926/lib/syntax_tools/src/erl_comment_scan.erl
erlang
===================================================================== This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as License, or (at your option) any later version. This library is distributed in the hope that it will be useful, ...
published by the Free Software Foundation ; either version 2 of the You should have received a copy of the GNU Lesser General Public Foundation , Inc. , 59 Temple Place , Suite 330 , Boston , MA 02111 - 1307 USA 1997 - 2006 @author < > @doc Functions for reading comment lines from Erlang source cod...
361bf1e905d0f3e56b942b7e2141a5ffaf22306ff0a6d1268ab159d70670d09f
kupl/FixML
sub14.ml
type formula = TRUE | FALSE | NOT of formula | ANDALSO of formula * formula | ORELSE of formula * formula | IMPLY of formula * formula | LESS of expr * expr and expr = NUM of int | PLUS of expr * expr | MINUS of expr * expr let rec calc ex = match ex with NUM f -> f | PLUS (a, b) -> calc a + calc...
null
https://raw.githubusercontent.com/kupl/FixML/0a032a733d68cd8ccc8b1034d2908cd43b241fce/benchmarks/formula/formula/submissions/sub14.ml
ocaml
type formula = TRUE | FALSE | NOT of formula | ANDALSO of formula * formula | ORELSE of formula * formula | IMPLY of formula * formula | LESS of expr * expr and expr = NUM of int | PLUS of expr * expr | MINUS of expr * expr let rec calc ex = match ex with NUM f -> f | PLUS (a, b) -> calc a + calc...
c8ddfcce75442878f14ba7776d2806c8682c6bd0b177a9d37869bd6785e1ccee
camdez/honeybadger
schemas.clj
(ns honeybadger.schemas (:require [schema.core :as s])) (def Event "A standard format for uniform processing by filters." {:api-key s/Str :env (s/maybe s/Keyword) :exception (s/either s/Str Throwable) :metadata {:tags #{s/Keyword} :request {(s/optional-key :method) s/Keyw...
null
https://raw.githubusercontent.com/camdez/honeybadger/2b126f53d4f5fa4f2c38d9d4fe1ae718fe43c483/src/honeybadger/schemas.clj
clojure
(ns honeybadger.schemas (:require [schema.core :as s])) (def Event "A standard format for uniform processing by filters." {:api-key s/Str :env (s/maybe s/Keyword) :exception (s/either s/Str Throwable) :metadata {:tags #{s/Keyword} :request {(s/optional-key :method) s/Keyw...
ccbdbdfa1e2b52c3927085297809b70edc3ad4d983602f29fe1fa3c98209e08c
mstksg/backprop-learn
Test.hs
# LANGUAGE ApplicativeDo # {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE PartialTypeSignatures #-} {-# LANGUAGE RankNTypes #-} {-# LANGUAGE ScopedTypeVariables #-} # LANGUAGE TypeApplications # {-...
null
https://raw.githubusercontent.com/mstksg/backprop-learn/59aea530a0fad45de6d18b9a723914d1d66dc222/old2/src/Backprop/Learn/Test.hs
haskell
# LANGUAGE FlexibleContexts # # LANGUAGE PartialTypeSignatures # # LANGUAGE RankNTypes # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # * Tests ** Manipulate tests * Run tests ** Correlation tests TODO...
# LANGUAGE ApplicativeDo # # LANGUAGE TypeApplications # # OPTIONS_GHC -fno - warn - partial - type - signatures # module Backprop.Learn.Test ( Test , maxIxTest, rmseTest , squaredErrorTest, absErrorTest, totalSquaredErrorTest, squaredErrorTestV , crossEntropyTest...
f2e3a01c122e6c066706b249887fb94c7112135a7a3960e85d788b3e2d1be4d8
drathier/elm-offline
Pattern.hs
# OPTIONS_GHC -Wall # module Canonicalize.Pattern ( verify , Bindings , DupsDict , canonicalize ) where import qualified Data.Map.Strict as Map import qualified AST.Canonical as Can import qualified AST.Module.Name as ModuleName import qualified AST.Source as Src import qualified Canonicalize.Environment...
null
https://raw.githubusercontent.com/drathier/elm-offline/f562198cac29f4cda15b69fde7e66edde89b34fa/compiler/src/Canonicalize/Pattern.hs
haskell
RESULTS VERIFY CANONICALIZE
# OPTIONS_GHC -Wall # module Canonicalize.Pattern ( verify , Bindings , DupsDict , canonicalize ) where import qualified Data.Map.Strict as Map import qualified AST.Canonical as Can import qualified AST.Module.Name as ModuleName import qualified AST.Source as Src import qualified Canonicalize.Environment...
1e6e8bf941edf86c111084fb16b85bb15ee320b6dcb1503f3bed0aa4dd524c40
scrintal/heroicons-reagent
language.cljs
(ns com.scrintal.heroicons.solid.language) (defn render [] [:svg {:xmlns "" :viewBox "0 0 24 24" :fill "currentColor" :aria-hidden "true"} [:path {:fillRule "evenodd" :d "M9 2.25a.75.75 0 01.75.75v1.506a49.38 49.38 0 015.343.371.75.75 0 11-.186 1.489c-...
null
https://raw.githubusercontent.com/scrintal/heroicons-reagent/572f51d2466697ec4d38813663ee2588960365b6/src/com/scrintal/heroicons/solid/language.cljs
clojure
(ns com.scrintal.heroicons.solid.language) (defn render [] [:svg {:xmlns "" :viewBox "0 0 24 24" :fill "currentColor" :aria-hidden "true"} [:path {:fillRule "evenodd" :d "M9 2.25a.75.75 0 01.75.75v1.506a49.38 49.38 0 015.343.371.75.75 0 11-.186 1.489c-...
3597ff003bc040a88cedb08a9e015bddbffc07339edf9b38c1baa0afd9773f3c
locusmath/locus
qr.clj
(ns locus.set.quiver.relation.quaternary.qr (:require [locus.set.logic.core.set :refer :all] [locus.set.logic.limit.product :refer :all] [locus.set.logic.sequence.object :refer :all] [locus.set.quiver.relation.binary.br :refer :all] [locus.set.quiver.relation.binary.sr ...
null
https://raw.githubusercontent.com/locusmath/locus/fb6068bd78977b51fd3c5783545a5f9986e4235c/src/clojure/locus/set/quiver/relation/quaternary/qr.clj
clojure
A quaternary relation is a set of ordered quadruples The theory of quaternary relations is even less developed than the theory of ternary relations, which in turn is less developed than the theory of binary relations. However, there are a number of cases in which quaternary relations appear in practice, so we prov...
(ns locus.set.quiver.relation.quaternary.qr (:require [locus.set.logic.core.set :refer :all] [locus.set.logic.limit.product :refer :all] [locus.set.logic.sequence.object :refer :all] [locus.set.quiver.relation.binary.br :refer :all] [locus.set.quiver.relation.binary.sr ...
5e1281e9e103372d0d71b2b37016a10bfbfc72ae0ce2f47f85072d9d316e0641
ToTal/total
print.ml
* Pretty - printing of expressions with [ Format ] library . * Print an expression , possibly placing parentheses around it . We always print things at a given " level " [ at_level ] . If the level exceeds the maximum allowed level [ max_level ] then the expression should be parenthesized . Let us...
null
https://raw.githubusercontent.com/ToTal/total/fa9c677c9110afd5fb423a4fe24eafff2fd08507/print.ml
ocaml
* Print the given source code position. * Print a sequence of things with the given (optional) separator. * [pi xs a ppf] prints abstraction [a] as dependent product using formatter [ppf]. * [lambda xs a ppf] prints abstraction [a] as a function using formatter [ppf]. * [expr ctx e ppf] prints expression [e] using ...
* Pretty - printing of expressions with [ Format ] library . * Print an expression , possibly placing parentheses around it . We always print things at a given " level " [ at_level ] . If the level exceeds the maximum allowed level [ max_level ] then the expression should be parenthesized . Let us...
8aca218af2e3fb910208a21a2187942dfb81bfc009df0c1fde0dc679eaa927b1
pixlsus/registry.gimp.org_static
migee.scm
(define (migee-add-watermark watermark_path inputfiles watermark_size watermark_padding watermark_layer_mode position_num output_dir) (let* ((filelist (cadr (file-glob inputfiles 1)))) (while (not (null? filelist)) (let* ( (filename (car filelist)) (image (car (file-jpeg-...
null
https://raw.githubusercontent.com/pixlsus/registry.gimp.org_static/ffcde7400f402728373ff6579947c6ffe87d1a5e/registry.gimp.org/files/migee.scm
scheme
Width of watermark is bigger. So set the width to percent, the adjust height to fit into the correct ratio. Height is set to same percent, then adjusted with aspect ratio (watermark) height/width. Scale Watermark [n][ NEW WIDTH ] [ NEW HEIGHT ((image width * .30)/wate...
(define (migee-add-watermark watermark_path inputfiles watermark_size watermark_padding watermark_layer_mode position_num output_dir) (let* ((filelist (cadr (file-glob inputfiles 1)))) (while (not (null? filelist)) (let* ( (filename (car filelist)) (image (car (file-jpeg-...
73bdee3ce8d38078469eedcf71cf821950c8ae363c4873def7636075d83c6129
sheyll/mediabus
FakePayload.hs
# LANGUAGE NumericUnderscores # module FakePayload where import Data.MediaBus import Test.QuickCheck import Control.Lens import Data.Default import Control.DeepSeq newtype FakePayload = FP { fakeDuration :: Ticks64At8000 } deriving (Eq, Show, Num, Arbitrary, Ord, NFData) instance Default FakePayload ...
null
https://raw.githubusercontent.com/sheyll/mediabus/f1a5d58412b5129d632c3968c23a5c3e1a300024/specs/FakePayload.hs
haskell
# LANGUAGE NumericUnderscores # module FakePayload where import Data.MediaBus import Test.QuickCheck import Control.Lens import Data.Default import Control.DeepSeq newtype FakePayload = FP { fakeDuration :: Ticks64At8000 } deriving (Eq, Show, Num, Arbitrary, Ord, NFData) instance Default FakePayload ...
826823cfa6e02d0bf8961f0a9cc7140b60a3ae3e7bdae6cb993d54d756bc4910
spawnfest/eep49ers
ex_graphicsContext.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 2009 - 2016 . 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 applic...
null
https://raw.githubusercontent.com/spawnfest/eep49ers/d1020fd625a0bbda8ab01caf0e1738eb1cf74886/lib/wx/examples/demo/ex_graphicsContext.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 l...
Copyright Ericsson AB 2009 - 2016 . 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(ex_graphicsContext). -behaviour(wx_object). -export([start/1]). -export([init/1, terminate/2, code_chang...
272f28601c12817bb32c56580f53b239edce9deba1e57a2882729210ff7bfe65
sneeuwballen/zipperposition
arTerm.ml
This file is free software , part of Zipperposition . See file " license " for more details . (** {1 Arbitrary Typed Terms and Formulas} *) open Logtk module QA = QCheck module T = Term type 'a arbitrary = 'a QCheck.arbitrary type 'a gen = 'a QCheck.Gen.t module PT = struct module PT = TypedSTerm let _const...
null
https://raw.githubusercontent.com/sneeuwballen/zipperposition/4774171b0d2dd8e0445dd769a8de544e25b5f190/src/arbitrary/arTerm.ml
ocaml
* {1 Arbitrary Typed Terms and Formulas} strict subterms shrink immediate subterms shrink immediate subterms
This file is free software , part of Zipperposition . See file " license " for more details . open Logtk module QA = QCheck module T = Term type 'a arbitrary = 'a QCheck.arbitrary type 'a gen = 'a QCheck.Gen.t module PT = struct module PT = TypedSTerm let _const ~ty s = PT.const ~ty (ID.make s) let rec s...
de9157d6a5cff4fda327db6250a7b02289a0f83a2daa15f89ddef61a35871583
ReactiveX/RxClojure
blocking.clj
(ns rx.lang.clojure.blocking "Blocking operators and functions. These should never be used in production code except at the end of an async chain to convert from rx land back to sync land. For example, to produce a servlet response. If you use these, you're a bad person. " (:refer-clojure :exclude [first i...
null
https://raw.githubusercontent.com/ReactiveX/RxClojure/8f8e454f447ae24549bcf5f001c9d2458af21cac/src/main/clojure/rx/lang/clojure/blocking.clj
clojure
(ns rx.lang.clojure.blocking "Blocking operators and functions. These should never be used in production code except at the end of an async chain to convert from rx land back to sync land. For example, to produce a servlet response. If you use these, you're a bad person. " (:refer-clojure :exclude [first i...
223fb4087d55eecf09e5e786f6b029f0b88df3d1cb051cfb728e7de095adeb3f
runtimeverification/haskell-backend
List.hs
| Module : Kore . Builtin . List Description : Built - in associative lists Copyright : ( c ) Runtime Verification , 2018 - 2021 License : BSD-3 - Clause Maintainer : Stability : experimental Portability : portable This module is intended to be imported qualified , to avoid collis...
null
https://raw.githubusercontent.com/runtimeverification/haskell-backend/283674984e2845ca5bf4877f36302a3c981e7bb4/kore/src/Kore/Builtin/List.hs
haskell
* Symbols * keys * Evaluators | Is the given sort hooked to the builtin List sort? Returns Nothing if the sort is unknown (i.e. the _PREDICATE sort). Returns Just False if the sort is a variable. | Verify that hooked symbol declarations are well-formed. See also: 'Builtin.verifySymbol' | Context for error m...
| Module : Kore . Builtin . List Description : Built - in associative lists Copyright : ( c ) Runtime Verification , 2018 - 2021 License : BSD-3 - Clause Maintainer : Stability : experimental Portability : portable This module is intended to be imported qualified , to avoid collis...
796ae4c5cc467eb1a9dd411e9774f66cf986646d5f75ed3ada9bd81709c7744d
ghcjs/ghcjs
arith011.hs
-- !!! Testing Int and Word module Main(main) where import Data.Int import Data.Word import Data.Bits added SOF import Control.Exception import Control.Monad import Numeric.Natural main :: IO () main = test test :: IO () test = do testIntlike "Int" (0::Int) testIntlike "Int8" (0::Int8) testIntlike "In...
null
https://raw.githubusercontent.com/ghcjs/ghcjs/e4cd4232a31f6371c761acd93853702f4c7ca74c/test/ghc/numeric/arith011.hs
haskell
!!! Testing Int and Word the overloading to work enumFrom enumFromThen enumFromTo enumFromThenTo
module Main(main) where import Data.Int import Data.Word import Data.Bits added SOF import Control.Exception import Control.Monad import Numeric.Natural main :: IO () main = test test :: IO () test = do testIntlike "Int" (0::Int) testIntlike "Int8" (0::Int8) testIntlike "Int16" (0::Int16) testIntl...
7cdcd65bd02f38c4b29306628e91b5bda4adbe3ce098c2460de0e5471538a264
rgeoghegan/ocaml-redis
test_redis_string_values.ml
Copyright ( C ) 2011 Released under the BSD license . See the LICENSE.txt file for more info . Tests for " Commands operating on string values " Released under the BSD license. See the LICENSE.txt file for more info. Tests for "Commands operating on string values" *) let test_set () = let t...
null
https://raw.githubusercontent.com/rgeoghegan/ocaml-redis/16b921c5cd3bc26103571f0fe0dfce6e796f06b4/tests/test_redis_string_values.ml
ocaml
These values come out backwards because of the way the list is unwrapped These values come out backwards because of the way the list is unwrapped
Copyright ( C ) 2011 Released under the BSD license . See the LICENSE.txt file for more info . Tests for " Commands operating on string values " Released under the BSD license. See the LICENSE.txt file for more info. Tests for "Commands operating on string values" *) let test_set () = let t...
ce6d3f5c02e1ce9baa9f5ab16401fcd916c2c5c5327328774166283ff14a0aa3
calvis/cKanren
mk-struct.rkt
#lang racket/base (require racket/base "../ck.rkt" "../tree-unify.rkt" "../tester.rkt") (provide test-mk-struct test-mk-struct-long) (define (test-mk-struct) (test "sanity test 1" (run* (q) succeed) '(_.0)) (test "sanity test 2" (run* (q) (== 5 5)) '(_.0)) (test-check ...
null
https://raw.githubusercontent.com/calvis/cKanren/8714bdd442ca03dbf5b1d6250904cbc5fd275e68/cKanren/tests/mk-struct.rkt
racket
#lang racket/base (require racket/base "../ck.rkt" "../tree-unify.rkt" "../tester.rkt") (provide test-mk-struct test-mk-struct-long) (define (test-mk-struct) (test "sanity test 1" (run* (q) succeed) '(_.0)) (test "sanity test 2" (run* (q) (== 5 5)) '(_.0)) (test-check ...
6b0f309d0b748d4f05ed84cfb4f0b6976c9b66d957946e849fa19f4dbc678c4d
satos---jp/mincaml_self_hosting
closure_conv.mli
type name = string * (Type.ty * Debug.debug_data) val name2str : name -> string val vs2str : name list -> string type cexp = | CConst of Syntax.const | COp of Syntax.optype * (name list) | CLet of name * cexp * cexp | CIf of Syntax.comptype * name * name * cexp * cexp | CVar of name | ...
null
https://raw.githubusercontent.com/satos---jp/mincaml_self_hosting/5fdf8b5083437d7607a924142eea52d9b1de0439/src/compiler/closure_conv.mli
ocaml
type name = string * (Type.ty * Debug.debug_data) val name2str : name -> string val vs2str : name list -> string type cexp = | CConst of Syntax.const | COp of Syntax.optype * (name list) | CLet of name * cexp * cexp | CIf of Syntax.comptype * name * name * cexp * cexp | CVar of name | ...
b5066a9ca8231ac9abed1312efa422604298b7920474882ad9183fac23c7da63
lamdu/lamdu
CodeEdit.hs
# LANGUAGE NamedFieldPuns , DisambiguateRecordFields # module Lamdu.GUI.CodeEdit ( make , Model , EvalResults , ExportActions(..) , -- exported for tests makePaneBodyEdit ) where import qualified Control.Lens as Lens import Control.Monad (zipWithM) import Control.Mon...
null
https://raw.githubusercontent.com/lamdu/lamdu/5b15688e53ccbf7448ff11134b3e51ed082c6b6c/src/Lamdu/GUI/CodeEdit.hs
haskell
exported for tests
# LANGUAGE NamedFieldPuns , DisambiguateRecordFields # module Lamdu.GUI.CodeEdit ( make , Model , EvalResults , ExportActions(..) makePaneBodyEdit ) where import qualified Control.Lens as Lens import Control.Monad (zipWithM) import Control.Monad.Once (OnceT) import ...
7c512a73019806def8a52fcb88444112e12726efaa2538d322410f1bd4c6aaa3
glguy/toml-parser
TOML.hs
{-# Language Safe #-} | Module : TOML Description : for the TOML configuration language Copyright : ( c ) , 2017 License : ISC Maintainer : Parser for the TOML file format : < -lang/toml > Module : TOML Description : Parser for the TOML configuration language Copyright : (c) Er...
null
https://raw.githubusercontent.com/glguy/toml-parser/a338e635292fa96dbcf15313f0a27c3ae1110d1f/src/TOML.hs
haskell
# Language Safe # * Parsing * Values * Error information key-value pairs or returns an error.
| Module : TOML Description : for the TOML configuration language Copyright : ( c ) , 2017 License : ISC Maintainer : Parser for the TOML file format : < -lang/toml > Module : TOML Description : Parser for the TOML configuration language Copyright : (c) Eric Mertens, 2017 Licen...
5b7ad889293221eb5e0ee42c68f3ebea0f597de1934a22a7c6a73b69fee2a39e
cojna/iota
RangedSum.hs
# LANGUAGE MultiParamTypeClasses # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # module Data.Monoid.RangedSum where import Control.Monad import Data.Bits import qualified Data.Foldable as F import qualified Data.Vector.Generic as G import qualified Data.Vector.Generic.Mutable as GM import qualified Data....
null
https://raw.githubusercontent.com/cojna/iota/a64e8c5e4dd4f92e5ed3fcd0413be94ef1108f9e/src/Data/Monoid/RangedSum.hs
haskell
# LANGUAGE MultiParamTypeClasses # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # module Data.Monoid.RangedSum where import Control.Monad import Data.Bits import qualified Data.Foldable as F import qualified Data.Vector.Generic as G import qualified Data.Vector.Generic.Mutable as GM import qualified Data....
94c1cf9ac739e2436d1eb0b7fecee5a35934c6ee7a92ce4da6f245a34899143e
xh4/web-toolkit
attribute.lisp
(in-package :dom) (defclass attribute () ((name :initarg :name :initform nil :accessor attribute-name) (value :initarg :value :initform nil :accessor attribute-value))) (defclass named-node-map () ((element :initarg :element :initform nil) (attributes :initarg :attributes...
null
https://raw.githubusercontent.com/xh4/web-toolkit/e510d44a25b36ca8acd66734ed1ee9f5fe6ecd09/dom/attribute.lisp
lisp
TODO: check name
(in-package :dom) (defclass attribute () ((name :initarg :name :initform nil :accessor attribute-name) (value :initarg :value :initform nil :accessor attribute-value))) (defclass named-node-map () ((element :initarg :element :initform nil) (attributes :initarg :attributes...
2d79feed1a5cf1fb5a751434d40defc0e3dfed507583ea480647fe7ebf81b716
glguy/toml-parser
Components.hs
| Module : TOML.Components Description : /Internal:/ Type and operations for raw top - level TOML elements Copyright : ( c ) , 2017 License : ISC Maintainer : This module provides an intermediate representation for TOML files . The parser produces a list of top - level table components...
null
https://raw.githubusercontent.com/glguy/toml-parser/a338e635292fa96dbcf15313f0a27c3ae1110d1f/src/TOML/Components.hs
haskell
^ key value pairs before any @[header]@ ^ key value pairs after any @[header]@ | Non-empty list of table keys | Merge a list of top-level components into a single table, or throw an error with an ambiguous path. | Collapse the various components generated by the parser into a single list of path-value pairs. Thi...
| Module : TOML.Components Description : /Internal:/ Type and operations for raw top - level TOML elements Copyright : ( c ) , 2017 License : ISC Maintainer : This module provides an intermediate representation for TOML files . The parser produces a list of top - level table components...