_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 |
|---|---|---|---|---|---|---|---|---|
f8bdb5576b9c021270a9a52469d5372c5d70b4e253ef43875929afb62608f7b7 | javalib-team/sawja | iter.ml |
* This file is part of SAWJA
* Copyright ( c)2010 ( INRIA )
*
* This program is free software : you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation , either version 3 of
* the License , or ( at your option ) a... | null | https://raw.githubusercontent.com/javalib-team/sawja/da39f9c1c4fc52a1a1a6350be0e39789812b6c00/src/dataflow_analyses/iter.ml | ocaml | program points are chosen in decreasing order
program points are chosen in increasing order
join at current program point
normalize after each join
intra analysis will be computed for points in [0 .. size-1]
entry points in the equation system
constant contraints on entry points |
* This file is part of SAWJA
* Copyright ( c)2010 ( INRIA )
*
* This program is free software : you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation , either version 3 of
* the License , or ( at your option ) a... |
1232874ae1572373ac544d221a335536d9efc69b96c730aa01c0136b92b19c6b | kupl/MicSE | log.ml | (* Logger *)
open! Core
(******************************************************************************)
(******************************************************************************)
(* Setting *)
(**************************************************... | null | https://raw.githubusercontent.com/kupl/MicSE/23678f01f993baac6c45ca2aab029e7356edfa2f/utils/log.ml | ocaml | Logger
****************************************************************************
****************************************************************************
Setting
****************************************************************************
***... |
open! Core
module Setting = struct
let log_created_flag : bool ref = ref false
let log_counter : Mtime_clock.counter = Mtime_clock.counter ()
let reporter : unit -> Logs.reporter =
fun () ->
let report _ level ~over k msgf =
let k' _ =
over ();
k ()
in
let dt ... |
5c4128b915e7e5b05bc023be5ae5c06f4cab81334140684eace4eb62d63fef7f | bobzhang/fan | functor-perf2.ml | <% types, with_constrs, module_application = ARGV.map { |x| x.to_i } %>
module type S = sig
<%- for i in 0 .. types do -%>
type t<%= i %>
<%- end -%>
end
module Make (M : S)
: S with type t0 = M.t0
<%- for i in 1 .. with_constrs do -%>
and type t<%= i %> = M.t<%= i %>
<%- end -%>
= struct
include M
end
... | null | https://raw.githubusercontent.com/bobzhang/fan/7ed527d96c5a006da43d3813f32ad8a5baa31b7f/src/todoml/test/fixtures/functor-perf2.ml | ocaml | <% types, with_constrs, module_application = ARGV.map { |x| x.to_i } %>
module type S = sig
<%- for i in 0 .. types do -%>
type t<%= i %>
<%- end -%>
end
module Make (M : S)
: S with type t0 = M.t0
<%- for i in 1 .. with_constrs do -%>
and type t<%= i %> = M.t<%= i %>
<%- end -%>
= struct
include M
end
... | |
4a87435ad471ebd8202a3cef5a0ba6453a14aee0f6f274d5b33f441c2704848c | pallet/pallet | rpmforge.clj | (ns pallet.crate.package.rpmforge
"Actions for working with the rpmforge repository"
(:require
[pallet.action :refer [action-fn with-action-options]]
[pallet.actions
:refer [exec-checked-script package package-manager repository]]
[pallet.actions-impl :refer [remote-file-action]]
[pallet.core.sessio... | null | https://raw.githubusercontent.com/pallet/pallet/30226008d243c1072dcfa1f27150173d6d71c36d/src/pallet/crate/package/rpmforge.clj | clojure | this is an aggregate so that it can come before the aggragate package-manager | (ns pallet.crate.package.rpmforge
"Actions for working with the rpmforge repository"
(:require
[pallet.action :refer [action-fn with-action-options]]
[pallet.actions
:refer [exec-checked-script package package-manager repository]]
[pallet.actions-impl :refer [remote-file-action]]
[pallet.core.sessio... |
91e1ef270a7d85800d96c5a315b29029e171af699832022c353bf76896884982 | sseefried/open-epidemic-game | SeparateShaders.hs | # LANGUAGE ScopedTypeVariables #
module GraphicsGL.GLSLPrograms.SeparateShaders (
initShaders
) where
import Graphics.Rendering.OpenGL.Raw
-- friends
import Util
import Types.Basic
import GraphicsGL.GLM
import GraphicsGL.Util
import Coordinate
import Foreign
-------------------------------------------------------... | null | https://raw.githubusercontent.com/sseefried/open-epidemic-game/ed623269022edc056dab3fd6d424295c984febec/src/GraphicsGL/GLSLPrograms/SeparateShaders.hs | haskell | friends
--------------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------
-
--
--
--
--
--
--
--
------------------------------------------------------------------------------------------... | # LANGUAGE ScopedTypeVariables #
module GraphicsGL.GLSLPrograms.SeparateShaders (
initShaders
) where
import Graphics.Rendering.OpenGL.Raw
import Util
import Types.Basic
import GraphicsGL.GLM
import GraphicsGL.Util
import Coordinate
import Foreign
worldGLSLSource :: GLSLSource
worldGLSLSource =
GLSLSource {
... |
bb91d69b9bf9e478cca48cbd55f35e93b9635b5a95cfbf899f0d38cdb9c7b917 | DKurilo/hackerrank | solution.hs | # LANGUAGE OverloadedStrings , UnicodeSyntax #
module Main where
import Prelude.Unicode
import Control.Monad
import qualified Data.ByteString.Char8 as BSC
import qualified Data.IntMap.Strict as DM
import Debug.Trace
import System.IO
action ∷ DM.IntMap (DM.IntMap Int) → [Int] → (Maybe Int, DM.IntMap (DM.IntMap Int))
... | null | https://raw.githubusercontent.com/DKurilo/hackerrank/37063170567b397b25a2b7123bc9c1299d34814a/fighting-armies/solution.hs | haskell | # LANGUAGE OverloadedStrings , UnicodeSyntax #
module Main where
import Prelude.Unicode
import Control.Monad
import qualified Data.ByteString.Char8 as BSC
import qualified Data.IntMap.Strict as DM
import Debug.Trace
import System.IO
action ∷ DM.IntMap (DM.IntMap Int) → [Int] → (Maybe Int, DM.IntMap (DM.IntMap Int))
... | |
ecd872720cef08f2db3d3a2e4a00b9731d4d5ad2131199e80ce6a630147ba954 | technomancy/leiningen | core_test.clj | (ns lein-test-reload-bug.core-test
(:require [clojure.test :refer [deftest is]]
[lein-test-reload-bug.a-deftype :refer [->A]]
[lein-test-reload-bug.b-protocol :refer [b]]))
(deftest a-test
(let [a (->A)]
(is (= :ok (b a)))))
| null | https://raw.githubusercontent.com/technomancy/leiningen/24fb93936133bd7fc30c393c127e9e69bb5f2392/test_projects/lein-test-reload-bug/test/lein_test_reload_bug/core_test.clj | clojure | (ns lein-test-reload-bug.core-test
(:require [clojure.test :refer [deftest is]]
[lein-test-reload-bug.a-deftype :refer [->A]]
[lein-test-reload-bug.b-protocol :refer [b]]))
(deftest a-test
(let [a (->A)]
(is (= :ok (b a)))))
| |
69724a1e0d7c40ab2acb77a25ccdf88a3ff535a561493c5ecb1b02253521f121 | kind2-mc/kind2 | lustreReporting.ml | This file is part of the Kind 2 model checker .
Copyright ( c ) 2015 by the Board of Trustees of the University of Iowa
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 a... | null | https://raw.githubusercontent.com/kind2-mc/kind2/fd816db0133f6737147fa4cf3ed49c23dadaf104/src/lustre/lustreReporting.ml | ocaml | *
Error and warning Reporting functions
Raise parsing exception
Raise parsing exception
Raise parsing exception | This file is part of the Kind 2 model checker .
Copyright ( c ) 2015 by the Board of Trustees of the University of Iowa
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 a... |
4a941a2dcb444b31035fa491342f9b5234e4a1d2b9ad8cc9d24ae7a228227988 | michaelliao/cljweb | templating.clj | (ns cljweb.templating
(:use ring.util.response
[selmer.parser :as parser]))
;; middleware using selmer templating system
(parser/cache-off!)
(parser/set-resource-path! (clojure.java.io/resource "templates"))
(defn- try-render [response]
(let [body (:body response)]
(if (map? body)
(let [[model... | null | https://raw.githubusercontent.com/michaelliao/cljweb/d833635a334f1e821e2e7144782b41a7bda700b5/src/cljweb/templating.clj | clojure | middleware using selmer templating system | (ns cljweb.templating
(:use ring.util.response
[selmer.parser :as parser]))
(parser/cache-off!)
(parser/set-resource-path! (clojure.java.io/resource "templates"))
(defn- try-render [response]
(let [body (:body response)]
(if (map? body)
(let [[model template] [(:model body) (:template body)]]
... |
6332b88307a938ea5dc9ac83878a4b66fc3307979fbbf464c4d75201b2d1ba37 | input-output-hk/cardano-transactions | ShelleySpec.hs | # LANGUAGE FlexibleInstances #
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RankNTypes #-}
# LANGUAGE ScopedTypeVariables #
# OPTIONS_GHC -fno - warn - orphans #
module Data.UTxO.Transaction.Cardano.ShelleySpec
( spec
) where
import Prelude
import Codec.Binary.Encoding
( fromBase16, fromBase58, fromB... | null | https://raw.githubusercontent.com/input-output-hk/cardano-transactions/efc3914f950438b70ebe20919bf6c0ecf93b3bbc/test/Data/UTxO/Transaction/Cardano/ShelleySpec.hs | haskell | # LANGUAGE OverloadedStrings #
# LANGUAGE RankNTypes #
Golden
^ An expected encoded result
^ The actual string received
NOTE Using QuickCheck here simply for getting better counter examples
Test Vectors
Mainnet
Testnet | # LANGUAGE FlexibleInstances #
# LANGUAGE ScopedTypeVariables #
# OPTIONS_GHC -fno - warn - orphans #
module Data.UTxO.Transaction.Cardano.ShelleySpec
( spec
) where
import Prelude
import Codec.Binary.Encoding
( fromBase16, fromBase58, fromBech32 )
import Control.Monad
( (>=>) )
import Data.ByteStri... |
43a1cb249e988d00b781fdd4ee40f56c698d298b4cce0e882206501c404f223e | xmonad/xmonad-contrib | NamedScratchpad.hs | # LANGUAGE InstanceSigs #
# LANGUAGE NamedFieldPuns #
{-# LANGUAGE ViewPatterns #-}
-----------------------------------------------------------------------------
-- |
-- Module : XMonad.Util.NamedScratchpad
-- Description : Toggle arbitrary windows to and from the current workspace.
Copyright : ( c )... | null | https://raw.githubusercontent.com/xmonad/xmonad-contrib/49904ec4d3a7ca4021a0f4078d1e15be4526fc93/XMonad/Util/NamedScratchpad.hs | haskell | # LANGUAGE ViewPatterns #
---------------------------------------------------------------------------
|
Module : XMonad.Util.NamedScratchpad
Description : Toggle arbitrary windows to and from the current workspace.
License : BSD-style (see LICENSE)
Stability : unstable
Portability : unportable
... | # LANGUAGE InstanceSigs #
# LANGUAGE NamedFieldPuns #
Copyright : ( c ) < >
Maintainer : < >
module XMonad.Util.NamedScratchpad (
NamedScratchpad(..),
scratchpadWorkspaceTag,
nonFloating,
defaultFloating,
customFloating,
NamedScratchpads,
namedScratchpadAction,
spawnHereNamedScrat... |
be6b7a8883f5f811380b7a464e5e1231d2bd4072aa976f7abba76228a083c982 | lspitzner/brittany | Test205.hs | instance Foo Int where
newtype Bar Int = BarInt
{ unBarInt :: Int
}
| null | https://raw.githubusercontent.com/lspitzner/brittany/a15eed5f3608bf1fa7084fcf008c6ecb79542562/data/Test205.hs | haskell | instance Foo Int where
newtype Bar Int = BarInt
{ unBarInt :: Int
}
| |
af5cf8eedb6e52632a722dc5bc8a1dd2d1da2ffaa02b897b583ea47a65fb8332 | haskoin/haskoin-core | Util.hs | # LANGUAGE CPP #
# LANGUAGE LambdaCase #
# LANGUAGE MultiParamTypeClasses #
|
Module : Haskoin . Util
Copyright : No rights reserved
License : MIT
Maintainer :
Stability : experimental
Portability : POSIX
This module defines various utility functions used across the library .
Mod... | null | https://raw.githubusercontent.com/haskoin/haskoin-core/d155f8803ce73f1211b4f7456e63d27ea9a48b96/src/Haskoin/Util.hs | haskell | * ByteString Helpers
* Maybe & Either Helpers
* Other Helpers
* Triples
* JSON Utilities
* Serialization Helpers
| Encode an 'Integer' to a 'ByteString' as big endian.
| Encode as string of human-readable hex characters.
| Decode string of human-readable hex characters.
| Obtain 'Int' bits from beginning of '... | # LANGUAGE CPP #
# LANGUAGE LambdaCase #
# LANGUAGE MultiParamTypeClasses #
|
Module : Haskoin . Util
Copyright : No rights reserved
License : MIT
Maintainer :
Stability : experimental
Portability : POSIX
This module defines various utility functions used across the library .
Mod... |
58d52f3c2c10b692653bf967b1033eee140ba4021b9a3a63c3474dc04b32aa1d | rleonid/oml | iris_scatter.ml | open Lacaml.D
module LU = Uncategorized.Lacaml_util
let m = Mat.random 10 3 ;;
let r = [1;2;3;1;2;3;1;2;3;1] ;;
#require "dsfo" ;;
let i = Iris.iris ;;
let m = List.map snd i |> Array.of_list |> Mat.of_array ;;
let c = List.map fst i ;;
let masks = LU.class_masks c ;;
let means = LU.class_means m masks ;;
let ... | null | https://raw.githubusercontent.com/rleonid/oml/a857d67708827ed00df3f175a942044601ca50cf/scripts/iris_scatter.ml | ocaml | open Lacaml.D
module LU = Uncategorized.Lacaml_util
let m = Mat.random 10 3 ;;
let r = [1;2;3;1;2;3;1;2;3;1] ;;
#require "dsfo" ;;
let i = Iris.iris ;;
let m = List.map snd i |> Array.of_list |> Mat.of_array ;;
let c = List.map fst i ;;
let masks = LU.class_masks c ;;
let means = LU.class_means m masks ;;
let ... | |
1e3f9f4317098df02a81834ea4865a390b02cff62df182f81c8251635e63edfe | spurious/sagittarius-scheme-mirror | json-schema-tests.scm | #!read-macro=sagittarius/regex
(import (rnrs)
(text json)
(text json schema)
(text json validator)
(util file)
(net server)
(sagittarius socket)
(sagittarius regex)
(util file)
(srfi :39)
(srfi :133)
(chibi test))
This test requires external git repository , so runs only on
;; environment using separated... | null | https://raw.githubusercontent.com/spurious/sagittarius-scheme-mirror/53f104188934109227c01b1e9a9af5312f9ce997/test/json-schema-tests.scm | scheme | environment using separated CMake command.
FIXME copy&paste...
optional tests always fail
format tests always fail, so manually check occasionally
(for-each run-schema-tests format-files) | #!read-macro=sagittarius/regex
(import (rnrs)
(text json)
(text json schema)
(text json validator)
(util file)
(net server)
(sagittarius socket)
(sagittarius regex)
(util file)
(srfi :39)
(srfi :133)
(chibi test))
This test requires external git repository , so runs only on
(define remote-directory "JSON... |
1d7d2e7d663caf82579f470fa5dc7e9009d8203a436b5e0f012078cedac1a5f2 | nedap/utils.modular | example_external_protocol.cljc | (ns unit.nedap.utils.modular.api.example-external-protocol)
(defprotocol Example
:extend-via-metadata true
(do-thing [this]))
(defn do-thing-impl [this]
3000)
| null | https://raw.githubusercontent.com/nedap/utils.modular/4c351624c5b5242317c7fb20e8df2e9aa5384034/test/unit/nedap/utils/modular/api/example_external_protocol.cljc | clojure | (ns unit.nedap.utils.modular.api.example-external-protocol)
(defprotocol Example
:extend-via-metadata true
(do-thing [this]))
(defn do-thing-impl [this]
3000)
| |
65cf7de18eb15970ef28d0fab608ded94ebaaabc2d29aa0025e96448d5c2f2d2 | awslabs/s2n-bignum | bignum_cmul_p384.ml |
* Copyright Amazon.com , Inc. or its affiliates . All Rights Reserved .
* SPDX - License - Identifier : Apache-2.0 OR ISC
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0 OR ISC
*)
(* =================================================================... | null | https://raw.githubusercontent.com/awslabs/s2n-bignum/824c15f908d7a343af1b2f378cfedd36e880bdde/arm/proofs/bignum_cmul_p384.ml | ocaml | =========================================================================
Multiplication modulo p_384 of a single word and a bignum < p_384.
=========================================================================
*** print_literal_from_elf "arm/p384/bignum_cmul_p384.o";;
***
arm_ADDS X8 X8 X12
arm_CS... |
* Copyright Amazon.com , Inc. or its affiliates . All Rights Reserved .
* SPDX - License - Identifier : Apache-2.0 OR ISC
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0 OR ISC
*)
let bignum_cmul_p384_mc = define_assert_from_elf "bignum_cmul_p384... |
37a9d095c23304f28532f1d3057ddb70b08f48381a4c139aa56fa20279e6cde5 | typelead/etlas | ConfVar.hs | {-# LANGUAGE OverloadedStrings #-}
module Distribution.Parsec.ConfVar (parseConditionConfVar) where
import Prelude ()
import Distribution.Compat.Prelude
import Distribution.Compat.Parsec (integral)
import Distribution.Parsec.Class (Parsec (..... | null | https://raw.githubusercontent.com/typelead/etlas/bbd7c558169e1fda086e759e1a6f8c8ca2807583/etlas-cabal/Distribution/Parsec/ConfVar.hs | haskell | # LANGUAGE OverloadedStrings #
| Parse @'Condition' 'ConfVar'@ from section arguments provided by parsec
based outline parser.
preprocess glued operators
The name of the input file is irrelevant, as we reformat the error message.
This is a hack, as we have "broken" .cabal files on Hackage
There are glued operato... | module Distribution.Parsec.ConfVar (parseConditionConfVar) where
import Prelude ()
import Distribution.Compat.Prelude
import Distribution.Compat.Parsec (integral)
import Distribution.Parsec.Class (Parsec (..))
import Distribution.Pa... |
94643b871f38c37bb4559e376e88a343bf165ac6017779389e35efae5ff889f1 | serioga/webapp-clojure-2020 | main.clj | (ns dev.env.main
"Initial namespace for development.
Not included to release application!
See `core` namespace as initial release application."
(:require [dev.env.system.app :as app.system]
[dev.env.system.core :as env.system]
[lib.clojure-tools-logging.logger :as logger]
[... | null | https://raw.githubusercontent.com/serioga/webapp-clojure-2020/215c4419564c65cb69565774758b4912cafac6e6/dev/dev/env/main.clj | clojure | (ns dev.env.main
"Initial namespace for development.
Not included to release application!
See `core` namespace as initial release application."
(:require [dev.env.system.app :as app.system]
[dev.env.system.core :as env.system]
[lib.clojure-tools-logging.logger :as logger]
[... | |
83203e477143e71c5f6462de88784de98a2eb21fad34c9d48ff2eee7af5ae8fc | chanshunli/clojurescript-study | env.clj | (ns highcharts-reagent-gp.env
(:require [clojure.tools.logging :as log]))
(def defaults
{:init
(fn []
(log/info "\n-=[highcharts-reagent-gp started successfully]=-"))
:stop
(fn []
(log/info "\n-=[highcharts-reagent-gp has shut down successfully]=-"))
:middleware identity})
| null | https://raw.githubusercontent.com/chanshunli/clojurescript-study/60f72e0a9198189d8a5a8f80e455909b5368b19f/reagent-use-plugin/highcharts-reagent-gp/env/prod/clj/highcharts_reagent_gp/env.clj | clojure | (ns highcharts-reagent-gp.env
(:require [clojure.tools.logging :as log]))
(def defaults
{:init
(fn []
(log/info "\n-=[highcharts-reagent-gp started successfully]=-"))
:stop
(fn []
(log/info "\n-=[highcharts-reagent-gp has shut down successfully]=-"))
:middleware identity})
| |
6075ca84a4858cf7c03b071cef682f325a0ed5366b77766bca0d29b15cd68038 | MinaProtocol/mina | pallas_constraint_system.ml | open Kimchi_backend_common
open Kimchi_pasta_basic
include
Plonk_constraint_system.Make (Fq) (Kimchi_bindings.Protocol.Gates.Vector.Fq)
(struct
let params =
Sponge.Params.(
map pasta_q_kimchi ~f:(fun x ->
Fq.of_bigint (Bigint256.of_decimal_string x) ))
end)
| null | https://raw.githubusercontent.com/MinaProtocol/mina/a40d965ae6b39ca93d9eed17efcbf77e0778de0a/src/lib/crypto/kimchi_backend/pasta/constraint_system/caml/pallas_constraint_system.ml | ocaml | open Kimchi_backend_common
open Kimchi_pasta_basic
include
Plonk_constraint_system.Make (Fq) (Kimchi_bindings.Protocol.Gates.Vector.Fq)
(struct
let params =
Sponge.Params.(
map pasta_q_kimchi ~f:(fun x ->
Fq.of_bigint (Bigint256.of_decimal_string x) ))
end)
| |
2c67f3d0c3f8cb417c990f71de784083324cd774a4b61855361efcb017f50ad6 | ssm-lang/sslang | SegmentLets.hs | -- | Unroll let-def blocks to break apart non-mutually recursive definitions.
{-# LANGUAGE OverloadedStrings #-}
module IR.SegmentLets
( segmentLets
, segmentDefs
, segmentDefs'
) where
import qualified Common.Compiler as Compiler
import Common.Identifiers ( HasFreeVars(..)
... | null | https://raw.githubusercontent.com/ssm-lang/sslang/d23597773d471fb222890e31a984d54289b45d28/src/IR/SegmentLets.hs | haskell | | Unroll let-def blocks to break apart non-mutually recursive definitions.
# LANGUAGE OverloadedStrings # | module IR.SegmentLets
( segmentLets
, segmentDefs
, segmentDefs'
) where
import qualified Common.Compiler as Compiler
import Common.Identifiers ( HasFreeVars(..)
, VarId(..)
, gen... |
8777108d8c02455a1c88f2d1fb7175cdf75272f7bcaaf48e54c2f8f575e5fe79 | phadej/cabal-fmt | Fields.hs | -- |
-- License: GPL-3.0-or-later
Copyright :
# LANGUAGE DeriveFunctor #
# LANGUAGE ExistentialQuantification #
# LANGUAGE FlexibleInstances #
# LANGUAGE MultiParamTypeClasses #
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE UndecidableInstances #-}
module CabalFmt.Fields (
... | null | https://raw.githubusercontent.com/phadej/cabal-fmt/ead940a3dd955a2c7b32b8817b03885ff550c128/src/CabalFmt/Fields.hs | haskell | |
License: GPL-3.0-or-later
# LANGUAGE RankNTypes #
# LANGUAGE UndecidableInstances #
-----------------------------------------------------------------------------
-----------------------------------------------------------------------------
strict pair
| Lookup both pretty-printer and value par... | Copyright :
# LANGUAGE DeriveFunctor #
# LANGUAGE ExistentialQuantification #
# LANGUAGE FlexibleInstances #
# LANGUAGE MultiParamTypeClasses #
module CabalFmt.Fields (
FieldDescrs,
fieldDescrLookup,
coerceFieldDescrs,
singletonF,
) where
import qualified Data.Map.Str... |
6e0d2ba779c7f91cc8a18d9301c4bd72c9359815432a322eb74ad023acbdce08 | reactiveml/rml | rml_fake.mli | type 'a process
type ('a, 'b) event
| null | https://raw.githubusercontent.com/reactiveml/rml/d178d49ed923290fa7eee642541bdff3ee90b3b4/doc/stdlib/rml_fake.mli | ocaml | type 'a process
type ('a, 'b) event
| |
3d5c169de28b627094a54c78bfae274b3352fe1bbc2f577363e27782ed802a79 | 8c6794b6/guile-tjit | describe.scm | ;;; installed-scm-file
Copyright ( C ) 1998 , 1999 , 2001 , 2006 , 2008 , 2009 , 2015 Free Software Foundation , Inc.
Copyright ( C ) 1993 - 1998 / ESSI < >
;;;;
;;;; This library is free software; you can redistribute it and/or
;;;; modify it under the terms of the GNU Lesser General Public
License as pu... | null | https://raw.githubusercontent.com/8c6794b6/guile-tjit/9566e480af2ff695e524984992626426f393414f/module/oop/goops/describe.scm | scheme | installed-scm-file
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
either
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PART... |
Copyright ( C ) 1998 , 1999 , 2001 , 2006 , 2008 , 2009 , 2015 Free Software Foundation , Inc.
Copyright ( C ) 1993 - 1998 / ESSI < >
version 3 of the License , or ( at your option ) any later version .
You should have received a copy of the GNU Lesser General Public
Foundation , Inc. , 51 Franklin St... |
93e09252476a09ccc06ccd0beb5b83dd06a7cad5859124b42ba6bcf879cf1397 | sweirich/pi-forall | Environment.hs | {- pi-forall language -}
-- | Utilities for managing a typechecking context.
module Environment
( TcMonad,
runTcMonad,
Env,
emptyEnv,
lookupTy,
lookupTyMaybe,
lookupDef,
lookupRecDef,
lookupHint,
getCtx,
getLocalCtx,
extendCtx,
extendCtxs,
extendCtxsGlobal,
ext... | null | https://raw.githubusercontent.com/sweirich/pi-forall/93de2eee777c9123bf67534b7b8453656370542d/version1/src/Environment.hs | haskell | pi-forall language
| Utilities for managing a typechecking context.
environment), freshness state (for supporting locally-nameless
(for e.g. warning messages).
| Entry point for the type checking monad, given an
initial environment, returns either an error message
or some result.
| Marked locations in the sou... |
module Environment
( TcMonad,
runTcMonad,
Env,
emptyEnv,
lookupTy,
lookupTyMaybe,
lookupDef,
lookupRecDef,
lookupHint,
getCtx,
getLocalCtx,
extendCtx,
extendCtxs,
extendCtxsGlobal,
extendCtxMods,
extendHints,
extendSourceLocation,
getSourceLocation,... |
556a08f2910250f1de1bc48c925a8f8d668efa1b54866030c1721eab6731c287 | janestreet/merlin-jst | load_path.ml | (**************************************************************************)
(* *)
(* OCaml *)
(* *)
... | null | https://raw.githubusercontent.com/janestreet/merlin-jst/980b574405617fa0dfb0b79a84a66536b46cd71b/src/ocaml/utils/load_path.ml | ocaml | ************************************************************************
OCaml
... | , Jane Street Europe
Copyright 2018 Jane Street Group LLC
the GNU Lesser General Public License version 2.1 , with the
open Local_store
module STbl = Misc.String.Tbl
type registry = string STbl.t
let files : registry ref = s... |
4917855b1fc599fb2a7be5cabff3f6bfedfeb96e3692d73d398a31561f01ecbe | Silvast/valihuuto | config.clj | (ns valihuuto.config
(:require [clojure.java.io :as io]
[clojure.edn :as edn]
[environ.core :refer [env]]))
(def ^:private default-file "configuration/default.edn")
(defn- load-config [file]
(with-open [reader (io/reader file)]
(edn/read (java.io.PushbackReader. reader))))
(defn get-c... | null | https://raw.githubusercontent.com/Silvast/valihuuto/ad7d2cf98eebe4290fdf25479c2ff2865c1770d5/src/valihuuto/config.clj | clojure | (ns valihuuto.config
(:require [clojure.java.io :as io]
[clojure.edn :as edn]
[environ.core :refer [env]]))
(def ^:private default-file "configuration/default.edn")
(defn- load-config [file]
(with-open [reader (io/reader file)]
(edn/read (java.io.PushbackReader. reader))))
(defn get-c... | |
384a39618a242e7fbe1d78b8bc40ffd32ce8c41e8dc1641045c13352a7311955 | bytekid/mkbtt | trs.ml | Copyright 2008 , Christian Sternagel ,
* GNU Lesser General Public License
*
* This file is part of TTT2 .
*
* TTT2 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 ve... | null | https://raw.githubusercontent.com/bytekid/mkbtt/c2f8e0615389b52eabd12655fe48237aa0fe83fd/src/processors/src/rewriting/trs.ml | ocaml | ** MODULES *****************************************************************
** OPENS *******************************************************************
** INCLUDES ****************************************************************
** FUNCTIONS ***************************************************************
Labeling an... | Copyright 2008 , Christian Sternagel ,
* GNU Lesser General Public License
*
* This file is part of TTT2 .
*
* TTT2 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 ve... |
4d46e8546f12fe1871dc9a8998f7da64a1a1dbfa7738620d010cc67dc8849c78 | puppetlabs/trapperkeeper-webserver-jetty9 | webrouting_service.clj | (ns puppetlabs.trapperkeeper.services.webrouting.webrouting-service
(:require
[clojure.tools.logging :as log]
[puppetlabs.trapperkeeper.services :refer [service-context]]
[puppetlabs.trapperkeeper.services.webrouting.webrouting-service-core :as core]
[puppetlabs.trapperkeeper.core :refer [defservice]... | null | https://raw.githubusercontent.com/puppetlabs/trapperkeeper-webserver-jetty9/98fd16ef3df2b0b753fce743848bc078d9527cb7/src/puppetlabs/trapperkeeper/services/webrouting/webrouting_service.clj | clojure | (ns puppetlabs.trapperkeeper.services.webrouting.webrouting-service
(:require
[clojure.tools.logging :as log]
[puppetlabs.trapperkeeper.services :refer [service-context]]
[puppetlabs.trapperkeeper.services.webrouting.webrouting-service-core :as core]
[puppetlabs.trapperkeeper.core :refer [defservice]... | |
5f3a0deb6daa3126409f098bdf1ce3d2c92e78b0f324a6cc007270c1bd8ccbd8 | abdulapopoola/SICPBook | Ex2.60.scm | #lang planet neil/sicp
;; helpers
(define (element-of-set? x set)
(cond ((null? set) false)
((equal? x (car set)) true)
(else (element-of-set? x (cdr set)))))
O(N ) no difference from version in 2.59
(define (adjoin-set x set)
(cons x set))
O(1 ) different from version in 2.59 which is O(N )
(d... | null | https://raw.githubusercontent.com/abdulapopoola/SICPBook/c8a0228ebf66d9c1ddc5ef1fcc1d05d8684f090a/Chapter%202/2.3/Ex2.60.scm | scheme | helpers
This version might be preferred for operations on large datasets
which require speed. The flipside is that lookups might take more
time as N grows larger due to replication of the same values and more
memory usage too. | #lang planet neil/sicp
(define (element-of-set? x set)
(cond ((null? set) false)
((equal? x (car set)) true)
(else (element-of-set? x (cdr set)))))
O(N ) no difference from version in 2.59
(define (adjoin-set x set)
(cons x set))
O(1 ) different from version in 2.59 which is O(N )
(define (unio... |
397282e53a24b3748e5e64f0d8565574118c2d396cc64acc10cc53cd37e22fd8 | pavankumarbn/DroneGUIROS | _package_navdata_trackers_send.lisp | (cl:in-package ardrone_autonomy-msg)
(cl:export '(HEADER-VAL
HEADER
DRONE_TIME-VAL
DRONE_TIME
TAG-VAL
TAG
SIZE-VAL
SIZE
LOCKED-VAL
LOCKED
POINT-VAL
POINT
)) | null | https://raw.githubusercontent.com/pavankumarbn/DroneGUIROS/745320d73035bc50ac4fea2699e22586e10be800/devel/share/common-lisp/ros/ardrone_autonomy/msg/_package_navdata_trackers_send.lisp | lisp | (cl:in-package ardrone_autonomy-msg)
(cl:export '(HEADER-VAL
HEADER
DRONE_TIME-VAL
DRONE_TIME
TAG-VAL
TAG
SIZE-VAL
SIZE
LOCKED-VAL
LOCKED
POINT-VAL
POINT
)) | |
035d178ca5cf460d45d67654b5480f97573602e9482c31092a2094cc5bbfd624 | cbaggers/l-lisp | buffer.lisp | ;;; *** buffer.lisp ***
;;;
This file is part of L - Lisp by .
;;; Implements a growing sequence as a list of vectors.
(in-package :l-systems)
;; *** Buffer data structure ***
(defstruct (buffer (:constructor internal-make-buffer))
(inc-size 0 :type fixnum) ; size of each "minibuffer"
(list nil) ... | null | https://raw.githubusercontent.com/cbaggers/l-lisp/7a09d3a5a59cf63fead2a15b7b995787d7c6971d/buffer.lisp | lisp | *** buffer.lisp ***
Implements a growing sequence as a list of vectors.
*** Buffer data structure ***
size of each "minibuffer"
list of minibuffers
current minibuffer (for fast access)
total number of elements
number of elements in current buffer
length of list | This file is part of L - Lisp by .
(in-package :l-systems)
(defstruct (buffer (:constructor internal-make-buffer))
(defun make-buffer (&optional (inc-size 4096))
(internal-make-buffer :inc-size inc-size
:current-size inc-size))
(declaim (inline buffer-push))
(defun buffer-push (elt bu... |
04cd81da9dea0d668936fa879f5f375b3a9abf39a538a5156cb19e8e97c68ebd | lancelet/wgpu-hs | Git.hs | {-# LANGUAGE OverloadedStrings #-}
-- | Obtain simple git submodule information to dump in the output.
module WGPU.Metadata.Git
( -- * Functions
getWGPUSubmoduleString,
)
where
import Control.Monad (when)
import Data.Text (Text)
import qualified Data.Text as Text
import System.Process (readProcess)
| Fetch... | null | https://raw.githubusercontent.com/lancelet/wgpu-hs/61c8af77726650eedf8f9ca481d73d4b950e1b4c/wgpu-raw-hs-codegen/src/WGPU/Metadata/Git.hs | haskell | # LANGUAGE OverloadedStrings #
| Obtain simple git submodule information to dump in the output.
* Functions |
module WGPU.Metadata.Git
getWGPUSubmoduleString,
)
where
import Control.Monad (when)
import Data.Text (Text)
import qualified Data.Text as Text
import System.Process (readProcess)
| Fetch the string output for @wgpu - native@ from @git submodule status@.
getWGPUSubmoduleString :: IO Text
getWGPUSubmoduleStri... |
fdd5069916020ddb3121556cf5da1f3233857f46f52b81a7038a5283bd8d5b66 | clj-kondo/clj-kondo | ok.clj | (ns read-error.ok)
(defn foo [] 1)
;; this should still yield an error
(foo 1)
| null | https://raw.githubusercontent.com/clj-kondo/clj-kondo/626978461cbf113c376634cdf034d7262deb429f/corpus/read_error/ok.clj | clojure | this should still yield an error | (ns read-error.ok)
(defn foo [] 1)
(foo 1)
|
104fb8a85181e687caa71f90988d9d5d96b8f75d4c740ba864f664c5b475c8f3 | mlabs-haskell/hydra-demo | OnChain.hs | {-# LANGUAGE DeriveAnyClass #-}
# LANGUAGE TemplateHaskell #
# LANGUAGE TypeFamilies #
module HydraRPS.OnChain (
rpsValidator,
rpsValidatorHash,
rpsValidatorAddress,
typedRPSValidator,
Gesture (..),
GameDatum (..),
GameRedeemer (..),
RPS,
beats,
encryptGesture,
toGesture,
) where
import Data.Aes... | null | https://raw.githubusercontent.com/mlabs-haskell/hydra-demo/e5efebe1adbb379be293550996500ece9f6aa242/src/HydraRPS/OnChain.hs | haskell | # LANGUAGE DeriveAnyClass # | # LANGUAGE TemplateHaskell #
# LANGUAGE TypeFamilies #
module HydraRPS.OnChain (
rpsValidator,
rpsValidatorHash,
rpsValidatorAddress,
typedRPSValidator,
Gesture (..),
GameDatum (..),
GameRedeemer (..),
RPS,
beats,
encryptGesture,
toGesture,
) where
import Data.Aeson (FromJSON, ToJSON)
import GHC... |
6b5c7dd21d1fbfdc56fcacaba9868e499828a4cf43242c81bf1c6f605c000b43 | pjotrp/guix | kde.scm | ;;; GNU Guix --- Functional package management for GNU
Copyright © 2013 , 2014 , 2015 < >
;;;
;;; This file is part of GNU Guix.
;;;
GNU is free software ; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by
the Free Software Foundation ; either version... | null | https://raw.githubusercontent.com/pjotrp/guix/96250294012c2f1520b67f12ea80bfd6b98075a2/gnu/packages/kde.scm | scheme | GNU Guix --- Functional package management for GNU
This file is part of GNU Guix.
you can redistribute it and/or modify it
either version 3 of the License , or ( at
your option) any later version.
GNU Guix is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied wa... | Copyright © 2013 , 2014 , 2015 < >
under the terms of the GNU General Public License as published by
You should have received a copy of the GNU General Public License
along with GNU . If not , see < / > .
(define-module (gnu packages kde)
#:use-module ((guix licenses) #:select (bsd-2 lgpl2.0+ lgpl2.1 l... |
1126456254f1cd1ad401d9fea59bd0cdba505591c94cedc206454b0d5b7b1ac8 | sogaiu/adorn | core.cljs | (ns adorn.core
(:require [adorn.atom :as aa]
[adorn.dispose :as ad]
[adorn.jsonrpc :as aj]))
(def cp
(js/require "child_process"))
(def path
(js/require "path"))
(def adorn-path
(let [pkg-dir-path (->> (aa/path-for-pkg "adorn")
(.dirname path)
... | null | https://raw.githubusercontent.com/sogaiu/adorn/e76dc2b04c58db2c79eff7700055ca7ddbf79eda/atom/src/adorn/core.cljs | clojure | receiving response from helper
XXX: handle error case
XXX: when no text returned, tell user no defn/defn- detected?
sending to helper
| (ns adorn.core
(:require [adorn.atom :as aa]
[adorn.dispose :as ad]
[adorn.jsonrpc :as aj]))
(def cp
(js/require "child_process"))
(def path
(js/require "path"))
(def adorn-path
(let [pkg-dir-path (->> (aa/path-for-pkg "adorn")
(.dirname path)
... |
d8df8571f9cffce19abd1ef705b558ca1e518cdecc8d475f8d119a8a937f2c92 | jyh/metaprl | m_doc_x86_asm.ml | (* -*- mode: text; -*- *)
doc <:doc<
@begin[spelling]
mem reg CMP DIV INC JEQ JGT JLT JMP MOV MUL cc cmp eax ebp ebx ecx
edi edx esi esp inst jcc jmp mov opcodes Caml
@end[spelling]
@section[m_doc_x86_asm]{Scoped x86 assembly language}
@docoff
-----------------------------------------------------... | null | https://raw.githubusercontent.com/jyh/metaprl/51ba0bbbf409ecb7f96f5abbeb91902fdec47a19/theories/experimental/compile/m_doc_x86_asm.ml | ocaml | -*- mode: text; -*-
* Operands.
* Condition codes.
* Instructions.
* Various forms of tailcalls.
* The tailcall takes the arguments in a list.
* For conditional jumps, pretend that it is a real
* conditional. The printer will have to insert a label.
* Reserve some words.
* The params are the... | doc <:doc<
@begin[spelling]
mem reg CMP DIV INC JEQ JGT JLT JMP MOV MUL cc cmp eax ebp ebx ecx
edi edx esi esp inst jcc jmp mov opcodes Caml
@end[spelling]
@section[m_doc_x86_asm]{Scoped x86 assembly language}
@docoff
----------------------------------------------------------------
@begin[lic... |
912b8f22634502b791333d51e2db2c61ab6bf41f4a18f73a73d75489d0f05128 | cracauer/sbcl-ita | alloc.lisp | allocation VOPs for the Sparc port
This software is part of the SBCL system . See the README file for
;;;; more information.
;;;;
This software is derived from the CMU CL system , which was
written at Carnegie Mellon University and released into the
;;;; public domain. The software is in the public domain and ... | null | https://raw.githubusercontent.com/cracauer/sbcl-ita/f85a8cf0d1fb6e8c7b258e898b7af3233713e0b9/src/compiler/sparc/alloc.lisp | lisp | more information.
public domain. The software is in the public domain and is
provided with absolutely no warranty. See the COPYING and CREDITS
files for more information.
LIST and LIST*
Special purpose inline allocators.
Not any more, or not in that sense at least, because the
"p/a bit is also the highest lo... | allocation VOPs for the Sparc port
This software is part of the SBCL system . See the README file for
This software is derived from the CMU CL system , which was
written at Carnegie Mellon University and released into the
(in-package "SB!VM")
(define-vop (list-or-list*)
(:args (things :more t))
(:tempor... |
fc55c13a723a1c6f32188f68bf350836adf37b0105f34dc31846dd32c9f83efb | abailly/hevents | Version.hs | # LANGUAGE PatternSynonyms , ScopedTypeVariables , AllowAmbiguousTypes , DataKinds , KindSignatures , GADTs , PolyKinds , DeriveFunctor #
import Data.ByteString (ByteString)
import Data.Proxy
import Data.Serialize
import Data.Text (Text, pack)
import Data.Te... | null | https://raw.githubusercontent.com/abailly/hevents/d38789bf5ae787c35d496b72fe47419d965032de/test/Hevents/Eff/Version.hs | haskell | | "Horizontal" composition, to enumerate arguments
| Compute a path in a tree of tuple values
| Vertical composition. "applies" A function to its arguments, yielding a result
| Generalized application of a "function" `f` to an argument `a` yielding a result `b`
| Defines how to `graft` value inside another structu... | # LANGUAGE PatternSynonyms , ScopedTypeVariables , AllowAmbiguousTypes , DataKinds , KindSignatures , GADTs , PolyKinds , DeriveFunctor #
import Data.ByteString (ByteString)
import Data.Proxy
import Data.Serialize
import Data.Text (Text, pack)
import Data.Te... |
5becd25d707d2eb26614d8e2724d2f3340a5cf78d6c0b5a9e935e993d9158446 | TakaiKinoko/Cornell_CS3110_OCaml | Stack_type.ml | * module type Stack
module type Stack = sig
type 'a stack (** The type 'a stack is an example of a representation type: a type that is used to represent a version of a data structure *)
val empty : 'a stack
val is_empty : 'a stack -> bool
val push : 'a -> 'a stack -> 'a stack
val peek : 'a stack -... | null | https://raw.githubusercontent.com/TakaiKinoko/Cornell_CS3110_OCaml/0a830bc50a5e39f010074dc289161426294cad1d/Chap5_Modules/01module/Stack_type.ml | ocaml | * The type 'a stack is an example of a representation type: a type that is used to represent a version of a data structure | * module type Stack
module type Stack = sig
val empty : 'a stack
val is_empty : 'a stack -> bool
val push : 'a -> 'a stack -> 'a stack
val peek : 'a stack -> 'a
val pop : 'a stack -> 'a stack
end
* now define a module ListStack with type Stack
module ListStack : Stack = struct
type 'a stack ... |
da67bb19b5957ee5071b243daa2ae15d3cc244fb9d1b5a9f02f3d96a1d09e5bb | linkfluence/inventory | core.clj | (ns com.linkfluence.inventory.prometheus.core
(:require [compojure.core :refer :all]
[compojure.route :as route]
[ring.adapter.jetty :refer [run-jetty]]
[ring.util.response :refer [response]]
[ring.middleware.gzip :refer [wrap-gzip]]
[ring.middleware.content... | null | https://raw.githubusercontent.com/linkfluence/inventory/c9ef909b36cb484375afe188982c02e49561c27d/src/clj/com/linkfluence/inventory/prometheus/core.clj | clojure | import api handler | (ns com.linkfluence.inventory.prometheus.core
(:require [compojure.core :refer :all]
[compojure.route :as route]
[ring.adapter.jetty :refer [run-jetty]]
[ring.util.response :refer [response]]
[ring.middleware.gzip :refer [wrap-gzip]]
[ring.middleware.content... |
aff183e304f0b8bbfd9b983163bbf1394d2d32a814ee90277012aa78ff5db802 | eeng/shevek | designer.cljs | (ns shevek.schemas.designer
(:require [schema.core :as s]
[shevek.schemas.cube :refer [Dimension Measure]]
[shevek.schemas.query :refer [Results RawQueryResults SortBy StringOrNumber]]
[shevek.schemas.report :refer [Report]]))
(s/defschema Split
(assoc Dimension
:limit ... | null | https://raw.githubusercontent.com/eeng/shevek/7783b8037303b8dd5f320f35edee3bfbb2b41c02/src/cljs/shevek/schemas/designer.cljs | clojure | (ns shevek.schemas.designer
(:require [schema.core :as s]
[shevek.schemas.cube :refer [Dimension Measure]]
[shevek.schemas.query :refer [Results RawQueryResults SortBy StringOrNumber]]
[shevek.schemas.report :refer [Report]]))
(s/defschema Split
(assoc Dimension
:limit ... | |
058d19212136566e598742947c126e955805a5c1d51021d244f264f1f29c9479 | appleshan/cl-http | packages.lisp | -*- Syntax : Ansi - Common - Lisp ; Package : cl - user ; Base : 10 ; Mode : lisp -*-
;;; File: packages.lisp
Last edited by smishra on Fri Feb 6 00:59:11 1998
( c ) Copyright 1996 - 97 , ( )
;;; All Rights Reserved
#-CL-HTTP
(defpackage tk1
(:use #+GENERA :future-common-lisp
#+(OR LISPWORKS ALLEG... | null | https://raw.githubusercontent.com/appleshan/cl-http/a7ec6bf51e260e9bb69d8e180a103daf49aa0ac2/html-parser/v9/packages.lisp | lisp | Package : cl - user ; Base : 10 ; Mode : lisp -*-
File: packages.lisp
All Rights Reserved
Classes
Primary functions
Secondary functions
Definition macros - probably not for the general user
Variables & constants
Other symbols |
Last edited by smishra on Fri Feb 6 00:59:11 1998
( c ) Copyright 1996 - 97 , ( )
#-CL-HTTP
(defpackage tk1
(:use #+GENERA :future-common-lisp
#+(OR LISPWORKS ALLEGRO LUCID MCL CMU) :common-lisp
#+mcl :ccl)
(:export
"DEFINE-TOKENIZER"
"UNDEFINE-TOKENIZER"))
(defpackage :html-parser
#+CL-HT... |
241296c0771e9ae676c3206a15f0b51ca121db1ea2b1f78a4aa0e17f8bce9330 | humorless/spark-movie-lens | handler.clj | (ns intowow.test.handler
(:require [clojure.test :refer :all]
[ring.mock.request :refer :all]
[intowow.handler :refer :all]))
(deftest test-app
(testing "main route"
(let [response ((app) (request :get "/"))]
(is (= 200 (:status response)))))
(testing "not-found route"
(let... | null | https://raw.githubusercontent.com/humorless/spark-movie-lens/3062227f0087f8437144cebc5f8cfbd2ee74e965/test/clj/intowow/test/handler.clj | clojure | (ns intowow.test.handler
(:require [clojure.test :refer :all]
[ring.mock.request :refer :all]
[intowow.handler :refer :all]))
(deftest test-app
(testing "main route"
(let [response ((app) (request :get "/"))]
(is (= 200 (:status response)))))
(testing "not-found route"
(let... | |
c71a50acf12286cbd0ed0fc5794f6318ab55cc86f3b5f369863038411de19518 | brianhempel/maniposynth | nat_plus.ml | type nat = Z | S of nat
let rec plus a b =
match b with S nat -> S (plus a nat) | Z -> a
[@@pos 826, 273]
let plus_S = plus (S Z) (S (S (S Z))) [@@pos 1276, 283]
| null | https://raw.githubusercontent.com/brianhempel/maniposynth/8cb8e0c84db2ffb51feae2fccb10dbff40c4e0e0/expert_eval_manual/nat_plus.ml | ocaml | type nat = Z | S of nat
let rec plus a b =
match b with S nat -> S (plus a nat) | Z -> a
[@@pos 826, 273]
let plus_S = plus (S Z) (S (S (S Z))) [@@pos 1276, 283]
| |
b1b1396db524d68e48c9cbbd9a61b7c6a497e329841f607481888a218b09457e | instedd/planwise | coverage.cljs | (ns planwise.client.coverage
(:require [re-frame.core :as rf]
[planwise.client.components.common2 :as common2]
[planwise.client.utils :as utils]
[planwise.client.ui.rmwc :as m]))
;; ----------------------------------------------------------------------------
;; API methods
(def l... | null | https://raw.githubusercontent.com/instedd/planwise/9a8d49042310df7ca4c79a1aa211712af9ce72a7/client/src/planwise/client/coverage.cljs | clojure | ----------------------------------------------------------------------------
API methods
----------------------------------------------------------------------------
Events
----------------------------------------------------------------------------
Subs
----------------------------------------------------------... | (ns planwise.client.coverage
(:require [re-frame.core :as rf]
[planwise.client.components.common2 :as common2]
[planwise.client.utils :as utils]
[planwise.client.ui.rmwc :as m]))
(def load-coverage-algorithms
{:method :get
:uri "/api/coverage/algorithms"})
(rf/reg-event... |
6446500a8ac61973982fd88585e9b70f3ddf298ac4990cc64b3867119f43a01f | mejgun/haskell-tdlib | PhotoSize.hs | {-# LANGUAGE OverloadedStrings #-}
-- |
module TD.Data.PhotoSize where
import qualified Data.Aeson as A
import qualified Data.Aeson.Types as T
import qualified TD.Data.File as File
import qualified Utils as U
-- |
data PhotoSize = -- | Describes an image in JPEG format
PhotoSize
{ -- | Sizes of progressive JPEG ... | null | https://raw.githubusercontent.com/mejgun/haskell-tdlib/dc380d18d49eaadc386a81dc98af2ce00f8797c2/src/TD/Data/PhotoSize.hs | haskell | # LANGUAGE OverloadedStrings #
|
|
| Describes an image in JPEG format
| Sizes of progressive JPEG file prefixes, which can be used to preliminarily show the image; in bytes
| Image height
| Image width
| Information about the image file
| Image type (see ) |
module TD.Data.PhotoSize where
import qualified Data.Aeson as A
import qualified Data.Aeson.Types as T
import qualified TD.Data.File as File
import qualified Utils as U
PhotoSize
progressive_sizes :: Maybe [Int],
height :: Maybe Int,
width :: Maybe Int,
photo :: Maybe File.File,
_type :: Maybe ... |
afa16ffe333fff58e827bb51d1a0aa6436de92617d2565c9130db2a3cb58a957 | jackfirth/rebellion | sorted-map-interface.rkt | #lang racket/base
(require racket/contract/base)
(provide
(contract-out
[sorted-map? predicate/c]
[immutable-sorted-map? predicate/c]
[mutable-sorted-map? predicate/c]
[in-sorted-map (->* (sorted-map?) (#:descending? boolean?) (sequence/c entry?))]
[in-sorted-map-keys (->* (sorted-map?) (#:descending? bo... | null | https://raw.githubusercontent.com/jackfirth/rebellion/206ced365b07d1c6da5dcbe93f892fbb9bd7ba72/collection/private/sorted-map-interface.rkt | racket | The APIs for creating the generic, extensible hierarchy of collection implementations exist only to
external consumption, and no promises of API stability or quality are made. Please do not make your
own implementations of these interfaces; instead file an issue at
describing your use case. These APIs might be mad... | #lang racket/base
(require racket/contract/base)
(provide
(contract-out
[sorted-map? predicate/c]
[immutable-sorted-map? predicate/c]
[mutable-sorted-map? predicate/c]
[in-sorted-map (->* (sorted-map?) (#:descending? boolean?) (sequence/c entry?))]
[in-sorted-map-keys (->* (sorted-map?) (#:descending? bo... |
28f0788e1f52f98e01a8c7ae4780d1f4ab2190d4a58fdda94c9bd2550cc6a01c | CBMM/tagging | Subject.hs | # LANGUAGE OverloadedStrings #
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE ScopedTypeVariables #-}
# LANGUAGE RecordWildCards #
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE TypeOperators #-}
# LANGUAGE MultiParamTypeClasses #
module Server.Subject where
import Control.Er... | null | https://raw.githubusercontent.com/CBMM/tagging/15f257394f3dda5baf6db0581a52d9c9f99e2abe/tagging-server/src/Server/Subject.hs | haskell | # LANGUAGE DeriveGeneric #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE DataKinds #
# LANGUAGE TypeOperators #
----------------------------------------------------------------------------
----------------------------------------------------------------------------
--------------------------... | # LANGUAGE OverloadedStrings #
# LANGUAGE RecordWildCards #
# LANGUAGE MultiParamTypeClasses #
module Server.Subject where
import Control.Error
import Control.Lens
import Control.Monad
import Control.Monad.IO.Class (liftIO)
import Control.Monad.Trans.C... |
7a8b88a71888582412b3c5f31adeed96dc816fc235dcb025b97706844532021e | ijvcms/chuanqi_dev | scene_npc_lib.erl | %%%-------------------------------------------------------------------
%%% @author tuhujia
( C ) 2016 , < COMPANY >
%%% @doc 场景npc
%%%
%%% @end
Created : 05 . 一月 2016 10:01
%%%-------------------------------------------------------------------
-module(scene_npc_lib).
-include("common.hrl").
-include("record.hrl")... | null | https://raw.githubusercontent.com/ijvcms/chuanqi_dev/7742184bded15f25be761c4f2d78834249d78097/server/trunk/server/src/business/scene/scene_npc_lib.erl | erlang | -------------------------------------------------------------------
@author tuhujia
@doc 场景npc
@end
-------------------------------------------------------------------
API
callbacks
====================================================================
API functions
==============================================... | ( C ) 2016 , < COMPANY >
Created : 05 . 一月 2016 10:01
-module(scene_npc_lib).
-include("common.hrl").
-include("record.hrl").
-include("proto.hrl").
-include("cache.hrl").
-include("db_record.hrl").
-include("uid.hrl").
-include("config.hrl").
-include("language_config.hrl").
-include("gameconfig_config.hrl").
-... |
834cb12991a1ec27715d3d19c09d9874f6a940a4e8c95bd6d1417705aa96e410 | sol/reserve | Options.hs | module Options (
Options (..)
, Port
, withOptions
, parseOptions
, defaultOptions
-- exported to silence warnings
, Arg (..)
) where
import Data.Maybe
import Data.List
import Text.Read
import System.Console.GetOpt
import System.Environment
import System.I... | null | https://raw.githubusercontent.com/sol/reserve/9a42242b3579134bc69eb71c0da007e429f5de11/src/Options.hs | haskell | exported to silence warnings | module Options (
Options (..)
, Port
, withOptions
, parseOptions
, defaultOptions
, Arg (..)
) where
import Data.Maybe
import Data.List
import Text.Read
import System.Console.GetOpt
import System.Environment
import System.IO
import System.Exit
... |
52b2b5b3687aef4f78aa0876e8d9309e193dac9a88e76b5518a1c62371fa12df | openmusic-project/openmusic | load-lw-lisp-tools.lisp | ;;===========================================================================
LW Lisp Tools
Lisp programming tools for LispWorks delivered applications
;;===========================================================================
;===========================================================================
; Th... | null | https://raw.githubusercontent.com/openmusic-project/openmusic/9560c064512a1598cd57bcc9f0151c0815178e6f/OPENMUSIC/code/api/om-LW/lw-lisp-tools/load-lw-lisp-tools.lisp | lisp | ===========================================================================
===========================================================================
===========================================================================
This program is free software; you can redistribute it and/or
either version 2
Se... | LW Lisp Tools
Lisp programming tools for LispWorks delivered applications
modify it under the terms of the GNU General Public License
of the License , or ( at your option ) any later version .
You should have received a copy of the GNU General Public License
Foundation , Inc. , 59 Temple Place - Sui... |
1d9c1b6d79d36d4b9fa62fad5a5a0878e0a22b2ed375528af19cd7cc50df0f66 | zyrolasting/racket-vulkan | api-constants.test.rkt | #lang racket/base
(module+ test
(require racket/sequence
rackunit
"./api-constants.rkt")
(test-equal? "(find-extension-constants)"
(find-extension-constants
'(root (extension "\n "
(require (enum ((extends "A") (name "B")))... | null | https://raw.githubusercontent.com/zyrolasting/racket-vulkan/4f743b4b2933173ee4f141e5ae94739895c54b67/private/generate/api-constants.test.rkt | racket | #lang racket/base
(module+ test
(require racket/sequence
rackunit
"./api-constants.rkt")
(test-equal? "(find-extension-constants)"
(find-extension-constants
'(root (extension "\n "
(require (enum ((extends "A") (name "B")))... | |
aa4b5e1498f9c5d98443141c77bedf942525c614dbb9e30aea033110efc2deb6 | bobeff/playground | 015.rkt | Exercise 15 . Define = = > . The function consumes two Boolean values , call them
sunny and friday . Its answer is # true if sunny is false or friday is true .
Note Logicians call this Boolean operation implication , and they use the
notation sunny = > friday for this purpose .
#lang racket
(require rackunit)... | null | https://raw.githubusercontent.com/bobeff/playground/7072dbd7e0acd690749abe1498dd5f247cc21637/htdp-second-edition/exercises/015.rkt | racket | Exercise 15 . Define = = > . The function consumes two Boolean values , call them
sunny and friday . Its answer is # true if sunny is false or friday is true .
Note Logicians call this Boolean operation implication , and they use the
notation sunny = > friday for this purpose .
#lang racket
(require rackunit)... | |
31ace5495195389c471deac4b48b97d8b68df81de035dcc4a3260e95c9ced1d2 | elbrujohalcon/witchcraft | partial.erl | -module(partial).
-export([app/2]).
app(F, Args) ->
{arity, InitialArity} = erlang:fun_info(F, arity),
case length(Args) of
L when L < InitialArity ->
MissingArgs = [{var, 1, N} || N <- lists:seq(1, InitialArity - L)],
ArgList = [case is_function(A) of
false -> erl_parse:abstrac... | null | https://raw.githubusercontent.com/elbrujohalcon/witchcraft/050e91f028a50874347fea9dc552a0e0a056018f/src/partial.erl | erlang | -module(partial).
-export([app/2]).
app(F, Args) ->
{arity, InitialArity} = erlang:fun_info(F, arity),
case length(Args) of
L when L < InitialArity ->
MissingArgs = [{var, 1, N} || N <- lists:seq(1, InitialArity - L)],
ArgList = [case is_function(A) of
false -> erl_parse:abstrac... | |
d606ce51cdc5b0bcd9c1ad21b1790b00e51b542ccb122cefb215bbffc5288455 | flipstone/orville | AutoMigration.hs | {-# LANGUAGE GADTs #-}
module Test.AutoMigration
( autoMigrationTests,
)
where
import qualified Control.Exception.Safe as ExSafe
import qualified Control.Monad.IO.Class as MIO
import qualified Data.ByteString.Char8 as B8
import qualified Data.Foldable as Fold
import qualified Data.Function as Function
import Data... | null | https://raw.githubusercontent.com/flipstone/orville/3e5ad212dfd777690baa4fef29cd103ddff9ec9b/orville-postgresql-libpq/test/Test/AutoMigration.hs | haskell | # LANGUAGE GADTs #
"add column" path
Serial columns are omitted from this list currently because
the are pseudo-types in postgresql, rather than real column types.
We don't handle migrating "away" from them to regular integer type.
time-like and boolean columns are omitted because postgresql raises
an unable-to-... |
module Test.AutoMigration
( autoMigrationTests,
)
where
import qualified Control.Exception.Safe as ExSafe
import qualified Control.Monad.IO.Class as MIO
import qualified Data.ByteString.Char8 as B8
import qualified Data.Foldable as Fold
import qualified Data.Function as Function
import Data.Int (Int32)
import Dat... |
455cf0fb53f4269475ca14a13cf4b6b17cc68f95e9a3d4bea2db0eeb587e464b | jaredly/belt | belt_Id.ml |
Copyright ( C ) 2017 Authors of BuckleScript
*
* This program is free software : you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation , either version 3 of the License , or
* ( at your option ) any later vers... | null | https://raw.githubusercontent.com/jaredly/belt/4d07f859403fdbd3fbfc5a9547c6066d657a2131/belt_src/belt_Id.ml | ocaml | see #r173330825 |
Copyright ( C ) 2017 Authors of BuckleScript
*
* This program is free software : you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation , either version 3 of the License , or
* ( at your option ) any later vers... |
a59681ce6b7f6598c249d6a3be6bce83d2ca83f9f97324c371fd5a987ad0acf9 | haskell/statistics | Simple.hs | # LANGUAGE DeriveDataTypeable , DeriveGeneric , FlexibleContexts #
-- |
-- Module : Statistics.Sample.KernelDensity.Simple
Copyright : ( c ) 2009
-- License : BSD3
--
-- Maintainer :
-- Stability : experimental
-- Portability : portable
--
-- Kernel density estimation code, providing non-parametric ways to... | null | https://raw.githubusercontent.com/haskell/statistics/a2aa25181e50cd63db4a785c20c973a3c4dd5dac/Statistics/Sample/KernelDensity/Simple.hs | haskell | |
Module : Statistics.Sample.KernelDensity.Simple
License : BSD3
Maintainer :
Stability : experimental
Portability : portable
Kernel density estimation code, providing non-parametric ways to
estimate the probability density function of a sample.
The techniques used by functions in this module are r... | # LANGUAGE DeriveDataTypeable , DeriveGeneric , FlexibleContexts #
Copyright : ( c ) 2009
module Statistics.Sample.KernelDensity.Simple
(
epanechnikovPDF
, gaussianPDF
, Points(..)
, choosePoints
, Bandwidth
, bandwidth
, epanechnikovBW
, gaussianBW
, Kernel
, epanech... |
95f3127e5615b0b61d864c1bd28adaf4a83156891c146918f5a7bf5162b8a09d | lexi-lambda/eff | Strict.hs | module Control.Effect.State.Strict
( module Control.Effect.State
, runState
, evalState
, execState
) where
import Control.Effect.Base
import Control.Effect.State
import Control.Effect.Internal (evalState)
import Data.Tuple (swap)
-- | Handles a @'State'@ effect using a strict cell of mutable state—each use... | null | https://raw.githubusercontent.com/lexi-lambda/eff/8c4df4bf54faf22456354be18095b14825be5e85/eff/src/Control/Effect/State/Strict.hs | haskell | | Handles a @'State'@ effect using a strict cell of mutable state—each use
of 'put' or 'modify' eagerly forces the new value. The state is initialized
to the given value, and the final state is returned alongside the
computation’s result. | module Control.Effect.State.Strict
( module Control.Effect.State
, runState
, evalState
, execState
) where
import Control.Effect.Base
import Control.Effect.State
import Control.Effect.Internal (evalState)
import Data.Tuple (swap)
runState :: s -> Eff (State s ': effs) a -> Eff effs (s, a)
runState s m = ev... |
7c7aa5689ce47785a2c1620c151e9b7da84a959b2a00a972f1db7d5f0b7e211f | gafiatulin/codewars | Numbers 4.hs | Beginner Series # 5 Triangular Numbers
-- /
module Codewars.Numbers where
import Control.Arrow ((&&&))
isTriangular :: Int -> Bool
isTriangular = uncurry (==) . (id &&& (^2) . round . sqrt . fromIntegral) . succ . (*8)
| null | https://raw.githubusercontent.com/gafiatulin/codewars/535db608333e854be93ecfc165686a2162264fef/src/7%20kyu/Numbers%204.hs | haskell | / | Beginner Series # 5 Triangular Numbers
module Codewars.Numbers where
import Control.Arrow ((&&&))
isTriangular :: Int -> Bool
isTriangular = uncurry (==) . (id &&& (^2) . round . sqrt . fromIntegral) . succ . (*8)
|
d6c03bc63b338e308015a5990f3cc88b8f2a97bbef74a5495ad77f7652cf3ab1 | cirodrig/triolet | Classes.hs | {- | Constraint manipulation is performed in this module.
-}
# LANGUAGE FlexibleContexts , TypeFamilies , ConstraintKinds , RankNTypes ,
UndecidableInstances #
UndecidableInstances #-}
module Untyped.Classes
(isInstancePredicate, isEqualityPredicate,
reduceTypeFunction,
... | null | https://raw.githubusercontent.com/cirodrig/triolet/e515a1dc0d6b3e546320eac7b71fb36cea5b53d0/src/program/Untyped/Classes.hs | haskell | | Constraint manipulation is performed in this module.
| Flag turns on debugging dumps during context reduction
-----------------------------------------------------------------------------
Context reduction environments
| A proof construction environment for constructing proofs of predicates.
@d@ in monad @m@... |
# LANGUAGE FlexibleContexts , TypeFamilies , ConstraintKinds , RankNTypes ,
UndecidableInstances #
UndecidableInstances #-}
module Untyped.Classes
(isInstancePredicate, isEqualityPredicate,
reduceTypeFunction,
Derivation(..),
toHnf,
dependentT... |
0b8cffc119590d6ad67542332cfb21a440d0d116e45d73fdd304798dec005937 | sebfisch/haskell-regexp | Matching.hs | # LANGUAGE MultiParamTypeClasses , FlexibleContexts #
module Text.RegExp.Matching where
import Data.Semiring
import Text.RegExp.Data
import Text.RegExp.Matching.Leftmost.Type
import Text.RegExp.Matching.Longest.Type
import Text.RegExp.Matching.LeftLong.Type
-- |
-- Checks whether a regular expression matches the gi... | null | https://raw.githubusercontent.com/sebfisch/haskell-regexp/3acc5087c296860460f01ea74aa9725644299b13/src/Text/RegExp/Matching.hs | haskell | |
Checks whether a regular expression matches the given word. For
@\"b\"@.
|
Checks whether a regular expression matches a subword of the given
|
Computes in how many ways a word can be matched against a regular
expression.
# SPECIALIZE matchingCount :: RegExp c -> [c] -> Int #
|
Matches a regular expre... | # LANGUAGE MultiParamTypeClasses , FlexibleContexts #
module Text.RegExp.Matching where
import Data.Semiring
import Text.RegExp.Data
import Text.RegExp.Matching.Leftmost.Type
import Text.RegExp.Matching.Longest.Type
import Text.RegExp.Matching.LeftLong.Type
example , @acceptFull ( fromString \"b|abc\ " ) \"b\"@ y... |
be01e3ae331fa6d7188283ac3a103e2dae36da40086d8cb91bf88c4536ef978e | gilith/hol-light | hardware-counter.ml | (* ========================================================================= *)
HARDWARE COUNTER DEVICES
(* ========================================================================= *)
(* --------------... | null | https://raw.githubusercontent.com/gilith/hol-light/f3f131963f2298b4d65ee5fead6e986a4a14237a/opentheory/theories/hardware/hardware-counter.ml | ocaml | =========================================================================
=========================================================================
-------------------------------------------------------------------------
Definition of hardware counter devices.
---------------... | HARDWARE COUNTER DEVICES
export_theory "hardware-counter-def";;
let bpipe_def = new_definition
`!w x.
bpipe w x <=>
?r xp x0 x1 x2.
width x = r + 1 /\
width xp = r
/\
... |
02817cb1cae8c900d50e2b8f107b42d46b5dd9be6b3368f70c0160ffc3e3c97b | rlipscombe/topcat | topcat_error_logger.erl | -module(topcat_error_logger).
-export([report/1]).
-include("topcat_colored.hrl").
-export([format_reason/1]).
report(Event) ->
try
report_event(Event)
catch
Cl:Ex ->
io:format(?red("INTERNAL FAILURE: Exception ~p:~p while reporting event.\n"), [Cl, Ex]),
error_logger_u... | null | https://raw.githubusercontent.com/rlipscombe/topcat/2be8c8fdf7582ad3d83d582990b298751062bd75/src/topcat_error_logger.erl | erlang | Ignore progress reports; too many of them absolutely kills performance.
They're filtered in the slave, but it doesn't hurt to drop them here as well.
line numbers
@doc The rest of this is borrowed from lager's
this kind of weird stacktrace can be generated by a uncaught throw in a gen_server
this kind of weird st... | -module(topcat_error_logger).
-export([report/1]).
-include("topcat_colored.hrl").
-export([format_reason/1]).
report(Event) ->
try
report_event(Event)
catch
Cl:Ex ->
io:format(?red("INTERNAL FAILURE: Exception ~p:~p while reporting event.\n"), [Cl, Ex]),
error_logger_u... |
4a146d1da1dcea0da877a25984f7aafddfcc719a755f1a9d69100c357a3039ed | ghc/nofib | Patchlevel.hs |
- ( The Solid Modeller , written in Haskell )
-
- Copyright 1990,1991,1992,1993 Duncan Sinclair
-
- Permissiom to use , copy , modify , and distribute this software for any
- purpose and without fee is hereby granted , provided that the above
- copyright notice and this permission notice appea... | null | https://raw.githubusercontent.com/ghc/nofib/f34b90b5a6ce46284693119a06d1133908b11856/gc/fulsom/Patchlevel.hs | haskell | hbc requires that I type these, else I get: "Bad overloading in exports" |
- ( The Solid Modeller , written in Haskell )
-
- Copyright 1990,1991,1992,1993 Duncan Sinclair
-
- Permissiom to use , copy , modify , and distribute this software for any
- purpose and without fee is hereby granted , provided that the above
- copyright notice and this permission notice appea... |
088e99b176dae7c8dc826649bad02beea716832851a7af6bc3305494efebc42a | propan/geheimtur | credentials_test.clj | (ns geheimtur.util.credentials-test
(:require [clojure.test :refer :all ]
[geheimtur.util.credentials :refer :all ]))
(deftest pbkdf2-hashing
(are [res hash] (= res (pbkdf2-verify "password" hash))
true (pbkdf2-hash "password")
true (pbkdf2-hash "password" :iterations 5000)
true (pbkdf2-has... | null | https://raw.githubusercontent.com/propan/geheimtur/bae0b1f69182289a92813ddc42db0604e53c99af/test/geheimtur/util/credentials_test.clj | clojure | (ns geheimtur.util.credentials-test
(:require [clojure.test :refer :all ]
[geheimtur.util.credentials :refer :all ]))
(deftest pbkdf2-hashing
(are [res hash] (= res (pbkdf2-verify "password" hash))
true (pbkdf2-hash "password")
true (pbkdf2-hash "password" :iterations 5000)
true (pbkdf2-has... | |
162397c6cf547be29f6792ceab47364a8a615be26c582c5c6e880da38dbda471 | Plutonomicon/plutarch-core | Helpers.hs | # LANGUAGE FlexibleInstances #
# LANGUAGE UndecidableInstances #
# LANGUAGE UndecidableSuperClasses #
{-# OPTIONS_GHC -Wno-unused-foralls #-}
module Plutarch.Helpers (
IsPType1,
IsPType2,
IsPType3,
PConstructable1,
PConstructable2,
PConstructable3,
plet,
pbind,
(#),
plam,
T,
pany,
type ($),
... | null | https://raw.githubusercontent.com/Plutonomicon/plutarch-core/6befe9f205fd3a9f1b6697f09e7162331029dde0/Plutarch/Helpers.hs | haskell | # OPTIONS_GHC -Wno-unused-foralls #
change the type of `pforall` too.
TODO: fix asymptotics, below is O(n^2) for n variables
This would mean you can prove `Any @() ~ '()`. While it seems bad, I'm unconvinced
it has any practical detriments.
# OVERLAPPABLE # | # LANGUAGE FlexibleInstances #
# LANGUAGE UndecidableInstances #
# LANGUAGE UndecidableSuperClasses #
module Plutarch.Helpers (
IsPType1,
IsPType2,
IsPType3,
PConstructable1,
PConstructable2,
PConstructable3,
plet,
pbind,
(#),
plam,
T,
pany,
type ($),
($$),
PForall (..),
PForallClass,
... |
bfb140f5ccd4f124a9cbdca35bf1c65bcbc31a962591f63804c0272266772d68 | TrustInSoft/tis-interpreter | variables_analysis.ml | Modified by TrustInSoft
(**************************************************************************)
(* *)
This file is part of WP plug - in of Frama - C.
(* ... | null | https://raw.githubusercontent.com/TrustInSoft/tis-interpreter/33132ce4a825494ea48bf2dd6fd03a56b62cc5c3/src/plugins/wp/variables_analysis.ml | ocaml | ************************************************************************
alternatives)
... | Modified by TrustInSoft
This file is part of WP plug - in of Frama - C.
Copyright ( C ) 2007 - 2015
CEA ( Commissariat a l'energie atomique et aux energies
Lesser General Public License as published by the Free Soft... |
19db89c4dde16741663f046974228747331eee6f5d96c457f4a5eb4e6bfaae2b | restyled-io/restyler | DelimitedSpec.hs | module Restyler.DelimitedSpec
( spec
) where
import SpecHelper
import qualified Data.Text as T
import Restyler.Delimited
spec :: Spec
spec = withTestApp $ do
describe "restyleDelimited" $ do
it "restyles delimited content" $ testAppExample $ do
writeFile "foo.rb" $ T.unlines
... | null | https://raw.githubusercontent.com/restyled-io/restyler/3da7d1cb62ec078c03794d4a2c5fbeb5c26fd005/test/Restyler/DelimitedSpec.hs | haskell | module Restyler.DelimitedSpec
( spec
) where
import SpecHelper
import qualified Data.Text as T
import Restyler.Delimited
spec :: Spec
spec = withTestApp $ do
describe "restyleDelimited" $ do
it "restyles delimited content" $ testAppExample $ do
writeFile "foo.rb" $ T.unlines
... | |
213bbfb55930cff44e25c0d04467c27fb91a2a9b99bb0eb98bdebc3c7579c751 | realworldocaml/book | ppx_typerep_conv.ml | open Base
open Ppxlib
open Ast_builder.Default
let ( @@ ) a b = a b
module Gen = struct
let let_in loc list_lid_expr body =
List.fold_right list_lid_expr ~init:body ~f:(fun (lid, expr) body ->
[%expr let [%p pvar ~loc lid] = [%e expr] in [%e body] ])
end
module Field_case = struct
type t =
{ label... | null | https://raw.githubusercontent.com/realworldocaml/book/d822fd065f19dbb6324bf83e0143bc73fd77dbf9/duniverse/ppx_typerep_conv/src/ppx_typerep_conv.ml | ocaml | The value must be a float else this segfaults. This is tested by the
unit tests in case this property changes.
Calling [get] on the fields from left to right matters, so that iteration
goes left to right too.
Add type annotations to parameters, at least to avoid the unused type warning... | open Base
open Ppxlib
open Ast_builder.Default
let ( @@ ) a b = a b
module Gen = struct
let let_in loc list_lid_expr body =
List.fold_right list_lid_expr ~init:body ~f:(fun (lid, expr) body ->
[%expr let [%p pvar ~loc lid] = [%e expr] in [%e body] ])
end
module Field_case = struct
type t =
{ label... |
10a4283778abd721bee4263055aae19139c343eb9ff9e8fdb5b4c85e4dbc83ef | generateme/fastmath | x.clj | (ns fastmath.fields.x
(:require [fastmath.core :as m]
[fastmath.vector :as v]
[fastmath.random :as r]
[fastmath.fields.utils :as u])
(:import [fastmath.vector Vec2]))
(set! *unchecked-math* :warn-on-boxed)
(m/use-primitive-operators)
(defn x
([] {:type :regular
:config... | null | https://raw.githubusercontent.com/generateme/fastmath/820d9e5c432441465d5d6576d4a583677a3bd84f/src/fastmath/fields/x.clj | clojure | (ns fastmath.fields.x
(:require [fastmath.core :as m]
[fastmath.vector :as v]
[fastmath.random :as r]
[fastmath.fields.utils :as u])
(:import [fastmath.vector Vec2]))
(set! *unchecked-math* :warn-on-boxed)
(m/use-primitive-operators)
(defn x
([] {:type :regular
:config... | |
cbcf86ae22a9e78f206c68d1b84fdab99283d7e107cc3266f0719df0f8d0c9da | ekmett/ekmett.github.com | Ideal.hs | {-# OPTIONS_GHC -fglasgow-exts #-}
-----------------------------------------------------------------------------
-- |
Module : Control . Monad . Ideal
Copyright : ( C ) 2008
-- License : BSD-style (see the file LICENSE)
--
Maintainer : < >
-- Stability : experimental
-- Portability :... | null | https://raw.githubusercontent.com/ekmett/ekmett.github.com/8d3abab5b66db631e148e1d046d18909bece5893/haskell/category-extras-backup/src/Control/Monad/Ideal.hs | haskell | # OPTIONS_GHC -fglasgow-exts #
---------------------------------------------------------------------------
|
License : BSD-style (see the file LICENSE)
Stability : experimental
Portability : portable
--------------------------------------------------------------------------
* Ideal Monads
* Coideal Com... | Module : Control . Monad . Ideal
Copyright : ( C ) 2008
Maintainer : < >
module Control.Monad.Ideal
(
MonadIdeal(..)
, Ideal
, ideal
, destroyIdeal
, ComonadCoideal(..)
, Coideal
, coideal
, buildCoideal
, Mutual(..)
, (:*)
* Ideal
, (:+)
) where
import Prelude hiding (f... |
ae61cbf8986b3315b86af57f761ecd143c818235191d01f44ae90cf1b0fa39f0 | gregtatcam/imaplet-lwt | smtplet_relay.mli |
* Copyright ( c ) 2013 - 2014 < >
*
* Permission to use , copy , modify , and distribute this software for any
* purpose with or without fee is hereby granted , provided that the above
* copyright notice and this permission notice appear in all copies .
*
* THE SOFTWARE IS PROVIDED " AS IS " AND... | null | https://raw.githubusercontent.com/gregtatcam/imaplet-lwt/d7b51253e79cffa97e98ab899ed833cd7cb44bb6/servers/smtplet_relay.mli | ocaml |
* Copyright ( c ) 2013 - 2014 < >
*
* Permission to use , copy , modify , and distribute this software for any
* purpose with or without fee is hereby granted , provided that the above
* copyright notice and this permission notice appear in all copies .
*
* THE SOFTWARE IS PROVIDED " AS IS " AND... | |
24641a7c0683cc229dcfdd92cc515b3b49f68a14d1ac4b63804c2ffd737f7c0f | CompSciCabal/SMRTYPRTY | main.rkt | #lang racket/base
(require "mk.rkt")
(provide (all-from-out "mk.rkt")
quote quasiquote unquote
define
#%datum
#%app
let)
| null | https://raw.githubusercontent.com/CompSciCabal/SMRTYPRTY/4a5550789c997c20fb7256b81469de1f1fce3514/paip/will/faster-miniKanren/main.rkt | racket | #lang racket/base
(require "mk.rkt")
(provide (all-from-out "mk.rkt")
quote quasiquote unquote
define
#%datum
#%app
let)
| |
f2679e2de146446f5994d072be5124c43b9c5e8e56958447cacae52e09e877ab | thosmos/riverdb | safetoswim.clj | (ns riverdb.safetoswim
(:require
[clojure.tools.logging :as log :refer [debug info warn error]]
[datomic.api :as d]
[riverdb.db :refer [remap-query limit-fn]]
[riverdb.state :refer [db cx]]
[java-time :as jt]))
| null | https://raw.githubusercontent.com/thosmos/riverdb/db4567b7eb957d9ee668525c8f48133421dd53e2/src/server/riverdb/safetoswim.clj | clojure | (ns riverdb.safetoswim
(:require
[clojure.tools.logging :as log :refer [debug info warn error]]
[datomic.api :as d]
[riverdb.db :refer [remap-query limit-fn]]
[riverdb.state :refer [db cx]]
[java-time :as jt]))
| |
5a77326271a656689933fd1cf2c45a9c97f3da5ff494edbbdd9d122e35dd4903 | chyanju/__archived__Medjai | program.rkt | #lang rosette
; this module stores all program related components, including:
; |- Program
(require json
(prefix-in tokamak: "./tokamak.rkt")
)
(provide (all-defined-out))
; ================================= ;
; ======== helping structs ======== ;
; ================================= ;
; (ScopeName)
; (CairoHint)... | null | https://raw.githubusercontent.com/chyanju/__archived__Medjai/d961b9954d20dd540be385a85d2fe843207ca567/medjai/program.rkt | racket | this module stores all program related components, including:
|- Program
================================= ;
======== helping structs ======== ;
================================= ;
(ScopeName)
(CairoHint)
========================= ;
======== Program ======== ;
========================= ;
int
list[int]
li... | #lang rosette
(require json
(prefix-in tokamak: "./tokamak.rkt")
)
(provide (all-defined-out))
( ProgramBase ) - > ( Program )
(struct program (
ProgramBase
Program
( fixme ) ( reference_manager ) ReferenceManager
( fixme ) ( debug_info ) DebugInfo or null
) #:mutable #:transparent #:reflection-name 'p... |
0bb970546cb63a38b8da3b1ec73918b5a31437faf113baf8f72f668a9fc4fa4a | emqx/emqx | emqx_cm_proto_v1.erl | %%--------------------------------------------------------------------
Copyright ( c ) 2022 - 2023 EMQ Technologies Co. , Ltd. All Rights Reserved .
%%
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
%% you may not use this file except in compliance with the License.
%% You may obtain a copy o... | null | https://raw.githubusercontent.com/emqx/emqx/dbc10c2eed3df314586c7b9ac6292083204f1f68/apps/emqx/src/proto/emqx_cm_proto_v1.erl | erlang | --------------------------------------------------------------------
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
-2.0
Unless required by applicable law or agreed to in writing, software
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express ... | Copyright ( c ) 2022 - 2023 EMQ Technologies Co. , Ltd. All Rights Reserved .
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
distributed under the License is distributed on an " AS IS " BASIS ,
-module(emqx_cm_proto_v1).
-behaviour(emqx_bpapi).
-export([
introduced_in/0,
lookup_... |
f70daf82a5d8e03460daec5136fc36f4798f2f658d23c9413c1bfc9a8fc09ec0 | malcolmreynolds/GSLL | operations.lisp | ;; Histogram operations
, Mon Jan 1 2007 - 16:47
Time - stamp : < 2009 - 01 - 04 11:15:17EST operations.lisp >
$ Id$
(in-package :gsl)
(export 'equal-bins-p)
(defgeneric equal-bins-p (histogram1 histogram2)
"Are all of the individual bin ranges of the two histograms are identical?"))
(defmfun equal-b... | null | https://raw.githubusercontent.com/malcolmreynolds/GSLL/2f722f12f1d08e1b9550a46e2a22adba8e1e52c4/histogram/operations.lisp | lisp | Histogram operations
C function means; assumed to be error code.
C function means; assumed to be error code.
C function means; assumed to be error code.
C function means; assumed to be error code.
C function means; assumed to be error code.
C function means; assumed to be error code.
C function means; assumed t... | , Mon Jan 1 2007 - 16:47
Time - stamp : < 2009 - 01 - 04 11:15:17EST operations.lisp >
$ Id$
(in-package :gsl)
(export 'equal-bins-p)
(defgeneric equal-bins-p (histogram1 histogram2)
"Are all of the individual bin ranges of the two histograms are identical?"))
(defmfun equal-bins-p ((histogram1 histo... |
5d43cae92e065cb36bae4b4ff6bf8150b578c618702027ba8d13cb6038539e2c | pqwy/notty | rain.ml |
let () = Random.self_init ()
let rec (--) a b = if a > b then [] else a :: succ a -- b
let utf8_of_code_point =
let buf = Buffer.create 7 in fun cp ->
Buffer.clear buf;
Uutf.Buffer.add_utf_8 buf (Uchar.of_int cp);
Buffer.contents buf
let nsym = 4096
let glitch = nsym / 20
let symbols = Array.(concat [... | null | https://raw.githubusercontent.com/pqwy/notty/389366c023396017aa21efcdbb07ade5ba0974c5/examples/rain.ml | ocaml |
let () = Random.self_init ()
let rec (--) a b = if a > b then [] else a :: succ a -- b
let utf8_of_code_point =
let buf = Buffer.create 7 in fun cp ->
Buffer.clear buf;
Uutf.Buffer.add_utf_8 buf (Uchar.of_int cp);
Buffer.contents buf
let nsym = 4096
let glitch = nsym / 20
let symbols = Array.(concat [... | |
2f530f999aad9a1b21cb85499f6cf49949ebbc32f035542ca9ba3cc0cfb2d703 | gadfly361/rid3 | basics.cljs | (ns rid3.basics
(:require
[cljs.spec :as spec]
[reagent.core :as reagent]
[re-frisk.core :as rf]
[rid3.b01-make-elem :as b01-make-elem]
[rid3.b02-add-attrs-to-elem :as b02-add-attrs-to-elem]
[rid3.b03-add-element-on-top :as b03-add-element-on-top]
[rid3.b04-make-elements-from-data :as b04-make-e... | null | https://raw.githubusercontent.com/gadfly361/rid3/cae79fdbee3b5aba45e29b589425f9a17ef8613b/src/basics/rid3/basics.cljs | clojure |
Page
| (ns rid3.basics
(:require
[cljs.spec :as spec]
[reagent.core :as reagent]
[re-frisk.core :as rf]
[rid3.b01-make-elem :as b01-make-elem]
[rid3.b02-add-attrs-to-elem :as b02-add-attrs-to-elem]
[rid3.b03-add-element-on-top :as b03-add-element-on-top]
[rid3.b04-make-elements-from-data :as b04-make-e... |
765a00f9d6c4603d0cd2facf4e9ca85f1c4321887b9b20929a1123fb3f5d243f | lipas-liikuntapaikat/lipas | generated.cljc | (ns lipas.i18n.generated)
From csv ; ;
(def dicts
{:fi
{:newsletter
{:subscribe-short "Tilaa"
:subscribe "Tilaa uutiskirje"
:subscription-failed "Uutiskirjeen tilaus epäonnistui. Yritä uudelleen."
:subscription-success "Uutiskirje tilattu!"}
:analysis
{:headline ... | null | https://raw.githubusercontent.com/lipas-liikuntapaikat/lipas/30d9fff82bdc0ebf9805294e7383cbdfcefcc05c/webapp/src/cljc/lipas/i18n/generated.cljc | clojure | ; | (ns lipas.i18n.generated)
(def dicts
{:fi
{:newsletter
{:subscribe-short "Tilaa"
:subscribe "Tilaa uutiskirje"
:subscription-failed "Uutiskirjeen tilaus epäonnistui. Yritä uudelleen."
:subscription-success "Uutiskirje tilattu!"}
:analysis
{:headline "... |
7d1f51f964717cf3cec1055caa1be603c7bca402152156eb68a767e0d98037d0 | zachsully/dl | Intercompilation.hs | module DL.Core.Intercompilation
( visitor
, tabulate
) where
import DL.Core.Data.Syntax
import DL.Core.Codata.Syntax
import DL.Utils.StdMonad
--------------------------------------------------------------------------------
-- Visitor --
--------... | null | https://raw.githubusercontent.com/zachsully/dl/c99cdfa8a3b59b1977a34876f397c467518091b6/haskell/DL/Core/Intercompilation.hs | haskell | ------------------------------------------------------------------------------
Visitor --
------------------------------------------------------------------------------
^ positive cases
^ negative cases
-----------------------------------------------... | module DL.Core.Intercompilation
( visitor
, tabulate
) where
import DL.Core.Data.Syntax
import DL.Core.Codata.Syntax
import DL.Utils.StdMonad
visitor :: LData -> Std LCodata
visitor (DLet v a b) = CLet v <$> visitor a <*> visitor b
visitor (DFix v a) = CFix v <$> visitor a
visitor (DVar v) = pure (C... |
f2a372589d8c01ebc0c814e08c77a11cb07d382ceb53680a70f639bed957d713 | parsonsmatt/annotated-exception | Annotated.hs | # LANGUAGE DeriveFoldable #
# LANGUAGE DeriveFunctor #
{-# LANGUAGE DeriveTraversable #-}
# LANGUAGE FlexibleContexts #
# LANGUAGE FlexibleInstances #
{-# LANGUAGE GADTs #-}
# LANGUAGE InstanceSigs #
# LANGUAGE MultiParamTypeClasses #
{-# LANGUAGE RankNTypes #-}
# LANGUAGE ScopedTypeVariables #
# LANGUAGE StandaloneDer... | null | https://raw.githubusercontent.com/parsonsmatt/annotated-exception/ff59f70e6648b88cfe3d520d019f0f21c712fe78/src/Control/Exception/Annotated.hs | haskell | # LANGUAGE DeriveTraversable #
# LANGUAGE GADTs #
# LANGUAGE RankNTypes #
| This module defines an exception wrapper 'AnnotatedException' that
carries a list of 'Annotation's, along with some helper methods for
throwing and catching that can make the annotations transparent.
While this library can be used directly... | # LANGUAGE DeriveFoldable #
# LANGUAGE DeriveFunctor #
# LANGUAGE FlexibleContexts #
# LANGUAGE FlexibleInstances #
# LANGUAGE InstanceSigs #
# LANGUAGE MultiParamTypeClasses #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE StandaloneDeriving #
# LANGUAGE TypeApplications #
module Control.Exception.Annotated
Annota... |
df2e58386445984c14d84a9179dc2c8b709a4cade11a0d6bcb03c452adfcd846 | NoRedInk/jetpack | Comment.hs | {-| Parser for line and block comments in js or coffeescript.
imports for doctests
>>> import qualified Data.Text as T
-}
module Parser.Comment
( eatJsComments
, eatCoffeeComments
, eatElmComments
)
where
import Data.Functor (void)
import qualified Data.List as L
import qualified Data.Text as T
import Tex... | null | https://raw.githubusercontent.com/NoRedInk/jetpack/721d12226b593c117cba26ceb7c463c7c3334b8b/src/Parser/Comment.hs | haskell | | Parser for line and block comments in js or coffeescript.
imports for doctests
>>> import qualified Data.Text as T
| Removes block and line comments from text.
>>> :{
eatElmComments $
T.unlines
[ "import Page.Foo.Bar"
, "-- import Maybe.Extra"
, "type Msg = NoOp"
, ... | module Parser.Comment
( eatJsComments
, eatCoffeeComments
, eatElmComments
)
where
import Data.Functor (void)
import qualified Data.List as L
import qualified Data.Text as T
import Text.Parsec
, "foo = 42"
]
:}
"import Page.Foo.Bar\ntype Msg = NoOp\n\nfoo = 42\n"
-}
eatElmComments :: T... |
d6453b04e1742f031f3a3de9169f7f539b8443068267837944f7e7382837db24 | simonmar/parconc-examples | geturls1.hs | < <
import Control.Concurrent
import Data.ByteString as B
import GetURL
main = do
< 1 >
< 1 >
< 2 >
r <- getURL ""
putMVar m1 r
forkIO $ do -- <3>
r <- getURL ""
putMVar m2 r
< 4 >
< 5 >
< 6 >
-- >>
| null | https://raw.githubusercontent.com/simonmar/parconc-examples/840a3f508f9bb6e03961e1b90311a1edd945adba/geturls1.hs | haskell | <3>
>> | < <
import Control.Concurrent
import Data.ByteString as B
import GetURL
main = do
< 1 >
< 1 >
< 2 >
r <- getURL ""
putMVar m1 r
r <- getURL ""
putMVar m2 r
< 4 >
< 5 >
< 6 >
|
0f31732f3287ef1b4ce3c1148e3990ac89c5261a5903e22e1ea0d40a38a9f709 | r-willis/biten | chain.erl | %%% ---------------------------------------------------------------------------
%%% Blockchain service
%%% ---------------------------------------------------------------------------
-module(chain).
-behaviour(gen_server).
%% API fucntions
-export([start_link/0, get_stats/0, get_chain/1, got_inv/2, got_headers/1, go... | null | https://raw.githubusercontent.com/r-willis/biten/75b13ea296992f8fa749646b9d7c15c5ef23d94d/apps/biten/src/chain.erl | erlang | ---------------------------------------------------------------------------
Blockchain service
---------------------------------------------------------------------------
API fucntions
gen_server callbacks
Use module name for registered process
====================================================================... |
-module(chain).
-behaviour(gen_server).
-export([start_link/0, get_stats/0, get_chain/1, got_inv/2, got_headers/1, got_getdata/1, stop/0]).
-export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]).
-include("include/config.hrl").
-define(SERVER, ?MODULE).
start_link() ->
ge... |
82a5f370a7039dbf7d00b2de59e197ea6cb8ba84b8c8d9e973f7d718ff07ed7e | LaurentMazare/ocaml-jupyter-async | worker.ml | open! Core
(* The worker part does not use async, only import it locally for the parent
process. *)
let worker_buf_len = 4096
type worker_input =
| Execute of { code : string }
| Complete of { code : string }
[@@deriving bin_io]
type worker_output =
| Execute_output of unit Or_error.t
| Complete_output ... | null | https://raw.githubusercontent.com/LaurentMazare/ocaml-jupyter-async/c7a4e237c108ffa8be9ccfe560ff4758ff6bf74c/src/kernel/worker.ml | ocaml | The worker part does not use async, only import it locally for the parent
process.
This has to be called before starting the async scheduler. | open! Core
let worker_buf_len = 4096
type worker_input =
| Execute of { code : string }
| Complete of { code : string }
[@@deriving bin_io]
type worker_output =
| Execute_output of unit Or_error.t
| Complete_output of (int * (string * string) list)
[@@deriving bin_io]
type display_data_output = Jupyter_asy... |
498ba516aaeb147a9f0e3045ca53a2e84e0afa06866fecda27d9192bec20b7b3 | int-index/ether | T7.hs | module Regression.T7 (test7) where
import Data.Monoid
import Control.Monad
import Ether
import qualified Control.Monad.Writer as T
import Test.Tasty
import Test.Tasty.QuickCheck
data WTag
testEther
:: Num a
=> T.MonadWriter (Sum a) m
=> MonadWriter WTag (Sum a) m
=> [a] -> m ()
testEther xs = do
forM_ xs... | null | https://raw.githubusercontent.com/int-index/ether/84c1d560da241c8111d1a3c98d9a896f0c62087b/test/Regression/T7.hs | haskell | module Regression.T7 (test7) where
import Data.Monoid
import Control.Monad
import Ether
import qualified Control.Monad.Writer as T
import Test.Tasty
import Test.Tasty.QuickCheck
data WTag
testEther
:: Num a
=> T.MonadWriter (Sum a) m
=> MonadWriter WTag (Sum a) m
=> [a] -> m ()
testEther xs = do
forM_ xs... | |
aac0b69defa08ebd003a00c55201f2ed35e71f960d16fe369e304bbccbe80c97 | cljfx/cljfx | mesh_view.clj | (ns cljfx.fx.mesh-view
"Part of a public API"
(:require [cljfx.composite :as composite]
[cljfx.lifecycle :as lifecycle]
[cljfx.fx.shape3d :as fx.shape3d])
(:import [javafx.scene.shape MeshView]))
(set! *warn-on-reflection* true)
(def props
(merge
fx.shape3d/props
(composite/pro... | null | https://raw.githubusercontent.com/cljfx/cljfx/543f7409290051e9444771d2cd86dadeb8cdce33/src/cljfx/fx/mesh_view.clj | clojure | (ns cljfx.fx.mesh-view
"Part of a public API"
(:require [cljfx.composite :as composite]
[cljfx.lifecycle :as lifecycle]
[cljfx.fx.shape3d :as fx.shape3d])
(:import [javafx.scene.shape MeshView]))
(set! *warn-on-reflection* true)
(def props
(merge
fx.shape3d/props
(composite/pro... | |
16b538cd5c30d00ebc6f1e763275207e1d6ffd9ef3ad4e8ccea39c31076f96af | tokenmill/beagle | annotation.clj | (ns beagle.java.annotation)
(gen-class
:name lt.tokenmill.beagle.phrases.Annotation
:prefix Annotation-
:state "state"
:init "init"
:constructors {[String String Long Long String java.util.Map] []}
:methods [[text [] String]
[type [] String]
[beginOffset [] Long]
[endOff... | null | https://raw.githubusercontent.com/tokenmill/beagle/863ffa63364e9ae7e7a22a3c7e258fd02ace1632/src/beagle/java/annotation.clj | clojure | (ns beagle.java.annotation)
(gen-class
:name lt.tokenmill.beagle.phrases.Annotation
:prefix Annotation-
:state "state"
:init "init"
:constructors {[String String Long Long String java.util.Map] []}
:methods [[text [] String]
[type [] String]
[beginOffset [] Long]
[endOff... | |
1ed5d75a9446b2b42119bb8d09249ac95be26a1cdc8f0b2d015fb5cbce6f3762 | flora-pm/flora-server | Types.hs | # OPTIONS_GHC -Wno - orphans #
module FloraJobs.Types where
import Commonmark qualified
import Control.Exception (Exception)
import Data.Aeson
import Data.Pool hiding (PoolConfig)
import Data.Text qualified as Text
import Data.Text.Encoding.Error (UnicodeException)
import Database.PostgreSQL.Simple (Connection)
impor... | null | https://raw.githubusercontent.com/flora-pm/flora-server/c214c0b5d5db71a8330eb69326284be5a4d5e858/src/jobs-worker/FloraJobs/Types.hs | haskell | # OPTIONS_GHC -Wno - orphans #
module FloraJobs.Types where
import Commonmark qualified
import Control.Exception (Exception)
import Data.Aeson
import Data.Pool hiding (PoolConfig)
import Data.Text qualified as Text
import Data.Text.Encoding.Error (UnicodeException)
import Database.PostgreSQL.Simple (Connection)
impor... | |
c0a62119754302015e774bd2623cf2d97ab5cec077c99539649c31d74e03006a | muattiyah/udp-wrapper | core.clj | (ns udp-wrapper.core
(:import (java.net InetAddress DatagramPacket DatagramSocket)
(java.nio.charset Charset)))
(defn localhost
"Get the InetAddress of the localhost."
[]
(InetAddress/getLocalHost))
(defn make-address
"Make an InetAddress from a string."
[ip]
(InetAddress/getByName ip))
(def... | null | https://raw.githubusercontent.com/muattiyah/udp-wrapper/9c8a23759b6a00621442dda86c39325c2837feb5/src/udp_wrapper/core.clj | clojure | (ns udp-wrapper.core
(:import (java.net InetAddress DatagramPacket DatagramSocket)
(java.nio.charset Charset)))
(defn localhost
"Get the InetAddress of the localhost."
[]
(InetAddress/getLocalHost))
(defn make-address
"Make an InetAddress from a string."
[ip]
(InetAddress/getByName ip))
(def... | |
ce7009f1605e835253b18fce524f0ba49df8ebb9e398ac28b847106ba6dc577f | lerouxrgd/celtuce | bitfield.clj | (ns celtuce.args.bitfield
(:import
(io.lettuce.core
BitFieldArgs
BitFieldArgs$BitFieldType
BitFieldArgs$OverflowType)))
(defn ^BitFieldArgs$BitFieldType bft
"Constructs a BitFieldType from a keyword"
[bft-kw]
(if-let [[_ sign bits] (re-find #"(^[us])(\d+)$" ((fnil name "") bft-kw))]
(case ... | null | https://raw.githubusercontent.com/lerouxrgd/celtuce/c8c501f8fbb00780a7e4218c908b81d5ac06b74a/modules/celtuce-core/src/celtuce/args/bitfield.clj | clojure | (ns celtuce.args.bitfield
(:import
(io.lettuce.core
BitFieldArgs
BitFieldArgs$BitFieldType
BitFieldArgs$OverflowType)))
(defn ^BitFieldArgs$BitFieldType bft
"Constructs a BitFieldType from a keyword"
[bft-kw]
(if-let [[_ sign bits] (re-find #"(^[us])(\d+)$" ((fnil name "") bft-kw))]
(case ... | |
e02fdbd01eda9d73e46b026f92a0eff29b80ad42b9b93c3d52d8ee2ee4e721ab | fare/command-line-arguments | test.lisp | #+xcvb (module (:depends-on ("asdf-encodings" (:asdf "hu.dwim.stefil"))))
(defpackage :command-line-arguments/test
(:use :cl :command-line-arguments :alexandria :hu.dwim.stefil))
(in-package :command-line-arguments/test)
;;; Testing the asdf-encodings library.
(defsuite* (test-suite
:in root-suite
... | null | https://raw.githubusercontent.com/fare/command-line-arguments/5008c4e4cac5dad8f00438c6d335f36bc4fa6747/test.lisp | lisp | Testing the asdf-encodings library. | #+xcvb (module (:depends-on ("asdf-encodings" (:asdf "hu.dwim.stefil"))))
(defpackage :command-line-arguments/test
(:use :cl :command-line-arguments :alexandria :hu.dwim.stefil))
(in-package :command-line-arguments/test)
(defsuite* (test-suite
:in root-suite
:documentation "Testing command... |
208e9ddce2eb9a6b6c874e23c5d9d1eb1da500897e24c2845e4c2090ce493470 | astrada/ocaml-extjs | ext_grid_View.mli | * The grid View class provides extra Ext.grid . Panel ...
{ % < p > The grid View class provides extra < a href="#!/api / Ext.grid . Panel " rel="Ext.grid . Panel " class="docClass">Ext.grid . Panel</a > specific functionality to the
< a href="#!/api / Ext.view . Table " rel="Ext.view . Table " class="docClass... | null | https://raw.githubusercontent.com/astrada/ocaml-extjs/77df630a75fb84667ee953f218c9ce375b3e7484/lib/ext_grid_View.mli | ocaml | * [of_configs c] casts a config object [c] to an instance of class [t]
* [to_configs o] casts instance [o] of class [t] to a config object | * The grid View class provides extra Ext.grid . Panel ...
{ % < p > The grid View class provides extra < a href="#!/api / Ext.grid . Panel " rel="Ext.grid . Panel " class="docClass">Ext.grid . Panel</a > specific functionality to the
< a href="#!/api / Ext.view . Table " rel="Ext.view . Table " class="docClass... |
a6511ccd600f1ce33d6453a48fa8e4c6bafa36a45b757f403dc3cb010cb04e4e | RefactoringTools/HaRe | CExpected.hs | module C where
-- Test for refactor of if to case
-- The comments on the then and else legs should be preserved
foo x = case (odd x) of
True -> -- This is an odd result
bob x 1
False -> -- This is an even result
bob x 2
bob x y = x + y
| null | https://raw.githubusercontent.com/RefactoringTools/HaRe/ef5dee64c38fb104e6e5676095946279fbce381c/test/testdata/Case/CExpected.hs | haskell | Test for refactor of if to case
The comments on the then and else legs should be preserved
This is an odd result
This is an even result | module C where
foo x = case (odd x) of
bob x 1
bob x 2
bob x y = x + y
|
0eb084c2465ed11eabd985022619679dc226dba449a8e0a18cb3ac3a16789c9f | FFPiHaskell/Vorlesung2016 | Main-Static.hs | module Main where
import Parser
import GUI
import Types
import Data.ByteString as BS
import Data.Array
import Data.Time
import Data.Word
import Graphics.Gloss
import Data.Monoid
datafile :: String
datafile = "time_ip.csv"
mainStatic :: IO ()
mainStatic = do
df <- BS.readFile datafile
let pd = hourBuc... | null | https://raw.githubusercontent.com/FFPiHaskell/Vorlesung2016/22e9095cf9fc27b0c04b8f4ca636a72004452376/%C3%9Cbungen/Blatt5-solution/app/Main-Static.hs | haskell | module Main where
import Parser
import GUI
import Types
import Data.ByteString as BS
import Data.Array
import Data.Time
import Data.Word
import Graphics.Gloss
import Data.Monoid
datafile :: String
datafile = "time_ip.csv"
mainStatic :: IO ()
mainStatic = do
df <- BS.readFile datafile
let pd = hourBuc... | |
a15deaf6a7acee322b823bc014ad4f940edf4ef3ee181934edd09c360b87ffa1 | pascal-knodel/haskell-craft | E'12'14.hs | --
--
--
------------------
Exercise 12.14 .
------------------
--
--
--
module E'12'14 where
| null | https://raw.githubusercontent.com/pascal-knodel/haskell-craft/c03d6eb857abd8b4785b6de075b094ec3653c968/_/links/E'12'14.hs | haskell |
----------------
----------------
| Exercise 12.14 .
module E'12'14 where
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.