_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 |
|---|---|---|---|---|---|---|---|---|
c5ba22d41b663ca0e2cf2bd52b36eb5ef9f08b2423ff1b94809d9d2bf3b72bbf | mark-watson/loving-common-lisp | web-hunchentoot-example.lisp | (ql:quickload :hunchentoot)
(ql:quickload :cl-who)
(in-package :cl-user)
(defpackage hdemo
(:use :cl
:cl-who
:hunchentoot))
(in-package :hdemo)
(defvar *h* (make-instance 'easy-acceptor :port 3000))
;; define a handler with the arbitrary name my-greetings:
(define-easy-handler (my-greetings :uri "... | null | https://raw.githubusercontent.com/mark-watson/loving-common-lisp/32f6abf3d2e500baeffd15c085a502b03399a074/src/hunchentoot_examples/web-hunchentoot-example.lisp | lisp | define a handler with the arbitrary name my-greetings: | (ql:quickload :hunchentoot)
(ql:quickload :cl-who)
(in-package :cl-user)
(defpackage hdemo
(:use :cl
:cl-who
:hunchentoot))
(in-package :hdemo)
(defvar *h* (make-instance 'easy-acceptor :port 3000))
(define-easy-handler (my-greetings :uri "/hello") (name)
(setf (hunchentoot:content-type*) "text/... |
a583423976320f65fa302e731f16e6f65bb63a6b197977b08b9c79e2eb02f113 | theodormoroianu/SecondYearCourses | LambdaChurch_20210415170220.hs | module LambdaChurch where
import Data.Char (isLetter)
import Data.List ( nub )
class ShowNice a where
showNice :: a -> String
class ReadNice a where
readNice :: String -> (a, String)
data Variable
= Variable
{ name :: String
, count :: Int
}
deriving (Show, Eq, Ord)
var :: String -> Variable
var ... | null | https://raw.githubusercontent.com/theodormoroianu/SecondYearCourses/5e359e6a7cf588a527d27209bf53b4ce6b8d5e83/FLP/Laboratoare/Lab%209/.history/LambdaChurch_20210415170220.hs | haskell | alpha-equivalence
subst u x t defines [u/x]t, i.e., substituting u for x in t
This substitution avoids variable captures so it is safe to be used when
reducing terms with free variables (e.g., if evaluating inside lambda abstractions)
^ substitution term
^ variable to be substitutes
^ term in which the substit... | module LambdaChurch where
import Data.Char (isLetter)
import Data.List ( nub )
class ShowNice a where
showNice :: a -> String
class ReadNice a where
readNice :: String -> (a, String)
data Variable
= Variable
{ name :: String
, count :: Int
}
deriving (Show, Eq, Ord)
var :: String -> Variable
var ... |
c110efd091f201eeeac1939bcecdad138366c8cf76860689c910c300bf85c095 | magicant/flesh | LexSpec.hs |
Copyright ( C ) 2017 WATANABE >
This program is free software ; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation ; either version 2 of the License , or
( at your option ) any later version .
This program is distribut... | null | https://raw.githubusercontent.com/magicant/flesh/0e76312d291aae8f890ba55d8131ade78600d7e8/hspec-src/Flesh/Language/Parser/LexSpec.hs | haskell | vim: set et sw=2 sts=2 tw=78: |
Copyright ( C ) 2017 WATANABE >
This program is free software ; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation ; either version 2 of the License , or
( at your option ) any later version .
This program is distribut... |
dbfb5e2bf10eaf49f007e779ab1f6bc3113d78f1403fccf92f6c7f5d72204437 | jimcrayne/jhc | TrueSet.hs | module Util.TrueSet(
TrueSet,
fromList,
member,
empty,
full,
singleton,
insert,
delete,
unions,
union,
intersection,
intersects,
difference,
(\\)
) where
import qualified Data.Set as Set
infixl 9 \\
data TrueSet a = TrueSet (Set.Set a) Bool
False `xor` y ... | null | https://raw.githubusercontent.com/jimcrayne/jhc/1ff035af3d697f9175f8761c8d08edbffde03b4e/src/Util/TrueSet.hs | haskell | module Util.TrueSet(
TrueSet,
fromList,
member,
empty,
full,
singleton,
insert,
delete,
unions,
union,
intersection,
intersects,
difference,
(\\)
) where
import qualified Data.Set as Set
infixl 9 \\
data TrueSet a = TrueSet (Set.Set a) Bool
False `xor` y ... | |
652068965235f245f2034c420aa332c81183dec60afd1ef3e9d88f51d8cf8005 | mirage/irmin-watcher | irmin_watcher.ml | ---------------------------------------------------------------------------
Copyright ( c ) 2016 . All rights reserved .
Distributed under the ISC license , see terms at the end of the file .
% % NAME%% % % ---------------------------------------------------------------------------
Copyright (c) 2... | null | https://raw.githubusercontent.com/mirage/irmin-watcher/753084ba383ca5d1ea30b3bf89c8757a782d213c/src/irmin_watcher.ml | ocaml | ---------------------------------------------------------------------------
Copyright ( c ) 2016 . All rights reserved .
Distributed under the ISC license , see terms at the end of the file .
% % NAME%% % % ---------------------------------------------------------------------------
Copyright (c) 2... | |
e169fb5e540c1d0b7a44a5bb2f11348b3a9fdf7c383cc2dc20b083a341c217c3 | fakedata-haskell/fakedata | FrCaTextSpec.hs | # LANGUAGE ScopedTypeVariables #
{-# LANGUAGE OverloadedStrings #-}
module FrCaTextSpec where
import Data.Text (Text)
import qualified Data.Text as T
import Faker hiding (defaultFakerSettings)
import qualified Faker.Address as FA
import Faker.Combinators (listOf)
import qualified Faker.Company as CO
import qualified ... | null | https://raw.githubusercontent.com/fakedata-haskell/fakedata/e6fbc16cfa27b2d17aa449ea8140788196ca135b/test/FrCaTextSpec.hs | haskell | # LANGUAGE OverloadedStrings # | # LANGUAGE ScopedTypeVariables #
module FrCaTextSpec where
import Data.Text (Text)
import qualified Data.Text as T
import Faker hiding (defaultFakerSettings)
import qualified Faker.Address as FA
import Faker.Combinators (listOf)
import qualified Faker.Company as CO
import qualified Faker.Internet as IN
import qualifi... |
0a7e583b90143fe315ca2e7003882ba8014fb33c92184ac096686fcb547cc6c2 | fragnix/fragnix | Text.Appar.Input.hs | # LANGUAGE Haskell98 #
{-# LINE 1 "Text/Appar/Input.hs" #-}
{-# LANGUAGE TypeSynonymInstances, FlexibleInstances #-}
module Text.Appar.Input where
import qualified Data.ByteString.Char8 as S
import qualified Data.ByteString.Lazy.Char8 as L
----------------------------------------------------------------
{-|
The c... | null | https://raw.githubusercontent.com/fragnix/fragnix/b9969e9c6366e2917a782f3ac4e77cce0835448b/tests/packages/scotty/Text.Appar.Input.hs | haskell | # LINE 1 "Text/Appar/Input.hs" #
# LANGUAGE TypeSynonymInstances, FlexibleInstances #
--------------------------------------------------------------
|
The class for parser input.
| The head function for input
| The tail function for input
| The end of input
| The function to check the end of input | # LANGUAGE Haskell98 #
module Text.Appar.Input where
import qualified Data.ByteString.Char8 as S
import qualified Data.ByteString.Lazy.Char8 as L
class Eq inp => Input inp where
car :: inp -> Char
cdr :: inp -> inp
nil :: inp
isNil :: inp -> Bool
instance Input S.ByteString where
car = S.hea... |
74531a2eeefe8cd93bb0333fc2e1a9134d6520e527363c1eececcbed82f127ec | Practical-Formal-Methods/adiff | SemRep.hs | {-# LANGUAGE DeriveDataTypeable #-}
# LANGUAGE StandaloneDeriving #
-----------------------------------------------------------------------------
-- |
-- Module : Language.C.Analysis.Syntax
Copyright : ( c ) 2008
-- License : BSD-style
-- Maintainer :
-- Stability : alpha
Portability : ghc... | null | https://raw.githubusercontent.com/Practical-Formal-Methods/adiff/c18872faf3e31572437686d766f9972e00274588/language-c-extensible/src/Language/C/Analysis/SemRep.hs | haskell | # LANGUAGE DeriveDataTypeable #
---------------------------------------------------------------------------
|
Module : Language.C.Analysis.Syntax
License : BSD-style
Maintainer :
Stability : alpha
This module contains definitions for representing C translation units.
of a translation unit.
----... | # LANGUAGE StandaloneDeriving #
Copyright : ( c ) 2008
Portability : ghc
In contrast to ' Language . C.Syntax . AST ' , the representation tries to express the semantics of
module Language.C.Analysis.SemRep(
TagDef(..),typeOfTagDef,
Declaration(..),declIdent,declName,declType,declAttrs,
IdentDecl(..),obj... |
1aa84d49b279fa1d40bf2912118d6c068bcc53923abc8060a98e37795b03132e | bwo/macroparser | project.clj | (defproject bwo/macroparser "0.0.7c"
:license {:name "Eclipse Public License - v 1.0"
:url "-v10.html"
:distribution :repo
:comments "same as Clojure"}
:description "Tools for simplifying the writing of complex macros"
:url ""
:dependencies [[expectations "1.4.18"]
... | null | https://raw.githubusercontent.com/bwo/macroparser/f03135fe1108959ea06c91cf6984bfb9a0fa9cd6/project.clj | clojure | (defproject bwo/macroparser "0.0.7c"
:license {:name "Eclipse Public License - v 1.0"
:url "-v10.html"
:distribution :repo
:comments "same as Clojure"}
:description "Tools for simplifying the writing of complex macros"
:url ""
:dependencies [[expectations "1.4.18"]
... | |
b755fd95ba1846dc344fe00a70ec3a73b91425edf77a51202ab19e90b555b4cd | oakmac/atom-parinfer | util.cljs | (ns atom-parinfer.util
(:require
[goog.dom :as gdom]
[oops.core :refer [ocall]]))
;; -----------------------------------------------------------------------------
;; Logging
(defn js-log
"Logs a JavaScript thing."
[js-thing]
(ocall js/console "log" js-thing))
(defn log
"Logs a Clojure thing."
[cl... | null | https://raw.githubusercontent.com/oakmac/atom-parinfer/3e12b9722466e163a0b536ec71c7c3e4a34a0e53/src-cljs/atom_parinfer/util.cljs | clojure | -----------------------------------------------------------------------------
Logging
-----------------------------------------------------------------------------
-----------------------------------------------------------------------------
String
-----------------------------------------------------------------... | (ns atom-parinfer.util
(:require
[goog.dom :as gdom]
[oops.core :refer [ocall]]))
(defn js-log
"Logs a JavaScript thing."
[js-thing]
(ocall js/console "log" js-thing))
(defn log
"Logs a Clojure thing."
[clj-thing]
(js-log (pr-str clj-thing)))
(defn log-atom-changes [_atm _kwd old-value new-val... |
6bd0a2bbbe30d6862c25aeecdc92d9c1be0d304ceee8be067e1685a743d95101 | mrkkrp/req | Req.hs | {-# LANGUAGE BangPatterns #-}
# LANGUAGE DataKinds #
{-# LANGUAGE DeriveDataTypeable #-}
# LANGUAGE DeriveGeneric #
{-# LANGUAGE DeriveLift #-}
# LANGUAGE FlexibleInstances #
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE LambdaCase #
# LANGUAGE MultiParamTypeClasses #
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE ... | null | https://raw.githubusercontent.com/mrkkrp/req/4ec1f7bf87ce70ddb2f88126e9e817d3b05c994f/Network/HTTP/Req.hs | haskell | # LANGUAGE BangPatterns #
# LANGUAGE DeriveDataTypeable #
# LANGUAGE DeriveLift #
# LANGUAGE OverloadedStrings #
# LANGUAGE RankNTypes #
# LANGUAGE TemplateHaskellQuotes #
|
Stability : experimental
Portability : portable
The documentation below is structured in such a way that the most
requests, how to embe... | # LANGUAGE DataKinds #
# LANGUAGE DeriveGeneric #
# LANGUAGE FlexibleInstances #
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE LambdaCase #
# LANGUAGE MultiParamTypeClasses #
# LANGUAGE QuasiQuotes #
# LANGUAGE RecordWildCards #
# LANGUAGE RoleAnnotations #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE StandaloneDer... |
80753ccc93b58bf17be632fea289ce4236a609bdeb6b9400447e1048495daaa5 | valderman/haste-compiler | TestDriver.hs | # LANGUAGE CPP #
module Main where
#ifdef __HASTE__
import Haste
#endif
import Tests.TEST_MODULE (runTest)
main = do
res <- runTest
putStrLn $ show res
| null | https://raw.githubusercontent.com/valderman/haste-compiler/47d942521570eb4b8b6828b0aa38e1f6b9c3e8a8/TestDriver.hs | haskell | # LANGUAGE CPP #
module Main where
#ifdef __HASTE__
import Haste
#endif
import Tests.TEST_MODULE (runTest)
main = do
res <- runTest
putStrLn $ show res
| |
9470e2203c93f8c231e1607313e38413acc8911518e48eca6874742a96fa628d | WorksHub/client | subs.cljc | (ns wh.components.navbar.subs
(:require [re-frame.core :refer [reg-sub]]
[wh.common.search :as search]
[wh.common.user :as user-common]
[wh.components.navbar.db :as db]
[wh.job.db :as job]))
(reg-sub
::profile-image
:<- [:user/sub-db]
(fn [{:keys [wh.user.db/type... | null | https://raw.githubusercontent.com/WorksHub/client/77e4212a69dad049a9e784143915058acd918982/common/src/wh/components/navbar/subs.cljc | clojure | (ns wh.components.navbar.subs
(:require [re-frame.core :refer [reg-sub]]
[wh.common.search :as search]
[wh.common.user :as user-common]
[wh.components.navbar.db :as db]
[wh.job.db :as job]))
(reg-sub
::profile-image
:<- [:user/sub-db]
(fn [{:keys [wh.user.db/type... | |
451b478d40de13b0599ece0217f18fec69a3bc8007e80bc6c3a23b250255e514 | theam/haskell-do | View.hs |
- Copyright ( c ) 2017 The Agile Monkeys S.L. < >
-
- 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 ag... | null | https://raw.githubusercontent.com/theam/haskell-do/f339e57859d308437a72800bda08f96d0de12982/src/common/HaskellDo/View.hs | haskell |
- Copyright ( c ) 2017 The Agile Monkeys S.L. < >
-
- 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 ag... | |
39e2768c4d8bde613322df104e571463cd46bb0107f0ff95fcbe67f2ae17bd2f | docopt/docopt.clj | optionsblock.clj | (ns docopt.optionsblock
(:require [clojure.string :as s])
(:use docopt.util))
(defn tokenize-option
"Generates a sequence of tokens for an option specification string."
[string]
(tokenize string [[#"\s{2,}(?s).*\[(?i)default(?-i):\s*([^\]]+).*" :default]
[#"\s{2,}(?s).*"]
... | null | https://raw.githubusercontent.com/docopt/docopt.clj/0ae9b2eeb60d5e99388176ab4e9571238c964627/src/docopt/optionsblock.clj | clojure | (ns docopt.optionsblock
(:require [clojure.string :as s])
(:use docopt.util))
(defn tokenize-option
"Generates a sequence of tokens for an option specification string."
[string]
(tokenize string [[#"\s{2,}(?s).*\[(?i)default(?-i):\s*([^\]]+).*" :default]
[#"\s{2,}(?s).*"]
... | |
2227b15a782c76c697bc893e2c9fe2e041ec31bac09e375bd13f41a4843fa3d0 | IndianRoboticsOrganization/ArimaTTS | INST_uk_VOX_other.scm | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; ;;;
Carnegie Mellon University ; ; ;
and and ; ; ;
Copyright ( c ) 1998 - 2000 ... | null | https://raw.githubusercontent.com/IndianRoboticsOrganization/ArimaTTS/7377dca466306e2e6b90a063427273142cd50616/festvox/src/vox_files/uk/INST_uk_VOX_other.scm | scheme |
;;;
; ;
; ;
; ;
; ;
;;;
Permission is hereby granted, free of charge, to use and distribute ;;;
this software and its documentation without restriction, including ;;;
withou... |
(define (INST_uk_VOX::select_other)
"(INST_uk_VOX::select_other)
Set up the anything esle for the voice."
)
(define (INST_uk_VOX::reset_other)
"(INST_uk_VOX::reset_other)
Reset other information."
t
)
(provide 'INST_uk_VOX_other)
|
d96f7c522785ca7c9e31c7d26dee3f7500eb7e4a0245f0f0194a879968c6b728 | arttuka/reagent-material-ui | step_button.cljs | (ns reagent-mui.material.step-button
"Imports @mui/material/StepButton as a Reagent component.
Original documentation is at -ui/api/step-button/ ."
(:require [reagent.core :as r]
["@mui/material/StepButton" :as MuiStepButton]))
(def step-button (r/adapt-react-class (.-default MuiStepButton)))
| null | https://raw.githubusercontent.com/arttuka/reagent-material-ui/14103a696c41c0eb67fc07fc67cd8799efd88cb9/src/core/reagent_mui/material/step_button.cljs | clojure | (ns reagent-mui.material.step-button
"Imports @mui/material/StepButton as a Reagent component.
Original documentation is at -ui/api/step-button/ ."
(:require [reagent.core :as r]
["@mui/material/StepButton" :as MuiStepButton]))
(def step-button (r/adapt-react-class (.-default MuiStepButton)))
| |
b3b4b0f51c5e48183866be7b265c39535e0470cb10fd62b4f4fbd1b1ed0e80a0 | BekaValentine/SimpleFP | TypeChecking.hs | {-# OPTIONS -Wall #-}
# LANGUAGE TypeFamilies #
module Poly.Unification.TypeChecking where
import Control.Applicative ((<$>))
import Control.Monad.Except
import Control.Monad.State
import Data.List (intercalate,nubBy,find)
import Scope
import TypeChecker
import Poly.Core.Term
import Poly.Core.Type
-- Signatures
... | null | https://raw.githubusercontent.com/BekaValentine/SimpleFP/3cff456be9f0b99509e5cbe809be1055009b32df/src/Poly/Unification/TypeChecking.hs | haskell | # OPTIONS -Wall #
Signatures
argnum, Params -> ([Arg],Ret)
Definitions
Contexts
Unifying Type Checkers
Type well-formedness
Inserting param variables into con data
Instantiating quantified values until there are no more initial quantifiers
Type Inference
Type Checking
unify arg arg'
type checking succees exa... | # LANGUAGE TypeFamilies #
module Poly.Unification.TypeChecking where
import Control.Applicative ((<$>))
import Control.Monad.Except
import Control.Monad.State
import Data.List (intercalate,nubBy,find)
import Scope
import TypeChecker
import Poly.Core.Term
import Poly.Core.Type
data ConSig = ConSig Int (Scope Typ... |
7450cc3611be4119f8985a5a8c8210a7a59f644259f9f131b79a3046d6bc1f46 | borodust/claw-legacy | dynamic.lisp | (cl:in-package :claw.cffi.c)
(defgeneric initialize-adapter (library-name))
(defclass dynamic-adapter (adapter) ())
(defun make-dynamic-adapter (wrapper path)
(make-instance 'dynamic-adapter :wrapper wrapper :path path))
(defun load-dynamic-adapter-template ()
(alexandria:read-file-into-string
(asdf:syst... | null | https://raw.githubusercontent.com/borodust/claw-legacy/3cd4a96fca95eb9e8d5d069426694669f81b2250/src/cffi/c/adapter/dynamic.lisp | lisp | (cl:in-package :claw.cffi.c)
(defgeneric initialize-adapter (library-name))
(defclass dynamic-adapter (adapter) ())
(defun make-dynamic-adapter (wrapper path)
(make-instance 'dynamic-adapter :wrapper wrapper :path path))
(defun load-dynamic-adapter-template ()
(alexandria:read-file-into-string
(asdf:syst... | |
52488a7d2af2a248a03fecf37669da6c1c530be8fa2de5094e87e7c6a9914d4f | 8c6794b6/guile-tjit | program.scm | ;;; Guile VM program functions
Copyright ( C ) 2001 , 2009 , 2010 , 2013 , 2014 Free Software Foundation , Inc.
;;;
;;; 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
versio... | null | https://raw.githubusercontent.com/8c6794b6/guile-tjit/9566e480af2ff695e524984992626426f393414f/module/system/vm/program.scm | scheme | Guile VM program functions
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
either
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FO... |
Copyright ( C ) 2001 , 2009 , 2010 , 2013 , 2014 Free Software Foundation , Inc.
version 3 of the License , or ( at your option ) any later version .
You should have received a copy of the GNU Lesser General Public
Foundation , Inc. , 51 Franklin Street , Fifth Floor , Boston , USA
(define-module (system... |
401db778c133c4e4776b5528548b31516fa88661424433e1ca86df273bfbc45c | LexiFi/csml | csml_iface.mli | This file is released under the terms of an MIT - like license .
(* See the attached LICENSE file. *)
Copyright 2016 by LexiFi .
(** Csml.*)
val csharp_available: bool ref
(** Is the .Net runtime available in the current process.... | null | https://raw.githubusercontent.com/LexiFi/csml/1bdffc60b937b0cd23730589b191940cd1861640/src/csml_iface.mli | ocaml | See the attached LICENSE file.
* Csml.
* Is the .Net runtime available in the current process.
* A C# exception wrapped as an OCaml exception.
The arguments are: the exception's type name, the exception's message,
the exception value itself.
* Dynamically load a pl... | This file is released under the terms of an MIT - like license .
Copyright 2016 by LexiFi .
val csharp_available: bool ref
type cshandle
exception Csharp_exception of string * string * cshandle
class csval: cshandle ->
object
method cshandle: cshandle
end
*... |
dbf74f00470959614e9d173ca7bcd975482d69a0dfcd872b8f52a4d2143a09a2 | dparis/gen-phzr | quartic.cljs | (ns phzr.easing.quartic
(:require [phzr.impl.utils.core :refer [clj->phaser phaser->clj]]
[phzr.impl.extend :as ex]
[cljsjs.phaser]))
(defn in
"Quartic ease-in.
Parameters:
* quartic (Phaser.Easing.Quartic) - Targeted instance for method
* k (number) - The value to be tweened.
... | null | https://raw.githubusercontent.com/dparis/gen-phzr/e4c7b272e225ac343718dc15fc84f5f0dce68023/out/easing/quartic.cljs | clojure | (ns phzr.easing.quartic
(:require [phzr.impl.utils.core :refer [clj->phaser phaser->clj]]
[phzr.impl.extend :as ex]
[cljsjs.phaser]))
(defn in
"Quartic ease-in.
Parameters:
* quartic (Phaser.Easing.Quartic) - Targeted instance for method
* k (number) - The value to be tweened.
... | |
7ae55bac6d4cbc81636a23c8a5b6162f9b71d98cedb36548c03ef17ad45018f9 | andrewthad/sockets | Indefinite.hs | # language BangPatterns #
# language LambdaCase #
{-# language MultiWayIf #-}
module Datagram.Send.Indefinite
( send
, attemptSend
) where
import Control.Concurrent.STM (TVar)
import Datagram.Send (Peer)
import Foreign.C.Error (Errno(..), eAGAIN, eWOULDBLOCK, eACCES, eMSGSIZE)
import Foreign.C.Error (eCONNREFUS... | null | https://raw.githubusercontent.com/andrewthad/sockets/90d314bd2ec71b248a90da6ad964c679f75cfcca/src-datagram-send/Datagram/Send/Indefinite.hs | haskell | # language MultiWayIf #
Send the entirely of the buffer, making a single call to
POSIX @send@. This is used for datagram sockets. We cannot use a
Socket newtype here since destined and undestined sockets
use different newtypes.
Never blocks. | # language BangPatterns #
# language LambdaCase #
module Datagram.Send.Indefinite
( send
, attemptSend
) where
import Control.Concurrent.STM (TVar)
import Datagram.Send (Peer)
import Foreign.C.Error (Errno(..), eAGAIN, eWOULDBLOCK, eACCES, eMSGSIZE)
import Foreign.C.Error (eCONNREFUSED,eNOTCONN)
import Foreign.... |
a43231fa2c90944de289fe3d0df99184cd19b3df1d06ce2cc6ddd477e557c69a | coq/coq | tok.ml | (************************************************************************)
(* * The Coq Proof Assistant / The Coq Development Team *)
v * Copyright INRIA , CNRS and contributors
< O _ _ _ , , * ( see version control and CREDITS file for authors & dates )
\VV/ * * *... | null | https://raw.githubusercontent.com/coq/coq/0532b6cd6be0f1386492dda01d52db67a1608011/parsing/tok.ml | ocaml | **********************************************************************
* The Coq Proof Assistant / The Coq Development Team
// * This file is distributed under the terms of the
* (see LICENSE file for the text of the license)
************************************... | v * Copyright INRIA , CNRS and contributors
< O _ _ _ , , * ( see version control and CREDITS file for authors & dates )
\VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* GNU Lesser Gener... |
8929d4b123f339dd7971a784cfaddbe23f6ce31f23824c627778d8883607d697 | NorfairKing/cursor | Gen.hs | module Cursor.Simple.Map.KeyValue.Gen
(
)
where
import Cursor.Map.KeyValue.Gen ()
| null | https://raw.githubusercontent.com/NorfairKing/cursor/71ec3154809e229efbf35d500ac6d1a42ae5fdc0/cursor-gen/src/Cursor/Simple/Map/KeyValue/Gen.hs | haskell | module Cursor.Simple.Map.KeyValue.Gen
(
)
where
import Cursor.Map.KeyValue.Gen ()
| |
7a7e39dbfce0bf2218313c96509bf8496f6933caee933d7f47fac3a29b239d73 | clash-lang/clash-compiler | ReduceOne.hs | module ReduceOne where
import Clash.Prelude
import Clash.Explicit.Testbench
topEntity
:: Clock System
-> Reset System
-> Enable System
-> Signal System (Signed 1)
-> Signal System (Bit, Bit, Bit)
topEntity clk rst en =
fmap (\a -> (reduceAnd a, reduceOr a, reduceXor a))
{-# NOINLINE topEntity #-}
testB... | null | https://raw.githubusercontent.com/clash-lang/clash-compiler/8e461a910f2f37c900705a0847a9b533bce4d2ea/tests/shouldwork/BitVector/ReduceOne.hs | haskell | # NOINLINE topEntity # | module ReduceOne where
import Clash.Prelude
import Clash.Explicit.Testbench
topEntity
:: Clock System
-> Reset System
-> Enable System
-> Signal System (Signed 1)
-> Signal System (Bit, Bit, Bit)
topEntity clk rst en =
fmap (\a -> (reduceAnd a, reduceOr a, reduceXor a))
testBench :: Signal System Bool
... |
50563c662edb5869b92716283382a7e18b24dc290632f208a9800956ea962580 | Yuppiechef/cqrs-server | simple_dynamo_test.clj | (ns cqrs-server.simple-dynamo-test
(:require
[schema.core :as s]
[clojure.core.async :as a]
[clojure.test :refer :all]
[clojure.tools.logging :as log]
[taoensso.faraday :as far]
[taoensso.nippy :as nippy]
[cqrs-server.cqrs :as cqrs]
[cqrs-server.simple :as simple]
[cqrs-server.async... | null | https://raw.githubusercontent.com/Yuppiechef/cqrs-server/57621f52e8f4a9de9f2e06fff16b4b918a81228a/test/cqrs_server/simple_dynamo_test.clj | clojure | Simple testing module
Our super lightweight 'database'
:user/create
Implementation
Requires dynamo local | (ns cqrs-server.simple-dynamo-test
(:require
[schema.core :as s]
[clojure.core.async :as a]
[clojure.test :refer :all]
[clojure.tools.logging :as log]
[taoensso.faraday :as far]
[taoensso.nippy :as nippy]
[cqrs-server.cqrs :as cqrs]
[cqrs-server.simple :as simple]
[cqrs-server.async... |
0a425d9d51145a84612c405ee97a825f5a46c147802bf4d86d1a37535cf5e8fb | mejgun/haskell-tdlib | SetUsername.hs | {-# LANGUAGE OverloadedStrings #-}
-- |
module TD.Query.SetUsername where
import qualified Data.Aeson as A
import qualified Data.Aeson.Types as T
import qualified Utils as U
-- |
-- Changes the editable username of the current user
data SetUsername = SetUsername
{ -- | The new value of the username. Use an empty s... | null | https://raw.githubusercontent.com/mejgun/haskell-tdlib/dc380d18d49eaadc386a81dc98af2ce00f8797c2/src/TD/Query/SetUsername.hs | haskell | # LANGUAGE OverloadedStrings #
|
|
Changes the editable username of the current user
| The new value of the username. Use an empty string to remove the username. The username can't be completely removed if there is another active or disabled username |
module TD.Query.SetUsername where
import qualified Data.Aeson as A
import qualified Data.Aeson.Types as T
import qualified Utils as U
data SetUsername = SetUsername
username :: Maybe String
}
deriving (Eq)
instance Show SetUsername where
show
SetUsername
{ username = username_
} =
"S... |
7eb6f7610bc29cb202e4a870fe88b391338b10c3ee0a83297d00b95a5f057259 | ocaml-multicore/tezos | michelson_v1_primitives.mli | (*****************************************************************************)
(* *)
(* Open Source License *)
Copyright ( c ) 2018 Dynamic Ledger Solutions , Inc. < >
Copyright ( c... | null | https://raw.githubusercontent.com/ocaml-multicore/tezos/e4fd21a1cb02d194b3162ab42d512b7c985ee8a9/src/proto_012_Psithaca/lib_protocol/michelson_v1_primitives.mli | ocaml | ***************************************************************************
Open Source License
Permission is h... | Copyright ( c ) 2018 Dynamic Ledger Solutions , Inc. < >
Copyright ( c ) 2020 Metastate AG < >
to deal in the Software without restriction , including without limitation
and/or sell copies of the Software , and to permit persons to whom the
THE SOFTWARE IS PROVIDED " AS IS " ,... |
461c6eb3c263bf2de9b37f1147fe0ca2ff949fb0e911681e064e7b1ed64bda71 | imdea-software/leap | SMTTllQuery_reduced.ml |
(***********************************************************************)
(* *)
LEAP
(* *)
, IMDEA ... | null | https://raw.githubusercontent.com/imdea-software/leap/5f946163c0f80ff9162db605a75b7ce2e27926ef/src/solvers/backend/query/smtlib/SMTTllQuery_reduced.ml | ocaml | *********************************************************************
... |
LEAP
, IMDEA Software Institute
Copyright 2011 IMDEA Software Institute
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
you may not use this file except in compl... |
93fbb29ac3a0b7cee0ef399872f54a7d035dc2e0919ad05ada36eebdfd8b7c25 | ocaml/ocamlbuild | bb.ml | (***********************************************************************)
(* *)
(* ocamlbuild *)
(* *)
, , projet Galliu... | null | https://raw.githubusercontent.com/ocaml/ocamlbuild/792b7c8abdbc712c98ed7e69469ed354b87e125b/test/test11/b/bb.ml | ocaml | *********************************************************************
ocamlbuild
... | , , projet Gallium , INRIA Rocquencourt
Copyright 2007 Institut National de Recherche en Informatique et
en Automatique . All rights reserved . This file is distributed
under the terms of the GNU Library General Public License , with
let foo = [2.2]
|
48b5c14978f2f9fe63f2daedd6bc476e93461ae1d6f06bd7ccc7eb38642807d9 | saltysystems/overworld | ow_app.erl | %%%-------------------------------------------------------------------
%% @doc Overworld Public API
%% @end
%%%-------------------------------------------------------------------
-module(ow_app).
-behaviour(application).
-export([start/2, stop/1]).
% status information via JSON API
-export([status/0]).
-define(PEE... | null | https://raw.githubusercontent.com/saltysystems/overworld/e5def9e4784fde42b27cc37abfec80de58b02c14/src/ow_app.erl | erlang | -------------------------------------------------------------------
@doc Overworld Public API
@end
-------------------------------------------------------------------
status information via JSON API
{"/libow.gd", cowboy_static,
{file, "apps/ow_core/static/libow.gd"}}
Start WebSocket/CowBoy
Start ENet |
-module(ow_app).
-behaviour(application).
-export([start/2, stop/1]).
-export([status/0]).
-define(PEER_LIMIT, 64).
-define(CHANNEL_LIMIT, 4).
-define(ENET_PORT, 4484).
-define(ENET_DTLS_PORT, 4485).
-define(WS_PORT, 4434).
-define(WS_TLS_PORT, 4435).
start(_StartType, _StartArgs) ->
Dispatch = cowboy_router:... |
ee52f52adccea45e2ebc62c15fd02883c1fc289faf8397dfa8e6ce5ede0add17 | input-output-hk/cardano-rest | TxLast.hs | {-# LANGUAGE OverloadedStrings #-}
module Explorer.Web.Api.Legacy.TxLast
( getLastTxs
) where
import Cardano.Db
( EntityField (..), Tx, isJust )
import Control.Monad.IO.Class
( MonadIO )
import Data.ByteString.Char8
( ByteString )
import Data.Fixed
( Fixed (..), Uni )
import Data.Time.Clock
( ... | null | https://raw.githubusercontent.com/input-output-hk/cardano-rest/040b123b45af06060aae04479d92fada68820f12/explorer-api/src/Explorer/Web/Api/Legacy/TxLast.hs | haskell | # LANGUAGE OverloadedStrings #
This actually is safe. |
module Explorer.Web.Api.Legacy.TxLast
( getLastTxs
) where
import Cardano.Db
( EntityField (..), Tx, isJust )
import Control.Monad.IO.Class
( MonadIO )
import Data.ByteString.Char8
( ByteString )
import Data.Fixed
( Fixed (..), Uni )
import Data.Time.Clock
( UTCTime )
import Data.Time.Clock.PO... |
9bf9c72b69f0712937c5347464bda06ecad143809135bcf1cb2a3de80289f9ef | haskell-compat/deriving-compat | Via.hs | # LANGUAGE CPP #
|
Module : Data . Deriving . Via
Copyright : ( C ) 2015 - 2017
License : BSD - style ( see the file LICENSE )
Maintainer :
Portability : Template Haskell
On @template - haskell-2.12@ or later ( i.e. , GHC 8.2 or later ) , this module
exports functionality which emula... | null | https://raw.githubusercontent.com/haskell-compat/deriving-compat/23e62c003325258e925e6c2fe7e46fafdeaf199a/src/Data/Deriving/Via.hs | haskell | * @GeneralizedNewtypeDeriving@
* Limitations
$constraints | # LANGUAGE CPP #
|
Module : Data . Deriving . Via
Copyright : ( C ) 2015 - 2017
License : BSD - style ( see the file LICENSE )
Maintainer :
Portability : Template Haskell
On @template - haskell-2.12@ or later ( i.e. , GHC 8.2 or later ) , this module
exports functionality which emula... |
bd94d095e1a8e85e2af7641ed13c15e69accf067f9782446270ba83180400311 | susisu/est-ocaml | value.mli | open Core
type t = Num of float
| Fun of (t -> t)
| Vec of t array
val equal : t -> t -> bool
val type_string_of : t -> string
val to_string : t -> string
| null | https://raw.githubusercontent.com/susisu/est-ocaml/e610d07b166a51e5763aa4f7b12449ec0438071c/src/value.mli | ocaml | open Core
type t = Num of float
| Fun of (t -> t)
| Vec of t array
val equal : t -> t -> bool
val type_string_of : t -> string
val to_string : t -> string
| |
dbbd7748e56a6e271121808efb1f73a23a629a8b1020ac3c8193cdd2b5cfd45f | exoscale/pithos | keystore.clj | (ns io.pithos.keystore
"A keystore is a simple protocol which yields a map
of tenant details for a key id.
The basic implementation wants keys from the configuration
file, you'll likely want to use a custom implementation that
interacts with your user-base here.
")
(defn map-keystore [{:keys [keys]}]
... | null | https://raw.githubusercontent.com/exoscale/pithos/54790f00fbfd330c6196d42e5408385028d5e029/src/io/pithos/keystore.clj | clojure | (ns io.pithos.keystore
"A keystore is a simple protocol which yields a map
of tenant details for a key id.
The basic implementation wants keys from the configuration
file, you'll likely want to use a custom implementation that
interacts with your user-base here.
")
(defn map-keystore [{:keys [keys]}]
... | |
5439783633eec778fcf4318ce29e5001b2ffd9ec375e5965ed5b19fd50170c91 | flyspeck/flyspeck | arith_float.mli | open Hol_core
open Num
val mk_num_exp : term -> term -> term
val dest_num_exp : term -> (term * term)
val dest_float : term -> (string * term * term)
val float_lt0 : term -> thm
val float_gt0 : term -> thm
val float_lt : term -> term -> thm
val float_le0 : term -> thm
val float_ge... | null | https://raw.githubusercontent.com/flyspeck/flyspeck/05bd66666b4b641f49e5131a37830f4881f39db9/azure/formal_ineqs-nat/arith/arith_float.mli | ocaml | open Hol_core
open Num
val mk_num_exp : term -> term -> term
val dest_num_exp : term -> (term * term)
val dest_float : term -> (string * term * term)
val float_lt0 : term -> thm
val float_gt0 : term -> thm
val float_lt : term -> term -> thm
val float_le0 : term -> thm
val float_ge... | |
a999ad9e32bc96320e4cda096ffcf7e06c9b5fa25e3697b81c4915c6590af9f9 | CardanoSolutions/ogmios | WspSpec.hs | This Source Code Form is subject to the terms of the Mozilla Public
License , v. 2.0 . If a copy of the MPL was not distributed with this
file , You can obtain one at /.
# LANGUAGE QuasiQuotes #
# LANGUAGE TypeApplications #
module Codec.Json.WspSpec
( spec,
)
where
import Prelude
import Data.Aeson
... | null | https://raw.githubusercontent.com/CardanoSolutions/ogmios/c52916ab99244a905556919c9e88bc47f3fbc250/server/modules/json-wsp/test/unit/Codec/Json/WspSpec.hs | haskell | This Source Code Form is subject to the terms of the Mozilla Public
License , v. 2.0 . If a copy of the MPL was not distributed with this
file , You can obtain one at /.
# LANGUAGE QuasiQuotes #
# LANGUAGE TypeApplications #
module Codec.Json.WspSpec
( spec,
)
where
import Prelude
import Data.Aeson
... | |
feebce48955883347e9355fe1bb4064b99a9a6a2a8bd804b8a64b1a47108f639 | sebhoss/bc-clj | key_generator.clj | ;
Copyright © 2013 < >
; This work is free. You can redistribute it and/or modify it under the
terms of the Do What The Fuck You Want To Public License , Version 2 ,
as published by . See / for more details .
;
(ns bouncycastle.key-generator
"Wrapper around key-generators provided by Bouncy Castle."
(:i... | null | https://raw.githubusercontent.com/sebhoss/bc-clj/62a8fa69d729e7efee91574e0243c411c2172b0a/src/main/clojure/bouncycastle/key_generator.clj | clojure |
This work is free. You can redistribute it and/or modify it under the
| Copyright © 2013 < >
terms of the Do What The Fuck You Want To Public License , Version 2 ,
as published by . See / for more details .
(ns bouncycastle.key-generator
"Wrapper around key-generators provided by Bouncy Castle."
(:import javax.crypto.KeyGenerator
(java.security KeyPairGenerator P... |
f47ad41b06e3cc4db848390de334992b35c2dcc563b7d9c2298f026dc8eff3b9 | oliyh/kamera | core_test.cljs | (ns example.core-test
(:require
[cljs.test :refer-macros [deftest is testing]]
[example.core :refer [hello-user]]
[devcards.core :refer-macros [defcard-rg]]))
(defcard-rg hello-user-test
[hello-user false])
| null | https://raw.githubusercontent.com/oliyh/kamera/8e9b3708a16c09ffbdc7ffa7894e3d023dcb7101/example/test/example/core_test.cljs | clojure | (ns example.core-test
(:require
[cljs.test :refer-macros [deftest is testing]]
[example.core :refer [hello-user]]
[devcards.core :refer-macros [defcard-rg]]))
(defcard-rg hello-user-test
[hello-user false])
| |
e36724e073792b3eec19e98624310e98e2f15589ab9d349a89caae6c04729e28 | 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)]
(recipe-db/find-all-recipes (:da... | null | https://raw.githubusercontent.com/jacekschae/learn-datomic-course-files/d27af218b89006497fd868d58b58b282e7c3e38c/increments/23-list-all-recipes-tests/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)]
(recipe-db/find-all-recipes (:da... |
63f57edbe4c77dfddaba2d5f7c5d71ec975c155f5560c1541ce08f6dc25b1771 | Ericson2314/lighthouse | Parse.hs | Copyright ( c ) 2000 Galois Connections , Inc.
-- All rights reserved. This software is distributed as
-- free software under the license in the file "LICENSE",
-- which is included in the distribution.
module Parse where
import Char
import Text.ParserCombinators.Parsec hiding (token)
import Data
program :: Par... | null | https://raw.githubusercontent.com/Ericson2314/lighthouse/210078b846ebd6c43b89b5f0f735362a01a9af02/ghc-6.8.2/libraries/hpc/tests/raytrace/Parse.hs | haskell | All rights reserved. This software is distributed as
free software under the license in the file "LICENSE",
which is included in the distribution.
No whitespace after slash
Tests for numbers
Hugs breaks on big exponents (> ~40)
Always int or real
FIXME: Handle error conditions
---------------------------------... | Copyright ( c ) 2000 Galois Connections , Inc.
module Parse where
import Char
import Text.ParserCombinators.Parsec hiding (token)
import Data
program :: Parser Code
program =
do { whiteSpace
; ts <- tokenList
; eof
; return ts
}
tokenList :: Parser Code
tokenList = many token <?> "list of ... |
0926a3572fc96ada68389636a3998c4839207d0c60cfa37fec6958ba752d6637 | xapi-project/xen-api | xapi_vtpm.ml |
Copyright ( C ) Citrix Systems Inc.
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 ; version 2.1 only . with the special
exception on linking described in file LICENS... | null | https://raw.githubusercontent.com/xapi-project/xen-api/48cc1489fff0e344246ecf19fc1ebed6f09c7471/ocaml/xapi/xapi_vtpm.ml | ocaml | verify contents to be already base64-encoded |
Copyright ( C ) Citrix Systems Inc.
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 ; version 2.1 only . with the special
exception on linking described in file LICENS... |
fcb93051106a6665cb02436dddbfbd00263657cdc8a04382eae1984adbcda90c | clojure/core.rrb-vector | test_utils.clj | (ns clojure.core.rrb-vector.test-utils
(:require [clojure.test :as test]
[clojure.string :as str]
[clojure.core.rrb-vector.rrbt :as rrbt]))
;; Parts of this file are nearly identical to
;; src/test/cljs/clojure/core/rrb_vector/test_utils.cljs, but also
significant parts are specific to each... | null | https://raw.githubusercontent.com/clojure/core.rrb-vector/88c2f814b47c0bbc4092dad82be2ec783ed2961f/src/test/clojure/clojure/core/rrb_vector/test_utils.clj | clojure | Parts of this file are nearly identical to
src/test/cljs/clojure/core/rrb_vector/test_utils.cljs, but also
give much benefit to do so.
ex-message was added. | (ns clojure.core.rrb-vector.test-utils
(:require [clojure.test :as test]
[clojure.string :as str]
[clojure.core.rrb-vector.rrbt :as rrbt]))
significant parts are specific to each of the clj / cljs versions , so
while they could later be combined into a .cljc file , it may not
(def extra-... |
c6c8666273e7a08a14c28f21260caa7ecbe99b68780a558a53a62cc904e06031 | janestreet/base_quickcheck | test_generator.mli | include module type of Base_quickcheck.Generator
| null | https://raw.githubusercontent.com/janestreet/base_quickcheck/b3dc5bda5084253f62362293977e451a6c4257de/test/src/test_generator.mli | ocaml | include module type of Base_quickcheck.Generator
| |
a664ea8d8ce8a13a73a4ee94c732ecfcbe7f968fc6a90a4766c9b47b7c78b6b8 | okuoku/nausicaa | test-mpf.sps | ;;;
Part of : / MP
Contents : tests for the MPF numbers
Date : Thu Nov 27 , 2008
;;;
;;;Abstract
;;;
;;;
;;;
Copyright ( c ) 2008 , 2009 < >
;;;
;;;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 Foundat... | null | https://raw.githubusercontent.com/okuoku/nausicaa/50e7b4d4141ad4d81051588608677223fe9fb715/mp/tests/test-mpf.sps | scheme |
Abstract
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
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 warra... | Part of : / MP
Contents : tests for the MPF numbers
Date : Thu Nov 27 , 2008
Copyright ( c ) 2008 , 2009 < >
the Free Software Foundation , either version 3 of the License , or ( at
General Public License for more details .
You should have received a copy of the GNU General Public License
(import (nausic... |
e8842ccc4d6016ed99b71c341db106cf47b8385138ad351d424e558957b8a6cc | nineties/Choco | Liveness.hs | -------------------------------------------------
Choco --
Chikadzume Oriented Compiler --
Copyright 2007 - 2008 by Basement fairy --
-------------------------------------------------
module Liveness (fundecl) where
{- liveness analysis -}
import Ch... | null | https://raw.githubusercontent.com/nineties/Choco/0081351d0b556ff74f096accb65c9ab45d29ddfe/src/Liveness.hs | haskell | -----------------------------------------------
-----------------------------------------------
liveness analysis
Sanity check: only function parameters can be live at entrypoint | module Liveness (fundecl) where
import Choco
import Mach
import Outputable
import Panic
import Proc
import Reg
import Control.Monad.State
import qualified Data.Set as S
isNormal r = case loc r of
Register r -> normalRegFirst <= r && r < normalRegEnd
_ -> True
normalArgs i = filter isNormal (args i)
liveness ... |
d7c1f331daaa3099384908f3324fde21f4564ad5dd7ac53d68df224f877e4bbd | qfpl/reflex-dom-storage | Example.hs | |
Copyright : ( c ) 2018 , Commonwealth Scientific and Industrial Research Organisation
License : :
Stability : experimental
Portability : non - portable
Copyright : (c) 2018, Commonwealth Scientific and Industrial Research Organisation
License : BSD3
Maintainer :
Stability : experi... | null | https://raw.githubusercontent.com/qfpl/reflex-dom-storage/2ffa13a48740681993dead6a10830c23d251d3a4/example/frontend/src/Storage/Example.hs | haskell | # LANGUAGE GADTs #
# LANGUAGE OverloadedStrings # | |
Copyright : ( c ) 2018 , Commonwealth Scientific and Industrial Research Organisation
License : :
Stability : experimental
Portability : non - portable
Copyright : (c) 2018, Commonwealth Scientific and Industrial Research Organisation
License : BSD3
Maintainer :
Stability : experi... |
5b18b6440b89bb4ff62c6648e38e40d4a88a863ebff7882d5485733a2c4d8483 | haskellari/edit-distance | Benchmark.hs | # OPTIONS_GHC -fno - full - laziness #
module Main where
import Text.EditDistance.EditCosts
import Text.EditDistance.MonadUtilities
import qualified Text.EditDistance as BestEffort
import qualified Text.EditDistance.Bits as Bits
import qualified Text.EditDistance.STUArray as STUArray
import qualifi... | null | https://raw.githubusercontent.com/haskellari/edit-distance/5521afd4f4966a947499a16cfc7ce6d9e0a028ee/Text/EditDistance/Benchmark.hs | haskell | with the benchmarking
Our sample is the time taken to find the edit distance | # OPTIONS_GHC -fno - full - laziness #
module Main where
import Text.EditDistance.EditCosts
import Text.EditDistance.MonadUtilities
import qualified Text.EditDistance as BestEffort
import qualified Text.EditDistance.Bits as Bits
import qualified Text.EditDistance.STUArray as STUArray
import qualifi... |
fd0ca10bfd3a2f7880e048717fe04d2184294bdff0b2e893242a02e1dcb87bc5 | pgujjula/list-utilities | Filter.hs | | Module : Data . List . Filter
Description : Special takes and drops on lists
Copyright : ( c ) , 2020
License : BSD3
Maintainer : pgujjula+
Stability : experimental
Special takes and drops on lists .
Description : Special takes and drops on lists
Copyrig... | null | https://raw.githubusercontent.com/pgujjula/list-utilities/03d26bb5a16fa0fb7ae5b112e1897fbf79d11c92/list-filter/src/Data/List/Filter.hs | haskell | | Module : Data . List . Filter
Description : Special takes and drops on lists
Copyright : ( c ) , 2020
License : BSD3
Maintainer : pgujjula+
Stability : experimental
Special takes and drops on lists .
Description : Special takes and drops on lists
Copyrig... | |
c45cf867cf52be580fbc6abd77a42f4bc4feaaa3af743f83d76f4db0e2e49d88 | Mathieu-Desrochers/Schemings | jansson.scm | (declare (unit jansson))
(foreign-declare "
#include <jansson.h>
")
;; jansson types definition
(define-foreign-type json-t "json_t")
(define-foreign-type json-t* (c-pointer json-t))
(define-foreign-type json-error-t "json_error_t")
(define-foreign-type json-error-t* (c-pointer json-error-t))
;; returns a new jans... | null | https://raw.githubusercontent.com/Mathieu-Desrochers/Schemings/3df7c8f8589a1c9c4135a3ae4c1bab3244e6444c/sources/foreign-interfaces/jansson.scm | scheme | jansson types definition
returns a new jansson object
returns a new jansson array
returns a new jansson value
sets the value of key to value in object
appends a value to the end of array
returns the jansson representation as a string
decodes the jansson string input
returns the type of the jansson value
retur... | (declare (unit jansson))
(foreign-declare "
#include <jansson.h>
")
(define-foreign-type json-t "json_t")
(define-foreign-type json-t* (c-pointer json-t))
(define-foreign-type json-error-t "json_error_t")
(define-foreign-type json-error-t* (c-pointer json-error-t))
(define json-object (foreign-lambda json-t* "json... |
ca3fe47d9d570b2b14b9ddc24cf9b3778aeddb78c186c06a3cb49df6f26e5e30 | aiya000/haskell-examples | Main.hs | # LANGUAGE DataKinds #
# LANGUAGE FlexibleContexts #
# LANGUAGE OverloadedLabels #
# LANGUAGE TypeApplications #
import Data.Extensible (Associate, WriterEff, Eff, tellEff, leaveEff, runWriterEff)
context :: ( Associate "greet" (WriterEff [String]) xs
, Associate "message" (WriterEff [String]) xs
... | null | https://raw.githubusercontent.com/aiya000/haskell-examples/a337ba0e86be8bb1333e7eea852ba5fa1d177d8a/Data/Extensible/Effect/Main.hs | haskell | # LANGUAGE DataKinds #
# LANGUAGE FlexibleContexts #
# LANGUAGE OverloadedLabels #
# LANGUAGE TypeApplications #
import Data.Extensible (Associate, WriterEff, Eff, tellEff, leaveEff, runWriterEff)
context :: ( Associate "greet" (WriterEff [String]) xs
, Associate "message" (WriterEff [String]) xs
... | |
dd3b217eeaf6129755c990267fbc1de707c62260584cabdeadff69c5fdfd2d4d | danr/hipspec | PropT20.hs | module PropT20 where
import Prelude(Bool(..))
import Zeno
-- Definitions
True && x = x
_ && _ = False
False || x = x
_ || _ = True
not True = False
not False = True
-- Nats
data Nat = S Nat | Z
(+) :: Nat -> Nat -> Nat
Z + y = y
(S x) + y = S (x + y)
(*) :: Nat -> Nat -> Nat
Z * _ = Z
(S x) * y = y + (x... | null | https://raw.githubusercontent.com/danr/hipspec/a114db84abd5fee8ce0b026abc5380da11147aa9/testsuite/prod/zeno_version/PropT20.hs | haskell | Definitions
Nats
Lists
Theorem | module PropT20 where
import Prelude(Bool(..))
import Zeno
True && x = x
_ && _ = False
False || x = x
_ || _ = True
not True = False
not False = True
data Nat = S Nat | Z
(+) :: Nat -> Nat -> Nat
Z + y = y
(S x) + y = S (x + y)
(*) :: Nat -> Nat -> Nat
Z * _ = Z
(S x) * y = y + (x * y)
(==),(/=) :: Nat... |
a91de598d9ccb4eaa8440e4b7a2b37e547663662e88e8539829f81fd99442d20 | nmattia/niv | Cmd.hs | {-# LANGUAGE RankNTypes #-}
module Niv.Cmd where
import qualified Data.Aeson as Aeson
import qualified Data.Text as T
import Niv.Sources
import Niv.Update
import qualified Options.Applicative as Opts
-- TODO: add filter
data Cmd = Cmd
{ description :: forall a. Opts.InfoMod a,
parseCmdShortcut :: T.Text -> May... | null | https://raw.githubusercontent.com/nmattia/niv/94080ae8286024820c570a2a24ed7c36d7ad04a9/src/Niv/Cmd.hs | haskell | # LANGUAGE RankNTypes #
TODO: add filter
| Some notes to print |
module Niv.Cmd where
import qualified Data.Aeson as Aeson
import qualified Data.Text as T
import Niv.Sources
import Niv.Update
import qualified Options.Applicative as Opts
data Cmd = Cmd
{ description :: forall a. Opts.InfoMod a,
parseCmdShortcut :: T.Text -> Maybe (PackageName, Aeson.Object),
parsePackage... |
78f30b6019d2c98fc17c828f1586613a804ee070ece0d954959579d534d850f0 | monadbobo/ocaml-core | crit_bit.mli | open Core.Std
type 'data t
val empty : 'data t
val find : 'data t -> string -> 'data option
val add : 'data t -> key:string -> data:'data -> 'data t
val remove : 'data t -> string -> 'data t
val iter : 'data t -> f:(key:string -> data:'data -> unit) -> unit
val map : 'data t -> f:('data -> 'b) -> 'b ... | null | https://raw.githubusercontent.com/monadbobo/ocaml-core/9c1c06e7a1af7e15b6019a325d7dbdbd4cdb4020/base/core/extended/lib/crit_bit.mli | ocaml | open Core.Std
type 'data t
val empty : 'data t
val find : 'data t -> string -> 'data option
val add : 'data t -> key:string -> data:'data -> 'data t
val remove : 'data t -> string -> 'data t
val iter : 'data t -> f:(key:string -> data:'data -> unit) -> unit
val map : 'data t -> f:('data -> 'b) -> 'b ... | |
c6abf54deb5efaca46053d1a51588b886d69f82b426af0892e22362199cfbb97 | scalaris-team/scalaris | unittest_helper.erl | 2008 - 2018 Zuse Institute Berlin
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
% you may not use this file except in compliance with the License.
% You may obtain a copy of the License at
%
% -2.0
%
% Unless required by applicable law or agreed to in writing, software
d... | null | https://raw.githubusercontent.com/scalaris-team/scalaris/feb894d54e642bb3530e709e730156b0ecc1635f/test/unittest_helper.erl | erlang | you may not use this file except in compliance with the License.
You may obtain a copy of the License at
-2.0
Unless required by applicable law or agreed to in writing, software
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language gov... | 2008 - 2018 Zuse Institute Berlin
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
distributed under the License is distributed on an " AS IS " BASIS ,
@author < >
-module(unittest_helper).
-author('').
-vsn('$Id$').
-define(TRACE_RING_DATA(), ok).
-export([get_scalaris_port/0,... |
38f680d6eab0ae456c15c7927a4f866daf7967c424e413c2539d632a1bf527cf | helium/router | console_callback.erl | -module(console_callback).
-behaviour(elli_handler).
-behaviour(elli_websocket_handler).
-include("console_test.hrl").
-export([
init/2,
handle/2,
handle_event/3
]).
-export([
websocket_init/2,
websocket_handle/3,
websocket_info/3,
websocket_handle_event/3
]).
init(Req, Args) ->
cas... | null | https://raw.githubusercontent.com/helium/router/8a103868831e99f72600ba34ef2f8ea2c3351e51/test/utils/console_callback.erl | erlang | Get All Devices
Get Device
Get token
Report status
POST to channel
Upgrade to a websocket connection.
websocket is closed:
See RFC-6455 () for a list of
valid WS status codes than can be used on a close frame.
in regards to your server and sub-protocol. | -module(console_callback).
-behaviour(elli_handler).
-behaviour(elli_websocket_handler).
-include("console_test.hrl").
-export([
init/2,
handle/2,
handle_event/3
]).
-export([
websocket_init/2,
websocket_handle/3,
websocket_info/3,
websocket_handle_event/3
]).
init(Req, Args) ->
cas... |
46090a612cd26f58c298b997f034dc849066ba88f2ac9a601a1adc400d8c2521 | sebsheep/elm2node | Magnitude.hs | module Elm.Magnitude
( Magnitude(..)
, toChars
)
where
-- MAGNITUDE
data Magnitude
= PATCH
| MINOR
| MAJOR
deriving (Eq, Ord)
toChars :: Magnitude -> String
toChars magnitude =
case magnitude of
PATCH -> "PATCH"
MINOR -> "MINOR"
MAJOR -> "MAJOR"
| null | https://raw.githubusercontent.com/sebsheep/elm2node/602a64f48e39edcdfa6d99793cc2827b677d650d/compiler/src/Elm/Magnitude.hs | haskell | MAGNITUDE | module Elm.Magnitude
( Magnitude(..)
, toChars
)
where
data Magnitude
= PATCH
| MINOR
| MAJOR
deriving (Eq, Ord)
toChars :: Magnitude -> String
toChars magnitude =
case magnitude of
PATCH -> "PATCH"
MINOR -> "MINOR"
MAJOR -> "MAJOR"
|
376ae1464d56efdcf85938975bf07d9484dcdb44e918945e22f5470b192b1e48 | ahrefs/monorobot | action.ml | open Devkit
open Base
open Slack
open Config_t
open Common
open Github_j
exception Action_error of string
let action_error msg = raise (Action_error msg)
let log = Log.from "action"
module Action (Github_api : Api.Github) (Slack_api : Api.Slack) = struct
let partition_push (cfg : Config_t.config) n =
let defau... | null | https://raw.githubusercontent.com/ahrefs/monorobot/93ccfca195f81d5e7534f0b0d0777e191f07e00e/lib/action.ml | ocaml | non-main branch build notifications go to default channel to reduce spam in topic channels
| Github.Push n -> Some n.sender.login
| Pull_request n -> Some n.sender.login
| PR_review n -> Some n.sender.login
| PR_review_comment n -> Some n.sender.login
| Issue n -> So... | open Devkit
open Base
open Slack
open Config_t
open Common
open Github_j
exception Action_error of string
let action_error msg = raise (Action_error msg)
let log = Log.from "action"
module Action (Github_api : Api.Github) (Slack_api : Api.Slack) = struct
let partition_push (cfg : Config_t.config) n =
let defau... |
ac1130b98cb79e65a062996986f789a5be8b5771376ad99c583887a2c17345c3 | geophf/1HaskellADay | Exercise.hs | module Y2020.M09.D08.Exercise where
-
Yesterday * ...
-
Yesterday* ...
--}
import Y2020.M09.D01.Exercise
-
* time is so fluid for me , ... it being time , and all ... * rolleyes *
... we build this city ...
... wait : we built this ONTOLOGY of words to novels in the top 100 - read
books in gutenberg . ... | null | https://raw.githubusercontent.com/geophf/1HaskellADay/514792071226cd1e2ba7640af942667b85601006/exercises/HAD/Y2020/M09/D08/Exercise.hs | haskell | }
}
A little helper-function to load the ontology
}
0. How many words are in all the books?
}
}
}
occur in multiple books, if they occur just once in any book, what are these
words?
}
} | module Y2020.M09.D08.Exercise where
-
Yesterday * ...
-
Yesterday* ...
import Y2020.M09.D01.Exercise
-
* time is so fluid for me , ... it being time , and all ... * rolleyes *
... we build this city ...
... wait : we built this ONTOLOGY of words to novels in the top 100 - read
books in gutenberg .
O... |
26dfc1db17d14546167831ee18d1bcda6c4f552e1f6b60ab96438dd9fcf19928 | mirage/ocaml-openflow | flowvisor.ml |
* Copyright ( c ) 2011 < >
*
* Permission to use , copy , modify , and distribute this software for any
* purpose with or without fee is hereby granted , provided that the above
* copyright notice and this permission notice appear in all copies .
*
* THE SOFTWARE IS PROVIDED " AS IS " AND THE AU... | null | https://raw.githubusercontent.com/mirage/ocaml-openflow/dcda113745e8edc61b5508eb8ac2d1e864e1a2df/lib/flowvisor.ml | ocaml | fake switch state to be exposed to controllers
counters
controller and switch storage
Mapping transients id values
topology managment module
xid buffer controller functions
communication primitives
find the controller that should handle the packet in
************************************************
* Sw... |
* Copyright ( c ) 2011 < >
*
* Permission to use , copy , modify , and distribute this software for any
* purpose with or without fee is hereby granted , provided that the above
* copyright notice and this permission notice appear in all copies .
*
* THE SOFTWARE IS PROVIDED " AS IS " AND THE AU... |
bc475991b3e9c00f70b0f71c0f06e81aef1f93d8932f2ca02ea2b2be57d39287 | fragnix/fragnix | Data.ByteString.Base64.hs | # LANGUAGE Haskell98 #
# LINE 1 " Data / ByteString / Base64.hs " #
# LANGUAGE CPP #
# LANGUAGE Trustworthy #
-- |
-- Module : Data.ByteString.Base64
Copyright : ( c ) 2010
--
-- License : BSD-style
-- Maintainer :
-- Stability : experimental
Porta... | null | https://raw.githubusercontent.com/fragnix/fragnix/b9969e9c6366e2917a782f3ac4e77cce0835448b/tests/packages/scotty/Data.ByteString.Base64.hs | haskell | |
Module : Data.ByteString.Base64
License : BSD-style
Maintainer :
Stability : experimental
Fast and efficient encoding and decoding of base64-encoded strings.
| Encode a string into base64 form. The result will always be a
| Decode a base64-encoded string. This function strictly follows
<>.
... | # LANGUAGE Haskell98 #
# LINE 1 " Data / ByteString / Base64.hs " #
# LANGUAGE CPP #
# LANGUAGE Trustworthy #
Copyright : ( c ) 2010
Portability : GHC
module Data.ByteString.Base64
(
encode
, decode
, decodeLenient
, joinWith
) where
... |
3d2b627e57f47dc2cb020fbe20023009e855a1ecaf8861823de634b6f814bf7a | mmontone/gestalt | transactions.lisp | (require :ele-bdb)
(require :hunchentoot)
(require :cl-who)
(defpackage tapp
(:use :cl :elephant :hunchentoot :cl-who))
(in-package :tapp)
(setf hunchentoot:*catch-errors-p* nil)
(setf hunchentoot:*HUNCHENTOOT-DEFAULT-EXTERNAL-FORMAT*
(flexi-streams:make-external-format :utf8 :eol-style :lf))
(start (make... | null | https://raw.githubusercontent.com/mmontone/gestalt/fd019c0ca03b4efc73b9ddd3db1e3ed211233428/examples/transactions.lisp | lisp | (require :ele-bdb)
(require :hunchentoot)
(require :cl-who)
(defpackage tapp
(:use :cl :elephant :hunchentoot :cl-who))
(in-package :tapp)
(setf hunchentoot:*catch-errors-p* nil)
(setf hunchentoot:*HUNCHENTOOT-DEFAULT-EXTERNAL-FORMAT*
(flexi-streams:make-external-format :utf8 :eol-style :lf))
(start (make... | |
59ca105f51cd09a26f15cdcc260b76cdc5a28e6b5c2835dbffcbeb8fb68de6fb | UU-ComputerScience/js-asteroids | WX.hs | --------------------------------------------------------------------------------
| Module : WX
Copyright : ( c ) 2003
License : wxWindows
Maintainer :
Stability : provisional
Portability : portable
The WX module just re - exports functionality from helper modules a... | null | https://raw.githubusercontent.com/UU-ComputerScience/js-asteroids/b7015d8ad4aa57ff30f2631e0945462f6e1ef47a/wxasteroids/src/Graphics/UI/WX.hs | haskell | ------------------------------------------------------------------------------
------------------------------------------------------------------------------
* Functions
* Modules
, module Graphics.UI.WX.Layout
, module Graphics.UI.WX.Frame
, module Graphics.UI.WX.Menu
, module Graphics.UI.WX.Dialogs
| 'start' runs ... | | Module : WX
Copyright : ( c ) 2003
License : wxWindows
Maintainer :
Stability : provisional
Portability : portable
The WX module just re - exports functionality from helper modules and
defines the ' start ' function .
The WX library provides a /haskellized/ ... |
29f9acb0951b4e509801c55e8933af703e8cb2cb38c31824959d5ff747e1d017 | haroldcarr/learn-haskell-coq-ml-etc | EntityTagCacheNoSigs.hs | # OPTIONS_GHC -fno - warn - missing - signatures -fno - warn - unused - binds #
{-# LANGUAGE OverloadedStrings #-}
module EntityTagCacheNoSigs where
import Control.Monad ((>=>))
import Data.List (isPrefixOf)
import Data.Map.Strict as M
import Data.Maybe as MB (mapM... | null | https://raw.githubusercontent.com/haroldcarr/learn-haskell-coq-ml-etc/b4e83ec7c7af730de688b7376497b9f49dc24a0e/haskell/playpen/interview/api-catalog/src/EntityTagCacheNoSigs.hs | haskell | # LANGUAGE OverloadedStrings #
----------------------------------------------------------------------------
entity id to tag numbers
next tag number
tag to tag number
tag number to tag
----------------------------------------------------------------------------
Use cache
impure
pure
-----------------------------... | # OPTIONS_GHC -fno - warn - missing - signatures -fno - warn - unused - binds #
module EntityTagCacheNoSigs where
import Control.Monad ((>=>))
import Data.List (isPrefixOf)
import Data.Map.Strict as M
import Data.Maybe as MB (mapMaybe)
import Prelude ... |
aa4eab5d2edfe18b4be62cdf874ad7b51b2c7c16e8659912a2e3198ec0c5eb32 | rizo/streams-bench | Config.ml | let length = ref (int_of_float (2.0 ** 10.0))
let limit = ref (!length / 2)
let main_ops = ref "all"
let configure () =
begin
try
main_ops := Sys.getenv "STREAMS_BENCHMARK";
length := int_of_string (Sys.getenv "STREAMS_LENGTH");
limit := int_of_string (Sys.getenv "STREAMS_LIMIT")
with Not_f... | null | https://raw.githubusercontent.com/rizo/streams-bench/87baf838971c84613b801ab32b6473d397bcc23f/experiments/Config.ml | ocaml | let length = ref (int_of_float (2.0 ** 10.0))
let limit = ref (!length / 2)
let main_ops = ref "all"
let configure () =
begin
try
main_ops := Sys.getenv "STREAMS_BENCHMARK";
length := int_of_string (Sys.getenv "STREAMS_LENGTH");
limit := int_of_string (Sys.getenv "STREAMS_LIMIT")
with Not_f... | |
dedeb1e7e8139a0ecb04afee4612bebace0437f33437eb940ae3b68721cd2407 | blitz/stumpwm | primitives.lisp | Copyright ( C ) 2003 - 2008
;;
This file is part of stumpwm .
;;
stumpwm 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.
stumpwm is ... | null | https://raw.githubusercontent.com/blitz/stumpwm/439180985920a628b18d4426f1a29b1c36576531/primitives.lisp | lisp |
you can redistribute it and/or modify
either version 2 , or ( at your option )
any later version.
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
along with this software; see the file COPY... | Copyright ( C ) 2003 - 2008
This file is part of stumpwm .
it under the terms of the GNU General Public License as published by
stumpwm is distributed in the hope that it will be useful ,
You should have received a copy of the GNU General Public License
the Free Software Foundation , Inc. , 59 Temple P... |
4bdbb8ba7415409cd0690579fd3488669330096360aa11577eed87250b2262cc | simedw/Kandidat | Debugger.hs | # LANGUAGE NamedFieldPuns #
{-# LANGUAGE PackageImports #-}
# LANGUAGE PatternGuards #
# LANGUAGE RecordWildCards #
module Debugger where
import "mtl" Control.Monad.State
import Data.Function
import Data.List
import qualified Data.Map as M
import System( getArgs )
import System.Console.GetOpt
import System.Directory
i... | null | https://raw.githubusercontent.com/simedw/Kandidat/fbf68edf5b003aba2ce13dac32ee1b94172d57d8/test/Debugger.hs | haskell | # LANGUAGE PackageImports #
[":force!"] -> forcing st >> loop st
[":force", var] -> forceit st var >> loop st
if forceStg opts | # LANGUAGE NamedFieldPuns #
# LANGUAGE PatternGuards #
# LANGUAGE RecordWildCards #
module Debugger where
import "mtl" Control.Monad.State
import Data.Function
import Data.List
import qualified Data.Map as M
import System( getArgs )
import System.Console.GetOpt
import System.Directory
import System.FilePath
import qua... |
cdb8260947fb19f99db3f4239e3406cbeb21d0ec22509e98e307968a427c8332 | tomsmalley/semantic-reflex | Dimmer.hs | # LANGUAGE RecursiveDo #
# LANGUAGE TemplateHaskell #
-- | Semantic UI dimmers. Pure reflex implementation is provided.
-- -ui.com/modules/dimmers.html
module Reflex.Dom.SemanticUI.Dimmer
(
dimmer, dimmer'
, DimmerConfig (..)
, dimmerConfig_inverted
, dimmerConfig_page
, dimmerConfig_dimmed
, dimmerCo... | null | https://raw.githubusercontent.com/tomsmalley/semantic-reflex/5a973390fae1facbc4351b75ea59210d6756b8e5/semantic-reflex/src/Reflex/Dom/SemanticUI/Dimmer.hs | haskell | | Semantic UI dimmers. Pure reflex implementation is provided.
-ui.com/modules/dimmers.html
^ Dimmers can be inverted
^ Dimmers can dim the whole page
^ Dimmer state control
^ Type of transition to use
^ Duration of transition
^ User can click out of a dimmer
^ Config
| Make the dimmer div classes from the co... | # LANGUAGE RecursiveDo #
# LANGUAGE TemplateHaskell #
module Reflex.Dom.SemanticUI.Dimmer
(
dimmer, dimmer'
, DimmerConfig (..)
, dimmerConfig_inverted
, dimmerConfig_page
, dimmerConfig_dimmed
, dimmerConfig_transitionType
, dimmerConfig_duration
, dimmerConfig_closeOnClick
, dimmerConfig_elCon... |
b7565047f2bded1e0ba4f41ccf2fb9ede724e27e4c19ab8d2662ba63e7a68f69 | resttime/cl-liballegro | file-io.lisp | (in-package :cl-liballegro)
(defcenum seek
(:seek-set 0)
(:seek-cur)
(:seek-end))
| null | https://raw.githubusercontent.com/resttime/cl-liballegro/0f8a3a77d5c81fe14352d9a799cba20e1a3a90b4/src/constants/file-io.lisp | lisp | (in-package :cl-liballegro)
(defcenum seek
(:seek-set 0)
(:seek-cur)
(:seek-end))
| |
6d33903c9b3adb42dfd923cba42c35fb072731f863323fd4bc6f8fcc2020b97b | avsm/ocaml-ssh | kex.mli |
* Copyright ( c ) 2004,2005 Anil Madhavapeddy < >
*
* Permission to use , copy , modify , and distribute this software for any
* purpose with or without fee is hereby granted , provided that the above
* copyright notice and this permission notice appear in all copies .
*
* THE SOFTWARE IS PROVIDED... | null | https://raw.githubusercontent.com/avsm/ocaml-ssh/26577d1501e7a43e4b520239b08da114c542eda4/lib/kex.mli | ocaml |
* Copyright ( c ) 2004,2005 Anil Madhavapeddy < >
*
* Permission to use , copy , modify , and distribute this software for any
* purpose with or without fee is hereby granted , provided that the above
* copyright notice and this permission notice appear in all copies .
*
* THE SOFTWARE IS PROVIDED... | |
5638e1559fac037dbde7ab0471b412346a191c7089923fbfd5ec643e62f8671b | hypernumbers/hypernumbers | stdfuns_info.erl | %%% @doc Built-in information functions.
@author < >
@private
( C ) 2009 - 2014 , Hypernumbers Ltd.
%%%-------------------------------------------------------------------
%%%
%%% LICENSE
%%%
%%% This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero Gener... | null | https://raw.githubusercontent.com/hypernumbers/hypernumbers/281319f60c0ac60fb009ee6d1e4826f4f2d51c4e/lib/formula_engine-1.0/src/stdfuns_info.erl | erlang | @doc Built-in information functions.
-------------------------------------------------------------------
LICENSE
This program is free software: you can redistribute it and/or modify
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
ME... | @author < >
@private
( C ) 2009 - 2014 , Hypernumbers Ltd.
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation version 3
You should have received a copy of the GNU Affero General Public License
-module(stdfuns_info).
fns that pass test
-export(... |
a5afe38aa7b473cc1d23dd1ba0d2ec27dbec2aa5bafc65ef401698a6b5852847 | zmactep/hasbolt-sample-app | Routes.hs | {-# LANGUAGE OverloadedStrings #-}
module Routes where
import Control.Monad.Trans (lift, liftIO)
import Control.Monad.Trans.Reader (ask)
import Data.Pool (withResource)
import Data.Text.Lazy (Text, toStrict)
import Database.Bolt
imp... | null | https://raw.githubusercontent.com/zmactep/hasbolt-sample-app/bae5aae8ed21e6b8779fe8041a681b3fbb1e746d/src/Routes.hs | haskell | # LANGUAGE OverloadedStrings #
|Main page route
|Graph response route
|Search response route
|Movie response route |
module Routes where
import Control.Monad.Trans (lift, liftIO)
import Control.Monad.Trans.Reader (ask)
import Data.Pool (withResource)
import Data.Text.Lazy (Text, toStrict)
import Database.Bolt
import Web.Scotty.Trans ... |
c9b79e2f89cff7d797aaa1da76da991fadb2db4d15dce6938a135e0088369ab3 | kowainik/tomland | Key.hs | # LANGUAGE PatternSynonyms #
|
Module : Toml . Type . Key
Copyright : ( c ) 2018 - 2022 Kowainik
SPDX - License - Identifier : MPL-2.0
Maintainer : < >
Stability : Stable
Portability : Portable
Implementation of key type . Th... | null | https://raw.githubusercontent.com/kowainik/tomland/561aefdbcf177498c06e6c6fcee2b3fe299b3af6/src/Toml/Type/Key.hs | haskell | * Core types
* Key difference
can't happen
| Bidirectional pattern synonym for constructing and deconstructing 'Key's.
# COMPLETE (:||) #
# INLINE (<|) #
^ Keys are equal
^ Keys don't have any common part.
^ Key have a common prefix.
^ Common prefix. | # LANGUAGE PatternSynonyms #
|
Module : Toml . Type . Key
Copyright : ( c ) 2018 - 2022 Kowainik
SPDX - License - Identifier : MPL-2.0
Maintainer : < >
Stability : Stable
Portability : Portable
Implementation of key type . Th... |
1ceb3a9a9c20f8b7cedd5492a2750d15cad56f2fb5b55beeacff5eac7c8fc270 | paurkedal/batyr | xmpp_inst.mli | Copyright ( C ) 2013 - -2019 < >
*
* This program is free software : you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation , either version 3 of the License , or
* ( at your option ) any later version .
*
... | null | https://raw.githubusercontent.com/paurkedal/batyr/e7b290340afea5b80880f9ab96db769142438a77/batyr-on-xmpp/lib/xmpp_inst.mli | ocaml | * XMPP based on erm-xmpp specialized for Lwt.
* {2 Basic Session} | Copyright ( C ) 2013 - -2019 < >
*
* This program is free software : you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation , either version 3 of the License , or
* ( at your option ) any later version .
*
... |
dbe7e4550c67e854460fc592a3c52a6784100f44d575439f1469ee50f0b4d909 | ocamllabs/ocaml-modular-implicits | callback.mli | (***********************************************************************)
(* *)
(* OCaml *)
(* *)
, projet ... | null | https://raw.githubusercontent.com/ocamllabs/ocaml-modular-implicits/92e45da5c8a4c2db8b2cd5be28a5bec2ac2181f1/stdlib/callback.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 GNU Library General Public License , with
val register : string -> 'a -> unit
v... |
0b7dd064595571fcf70f400b1fa7de484336cbcb39c894d6329af17592760a7a | spacegangster/gcal-clj | specs_calendar.clj | (ns gcal-clj.specs-calendar
(:require [clojure.spec.alpha :as s]
[common.specs]
[common.specs.http]
[gcal-clj.specs-event]
[gcal-clj.specs-macros :as sm]))
(s/def :s.gcal.prop.calendar/kind #{"calendar#calendar"})
(sm/mapdef1 :s.gcal.prop/notification-settings
{:s.p... | null | https://raw.githubusercontent.com/spacegangster/gcal-clj/c7b14d6330f1099adb1b9ae6f5631dfebde0cbd3/src/gcal_clj/specs_calendar.clj | clojure | Calendar List entry
:opt-un for calendar list entry
Calendar plain #resource | (ns gcal-clj.specs-calendar
(:require [clojure.spec.alpha :as s]
[common.specs]
[common.specs.http]
[gcal-clj.specs-event]
[gcal-clj.specs-macros :as sm]))
(s/def :s.gcal.prop.calendar/kind #{"calendar#calendar"})
(sm/mapdef1 :s.gcal.prop/notification-settings
{:s.p... |
3ac69cd41033de53704a15e109b9bc2d2769d881fc3238f282e110d86fae13a3 | janestreet/merlin-jst | outcometree.mli | (**************************************************************************)
(* *)
(* OCaml *)
(* *)
, ... | null | https://raw.githubusercontent.com/janestreet/merlin-jst/980b574405617fa0dfb0b79a84a66536b46cd71b/upstream/ocaml_flambda/typing/outcometree.mli | ocaml | ************************************************************************
OCaml
... | , projet Cristal , INRIA Rocquencourt
Copyright 2001 Institut National de Recherche en Informatique et
the GNU Lesser General Public License version 2.1 , with the
These types represent messages that the toplevel displays as normal
results or errors . The real display... |
6e7b8ef312bcae590721f4e69e782731e252a430f8c84ca874f7a5f06e9a3a0a | maximk/spawnpool | redirect_handler.erl | -module(redirect_handler).
-export([init/3]).
-export([handle/2,terminate/3]).
-define(ZERGLING_IMAGE, <<"/home/mk/zergling/vmling">>).
-define(BRIDGE, <<"xenbr0">>).
-define(BASIC_EXTRA,
"-notify 10.0.0.1:8909 -shutdown_after 15000 "
" -home /zergling "
"-pz /zergling/ebin "
"-pz /zergling/deps/cowboy/ebi... | null | https://raw.githubusercontent.com/maximk/spawnpool/f6a36a7634e0d08a6ab48d7bdaa5d2b548d96bcc/src/redirect_handler.erl | erlang | ------------------------------------------------------------------------------ | -module(redirect_handler).
-export([init/3]).
-export([handle/2,terminate/3]).
-define(ZERGLING_IMAGE, <<"/home/mk/zergling/vmling">>).
-define(BRIDGE, <<"xenbr0">>).
-define(BASIC_EXTRA,
"-notify 10.0.0.1:8909 -shutdown_after 15000 "
" -home /zergling "
"-pz /zergling/ebin "
"-pz /zergling/deps/cowboy/ebi... |
b7863e28115f331660c3a32fc75144008ef0f9385fccae3567db63781547a311 | the-little-typer/pie | pretty.rkt | #lang racket/base
(require racket/function racket/list racket/match)
(require "resugar.rkt")
(provide pprint-pie pprint-message indented)
(define indentation (make-parameter 0))
(define-syntax indented
(syntax-rules ()
[(_ i e ...)
(parameterize ([indentation (+ i (indentation))])
(begin e ...))... | null | https://raw.githubusercontent.com/the-little-typer/pie/a698d4cacd6823b5161221596d34bd17ce5282b8/pretty.rkt | racket | Always display something, even if the print code is borked | #lang racket/base
(require racket/function racket/list racket/match)
(require "resugar.rkt")
(provide pprint-pie pprint-message indented)
(define indentation (make-parameter 0))
(define-syntax indented
(syntax-rules ()
[(_ i e ...)
(parameterize ([indentation (+ i (indentation))])
(begin e ...))... |
5db67de7ca45facc86bc9435adb10b430f7fa41d9e5ae0581c78fdd518e8ba23 | LPCIC/matita | grafiteDisambiguate.mli | Copyright ( C ) 2004 - 2005 , HELM Team .
*
* This file is part of HELM , an Hypertextual , Electronic
* Library of Mathematics , developed at the Computer Science
* Department , University of Bologna , Italy .
*
* is free software ; you can redistribute it and/or
* modify it under the terms of ... | null | https://raw.githubusercontent.com/LPCIC/matita/794ed25e6e608b2136ce7fa2963bca4115c7e175/matita/components/ng_disambiguation/grafiteDisambiguate.mli | ocaml | implicit ones are made explicit
args: print function, message (may be empty), status | Copyright ( C ) 2004 - 2005 , HELM Team .
*
* This file is part of HELM , an Hypertextual , Electronic
* Library of Mathematics , developed at the Computer Science
* Department , University of Bologna , Italy .
*
* is free software ; you can redistribute it and/or
* modify it under the terms of ... |
b2eea17176e6fbe304fe3122dd6698a458636d3246174a2d5be2683c71843707 | ghcjs/ghcjs | t4136.hs | module Main where
data T = (:=:) {- | (:!=:) -} deriving (Show,Read)
main
= do putStrLn ("show (:=:) = " ++ show (:=:))
putStrLn ("read (show (:=:)) :: T = " ++
show (read (show (:=:)) :: T))
| null | https://raw.githubusercontent.com/ghcjs/ghcjs/e4cd4232a31f6371c761acd93853702f4c7ca74c/test/ghc/deriving/t4136.hs | haskell | | (:!=:) | module Main where
main
= do putStrLn ("show (:=:) = " ++ show (:=:))
putStrLn ("read (show (:=:)) :: T = " ++
show (read (show (:=:)) :: T))
|
11300a2928bcedcfb90153e431f6ab1e0259f5794f760c9680e240fbef2ec050 | a9032676/Codewars-Haskell | AdditionCommutes_Definitions.hs | {-# LANGUAGE GADTs #-}
# LANGUAGE TypeFamilies #
# LANGUAGE TypeOperators #
module AdditionCommutes_Definitions where
-- | The natural numbers, encoded in types.
data Z
data S n
-- | Predicate describing natural numbers.
-- | This allows us to reason with `Nat`s.
data Natural :: * -> * where
NumZ :: Nat... | null | https://raw.githubusercontent.com/a9032676/Codewars-Haskell/6eccd81e9b6ae31b5c0a28ecc16b933f3abae1a5/src/AdditionCommutes_Definitions.hs | haskell | # LANGUAGE GADTs #
| The natural numbers, encoded in types.
| Predicate describing natural numbers.
| This allows us to reason with `Nat`s.
| Predicate describing equality of natural numbers.
| Peano definition of addition.
These are some lemmas that may be helpful.
They will *not* be tested, so rename t... | # LANGUAGE TypeFamilies #
# LANGUAGE TypeOperators #
module AdditionCommutes_Definitions where
data Z
data S n
data Natural :: * -> * where
NumZ :: Natural Z
NumS :: Natural n -> Natural (S n)
data Equal :: * -> * -> * where
EqlZ :: Equal Z Z
EqlS :: Equal n m -> Equal (S n) (S m)
type family (:+:... |
4168dcc87f460833ba8bc0ff660258443ee0c340f0aec026d6b7b26a103c6d5e | pbv/codex | Limits.hs | {-# LANGUAGE OverloadedStrings #-}
{-
Limits for memory, cpu time, etc. under a "sandbox"
-}
module Codex.Tester.Limits (
Limits(..),
lookupLimits,
) where
import Data.Configurator.Types(Config)
import qualified Data.Configurator as Configurator
import Control.Monad (mplus)
-- | SafeEx... | null | https://raw.githubusercontent.com/pbv/codex/1a5a81965b12f834b436e2165c07120360aded99/src/Codex/Tester/Limits.hs | haskell | # LANGUAGE OverloadedStrings #
Limits for memory, cpu time, etc. under a "sandbox"
| SafeExec limits
seconds
seconds
KB
KB
KB
KB
| empty element; no limits set
| combine limits; left-hand side overrriding right-hand side
| lookup limits from a subconfig | module Codex.Tester.Limits (
Limits(..),
lookupLimits,
) where
import Data.Configurator.Types(Config)
import qualified Data.Configurator as Configurator
import Control.Monad (mplus)
data Limits
, numProc :: !(Maybe Int)
} deriving (Eq, Show, Read)
instance Monoid L... |
1e1d3c6f6c703ae0438ad1f862ec788317cc182427b10d5e8e1c0f1f69721c80 | schemedoc/implementation-metadata | airship.scm | (title "Airship Scheme")
(person "Michael Babich")
| null | https://raw.githubusercontent.com/schemedoc/implementation-metadata/6280d9c4c73833dc5bd1c9bef9b45be6ea5beb68/schemes/airship.scm | scheme | (title "Airship Scheme")
(person "Michael Babich")
| |
ba30a45351ff605b16909585885c8b1f469eb0f268c1246babc183dd11e456ec | project-oak/hafnium-verification | exec.ml |
* Copyright ( c ) Facebook , Inc. and its affiliates .
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree .
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
... | null | https://raw.githubusercontent.com/project-oak/hafnium-verification/6071eff162148e4d25a0fedaea003addac242ace/experiments/ownership-inference/infer/sledge/src/symbheap/exec.ml | ocaml | * Symbolic Execution
* generic command: [∀xs. {foot ∧ sub} ms := - {post}]
Overwritten variables renaming and remaining modified variables. [ws] are
the written variables; [rs] are the variables read or in the
precondition; [us] are the variables to which ghosts must be chosen
fresh.
* Instruction small ... |
* Copyright ( c ) Facebook , Inc. and its affiliates .
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree .
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
... |
cd602954912d62af488430adf948c382362d8270e89a5242ff89ef7ecdd532db | mcorbin/meuse | ring.clj | (ns meuse.interceptor.ring
(:require [ring.middleware.cookies :as cookies]
[ring.middleware.params :as params]
[ring.middleware.keyword-params :as keyword-params]))
(def keyword-params
{:name ::keyword-params
:enter (fn [ctx] (update ctx :request keyword-params/keyword-params-request))})... | null | https://raw.githubusercontent.com/mcorbin/meuse/d2b74543fce37c8cde770ae6f6097cabb509a804/src/meuse/interceptor/ring.clj | clojure | (ns meuse.interceptor.ring
(:require [ring.middleware.cookies :as cookies]
[ring.middleware.params :as params]
[ring.middleware.keyword-params :as keyword-params]))
(def keyword-params
{:name ::keyword-params
:enter (fn [ctx] (update ctx :request keyword-params/keyword-params-request))})... | |
88b2a86c044cc9ad4c7584cbf6ffb9c154d2f2b3b8dedbde12ac4167b4caf4b7 | robert-strandh/SICL | segment.lisp | (cl:in-package #:sicl-elf)
(defparameter *segment-type*
'((0 . :unused-entry)
(1 . :loadable-segment)
(2 . :dynamic-link-tables)
(3 . :program-interpreter-path-name)
(4 . :note-sections)
5 is reserved
(6 . :program-header-table)))
(defparameter *segment-attribute*
'((#x1 . :execute-permissio... | null | https://raw.githubusercontent.com/robert-strandh/SICL/7ecf9978aba7e11744b58da60dbcb49cf1b81b0a/Code/ELF/segment.lisp | lisp | Physical address is reserved.
Size of segment in file. Maybe this value needs to be rounded up?
Size of segment in memory. Maybe this value needs to be rounded up? | (cl:in-package #:sicl-elf)
(defparameter *segment-type*
'((0 . :unused-entry)
(1 . :loadable-segment)
(2 . :dynamic-link-tables)
(3 . :program-interpreter-path-name)
(4 . :note-sections)
5 is reserved
(6 . :program-header-table)))
(defparameter *segment-attribute*
'((#x1 . :execute-permissio... |
f5461b4b2ac36d6da00492ce201c0069038a9dc8785e0674538a5633e6041910 | robert-strandh/Second-Climacs | view-name.lisp | (cl:in-package #:second-climacs-base)
(defgeneric view-name (view)
(:method (view) "Unknown"))
| null | https://raw.githubusercontent.com/robert-strandh/Second-Climacs/45f683249fcdec364991a28342b223469a3fb3ad/Code/Base/view-name.lisp | lisp | (cl:in-package #:second-climacs-base)
(defgeneric view-name (view)
(:method (view) "Unknown"))
| |
285dd20f26361e02ee5f80d9d5cb3b4f654a5009a0a6762235065392e2438e2b | yitzchak/common-lisp-jupyter | select.lisp | (in-package #:jupyter/widgets)
(defwidget base-select (description-widget %options-labels-slot disabled-slot)
((rows
:initarg :rows
:initform 5
:accessor widget-rows
:documentation "The number of rows to display."
:trait :int)))
(defwidget select (base-select index-slot)
((options
:... | null | https://raw.githubusercontent.com/yitzchak/common-lisp-jupyter/a1dc775e4116ab61b34530fe33f3e27291d937f4/src/widgets/select.lisp | lisp | Simulate value property below | (in-package #:jupyter/widgets)
(defwidget base-select (description-widget %options-labels-slot disabled-slot)
((rows
:initarg :rows
:initform 5
:accessor widget-rows
:documentation "The number of rows to display."
:trait :int)))
(defwidget select (base-select index-slot)
((options
:... |
3251eed8c5965db2e7e88cb696e2b47285c4977c4fbbfa609c67dd0de4eace29 | mhuebert/chia | routers.cljs | (ns chia.routing.routers
(:require [chia.db :as db]))
(def db-id :db/routers)
(defn get-router
([]
(db/entity db-id))
([k]
;; keep :routers here?
(db/get db-id k))) | null | https://raw.githubusercontent.com/mhuebert/chia/74ee3ee9f86efbdf81d8829ab4f0a44d619c73d3/routing/src/chia/routing/routers.cljs | clojure | keep :routers here? | (ns chia.routing.routers
(:require [chia.db :as db]))
(def db-id :db/routers)
(defn get-router
([]
(db/entity db-id))
([k]
(db/get db-id k))) |
0d357ceccb6965cd2f9f0980a3dc2e84d2199856ee483f2375e04e06852baf24 | haskell-repa/repa | Int.hs |
module Data.Array.Repa.Series.Prim.Int where
import Data.Array.Repa.Series.Rate
import Data.Array.Repa.Series.Prim.Utils
import Data.Array.Repa.Series.Vector as V
import Data.Array.Repa.Series.Series as S
import Data.Array.Repa.Series.Ref as Ref
import GHC.Exts
import GHC.Types
Ref --------------------... | null | https://raw.githubusercontent.com/haskell-repa/repa/c867025e99fd008f094a5b18ce4dabd29bed00ba/icebox/abandoned/repa-series/Data/Array/Repa/Series/Prim/Int.hs | haskell | ----------------------------------------------------------------------
# INLINE [1] repa_newRefInt #
# INLINE [1] repa_readRefInt #
# INLINE [1] repa_writeRefInt #
Vector ---------------------------------------------------------------------
# INLINE [1] repa_newVectorInt #
# INLINE [1] repa_readVectorInt #
# INLINE [1... |
module Data.Array.Repa.Series.Prim.Int where
import Data.Array.Repa.Series.Rate
import Data.Array.Repa.Series.Prim.Utils
import Data.Array.Repa.Series.Vector as V
import Data.Array.Repa.Series.Series as S
import Data.Array.Repa.Series.Ref as Ref
import GHC.Exts
import GHC.Types
repa_newRefInt ::... |
1c21e68db3922c97f39e0a8afd0742719626eea7083c63a532eb265c1286fb95 | ocaml/opam | opamProcess.mli | (**************************************************************************)
(* *)
Copyright 2012 - 2018 OCamlPro
Copyright 2012 INRIA
(* ... | null | https://raw.githubusercontent.com/ocaml/opam/800dc5be9a51a14c3a1f35bfc08d914930ab866f/src/core/opamProcess.mli | ocaml | ************************************************************************
All rights reserved. This file is distributed under the terms of the
exception on linking descr... | Copyright 2012 - 2018 OCamlPro
Copyright 2012 INRIA
GNU Lesser General Public License version 2.1 , with the special
type command
* Builds a shell command for later execution .
@param env enviro... |
7eaa1d08b418bc5c002a42833b152b42e3dd075bd0793b187f088153f3ce4f80 | ragkousism/Guix-on-Hurd | lout.scm | ;;; GNU Guix --- Functional package management for GNU
Copyright © 2012 , 2013 < >
;;;
;;; 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/ragkousism/Guix-on-Hurd/e951bb2c0c4961dc6ac2bda8f331b9c4cee0da95/gnu/packages/lout.scm | scheme | GNU Guix --- Functional package management for GNU
This file is part of GNU Guix.
you can redistribute it and/or modify it
either version 3 of the License , or ( at
your option) any later version.
GNU Guix is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied wa... | Copyright © 2012 , 2013 < >
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 lout)
#:use-module (guix licenses)
#:use-module (guix packages)
#:use-mo... |
a3f2475bbb7ea201401073c85281af6f1c280e50826576f1035caaf8ff0249d1 | Helium4Haskell/helium | MonadInstance1.hs |
main = do
x <- return 3
y <- Just "Hello"
let z = True
return (x, y, z) | null | https://raw.githubusercontent.com/Helium4Haskell/helium/5928bff479e6f151b4ceb6c69bbc15d71e29eb47/test/typeClasses/MonadInstance1.hs | haskell |
main = do
x <- return 3
y <- Just "Hello"
let z = True
return (x, y, z) | |
df488fbf75f4fb7902ba7a416b5f86fcdcbd2e0d84ddb9023a5b8838037cf6a3 | avsm/platform | max_indent.ml | let () =
fooooo
|> List.iter (fun x ->
let x = x $ y in
fooooooooooo x)
let () =
fooooo
|> List.iter
(fun some_really_really_really_long_name_that_doesn't_fit_on_the_line ->
let x =
some_really_really_really_long_name_that_doesn't_fit_on_the_line $ y
in
fooooooooooo x)
| null | https://raw.githubusercontent.com/avsm/platform/b254e3c6b60f3c0c09dfdcde92eb1abdc267fa1c/duniverse/ocamlformat.0.12/test/passing/max_indent.ml | ocaml | let () =
fooooo
|> List.iter (fun x ->
let x = x $ y in
fooooooooooo x)
let () =
fooooo
|> List.iter
(fun some_really_really_really_long_name_that_doesn't_fit_on_the_line ->
let x =
some_really_really_really_long_name_that_doesn't_fit_on_the_line $ y
in
fooooooooooo x)
| |
89cce621e00db67e10a18fc18e44dd1632a22aa80a67187d2a6aa3f8ddb718b1 | Chris00/ocaml-rope | rope.ml | File : rope.ml
Copyright ( C ) 2007
email :
WWW : /
This library is free software ; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License version 2.1 or
later as published by the Free Software Foundation , with the special
... | null | https://raw.githubusercontent.com/Chris00/ocaml-rope/be74c6069e407a40fc8c1f2cc41741e3224781fd/src/rope.ml | ocaml | One assumes throughout that the length is a representable
integer. Public functions that allow to construct larger ropes
must check this.
* Use this as leaf when creating fresh leaves. Also sub-ropes of
length [<= small_rope_length] may be flattened by [concat2].
This value must be quite small, ty... | File : rope.ml
Copyright ( C ) 2007
email :
WWW : /
This library is free software ; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License version 2.1 or
later as published by the Free Software Foundation , with the special
... |
108b9447b5cc918ef64e110ca7dc1dd2da658bb5b0b506176ca7a142b2c0701c | zenspider/schemers | exercise.1.28.scm | #lang racket/base
Exercise 1.28 :
One variant of the Fermat test that can not be fooled is called the
" - Rabin test " ( 1976 ; 1980 ) . This starts from an
alternate form of Fermat 's Little Theorem , which states that if n
;; is a prime number and a is any positive integer less than n, then a
raised to... | null | https://raw.githubusercontent.com/zenspider/schemers/2939ca553ac79013a4c3aaaec812c1bad3933b16/sicp/ch_1/exercise.1.28.scm | scheme | 1980 ) . This starts from an
is a prime number and a is any positive integer less than n, then a
random number a<n and raise a to the (n - 1)st power modulo n using
the `expmod' procedure. However, whenever we perform the squaring
step in `expmod', we check to see if we have discovered a
is not prime. It is also... | #lang racket/base
Exercise 1.28 :
One variant of the Fermat test that can not be fooled is called the
alternate form of Fermat 's Little Theorem , which states that if n
raised to the ( n - 1)st power is congruent to 1 modulo n. To test
the primality of a number n by the - Rabin test , we pick a
" nontri... |
0e7214797be3b776f1d993d22c32b386508c2166c3351a417a358e78f068aaae | grin-compiler/ghc-wpc-sample-programs | Common.hs | |
Module : . Package . Common
Description : Data structures common to all ` iPKG ` file formats .
License : : The Idris Community .
Module : Idris.Package.Common
Description : Data structures common to all `iPKG` file formats.
License : BSD3
Maintainer : The Idris Community.
-}
module... | null | https://raw.githubusercontent.com/grin-compiler/ghc-wpc-sample-programs/0e3a9b8b7cc3fa0da7c77fb7588dd4830fb087f7/idris-1.3.3/src/Idris/Package/Common.hs | haskell | ^ Name associated with a package.
^ List of packages this package depends on.
^ Brief description of the package.
^ Version string to associate with the package.
^ Location of the README file.
^ Description of the licensing information.
^ Author information.
^ Maintainer information.
^ Website associated with ... | |
Module : . Package . Common
Description : Data structures common to all ` iPKG ` file formats .
License : : The Idris Community .
Module : Idris.Package.Common
Description : Data structures common to all `iPKG` file formats.
License : BSD3
Maintainer : The Idris Community.
-}
module... |
f17c9ff22fe48bbdd06bf4bdbac10ae809ffbbece1dec3bd409416169b33bcd5 | dannypsnl/typed-nanopass | define-language.rkt | #lang typed/racket
(provide define-language)
(require syntax/parse/define
(for-syntax ee-lib
fancy-app
racket/syntax
syntax/stx))
(define-for-syntax (prefix-id prefix id)
(format-id id #:source id #:props id "~a:~a" prefix id))
(begin-for-synta... | null | https://raw.githubusercontent.com/dannypsnl/typed-nanopass/4db0a30ab394b410f70cc988a528e8e056a2210c/define-language.rkt | racket | TODO: how to check this is a valid type in typed/racket?
TODO:
Currently, we have only simple rule-case
there should have a syntax
rule-case => rule-pretty-form
for example,
(bind ,x ,ty) => (,x : ,ty)... | #lang typed/racket
(provide define-language)
(require syntax/parse/define
(for-syntax ee-lib
fancy-app
racket/syntax
syntax/stx))
(define-for-syntax (prefix-id prefix id)
(format-id id #:source id #:props id "~a:~a" prefix id))
(begin-for-synta... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.