_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 |
|---|---|---|---|---|---|---|---|---|
fc69e1efbc248d3f0386e941a733c66b43d7fd30c32323fc573f8f314d35ddae | swtwsk/vinci-lang | FreeVariables.hs | module Core.FreeVariables (
freeVariablesProg,
freeVariablesExpr
) where
import Control.Monad.Reader
import qualified Data.Set as Set
import Data.Functor ((<&>))
import Core.AST
type VarSet a = Set.Set (VarId a)
freeVariablesProg :: (EquableFunctor a) => Prog a -> VarSet a
freeVariablesProg (Prog f args e) ... | null | https://raw.githubusercontent.com/swtwsk/vinci-lang/9c7e01953e0b1cf135af7188e0c71fe6195bdfa1/src/Core/FreeVariables.hs | haskell | module Core.FreeVariables (
freeVariablesProg,
freeVariablesExpr
) where
import Control.Monad.Reader
import qualified Data.Set as Set
import Data.Functor ((<&>))
import Core.AST
type VarSet a = Set.Set (VarId a)
freeVariablesProg :: (EquableFunctor a) => Prog a -> VarSet a
freeVariablesProg (Prog f args e) ... | |
163fac98892d7d143c754d7475fefdf63de4ca640332f391036ecc57ac241038 | andy128k/cl-gobject-introspection | trampoline.lisp | (in-package :gir)
(defvar *trampolines* (make-hash-table))
(defun make-trampoline (func &optional pointer)
(let ((ptr (or pointer (cffi:foreign-alloc :int))))
(setf (gethash (cffi:pointer-address ptr) *trampolines*) func)
ptr))
(defun trampoline-get-function (ptr)
(gethash (cffi:pointer-address ptr) *tra... | null | https://raw.githubusercontent.com/andy128k/cl-gobject-introspection/13f7ea0c4b33ec0f91eed5131d271dc74f6ea3d2/src/trampoline.lisp | lisp | (in-package :gir)
(defvar *trampolines* (make-hash-table))
(defun make-trampoline (func &optional pointer)
(let ((ptr (or pointer (cffi:foreign-alloc :int))))
(setf (gethash (cffi:pointer-address ptr) *trampolines*) func)
ptr))
(defun trampoline-get-function (ptr)
(gethash (cffi:pointer-address ptr) *tra... | |
81b3df90f8423584e02481a62eefd53e69e665fb9a2368f62581056e433b711a | ocaml/merlin | mreader_recover.mli | module Make
(Parser : MenhirLib.IncrementalEngine.EVERYTHING)
(Recovery : sig
val default_value : Location.t -> 'a Parser.symbol -> 'a
type action =
| Abort
| R of int
| S : 'a Parser.symbol -> action
| Sub of action list
type decision =
| Noth... | null | https://raw.githubusercontent.com/ocaml/merlin/e576bc75f11323ec8489d2e58a701264f5a7fe0e/src/kernel/mreader_recover.mli | ocaml | module Make
(Parser : MenhirLib.IncrementalEngine.EVERYTHING)
(Recovery : sig
val default_value : Location.t -> 'a Parser.symbol -> 'a
type action =
| Abort
| R of int
| S : 'a Parser.symbol -> action
| Sub of action list
type decision =
| Noth... | |
18ec27fe200a23ac20dc247cc80b0b8717f699b9d6dd1094e506cef06bb29ab9 | blindglobe/lisp-matrix | macros.lisp | (in-package :lisp-matrix)
(defmacro define-abstract-class (classname super-list &body body)
"A wrapper for DEFCLASS that lets you define abstract base classes.
If you try to instantiate an object of this class, a warning is signaled."
`(progn
(defclass ,classname ,super-list ,@body)
;; Protect agains... | null | https://raw.githubusercontent.com/blindglobe/lisp-matrix/f9c88dae132baf52884dd54612581d1331b82b40/src/macros.lisp | lisp | Protect against abstract class instantiation.
We could remove this programmatically later using a
compile-time constant (or even check the optimization options
and remove it if SAFETY is set low enough). | (in-package :lisp-matrix)
(defmacro define-abstract-class (classname super-list &body body)
"A wrapper for DEFCLASS that lets you define abstract base classes.
If you try to instantiate an object of this class, a warning is signaled."
`(progn
(defclass ,classname ,super-list ,@body)
(defmethod initi... |
ef482631b6900cbee65fcef57c07034869e21e5b699dcf720e309a341fc40cc5 | ocaml/uchar | testpkg.ml |
let () =
Format.printf "%a\n" Uchar.dump (Uchar.of_int 0x1F42B) | null | https://raw.githubusercontent.com/ocaml/uchar/f9988830581a1f233d32e79aaacf8af76ddb9613/test/testpkg.ml | ocaml |
let () =
Format.printf "%a\n" Uchar.dump (Uchar.of_int 0x1F42B) | |
eaeb6d083fd773fce85ec4fe8a597377483bcbfa1c4c4e065d0d968f85c31051 | slipstream/SlipStreamServer | resource_metadata_value_scope.cljc | (ns com.sixsq.slipstream.ssclj.resources.spec.resource-metadata-value-scope
"schema definitions for the 'vscope' field of a ResourceMetadata resource"
(:require
[clojure.spec.alpha :as s]
[com.sixsq.slipstream.ssclj.resources.spec.resource-metadata-value-scope-enumeration :as enumeration]
[com.sixsq.sli... | null | https://raw.githubusercontent.com/slipstream/SlipStreamServer/3ee5c516877699746c61c48fc72779fe3d4e4652/cimi/src/com/sixsq/slipstream/ssclj/resources/spec/resource_metadata_value_scope.cljc | clojure | FIXME: This function shouldn't be necessary!
There is a problem when using the ::value-scope spec directly in the
trying to validate against single-value or collection-item. Hiding
the details behind this function works, but clearly isn't ideal for
error reporting. The reason for the problem needs to be determine... | (ns com.sixsq.slipstream.ssclj.resources.spec.resource-metadata-value-scope
"schema definitions for the 'vscope' field of a ResourceMetadata resource"
(:require
[clojure.spec.alpha :as s]
[com.sixsq.slipstream.ssclj.resources.spec.resource-metadata-value-scope-enumeration :as enumeration]
[com.sixsq.sli... |
27599d3cb73f8227a981f3a18fee23513e88cbe2e85059757dbbfb1fea1f0c1e | susisu/est-ocaml | printer.mli | open Core
module type Printer_intf = sig
module Config : sig
type options
type t
val options_of_sexp : Sexp.t -> options
val empty_options : options
val merge_options : options -> options -> options
val of_options : default:t -> options -> t
end
val print_to_channel : Config.t -> Out_cha... | null | https://raw.githubusercontent.com/susisu/est-ocaml/e610d07b166a51e5763aa4f7b12449ec0438071c/src/printer.mli | ocaml | open Core
module type Printer_intf = sig
module Config : sig
type options
type t
val options_of_sexp : Sexp.t -> options
val empty_options : options
val merge_options : options -> options -> options
val of_options : default:t -> options -> t
end
val print_to_channel : Config.t -> Out_cha... | |
1879aa15101e2478e0be8a719f9a572f050488ba925da5f2bedd5620534857f3 | treeowl/lazify | Internal.hs | # language AllowAmbiguousTypes #
{-# language CPP #-}
# language DataKinds #
{-# language DefaultSignatures #-}
{-# language FlexibleContexts #-}
# language FlexibleInstances #
# language MultiParamTypeClasses #
# language PolyKinds #
{-# language ScopedTypeVariables #-}
{-# language TypeFamilies #-}
{-# language TypeI... | null | https://raw.githubusercontent.com/treeowl/lazify/3a8edcd13e97779c0848d6eda29e71a15ef299c9/src/Data/Lazify/Internal.hs | haskell | # language CPP #
# language DefaultSignatures #
# language FlexibleContexts #
# language ScopedTypeVariables #
# language TypeFamilies #
# language TypeInType #
# language UndecidableInstances #
matching. This module offers functions for making them lazy
/generically/.
| A class for types that can be lazified. A gen... | # language AllowAmbiguousTypes #
# language DataKinds #
# language FlexibleInstances #
# language MultiParamTypeClasses #
# language PolyKinds #
# language TypeOperators #
# language TypeApplications #
# OPTIONS_HADDOCK not - home #
| Record types in Haskell can be made lazy through lazy pattern
module Data.Lazify.... |
03c9cf7c84f23409e2e652475a4fbdcdbc740c33ada03d2b13a5736d0fd692ea | rurban/clisp | clclock.lisp | ;;; Adapted from -lisp.net/~crhodes/clx by...
Copyright ( C ) 2007 - 2008 < >
This is free software , distributed under the GNU GPL v2 +
(in-package :clx-demos)
(defun required-size (font &optional (extra-width 0) (extra-height 0))
(multiple-value-bind (width-R ascent-R)
(xlib:text-extents font "XVIIII... | null | https://raw.githubusercontent.com/rurban/clisp/75ed2995ff8f5364bcc18727cde9438cca4e7c2c/modules/clx/new-clx/demos/clclock.lisp | lisp | Adapted from -lisp.net/~crhodes/clx by... | Copyright ( C ) 2007 - 2008 < >
This is free software , distributed under the GNU GPL v2 +
(in-package :clx-demos)
(defun required-size (font &optional (extra-width 0) (extra-height 0))
(multiple-value-bind (width-R ascent-R)
(xlib:text-extents font "XVIIII XXXVIIII XXXVIIII")
(multiple-value-bind ... |
7cd2e1fe7662765851ff56d8082d84878bf295c340534449514a23bea5b23201 | dschrempf/elynx | Distance.hs | {-# LANGUAGE OverloadedStrings #-}
-- |
-- Description : Compute distances between trees
Copyright : 2021
License : GPL-3.0 - or - later
--
-- Maintainer :
-- Stability : unstable
-- Portability : portable
--
Creation date : We d May 29 18:09:39 2019 .
--
- Symmetric ( Robinson - Foulds )... | null | https://raw.githubusercontent.com/dschrempf/elynx/4b6907b240d2f91bf7932c79ed38a469b5ed64ed/tlynx/src/TLynx/Distance/Distance.hs | haskell | # LANGUAGE OverloadedStrings #
|
Description : Compute distances between trees
Maintainer :
Stability : unstable
Portability : portable
- Incompatible splits distance.
Compute pairwise distances of a list of input trees. Use given distance
| Distance function
| Input trees
| (index i, index j, dist... |
Copyright : 2021
License : GPL-3.0 - or - later
Creation date : We d May 29 18:09:39 2019 .
- Symmetric ( Robinson - Foulds ) distance .
module TLynx.Distance.Distance
( distance,
)
where
import Control.Monad
( unless,
when,
)
import Control.Monad.IO.Class
import Control.Monad.Trans.... |
b7b3890bb3841c183075a416cf32d8864ffe0699005d70228b4e402144d56fbf | chetmurthy/ensemble | emrg.ml | (**************************************************************)
EMV.ML
Author : , 12/96
Changes : Ohad Rodeh 1/2001
(**************************************************************)
open Printf
(**************************************************************)
type platform =
| Unix
| Other
let platform = m... | null | https://raw.githubusercontent.com/chetmurthy/ensemble/8266a89e68be24a4aaa5d594662e211eeaa6dc89/ensemble/tools/emrg.ml | ocaml | ************************************************************
************************************************************
************************************************************
************************************************************
let file =
try find_path !path file with Not_found ->
exit 0
... | EMV.ML
Author : , 12/96
Changes : Ohad Rodeh 1/2001
open Printf
type platform =
| Unix
| Other
let platform = match Sys.os_type with
| "Unix" -> Unix
| _ -> Other
let read_lines c =
let lines = ref [] in
try
while true do
let line = input_line c in
lines := line :: !lines
done... |
73e68e38a897fbd17e710ff012debad6f07d6fbf9581c6a77884f31230160cde | thelema/ocaml-community | printtyped.ml | (***********************************************************************)
(* *)
(* OCaml *)
(* *)
, ... | null | https://raw.githubusercontent.com/thelema/ocaml-community/ed0a2424bbf13d1b33292725e089f0d7ba94b540/typing/printtyped.ml | ocaml | *********************************************************************
OCaml
... | , INRIA Saclay
Copyright 1999 Institut National de Recherche en Informatique et
en Automatique . All rights reserved . This file is distributed
under the terms of the Q Tublic License version 1.0 .
open Asttypes;;
open Format;;
open Lexing;;
o... |
d92a9ac2bd54baad05b99a68c29546aca30ce2926c28858eedc8c7d85c774274 | RailsOnLisp/thot | thot-epoll.lisp | ;;
;; Thot - http web server
Copyright 2017,2018 Thomas de Grivel < > 0614550127
;;
(in-package :thot)
epoll infos
(defclass epoll-infos ()
((fd :initarg :fd
:reader epoll-fd
:type (unsigned-byte 31))
(agents :initform (make-hash-table)
:reader epoll-agents
:type hash... | null | https://raw.githubusercontent.com/RailsOnLisp/thot/9cfb6c228753a752d9326a8b39a77b77f790263c/thot-epoll.lisp | lisp |
Thot - http web server
Adding an agent
Worker agent
Acceptor agent
Thread event loop | Copyright 2017,2018 Thomas de Grivel < > 0614550127
(in-package :thot)
epoll infos
(defclass epoll-infos ()
((fd :initarg :fd
:reader epoll-fd
:type (unsigned-byte 31))
(agents :initform (make-hash-table)
:reader epoll-agents
:type hash-table)))
Generic epoll agent... |
3782f6c38dcb44d96884a00bd739f36e95fb2430018aaaf95bc89ecc05eec5cf | mirage/ptt | nec.mli | * { 1 : A DKIM signer as a SMTP server . }
This module implements a server which signs incoming emails with a private
RSA key . It re - sends emails with the computed DKIM field .
This module implements a server which signs incoming emails with a private
RSA key. It re-sends emails with the comp... | null | https://raw.githubusercontent.com/mirage/ptt/c4851958be6a3a98c5c267ae963e10cb41eb72e4/lib/nec.mli | ocaml | * { 1 : A DKIM signer as a SMTP server . }
This module implements a server which signs incoming emails with a private
RSA key . It re - sends emails with the computed DKIM field .
This module implements a server which signs incoming emails with a private
RSA key. It re-sends emails with the comp... | |
9bc1ba635860c2a06976e25c86afde74774987680f2f89c0221c6f5064b4a8b0 | iand675/hs-opentelemetry | Processor.hs | -----------------------------------------------------------------------------
-----------------------------------------------------------------------------
|
Module : OpenTelemetry . Processor
Copyright : ( c ) , 2021
License : BSD-3
Description : Hooks for performing actions on ... | null | https://raw.githubusercontent.com/iand675/hs-opentelemetry/b08550db292ca0d8b9ce9156988e6d08dd6a2e61/api/src/OpenTelemetry/Processor.hs | haskell | ---------------------------------------------------------------------------
--------------------------------------------------------------------------- |
|
Module : OpenTelemetry . Processor
Copyright : ( c ) , 2021
License : BSD-3
Description : Hooks for performing actions on the start and end of recording spans
Maintainer :
Stability : experimental
Portability : non - portable ( GHC extensions )
Span pr... |
3c7ef52e46a9821001ee7a77044574793b240599de0b5f8408b4f42ce0ef1776 | mcorbin/riemann-cond-dt-plugin | core_test.clj | (ns riemann-cond-dt.core-test
(:require [riemann-cond-dt.core :refer :all]
[riemann.time :refer :all]
[riemann.time.controlled :refer :all]
[riemann.test :refer [test-stream]]
[clojure.test :refer :all]))
(deftest above-test
(testing "do nothing"
(test-stream (ab... | null | https://raw.githubusercontent.com/mcorbin/riemann-cond-dt-plugin/a584ac0b44be91b11c0255687c7f6cd90d7c1e68/test/riemann_cond_dt/core_test.clj | clojure | too old
event ok
fire event
fire event
fire event
too old
event ok
fire event
ignore old ok event
ignore old ok event
ignored | (ns riemann-cond-dt.core-test
(:require [riemann-cond-dt.core :refer :all]
[riemann.time :refer :all]
[riemann.time.controlled :refer :all]
[riemann.test :refer [test-stream]]
[clojure.test :refer :all]))
(deftest above-test
(testing "do nothing"
(test-stream (ab... |
79822550e89001bc291d708fba7ed6669e19dc6e4cc25651e6b2ee278927abad | karamellpelle/grid | ShadeSceneBegin.hs | grid is a game written in Haskell
Copyright ( C ) 2018
--
-- This file is part of grid.
--
-- grid 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 optio... | null | https://raw.githubusercontent.com/karamellpelle/grid/56729e63ed6404fd6cfd6d11e73fa358f03c386f/source/Game/Run/RunData/Plain/ShadeSceneBegin.hs | haskell |
This file is part of grid.
grid is free software: you can redistribute it and/or modify
(at your option) any later version.
grid is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GN... | grid is a game written in Haskell
Copyright ( C ) 2018
it under the terms of the GNU General Public License as published by
the Free Software Foundation , either version 3 of the License , or
You should have received a copy of the GNU General Public License
module Game.Run.RunData.Plain.ShadeSceneBegin
(
... |
248262878fa76e001049a1b808938ad70cd8ca4ad2b4834db6e9ea4403dd2bcb | clojure-interop/google-cloud-clients | DatabaseAdminSettings$Builder.clj | (ns com.google.cloud.spanner.admin.database.v1.DatabaseAdminSettings$Builder
"Builder for DatabaseAdminSettings."
(:refer-clojure :only [require comment defn ->])
(:import [com.google.cloud.spanner.admin.database.v1 DatabaseAdminSettings$Builder]))
(defn drop-database-settings
"Returns the builder for the sett... | null | https://raw.githubusercontent.com/clojure-interop/google-cloud-clients/80852d0496057c22f9cdc86d6f9ffc0fa3cd7904/com.google.cloud.spanner/src/com/google/cloud/spanner/admin/database/v1/DatabaseAdminSettings%24Builder.clj | clojure | (ns com.google.cloud.spanner.admin.database.v1.DatabaseAdminSettings$Builder
"Builder for DatabaseAdminSettings."
(:refer-clojure :only [require comment defn ->])
(:import [com.google.cloud.spanner.admin.database.v1 DatabaseAdminSettings$Builder]))
(defn drop-database-settings
"Returns the builder for the sett... | |
900ba9c7a39e315ef1fa3545afee0ae0021b889579a670af2c1ab37c25add36f | ekmett/algebra | Hyperbolic.hs | # LANGUAGE MultiParamTypeClasses , FlexibleInstances , TypeFamilies , UndecidableInstances , DeriveDataTypeable #
module Numeric.Coalgebra.Hyperbolic
( Hyperbolic(..)
, HyperBasis(..)
, Hyper(..)
) where
import Control.Applicative
import Control.Monad.Reader.Class
import Data.Data
import Data.Distributive
imp... | null | https://raw.githubusercontent.com/ekmett/algebra/12dd33e848f406dd53d19b69b4f14c93ba6e352b/src/Numeric/Coalgebra/Hyperbolic.hs | haskell | complex basis
| the trivial diagonal algebra
| the hyperbolic trigonometric coalgebra | # LANGUAGE MultiParamTypeClasses , FlexibleInstances , TypeFamilies , UndecidableInstances , DeriveDataTypeable #
module Numeric.Coalgebra.Hyperbolic
( Hyperbolic(..)
, HyperBasis(..)
, Hyper(..)
) where
import Control.Applicative
import Control.Monad.Reader.Class
import Data.Data
import Data.Distributive
imp... |
fb61d3b916195d004efebcc46da2173e50dc3aef298a710ce9b1d2c088405857 | tolysz/ghcjs-stack | PreProcess.hs | -----------------------------------------------------------------------------
-- |
Module : Distribution . Simple . PreProcess
Copyright : ( c ) 2003 - 2005 , ,
-- License : BSD3
--
-- Maintainer :
-- Portability : portable
--
This defines a ' PreProcessor ' abstraction which represents ... | null | https://raw.githubusercontent.com/tolysz/ghcjs-stack/83d5be83e87286d984e89635d5926702c55b9f29/special/cabal/Cabal/Distribution/Simple/PreProcess.hs | haskell | ---------------------------------------------------------------------------
|
License : BSD3
Maintainer :
Portability : portable
that can transform one kind of file into another. There is also a
'PPSuffixHandler' which is a combination of a file extension and a function
lists them in 'knownSuffixHandl... | Module : Distribution . Simple . PreProcess
Copyright : ( c ) 2003 - 2005 , ,
This defines a ' PreProcessor ' abstraction which represents a pre - processor
for configuring a ' PreProcessor ' . It defines a bunch of known built - in
preprocessors like @cpp@ , @cpphs@ , @c2hs@ , , @happy@ , @... |
67dca8312438c9d8fcfb04b082a614029a85c4023c075391a7905c5bfe1157f6 | informatimago/lisp | rfc2822.lisp | -*- coding : utf-8 -*-
;;;;****************************************************************************
FILE : rfc2822.lisp
;;;;LANGUAGE: Common-Lisp
;;;;SYSTEM: Common-Lisp
USER - INTERFACE :
;;;;DESCRIPTION
;;;;
;;;; See defpackage documentation string.
;;;;
< PJB... | null | https://raw.githubusercontent.com/informatimago/lisp/571af24c06ba466e01b4c9483f8bb7690bc46d03/common-lisp/rfc2822/rfc2822.lisp | lisp | ****************************************************************************
LANGUAGE: Common-Lisp
SYSTEM: Common-Lisp
DESCRIPTION
See defpackage documentation string.
LEGAL
This program is free software: you can redistribute it and/or modify
(at your option) any later version.
... | -*- coding : utf-8 -*-
FILE : rfc2822.lisp
USER - INTERFACE :
< PJB > < >
MODIFICATIONS
2005 - 09 - 01 < PJB > Made use of ecma048 / iso6429 .
2004 - 08 - 17 < PJB > Created ( fetched basic functions from antispam.lisp ) .
AGPL3
Copyright 2004 - 2016
it unde... |
685353d756e31d897ef1b734baab158c9fe1758f1168a1f5a396a8d470508c40 | OCamlPro/ezjs | ezjs_bind.ml | open Js_of_ocaml
type string_field = Js.js_string Js.t Js.prop
type int_field = int Js.prop
type float_field = float Js.prop
type bool_field = bool Js.prop
type 'a array_field = 'a Js.js_array Js.t Js.prop
let eval_js txt = ignore(Js.Unsafe.eval_string txt)
let link_js scriptUrl f =
Ezjs_xhr.get "jsreq" scriptUrl ... | null | https://raw.githubusercontent.com/OCamlPro/ezjs/4dc09b1e9eeecd46f3717036303ac704cc49b9a1/libs/utils/ezjs_bind.ml | ocaml | open Js_of_ocaml
type string_field = Js.js_string Js.t Js.prop
type int_field = int Js.prop
type float_field = float Js.prop
type bool_field = bool Js.prop
type 'a array_field = 'a Js.js_array Js.t Js.prop
let eval_js txt = ignore(Js.Unsafe.eval_string txt)
let link_js scriptUrl f =
Ezjs_xhr.get "jsreq" scriptUrl ... | |
aec1a34dfb4a79b718ce8a55b6f85e166153054c7ef0bfef91690b0e121501d4 | deadpendency/deadpendency | GHNodeId.hs | module Common.Model.GitHub.GHNodeId
( GHNodeId (..),
)
where
import Common.Aeson.Aeson (cleanJSONOptions)
import Data.Aeson
newtype GHNodeId = GHNodeId
{ _ntText :: Text
}
deriving stock (Show, Generic, Eq)
instance ToJSON GHNodeId where
toJSON = genericToJSON cleanJSONOptions
toEncoding = genericToEnc... | null | https://raw.githubusercontent.com/deadpendency/deadpendency/170d6689658f81842168b90aa3d9e235d416c8bd/apps/common/src/Common/Model/GitHub/GHNodeId.hs | haskell | module Common.Model.GitHub.GHNodeId
( GHNodeId (..),
)
where
import Common.Aeson.Aeson (cleanJSONOptions)
import Data.Aeson
newtype GHNodeId = GHNodeId
{ _ntText :: Text
}
deriving stock (Show, Generic, Eq)
instance ToJSON GHNodeId where
toJSON = genericToJSON cleanJSONOptions
toEncoding = genericToEnc... | |
8f0a193472314b5a15eff341b9b79a9d9e929d50d2c52b4114fa6231e729c753 | tud-fop/vanda-haskell | XFSA.hs | -----------------------------------------------------------------------------
-- |
Copyright : ( c ) Technische Universität Dresden 2018
-- License : BSD-style
--
-- Stability : unknown
-- Portability : portable
-----------------------------------------------------------------------------
module Vanda.... | null | https://raw.githubusercontent.com/tud-fop/vanda-haskell/3214966361b6dbf178155950c94423eee7f9453e/library/Vanda/Grammar/XFSA.hs | haskell | ---------------------------------------------------------------------------
|
License : BSD-style
Stability : unknown
Portability : portable
--------------------------------------------------------------------------- | Copyright : ( c ) Technische Universität Dresden 2018
module Vanda.Grammar.XFSA (
module X
) where
import Vanda.Grammar.XFSA.XFSA as X
import Vanda.Grammar.XFSA.Closure as X
import Vanda.Grammar.XFSA.Language as X
|
e64761623f22ddf7d1932efcd836d68cdd6c6c4a9d72d1bc45d6669f1a393fd5 | graninas/Hydra | Types.hs | {-|
States that are dependent on labyrinth shape,
player's previous actions, and state of player's inventory.
-}
{-# LANGUAGE DeriveAnyClass #-}
module Labyrinth.Types where
import Labyrinth.Prelude
import Labyrinth.Domain
import Labyrinth.KVDB.Model
type PlayerPos = Pos
type PlayerHP = Int
type BearPos = Pos
type... | null | https://raw.githubusercontent.com/graninas/Hydra/60d591b1300528f5ffd93efa205012eebdd0286c/app/labyrinth/src/Labyrinth/Types.hs | haskell | |
States that are dependent on labyrinth shape,
player's previous actions, and state of player's inventory.
# LANGUAGE DeriveAnyClass # |
module Labyrinth.Types where
import Labyrinth.Prelude
import Labyrinth.Domain
import Labyrinth.KVDB.Model
type PlayerPos = Pos
type PlayerHP = Int
type BearPos = Pos
type PlayerHasTreasure = Bool
type PlayerHasTheMap = Bool
data InventoryState = InventoryState
{ _treasureState :: StateVar PlayerHasTreasure
, ... |
8b0def354178969ef6e445c69545fd65052b4bd4acc1ae32a39cb79c8b692dd5 | mstksg/advent-of-code-2017 | Day10.hs | module AOC2017.Day10 (day10a, day10b, knothash) where
import AOC2017.Types (Challenge)
import AOC2017.Util (strip)
import Data.Bits (xor)
import Data.Char (ord)
import Data.List (foldl')
import Data.List.Split ... | null | https://raw.githubusercontent.com/mstksg/advent-of-code-2017/f9e97680726e87be175cf423241da3048ef6564d/src/AOC2017/Day10.hs | haskell | module AOC2017.Day10 (day10a, day10b, knothash) where
import AOC2017.Types (Challenge)
import AOC2017.Util (strip)
import Data.Bits (xor)
import Data.Char (ord)
import Data.List (foldl')
import Data.List.Split ... | |
7d34ef63d567584389ac24050c33e7bc4842684d21555c46f7dbe0d8f3941264 | Oblosys/proxima | HsTokenScanner.hs |
module HsTokenScanner where
import HsToken
import UU.Scanner.Position
import List(sort)
import UU.Util.BinaryTrees
import CommonTypes
import Maybe
import Char
isAGesc c = c == '@'
lexTokens :: Pos -> String -> [HsToken]
lexTokens = scanTokens keywordstxt keywordsops specialchars opchars
where keywordstxt = []
... | null | https://raw.githubusercontent.com/Oblosys/proxima/f154dff2ccb8afe00eeb325d9d06f5e2a5ee7589/uuagc/src/HsTokenScanner.hs | haskell | }
keyword
'_' |
module HsTokenScanner where
import HsToken
import UU.Scanner.Position
import List(sort)
import UU.Util.BinaryTrees
import CommonTypes
import Maybe
import Char
isAGesc c = c == '@'
lexTokens :: Pos -> String -> [HsToken]
lexTokens = scanTokens keywordstxt keywordsops specialchars opchars
where keywordstxt = []
... |
6908671e6d78676044507102c4c1f5ea67bb5e2f07335962dfb9c79eaba0175a | SonyCSLParis/fcg-hybrids | de-render.lisp |
;; Copyright 2019-present
Sony Computer Science Laboratories Paris
( )
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 ... | null | https://raw.githubusercontent.com/SonyCSLParis/fcg-hybrids/7db632609a36dfa915bcc463b152c0b2bea962d9/languages/English/de-render.lisp | lisp | Copyright 2019-present
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
-2.0
Unless required by applicable law or agreed to in writing, software
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific l... |
Sony Computer Science Laboratories Paris
( )
distributed under the License is distributed on an " AS IS " BASIS ,
(in-package :fcg)
(defmethod de-render ((utterance string) (mode (eql :english-hybrid))
&key (key :english) cxn-inventory (model "en") &allow-other-... |
7fad6c49ff59ed5e2f832ddfe34ab453d060d5bb4673b81ef33ba6670ca312b5 | samply/blaze | executors.clj | (ns blaze.executors
(:import
[java.util.concurrent Executor ExecutorService Executors ThreadFactory]))
(set! *warn-on-reflection* true)
(defn executor? [x]
(instance? Executor x))
(defn executor-service? [x]
(instance? ExecutorService x))
(defn execute!
"Executes the function `f` at some time in the... | null | https://raw.githubusercontent.com/samply/blaze/41244588a59c5d5bf1070da1b263af7b46788268/modules/executor/src/blaze/executors.clj | clojure | (ns blaze.executors
(:import
[java.util.concurrent Executor ExecutorService Executors ThreadFactory]))
(set! *warn-on-reflection* true)
(defn executor? [x]
(instance? Executor x))
(defn executor-service? [x]
(instance? ExecutorService x))
(defn execute!
"Executes the function `f` at some time in the... | |
b1ab2d4cd6600f4c38e80739a02027d2a946ac60c71d0555bf41970577205e7d | RBornat/jape | doubleclick.ml |
Copyright ( C ) 2003 - 19
This file is part of the proof engine , which is part of .
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 ver... | null | https://raw.githubusercontent.com/RBornat/jape/afe9f207e89e965636b43ef8fad38fd1f69737ae/distrib/camlengine/doubleclick.ml | ocaml |
Copyright ( C ) 2003 - 19
This file is part of the proof engine , which is part of .
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 ver... | |
87a83f00bc615f38b84233063d72a65ab1274ee6c56be82b96538a3afece73d3 | mkoppmann/eselsohr | Command.hs | module Lib.App.Command
( -- * Article related
* * CreateArticle
CreateArticle (..)
, createArticle
* *
, ChangeArticleTitle (..)
, changeArticleTitle
-- ** ChangeArticleState
, MarkArticleAsRead (..)
, markArticleAsRead
, MarkArticleAsUnread (..)
, markArticleAsUnread... | null | https://raw.githubusercontent.com/mkoppmann/eselsohr/3bb8609199c1dfda94935e6dde0c46fc429de84e/src/Lib/App/Command.hs | haskell | * Article related
** ChangeArticleState
* Capability related
** CreateUnlockLink
** DeleteShareUnlockLinks
** DeleteShareArticleList
** AddShareArticle
** DeleteShareArticle
** RemoveExpiredCapabilities
* Collection related
** CreateCollection
-----------------------------------------------------------------... | module Lib.App.Command
* * CreateArticle
CreateArticle (..)
, createArticle
* *
, ChangeArticleTitle (..)
, changeArticleTitle
, MarkArticleAsRead (..)
, markArticleAsRead
, MarkArticleAsUnread (..)
, markArticleAsUnread
* * DeleteArticle
, DeleteArticle (..)
, delet... |
d426cb30a701b335636c00455be2bc2da21820b3e7e86b30d4411e503e51b890 | leviroth/ocaml-reddit-api | bounded_set.ml | open! Core
module Make (Hashable : Hashtbl.Key_plain) = struct
type t =
{ capacity : int
; hash_queue : (Hashable.t, unit) Hash_queue.t
}
let create ~capacity =
{ capacity
; hash_queue = Hash_queue.create (Hashtbl.Hashable.of_key (module Hashable))
}
;;
let mem { hash_queue; _ } value... | null | https://raw.githubusercontent.com/leviroth/ocaml-reddit-api/a6c0cb2a325a26aa7c117e77d18ba9cb7c4a1f4b/reddit_api_async/bounded_set.ml | ocaml | open! Core
module Make (Hashable : Hashtbl.Key_plain) = struct
type t =
{ capacity : int
; hash_queue : (Hashable.t, unit) Hash_queue.t
}
let create ~capacity =
{ capacity
; hash_queue = Hash_queue.create (Hashtbl.Hashable.of_key (module Hashable))
}
;;
let mem { hash_queue; _ } value... | |
90f2325e21c7849eff50f9fa2692a653f9f9937bfbaa062275e91ac75036ef86 | pezipink/Pisemble | stack.rkt | #lang pisemble
(require (for-syntax syntax/parse))
(define-syntax (regs stx)
(syntax-parse stx
[(_ ([new-reg old-reg:register]...) expr ...)
#'(let-syntax ([new-reg (make-rename-transformer #'old-reg)] ...)
expr ...)]))
(define-syntax (PUSH-REG-INNER stx)
(writeln stx)
(syntax-parse stx
[(... | null | https://raw.githubusercontent.com/pezipink/Pisemble/63b1a6027af7e6e06d2facec019bed237696dce9/stack.rkt | racket | finished slot
enough room for any reg
otherwise pad the sp with remaning bytes
pad the sp with remaning bytes
define a subroutine. create a label for it and push/pop the supplied
regs as a prologue/epilogue. rename regs to user-friendlty names.
Of course, with a bit more work they could be automatically detected
a... | #lang pisemble
(require (for-syntax syntax/parse))
(define-syntax (regs stx)
(syntax-parse stx
[(_ ([new-reg old-reg:register]...) expr ...)
#'(let-syntax ([new-reg (make-rename-transformer #'old-reg)] ...)
expr ...)]))
(define-syntax (PUSH-REG-INNER stx)
(writeln stx)
(syntax-parse stx
[(... |
d9f164946d84748e7f635839213422153867ba6175fccb7e47a83b602dc83fe6 | arttuka/reagent-material-ui | sos_rounded.cljs | (ns reagent-mui.icons.sos-rounded
"Imports @mui/icons-material/SosRounded as a Reagent component."
(:require-macros [reagent-mui.util :refer [create-svg-icon e]])
(:require [react :as react]
["@mui/material/SvgIcon" :as SvgIcon]
[reagent-mui.util]))
(def sos-rounded (create-svg-icon (e "p... | null | https://raw.githubusercontent.com/arttuka/reagent-material-ui/c7cd0d7c661ab9df5b0aed0213a6653a9a3f28ea/src/icons/reagent_mui/icons/sos_rounded.cljs | clojure | (ns reagent-mui.icons.sos-rounded
"Imports @mui/icons-material/SosRounded as a Reagent component."
(:require-macros [reagent-mui.util :refer [create-svg-icon e]])
(:require [react :as react]
["@mui/material/SvgIcon" :as SvgIcon]
[reagent-mui.util]))
(def sos-rounded (create-svg-icon (e "p... | |
4053f766a9fc043beea934ff9c9296efca6ba18fccdca6146e14d25209c2d3e1 | samply/blaze | spec.clj | (ns blaze.http.util.spec
(:require
[clojure.spec.alpha :as s]))
(s/def :blaze.http.header.element.param/name
string?)
(s/def :blaze.http.header.element.param/value
string?)
(s/def :blaze.http.header.element/param
(s/keys :req-un [:blaze.http.header.element.param/name
:blaze.http.hea... | null | https://raw.githubusercontent.com/samply/blaze/c479410a9198526453a0df769ab7db2e6d5dd654/modules/rest-util/src/blaze/http/util/spec.clj | clojure | (ns blaze.http.util.spec
(:require
[clojure.spec.alpha :as s]))
(s/def :blaze.http.header.element.param/name
string?)
(s/def :blaze.http.header.element.param/value
string?)
(s/def :blaze.http.header.element/param
(s/keys :req-un [:blaze.http.header.element.param/name
:blaze.http.hea... | |
136bbbfc9c666c802ed2bc2d7aa4538d498beb8f339dc28daa218c158572952f | abdulapopoola/SICPBook | helpers.scm | (define (pretty-print compiled-code)
(if (not (null? compiled-code))
(let ((first-instruction (car compiled-code)))
(if (not (symbol? first-instruction)) ;; is not a label?
(display " ")
(newline))
(begin
(print-to-screen first-instruction)
(... | null | https://raw.githubusercontent.com/abdulapopoola/SICPBook/c8a0228ebf66d9c1ddc5ef1fcc1d05d8684f090a/Chapter%205/5.5/helpers.scm | scheme | is not a label? | (define (pretty-print compiled-code)
(if (not (null? compiled-code))
(let ((first-instruction (car compiled-code)))
(display " ")
(newline))
(begin
(print-to-screen first-instruction)
(pretty-print (cdr compiled-code))
(newline)))
... |
95af6e9b37693c3efba56e356c34212b9175e030c2950e8ccedbb00070305a58 | raaz-crypto/raaz | XChaCha20Spec.hs | # OPTIONS_GHC -fno - warn - orphans #
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE DataKinds #-}
module Raaz.Cipher.XChaCha20Spec where
import Tests.Core
import qualified XChaCha20.Implementation as XI
import qualified ChaCha20.CPortable as CP
import ... | null | https://raw.githubusercontent.com/raaz-crypto/raaz/91799e1ae528e909ad921f6c0d6f51ebd8c7328f/tests/Raaz/Cipher/XChaCha20Spec.hs | haskell | # LANGUAGE OverloadedStrings #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE DataKinds # | # OPTIONS_GHC -fno - warn - orphans #
module Raaz.Cipher.XChaCha20Spec where
import Tests.Core
import qualified XChaCha20.Implementation as XI
import qualified ChaCha20.CPortable as CP
import System.IO.Unsafe( unsafePerformIO )
unsafeRun :: Memory mem => (mem -> IO a) -> a
unsafeRun = unsafePerf... |
af26f3ee165ec7e719adfcf652b717cd172648fb36bf577ceb4810d7634000c6 | freedict/tools | Token.hs |
- Language / Ding / Token.hs - token structures as produced by the lexer
-
- Copyright 2020 - 2021
-
- This file is part of ding2tei - haskell .
-
- ding2tei - haskell is free software : you can redistribute it and/or modify
- it under the terms of the GNU Affero General Public License as publ... | null | https://raw.githubusercontent.com/freedict/tools/3596640e6e0582cc5fb76a342e5d8e7413aa4b34/importers/ding2tei/src/Language/Ding/Token.hs | haskell | | Token, as produced by the lexer. Annotated with any directly preceding
whitespace and the position in the input.
^ Preceding whitespace.
^ Neutral element in the monoid.
Note:
* This instance's show function is not injective. Information on position
and preceding whitespace is dropped.
dependenc... |
- Language / Ding / Token.hs - token structures as produced by the lexer
-
- Copyright 2020 - 2021
-
- This file is part of ding2tei - haskell .
-
- ding2tei - haskell is free software : you can redistribute it and/or modify
- it under the terms of the GNU Affero General Public License as publ... |
0d6c20159ece5f41df6644cb612ac0d706a2078d9bbcfa08c10a2e55647e944a | facebook/flow | exception.ml |
* Copyright ( c ) Meta Platforms , Inc. and affiliates .
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree .
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in t... | null | https://raw.githubusercontent.com/facebook/flow/1232fa6f444797403095fc1f69dae7bf7789a313/src/hack_forked/utils/core/exception.ml | ocaml | DO THIS FIRST!!!
If this code throws internally it will overwrite the global backtrace
The inverse of `wrap`, returns the wrapped `exn`. You might use this to pattern
match on the raw exception or print it, but should not reraise it since it
will not include the correct backtrace; use `reraise` or `to_exn` i... |
* Copyright ( c ) Meta Platforms , Inc. and affiliates .
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree .
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in t... |
dac91d14032294017533e52adc04a6a54867a7528700e8508a1bc82d91bcf369 | 15Galan/asignatura-204 | GraphDemoG.hs | import DataStructures.Graph.Graph
import DataStructures.Graph.GraphES as G
g1 :: Graph Int
g1 = mkGraphSuc [1,2,3,4] suc
where
suc 1 = [2,3]
suc 2 = [1,3]
suc 3 = [1,2,4]
suc 4 = [3]
g1' :: Graph Int
g1' = mkGraphEdges [1,2,3,4] [(1,2),(1,3),(2,3),(3,4)]
{-
g1 y g1':
1--2
... | null | https://raw.githubusercontent.com/15Galan/asignatura-204/894f33ff8e0f52a75d8f9ff15155c656f1a8f771/Recursos/data.structures/haskell/Demos/Graph/GraphDemoG.hs | haskell |
g1 y g1':
1--2
\ |
3--4
| import DataStructures.Graph.Graph
import DataStructures.Graph.GraphES as G
g1 :: Graph Int
g1 = mkGraphSuc [1,2,3,4] suc
where
suc 1 = [2,3]
suc 2 = [1,3]
suc 3 = [1,2,4]
suc 4 = [3]
g1' :: Graph Int
g1' = mkGraphEdges [1,2,3,4] [(1,2),(1,3),(2,3),(3,4)]
g2 :: Grafo Int
g2 = cre... |
f613937476afceda5fbba05fdd5a9dc2ba64a58a89aa11344025ca3bc59eb3dc | sids/nerchuko | country.clj | (ns nerchuko-test.classification.naive-bayes.country
(:use nerchuko.classification
nerchuko.utils
nerchuko.helpers)
(:use clojure.test))
(def training-dataset [["chinese beijing chinese" :yes]
["chinese chinese shanghai" :yes]
["chinese macao" :yes]
... | null | https://raw.githubusercontent.com/sids/nerchuko/8aa56497dd8e93e868713dd542667a56215522fb/test/nerchuko_test/classification/naive_bayes/country.clj | clojure | (ns nerchuko-test.classification.naive-bayes.country
(:use nerchuko.classification
nerchuko.utils
nerchuko.helpers)
(:use clojure.test))
(def training-dataset [["chinese beijing chinese" :yes]
["chinese chinese shanghai" :yes]
["chinese macao" :yes]
... | |
38066005a2e8d008b417b2749b1877847b38dd665563b2fa1a5dd9d2b2ffce72 | airalab/hs-web3 | System.hs | # LANGUAGE FlexibleContexts #
{-# LANGUAGE OverloadedStrings #-}
-- |
-- Module : Network.Polkadot.Rpc.System
Copyright : 2016 - 2021
-- License : Apache-2.0
--
-- Maintainer :
-- Stability : experimental
-- Portability : portable
--
-- Polkadot RPC methods with `system` prefix.
--
module... | null | https://raw.githubusercontent.com/airalab/hs-web3/c03b86eb621f963886a78c39ee18bcec753f17ac/packages/polkadot/src/Network/Polkadot/Rpc/System.hs | haskell | # LANGUAGE OverloadedStrings #
|
Module : Network.Polkadot.Rpc.System
License : Apache-2.0
Maintainer :
Stability : experimental
Portability : portable
Polkadot RPC methods with `system` prefix.
| Adds a reserved peer.
^ Peer URI
| Retrieves the chain.
| Retrieves the chain type.
| Retu... | # LANGUAGE FlexibleContexts #
Copyright : 2016 - 2021
module Network.Polkadot.Rpc.System where
import Data.Aeson (Object)
import Data.Text (Text)
import Network.JsonRpc.TinyClient (JsonRpc (..))
import Network.Polkadot.Rpc.Types (Ch... |
cda5e655ff6949310e0b57773655875ab0ad49cfd42e9f5cd6b60d976ac7d5da | discus-lang/ddc | Guards.hs |
Suppress Data . Monoid warnings during GHC 8.4.1 transition
{-# OPTIONS -Wno-unused-imports #-}
| guards and nested patterns to match expressions .
module DDC.Source.Discus.Transform.Guards
( type S, evalState, newVar
, desugarModule)
where
import DDC.Source.Discus.Module
import DDC.Source.Discu... | null | https://raw.githubusercontent.com/discus-lang/ddc/2baa1b4e2d43b6b02135257677671a83cb7384ac/src/s1/ddc-source-discus/DDC/Source/Discus/Transform/Guards.hs | haskell | # OPTIONS -Wno-unused-imports #
-----------------------------------------------------------------------------
-----------------------------------------------------------------------------
-----------------------------------------------------------------------------
-----------------------------------------------------... |
Suppress Data . Monoid warnings during GHC 8.4.1 transition
| guards and nested patterns to match expressions .
module DDC.Source.Discus.Transform.Guards
( type S, evalState, newVar
, desugarModule)
where
import DDC.Source.Discus.Module
import DDC.Source.Discus.Exp
import Data.Monoid
import Data.... |
328472bd4847263f19dc19619146a804e2c3f590d24ed2d3fd6d193bb773276d | haskell/cabal | cabal.test.hs | import Test.Cabal.Prelude
-- Points to dist.
main = cabalTest $
fails $ cabal "check" []
| null | https://raw.githubusercontent.com/haskell/cabal/1cfe7c4c7257aa7ae450209d34b4a359e6703a10/cabal-testsuite/PackageTests/Check/ConfiguredPackage/Paths/DistPoint/cabal.test.hs | haskell | Points to dist. | import Test.Cabal.Prelude
main = cabalTest $
fails $ cabal "check" []
|
8dc3beb822ef983c400eaa04c2694af6b16ef11e5e70190ebe3366cef518347d | mhkoji/Senn | base.lisp | (fiveam:in-suite* :senn.t)
| null | https://raw.githubusercontent.com/mhkoji/Senn/74f909bfe10ba360523be5b3b162688f21f5b333/senn/t/base.lisp | lisp | (fiveam:in-suite* :senn.t)
| |
acd5475a303f3d337f4d4d3eeeda59b995d61215379c4dbecaae888fbfef8e57 | simonmar/monad-par | TestHelpers.hs | {-# LANGUAGE BangPatterns #-}
module TestHelpers where
import Data.List
import Prelude hiding (catch)
import Control.Exception
import System.IO.Unsafe (unsafePerformIO)
import Data.IORef
import Data.Time.Clock
import Control.Monad.Par.Class
------------------------------------------------------------
-- Helpers
... | null | https://raw.githubusercontent.com/simonmar/monad-par/9a25911e2004c66c1eb14dc200d1f5b0c2d83f0e/monad-par/tests/TestHelpers.hs | haskell | # LANGUAGE BangPatterns #
----------------------------------------------------------
Helpers
This version watches the clock so it uses a constant amount of time
regardless of compile/interpret mode an opt lvl.
Obviously this takes a lot longer if it's interpreted:
| Haskell doesn't offer a way to create a Handle f... |
module TestHelpers where
import Data.List
import Prelude hiding (catch)
import Control.Exception
import System.IO.Unsafe (unsafePerformIO)
import Data.IORef
import Data.Time.Clock
import Control.Monad.Par.Class
_ : : IO a - > Par a
_unsafeio :: ParFuture iv p => IO a -> p a
_unsafeio io = let x = unsafePerform... |
9d9f5c106447e3abb112ab2c4fa8b19032af4cac99e7741da5ce9dddb6c420a5 | esl/MongooseIM | mongoose_domain_api.erl | %% Main module other parts of MongooseIM should use to access the domain
%% management.
-module(mongoose_domain_api).
-include("mongoose_logger.hrl").
-export([init/0,
stop/0,
get_host_type/1]).
external domain API for GraphQL or REST handlers
-export([insert_domain/2,
delete_domain/2,
... | null | https://raw.githubusercontent.com/esl/MongooseIM/c863ca0a6109c782577a63e00510f634ca31d831/src/domain/mongoose_domain_api.erl | erlang | Main module other parts of MongooseIM should use to access the domain
management.
domain API
domain admin API
subdomain API
Helper for remove_domain
For testing
Stops gen_servers, that are started from init/0
Does not fail, even if servers are already stopped
Get the list of the host_types provided during ini... | -module(mongoose_domain_api).
-include("mongoose_logger.hrl").
-export([init/0,
stop/0,
get_host_type/1]).
external domain API for GraphQL or REST handlers
-export([insert_domain/2,
delete_domain/2,
request_delete_domain/2,
disable_domain/1,
enable_domain/1,
... |
f360523910b56084c731c6416e29e357d01916cf2edd0dfbf67853c3defb7d93 | jrheard/voke | state.cljs | (ns voke.state
"Contains functions that let Systems express an intent to modify the state of the game.
Systems can call add-entity!, update-entity!, and remove-entity! in their tick functions / event handlers.
These updates/removes will be queued, and will be processed by the core game loop in voke.core
at the... | null | https://raw.githubusercontent.com/jrheard/voke/15b272955d214ce0c531fb2b8d645feb217255c2/src/voke/state.cljs | clojure | Private
Public (but only intended to be used by voke.core)
i'm sure there's a more concise way to write this
Public
the time we spend. consider replacing the buffer with (gasp) a regular js array. not worth it yet though | (ns voke.state
"Contains functions that let Systems express an intent to modify the state of the game.
Systems can call add-entity!, update-entity!, and remove-entity! in their tick functions / event handlers.
These updates/removes will be queued, and will be processed by the core game loop in voke.core
at the... |
7d1b7af6e969480de8ec162dcc5f2c16fbe1ba025d38776de53256b800549c21 | robrix/sequoia | Assertion.hs | {-# LANGUAGE ConstraintKinds #-}
module Sequoia.Calculus.Assertion
( -- * Assertion
AssertionIntro
-- * Re-exports
, module Sequoia.Calculus.NotUntrue
, module Sequoia.Calculus.True
) where
import Sequoia.Calculus.NotUntrue
import Sequoia.Calculus.True
type AssertionIntro s = (NotUntrueIntro s, TrueIntro s)
| null | https://raw.githubusercontent.com/robrix/sequoia/ab008900ca0d7eece2e693d921a31e2e2518b15d/src/Sequoia/Calculus/Assertion.hs | haskell | # LANGUAGE ConstraintKinds #
* Assertion
* Re-exports | module Sequoia.Calculus.Assertion
AssertionIntro
, module Sequoia.Calculus.NotUntrue
, module Sequoia.Calculus.True
) where
import Sequoia.Calculus.NotUntrue
import Sequoia.Calculus.True
type AssertionIntro s = (NotUntrueIntro s, TrueIntro s)
|
70ee951e6f2100553e7fae8ab50209bbcb532fd29e42a985dc7983a08884ef47 | ocaml/oasis | OASISVersion.ml | (******************************************************************************)
OASIS : architecture for building OCaml libraries and applications
(* *)
Copyright ( C ) 2011 - 2016 ,
Copyrig... | null | https://raw.githubusercontent.com/ocaml/oasis/3d1a9421db92a0882ebc58c5df219b18c1e5681d/src/oasis/OASISVersion.ml | ocaml | ****************************************************************************
This library is free software; you can redistribute it and/or modify it
under the t... | OASIS : architecture for building OCaml libraries and applications
Copyright ( C ) 2011 - 2016 ,
Copyright ( C ) 2008 - 2011 , OCamlCore SARL
the Free Software Foundation ; either version 2.1 of the License , or ( at
You s... |
f9707c72056a4ee3feea897c1258eb1490077ac89fd5509f82369c3d22f3bc63 | p2k/ecoinpool | ebitcoin_chain_data.erl |
%%
Copyright ( C ) 2011 Patrick " p2k " < >
%%
This file is part of ebitcoin .
%%
%% ebitcoin 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) ... | null | https://raw.githubusercontent.com/p2k/ecoinpool/01ba76a7ab4b17b60cb0c525786fddef43ea80e1/apps/ebitcoin/src/ebitcoin_chain_data.erl | erlang |
ebitcoin is free software: you can redistribute it and/or modify
(at your option) any later version.
ebitcoin is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public Licen... |
Copyright ( C ) 2011 Patrick " p2k " < >
This file is part of ebitcoin .
it under the terms of the GNU General Public License as published by
the Free Software Foundation , either version 3 of the License , or
You should have received a copy of the GNU General Public License
along with ebitcoin . If ... |
0fd91e2c220d1d201132ab1abd38eb85440a4b693ec2348a680dfb01ff5bea81 | subttle/regular | DFA.hs | # LANGUAGE FlexibleContexts #
# LANGUAGE FlexibleInstances #
# LANGUAGE MultiParamTypeClasses #
# LANGUAGE ExistentialQuantification #
{-# OPTIONS_GHC -Wall #-}
module DFA where
import Algebra.Graph.Relation as Relation (stars)
import Data.Bool (bool)
impor... | null | https://raw.githubusercontent.com/subttle/regular/1a9e71cb1c43cb3215b9331efa98d4dcf21fbf9c/src/DFA.hs | haskell | # OPTIONS_GHC -Wall #
Deterministic Finite Automaton
q is the set of states, Q
s is the set of symbols Σ
The (total) transition function, δ : Q × Σ → Q
The initial state, q₀ ∈ Q
The final states, F ⊆ Q
{ q ∈ Q | ∃w ∈ Σ★, δ★(q₀, w) = q }
δ★ : Q × Σ★ → Q
"Extended de... | # LANGUAGE FlexibleContexts #
# LANGUAGE FlexibleInstances #
# LANGUAGE MultiParamTypeClasses #
# LANGUAGE ExistentialQuantification #
module DFA where
import Algebra.Graph.Relation as Relation (stars)
import Data.Bool (bool)
import Data.Bool.Unicode ((∧), (∨))
im... |
b3ed54ff75ca0efb07b8da2ea2db5026bf97a6413c49de94356fe0445acf57e7 | chrisdone/prana | FFI.hs | # LANGUAGE ViewPatterns #
{-# LANGUAGE EmptyDataDeriving #-}
-- | FFI-related work.
module Prana.FFI where
import Data.Bifunctor
import Data.Function
import Data.List.NonEmpty (NonEmpty(..))
import Data.Map.Strict (Map)
import qualified Data.Map.Strict as M
import Da... | null | https://raw.githubusercontent.com/chrisdone/prana/f2e45538937d326aff562b6d49296eaedd015662/prana-ghc/src/Prana/FFI.hs | haskell | # LANGUAGE EmptyDataDeriving #
| FFI-related work. | # LANGUAGE ViewPatterns #
module Prana.FFI where
import Data.Bifunctor
import Data.Function
import Data.List.NonEmpty (NonEmpty(..))
import Data.Map.Strict (Map)
import qualified Data.Map.Strict as M
import Data.Maybe
import Data.Typeable
import D... |
2298250a14b89b658a65123591b19679e8483ec6234d16a98a1509c00a273ef7 | sansarip/owlbear | utilities.cljs | (ns owlbear.parser.utilities
(:require [oops.core :refer [oget]]))
(defn ctx->children-seq
"Given a context,
returns a flattened, depth-first traversed, lazy sequence
of all of the context's children"
[ctx]
(tree-seq #(oget % :?children) #(oget % :children) ctx))
(defn ctx->parent-seq
"Given a conte... | null | https://raw.githubusercontent.com/sansarip/owlbear/b25d46e3f401f5fee739889e5bc604f6b9c00c41/src/cljs/owlbear/parser/utilities.cljs | clojure | Accounts for scenarios where an HTML element context has a parent HTML elements context | (ns owlbear.parser.utilities
(:require [oops.core :refer [oget]]))
(defn ctx->children-seq
"Given a context,
returns a flattened, depth-first traversed, lazy sequence
of all of the context's children"
[ctx]
(tree-seq #(oget % :?children) #(oget % :children) ctx))
(defn ctx->parent-seq
"Given a conte... |
9de38fd7543fc72e3ab0ba533902550c7f1bf45cb5a496624c4fb1735fca08b1 | athos/symbol-analyzer | extraction_test.clj | (ns symbol-analyzer.extraction-test
(:require [symbol-analyzer.extraction :refer :all]
[clojure.test :refer :all]
[clojure.core.match :refer [match]]))
(defn- install-data-readers [n]
(letfn [(make-annotator [id]
(fn [form]
(vary-meta form assoc :id id)))]
(dot... | null | https://raw.githubusercontent.com/athos/symbol-analyzer/99c7090f5fda52ccd40404c8823614ea343e5a51/test/symbol_analyzer/extraction_test.clj | clojure | (ns symbol-analyzer.extraction-test
(:require [symbol-analyzer.extraction :refer :all]
[clojure.test :refer :all]
[clojure.core.match :refer [match]]))
(defn- install-data-readers [n]
(letfn [(make-annotator [id]
(fn [form]
(vary-meta form assoc :id id)))]
(dot... | |
53e6cc711f8a8944a14cacbceb772b0a55b336e74fc7b8366cc20ddd240a6ab2 | mthbernardes/shaggy-rogers | lambda_test.clj | (ns shaggy-rogers.middleware.lambda-test
(:require [clojure.test :refer :all]
[shaggy-rogers.middleware.lambda :as lambda])
(:import (java.util HashMap)))
(deftest ->cljmap
(testing "testing ->cljmap conversion"
(is (= {:first-key "value"
:second-key ["value1"
... | null | https://raw.githubusercontent.com/mthbernardes/shaggy-rogers/aa100bf81ec142503f69882aa811ef15fae4f027/test/shaggy_rogers/middleware/lambda_test.clj | clojure | (ns shaggy-rogers.middleware.lambda-test
(:require [clojure.test :refer :all]
[shaggy-rogers.middleware.lambda :as lambda])
(:import (java.util HashMap)))
(deftest ->cljmap
(testing "testing ->cljmap conversion"
(is (= {:first-key "value"
:second-key ["value1"
... | |
7aa2b0af1351784dfedb59c8a55b7b77b25196b00bc21234b52072b6d2cd7289 | BBVA/ust2dsa | Parser.hs | |
Copyright 2020 Banco Bilbao Vizcaya Argentaria , S.A.
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 , soft... | null | https://raw.githubusercontent.com/BBVA/ust2dsa/0688651f77ebda312dac76ae6a1901357ab12907/src/Text/UbuntuSecurityTracker/CVE/Parser.hs | haskell | |
Copyright 2020 Banco Bilbao Vizcaya Argentaria , S.A.
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 , soft... | |
20f9f7e2cce28fd5e6f87043b00c68434d235d41ee8000ef9ad96f999a7b5c1b | swlkr/majestic-web | project.clj | (defproject {{name}} "0.1.0-SNAPSHOT"
:description "FIXME: write description"
:url ""
:min-lein-version "2.6.1"
:dependencies [[org.clojure/clojure "1.8.0"]
[org.clojure/tools.namespace "0.2.11"]
[ring/ring-core "1.5.0"]
[ring/ring-devel "1.5.0"]
... | null | https://raw.githubusercontent.com/swlkr/majestic-web/3d247f6b5ccc4ff3662a64544a4ca27beada971b/resources/leiningen/new/majestic_web/project.clj | clojure | (defproject {{name}} "0.1.0-SNAPSHOT"
:description "FIXME: write description"
:url ""
:min-lein-version "2.6.1"
:dependencies [[org.clojure/clojure "1.8.0"]
[org.clojure/tools.namespace "0.2.11"]
[ring/ring-core "1.5.0"]
[ring/ring-devel "1.5.0"]
... | |
974e2e8e941cfc02f6183fd760e9b10df974bd48cc879ab4919e70dcf86782bd | amosr/folderol | Folderol.hs | {-# LANGUAGE BangPatterns #-}
# LANGUAGE TemplateHaskell #
module Bench.Audio.Folderol where
import Bench.Audio.Audio
import qualified Bench.Plumbing.Folderol as Plumbing
import qualified Folderol.Typed as Network
import qualified Folderol.Process as Process
import qualified Folderol.Splice as Splice
import qualif... | null | https://raw.githubusercontent.com/amosr/folderol/9b8c0cd30cfb798dadaa404cc66404765b1fc4fe/bench/Bench/Audio/Folderol.hs | haskell | # LANGUAGE BangPatterns # | # LANGUAGE TemplateHaskell #
module Bench.Audio.Folderol where
import Bench.Audio.Audio
import qualified Bench.Plumbing.Folderol as Plumbing
import qualified Folderol.Typed as Network
import qualified Folderol.Process as Process
import qualified Folderol.Splice as Splice
import qualified Folderol.Source as Source
... |
9fe86e1f68c9436782ed0b9d3b1ea8a8fb6167958dd40211109dfaa6afc55c1c | robert-strandh/SICL | make-symbol-defun.lisp | (cl:in-package #:sicl-symbol)
(defun make-symbol (string)
(unless (stringp string)
(error 'type-error
:datum string
:expected-type 'string))
(make-instance 'symbol
:name string
:package nil))
| null | https://raw.githubusercontent.com/robert-strandh/SICL/837f2e8e436c42fba3e13f6d823136976a04e775/Code/Symbol/make-symbol-defun.lisp | lisp | (cl:in-package #:sicl-symbol)
(defun make-symbol (string)
(unless (stringp string)
(error 'type-error
:datum string
:expected-type 'string))
(make-instance 'symbol
:name string
:package nil))
| |
b74a634c199af99c2d641a35cce1a7c61bdb5694f090a11ed209c4bd997b8249 | brownplt/LambdaS5 | prelude.mli | type id = string
module Pos : sig
type t = Lexing.position * Lexing.position * bool (* start, end, is synthetic? *)
val dummy : t
val compare : t -> t -> int
val before : t -> t -> bool
val synth : t -> t
val synthetic : Lexing.position * Lexing.position -> t
val real : Lexing.position * Lexing.position... | null | https://raw.githubusercontent.com/brownplt/LambdaS5/f0bf5c7baf1daa4ead4e398ba7d430bedb7de9cf/src/util/prelude.mli | ocaml | start, end, is synthetic?
* [nub lst] removes duplicates from the [lst]. Duplicates are identified by
structural equality.
* [iota n] returns the list of integers [0] through [n-1], inclusive. | type id = string
module Pos : sig
val dummy : t
val compare : t -> t -> int
val before : t -> t -> bool
val synth : t -> t
val synthetic : Lexing.position * Lexing.position -> t
val real : Lexing.position * Lexing.position -> t
val rangeToString : Lexing.position -> Lexing.position -> string
val strin... |
ae2619cac93189955da816b3080659409c2b211c9d585263a6a40a068d897c61 | jaredloomis/Haskell-OpenGL | NewMatrix.hs | # LANGUAGE DataKinds #
# LANGUAGE NoMonomorphismRestriction #
# LANGUAGE TypeOperators #
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE FlexibleInstances #
# LANGUAGE FlexibleContexts #
# LANGUAGE MultiParamTypeClasses #
module Engine.Matrix.NewMatrix where
import Foreign.Storable (Storable(..))
import qualified D... | null | https://raw.githubusercontent.com/jaredloomis/Haskell-OpenGL/5c7363bbc07c5064e49b608d689cda2cab99f3eb/src/Engine/Matrix/NewMatrix.hs | haskell | # LANGUAGE DataKinds #
# LANGUAGE NoMonomorphismRestriction #
# LANGUAGE TypeOperators #
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE FlexibleInstances #
# LANGUAGE FlexibleContexts #
# LANGUAGE MultiParamTypeClasses #
module Engine.Matrix.NewMatrix where
import Foreign.Storable (Storable(..))
import qualified D... | |
6e84e4cf8bb466555d7425d14ebd5b8581dadd39b7c3c27ade0aeb1e2565b1eb | AccelerateHS/accelerate-examples | Main.hs | # LANGUAGE ScopedTypeVariables , CPP , FlexibleContexts #
module Main where
import Data.Bits
import Properties
import Text.Printf
import Test.QuickCheck
import Data.Array.Accelerate
-- All tests, all element types (coffee time!)
--
main :: IO ()
main = do
mapM_ (\(s,t) -> printf "===> %s\n" s >> runTests t >> pu... | null | https://raw.githubusercontent.com/AccelerateHS/accelerate-examples/a973ee423b5eadda6ef2e2504d2383f625e49821/examples/icebox/quickcheck-ast-old/Main.hs | haskell | All tests, all element types (coffee time!)
Execute a sequence of (name,test) pairs
The test sets
mix and match types? | # LANGUAGE ScopedTypeVariables , CPP , FlexibleContexts #
module Main where
import Data.Bits
import Properties
import Text.Printf
import Test.QuickCheck
import Data.Array.Accelerate
main :: IO ()
main = do
mapM_ (\(s,t) -> printf "===> %s\n" s >> runTests t >> putStrLn "") $
[ ("Int", prop_integral (undef... |
9579296167ea9de4cf146b6af6f051b9d73bb2ac4b4569163f354af711d4a4c6 | osa1/StrictCore | Lint.hs | FIXME : This module needs some extra exports from CoreLint
module StrictCore.Lint
( lintCoreProgram
) where
--------------------------------------------------------------------------------
import Bag
import BasicTypes
import CoAxiom (Role (..))
import CoreLint hiding (lintExpr, lintSingleBinding, mkBadAltMsg, ... | null | https://raw.githubusercontent.com/osa1/StrictCore/f546099a0d345bc32297cd212edaf5197251886f/src/StrictCore/Lint.hs | haskell | ------------------------------------------------------------------------------
------------------------------------------------------------------------------
| Returns (warnings, errors).
------------------------------------------------------------------------------
FIXME: LambdaBodyOf wants an Id so can't use it her... | FIXME : This module needs some extra exports from CoreLint
module StrictCore.Lint
( lintCoreProgram
) where
import Bag
import BasicTypes
import CoAxiom (Role (..))
import CoreLint hiding (lintExpr, lintSingleBinding, mkBadAltMsg, mkCaseAltMsg,
mkNewTyDataConAltMsg)
import qualified CoreSyn
imp... |
a78750af5b48214cc80c10023a5e9489cbc54944a6025776282886b7b96b96e3 | fetburner/Coq2SML | dnet.mli | (************************************************************************)
v * The Coq Proof Assistant / The Coq Development Team
< O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2014
\VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *... | null | https://raw.githubusercontent.com/fetburner/Coq2SML/322d613619edbb62edafa999bff24b1993f37612/coq-8.4pl4/lib/dnet.mli | ocaml | **********************************************************************
// * This file is distributed under the terms of the
* GNU Lesser General Public License Version 2.1
**********************************************************************
* datatype you want to build a dnet ... | v * The Coq Proof Assistant / The Coq Development Team
< O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2014
\VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Generic discrimination net ... |
e5853aaaa2a5bf929a7a13485816782a6b2a66e0b4698f251dda624eac6291f9 | hipsleek/hipsleek | gLogViewWindow.ml | #include "xdebug.cppo"
(**/**)
open GUtil.SourceUtil
(**/**)
class log_view_window ?(title="Log") log () =
let tag_results = "results" in
let tag_current = "current" in
let win = GWindow.window
~title
~height:600 ~width:850
~allow_shrink:true
() in
object (self)
inherit GWindow.window win#a... | null | https://raw.githubusercontent.com/hipsleek/hipsleek/596f7fa7f67444c8309da2ca86ba4c47d376618c/bef_indent/gLogViewWindow.ml | ocaml | */*
*/*
set event handlers
****************
* Public methods
* **************
clear_callback ();
*****************
* Private methods
* ***************
clear current highlight
search
update current state and highlight all results
get next pos and it's iter
scroll to and highlight it
upda... | #include "xdebug.cppo"
open GUtil.SourceUtil
class log_view_window ?(title="Log") log () =
let tag_results = "results" in
let tag_current = "current" in
let win = GWindow.window
~title
~height:600 ~width:850
~allow_shrink:true
() in
object (self)
inherit GWindow.window win#as_window as supe... |
e6fe8b5910ee8c1a9ad87144a2cc4819018ac3eef57b91d21a6aac5a411a43a9 | huangz1990/SICP-answers | 52-square-limit.scm | 52-square-limit.scm
(define (square-limit painter n)
(let ((combine4 (square-of-four identity flip-horiz)
flip-vect rotate180))
(combine4 (corner-split painter n))))
| null | https://raw.githubusercontent.com/huangz1990/SICP-answers/15e3475003ef10eb738cf93c1932277bc56bacbe/chp2/code/52-square-limit.scm | scheme | 52-square-limit.scm
(define (square-limit painter n)
(let ((combine4 (square-of-four identity flip-horiz)
flip-vect rotate180))
(combine4 (corner-split painter n))))
| |
a4852ebf6267be8ec02b35f1c62d5575814912e3135de5ab3a5935d165f233f9 | texmacs/markdown | srfi-9.scm | ;;; srfi-9.scm --- define-record-type
Copyright ( C ) 2001 , 2002 , 2006 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
version 2.1 of ... | null | https://raw.githubusercontent.com/texmacs/markdown/f1332bba6d0d23d3448921acc8ae3ddf905659f7/progs/srfi/srfi-9.scm | scheme | srfi-9.scm --- define-record-type
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 FI... |
Copyright ( C ) 2001 , 2002 , 2006 Free Software Foundation , Inc.
version 2.1 of the License , or ( at your option ) any later version .
You should have received a copy of the GNU Lesser General Public
Foundation , Inc. , 51 Franklin Street , Fifth Floor , Boston , USA
guile > ( define f ( make - foo... |
fa3ff513eec4acc0562e2bb13603984f5bdfb445a61d2da0d4d521ce99312d9b | rbkmoney/fistful-server | ff_withdrawal_codec.erl | -module(ff_withdrawal_codec).
-behaviour(ff_codec).
-include_lib("fistful_proto/include/ff_proto_withdrawal_thrift.hrl").
-export([unmarshal_quote_params/1]).
-export([unmarshal_withdrawal_params/1]).
-export([marshal_withdrawal_params/1]).
-export([marshal_withdrawal_state/2]).
-export([marshal_event/1]).
-expor... | null | https://raw.githubusercontent.com/rbkmoney/fistful-server/526adc789f4f6083dae7eb4d7ac2d9ba3c34845b/apps/ff_server/src/ff_withdrawal_codec.erl | erlang | API
@see ff_adapter_withdrawal:rebind_transaction_info/1
already formatted
already formatted
@see ff_adapter_withdrawal:rebind_transaction_info/1
Internals
TESTS | -module(ff_withdrawal_codec).
-behaviour(ff_codec).
-include_lib("fistful_proto/include/ff_proto_withdrawal_thrift.hrl").
-export([unmarshal_quote_params/1]).
-export([unmarshal_withdrawal_params/1]).
-export([marshal_withdrawal_params/1]).
-export([marshal_withdrawal_state/2]).
-export([marshal_event/1]).
-expor... |
aeebedfd140e2b228985fffe93ec4d25eb2a68bd7d6e5b2c03757bd1c55aecde | nponeccop/HNC | Types.hs | # OPTIONS_GHC -fno - warn - unused - matches #
module SPL.Types (T (..), C (..), St (..), InFun (..)) where
import Data.Map
-- type
data T =
T [Char]
| TT [T]
| TU [Char]
| TV [Char]
| TD [Char] [T]
| TS (Map [Char] T)
| TL
| TUL [T]
deriving (Eq, Show, Read)
-- code
data InFun =
InFun [Char] ([C] -> Map [... | null | https://raw.githubusercontent.com/nponeccop/HNC/d8447009a04c56ae2cba4c7c179e39384085ea00/SPL/Types.hs | haskell | type
code | # OPTIONS_GHC -fno - warn - unused - matches #
module SPL.Types (T (..), C (..), St (..), InFun (..)) where
import Data.Map
data T =
T [Char]
| TT [T]
| TU [Char]
| TV [Char]
| TD [Char] [T]
| TS (Map [Char] T)
| TL
| TUL [T]
deriving (Eq, Show, Read)
data InFun =
InFun [Char] ([C] -> Map [Char] C -> C)
in... |
8e8537592286c18a1daf01a4c80d71ca5eaa233b4bcdecff3eff9feed91c8dfd | shriram/mystery-languages | semantics.rkt | #lang racket
(require mystery-languages/make-semantics)
(provide (rename-out [mod-begin #%module-begin]
[ti #%top-interaction]))
(define-values (namespaces lang-print-names)
(make-namespaces-and-lang-print-names (list 'mystery-languages/mut-structs/L1/semantics
... | null | https://raw.githubusercontent.com/shriram/mystery-languages/86f717654c9ff05b7f838ea7ba1e63fb280d9387/mut-structs/semantics.rkt | racket | #lang racket
(require mystery-languages/make-semantics)
(provide (rename-out [mod-begin #%module-begin]
[ti #%top-interaction]))
(define-values (namespaces lang-print-names)
(make-namespaces-and-lang-print-names (list 'mystery-languages/mut-structs/L1/semantics
... | |
5a8717604104426d2cdb5252a779430392044afaa0babf76c6692088c76222b0 | manuel-serrano/hop | wiki.scm | ;*=====================================================================*/
* serrano / prgm / project / hop/2.1.x / weblets / wiki / wiki.scm * /
;* ------------------------------------------------------------- */
* Author : * /
* Creation ... | null | https://raw.githubusercontent.com/manuel-serrano/hop/481cb10478286796addd2ec9ee29c95db27aa390/weblets/wiki/wiki.scm | scheme | *=====================================================================*/
* ------------------------------------------------------------- */
* ------------------------------------------------------------- */
* Wiki runtime system */
*===========================... | * serrano / prgm / project / hop/2.1.x / weblets / wiki / wiki.scm * /
* Author : * /
* Creation : Tue Mar 10 09:57:17 2009 * /
* Last change : Mon Mar 22 10:13:36 2010 ( serrano ) * /
* Copy... |
780902e13eeeb2571bf32a319f2786c35caf725eabcc9ee3403ccdcd88fb136e | sgbj/MaximaSharp | zdotc.lisp | ;;; Compiled by f2cl version:
( " f2cl1.l , v 2edcbd958861 2012/05/30 03:34:52 toy $ "
" f2cl2.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ "
" f2cl3.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ "
" f2cl4.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ "
" f2cl5.l , v 3fe93de3be82 2012/05/06 02:17:14 toy ... | null | https://raw.githubusercontent.com/sgbj/MaximaSharp/75067d7e045b9ed50883b5eb09803b4c8f391059/Test/bin/Debug/Maxima-5.30.0/share/maxima/5.30.0/share/lapack/blas/zdotc.lisp | lisp | Compiled by f2cl version:
Using Lisp CMU Common Lisp 20d (20D Unicode)
Options: ((:prune-labels nil) (:auto-save t) (:relaxed-array-decls t)
(:coerce-assigns :as-needed) (:array-type ':array)
(:array-slicing t) (:declare-common nil)
(:float-format double-float)) | ( " f2cl1.l , v 2edcbd958861 2012/05/30 03:34:52 toy $ "
" f2cl2.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ "
" f2cl3.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ "
" f2cl4.l , v 96616d88fb7e 2008/02/22 22:19:34 rtoy $ "
" f2cl5.l , v 3fe93de3be82 2012/05/06 02:17:14 toy $ "
" f2cl6.l , v 1d5cbacbb... |
43c3f635a505e33e96387aeddf1c1d9e7066cd8fe6cf4e3b7919e70e3bb1f578 | Deducteam/SizeChangeTool | call_extractor.ml | open Kernel
open Kernel.Term
open Rules
open Sign
open Sizematrix
open Callgraph
let rec dig_in_rhs : term -> (int * Basic.name * term array) list =
function
| Kind
| Type(_) -> assert false
| DB(_,_,_) -> []
| Const(_,f) -> [0, f, [||]]
| App(Const(_,f),u,l) ->
(0, f, Array.of_list (u::l))
:: ... | null | https://raw.githubusercontent.com/Deducteam/SizeChangeTool/0a4db26ee1beed6ca7cf404ba6edd0539d540371/src/call_extractor.ml | ocaml | A variable when applied has the same size as if it was not applied
* Add the calls associated to a rule in the call graph | open Kernel
open Kernel.Term
open Rules
open Sign
open Sizematrix
open Callgraph
let rec dig_in_rhs : term -> (int * Basic.name * term array) list =
function
| Kind
| Type(_) -> assert false
| DB(_,_,_) -> []
| Const(_,f) -> [0, f, [||]]
| App(Const(_,f),u,l) ->
(0, f, Array.of_list (u::l))
:: ... |
c6042c3e8144c7fae973a8a78e212f8f1fedbc776147c6151d32067c46f5b941 | well-typed/large-records | R030.hs | # LANGUAGE TypeApplications #
#if PROFILE_CORESIZE
{-# OPTIONS_GHC -ddump-to-file -ddump-ds-preopt -ddump-ds -ddump-simpl #-}
#endif
#if PROFILE_TIMING
{-# OPTIONS_GHC -ddump-to-file -ddump-timings #-}
#endif
module Experiment.Induction_Tree_Phantom.Sized.R030 where
import Data.Proxy
import Common.EmptyClass_Tree_P... | null | https://raw.githubusercontent.com/well-typed/large-records/c6c2b51af11e90f30822543d7ce4d1cb28cee294/large-records-benchmarks/bench/experiments/Experiment/Induction_Tree_Phantom/Sized/R030.hs | haskell | # OPTIONS_GHC -ddump-to-file -ddump-ds-preopt -ddump-ds -ddump-simpl #
# OPTIONS_GHC -ddump-to-file -ddump-timings # | # LANGUAGE TypeApplications #
#if PROFILE_CORESIZE
#endif
#if PROFILE_TIMING
#endif
module Experiment.Induction_Tree_Phantom.Sized.R030 where
import Data.Proxy
import Common.EmptyClass_Tree_Phantom
import Common.HListOfSize.HL030
requiresInstance :: ()
requiresInstance = requireEmptyClass (Proxy @ExampleFields)
|
95fdf2ff414d755a62d34793df8644280ebefa7aefa1f95e6d6d18139575f562 | dolotech/erlang_server | pt_attain.erl | %%----------------------------------------------------
协议24 - 成就
%%
$ Id$
%%
%% @author Rolong<>
%%----------------------------------------------------
-module(pt_attain).
-export([handle/3]).
-include("common.hrl").
-include("hero.hrl").
-include("equ.hrl").
-include("prop.hrl").
领取成就
hand... | null | https://raw.githubusercontent.com/dolotech/erlang_server/44ea3693317f60e18b19c9ddfa179307cbd646d7/src/pt/pt_attain.erl | erlang | ----------------------------------------------------
@author Rolong<>
----------------------------------------------------
Rs1 = Rs#role{diamond = NewDiamond},
Rs1 = Rs#role{luck = Luck},
TODO:邮件系统
初始化成就
Condition = data_attain:get(condition, Team),
=== 私有函数 ===
是否存在下一个成就
是否已经完成可领取
是否存在下一个成就
... | 协议24 - 成就
$ Id$
-module(pt_attain).
-export([handle/3]).
-include("common.hrl").
-include("hero.hrl").
-include("equ.hrl").
-include("prop.hrl").
领取成就
handle(24004, [Id], Rs) ->
Data = data_attain:get(Id),
PriceNum = util:get_val(num, Data),
if
Data == undefined ->
{ok, [127, 0, 0]}... |
b3bf0c543cef81421fa701d5a4db10cec37ea32b19c96cfcd48384261617a92e | Z572/guile-wlroots | drm-format-set.scm | (define-module (wlroots render drm-format-set)
#:use-module (oop goops)
#:duplicates (merge-accessors merge-generics replace warn-override-core warn last)
#:use-module (wlroots types)
#:use-module (wayland util)
#:use-module (bytestructures guile)
#:use-module ((system foreign) #:prefix ffi:)
#:use-module... | null | https://raw.githubusercontent.com/Z572/guile-wlroots/dc6cd05d5c46f811d75cbc30d1464820b19b1de8/wlroots/render/drm-format-set.scm | scheme | (define-module (wlroots render drm-format-set)
#:use-module (oop goops)
#:duplicates (merge-accessors merge-generics replace warn-override-core warn last)
#:use-module (wlroots types)
#:use-module (wayland util)
#:use-module (bytestructures guile)
#:use-module ((system foreign) #:prefix ffi:)
#:use-module... | |
c33246e52b367c36f1afbca959828d794d99344c0b8a9a1e5a15d08f53f9cddf | abcdw/rde | admin.scm | ;;; rde --- Reproducible development environment.
;;;
Copyright © 2022 < >
;;;
;;; This file is part of rde.
;;;
;;; rde 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 , ... | null | https://raw.githubusercontent.com/abcdw/rde/faa6bbfda680c444a1ba6d07782b7665ef1ebc00/src/rde/system/services/admin.scm | scheme | rde --- Reproducible development environment.
This file is part of rde.
rde is free software; you can redistribute it and/or modify it
either version 3 of the License , or ( at
your option) any later version.
rde is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the im... | Copyright © 2022 < >
under the terms of the GNU General Public License as published by
You should have received a copy of the GNU General Public License
(define-module (rde system services admin)
#:use-module (rde serializers utils)
#:use-module (gnu services)
#:use-module (gnu services configuration)
... |
4835c5a31abeae87ed9368e2e36ae6f34b3baa6fad3dea9680a627aafef84fdd | green-coder/girouette | comprehensive.cljc | (ns acme.frontend.comprehensive)
;; ---------------------------------------------------
;; Use {:retrieve :comprehensive} to collect those
;; (it's the default retrieval method)
;; ---------------------------------------------------
(defn compact-example []
[:h1.flex
[:div.flex-1 "hello"]
[:div.flex-2 "th... | null | https://raw.githubusercontent.com/green-coder/girouette/6b1a23aafdd73beeabd81a884ee31c4bfbc1de99/example/reagent-demo/src/acme/frontend/comprehensive.cljc | clojure | ---------------------------------------------------
Use {:retrieve :comprehensive} to collect those
(it's the default retrieval method)
--------------------------------------------------- | (ns acme.frontend.comprehensive)
(defn compact-example []
[:h1.flex
[:div.flex-1 "hello"]
[:div.flex-2 "the"]
[:div.flex-3 "world"]])
|
d0cccc919010eb77d6a8a22e0ccfaad53867af0d0d5ece13b087ee6e89ed8009 | replikativ/konserve | common.clj | (ns benchmark.common
(:require [konserve.core :as k]
[konserve.filestore :refer [new-fs-store delete-store]]
[konserve.memory :refer [new-mem-store]]
[clojure.core.async :refer [<!!] :as async]))
;; Store
(def fs-store-path "/tmp/konserve-fs-bench")
(defmulti get-store
(fn [ty... | null | https://raw.githubusercontent.com/replikativ/konserve/da09c0fcc066d0e13d6eded673a83382bb9f9e33/benchmark/src/benchmark/common.clj | clojure | Store
time measurements
other | (ns benchmark.common
(:require [konserve.core :as k]
[konserve.filestore :refer [new-fs-store delete-store]]
[konserve.memory :refer [new-mem-store]]
[clojure.core.async :refer [<!!] :as async]))
(def fs-store-path "/tmp/konserve-fs-bench")
(defmulti get-store
(fn [type] type)... |
fdc9c2c47cc1672d70489d9e1130ef971a03046904bd876c85c3e52f499438ee | tengstrand/lein-polylith | time_test.clj | (ns leiningen.polylith.cmd.time-test
(:require [clojure.test :refer :all]
[leiningen.polylith.time :as time]))
(deftest milliseconds->minutes-and-seconds--less-than-a-minute--returns-seconds
(is (= "7.3 seconds"
(time/milliseconds->minutes-and-seconds 7345))))
(deftest milliseconds->minutes-a... | null | https://raw.githubusercontent.com/tengstrand/lein-polylith/27bf508a7b4806e4d2dfac01787e99edf2c1c306/test/leiningen/polylith/cmd/time_test.clj | clojure | (ns leiningen.polylith.cmd.time-test
(:require [clojure.test :refer :all]
[leiningen.polylith.time :as time]))
(deftest milliseconds->minutes-and-seconds--less-than-a-minute--returns-seconds
(is (= "7.3 seconds"
(time/milliseconds->minutes-and-seconds 7345))))
(deftest milliseconds->minutes-a... | |
bea06b5cc6fa5c4378777e5af5bd3618fb46bc723eb75fcd217d7958ef2439b5 | haskell/vector | append.hs | import qualified Data.Vector as U
import Data.Bits
main = print . U.sum . U.map (`shiftL` 2) $
(U.++) (U.replicate 10000000 (1::Int))
(U.replicate 10000000 (7::Int))
| null | https://raw.githubusercontent.com/haskell/vector/4c87e88f07aad166c6ae2ccb94fa539fbdd99a91/old-testsuite/microsuite/append.hs | haskell | import qualified Data.Vector as U
import Data.Bits
main = print . U.sum . U.map (`shiftL` 2) $
(U.++) (U.replicate 10000000 (1::Int))
(U.replicate 10000000 (7::Int))
| |
f051f00014c9b936ddf3a8e4955852b9a33cef146141218a9f47361a570d8c59 | juxt/roll | generate_config_sample.cljs | (ns roll.generate-config-sample
(:require [roll.samples]
[cljs.nodejs :as nodejs]))
(def fs (nodejs/require "fs"))
(defn- spit [f data]
(fs.writeFileSync f data))
(defn -main [& argv]
(spit "sample-config.edn" (roll.samples/generate-roll-config)))
| null | https://raw.githubusercontent.com/juxt/roll/1ef07d72f05b5604eec4f7d6a5dbf0d21ec3c8b3/test/roll/generate_config_sample.cljs | clojure | (ns roll.generate-config-sample
(:require [roll.samples]
[cljs.nodejs :as nodejs]))
(def fs (nodejs/require "fs"))
(defn- spit [f data]
(fs.writeFileSync f data))
(defn -main [& argv]
(spit "sample-config.edn" (roll.samples/generate-roll-config)))
| |
fae5a4833f39f7ae10548c8383593dd1b8f0751d7cc6d021876755c9673516e0 | emaphis/HtDP2e-solutions | ex073.rkt | The first three lines of this file were inserted by . They record metadata
;; about the language level of this file in a form that our tools can easily process.
#reader(lib "htdp-beginner-reader.ss" "lang")((modname ex073) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #f ... | null | https://raw.githubusercontent.com/emaphis/HtDP2e-solutions/ecb60b9a7bbf9b8999c0122b6ea152a3301f0a68/1-Fixed-Size-Data/05-Adding-Structure/ex073.rkt | racket | about the language level of this file in a form that our tools can easily process.
It produces a Posn like p with n in the x field.
Note Functions such as posn-up-x are often called updaters or functional
setters. They are extremely useful when you write large programs.
Posn Number -> Posn
produces a Posn given a... | The first three lines of this file were inserted by . They record metadata
#reader(lib "htdp-beginner-reader.ss" "lang")((modname ex073) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #f #t none #f () #f)))
Ex . 73 :
Design the function posn - up - x , which consumes a... |
41102cb7e7a2ad908ccfe82d8b9e1b6d3498259b74fc7bc67790f5831dc4c00f | jrm-code-project/LISP-Machine | supdup-server.lisp | -*- Mode : LISP ; Package : SUPDUP ; Base:8 ; : ZL -*-
;;; This is a flavor definition generated by the window maker.
(DEFFLAVOR supdup-server-debug-frame
()
(TV:CONSTRAINT-FRAME)
(:DEFAULT-INIT-PLIST
:PANES '((ZMACS ZWEI:ZMACS-FRAME
:SAVE-BITS T)
(SUPDUP S... | null | https://raw.githubusercontent.com/jrm-code-project/LISP-Machine/0a448d27f40761fafabe5775ffc550637be537b2/lambda/pace/hacks/supdup-server.lisp | lisp | Package : SUPDUP ; Base:8 ; : ZL -*-
This is a flavor definition generated by the window maker.
lots of flags
height in lines
width in chars
scroll glitch |
(DEFFLAVOR supdup-server-debug-frame
()
(TV:CONSTRAINT-FRAME)
(:DEFAULT-INIT-PLIST
:PANES '((ZMACS ZWEI:ZMACS-FRAME
:SAVE-BITS T)
(SUPDUP SUPDUP
:SAVE-BITS T)
(SERVER TV:WINDOW
:SAVE-BITS T))
:CONSTRAI... |
b8ba53b3e42c63900d471428a56f4be9e1dc7e9f4ba9796e91800178835285f5 | samplecount/shake-language-c | BuildFlags.hs | Copyright 2012 - 2014 Samplecount 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 agreed to in writing, software
di... | null | https://raw.githubusercontent.com/samplecount/shake-language-c/7eba37910bf711cc4c3fe6e7f065c8108858eea4/src/Development/Shake/Language/C/BuildFlags.hs | haskell |
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 governing perm... | Copyright 2012 - 2014 Samplecount S.L.
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
distributed under the License is distributed on an " AS IS " BASIS ,
# LANGUAGE TemplateHaskell #
|
Description : Build flags record for building @C@ language projects
The ` BuildFlags ` record is a... |
05eb7e4115209aecfffb836336d5c4441f3f9faa1b9bd3738a8b798a3a3ccc62 | zlatozar/study-paip | krep1.lisp | -*- Mode : LISP ; Syntax : COMMON - LISP ; Package : CH14 - FIRST ; Base : 10 -*-
;;; Code from Paradigms of Artificial Intelligence Programming
Copyright ( c ) 1991
File krep1.lisp : Knowledge representation code ; first version .
(in-package #:ch14-first)
;;; ______________________________________________... | null | https://raw.githubusercontent.com/zlatozar/study-paip/dfa1ca6118f718f5d47d8c63cbb7b4cad23671e1/ch14/krep1.lisp | lisp | Syntax : COMMON - LISP ; Package : CH14 - FIRST ; Base : 10 -*-
Code from Paradigms of Artificial Intelligence Programming
first version .
____________________________________________________________________________
____________________________________________________________________________
_____________________... |
Copyright ( c ) 1991
(in-package #:ch14-first)
An ` nlist ' is implemented as a ( count . elements ) pair :
(defun make-empty-nlist ()
"Create a new, empty nlist."
(cons 0 nil))
(defun nlist-n (x) "The number of elements in an nlist." (car x))
(defun nlist-list (x) "The elements in an nlist." (cdr x))
... |
b9f860df1f36f88a663fd6db5af0168dddd1918a58f4374cfb16b496954fd96d | jordanthayer/ocaml-search | high_obstacles.ml | (** For generating instances with many obstacles (but not mazes) *)
open Grid
type cell_types =
| Verboten
| Free
| Blocked
let make_empty_instance ?(i = -1) cost moves x y =
{ blocked = Array.create_matrix x y false;
costs = cost;
moves = moves;
goal = [(x-1), 0];
start = 0,0;
instance =... | null | https://raw.githubusercontent.com/jordanthayer/ocaml-search/57cfc85417aa97ee5d8fbcdb84c333aae148175f/grid/high_obstacles.ml | ocaml | * For generating instances with many obstacles (but not mazes) |
open Grid
type cell_types =
| Verboten
| Free
| Blocked
let make_empty_instance ?(i = -1) cost moves x y =
{ blocked = Array.create_matrix x y false;
costs = cost;
moves = moves;
goal = [(x-1), 0];
start = 0,0;
instance = i; }
let make_rand_h seed =
Random.init seed;
(fun n -> Rando... |
2591b1f226a08b656db211ef7604cd6a3f6b79f7c40e38eb826c28c182b52f30 | NorfairKing/intray | HomeRSpec.hs | module Intray.Web.Server.Handler.HomeRSpec where
import Intray.Web.Server.Foundation
import Intray.Web.Server.TestUtils
import Test.Syd.Yesod
import TestImport
spec :: Spec
spec =
intrayWebServerSpec $
ydescribe "HomeR" $ do
yit "gets a 200 for non-logged-in user" $ do
get HomeR
statusIs 2... | null | https://raw.githubusercontent.com/NorfairKing/intray/6a2422111a3d007b9b89f9eae5965ac7bf6224f8/intray-web-server/test/Intray/Web/Server/Handler/HomeRSpec.hs | haskell | module Intray.Web.Server.Handler.HomeRSpec where
import Intray.Web.Server.Foundation
import Intray.Web.Server.TestUtils
import Test.Syd.Yesod
import TestImport
spec :: Spec
spec =
intrayWebServerSpec $
ydescribe "HomeR" $ do
yit "gets a 200 for non-logged-in user" $ do
get HomeR
statusIs 2... | |
98bbf102dbc15ab50e4c21d1ad778959f2beb86a70c553a31581c439cb37fe4e | zotonic/zotonic | action_wires_slide_fade_out.erl | @author < >
2009
%%
Based on code copyright ( c ) 2008 - 2009
Copyright 2009
%%
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 b... | null | https://raw.githubusercontent.com/zotonic/zotonic/852f627c28adf6e5212e8ad5383d4af3a2f25e3f/apps/zotonic_mod_wires/src/actions/action_wires_slide_fade_out.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 governing per... | @author < >
2009
Based on code copyright ( c ) 2008 - 2009
Copyright 2009
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
distributed under the License is distributed on an " AS IS " BASIS ,
-module(action_wires_slide_fade_out).
-include_lib("zotonic_core/include/zotonic.hr... |
f42e3685c10fc935a9a8cbf5ded43dff4d8dca561e9a6c0d37edae5094401192 | fulcro-legacy/semantic-ui-wrapper | ui_dimmer_dimmable.cljs | (ns fulcrologic.semantic-ui.modules.dimmer.ui-dimmer-dimmable
(:require
[fulcrologic.semantic-ui.factory-helpers :as h]
["semantic-ui-react/dist/commonjs/modules/Dimmer/DimmerDimmable" :default DimmerDimmable]))
(def ui-dimmer-dimmable
"A dimmable sub-component for Dimmer.
Props:
- as (custom): An... | null | https://raw.githubusercontent.com/fulcro-legacy/semantic-ui-wrapper/b0473480ddfff18496df086bf506099ac897f18f/semantic-ui-wrappers-shadow/src/main/fulcrologic/semantic_ui/modules/dimmer/ui_dimmer_dimmable.cljs | clojure | (ns fulcrologic.semantic-ui.modules.dimmer.ui-dimmer-dimmable
(:require
[fulcrologic.semantic-ui.factory-helpers :as h]
["semantic-ui-react/dist/commonjs/modules/Dimmer/DimmerDimmable" :default DimmerDimmable]))
(def ui-dimmer-dimmable
"A dimmable sub-component for Dimmer.
Props:
- as (custom): An... | |
cb9b4ea04d8a2137a68b5d7bac0b400af1546d1fbcb3b255c123c32c4f6cf7b2 | pepeiborra/narradar | NarrowingProblem.hs | # LANGUAGE ScopedTypeVariables #
# LANGUAGE PatternGuards , ViewPatterns , NamedFieldPuns #
# LANGUAGE FlexibleContexts , FlexibleInstances #
# LANGUAGE TypeOperators #
# LANGUAGE TypeFamilies #
# LANGUAGE MultiParamTypeClasses #
# LANGUAGE UndecidableInstances , OverlappingInstances , TypeSynonymInstances #
{-# LANGUA... | null | https://raw.githubusercontent.com/pepeiborra/narradar/bc53dcad9aee480ab3424a75239bac67e4794456/src/Narradar/Processor/NarrowingProblem.hs | haskell | # LANGUAGE GADTs #
-----------
Proofs
-----------
---------------
building blocks
---------------
| Takes a heuristic, an af with groundness information, an af to use as starting point, a problem and a rule,
^ the argument filtering to constrain
^ the rule to make ground | # LANGUAGE ScopedTypeVariables #
# LANGUAGE PatternGuards , ViewPatterns , NamedFieldPuns #
# LANGUAGE FlexibleContexts , FlexibleInstances #
# LANGUAGE TypeOperators #
# LANGUAGE TypeFamilies #
# LANGUAGE MultiParamTypeClasses #
# LANGUAGE UndecidableInstances , OverlappingInstances , TypeSynonymInstances #
module N... |
d6bbf2a03057169a34f5f733aa4e655d6502ae7a1982bbc499860cbb46c3ecaf | BranchTaken/Hemlock | array.mli | open Rudiments0
type 'a t = 'a array
include ContainerIntf.SPolyIter with type 'a t := 'a t
include FormattableIntf.SPoly with type 'a t := 'a t
val fmt: ?alt:bool -> ?width:uns -> ('a -> (module Fmt.Formatter) -> (module Fmt.Formatter))
-> 'a t -> (module Fmt.Formatter) -> (module Fmt.Formatter)
* [ fmt ~alt ~wid... | null | https://raw.githubusercontent.com/BranchTaken/Hemlock/ed397cf3294ca397024e69eb3b1ed5f1db773db6/bootstrap/src/basis/array.mli | ocaml | Seeming excess verbosity is necessary for destructive type substitution.
* [hash_fold hash_fold_a t state] incorporates the hash of [t] into [state] and returns the
resulting state. Array elements are sequentially hash-folded into the resulting state via
[hash_fold_a].
* Efficiently convert a sequence of fix... | open Rudiments0
type 'a t = 'a array
include ContainerIntf.SPolyIter with type 'a t := 'a t
include FormattableIntf.SPoly with type 'a t := 'a t
val fmt: ?alt:bool -> ?width:uns -> ('a -> (module Fmt.Formatter) -> (module Fmt.Formatter))
-> 'a t -> (module Fmt.Formatter) -> (module Fmt.Formatter)
* [ fmt ~alt ~wid... |
6a726f79c1e0af5455084e043a040df30292f77ed6427378c28ef5d528795ef4 | MassD/99 | p62.ml |
Collect the internal nodes of a binary tree in a list . ( easy )
An internal node of a binary tree has either one or two non - empty successors . Write a function internals to collect them in a list .
Collect the internal nodes of a binary tree in a list. (easy)
An internal node of a binary tree has either o... | null | https://raw.githubusercontent.com/MassD/99/1d3019eb55b0d621ed1df4132315673dd812b1e1/55-69-binary-tress/p62.ml | ocaml |
Collect the internal nodes of a binary tree in a list . ( easy )
An internal node of a binary tree has either one or two non - empty successors . Write a function internals to collect them in a list .
Collect the internal nodes of a binary tree in a list. (easy)
An internal node of a binary tree has either o... | |
e23f1159abcf1c9570199780aa74491cead29eede5d477d4916428d806c7b5d1 | mirage/mirage-channel | test_channel.ml | open Lwt.Infix
module F = Mirage_flow_combinators.F
let fail fmt = Fmt.kstr (fun s -> Alcotest.fail s) fmt
(* this is a very small set of tests for the channel interface,
intended to ensure that EOF conditions on the underlying flow are
handled properly *)
module Channel = Mirage_channel.Make(F)
let check_eof... | null | https://raw.githubusercontent.com/mirage/mirage-channel/7e6729e3e06de402526f7a27be18279e5449257f/test/test_channel.ml | ocaml | this is a very small set of tests for the channel interface,
intended to ensure that EOF conditions on the underlying flow are
handled properly
The line is longer than the limit
The line is shorter than the limit and bounded by \r\n | open Lwt.Infix
module F = Mirage_flow_combinators.F
let fail fmt = Fmt.kstr (fun s -> Alcotest.fail s) fmt
module Channel = Mirage_channel.Make(F)
let check_eof = function
| Ok (`Data ch) ->
fail "character %c was returned from Channel.read_char on an empty flow" ch
| Ok `Eof -> Lwt.return ()
| Error e -> fail ... |
fd2c347ca26f119c493a5e7b0978c6746b6532d08b7d68b55082a4b19e50d7da | clash-lang/clash-compiler | Unsigned.hs | |
Copyright : ( C ) 2021 - 2022 , QBayLogic B.V.
License : BSD2 ( see the file LICENSE )
Maintainer : QBayLogic B.V. < >
Random generation of Unsigned numbers .
Copyright : (C) 2021-2022, QBayLogic B.V.
License : BSD2 (see the file LICENSE)
Maintainer : QBayLogic B.V. <>
Random generation ... | null | https://raw.githubusercontent.com/clash-lang/clash-compiler/ba4765139ea0728546bf934005d2d9b77e48d8c7/clash-prelude-hedgehog/src/Clash/Hedgehog/Sized/Unsigned.hs | haskell | # LANGUAGE GADTs # | |
Copyright : ( C ) 2021 - 2022 , QBayLogic B.V.
License : BSD2 ( see the file LICENSE )
Maintainer : QBayLogic B.V. < >
Random generation of Unsigned numbers .
Copyright : (C) 2021-2022, QBayLogic B.V.
License : BSD2 (see the file LICENSE)
Maintainer : QBayLogic B.V. <>
Random generation ... |
f58c46a8d88340c26b9bf78ec4755bc72e30244ccfbfdf44f0cf9f0981f3bfe4 | discus-lang/ddc | LetPrivate.hs | {-# OPTIONS_HADDOCK hide #-}
module DDC.Core.Check.Judge.Type.LetPrivate
(checkLetPrivate)
where
import DDC.Core.Check.Judge.Kind
import DDC.Core.Check.Judge.EqT
import DDC.Core.Check.Judge.Type.Base
import qualified DDC.Core.Env.EnvT as EnvT
import qualified DDC.Type.Sum as Sum
import qualified ... | null | https://raw.githubusercontent.com/discus-lang/ddc/2baa1b4e2d43b6b02135257677671a83cb7384ac/src/s1/ddc-core/DDC/Core/Check/Judge/Type/LetPrivate.hs | haskell | # OPTIONS_HADDOCK hide #
private --------------------------------------
Check the kinds of the region binders.
These must already set to kind Region.
The binders must have region kind.
We can't shadow region binders because we might have witnesses
in the environment that conflict with the ones created here.
Chec... | module DDC.Core.Check.Judge.Type.LetPrivate
(checkLetPrivate)
where
import DDC.Core.Check.Judge.Kind
import DDC.Core.Check.Judge.EqT
import DDC.Core.Check.Judge.Type.Base
import qualified DDC.Core.Env.EnvT as EnvT
import qualified DDC.Type.Sum as Sum
import qualified DDC.Type.Env as Env... |
a15c776ecf2ea1926840cf3938d47462df93288300166218bd8caddba2a0196a | wdebeaum/step | utilize.lisp | ;;;;
;;;; W::utilize
;;;;
(define-words :pos W::v
:words (
(W::utilize
(SENSES
((LF-PARENT ont::use)
(example "a battery utilises a chemical reaction to maintain voltage")
(meta-data :origin beetle2 :entry-date 20080218 :change-date nil :comments pilot1)
(TEMPL AGENT-AFFECTED-XP-NP-TEMPL)
... | null | https://raw.githubusercontent.com/wdebeaum/step/f38c07d9cd3a58d0e0183159d4445de9a0eafe26/src/LexiconManager/Data/new/utilize.lisp | lisp |
W::utilize
|
(define-words :pos W::v
:words (
(W::utilize
(SENSES
((LF-PARENT ont::use)
(example "a battery utilises a chemical reaction to maintain voltage")
(meta-data :origin beetle2 :entry-date 20080218 :change-date nil :comments pilot1)
(TEMPL AGENT-AFFECTED-XP-NP-TEMPL)
)
)
)
))
|
30ce169b8da6fbb1d6a06961f289829dec30fa41d3d7096522c27b6e0004590f | input-output-hk/plutus-apps | Types.hs | # LANGUAGE DataKinds #
{-# LANGUAGE DeriveAnyClass #-}
{-# LANGUAGE DerivingVia #-}
# LANGUAGE LambdaCase #
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE TemplateHaskell #
| Defines a number of types that are used in Wallet . XXX modules
module Wallet.Ty... | null | https://raw.githubusercontent.com/input-output-hk/plutus-apps/0d35e44c615b57c8cce48d4e2d38f33e03e6f7cf/plutus-contract/src/Wallet/Types.hs | haskell | # LANGUAGE DeriveAnyClass #
# LANGUAGE DerivingVia #
# LANGUAGE NamedFieldPuns #
# LANGUAGE OverloadedStrings #
| Unique ID for contract instance
| A pure list of all 'ContractInstanceId' values. To be used in testing.
^ Indicates that the target contract does not have the expected schema
Not currently... | # LANGUAGE DataKinds #
# LANGUAGE LambdaCase #
# LANGUAGE TemplateHaskell #
| Defines a number of types that are used in Wallet . XXX modules
module Wallet.Types(
ContractInstanceId(..)
, contractInstanceIDs
, randomID
, ContractActivityStatus(..)
, parseContractActivityStatus
... |
0224607220eb5faa8f6fca20213df9b0182fc615c675f6deb70dae221845b993 | souenzzo/eql-as | alpha.cljc | (ns br.com.souenzzo.eql-as.alpha
(:refer-clojure :exclude [reverse])
(:require [edn-query-language.core :as eql]
[br.com.souenzzo.eql-as.ast :as ast]
[clojure.spec.alpha :as s]))
(defn as-query
[{::keys [as-map as-key]}]
(-> (ast/as-query {::ast/as-map as-map
::ast/... | null | https://raw.githubusercontent.com/souenzzo/eql-as/d33de8d1b4428d99c25e0d95b008fe4e3e842f24/src/main/br/com/souenzzo/eql_as/alpha.cljc | clojure | (ns br.com.souenzzo.eql-as.alpha
(:refer-clojure :exclude [reverse])
(:require [edn-query-language.core :as eql]
[br.com.souenzzo.eql-as.ast :as ast]
[clojure.spec.alpha :as s]))
(defn as-query
[{::keys [as-map as-key]}]
(-> (ast/as-query {::ast/as-map as-map
::ast/... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.