_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
b6c8ec4321c8502c77e674c03c9b9ac63ad2af5ce8ea378b699cb9350f0ac9e5
gtod/postgres-json
filter.lisp
(defpackage :filtering (:use :cl :postgres-json)) (in-package :filtering) (define-global-model cat -cat- (pgj-object-model)) (defun setup () (ensure-top-level-connection) (ensure-backend -cat-)) (defun cleanup () (drop-backend -cat-)) (defmacro show (form) `(progn (print ',form) (pp-json ,form)...
null
https://raw.githubusercontent.com/gtod/postgres-json/a545b6c61ca6ee4c6a579c77dbe6856013c7c34f/examples/filter.lisp
lisp
Postgres top level property 'existence' operator, better called HAVING-PROPERTY Requires the (slower/bigger) jsonb_ops index A simple version could be implemented like so: (define-json-query filter ((*to-json* contains)) (:select 'jdoc :from 'cat :where (:@> 'jdoc contains))) When using containment it's...
(defpackage :filtering (:use :cl :postgres-json)) (in-package :filtering) (define-global-model cat -cat- (pgj-object-model)) (defun setup () (ensure-top-level-connection) (ensure-backend -cat-)) (defun cleanup () (drop-backend -cat-)) (defmacro show (form) `(progn (print ',form) (pp-json ,form)...
d33fb2e3ea37620e9c45fcea333723b6a7900c0d36b05250095bd6b7c09dc4e8
Liqwid-Labs/agora
Vote.hs
{- | Module : Sample.Proposal.Vote Maintainer : Description: Generate sample data for testing the functionalities of voting on proposals. Sample and utilities for testing the functionalities of voting on proposals. -} module Sample.Proposal.Vote ( ParameterBundle (..), VoteParameters (..), StakeParameters (....
null
https://raw.githubusercontent.com/Liqwid-Labs/agora/00c10198e86800aa59c107043e7961ee32d987a2/agora-specs/Sample/Proposal/Vote.hs
haskell
| Module : Sample.Proposal.Vote Maintainer : Description: Generate sample data for testing the functionalities of voting on proposals. Sample and utilities for testing the functionalities of voting on proposals. ------------------------------------------------------------------------------ ----------------------...
module Sample.Proposal.Vote ( ParameterBundle (..), VoteParameters (..), StakeParameters (..), StakeInputParameters (..), StakeOutputParameters (..), NumProposals (..), ProposalParameters (..), TransactionParameters (..), Validity (..), vote, mkTestTree, mkValidOwnerVoteBundle, mkValidDelegate...
0c8fb503e70eddb26ab70f29ff7c393c91ecb4725c4b70732583391ccfa4d4ac
chetmurthy/ensemble
iq.mli
(**************************************************************) IQ.MLI Author : , 4/95 (**************************************************************) open Trans (**************************************************************) lo read hi \/ \/ ...
null
https://raw.githubusercontent.com/chetmurthy/ensemble/8266a89e68be24a4aaa5d594662e211eeaa6dc89/ensemble/server/mm/iq.mli
ocaml
************************************************************ ************************************************************ ************************************************************ ************************************************************ Add returns the Iq. This is done for the functional * optimizations. T...
IQ.MLI Author : , 4/95 open Trans lo read hi \/ \/ \/ [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ] 0<-- reset -- > < ---- unset ... l...
5fa6c6afae5c87e5bdbadd2f2c000bcc2dcda8d36b3880a69b9a9fdc4a7b0e97
agrafix/Spock
CsrfSpec.hs
# LANGUAGE CPP # {-# LANGUAGE DoAndIfThenElse #-} {-# LANGUAGE OverloadedStrings #-} # LANGUAGE ScopedTypeVariables # module Web.Spock.CsrfSpec (spec) where #if MIN_VERSION_base(4,11,0) #else import Data.Monoid #endif import qualified Data.ByteString.Lazy as BSL import qualified Data.Text.Encoding as T import qualif...
null
https://raw.githubusercontent.com/agrafix/Spock/6055362b54f2fae5418188c3fc2fc1659ca43e79/Spock/test/Web/Spock/CsrfSpec.hs
haskell
# LANGUAGE DoAndIfThenElse # # LANGUAGE OverloadedStrings #
# LANGUAGE CPP # # LANGUAGE ScopedTypeVariables # module Web.Spock.CsrfSpec (spec) where #if MIN_VERSION_base(4,11,0) #else import Data.Monoid #endif import qualified Data.ByteString.Lazy as BSL import qualified Data.Text.Encoding as T import qualified Network.Wai as Wai import qualified Network.Wai.Test as Test hid...
5518bcaa7642a38523416162e2aabc96b6a7c3be1ce8ef76c5b821cd83661d87
cnuernber/depsviz
leiningen.clj
(ns cnuernber.depsviz.leiningen (:require [leiningen.core.user :as user] [leiningen.core.classpath :as classpath] [leiningen.core.project :as project] [leiningen.core.main :as main] [cemerick.pomegranate.aether :as aether] [cnuernber.depsviz.graph :as ...
null
https://raw.githubusercontent.com/cnuernber/depsviz/3b9f4314d828b55929c486bdd701f5dbb1a9a380/src/cnuernber/depsviz/leiningen.clj
clojure
(ns cnuernber.depsviz.leiningen (:require [leiningen.core.user :as user] [leiningen.core.classpath :as classpath] [leiningen.core.project :as project] [leiningen.core.main :as main] [cemerick.pomegranate.aether :as aether] [cnuernber.depsviz.graph :as ...
4be6f77b2fbde9d690c3d3cb7d1e4b6ffe1c9c12afa7236c16fdb758d3e9ccfd
septract/jstar-old
support_symex.ml
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * This file is part of jStar src / / support_symex.ml Release $ Release$ Version $ Rev$ $ Copyright$ jStar is distributed under a BSD license , see , ...
null
https://raw.githubusercontent.com/septract/jstar-old/c3b4fc6c1efc098efcdb864edbf0c666130f5fe5/src/jimplefront/support_symex.ml
ocaml
given a variable it returns its key to use in the table ============== Conversion facilities ================ int, long, float are all represented with the unary op "numeric_const". string constants with the unary op "string_const". In this way we abstract from the differen numerical values as well as different ...
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * This file is part of jStar src / / support_symex.ml Release $ Release$ Version $ Rev$ $ Copyright$ jStar is distributed under a BSD license , see , ...
b3418d9ac739841d670290bb9d883c241a04371db76b224f539658eeb8d67419
juspay/atlas
FareCalculator.hs
| Copyright 2022 Juspay Technologies Pvt Ltd Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not use this file except in compliance with the License . You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing , software dis...
null
https://raw.githubusercontent.com/juspay/atlas/e64b227dc17887fb01c2554db21c08284d18a806/app/atlas-transport/src/Product/FareCalculator.hs
haskell
| Copyright 2022 Juspay Technologies Pvt Ltd Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not use this file except in compliance with the License . You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing , software dis...
bb3bf681eeab836a96e22fe489c17adc1476517d6d87094f186f3b76f58670a4
bitblaze-fuzzball/fuzzball
linear_decision_tree.ml
Copyright ( C ) BitBlaze , 2010 - 2012 , and copyright ( C ) 2010 Ensighta Security Inc. All rights reserved . Copyright (C) BitBlaze, 2010-2012, and copyright (C) 2010 Ensighta Security Inc. All rights reserved. *) module V = Vine;; open Exec_exceptions;; open Exec_options;; class linear_decision_t...
null
https://raw.githubusercontent.com/bitblaze-fuzzball/fuzzball/b9a617b45e68fa732f1357fedc08a2a10f87a62c/execution/linear_decision_tree.ml
ocaml
Copyright ( C ) BitBlaze , 2010 - 2012 , and copyright ( C ) 2010 Ensighta Security Inc. All rights reserved . Copyright (C) BitBlaze, 2010-2012, and copyright (C) 2010 Ensighta Security Inc. All rights reserved. *) module V = Vine;; open Exec_exceptions;; open Exec_options;; class linear_decision_t...
c5ad4be7883ebab467624e3859cd17d8b8ea4af6653fa386634278413ad05c06
ktakashi/sagittarius-scheme
sasl.scm
-*- mode : scheme ; coding : utf-8 -*- ;;; ;;; rfc/sasl.scm - SASL framework ;;; Copyright ( c ) 2022 < > ;;; ;;; Redistribution and use in source and binary forms, with or without ;;; modification, are permitted provided that the following conditions ;;; are met: ;;; ;;; 1. Redistributions...
null
https://raw.githubusercontent.com/ktakashi/sagittarius-scheme/6dfef5ca3ae97de2d38d18e0ed9dcf5a079b2bf4/sitelib/rfc/sasl.scm
scheme
coding : utf-8 -*- rfc/sasl.scm - SASL framework Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of condition...
Copyright ( c ) 2022 < > " AS IS " AND ANY EXPRESS OR IMPLIED WARRANTIES , INCLUDING , BUT NOT SPECIAL , EXEMPLARY , OR CONSEQUENTIAL DAMAGES ( INCLUDING , BUT NOT LIMITED LIABILITY , WHETHER IN CONTRACT , STRICT LIABILITY , OR TORT ( INCLUDING #!nounbound (library (rfc sasl) (export :all) ...
8a462813aa295622e373a5ca78eea7d0a042e19d37867606f0a03f54b1ba7c3a
serokell/qtah
QMarginsF.hs
This file is part of Qtah . -- Copyright 2015 - 2018 The Qtah Authors . -- -- 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 , either version 3 of the License , or -- (at your option) ...
null
https://raw.githubusercontent.com/serokell/qtah/abb4932248c82dc5c662a20d8f177acbc7cfa722/qtah-generator/src/Graphics/UI/Qtah/Generator/Interface/Core/QMarginsF.hs
haskell
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 (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 MER...
This file is part of Qtah . Copyright 2015 - 2018 The Qtah Authors . the Free Software Foundation , either version 3 of the License , or GNU Lesser General Public License for more details . You should have received a copy of the GNU Lesser General Public License module Graphics.UI.Qtah.Generator.Interface.Co...
044e044f97dde3ff00b2883bda1b820dafd45904bff7d94937483e4eb0efc5dc
Deducteam/Dedukti
env.mli
* An environment is a wrapper around the kernel of open Kernel open Basic open Term open Parsers * { 2 Error Datatype } * An environment is created from a { ! Parser.input } . Environment is the module which interacts with the kernel . An environment allows you to change at runtime the reduction engine ...
null
https://raw.githubusercontent.com/Deducteam/Dedukti/abbe11318189c32ae236671ccd8dcf3c89525065/api/env.mli
ocaml
* [dummy ?m ()] returns a dummy environment. If [m] is provided, the environment is built from module [m], but without file. * Flag to check for variables arity. Default is true. * Flag to check for rules left linearity. Default is false * If [true], a symbol from an external module cannot be imported implici...
* An environment is a wrapper around the kernel of open Kernel open Basic open Term open Parsers * { 2 Error Datatype } * An environment is created from a { ! Parser.input } . Environment is the module which interacts with the kernel . An environment allows you to change at runtime the reduction engine ...
ab1748a06fd56605f3141f29a4f66ca9935c388cbdd9e1e9626303e3eb8a137b
ppedrot/ocaml-melt
bench.ml
(**************************************************************************) Copyright ( c ) 2009 , (* All rights reserved. *) (* *) (* Redistribution and use in source and binary forms, with...
null
https://raw.githubusercontent.com/ppedrot/ocaml-melt/0e58bb97e2afe2b7cadbaac906481f28cea1932e/bench/bench.ml
ocaml
************************************************************************ All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted...
Copyright ( c ) 2009 , " AS IS " AND ANY EXPRESS OR , INCLUDING , BUT NOT LIMITED TO , THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR OWNER OR FOR ANY DIRECT , INDIRECT , INCIDENTAL , SPECIAL , EXEMPLARY , OR CONSEQUENTIAL DAMAGES ( INCLUDING , BUT NOT DATA , OR PR...
0115272a0d8e2eb6c41e6f43e4b50527c20690a29777da4b751695b92ae6c67c
bef/poc-apps
fast_agi_socket.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.1 of the License , or ( at your option ) any later version . %%% %%% This library is distributed in the hope th...
null
https://raw.githubusercontent.com/bef/poc-apps/754c308f0f170a3dd766f828fff7081122867f8b/lib/erlast/lib/fast_agi/src/fast_agi_socket.erl
erlang
This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU...
License as published by the Free Software Foundation ; either version 2.1 of the License , or ( at your option ) any later version . You should have received a copy of the GNU Lesser General Public Foundation , Inc. , 59 Temple Place , Suite 330 , Boston , MA 02111 - 1307 USA Created : 30 Mar 2006 @autho...
59054aa431a6f1b56e37b3af019eb23ce12ba0fb3861665d2964782c41e32cca
jyh/metaprl
itt_vec_flat_sequent_term.mli
* Flattened forms of sequents where the hyps are lists . * * ---------------------------------------------------------------- * * @begin[license ] * Copyright ( C ) 2006 Mojave Group , Caltech * * This program is free software ; you can redistribute it and/or * modify it under the terms of th...
null
https://raw.githubusercontent.com/jyh/metaprl/51ba0bbbf409ecb7f96f5abbeb91902fdec47a19/theories/itt/reflection/obsolete_flat/itt_vec_flat_sequent_term.mli
ocaml
* Append forms. * Tactics.
* Flattened forms of sequents where the hyps are lists . * * ---------------------------------------------------------------- * * @begin[license ] * Copyright ( C ) 2006 Mojave Group , Caltech * * This program is free software ; you can redistribute it and/or * modify it under the terms of th...
0eb5eb0fb3adf2e31d15ca1741c370a14b018b2b52b170c8ba66e3046222311c
haskell/haskell-ide-engine
Ghc.hs
# LANGUAGE CPP # {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE OverloadedStrings #-} # LANGUAGE TypeFamilies # # LANGUAGE LambdaCase # | This module provides the interface to GHC , mainly for loading -- modules while updating the module cache. module Haskell.Ide.Engine.Ghc ...
null
https://raw.githubusercontent.com/haskell/haskell-ide-engine/d84b84322ccac81bf4963983d55cc4e6e98ad418/hie-plugin-api/Haskell/Ide/Engine/Ghc.hs
haskell
# LANGUAGE FlexibleContexts # # LANGUAGE OverloadedStrings # modules while updating the module cache. , cabalModuleGraphs to do with BIOS import GhcMake ( moduleGraphNodes ) --------------------------------------------------------------------- -----------------------------------------------------------------...
# LANGUAGE CPP # # LANGUAGE TypeFamilies # # LANGUAGE LambdaCase # | This module provides the interface to GHC , mainly for loading module Haskell.Ide.Engine.Ghc ( setTypecheckedModule , Diagnostics(..) , AdditionalErrs , makeRevRedirMapFunc ) where import Debug.Trac...
f1f1708e81eafcf604169e3570bad12cd3c8f2e3cd11677db83d88a68b0fa344
mtgred/netrunner
nrdb.clj
(ns tasks.nrdb "NetrunnerDB import tasks" (:require ;; external [org.httpkit.client :as http] [org.httpkit.sni-client :as sni-client] [monger.collection :as mc] [monger.operators :refer [$exists $inc $currentDate]] [throttler.core :refer [throttle-fn]] [clojure.java.io :as io] [cloju...
null
https://raw.githubusercontent.com/mtgred/netrunner/bded4d2b793d503083b603c238dc321f17d9c604/src/clj/tasks/nrdb.clj
clojure
external internal these are cards with multiple faces, so we can't download them directly wait for all the GETs to complete
(ns tasks.nrdb "NetrunnerDB import tasks" (:require [org.httpkit.client :as http] [org.httpkit.sni-client :as sni-client] [monger.collection :as mc] [monger.operators :refer [$exists $inc $currentDate]] [throttler.core :refer [throttle-fn]] [clojure.java.io :as io] [clojure.edn :as edn] ...
31806c2e7c0c21531dcdc7d5f88c6dd6ccfc3d568af453acdf7cb06ea66ff06a
mmottl/ocaml-prog-pats
union_find.ml
NOTE : This does not work yet due to an OCaml bug . May get fixed in OCaml 4.08 . OCaml 4.08. *) (* type ('a, 'kind) tree = *) (* | Root : { mutable value : 'a; mutable rank : int } -> ('a, [ `root ]) tree *) (* | Inner : { mutable parent : 'a node } -> ('a, [ `inner ]) tree *) (* *) and ' a node = ...
null
https://raw.githubusercontent.com/mmottl/ocaml-prog-pats/cc01cad585743798213f82996acf423335dfde5d/union_find/union_find.ml
ocaml
type ('a, 'kind) tree = | Root : { mutable value : 'a; mutable rank : int } -> ('a, [ `root ]) tree | Inner : { mutable parent : 'a node } -> ('a, [ `inner ]) tree type 'a t = ('a, [ `inner ]) tree Avoids compression call
NOTE : This does not work yet due to an OCaml bug . May get fixed in OCaml 4.08 . OCaml 4.08. *) and ' a node = Node : ( ' a , _ ) tree - > ' a node [ @@ocaml.unboxed ] type ('a, 'kind, 'parent) tree = | Root : { mutable value : 'a; mutable rank : int } -> ('a, [ `root ], 'parent) tree | Inne...
b5959db9a448471fb4a67980d12f32984760b70b31ffe504a22123dddb127726
sgbj/MaximaSharp
rand-mt19937.lisp
MT19937 , adapted from CMUCL rand-mt19937.lisp -r1.11 ( 2003/03/06 ) CMUCL version by and based on public domain code from Carnegie Mellon University . Modified for Maxima by . ( 1 ) Construct floating point numbers using portable operations . ( 2 ) Construct large integers using all bits of each ...
null
https://raw.githubusercontent.com/sgbj/MaximaSharp/75067d7e045b9ed50883b5eb09803b4c8f391059/Test/bin/Debug/Maxima-5.30.0/share/maxima/5.30.0/src/rand-mt19937.lisp
lisp
Begin MT19937 implementation. ********************************************************************** Support for the Mersenne Twister, MT19937, random number generator Random state hackery: wrapped in a random-state structure: GENERATE-SEED Generate a random seed that can be used for seeding the generator. ...
MT19937 , adapted from CMUCL rand-mt19937.lisp -r1.11 ( 2003/03/06 ) CMUCL version by and based on public domain code from Carnegie Mellon University . Modified for Maxima by . ( 1 ) Construct floating point numbers using portable operations . ( 2 ) Construct large integers using all bits of each ...
e3d75007575b84b906d16ea12541760413180802a1fed4c4f99d5478ba917a14
exercism/common-lisp
sublist.lisp
(defpackage :sublist (:use :cl) (:export :sublist)) (in-package :sublist) (defun sublist (list1 list2) "what is list1 of list2 (sublist, superlist, equal or unequal)")
null
https://raw.githubusercontent.com/exercism/common-lisp/f3cdf6cf7e607138d1bb4d26c57999d4364af243/exercises/practice/sublist/sublist.lisp
lisp
(defpackage :sublist (:use :cl) (:export :sublist)) (in-package :sublist) (defun sublist (list1 list2) "what is list1 of list2 (sublist, superlist, equal or unequal)")
0737ea293c26d93bd4ecae73b7d7cad0da1bb422222b996fd01ba1487ba45cce
dmjio/aoc2020
Main.hs
{-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE BangPatterns #-} # LANGUAGE ViewPatterns # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE TypeApplications # # LANGUAGE ScopedTypeVariables # module Main where import Control.Monad import Data.Bits import Data.Char impo...
null
https://raw.githubusercontent.com/dmjio/aoc2020/83c1d55a2dad3b2318666debaf18b5368cff8738/4/Main.hs
haskell
# LANGUAGE FlexibleContexts # # LANGUAGE BangPatterns # # LANGUAGE OverloadedStrings #
# LANGUAGE ViewPatterns # # LANGUAGE TypeApplications # # LANGUAGE ScopedTypeVariables # module Main where import Control.Monad import Data.Bits import Data.Char import Data.List import Data.List.Split import qualified Data.Map.Strict as M import ...
bc99de0a4150e1b4d819c941f68190ded6e2e4c687c3ceec731542851a62d240
etorreborre/registry
SpecializationSpec.hs
# LANGUAGE DataKinds # # LANGUAGE IncoherentInstances # # LANGUAGE PartialTypeSignatures # # LANGUAGE RecordWildCards # # OPTIONS_GHC -fno - warn - missing - signatures # # OPTIONS_GHC -fno - warn - partial - type - signatures # module Test.Data.Registry.Make.SpecializationSpec where import Control.Monad.Trans.Resour...
null
https://raw.githubusercontent.com/etorreborre/registry/a35ce1d999a9567a88ee8d63c71bd4cb540476bc/test/Test/Data/Registry/Make/SpecializationSpec.hs
haskell
the one that is the children of the other in the current context wins duplicated because it is on the path of the specialization we want the following graph -------- Base ------------+ -------- Base ------------+ we want the following graph -------- -----------+----- > ( config3 : : Config ) ------...
# LANGUAGE DataKinds # # LANGUAGE IncoherentInstances # # LANGUAGE PartialTypeSignatures # # LANGUAGE RecordWildCards # # OPTIONS_GHC -fno - warn - missing - signatures # # OPTIONS_GHC -fno - warn - partial - type - signatures # module Test.Data.Registry.Make.SpecializationSpec where import Control.Monad.Trans.Resour...
7e4ab18436b52c853ccfa86efca47d1eafdff42211ad2dcd198cbd91b622e59b
KirinDave/fuzed
response_error_logger.erl
-module(response_error_logger). -behaviour(gen_server). % API Exports -export([start_link/1, start/1, is_active/0, set_active/1, logfile_name/0, log_error/2]). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). -record(state, {fname = "/p/log/fuzed/response_...
null
https://raw.githubusercontent.com/KirinDave/fuzed/56098d9e4c139613845289bdd5acebdfe608981a/elibs/response_error_logger.erl
erlang
API Exports External API ... Calls Casts Calls. Most of these are just introspection. Casts. Most of the meat goes here. I know that in the future I will regret it.
-module(response_error_logger). -behaviour(gen_server). -export([start_link/1, start/1, is_active/0, set_active/1, logfile_name/0, log_error/2]). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). -record(state, {fname = "/p/log/fuzed/response_errors.log", ...
a48137afb352e8b08f468ac78910d2f7973d432908ab79a8f6beb8260bd73817
GregorySchwartz/too-many-cells
Adjacency.hs
TooManyCells . MakeTree . Adjacency Collects functions pertaining to calculating similarities and adjacency matrices . Gregory W. Schwartz Collects functions pertaining to calculating similarities and adjacency matrices. -} module TooManyCells.MakeTree.Adjacency ( cosineSimilarityDense , cosineS...
null
https://raw.githubusercontent.com/GregorySchwartz/too-many-cells/0de948c6e99a489f1d2e8c412a04e4bcf3b26806/src/TooManyCells/MakeTree/Adjacency.hs
haskell
Remote Local | Get an adjacency matrix based on a matrix where each row is an observation and the adjacencies are cosine similarities. | Get an adjacency matrix based on a matrix where each row is an observation and the adjacencies are cosine similarities.
TooManyCells . MakeTree . Adjacency Collects functions pertaining to calculating similarities and adjacency matrices . Gregory W. Schwartz Collects functions pertaining to calculating similarities and adjacency matrices. -} module TooManyCells.MakeTree.Adjacency ( cosineSimilarityDense , cosineS...
5dc461fabf61dce6e64e342c08c6e95280eacfe977d3bd000597afcc60206314
ingesolvoll/kee-frame
controller_test.cljc
(ns kee-frame.controller-test (:require [clojure.test :refer [deftest testing is]] [kee-frame.controller :as c])) (deftest compact-syntax (testing "Can start and stop" (let [controllers [{:id :my-controller :params #(-> % :handler (= :some-page) (or nil)) ...
null
https://raw.githubusercontent.com/ingesolvoll/kee-frame/e77a672ca1a913b7eedd5b2e65af47a497755426/test/kee_frame/controller_test.cljc
clojure
(ns kee-frame.controller-test (:require [clojure.test :refer [deftest testing is]] [kee-frame.controller :as c])) (deftest compact-syntax (testing "Can start and stop" (let [controllers [{:id :my-controller :params #(-> % :handler (= :some-page) (or nil)) ...
29f794d1b0997a432f1e45239a5b048fff4e84fab4389ec948e5e733900c0807
byorgey/thesis
Tree.hs
{-# LANGUAGE DeriveDataTypeable #-} # LANGUAGE FlexibleInstances # # LANGUAGE NoImplicitPrelude # {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE TypeFamilies #-} # LANGUAGE UndecidableInstances # import Diagrams.TwoD.Layout.Tree import Math.Combinatorics.Species import ...
null
https://raw.githubusercontent.com/byorgey/thesis/b60af0501cdb2d1154d9303694884f461c0e499a/proposal/Tree.hs
haskell
# LANGUAGE DeriveDataTypeable # # LANGUAGE TemplateHaskell # # LANGUAGE TypeFamilies #
# LANGUAGE FlexibleInstances # # LANGUAGE NoImplicitPrelude # # LANGUAGE UndecidableInstances # import Diagrams.TwoD.Layout.Tree import Math.Combinatorics.Species import NumericPrelude data Tree a = E | B (Tree a) a (Tree a) deriveDefaultSpecies ''Tree
6ca35ff2f3cf97164a31ad1fbb60394aff2032117b18318993b36112ba4126f4
roosta/tincture
events_test.cljs
(ns tincture.events-test (:require [cljs.test :refer-macros [deftest testing is async]] [re-frame.core :as rf] [dommy.core :as dommy :refer-macros [sel1 sel]] [day8.re-frame.test :as rf-test] [tincture.events :as e] )) (rf/reg-sub :test/db (fn [db] db)) ...
null
https://raw.githubusercontent.com/roosta/tincture/587e68248dae09616942dc23bbd97cb9a1a4caa2/test/tincture/events_test.cljs
clojure
(ns tincture.events-test (:require [cljs.test :refer-macros [deftest testing is async]] [re-frame.core :as rf] [dommy.core :as dommy :refer-macros [sel1 sel]] [day8.re-frame.test :as rf-test] [tincture.events :as e] )) (rf/reg-sub :test/db (fn [db] db)) ...
3a72866c2500623d47fb6f95e20a5f14873e5265dc431e3de8c15b708c1478c5
pariyatti/kosa
file_fixtures.clj
(ns kosa.fixtures.file-fixtures (:require [babashka.fs :as fs])) (defn file [filename] (fs/file (fs/path "test/kosa/fixtures/files" filename)))
null
https://raw.githubusercontent.com/pariyatti/kosa/ce1e7ccbb77cbc78ba1d2d13da36ef78256e4a3b/test/kosa/fixtures/file_fixtures.clj
clojure
(ns kosa.fixtures.file-fixtures (:require [babashka.fs :as fs])) (defn file [filename] (fs/file (fs/path "test/kosa/fixtures/files" filename)))
4c0bb67d928152e6728951cf916abcd1dc4526a0f2d4bf0803c26155026c1f56
wilkerlucio/pathom
reakit.cljs
(ns com.wsscode.fulcro.ui.reakit (:refer-clojure :exclude [list]) (:require ["reakit" :as rk] [com.wsscode.fulcro.ui.core :as uc] [fulcro.client.primitives :as fp] [fulcro.client.localized-dom :as dom])) (def arrow (uc/wrap-react-component-localized rk/Arrow)) (def backdrop (uc/...
null
https://raw.githubusercontent.com/wilkerlucio/pathom/4ec25055d3d156241e9174d68ec438c93c971b9b/workspaces/src/com/wsscode/fulcro/ui/reakit.cljs
clojure
(ns com.wsscode.fulcro.ui.reakit (:refer-clojure :exclude [list]) (:require ["reakit" :as rk] [com.wsscode.fulcro.ui.core :as uc] [fulcro.client.primitives :as fp] [fulcro.client.localized-dom :as dom])) (def arrow (uc/wrap-react-component-localized rk/Arrow)) (def backdrop (uc/...
3d1bd7965ec9f34c409a63fbb3214ade0e36aad68870666cd1d20035ede473d8
yashrk/raylib-scm
color_select.scm
(include "raylib-definitions.scm") (import defstruct raylib-scm srfi-1) (use raylib-scm srfi-1) (define screen-width 800) (define screen-height 450) (defstruct crect color selected rect) (define colors (list DARKGRAY MAROON ORANGE DARKGREEN DARKBLUE DAR...
null
https://raw.githubusercontent.com/yashrk/raylib-scm/b4c6fe17374ce4ddd4162fda37f4691b1e35b5f2/examples/core/color_select/color_select.scm
scheme
(include "raylib-definitions.scm") (import defstruct raylib-scm srfi-1) (use raylib-scm srfi-1) (define screen-width 800) (define screen-height 450) (defstruct crect color selected rect) (define colors (list DARKGRAY MAROON ORANGE DARKGREEN DARKBLUE DAR...
ef1f95605f7f70f2adb72246319facc2e69add46cec31d5c7ba29dd0aa562665
joneshf/open-source
Lint.hs
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # {-# LANGUAGE PackageImports #-} # LANGUAGE TypeApplications # module Shake.Go.Lint (rules) where import "mtl" Control.Monad.Reader (ReaderT, asks, lift) import "shake" Development.Shake ( CmdOption(Traced) , Rules , cmd_ , copyFileChanged ...
null
https://raw.githubusercontent.com/joneshf/open-source/e3412fc68c654d89a8d3af4e12ac19c70e3055ec/Shake/Go/Lint.hs
haskell
# LANGUAGE PackageImports #
# LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # # LANGUAGE TypeApplications # module Shake.Go.Lint (rules) where import "mtl" Control.Monad.Reader (ReaderT, asks, lift) import "shake" Development.Shake ( CmdOption(Traced) , Rules , cmd_ , copyFileChanged , need , (%>) , (<//>) ...
6e27568b1a196a96746060f2df3cbbad77cc64f4ffcc2877ddb86ec34e36be2b
awslabs/s2n-bignum
bignum_montmul_p384_alt.ml
* Copyright Amazon.com , Inc. or its affiliates . All Rights Reserved . * SPDX - License - Identifier : Apache-2.0 OR ISC * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 OR ISC *) (* =================================================================...
null
https://raw.githubusercontent.com/awslabs/s2n-bignum/824c15f908d7a343af1b2f378cfedd36e880bdde/arm/proofs/bignum_montmul_p384_alt.ml
ocaml
========================================================================= ========================================================================= *** print_literal_from_elf "arm/p384/bignum_montmul_p384_alt.o";; *** arm_ADDS X13 X13 X11 arm_ADC X19 X19 XZR arm_ADDS X13 X13 X11 arm_ADCS X19 X19 X11 arm_A...
* Copyright Amazon.com , Inc. or its affiliates . All Rights Reserved . * SPDX - License - Identifier : Apache-2.0 OR ISC * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 OR ISC *) Montgomery multiplication modulo p_384 . ...
0e4638f080aa18610f9488ec1e9ddb31601fb7442e40985bb611b104b17f0ea5
lspitzner/pqueue
Foldable.hs
-- | Writing 'Foldable' instances for non-regular (AKA, nested) types in the natural manner leads to full ` Foldable ` dictionaries being constructed on -- each recursive call. This is pretty inefficient. It's better to construct -- exactly what we need instead. module Data.PQueue.Internals.Foldable ( Foldr (..) ...
null
https://raw.githubusercontent.com/lspitzner/pqueue/d723ff79cbf8ab52e57c22a1ff7ab580f47f8a5a/src/Data/PQueue/Internals/Foldable.hs
haskell
| Writing 'Foldable' instances for non-regular (AKA, nested) types in the each recursive call. This is pretty inefficient. It's better to construct exactly what we need instead.
natural manner leads to full ` Foldable ` dictionaries being constructed on module Data.PQueue.Internals.Foldable ( Foldr (..) , Foldl (..) , FoldMap (..) , Foldl' (..) , IFoldr (..) , IFoldl (..) , IFoldMap (..) , IFoldl' (..) ) where class Foldr t where foldr_ :: (a -> b -> b) -> b -> t a -> b ...
d1210c6e2f9b7a3cdece86cc6b4f94ed6b67143522b29c0bfa59ed9d276746d8
ocamllabs/ocaml-modular-implicits
reg.mli
(***********************************************************************) (* *) (* OCaml *) (* *) , projet ...
null
https://raw.githubusercontent.com/ocamllabs/ocaml-modular-implicits/92e45da5c8a4c2db8b2cd5be28a5bec2ac2181f1/asmcomp/reg.mli
ocaml
********************************************************************* OCaml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et en Automatique . All rights reserved . This file is distributed under the terms of the Q Public License version 1.0 . module Raw_name : sig type t val c...
4e3bc836f269358cdb2eb4bf04b1ccd23f1cf232e4cc6a0b3b7df84721039952
morpheusgraphql/morpheus-graphql
Arguments.hs
# LANGUAGE FlexibleContexts # # LANGUAGE NoImplicitPrelude # module Data.Morpheus.Parsing.Internal.Arguments (maybeArguments) where MORPHEUS import Data.Morpheus.Parsing.Internal.Internal ( Parser, getLocation, ) import Data.Morpheus.Parsing.Internal.Terms ( colon, parseName, uniqTupleOpt, ) imp...
null
https://raw.githubusercontent.com/morpheusgraphql/morpheus-graphql/f9684d1451fd4ee3aabdb821424fd352003a3982/morpheus-graphql-core/src/Data/Morpheus/Parsing/Internal/Arguments.hs
haskell
Arguments : -spec/June2018/#sec-Language.Arguments Arguments[Const] Argument[Const] Name : Value[Const]
# LANGUAGE FlexibleContexts # # LANGUAGE NoImplicitPrelude # module Data.Morpheus.Parsing.Internal.Arguments (maybeArguments) where MORPHEUS import Data.Morpheus.Parsing.Internal.Internal ( Parser, getLocation, ) import Data.Morpheus.Parsing.Internal.Terms ( colon, parseName, uniqTupleOpt, ) imp...
8973ecada392c13e2d99217ee8c13897b692457aafc02838dac4a5b99c7b1dab
pepeiborra/narradar
Goal.hs
# LANGUAGE TypeFamilies # # LANGUAGE OverlappingInstances , FlexibleInstances # # LANGUAGE StandaloneDeriving # module Narradar.Types.Goal where import Control.Applicative hiding (Alternative(..), many, optional) import Control.DeepSeq import Data.Bifunctor import qualified Data.Set as Set import Data.Term.Rules impor...
null
https://raw.githubusercontent.com/pepeiborra/narradar/bc53dcad9aee480ab3424a75239bac67e4794456/src/Narradar/Types/Goal.hs
haskell
# LANGUAGE TypeFamilies # # LANGUAGE OverlappingInstances , FlexibleInstances # # LANGUAGE StandaloneDeriving # module Narradar.Types.Goal where import Control.Applicative hiding (Alternative(..), many, optional) import Control.DeepSeq import Data.Bifunctor import qualified Data.Set as Set import Data.Term.Rules impor...
82b526fc62ef9a6ec83399a14693150a62592737dcaf15cec288eddb1d79550d
jbclements/sxml
multi-parser.rkt
#lang racket/base (require "myenv.ss" srfi/13/string "parse-error.ss" "SSAX-code.ss" "ssax-prim.ss" "id.ss" "xlink-parser.ss") (provide parent:new-level-seed-handler parent:construct-element ssax:multi-parser) ;; SSAX multi parser Provides ID - ...
null
https://raw.githubusercontent.com/jbclements/sxml/d3b8570cf7287c4e06636e17634f0f5c39203d52/sxml/ssax/multi-parser.rkt
racket
SSAX multi parser This software is in Public Domain. Please send bug reports and comments to: Dmitry Lizorkin Primary features: '() '(parent) '(id) '(parent id) '(id xlink) '(parent id xlink) ===================================...
#lang racket/base (require "myenv.ss" srfi/13/string "parse-error.ss" "SSAX-code.ss" "ssax-prim.ss" "id.ss" "xlink-parser.ss") (provide parent:new-level-seed-handler parent:construct-element ssax:multi-parser) Provides ID - index creation , SXML...
42245fb051d4b18e15174a77b72e53dbe164198fb429a28f7979f2768bdb6549
BinaryAnalysisPlatform/bap
bap_memory.mli
open Core_kernel[@@warning "-D"] open Bap_core_theory open Regular.Std open Bap_types.Std open Image_common type t [@@deriving bin_io, sexp_of] val create : ?pos:int (** defaults to [0] *) -> ?len:int (** defaults to full length *) -> endian -> addr -> Bigstring.t ->...
null
https://raw.githubusercontent.com/BinaryAnalysisPlatform/bap/253afc171bbfd0fe1b34f6442795dbf4b1798348/lib/bap_image/bap_memory.mli
ocaml
* defaults to [0] * defaults to full length
open Core_kernel[@@warning "-D"] open Bap_core_theory open Regular.Std open Bap_types.Std open Image_common type t [@@deriving bin_io, sexp_of] val create -> endian -> addr -> Bigstring.t -> t Or_error.t val rebase : t -> addr -> t val slot : (Theory.program, t option) KB.slot val of_file : endian -> addr -...
e64a6425b0da46585924b410ee5ce18c15bed1a3cbb2d431bf0351b76783a4cf
albertoruiz/easyVision
blur.hs
# LANGUAGE TemplateHaskell , RecordWildCards # import Vision.GUI.Simple import Image import Image.Devel(gray2float,float2gray) import Numeric.LinearAlgebra ((<>),ident) import Vision(ht,desp,scaling,kgen) import Util.Rotation import Util.Misc(degree) import Util.Geometry(Polyline(..)) import qualified OpenCV autoPara...
null
https://raw.githubusercontent.com/albertoruiz/easyVision/26bb2efaa676c902cecb12047560a09377a969f2/projects/opencv/blur.hs
haskell
# LANGUAGE TemplateHaskell , RecordWildCards # import Vision.GUI.Simple import Image import Image.Devel(gray2float,float2gray) import Numeric.LinearAlgebra ((<>),ident) import Vision(ht,desp,scaling,kgen) import Util.Rotation import Util.Misc(degree) import Util.Geometry(Polyline(..)) import qualified OpenCV autoPara...
6f409e3391042f3120fc6bce1995ee93f2f3f14933e177b0b5f4fb80653e475c
danehuang/augurv2
TypSyn.hs
- Copyright 2017 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...
null
https://raw.githubusercontent.com/danehuang/augurv2/480459bcc2eff898370a4e1b4f92b08ea3ab3f7b/compiler/augur/src/Comm/TypSyn.hs
haskell
-------------------------------------------------------------------- | [Note] Common type syntax. --------------------------------- == Instances
- Copyright 2017 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...
78774fc935cc25cb14bd248cb994b35dd701320562f50d59c326db3263dc26d3
pgj/mirage-kfreebsd
printf.mli
(***********************************************************************) (* *) (* Objective Caml *) (* *) and , projet Cris...
null
https://raw.githubusercontent.com/pgj/mirage-kfreebsd/0ff5b2cd7ab0975e3f2ee1bd89f8e5dbf028b102/packages/mirage-stdlib/src/printf.mli
ocaml
********************************************************************* Objective Caml ...
and , projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et en Automatique . All rights reserved . This file is distributed under the terms of the GNU Library General Public License , with $ I d : printf.mli 10968 2011 - 03 - 06 16:10:5...
ee92e4a4c884ef0c8065163dd2d495f38a83567846508ab740946ec43831fe4f
McCLIM/McCLIM
parsers.lisp
;;; --------------------------------------------------------------------------- ;;; License: LGPL-2.1+ (See file 'Copyright' for details). ;;; --------------------------------------------------------------------------- ;;; ( c ) copyright 1998,1999,2000 by ( ) ( c ) copyright 2000 by ( ) ( c ) copyrigh...
null
https://raw.githubusercontent.com/McCLIM/McCLIM/282753392aab1d1c25e9f61a8285647387ae1c70/Core/clim-core/commands/parsers.lisp
lisp
--------------------------------------------------------------------------- License: LGPL-2.1+ (See file 'Copyright' for details). --------------------------------------------------------------------------- --------------------------------------------------------------------------- Implementation of the comma...
( c ) copyright 1998,1999,2000 by ( ) ( c ) copyright 2000 by ( ) ( c ) copyright 2002 by ( ) (in-package #:clim-internals) (defvar *unsupplied-argument-marker* '%unsupplied-argument-marker%) (defun unsupplied-argument-p (val) (eq *unsupplied-argument-marker* val)) (defclass command-parsers ()...
3ae1abc058672a07b3455424a8e7018baa03e2145597bbeffc11b5d1a901ba9f
michaelklishin/neocons
spatial_test.clj
Copyright ( c ) 2011 - 2018 , , and The ClojureWerkz Team ;; ;; The use and distribution terms for this software are covered by the Eclipse Public License 1.0 ( -1.0.php ) ;; which can be found in the file epl-v10.html at the root of this distribution. ;; By using this software in any fashion, you are agreei...
null
https://raw.githubusercontent.com/michaelklishin/neocons/30f30e95686a01f7a34082600bc1221877c2acbd/test/clojurewerkz/neocons/rest/test/spatial_test.clj
clojure
The use and distribution terms for this software are covered by the which can be found in the file epl-v10.html at the root of this distribution. By using this software in any fashion, you are agreeing to be bound by the terms of this license. You must not remove this notice, or any other, from this software.
Copyright ( c ) 2011 - 2018 , , and The ClojureWerkz Team Eclipse Public License 1.0 ( -1.0.php ) (ns clojurewerkz.neocons.rest.test.spatial-test (:require [clojurewerkz.neocons.rest :as neorest] [clojurewerkz.neocons.rest.nodes :as nodes] [clojurewerkz.neocon...
e2c5af803d1364a1d6db006153f6b4d254ab81ddb2ba7e835025972328183504
7c6f434c/lang-os
network.lisp
(defpackage :lisp-os-helpers/network (:use :common-lisp :lisp-os-helpers/shell :lisp-os-helpers/daemon) (:export #:parsed-ip-address-show #:add-ip-address #:remove-ip-address #:flush-ip-addresses #:enable-ip-link #:disable-ip-link #:run-link-dhclient #:stop-link-dhclient ...
null
https://raw.githubusercontent.com/7c6f434c/lang-os/77a411b1310aae2dfd1cc8a19c12b050abc77e68/lisp-os-helpers/network.lisp
lisp
(defpackage :lisp-os-helpers/network (:use :common-lisp :lisp-os-helpers/shell :lisp-os-helpers/daemon) (:export #:parsed-ip-address-show #:add-ip-address #:remove-ip-address #:flush-ip-addresses #:enable-ip-link #:disable-ip-link #:run-link-dhclient #:stop-link-dhclient ...
c36c2558b715cf71f2d7410da8c946b3f036dc6268e7fb8134f41df4dc1b9fe9
huangjs/cl
direct.lisp
; *************************************************************** ; * MODULE SYM * * MANIPULATIONS DE FONCTIONS SYMETRIQUES * * ( version01 : Commonlisp pour Maxima ) * ; * ...
null
https://raw.githubusercontent.com/huangjs/cl/96158b3f82f82a6b7d53ef04b3b29c5c8de2dbf7/lib/maxima/share/sym/direct.lisp
lisp
*************************************************************** * MODULE SYM * * * * ---------------------- * * LITP (Equipe Ca...
* MANIPULATIONS DE FONCTIONS SYMETRIQUES * * ( version01 : Commonlisp pour Maxima ) * * * * GDR MEDICIS * * ( Mathe'matiques Effectives , , * * ...
54fbd449766d42c006bd528c58c21f338217e1394fa1245eb2e143cf9746ac8d
alanzplus/EOPL
a10.rkt
#lang racket (require "mk.rkt") (require "numbers.rkt") ;; Part I Write the answers to the following problems using your knowledge of miniKanren . For each problem , explain how miniKanren ;; arrived at the answer. You will be graded on the quality of your ;; explanation; a full explanation will require several s...
null
https://raw.githubusercontent.com/alanzplus/EOPL/d7b06392d26d93df851d0ca66d9edc681a06693c/Indiana-CS311/a10-Introduction%20to%20Logic%20Programming/a10.rkt
racket
Part I Write the answers to the following problems using your arrived at the answer. You will be graded on the quality of your explanation; a full explanation will require several sentences. a == b =/= c absento d numbero Part II goes here.
#lang racket (require "mk.rkt") (require "numbers.rkt") knowledge of miniKanren . For each problem , explain how miniKanren 1 What is the value of (run 2 (q) (== 5 q) (conde [(conde [(== 5 q) (== 6 q)]) (== 5 q)] [(== q 5)])) 2 What is the value of (run 1 (q) (fresh (a b) (...
a97542601716a403f93ba5ec73b7321a9ab373ee3c810599333220a1d8f4b42e
jwiegley/hierarchy
Cond.hs
# LANGUAGE CPP # # LANGUAGE DeriveFunctor # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE RankNTypes #-} # LANGUAGE RecursiveDo # # LANGUAGE TupleSections # # LANGUAGE TypeFamilies # # LA...
null
https://raw.githubusercontent.com/jwiegley/hierarchy/8c1a730605fef59e655c258684e89f5a7151d275/src/Control/Cond.hs
haskell
# LANGUAGE RankNTypes # * Promotions * Basic conditionals * Boolean logic * helper functions # INLINE (<>) # # INLINE accept' # # INLINE recurse' # an item of type 'a': that item passes the predicate, and/or if recursion should be performed from that item, should it relate to the branch of a tree. This is used t...
# LANGUAGE CPP # # LANGUAGE DeriveFunctor # # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # # LANGUAGE MultiParamTypeClasses # # LANGUAGE RecursiveDo # # LANGUAGE TupleSections # # LANGUAGE TypeFamilies # # LANGUAGE UndecidableInstances ...
d67485a76c010b380af8f3a4dd7bad8251ec9775be7866f88f108dda892db709
cbaggers/daft
collision.lisp
(in-package :daft) ;;------------------------------------------------------------ (defun touching-p (&optional set-of-actors/actor-kind) (let ((self *self*) (scene *current-scene*) (target set-of-actors/actor-kind)) (if (and target (symbolp target)) (%touching-kind-p scene self target) ...
null
https://raw.githubusercontent.com/cbaggers/daft/62c4b8b883469eb121b55403b6afabad5052b204/src/collision/collision.lisp
lisp
------------------------------------------------------------ ------------------------------------------------------------ ------------------------------------------------------------
(in-package :daft) (defun touching-p (&optional set-of-actors/actor-kind) (let ((self *self*) (scene *current-scene*) (target set-of-actors/actor-kind)) (if (and target (symbolp target)) (%touching-kind-p scene self target) (%touching-set-p scene self target)))) (defun %touching...
79f07e8dcb5a018660c32076a923063386e334c9bdc3d019d1e9f0a2e0190c5a
charlieg/Sparser
defining-other-words.lisp
;;; -*- Mode:LISP; Syntax:Common-Lisp; Package:(SPARSER LISP) -*- copyright ( c ) 1995 -- all rights reserved ;;; ;;; File: "defining other words" Module : " : " version : April 1995 initiated 4/12/95 (in-package :sparser) ;;;------------------------------------------ routines used ...
null
https://raw.githubusercontent.com/charlieg/Sparser/b9bb7d01d2e40f783f3214fc104062db3d15e608/Sparser/code/s/interface/grammar/defining-other-words.lisp
lisp
-*- Mode:LISP; Syntax:Common-Lisp; Package:(SPARSER LISP) -*- File: "defining other words" ------------------------------------------ ------------------------------------------ These are called from Save-word-definition after the dossier has been opened and set to the stream and the date information has b...
copyright ( c ) 1995 -- all rights reserved Module : " : " version : April 1995 initiated 4/12/95 (in-package :sparser) routines used by the AutoDefine facility (defun save-semantics-free-adjective (adj stream) (format stream "~&(define-adjective \"~A\")~%" (etypecase adj ...
7ebc65d37687610a50a183d36a29322d47a3153ac6004044a93aa4ec72978c2d
Liqwid-Labs/agora
Util.hs
| Module : Test . Util Maintainer : Description : Utility functions for testing Plutarch scripts with ScriptContext Module : Test.Util Maintainer : Description: Utility functions for testing Plutarch scripts with ScriptContext -} module Test.Util ( * - land utils datumHash, toDatum, toDatu...
null
https://raw.githubusercontent.com/Liqwid-Labs/agora/00c10198e86800aa59c107043e7961ee32d987a2/agora-testlib/Test/Util.hs
haskell
------------------------------------------------------------------------------ ------------------------------------------------------------------------------ | Calculate the blake2b-256 hash of any type that implements ToData Shamelessly go through plutus. -------------------------------------------------------...
| Module : Test . Util Maintainer : Description : Utility functions for testing Plutarch scripts with ScriptContext Module : Test.Util Maintainer : Description: Utility functions for testing Plutarch scripts with ScriptContext -} module Test.Util ( * - land utils datumHash, toDatum, toDatu...
4959060445d3e65a62930832cf3e63d84286109615f9b93be811a89b93250132
Clozure/ccl
ts-stream.lisp
-*- Package : Hemlock ; Log : hemlock.log -*- ;;; ;;; ********************************************************************** This code was written as part of the CMU Common Lisp project at Carnegie Mellon University , and has been placed in the public domain . ;;; (hemlock-ext:file-comment "$Header$") ;;; ;;; *...
null
https://raw.githubusercontent.com/Clozure/ccl/6c1a9458f7a5437b73ec227e989aa5b825f32fd3/cocoa-ide/hemlock/unused/archive/ts-stream.lisp
lisp
Log : hemlock.log -*- ********************************************************************** ********************************************************************** This file implements typescript streams. A typescript stream is a bidirectional stream which uses remote is: the code in this file is executed on...
This code was written as part of the CMU Common Lisp project at Carnegie Mellon University , and has been placed in the public domain . (hemlock-ext:file-comment "$Header$") function calls to interact with a Hemlock typescript buffer . That Written by . (in-package :hemlock) (defconstant ts-stream-outp...
0601297eddbd757dc1c1c345e329e481c42046be48bb4c7237872ac4605d3ab4
dfinity/motoko
printers.mli
open Parser.MenhirInterpreter This module offers the functionality required by the functor [ MenhirLib . Printers . Make ] . [MenhirLib.Printers.Make]. *) val string_of_symbol : xsymbol -> string val print: string -> unit val print_symbol: xsymbol -> unit val print_element: (element -> unit) option val to_...
null
https://raw.githubusercontent.com/dfinity/motoko/399b8e8b0b47890388cd38ee0ace7638d9092b1a/src/mo_frontend/printers.mli
ocaml
open Parser.MenhirInterpreter This module offers the functionality required by the functor [ MenhirLib . Printers . Make ] . [MenhirLib.Printers.Make]. *) val string_of_symbol : xsymbol -> string val print: string -> unit val print_symbol: xsymbol -> unit val print_element: (element -> unit) option val to_...
ddf676fcc0c24e8160cab66d6098189e835e1673cda008a7dd7a8399aa46c6a6
ds-wizard/engine-backend
DocumentMigration.hs
module Wizard.Database.Migration.Development.Document.DocumentMigration where import Shared.Constant.Component import Wizard.Database.DAO.Document.DocumentDAO import Wizard.Database.Migration.Development.Document.Data.Documents import Wizard.Model.Document.Document import Wizard.S3.Document.DocumentS3 import Wizard.Ut...
null
https://raw.githubusercontent.com/ds-wizard/engine-backend/d392b751192a646064305d3534c57becaa229f28/engine-wizard/src/Wizard/Database/Migration/Development/Document/DocumentMigration.hs
haskell
module Wizard.Database.Migration.Development.Document.DocumentMigration where import Shared.Constant.Component import Wizard.Database.DAO.Document.DocumentDAO import Wizard.Database.Migration.Development.Document.Data.Documents import Wizard.Model.Document.Document import Wizard.S3.Document.DocumentS3 import Wizard.Ut...
18d4c7b0d15063408cbeafd249e7716edd7c84d44a31d428d80cdc2eb58fba6b
droundy/iolaus-broken
FileName.hs
Copyright ( C ) 2002 - 2003 -- -- This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 , or ( at your option ) -- any later version. -- -- This program is distributed in the hope ...
null
https://raw.githubusercontent.com/droundy/iolaus-broken/e40c001f3c5a106bf39f437d6349858e7e9bf51e/Iolaus/FileName.hs
haskell
This program is free software; you can redistribute it and/or modify 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 PURPOSE. See the GNU General Public License for more...
Copyright ( C ) 2002 - 2003 it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 , or ( at your option ) You should have received a copy of the GNU General Public License the Free Software Foundation , Inc. , 51 Franklin Street , Fifth Floor , ...
0ce87c3dceaa5586bee76e1b8c71e14ef53cdf8da30f9ce3409c404ab0ddbd7e
haskell-servant/servant
BasicAuth.hs
{-# LANGUAGE DataKinds #-} {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE KindSignatures #-} # LANGUAGE PolyKinds # module Servant.API.BasicAuth where import Data.ByteString (ByteString) import Data.Typeable (Typeable) import GHC...
null
https://raw.githubusercontent.com/haskell-servant/servant/d06b65c4e6116f992debbac2eeeb83eafb960321/servant/src/Servant/API/BasicAuth.hs
haskell
# LANGUAGE DataKinds # # LANGUAGE DeriveDataTypeable # # LANGUAGE KindSignatures # | Combinator for <#section-2 Basic Access Authentication>. encrypted. Note also that because the same credentials are sent on every implementation in servant-server does not protect against some types of timing attacks....
# LANGUAGE PolyKinds # module Servant.API.BasicAuth where import Data.ByteString (ByteString) import Data.Typeable (Typeable) import GHC.TypeLits (Symbol) * IMPORTANT * : Only use Basic Auth over HTTPS ! Credentials are not...
cd7bcee6baf25e79a6857ec9d884a3a0371617b61369bf494c4a0e9325c8d9be
wdebeaum/step
SpeechActAnalysis.lisp
;; The Top level code for matching logical forms against conventional patterns for acts - stores the results in the discourse record (in-package :IM) (defun Do-speech-act-processing (rec index) "creates an ordered list of possible interpretations of the speech act at INDEX" (let* ((lfs (mapcar #'referent-lf (...
null
https://raw.githubusercontent.com/wdebeaum/step/f38c07d9cd3a58d0e0183159d4445de9a0eafe26/src/NewIM/SpeechActAnalysis.lisp
lisp
The Top level code for matching logical forms against conventional (if results if we succeed we have at least produced some sort of mapping non-temporal pred, we check the mods predicate with value as the type restriction ======================= extract conditionals if present now interpret the modality and rep...
patterns for acts - stores the results in the discourse record (in-package :IM) (defun Do-speech-act-processing (rec index) "creates an ordered list of possible interpretations of the speech act at INDEX" (let* ((lfs (mapcar #'referent-lf (utt-record-referring-expressions rec))) (results (process-speech-act...
5d413d9fd0970bee383c52e6f6105106ebe023b4b7e924775b1f8805117142ce
well-typed/large-records
Interpretation.hs
{-# LANGUAGE RankNTypes #-} # LANGUAGE TypeApplications # # LANGUAGE KindSignatures # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # # LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # -- | Integration of large-generics with mini-beam -- -- See the @beam-large-package@ for full beam integrati...
null
https://raw.githubusercontent.com/well-typed/large-records/fbc9d886094b7b40d6b89db72ff4c7fb59d5b903/large-generics/test/Test/Record/Generic/Infra/Beam/Interpretation.hs
haskell
# LANGUAGE RankNTypes # | Integration of large-generics with mini-beam See the @beam-large-package@ for full beam integration.
# LANGUAGE TypeApplications # # LANGUAGE KindSignatures # # LANGUAGE ScopedTypeVariables # # LANGUAGE TypeFamilies # # LANGUAGE FlexibleInstances # # LANGUAGE MultiParamTypeClasses # module Test.Record.Generic.Infra.Beam.Interpretation ( BeamInterpretation , ZipInterpreted(..) , gzipBeam ) where import Data...
02dfeef8ff31223fbd59d88db97541764419b42e15eaccb76ee35af46df27e34
herbelin/coq-hh
declare.mli
(************************************************************************) v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2010 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *...
null
https://raw.githubusercontent.com/herbelin/coq-hh/296d03d5049fea661e8bdbaf305ed4bf6d2001d2/library/declare.mli
ocaml
********************************************************************** // * This file is distributed under the terms of the * GNU Lesser General Public License Version 2.1 ********************************************************************** * Declaration of local constructions...
v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2010 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * open Names open Libnames open...
df912ef0e0cc66c171c907965e2d315bdcaf605eb36f23231df699e37bb211a2
ucsd-progsys/liquidhaskell
SndOrdPred.hs
{-@ LIQUID "--expect-any-error" @-} module SndOrdPred where {-@ assume relational foo ~ foo :: {x1:_ -> _ ~ x2:_ -> _ | x1 < x2 :=> r1 < r2} @-} -- x1 < x2 :=> r1 x1 > r2 x2 foo :: Int -> Int foo x = x {-@ assume relational bar ~ bar :: {f1:(x1':_ -> _) -> x1:_ -> _ ...
null
https://raw.githubusercontent.com/ucsd-progsys/liquidhaskell/177331c811145dab2606bc442389e0031d7db41b/tests/relational/neg/SndOrdPred.hs
haskell
@ LIQUID "--expect-any-error" @ @ assume relational foo ~ foo :: {x1:_ -> _ ~ x2:_ -> _ | x1 < x2 :=> r1 < r2} @ x1 < x2 :=> r1 x1 > r2 x2 @ assume relational bar ~ bar :: {f1:(x1':_ -> _) -> x1:_ -> _ ~ f2:(x2':_ -> _) -> x2:_ -> _ | (x1' ...
module SndOrdPred where foo :: Int -> Int foo x = x bar :: (Int -> Int) -> Int -> Int bar f x = f (x + 1) bar' :: Int -> (Int -> Int) -> Int bar' x f = f (x + 1) u1 : = > v1 v2 : = > u2 ( -1 ) ~ ( -1 ) | v1 : = > v2 ( syn ) ( -1 ) ~ ( -1 ) | u1 : = ...
9abfffed344142aaa0ea5c49fe7c474971ee58e883e8f3d84348ed2eef4f07e3
esumii/min-caml
join-stack3.ml
let rec f _ = 123 in let rec g _ = 456 in let rec h _ = 789 in let x = f () in print_int ((if x <= 0 then g () else h ()) + x) (* then節でもelse節でもxがセーブされるが、レジスタにはリストアされない *)
null
https://raw.githubusercontent.com/esumii/min-caml/8860b6fbc50786a27963aff1f7639b94c244618a/test/join-stack3.ml
ocaml
then節でもelse節でもxがセーブされるが、レジスタにはリストアされない
let rec f _ = 123 in let rec g _ = 456 in let rec h _ = 789 in let x = f () in print_int ((if x <= 0 then g () else h ()) + x)
3313937f92ef3c5c0776804a499133866a334a899a34d3cb8b66b45ebaed11f0
uhc/uhc
CTypes.hs
# EXCLUDE_IF_TARGET js # module CTypes (module Foreign.C.Types) where import Foreign.C.Types
null
https://raw.githubusercontent.com/uhc/uhc/8eb6914df3ba2ba43916a1a4956c6f25aa0e07c5/EHC/ehclib/haskell98/CTypes.hs
haskell
# EXCLUDE_IF_TARGET js # module CTypes (module Foreign.C.Types) where import Foreign.C.Types
6f718d2bdce16b98501441a387ba4d14d33161855261a63e30b9209582d57472
aws-beam/aws-erlang
aws_elastic_load_balancing_v2.erl
%% WARNING: DO NOT EDIT, AUTO-GENERATED CODE! See -beam/aws-codegen for more details . %% @doc Elastic Load Balancing %% %% A load balancer distributes incoming traffic across targets, such as your %% EC2 instances. %% %% This enables you to increase the availability of your application. The %% load balancer also mo...
null
https://raw.githubusercontent.com/aws-beam/aws-erlang/699287cee7dfc9dc8c08ced5f090dcc192c9cba8/src/aws_elastic_load_balancing_v2.erl
erlang
WARNING: DO NOT EDIT, AUTO-GENERATED CODE! @doc Elastic Load Balancing A load balancer distributes incoming traffic across targets, such as your EC2 instances. This enables you to increase the availability of your application. The load balancer also monitors the health of its registered targets and ensures tha...
See -beam/aws-codegen for more details . load balancer to accept incoming traffic by specifying one or more Application Load Balancers , Network Load Balancers , Gateway Load Balancers , and Classic Load Balancers . This reference covers the following ( layer 7 ) and supports HTTP and HTTPS . 4 ) and suppo...
b85d2ca685cc29a4974adb08622d49e15d761c0c161c1908e78238d5256fb6df
lisp-mirror/cl-tar
build-static-release.lisp
(in-package :cl-user) (require "asdf") (asdf:load-system "asdf-release-ops") (asdf:operate 'asdf-release-ops:static-release-archive-op :tar-cli)
null
https://raw.githubusercontent.com/lisp-mirror/cl-tar/7c6e07a10c93d9e311f087b5f6328cddd481669a/scripts/build-static-release.lisp
lisp
(in-package :cl-user) (require "asdf") (asdf:load-system "asdf-release-ops") (asdf:operate 'asdf-release-ops:static-release-archive-op :tar-cli)
b9d22d4babc0a77b641258378aae3f924defbbb665001dc9c138b339a6985265
Kappa-Dev/KappaTools
lKappa_group_action.mli
* * LKappa_group_action.ml * openkappa * , projet Antique , INRIA Paris - Rocquencourt * * Creation : 2016 , the 5th of December * Last modification : Time - stamp : < Jun 12 2017 > * * Abstract domain to record relations between pair of sites in connected agents . * ...
null
https://raw.githubusercontent.com/Kappa-Dev/KappaTools/eef2337e8688018eda47ccc838aea809cae68de7/core/symmetries/lKappa_group_action.mli
ocaml
what i have to divide to get gamma counter the number of array of orbit
* * LKappa_group_action.ml * openkappa * , projet Antique , INRIA Paris - Rocquencourt * * Creation : 2016 , the 5th of December * Last modification : Time - stamp : < Jun 12 2017 > * * Abstract domain to record relations between pair of sites in connected agents . * ...
eab949432e3b3ccbedd1e1a722fef860c1b530c4dce2ce296c4292bdeeb1332d
v-kolesnikov/sicp
rational.clj
(ns sicp.chapter02.2-77.rational (:require [sicp.common :as sicp] [sicp.common.dispatch-table :as dt] [sicp.common.pairs :as p] [sicp.common.tagged-data :as t])) (defn tag [x] (t/attach-tag 'rational x)) (defn numer [x] (p/car x)) (defn denom [x] (p/cdr x)) (defn make [n d] ...
null
https://raw.githubusercontent.com/v-kolesnikov/sicp/4298de6083440a75898e97aad658025a8cecb631/src/sicp/chapter02/2_77/rational.clj
clojure
(ns sicp.chapter02.2-77.rational (:require [sicp.common :as sicp] [sicp.common.dispatch-table :as dt] [sicp.common.pairs :as p] [sicp.common.tagged-data :as t])) (defn tag [x] (t/attach-tag 'rational x)) (defn numer [x] (p/car x)) (defn denom [x] (p/cdr x)) (defn make [n d] ...
677b3d65205ba659e86e715d8682e1f5066a834afa96c368f01c1315adb2c1a4
input-output-hk/project-icarus-importer
Functions.hs
# LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # # LANGUAGE NamedFieldPuns # {-# LANGUAGE RankNTypes #-} # LANGUAGE ScopedTypeVariables # # LANGUAGE TupleSections # # LANGUAGE TypeApplications # module Functions ( runActi...
null
https://raw.githubusercontent.com/input-output-hk/project-icarus-importer/36342f277bcb7f1902e677a02d1ce93e4cf224f0/wallet-new/integration/Functions.hs
haskell
# LANGUAGE RankNTypes # of actions to test against the API. It runs the actions through, eventually returning the final state. | Attempt each action in the list. If an action fails, ignore the failure and try the next action in the sequence. | Here we run the actions. NOTE: ordNub is available in ...
# LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # # LANGUAGE NamedFieldPuns # # LANGUAGE ScopedTypeVariables # # LANGUAGE TupleSections # # LANGUAGE TypeApplications # module Functions ( runActionCheck , printT ) where import ...
65f0a313d32642b73d85a004c8f6110fc5463d0b1db6aa55b97ae28a7347f838
lunarcoffee/advent-of-code
Day17.hs
import Control.Lens import Control.Monad import Data.List (find) import Data.Map qualified as Map import Data.Maybe (fromMaybe) import Data.Set (Set) import Data.Set qualified as Set type Pos = (Int, Int) rocks :: [(Int, [Pos])] rocks = let flat = map (4,) [2 .. 5] cross = [(4, 3), (5, 2), (5, 3), (5, 4), (6,...
null
https://raw.githubusercontent.com/lunarcoffee/advent-of-code/97501bb4ca3cc065f7ceae620d0b4249c118021b/2022/Day17.hs
haskell
import Control.Lens import Control.Monad import Data.List (find) import Data.Map qualified as Map import Data.Maybe (fromMaybe) import Data.Set (Set) import Data.Set qualified as Set type Pos = (Int, Int) rocks :: [(Int, [Pos])] rocks = let flat = map (4,) [2 .. 5] cross = [(4, 3), (5, 2), (5, 3), (5, 4), (6,...
403ec094925706252a398a335042786963cbff541a8f616ac3c310e40f309ad8
theronic/eacl
old_core_test.clj
(ns eacl.core-test (:require [eacl.utils :refer [spy profile]] [taoensso.timbre :as log] [clojure.test :refer [deftest is]] [eacl.core :as eacl] [eacl.data.schema :as schema] [datascript.core :as d])) was 100000 . belongs under perf / benchmark tests . (defn my-fixtures [f] (spy :fixture...
null
https://raw.githubusercontent.com/theronic/eacl/e9913b646bbc2d4492994ce2c67a365e53b0e76c/clj-eacl/test/eacl/old_core_test.clj
clojure
(:db/id user) (:db/id invoices)})))) (:db/id user) (:db/id invoices)})))))) not sure :read] true] /blocked? (d/q '[:find (pull ?user [*]) ?allowed ?action (pull ?resource [*]) (pull ?group [*]) (pull ?perm [*]) :in $ % :where ;[?perm :eacl/user ?user...
(ns eacl.core-test (:require [eacl.utils :refer [spy profile]] [taoensso.timbre :as log] [clojure.test :refer [deftest is]] [eacl.core :as eacl] [eacl.data.schema :as schema] [datascript.core :as d])) was 100000 . belongs under perf / benchmark tests . (defn my-fixtures [f] (spy :fixture...
a5631e9ddaf1e370987c0c2c307abb15426b04781bc2d08f3a880384bafdf3b2
yueyoum/codebattle-server
cb_room_sup.erl
-module(cb_room_sup). -behaviour(supervisor). %% API -export([start_link/0, create_room/3]). %% Supervisor callbacks -export([init/1]). -define(CHILD(Id, Mod, Type, Args), {Id, {Mod, start_link, Args}, temporary, brutal_kill, Type, [Mod]}). %%%==========================...
null
https://raw.githubusercontent.com/yueyoum/codebattle-server/5e8ae24649be14eb7c3dc1910502bf88af97ed8d/src/cb_room_sup.erl
erlang
API Supervisor callbacks =================================================================== API functions =================================================================== -------------------------------------------------------------------- @doc Starts the supervisor @end -------------------------------------...
-module(cb_room_sup). -behaviour(supervisor). -export([start_link/0, create_room/3]). -export([init/1]). -define(CHILD(Id, Mod, Type, Args), {Id, {Mod, start_link, Args}, temporary, brutal_kill, Type, [Mod]}). ( ) - > { ok , Pid } | ignore | { error , Error } start...
e11aedf81dd47bc1473b4ac815feea7ae98ebccd1f3ef306b1b1483960c99271
wangsix/VMO_repeated_themes_discovery
converter.lisp
;(in-package :common-lisp-user) (load (concatenate 'string *lisp-code-root* "/File conversion" "/csv-files.lisp")) (load (concatenate 'string *lisp-code-root* "/File conversion" "/humdrum-by-col.lisp")) (load (concatenate 'string *lisp-code-root* "/File conversion" "/midi-save.lisp")) (setq *pa...
null
https://raw.githubusercontent.com/wangsix/VMO_repeated_themes_discovery/0082b3c55e64ed447c8b68bcb705fd6da8e3541f/JKUPDD-Aug2013/groundTruth/beethovenOp2No1Mvt3/polyphonic/repeatedPatterns/barlowAndMorgenstern/A/script/converter.lisp
lisp
(in-package :common-lisp-user)
(load (concatenate 'string *lisp-code-root* "/File conversion" "/csv-files.lisp")) (load (concatenate 'string *lisp-code-root* "/File conversion" "/humdrum-by-col.lisp")) (load (concatenate 'string *lisp-code-root* "/File conversion" "/midi-save.lisp")) (setq *path&name* (concatenate 'string...
c28aae66e148c296da02602d912c9343d1c71ad2e96f13f8bd254217f9118932
input-output-hk/plutus-apps
Sum.hs
{-# LANGUAGE BangPatterns #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE FlexibleContexts #-} # LANGUAGE NoImplicitPrelude # # LANGUAGE ScopedTypeVariables # # LANGUAGE TemplateHaskell # # LANGUAGE TypeApplications # # LANGUAGE TypeFamilies # {-# LANGUAGE TypeOperators #-} mo...
null
https://raw.githubusercontent.com/input-output-hk/plutus-apps/c1269a7ab8806957cda93448a4637c485352cda5/plutus-example/src/PlutusExample/PlutusVersion1/Sum.hs
haskell
# LANGUAGE BangPatterns # # LANGUAGE DataKinds # # LANGUAGE FlexibleContexts # # LANGUAGE TypeOperators # | The validation function
# LANGUAGE NoImplicitPrelude # # LANGUAGE ScopedTypeVariables # # LANGUAGE TemplateHaskell # # LANGUAGE TypeApplications # # LANGUAGE TypeFamilies # module PlutusExample.PlutusVersion1.Sum where import Prelude hiding (($), (+), (-), (==)) import Cardano.Api.Shelley (PlutusScript (..), PlutusScr...
4282b791e59596024b26a82051ea8730a4b8fbc6244b4a9a422bf19f69c70f0e
inaka/rpsls
rpsls_cabra_player.erl
%%%------------------------------------------------------------------- @author < > ( C ) 2014 , %%% @doc %%% This player detects predictable patterns such as: alternating pattern , repeating pattern ( like bart , spock ) and copycat pattern . %%% In other cases the logic applied is: if the opponent wins...
null
https://raw.githubusercontent.com/inaka/rpsls/85f6621cfa55a803edf9c2a9fd43901415b9ba80/src/players/rpsls_cabra_player.erl
erlang
------------------------------------------------------------------- @doc This player detects predictable patterns such as: alternating In other cases the logic applied is: if the opponent wins, then pick the thing that beats what the opponent just played. If my player wins, then pick the thing that beats the possi...
@author < > ( C ) 2014 , pattern , repeating pattern ( like bart , spock ) and copycat pattern . Created : 13 . Dec 2014 12:02 PM -module(rpsls_cabra_player). -behaviour(rpsls_player). -export([init/0, play/2]). -define(CHOICES, [rock, paper, scissors, lizard, spock]). @private -spec init() -> ...
8a3bbd926eb9944fa28517487114bcd92ad5ea54142ce9c1ec62b606a0193e9c
haskell/haskell-language-server
ExplicitBinds.hs
{-# LANGUAGE Haskell2010 #-} module ExplicitBinds where data MyRec = MyRec { foo :: Int , bar :: Int , baz :: Char } convertMe :: MyRec -> String convertMe MyRec {foo = foo', bar = bar', baz = baz'} = show foo' ++ show bar' ++ show baz'
null
https://raw.githubusercontent.com/haskell/haskell-language-server/85f788135175a007d3db4ac911c4115b30ab9d87/plugins/hls-explicit-record-fields-plugin/test/testdata/noop/ExplicitBinds.hs
haskell
# LANGUAGE Haskell2010 #
module ExplicitBinds where data MyRec = MyRec { foo :: Int , bar :: Int , baz :: Char } convertMe :: MyRec -> String convertMe MyRec {foo = foo', bar = bar', baz = baz'} = show foo' ++ show bar' ++ show baz'
4867ca017ee1d3e420dff261b3f11b34121864a1fb1f9092c86792e22095aeb5
jumper149/go
Model.hs
# LANGUAGE UndecidableInstances # module Representation.Model ( GameModelRep (..) ) where import GHC.Generics import qualified Game.Board.Default as D import Game.Model data GameModelRep = GameModelD_9_2 (GameModel (D.Board 9 2)) | GameModelD_13_2 (GameModel (D.Board 13...
null
https://raw.githubusercontent.com/jumper149/go/603e61f64e8e7c890bbc914fef6033b5ed7dd005/client/Representation/Model.hs
haskell
# LANGUAGE UndecidableInstances # module Representation.Model ( GameModelRep (..) ) where import GHC.Generics import qualified Game.Board.Default as D import Game.Model data GameModelRep = GameModelD_9_2 (GameModel (D.Board 9 2)) | GameModelD_13_2 (GameModel (D.Board 13...
03065a02748125a29c1314670821c553df72d9a2653208c23aa6fe0c6cae77b9
marijnh/Postmodern
strings-ascii.lisp
-*- Mode : LISP ; Syntax : Ansi - Common - Lisp ; Base : 10 ; Package : CL - POSTGRES ; -*- (in-package :cl-postgres) (defparameter *client-encoding* "SQL_ASCII") (declaim (inline enc-byte-length)) (defun enc-byte-length (sequence) (length sequence)) (declaim (ftype (function (t &key (:null-terminated t) ...
null
https://raw.githubusercontent.com/marijnh/Postmodern/45fa35ddad0f0aff6218f2708f7652a3deb83c06/cl-postgres/strings-ascii.lisp
lisp
Syntax : Ansi - Common - Lisp ; Base : 10 ; Package : CL - POSTGRES ; -*-
(in-package :cl-postgres) (defparameter *client-encoding* "SQL_ASCII") (declaim (inline enc-byte-length)) (defun enc-byte-length (sequence) (length sequence)) (declaim (ftype (function (t &key (:null-terminated t) (:byte-length unsigned-byte)) string) ...
cee6ddb3d63303f26cd213a710a1c973349bd51e80252eb02511d9bf582d98f3
oetr/racket-opencv
VideoCanny.rkt
#! /usr/bin/env racket #lang racket Author : Date : 2013 ;; Description: Capture video from a camera, apply canny filter ;; if some key is pressed while the focus is on the video window, ;; then the application terminates Tested with iSight camera of my MacBook Pro ;;; Includes (require opencv/core o...
null
https://raw.githubusercontent.com/oetr/racket-opencv/8124eb6b620769137656547e83f9d9587ab37c23/tutorials/03_imgproc/VideoCanny.rkt
racket
Description: Capture video from a camera, apply canny filter if some key is pressed while the focus is on the video window, then the application terminates Includes Capture an image to get parameters Get parameters from the captured image to initialize copied images clean up (not really necessary, because the a...
#! /usr/bin/env racket #lang racket Author : Date : 2013 Tested with iSight camera of my MacBook Pro (require opencv/core opencv/types opencv/highgui opencv/imgproc opencv/videoio) (define capture (cvCaptureFromCAM 0)) (define captured-image (cvQueryFrame capture)) (defi...
1d528b33a0f77346a97df691deff56cf5dec37c22315e76ea40e661906a2a5f8
nikita-volkov/rebase
FD.hs
module Rebase.GHC.IO.Handle.FD ( module GHC.IO.Handle.FD ) where import GHC.IO.Handle.FD
null
https://raw.githubusercontent.com/nikita-volkov/rebase/7c77a0443e80bdffd4488a4239628177cac0761b/library/Rebase/GHC/IO/Handle/FD.hs
haskell
module Rebase.GHC.IO.Handle.FD ( module GHC.IO.Handle.FD ) where import GHC.IO.Handle.FD
78d18e90b3b718392b8d21c873121a8506765c51e055794b6748bdd257d3b081
ocaml/ocaml-lsp
lsp_fiber.ml
module Fiber_io = Fiber_io module Lazy_fiber = Lazy_fiber module Rpc = Rpc module Client = Client module Server = Server module Json = Import.Json module Private = struct module Log = Import.Log end
null
https://raw.githubusercontent.com/ocaml/ocaml-lsp/032e3ff8f565b7a0f6a476dbeb4dbb49260066c8/lsp-fiber/src/lsp_fiber.ml
ocaml
module Fiber_io = Fiber_io module Lazy_fiber = Lazy_fiber module Rpc = Rpc module Client = Client module Server = Server module Json = Import.Json module Private = struct module Log = Import.Log end
9b697188f65bfcffcb8d0780acacf02821d369ca8750c87d5163bd4b20e86656
lowasser/TrieMap
Tests.hs
{-# LANGUAGE ScopedTypeVariables, UnboxedTuples #-} module Data.TrieMap.TrieKey.Projection.Tests (tests) where import Data.TrieMap.Sized import Data.TrieMap.TrieKey import qualified Data.Map as M import Data.TrieMap.TrieKey.Tests.Utils import Test.QuickCheck testMapMaybe :: forall k . (TrieKey k, Arbitrary k, Show k...
null
https://raw.githubusercontent.com/lowasser/TrieMap/1ab52b8d83469974a629f2aa577a85de3f9e867a/Data/TrieMap/TrieKey/Projection/Tests.hs
haskell
# LANGUAGE ScopedTypeVariables, UnboxedTuples #
module Data.TrieMap.TrieKey.Projection.Tests (tests) where import Data.TrieMap.Sized import Data.TrieMap.TrieKey import qualified Data.Map as M import Data.TrieMap.TrieKey.Tests.Utils import Test.QuickCheck testMapMaybe :: forall k . (TrieKey k, Arbitrary k, Show k) => String -> k -> Property testMapMaybe test _ = t...
fdfc70396e9672dd56eca797b16deee30f57c6e7b9b189986b6b748cf57d1fcf
lem-project/lem
syntax-table.lisp
(in-package :lem-base) (defstruct syntax-table (space-chars '(#\space #\tab #\newline)) (symbol-chars '(#\_)) (paren-pairs '((#\( . #\)) (#\[ . #\]) (#\{ . #\}))) (string-quote-chars '(#\")) (escape-chars '(#\\)) fence-chars expr-prefix-chars expr-suffix-chars expr-p...
null
https://raw.githubusercontent.com/lem-project/lem/3b9b92690b48710135a946b1d3754f64d2bfdaf1/src/base/syntax-table.lisp
lisp
(in-package :lem-base) (defstruct syntax-table (space-chars '(#\space #\tab #\newline)) (symbol-chars '(#\_)) (paren-pairs '((#\( . #\)) (#\[ . #\]) (#\{ . #\}))) (string-quote-chars '(#\")) (escape-chars '(#\\)) fence-chars expr-prefix-chars expr-suffix-chars expr-p...
128485ee04ce84ed70a7994239e1d3c0d2b1192dc968c97dfd7ecb005eedf5d8
LesBoloss-es/ppx_deriving_madcast
ppx_deriving_madcast.ml
let () = Ppx_deriving.(register (create "madcast" ~core_type: Madcast.derive ()))
null
https://raw.githubusercontent.com/LesBoloss-es/ppx_deriving_madcast/2c728604cf87c07c937b18d9b599fc6785670a9b/src/ppx_deriving_madcast.ml
ocaml
let () = Ppx_deriving.(register (create "madcast" ~core_type: Madcast.derive ()))
acfba7cdbaa51554cbbed074f2ab3cdb906bd1dd27b1cc39c14863cf7cd858ea
tonyg/racket-nat-traversal
example-upnp-ip-gateway.rkt
#lang racket/base (require racket/pretty) (require "../upnp-ip-gateway.rkt") ;;--------------------------------------------------------------------------- (start-upnp-gateway-scanner!) (upnp-external-ip-address) (when (upnp-query-port-mapping 'udp 2000) (upnp-delete-mapping! (upnp-query-port-mapping 'udp 2000)))...
null
https://raw.githubusercontent.com/tonyg/racket-nat-traversal/3983b52e1e23b820da1b90f514ddbe7d6398e0cb/examples/example-upnp-ip-gateway.rkt
racket
---------------------------------------------------------------------------
#lang racket/base (require racket/pretty) (require "../upnp-ip-gateway.rkt") (start-upnp-gateway-scanner!) (upnp-external-ip-address) (when (upnp-query-port-mapping 'udp 2000) (upnp-delete-mapping! (upnp-query-port-mapping 'udp 2000))) (define m1 (upnp-map-port! 'udp 5999 2000 30)) (pretty-print m1) (pretty-pri...
f893a21988402c46cb165bc3e906a539fe4c4fa781d9624e0afc63737cdd1fff
nstack/segmentio
Aeson.hs
module Network.Segment.Internal.Aeson (customOptions) where import Data.Aeson.Types ( defaultOptions, fieldLabelModifier, omitNothingFields) -- from: aeson import qualified Data.Aeson.Types as AeTy -- from: aeson import Data.Char (isUpper, toLower) customOptions :: AeTy.Options customOptions...
null
https://raw.githubusercontent.com/nstack/segmentio/93776460011dac6746bd030cea4a43a5c375f025/src/Network/Segment/Internal/Aeson.hs
haskell
from: aeson from: aeson
module Network.Segment.Internal.Aeson (customOptions) where import Data.Aeson.Types ( defaultOptions, fieldLabelModifier, import Data.Char (isUpper, toLower) customOptions :: AeTy.Options customOptions = defaultOptions { fieldLabelModifier = removePrefix, omitNothingFields = True } where removePrefix = lowerFirs...
6b13aec0940eadbf641fb6b92c59224391ac529deebe75118a63b69e815a9da2
jellelicht/guix
pciutils.scm
;;; GNU Guix --- Functional package management for GNU Copyright © 2014 , 2015 < > ;;; ;;; 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 Foundation ; either version 3 of t...
null
https://raw.githubusercontent.com/jellelicht/guix/83cfc9414fca3ab57c949e18c1ceb375a179b59c/gnu/packages/pciutils.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 © 2014 , 2015 < > under the terms of the GNU General Public License as published by You should have received a copy of the GNU General Public License along with GNU . If not , see < / > . (define-module (gnu packages pciutils) #:use-module (guix packages) #:use-module (guix download) #:us...
901211bda3bee3468f7daeec2adf414f093c7eb407d1fcaa088ce9b4476dabb3
mkhan45/RustScript2
capture.ml
open Base open Stdio open Rustscript.Run open Util let () = let ss, state = test_state () |> run_file (test_file "capture.rsc") in assert_equal_expressions "g(3)" "-2" ss state; assert_equal_expressions "g(5)" "0" ss state; assert_equal_expressions "f(1, 2, 4)" "quadratic(1, 2, 0, 4)" ss sta...
null
https://raw.githubusercontent.com/mkhan45/RustScript2/3c859508c3e4c976f2bd3a8e5bfd1097245b5f31/test/capture.ml
ocaml
open Base open Stdio open Rustscript.Run open Util let () = let ss, state = test_state () |> run_file (test_file "capture.rsc") in assert_equal_expressions "g(3)" "-2" ss state; assert_equal_expressions "g(5)" "0" ss state; assert_equal_expressions "f(1, 2, 4)" "quadratic(1, 2, 0, 4)" ss sta...
3c06dd855a758d32324131c8e0dac3e050e3471e350023c4af81ad825fe5ba73
psibi/yesod-rest
Application.hs
# OPTIONS_GHC -fno - warn - orphans # module Application ( getApplicationDev , appMain , develMain , makeFoundation , makeLogWare -- * for DevelMain , getApplicationRepl , shutdownApp -- * for GHCI , handler , db ) where import Control.Monad.Logger (liftL...
null
https://raw.githubusercontent.com/psibi/yesod-rest/6cf2a2584fb230933a8aa8831de32007459486dd/Application.hs
haskell
* for DevelMain * for GHCI Import all relevant handler modules here. Don't forget to add new modules to your cabal file! comments there for more details. | This function allocates resources (such as a database connection pool), performs initialization and returns a foundation datatype value. This is also the pl...
# OPTIONS_GHC -fno - warn - orphans # module Application ( getApplicationDev , appMain , develMain , makeFoundation , makeLogWare , getApplicationRepl , shutdownApp , handler , db ) where import Control.Monad.Logger (liftLoc, runLoggingT) import Database.Persist....
ca5a16e931157575bb422438c8e7ee9a88e814b3d0fecd4b57f5ea59a53a0429
mcorbin/riemann-cond-dt-plugin
core.clj
(ns riemann-cond-dt.core (:require [riemann.streams :refer [call-rescue]])) (defn cond-dt "A stream which detects if a condition `(f event)` is true during `dt` seconds. Takes a function of events `f` and a time period `dt` in seconds. If the condition is valid for all events received during at least the peri...
null
https://raw.githubusercontent.com/mcorbin/riemann-cond-dt-plugin/a584ac0b44be91b11c0255687c7f6cd90d7c1e68/src/riemann_cond_dt/core.clj
clojure
filter events with no time event is validating the condition last event is not ok, has no time or is too old => last-changed-state is now ok with a new time event is not validating the condition last event is ok, has no time or is too old default value, return the state we already had an ok event
(ns riemann-cond-dt.core (:require [riemann.streams :refer [call-rescue]])) (defn cond-dt "A stream which detects if a condition `(f event)` is true during `dt` seconds. Takes a function of events `f` and a time period `dt` in seconds. If the condition is valid for all events received during at least the peri...
dd04ec2ecf81a1189da6821232f6f077fc79e95c88e70a5d35a80d037547cf13
ndmitchell/tagsoup
LazyParse.hs
{-# OPTIONS_GHC -O2 #-} module Text.ParserCombinators.LazyParse (Parser, runParser ,get, put, modify ,eof, def, (==>), choice ,takesUntil, many, one, lit ) where import Control.Monad.State import Data.Maybe import Data.Char import Text.StringLike infix 0 ==> type Parser s a = State s a runPars...
null
https://raw.githubusercontent.com/ndmitchell/tagsoup/e116d3b965e4f149581bd55e45a05661b1113536/dead/LazyParse.hs
haskell
# OPTIONS_GHC -O2 #
module Text.ParserCombinators.LazyParse (Parser, runParser ,get, put, modify ,eof, def, (==>), choice ,takesUntil, many, one, lit ) where import Control.Monad.State import Data.Maybe import Data.Char import Text.StringLike infix 0 ==> type Parser s a = State s a runParser :: Parser s a -> s ->...
e0f9534dcd82bbb60ae30651c1f4932ccabf83f47e258ea2ee179a8dba81e975
wtfleming/clojurescript-examples
handler.clj
(ns om-todo-list-undo.core.handler (:require [compojure.core :refer :all] [compojure.route :as route] [compojure.response :refer [render]] [clojure.java.io :as io] [ring.middleware.defaults :refer [wrap-defaults site-defaults]])) (defn home [req] (render (io/resour...
null
https://raw.githubusercontent.com/wtfleming/clojurescript-examples/6f878f431a2cba405b6ae715199f776a19dda6f7/om-todo-list-undo/src/clj/om_todo_list_undo/core/handler.clj
clojure
(ns om-todo-list-undo.core.handler (:require [compojure.core :refer :all] [compojure.route :as route] [compojure.response :refer [render]] [clojure.java.io :as io] [ring.middleware.defaults :refer [wrap-defaults site-defaults]])) (defn home [req] (render (io/resour...
d66a1454e2d4f423d5e3268e241ea6be37b2b3c89c17f01eefffd44aca83ade5
jacekschae/learn-datomic-course-files
handlers.clj
(ns cheffy.recipe.handlers (:require [cheffy.recipe.db :as recipe-db] [cheffy.responses :as responses] [ring.util.response :as rr]) (:import (java.util UUID))) (defn list-all-recipes [{:keys [env claims] :as _request}] (let [account-id (:sub claims)] (rr/response (recipe-db/find-all...
null
https://raw.githubusercontent.com/jacekschae/learn-datomic-course-files/918a0dde7a6e95fd11b694f9784f4c6d7d9f2005/increments/24-create-recipe/src/main/cheffy/recipe/handlers.clj
clojure
FIXME: recipe-db/transact-recipe FIXME: recipe-db/find-recipe-by-id FIXME: recipe-db/transact-recipe FIXME: recipe-db/retract-recipe FIXME: recipe-db/transact-step FIXME: recipe-db/transact-step FIXME: recipe-db/retract-step FIXME: recipe-db/transact-ingredient FIXME: recipe-db/transact-ingredient FIXME: reci...
(ns cheffy.recipe.handlers (:require [cheffy.recipe.db :as recipe-db] [cheffy.responses :as responses] [ring.util.response :as rr]) (:import (java.util UUID))) (defn list-all-recipes [{:keys [env claims] :as _request}] (let [account-id (:sub claims)] (rr/response (recipe-db/find-all...
d20b565ed9a21178aa1678515607105bf2d41200bdb24524e12466306fadfcd3
untangled-web/untangled-client
server_rendering_spec.clj
(ns untangled.client.server-rendering-spec (:require [om.next :as om :refer [defui]] [om.dom :as dom] [untangled-spec.core :refer [specification behavior assertions]] [untangled.client.core :as uc])) (defui Item static uc/InitialAppState (initial-state [cls {:keys [id label]}]...
null
https://raw.githubusercontent.com/untangled-web/untangled-client/d9b350db3a5e19910692ee70281d8c156fd3a3f9/spec/untangled/client/server_rendering_spec.clj
clojure
(ns untangled.client.server-rendering-spec (:require [om.next :as om :refer [defui]] [om.dom :as dom] [untangled-spec.core :refer [specification behavior assertions]] [untangled.client.core :as uc])) (defui Item static uc/InitialAppState (initial-state [cls {:keys [id label]}]...
b7fd557fecdafc5e3051a206e4057925054af3cb12a1cf8858e6040f0af5a814
EveryTian/Haskell-Codewars
compare-powers.hs
-- -powers module Codewars.Exercise.Powers where import Data.Word type Power = (Word, Word) comparePowers :: Power -> Power -> Ordering comparePowers (0, _) (0, _) = EQ comparePowers (1, _) (1, _) = EQ comparePowers (n1, p1) (n2, p2) | n1 == n2 && p1 == p2 = EQ | n1 <= n2 && p1 <= p2 = LT | n1...
null
https://raw.githubusercontent.com/EveryTian/Haskell-Codewars/dc48d95c676ce1a59f697d07672acb6d4722893b/6kyu/compare-powers.hs
haskell
-powers
module Codewars.Exercise.Powers where import Data.Word type Power = (Word, Word) comparePowers :: Power -> Power -> Ordering comparePowers (0, _) (0, _) = EQ comparePowers (1, _) (1, _) = EQ comparePowers (n1, p1) (n2, p2) | n1 == n2 && p1 == p2 = EQ | n1 <= n2 && p1 <= p2 = LT | n1 >= n2 && p1...
a6853fba83b0e10bcfdaefefb1afe274ac4b89df56eecc9173472ef0813872de
kelamg/HtDP2e-workthrough
ex84.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-beginner-reader.ss" "lang")((modname ex84) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #f #...
null
https://raw.githubusercontent.com/kelamg/HtDP2e-workthrough/ec05818d8b667a3c119bea8d1d22e31e72e0a958/HtDP/Fixed-size-Data/ex84.rkt
racket
about the language level of this file in a form that our tools can easily process. graphical editor An Editor is a structure: interpretation (make-editor s t) describes an editor whose visible text is (string-append s t) with the cursor displayed between s and t Constants: Editor -> Image produces an image of...
The first three lines of this file were inserted by . They record metadata #reader(lib "htdp-beginner-reader.ss" "lang")((modname ex84) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #f #t none #f () #f))) (require 2htdp/image) (require 2htdp/universe) (define-struct edi...
66d7b69727e49677543cfda454b42d5c67e1e705a4a77d7c6001d7545cd64134
mstksg/inCode
Halves.hs
-- All of these versions of halve return a successful halving if the number -- is even, or a failure otherwise. -- -- * `halve` returns it in a Maybe container, where success is Just -- x and failure is Nothing -- * `halve'` returns it in a List, where success is [x] and failure is [] * ` genericHalve ` returns it ...
null
https://raw.githubusercontent.com/mstksg/inCode/e1f80a3dfd83eaa2b817dc922fd7f331cd1ece8a/code-samples/monad-plus/Halves.hs
haskell
All of these versions of halve return a successful halving if the number is even, or a failure otherwise. * `halve` returns it in a Maybe container, where success is Just x and failure is Nothing * `halve'` returns it in a List, where success is [x] and failure is [] To load: $ ghci λ: :l Halves.hs Some ...
* ` genericHalve ` returns it whatever container you want , provided it is a MonadPlus . You can view all MonadPlus 's currently loaded by typing ` : info MonadPlus ` on ghci . λ : halve 8 λ : genericHalve 8 : : Maybe Int λ : genericHalve 8 : : [ Int ] import Control.Monad (guard, MonadPlus) halve :...
3bc4793e74ca783ea118b1486ef9e27d6dbe76a58e9aba3d9ca06edb773fb5c7
tiensonqin/lymchat-exp
root.cljs
(ns lymchat.shared.scene.root (:require [reagent.core :as r] [re-frame.core :refer [subscribe dispatch]] [lymchat.styles :refer [styles]] [lymchat.shared.ui :refer [text view image touchable-highlight icon-button colors status-bar gradient image-prefetch activity-indicator] :as ui]...
null
https://raw.githubusercontent.com/tiensonqin/lymchat-exp/425a0738b11632119be08b5a59f12244f5df1575/src/lymchat/shared/scene/root.cljs
clojure
(ns lymchat.shared.scene.root (:require [reagent.core :as r] [re-frame.core :refer [subscribe dispatch]] [lymchat.styles :refer [styles]] [lymchat.shared.ui :refer [text view image touchable-highlight icon-button colors status-bar gradient image-prefetch activity-indicator] :as ui]...
cc726d8c758a132e8a0d332611f41b0731aead4339e8f15f32658ec0df88b905
CBMM/tagging
Stimulus.hs
# LANGUAGE DeriveGeneric # # LANGUAGE TypeFamilies # # LANGUAGE FlexibleInstances # # LANGUAGE FlexibleContexts # {-# LANGUAGE GADTs #-} # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE DeriveAnyClass #-} # LANGUAGE TemplateHaskell # # LANGUAGE QuasiQuotes # # LANGUAGE CPP # # LA...
null
https://raw.githubusercontent.com/CBMM/tagging/15f257394f3dda5baf6db0581a52d9c9f99e2abe/tagging-common/src/Tagging/Stimulus.hs
haskell
# LANGUAGE GADTs # # LANGUAGE OverloadedStrings # # LANGUAGE DeriveAnyClass # ---------------------------------------------------------------------------- --------------------------------------------------------------------------- as well as methods for deriving these types from untyped @StimulusResource@'s store...
# LANGUAGE DeriveGeneric # # LANGUAGE TypeFamilies # # LANGUAGE FlexibleInstances # # LANGUAGE FlexibleContexts # # LANGUAGE MultiParamTypeClasses # # LANGUAGE TemplateHaskell # # LANGUAGE QuasiQuotes # # LANGUAGE CPP # # LANGUAGE StandaloneDeriving # module Tagging.Stimulus where import Control.Lens ...
36f19d51fbc89c8ef1f735e990ec47f88935a819a4ad2cfd453b04c934f3869c
argp/bap
steensgard.ml
Steensgard 's loop nesting algorithm See Steensgaard , B. ( 1993 ) . Sequentializing Program Dependence Graphs for Irreducible Programs ( No . MSR - TR-93 - 14 ) , particularly page 5 . ( The algorithm is very simple ) See Steensgaard, B. (1993). Sequentializing Program Dependence Graphs fo...
null
https://raw.githubusercontent.com/argp/bap/2f60a35e822200a1ec50eea3a947a322b45da363/ocaml/steensgard.ml
ocaml
body of loop Progress check Remove closing edges SCCs contained in original region
Steensgard 's loop nesting algorithm See Steensgaard , B. ( 1993 ) . Sequentializing Program Dependence Graphs for Irreducible Programs ( No . MSR - TR-93 - 14 ) , particularly page 5 . ( The algorithm is very simple ) See Steensgaard, B. (1993). Sequentializing Program Dependence Graphs fo...
216108ca4f3e1f03e737b5e3f5bf27da3247643975c6dc74fee09c0db18091ed
onedata/op-worker
atm_openfaas_result_streamer_push_message.erl
%%%------------------------------------------------------------------- @author ( C ) 2022 ACK CYFRONET AGH This software is released under the MIT license cited in ' LICENSE.txt ' . %%% @end %%%------------------------------------------------------------------- %%% @doc %%% Record expressing a generic push m...
null
https://raw.githubusercontent.com/onedata/op-worker/af88ede8353170b5d20f815900f0cbca20a1dc70/src/modules/automation/task/executor/platforms/openfaas/activity_feed/result_streamer/protocol/push_messages/atm_openfaas_result_streamer_push_message.erl
erlang
------------------------------------------------------------------- @end ------------------------------------------------------------------- @doc Record expressing a generic push message sent to lambda result streamers. The record is not persistable, but is encoded to JSON on the activity feed channel. @end ------...
@author ( C ) 2022 ACK CYFRONET AGH This software is released under the MIT license cited in ' LICENSE.txt ' . -module(atm_openfaas_result_streamer_push_message). -author("Lukasz Opiola"). -behaviour(jsonable_record). -include("modules/automation/atm_execution.hrl"). -export([to_json/1, from_json/1]). -t...
c6fd02c3dedbe49e528601bbee8ba47c65201ac8edcb5a334ef20be6d1443c68
number571/Haskell
(!!).hs
module Main where (!!!) :: [a] -> Int -> a (!!!) _ n | n < 0 = undefined (!!!) [] _ = undefined (!!!) (x:_) 0 = x (!!!) (_:xs) n = (!!!) xs (n-1) main :: IO() main = print $ ['a'..'z'] !!! 2
null
https://raw.githubusercontent.com/number571/Haskell/7da2676c2604706d43791dc89c0ca8c9842aea48/Templates/(!!).hs
haskell
module Main where (!!!) :: [a] -> Int -> a (!!!) _ n | n < 0 = undefined (!!!) [] _ = undefined (!!!) (x:_) 0 = x (!!!) (_:xs) n = (!!!) xs (n-1) main :: IO() main = print $ ['a'..'z'] !!! 2
fdae64dc43828be70961cf48b17ac4d7ca8f997cd678a0cdef0edd8d9f60afe3
nibbula/yew
unipose-data.lisp
;; unipose-data.lisp - Unicode character composition data ;; (in-package :unipose) (defvar *unipose* '((?1 ((?2 ?½) (?4 ?¼) (?^ ?¹))) (?2 ((?^ ?²))) (?3 ((?^ ?³) (?4 ?¾))) (?8 ((?8 ?∞))) (?A ((?^ ?Â) (?' ?Á) (?` ?À) (?\" ?Ä) (?E ?Æ) (?o ?Å))) (?a ((?^ ?â) (?' ?á) (?` ?à) (?\" ?ä) (?e ?æ) (?o ?...
null
https://raw.githubusercontent.com/nibbula/yew/e4172647e7f8df116f12009de6f6b5cf53ba7cf8/io/unipose-data.lisp
lisp
captial circumflex lower circumflex capital acute lower acute misc acute capital grave lower greve capital umlat lower umlat upper twiddles lower twiddles misc twiddles
unipose-data.lisp - Unicode character composition data (in-package :unipose) (defvar *unipose* '((?1 ((?2 ?½) (?4 ?¼) (?^ ?¹))) (?2 ((?^ ?²))) (?3 ((?^ ?³) (?4 ?¾))) (?8 ((?8 ?∞))) (?A ((?^ ?Â) (?' ?Á) (?` ?À) (?\" ?Ä) (?E ?Æ) (?o ?Å))) (?a ((?^ ?â) (?' ?á) (?` ?à) (?\" ?ä) (?e ?æ) (?o ?å) (?_...
03afa88a745312020349e4c9fc434d4a09d323b06d2cb839866cff37d8256db9
metosin/kekkonen
http.clj
(ns kekkonen.http (:require [kekkonen.core :as k] [kekkonen.api :as ka] [kekkonen.common :as kc] [schema.core :as s])) (s/defn http-api [options] (ka/api (kc/deep-merge-map-like {:core {:type-resolver (k/type-resolver :get :head :patch :delete :options :post :put :any)...
null
https://raw.githubusercontent.com/metosin/kekkonen/5a38c52af34a0eb0f19d87e9f549e93e6d87885f/modules/kekkonen-core/src/kekkonen/http.clj
clojure
(ns kekkonen.http (:require [kekkonen.core :as k] [kekkonen.api :as ka] [kekkonen.common :as kc] [schema.core :as s])) (s/defn http-api [options] (ka/api (kc/deep-merge-map-like {:core {:type-resolver (k/type-resolver :get :head :patch :delete :options :post :put :any)...