_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 |
|---|---|---|---|---|---|---|---|---|
ac934b613a742204687a32a0ca9ac4b543643b104da2d247d4dfedcc62b7201e | Helium4Haskell/helium | ShadowNegate.hs | module ShadowNegate where
main :: Int
main = let negate = True in (-1)
| null | https://raw.githubusercontent.com/Helium4Haskell/helium/5928bff479e6f151b4ceb6c69bbc15d71e29eb47/test/runtimeerrors/ShadowNegate.hs | haskell | module ShadowNegate where
main :: Int
main = let negate = True in (-1)
| |
601e5dbd11bf3f810fc26900bad40ab9c61f0a0017364a724d69fa60ac6c855c | wdebeaum/step | social-contract.lisp | Rik -- August 2015
(in-package :om)
;; Working on the social-contract hierarchy,
;; I ended up with `essential-contract` and `nonessential-contract` under
;; `social-imperative`, but also `external/internal-authority` under `governing-principle`.
;; However, it seems that we can do away with those nodes if we intro... | null | https://raw.githubusercontent.com/wdebeaum/step/f38c07d9cd3a58d0e0183159d4445de9a0eafe26/src/OntologyManager/Data/LFdata/social-contract.lisp | lisp | Working on the social-contract hierarchy,
I ended up with `essential-contract` and `nonessential-contract` under
`social-imperative`, but also `external/internal-authority` under `governing-principle`.
However, it seems that we can do away with those nodes if we introduce a feature or
something like `authority-sou... | Rik -- August 2015
(in-package :om)
(define-type ont::social-contract
:arguments ((:OPTIONAL ONT::FIGURE (f::situation)))
:sem (F::abstr-obj (f::spatial-abstraction -))
:parent ont::mental-construction
:wordnet-sense-keys ("social_contract%1:26:00")
)
(define-type ont::social-imperative
:paren... |
9ab56ceabb1224a75b76661e2265ada4698df32331aa9f06a1c7c87d1a707b85 | inhabitedtype/ocaml-aws | describeInstancePatches.ml | open Types
open Aws
type input = DescribeInstancePatchesRequest.t
type output = DescribeInstancePatchesResult.t
type error = Errors_internal.t
let service = "ssm"
let signature_version = Request.V4
let to_http service region req =
let uri =
Uri.add_query_params
(Uri.of_string (Aws.Util.of_option_exn (... | null | https://raw.githubusercontent.com/inhabitedtype/ocaml-aws/3bc554af7ae7ef9e2dcea44a1b72c9e687435fa9/libraries/ssm/lib/describeInstancePatches.ml | ocaml | open Types
open Aws
type input = DescribeInstancePatchesRequest.t
type output = DescribeInstancePatchesResult.t
type error = Errors_internal.t
let service = "ssm"
let signature_version = Request.V4
let to_http service region req =
let uri =
Uri.add_query_params
(Uri.of_string (Aws.Util.of_option_exn (... | |
4a911f0560f43261bca63bc7497a59323ed02133fc6655f7d2dbf2d87b704b3f | gmarpons/asciidoc-hs | ElementAttributes.hs | # LANGUAGE DerivingStrategies #
{-# LANGUAGE OverloadedStrings #-}
-- |
-- Module : Text.AsciiDoc.ElementAttributes
Copyright : © 2020 – present
-- License : BSD-3-Clause
--
Maintainer : < >
-- Stability : experimental
-- Portability : portable
--
-- Implementation of the Element Attri... | null | https://raw.githubusercontent.com/gmarpons/asciidoc-hs/7bcda1dcbb70747563085d3926ddd2ddf7fc2250/src/Text/AsciiDoc/ElementAttributes.hs | haskell | # LANGUAGE OverloadedStrings #
|
Module : Text.AsciiDoc.ElementAttributes
License : BSD-3-Clause
Stability : experimental
Portability : portable
Implementation of the Element Attribute Language for AsciiDoc, i.e., the
language for describing properties (styles, identifiers, roles, named
See -... | # LANGUAGE DerivingStrategies #
Copyright : © 2020 – present
Maintainer : < >
attributes , etc . ) of entities like inlines and blocks .
This module contains Parsec - style parsers for the aforementioned language .
It tries to be compatible with Asciidoctor .
module Text.AsciiDoc.ElementAttribu... |
643ea79fd3eefc4c55c4234679d020d60ea77de826e4ba641b39f32cb86964ec | pascal-knodel/haskell-craft | E'6'27.hs | --
--
--
-----------------
Exercise 6.27 .
-----------------
--
--
--
module E'6'27 where
-- Run-length encoding of a black/white (; bicolor) picture:
type RunLength = Int
type Width = Int
type Picture'RWB = ( Width , [ ( RunLength , Bool ) ] )
| null | https://raw.githubusercontent.com/pascal-knodel/haskell-craft/c03d6eb857abd8b4785b6de075b094ec3653c968/Chapter%206/E'6'27.hs | haskell |
---------------
---------------
Run-length encoding of a black/white (; bicolor) picture: | Exercise 6.27 .
module E'6'27 where
type RunLength = Int
type Width = Int
type Picture'RWB = ( Width , [ ( RunLength , Bool ) ] )
|
12644cd0cab843d9976f34c54e24c8455f33f1b2818f6763e2026865a0fa3f4a | purebred-mua/purebred | System.hs | -- This file is part of purebred
Copyright ( C ) 2019
--
-- purebred is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation , either version 3 of the License , or
-- (at your option) any later version.
--
-... | null | https://raw.githubusercontent.com/purebred-mua/purebred/677db69fdbf84cbd47f075b5204d9fd57efe64c7/src/Purebred/System.hs | haskell | This file is part of purebred
purebred is free software: you can redistribute it and/or modify
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ... | Copyright ( C ) 2019
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation , either version 3 of the License , or
You should have received a copy of the GNU Affero General Public License
# LANGUAGE FlexibleContexts #
module Purebred.System
( tryIO
) whe... |
5b40a0364419023a2d23bddb3c41cbdcba9383628dc5f41e29d2b0bba298feb3 | keechma/keechma | test.cljs | (ns syntest.test
(:require [promesa.core :as p]
[cljs.core.async :refer [<! timeout]]
[cljs.test :refer-macros [async is]]
[syntest.util :as util :refer [promise->chan]])
(:require-macros [cljs.core.async.macros :refer [go-loop]]))
(defn run-async [actions]
(async done
... | null | https://raw.githubusercontent.com/keechma/keechma/8996bf401495e1e0d89bbab8c3c3b9fe43f32116/src/syntest/test.cljs | clojure | (ns syntest.test
(:require [promesa.core :as p]
[cljs.core.async :refer [<! timeout]]
[cljs.test :refer-macros [async is]]
[syntest.util :as util :refer [promise->chan]])
(:require-macros [cljs.core.async.macros :refer [go-loop]]))
(defn run-async [actions]
(async done
... | |
caad2054171369c4947c76f162ad2286dd978c67abda3d3928e4ba63050519d3 | samply/blaze | codec_spec.clj | (ns blaze.db.tx-log.local.codec-spec
(:require
[blaze.byte-buffer :as bb]
[blaze.db.tx-log.local.codec :as codec]
[blaze.db.tx-log.spec]
[clojure.spec.alpha :as s]))
(s/fdef codec/encode-key
:args (s/cat :t :blaze.db/t)
:ret bytes?)
(s/fdef codec/encode-tx-data
:args (s/cat :instant :blaze.d... | null | https://raw.githubusercontent.com/samply/blaze/7afce7769059a68561b76fe756ff858b6d9813d7/modules/db/test/blaze/db/tx_log/local/codec_spec.clj | clojure | (ns blaze.db.tx-log.local.codec-spec
(:require
[blaze.byte-buffer :as bb]
[blaze.db.tx-log.local.codec :as codec]
[blaze.db.tx-log.spec]
[clojure.spec.alpha :as s]))
(s/fdef codec/encode-key
:args (s/cat :t :blaze.db/t)
:ret bytes?)
(s/fdef codec/encode-tx-data
:args (s/cat :instant :blaze.d... | |
2f25af02707c7ee5f95901f76418bd398de0c9984c791795de53bac1490f8b5e | spaceships/circuit-synthesis | Builder.hs | module Circuit.Builder
( Builder
, BuilderT
, buildCircuit
, buildCircuitT
, setSymlen
, setSigma
, saveRef
, module Circuit.Builder
) where
import Circuit
import Circuit.Builder.Internals
import Circuit.Utils
import Control.Monad
import Data.Array
import Lens.Micro.Platform
import Text.Printf
impor... | null | https://raw.githubusercontent.com/spaceships/circuit-synthesis/3fdb67f814acd16e29064138b38c4fedff27b4d5/src/Circuit/Builder.hs | haskell | ------------------------------------------------------------------------------
base gates
inputBit does not create a new symbol: useful as a primitive
get the ref of a particular input, even if it does not exist already.
preserve duplication: there will be many gates for secret 0
avoid duplication: there will be o... | module Circuit.Builder
( Builder
, BuilderT
, buildCircuit
, buildCircuitT
, setSymlen
, setSigma
, saveRef
, module Circuit.Builder
) where
import Circuit
import Circuit.Builder.Internals
import Circuit.Utils
import Control.Monad
import Data.Array
import Lens.Micro.Platform
import Text.Printf
impor... |
c992005387e8dfc29fa8848e06f6b513b5fa3b091a726e03628c9ce035865550 | cryptosense/pkcs11 | pkcs11_CK_SESSION_HANDLE.ml | type t = P11_ulong.t [@@deriving yojson]
let typ = Ctypes.ulong
| null | https://raw.githubusercontent.com/cryptosense/pkcs11/93c39c7a31c87f68f0beabf75ef90d85a782a983/driver/pkcs11_CK_SESSION_HANDLE.ml | ocaml | type t = P11_ulong.t [@@deriving yojson]
let typ = Ctypes.ulong
| |
b7ba68a830b7cedbf67a862062c2e41512e7babb62edd714f83a53cd81989b42 | RichiH/git-annex | Special.hs | helpers for special remotes
-
- Copyright 2011 - 2014 < >
-
- Licensed under the GNU GPL version 3 or higher .
-
- Copyright 2011-2014 Joey Hess <>
-
- Licensed under the GNU GPL version 3 or higher.
-}
module Remote.Helper.Special (
findSpecialRemotes,
gitConfigSpecialRemote,
Preparer,
St... | null | https://raw.githubusercontent.com/RichiH/git-annex/bbcad2b0af8cd9264d0cb86e6ca126ae626171f3/Remote/Helper/Special.hs | haskell | Sets up configuration for a special remote in .git/config.
Use when nothing needs to be done to prepare a helper.
Use to run a check when preparing a helper.
Use to acquire a resource when preparing a helper.
the content of the key to store.
the content to store.
A Retriever that writes the content of a Key to ... | helpers for special remotes
-
- Copyright 2011 - 2014 < >
-
- Licensed under the GNU GPL version 3 or higher .
-
- Copyright 2011-2014 Joey Hess <>
-
- Licensed under the GNU GPL version 3 or higher.
-}
module Remote.Helper.Special (
findSpecialRemotes,
gitConfigSpecialRemote,
Preparer,
St... |
5d05d03e2e1d9e96c7dba5ac05e4a7c03e42e931ed562cd457269776f08d0ca6 | grin-compiler/ghc-wpc-sample-programs | Ipynb.hs | {-# LANGUAGE OverloadedStrings #-}
# LANGUAGE ScopedTypeVariables #
|
Module : Text . Pandoc . Writers . : Copyright ( C ) 2019 - 2020
License : GNU GPL , version 2 or above
Maintainer : < >
Stability : alpha
Portability : portable
( Jupyter notebook JSON forma... | null | https://raw.githubusercontent.com/grin-compiler/ghc-wpc-sample-programs/0e3a9b8b7cc3fa0da7c77fb7588dd4830fb087f7/pandoc-11df2a3c0f2b1b8e351ad8caaa7cdf583e1b3b2e/src/Text/Pandoc/Writers/Ipynb.hs | haskell | # LANGUAGE OverloadedStrings #
convert from a Value (JSON object) to a M.Map Text Value:
TODO warning here? shouldn't happen
means no format given | # LANGUAGE ScopedTypeVariables #
|
Module : Text . Pandoc . Writers . : Copyright ( C ) 2019 - 2020
License : GNU GPL , version 2 or above
Maintainer : < >
Stability : alpha
Portability : portable
( Jupyter notebook JSON format ) writer for pandoc .
Modul... |
e894c08db929d42c168e20ee133e5c7621bd46003ecbbcf7371bd84c0b35d818 | lpw25/ocaml-typed-effects | scanf.mli | (***********************************************************************)
(* *)
(* OCaml *)
(* *)
, projet ... | null | https://raw.githubusercontent.com/lpw25/ocaml-typed-effects/79ea08b285c1fd9caf3f5a4d2aa112877f882bea/stdlib/scanf.mli | ocaml | *********************************************************************
OCaml
... | , projet Cristal , INRIA Rocquencourt
Copyright 2002 Institut National de Recherche en Informatique et
en Automatique . All rights reserved . This file is distributed
under the terms of the GNU Library General Public License , with
* { 6 Introduction }
* { 7 Functiona... |
93f9dc557cdba1091efa4784fcc63e411cefd9a221d327576c4540a8ba9b0e8d | THISISDINOSAUR/Anatomy | main.rkt | #lang br/quicklang
(require "reader/parser.rkt" "reader/tokenizer.rkt")
(define (read-syntax path port)
(define parse-tree (parse path (make-tokenizer port path)))
(strip-bindings
#`(module basic-mod anatomy/expander/expander
#,parse-tree)))
(module+ reader
(provide read-syntax))
| null | https://raw.githubusercontent.com/THISISDINOSAUR/Anatomy/883aa140c41cd375575a2944bda79608c660935b/main.rkt | racket | #lang br/quicklang
(require "reader/parser.rkt" "reader/tokenizer.rkt")
(define (read-syntax path port)
(define parse-tree (parse path (make-tokenizer port path)))
(strip-bindings
#`(module basic-mod anatomy/expander/expander
#,parse-tree)))
(module+ reader
(provide read-syntax))
| |
73484fb5d48786d92bd840589deb7cf634f7c0735fd51d9b0880a5c2f5e55ec4 | wargrey/graphics | convert.rkt | #lang typed/racket/base
(provide (except-out (all-defined-out) create-argb-bitmap create-invalid-bitmap))
(provide Bitmap-Surface bitmap-surface? cairo-surface-shadow)
(provide (rename-out [bitmap<%>-surface bitmap-surface]))
(require typed/racket/unsafe)
(require file/convertible)
(unsafe-provide create-argb-bitmap... | null | https://raw.githubusercontent.com/wargrey/graphics/1ef71dead83418339c6da8dd3cc26d45f6290cba/bitmap/digitama/unsafe/convert.rkt | racket | #lang typed/racket/base
(provide (except-out (all-defined-out) create-argb-bitmap create-invalid-bitmap))
(provide Bitmap-Surface bitmap-surface? cairo-surface-shadow)
(provide (rename-out [bitmap<%>-surface bitmap-surface]))
(require typed/racket/unsafe)
(require file/convertible)
(unsafe-provide create-argb-bitmap... | |
7f65e9d4d9d295b82b2a6e8686b4d85b3a3c6f5c0ed19962badcaf07fb84aa46 | kpreid/e-on-cl | slots.lisp | Copyright 2005 - 2008 , under the terms of the MIT X license
found at ................
(in-package :e.elib)
;;; XXX review the actual uses of these various slot implementations; also consider moving them to e-lambdas
;;; XXX look for ways to reduce the duplication of these common makers
(defun import-uncall (... | null | https://raw.githubusercontent.com/kpreid/e-on-cl/f93d188051c66db0ad4ff150bd73b838f7bc25ed/lisp/slots.lisp | lisp | XXX review the actual uses of these various slot implementations; also consider moving them to e-lambdas
XXX look for ways to reduce the duplication of these common makers
xxx make readable under read-eval?
XXX move to e.syntax?
xxx make readable under read-eval?
XXX move to e.syntax?
XXX move to e.syntax?
XXX ... | Copyright 2005 - 2008 , under the terms of the MIT X license
found at ................
(in-package :e.elib)
(defun import-uncall (fqn)
`#(,(eelt (vat-safe-scope *vat*) "import__uriGetter") "get" #(,fqn)))
(defobject +the-make-simple-slot+ "org.erights.e.elib.slot.makeFinalSlot"
(:stamped +deep-frozen-s... |
56e9e2717c9756b74eab707063488c9bdfa39bf2edeba9cd9bc9b1c7fb53c199 | tommaisey/aeon | pv-phase-shift90.help.scm | ;; (pv-phase-shift90 buffer)
;; Swap the real and imaginary components of every bin at `buffer' and
;; swap the of the imaginary components.
(with-sc3
(lambda (fd)
(async fd (b-alloc 10 2048 1))))
(let ((n (mul (white-noise ar) 0.1)))
(audition (out 0 (ifft* (pv-phase-shift90 (fft* 10 n))))))
| null | https://raw.githubusercontent.com/tommaisey/aeon/80744a7235425c47a061ec8324d923c53ebedf15/libs/third-party/sc3/rsc3/help/ugen/fft/pv-phase-shift90.help.scm | scheme | (pv-phase-shift90 buffer)
Swap the real and imaginary components of every bin at `buffer' and
swap the of the imaginary components. |
(with-sc3
(lambda (fd)
(async fd (b-alloc 10 2048 1))))
(let ((n (mul (white-noise ar) 0.1)))
(audition (out 0 (ifft* (pv-phase-shift90 (fft* 10 n))))))
|
e6f634e44038ece5a063e3c9a23f1399af1b9518140acf3197555d96edcfc32b | nd/bird | 2.5.2.hs | case(f, g) . plus(h, k) = case(f . h, g . k)
case(f, g) . plus(h, k) ==
case(f, g) . case(Left . h, Right . k) ==
case(case(f, g) . Left . h, case(f, g) . Right . k) ==
case(f . h, g . k)
| null | https://raw.githubusercontent.com/nd/bird/06dba97af7cfb11f558eaeb31a75bd04cacf7201/ch02/2.5.2.hs | haskell | case(f, g) . plus(h, k) = case(f . h, g . k)
case(f, g) . plus(h, k) ==
case(f, g) . case(Left . h, Right . k) ==
case(case(f, g) . Left . h, case(f, g) . Right . k) ==
case(f . h, g . k)
| |
cb7e71222f9babc526b9dc3be55ee1675f36941a3ac453b42f2a655c9b9f5ba3 | PacktPublishing/HaskellCookbook | Main.hs | module Main where
import Data.Functor
-- Square a number
square :: Num a => a -> a
square x = x * x
-- Mapping a list
squareList :: Num a => [a] -> [a]
squareList xs = square <$> xs
-- Mapping a Maybe
squareMaybe :: Num a => Maybe a -> Maybe a
squareMaybe x = square <$> x
-- Mapping an Either
squareEither :: Num a... | null | https://raw.githubusercontent.com/PacktPublishing/HaskellCookbook/27e146b6d91c008a7b1d06eda4ea63fe8a8cdb04/Ch_4-Working_With_Functors_Applicatives_And_Monads/working-with-functors/src/Main.hs | haskell | Square a number
Mapping a list
Mapping a Maybe
Mapping an Either
Take the resultant function out of doubleSquare | module Main where
import Data.Functor
square :: Num a => a -> a
square x = x * x
squareList :: Num a => [a] -> [a]
squareList xs = square <$> xs
squareMaybe :: Num a => Maybe a -> Maybe a
squareMaybe x = square <$> x
squareEither :: Num a => Either c a -> Either c a
squareEither x = square <$> x
data Function a b... |
b8c90f1e21cb2e33ac3803d0f9bfdd614b1530e0ef1463ef19c35e52e2f37437 | JohnLato/language-objc | RenderTests.hs | {-# OPTIONS -XPatternGuards #-}
-----------------------------------------------------------------------------
-- |
-- Module : RenderTests.hs (executable)
Copyright : ( c ) 2008
-- License : BSD-style
-- Maintainer :
--
-- This module renders test results into HTML files, much like pugs smoke tes... | null | https://raw.githubusercontent.com/JohnLato/language-objc/8e9455f15b32229f7caf13769c8945d8544c79f0/test/src/RenderTests.hs | haskell | # OPTIONS -XPatternGuards #
---------------------------------------------------------------------------
|
Module : RenderTests.hs (executable)
License : BSD-style
Maintainer :
This module renders test results into HTML files, much like pugs smoke tests.
We use stylesheets to color cells in the resu... | Copyright : ( c ) 2008
TOOD : Display performance in detailled view too ( maybe only if differs significantly from the average performance )
module Main (main) where
import Control.Monad
import qualified Data.Set as Set
import Data.Map (Map)
import qualified Data.Map as Map
import Data.List
import System.IO... |
78c99afcae71f91cc41faeab510ec77bd0534676bf8721521cd60ad29b353471 | Helium4Haskell/helium | DataDupCon3.hs | module DataDupCon3 where
data A = Int :- Int
data B = Int :- Int
| null | https://raw.githubusercontent.com/Helium4Haskell/helium/5928bff479e6f151b4ceb6c69bbc15d71e29eb47/test/staticerrors/DataDupCon3.hs | haskell | module DataDupCon3 where
data A = Int :- Int
data B = Int :- Int
| |
cec4b8f41c24c44b2b9365f8607a1b493843355f12bc2ffcb519c197a80dd3da | SamuelSchlesinger/hs-ts | DevTool.hs | module DevTool where
import DevTool.Interface (Command(..), runCommand)
import Options.Applicative
main :: IO ()
main = customExecParser ps parser >>= runCommand
where
ps = prefs . mconcat $
[ disambiguate
, showHelpOnError
, showHelpOnEmpty
, columns 80
]
author :: String
author ... | null | https://raw.githubusercontent.com/SamuelSchlesinger/hs-ts/426dc6e5149cc5377f94faf717c3b1ab1bfbdb0d/src/DevTool.hs | haskell | module DevTool where
import DevTool.Interface (Command(..), runCommand)
import Options.Applicative
main :: IO ()
main = customExecParser ps parser >>= runCommand
where
ps = prefs . mconcat $
[ disambiguate
, showHelpOnError
, showHelpOnEmpty
, columns 80
]
author :: String
author ... | |
9bae72884d055993b1678075cc3be28a2f1877ed66da6df360c85599daf7df2f | rtoy/ansi-cl-tests | with-package-iterator.lsp | ;-*- Mode: Lisp -*-
Author :
Created : Sat Apr 25 08:03:36 1998
;;;; Contains: Tests of WITH-PACKAGE-ITERATOR
(in-package :cl-test)
(declaim (optimize (safety 3)))
(compile-and-load "package-aux.lsp")
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; with-package-iterator
(deftest with-package-iterator.1
... | null | https://raw.githubusercontent.com/rtoy/ansi-cl-tests/9708f3977220c46def29f43bb237e97d62033c1d/with-package-iterator.lsp | lisp | -*- Mode: Lisp -*-
Contains: Tests of WITH-PACKAGE-ITERATOR
with-package-iterator
Should test on some packages containing shadowed symbols,
multiple inheritance
Apply to all packages
Free declaration scope | Author :
Created : Sat Apr 25 08:03:36 1998
(in-package :cl-test)
(declaim (optimize (safety 3)))
(compile-and-load "package-aux.lsp")
(deftest with-package-iterator.1
(with-package-iterator-internal (list (find-package "COMMON-LISP-USER")))
t)
(deftest with-package-iterator.2
(with-package-iterat... |
04230bba5fcc19a5447933dbda308fe1b179bdc0842088de214154274aaea4c2 | kfsm/pipe | pipe_overflow_SUITE.erl | -module(pipe_overflow_SUITE).
-include_lib("common_test/include/ct.hrl").
-export([all/0]).
-export([
no_dead_lock/1,
congestion_side_b/1,
congestion_side_a/1
]).
-define(FLOOD, 100).
-define(CAPACITY, 10).
-define(STRATEGY, {one_for_all, 0, 1}).
all() ->
[Test || {Test, NAry} <- ?MODULE:module_inf... | null | https://raw.githubusercontent.com/kfsm/pipe/aa38648c477aacbc71af03d4651834eb386a39be/test/pipe_overflow_SUITE.erl | erlang |
------------------------------------------------------------------
helper
------------------------------------------------------------------
| -module(pipe_overflow_SUITE).
-include_lib("common_test/include/ct.hrl").
-export([all/0]).
-export([
no_dead_lock/1,
congestion_side_b/1,
congestion_side_a/1
]).
-define(FLOOD, 100).
-define(CAPACITY, 10).
-define(STRATEGY, {one_for_all, 0, 1}).
all() ->
[Test || {Test, NAry} <- ?MODULE:module_inf... |
4fcaecf948c3876e5903f5af5543ce12efb47a8dc1c321589b14ec45c5e5be0d | vituscze/norri | Parser.hs | -- | Provides main parsers for the language.
module Compiler.Parser
(
-- * Expressions
expr
-- * Value definitions
, def
, defOnly
-- * Type signatures
, typ
, typeSig
, scheme
, assume
-- * Data definitions
, dataDef
-- * Top level entities
, topLevel
... | null | https://raw.githubusercontent.com/vituscze/norri/133aef0b42b2c5bdd789ce2fa2655aecfcb96424/src/Compiler/Parser.hs | haskell | | Provides main parsers for the language.
* Expressions
* Value definitions
* Type signatures
* Data definitions
* Top level entities
* Files
For type quantification.
| Parse a variable of any sort (starting with lower or upper case letter).
| Parse a lambda abstraction.
| Parse a let-in expression.
| Parse... | module Compiler.Parser
(
expr
, def
, defOnly
, typ
, typeSig
, scheme
, assume
, dataDef
, topLevel
, file
)
where
import Text.Parsec
import qualified Text.Parsec.Expr as Ex
import Text.Parsec.String (Parser)
import Compiler.AST
import Compiler.Lexer
var ::... |
e4428389c1d6f3579f98c8367c23394449e21e65db16f71d9e9c0cb523fde4c1 | qfpl/reflex-workshop | Class.hs | |
Copyright : ( c ) 2018 , Commonwealth Scientific and Industrial Research Organisation
License : :
Stability : experimental
Portability : non - portable
Copyright : (c) 2018, Commonwealth Scientific and Industrial Research Organisation
License : BSD3
Maintainer :
Stability : experi... | null | https://raw.githubusercontent.com/qfpl/reflex-workshop/244ef13fb4b2e884f455eccc50072e98d1668c9e/src/Workshop/DOM/Elements/Class.hs | haskell | # LANGUAGE OverloadedStrings #
# LANGUAGE GADTs # | |
Copyright : ( c ) 2018 , Commonwealth Scientific and Industrial Research Organisation
License : :
Stability : experimental
Portability : non - portable
Copyright : (c) 2018, Commonwealth Scientific and Industrial Research Organisation
License : BSD3
Maintainer :
Stability : experi... |
0776f35f0b093262e06003e276e0925a0ddee52454ba10625eb69159c7306e78 | srdqty/talc-3.0 | popsyntax.ml | (**********************************************************************)
( c ) , , ,
June 1998 , all rights reserved .
(**********************************************************************)
open Numtypes;;
type location = Gcdfec.seg
type var = string
type type_name... | null | https://raw.githubusercontent.com/srdqty/talc-3.0/df83dd5ff0e2b189b13280ddae233d8277199350/popcorn/popsyntax.ml | ocaml | ********************************************************************
********************************************************************
floating point operations
More floating point operations.
Binary operators.
address operator
used for unification only
true corresponds to signed.
optional size
LR
E... | ( c ) , , ,
June 1998 , all rights reserved .
open Numtypes;;
type location = Gcdfec.seg
type var = string
type type_name = string
type field_name = string
module Varset = Smallset.Make(struct type t = var let compare = compare end)
type varset = Varset.t
type sco... |
db282d49cb7248fa706244390accd3e1b920214c14b812af0806e0c3a50b2243 | TheLortex/mirage-monorepo | simple_benchmark.ml | let read file =
let open Unix in
let size = (stat file).st_size in
let buf = Bytes.create size in
let rec loop pos len fd =
let n = read fd buf pos len in
if n > 0 then loop (pos + n) (len - n) fd
in
let fd = Unix.openfile file Unix.[O_RDONLY] 0 in
loop 0 size fd;
Unix.close fd;
Bigstringaf.o... | null | https://raw.githubusercontent.com/TheLortex/mirage-monorepo/754836818dc5c861bf3b0a78029315a065a543cc/duniverse/angstrom/benchmarks/simple_benchmark.ml | ocaml | let read file =
let open Unix in
let size = (stat file).st_size in
let buf = Bytes.create size in
let rec loop pos len fd =
let n = read fd buf pos len in
if n > 0 then loop (pos + n) (len - n) fd
in
let fd = Unix.openfile file Unix.[O_RDONLY] 0 in
loop 0 size fd;
Unix.close fd;
Bigstringaf.o... | |
a4c088b6146713c9be8c513e7dda3543c8036c7d72cceab61a22c31e54bbedac | logseq/logseq | debug.cljs | (ns ^:no-doc frontend.db.debug
(:require [frontend.db.utils :as db-utils]
[frontend.db :as db]
[datascript.core :as d]
[frontend.util :as util]))
;; shortcut for query a block with string ref
(defn qb
[string-id]
(db-utils/pull [:block/uuid (uuid string-id)]))
(defn check-lef... | null | https://raw.githubusercontent.com/logseq/logseq/9c7b4ea2016fb28b16ee42a7136c73dd52d8ce4b/src/main/frontend/db/debug.cljs | clojure | shortcut for query a block with string ref | (ns ^:no-doc frontend.db.debug
(:require [frontend.db.utils :as db-utils]
[frontend.db :as db]
[datascript.core :as d]
[frontend.util :as util]))
(defn qb
[string-id]
(db-utils/pull [:block/uuid (uuid string-id)]))
(defn check-left-id-conflicts
[]
(let [db (db/get-db)
... |
a797ee3c5dfd451b8366763791c3778ef7e85d58ef920f9c0a7ce27aa36e6241 | oden-lang/oden | MonomorphizationSpec.hs | module Oden.Compiler.MonomorphizationSpec where
import Data.Set as Set
import Test.Hspec
import Oden.Core.Definition
import Oden.Core.Expr
import Oden.Core.Monomorphed as Monomorphed
import Oden.Core.Package
import Oden.Core.Typed as ... | null | https://raw.githubusercontent.com/oden-lang/oden/10c99b59c8b77c4db51ade9a4d8f9573db7f4d14/test/Oden/Compiler/MonomorphizationSpec.hs | haskell | module Oden.Compiler.MonomorphizationSpec where
import Data.Set as Set
import Test.Hspec
import Oden.Core.Definition
import Oden.Core.Expr
import Oden.Core.Monomorphed as Monomorphed
import Oden.Core.Package
import Oden.Core.Typed as ... | |
59f5e5417538012b0fd52659872546d4d5910bb8e54db7e2120347144f9ab562 | nikomatsakis/a-mir-formality | grammar.rkt | #lang racket
(require redex/reduction-semantics
)
(provide formality-logic
RootUniverse
true-goal
false-goal
)
(define-language formality-logic
;; The "hook" is a bit of a hack that allows the environment
;; to (on demand) get access to clauses and invariants from the
... | null | https://raw.githubusercontent.com/nikomatsakis/a-mir-formality/c67bdca5ac615a410928cc44aa6c8e38cc3ee243/racket-src/logic/grammar.rkt | racket | The "hook" is a bit of a hack that allows the environment
to (on demand) get access to clauses and invariants from the
program without actually knowing the full representation
of the program itself. See hook.rkt for more details.
Parameters to the logic:
Value of a variable
Kinds for variables (e.g., type/lifeti... | #lang racket
(require redex/reduction-semantics
)
(provide formality-logic
RootUniverse
true-goal
false-goal
)
(define-language formality-logic
(Hook ::= (Hook: any))
* VarBinders -- maps variable names to quantifier - kinds / universes
(Envs ::= (Env ...))
(Env :... |
eeefd5d7709cc0649925d9ff4b6044d088fd6cfa0438002b23c1dd050d733844 | tokiwoousaka/ttask | File.hs | module Data.TTask.File.File
( Success(..)
, readActiveProject
, writeActiveProject
, activeProjectName
, setActiveProject
, initDirectory
, initProjectFile
, findProjects
) where
import Control.Applicative
import Control.Exception
import Control.Monad
import Data.Maybe
import Data.TTask.Types
impor... | null | https://raw.githubusercontent.com/tokiwoousaka/ttask/ef5a14ee49e9d8a1e8d0b5c35ee4ae131f4e9acc/src/Data/TTask/File/File.hs | haskell | --
--
ファイル作成直後なので成功している気持ち……
--
util | module Data.TTask.File.File
( Success(..)
, readActiveProject
, writeActiveProject
, activeProjectName
, setActiveProject
, initDirectory
, initProjectFile
, findProjects
) where
import Control.Applicative
import Control.Exception
import Control.Monad
import Data.Maybe
import Data.TTask.Types
impor... |
fcadbf329d0a93dd093408e9eaa569b6baf307814c95e30778d3600b0a3dce90 | samplecount/shake-language-c | OSX.hs | Copyright 2012 - 2014 Samplecount S.L.
--
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
-- you may not use this file except in compliance with the License.
-- You may obtain a copy of the License at
--
-- -2.0
--
-- Unless required by applicable law or agreed to in writing, software
di... | null | https://raw.githubusercontent.com/samplecount/shake-language-c/7eba37910bf711cc4c3fe6e7f065c8108858eea4/src/Development/Shake/Language/C/Host/OSX.hs | haskell |
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
-2.0
Unless required by applicable law or agreed to in writing, software
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing perm... | Copyright 2012 - 2014 Samplecount S.L.
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
distributed under the License is distributed on an " AS IS " BASIS ,
module Development.Shake.Language.C.Host.OSX (
getHostToolChain
) where
import Development.Shake
import Development.Shake.Language.C... |
4b8b14437d9a2503d3ba0cfd79cfd0e5d6b27b7cfbec98cd94dfa81ee35ac2ef | alanz/ghc-exactprint | T18522-dbg-ppr.hs | # LANGUAGE TemplateHaskell , ExplicitForAll , PolyKinds #
# LANGUAGE QuasiQuotes #
module Main where
import Language.Haskell.TH (runQ)
import GHC.Types.Basic
import GHC.ThToHs
import GHC.Driver.Session
import GHC.Core.TyCo.Ppr
import GHC.Utils.Outputable
import GHC.Tc.Module
import GHC.Tc.Utils.Zonk
import GHC.Utils.... | null | https://raw.githubusercontent.com/alanz/ghc-exactprint/b6b75027811fa4c336b34122a7a7b1a8df462563/tests/examples/ghc90/T18522-dbg-ppr.hs | haskell | # LANGUAGE TemplateHaskell , ExplicitForAll , PolyKinds #
# LANGUAGE QuasiQuotes #
module Main where
import Language.Haskell.TH (runQ)
import GHC.Types.Basic
import GHC.ThToHs
import GHC.Driver.Session
import GHC.Core.TyCo.Ppr
import GHC.Utils.Outputable
import GHC.Tc.Module
import GHC.Tc.Utils.Zonk
import GHC.Utils.... | |
cfbd0934c079e2514e0e1b722266469a2dce31bd80d52e8c226d9526818d8ea2 | fogus/bacwn | softstrat.cljs | Copyright ( c ) . All rights reserved . The use and
;; distribution terms for this software are covered by the Eclipse Public
;; License 1.0 (-1.0.php) which can
;; be found in the file epl-v10.html at the root of this distribution. By
;; using this software in any fashion, you are agreeing to be bound by t... | null | https://raw.githubusercontent.com/fogus/bacwn/8aa39b6683db1772aedb7a0ecd7aa6372b72b231/src/clojurescript/fogus/datalog/bacwn/impl/softstrat.cljs | clojure | distribution terms for this software are covered by the Eclipse Public
License 1.0 (-1.0.php) which can
be found in the file epl-v10.html at the root of this distribution. By
using this software in any fashion, you are agreeing to be bound by the
terms of this license. You must not remove this notice, or an... | Copyright ( c ) . All rights reserved . The use and
A Clojure implementation of Datalog -- Soft Stratification
straszheimjeffrey ( gmail )
Created 28 Feburary 2009
Converted to Clojure1.4 by 2012 .
Ported to ClojureScript by 2012 .
(ns fogus.datalog.bacwn.impl.softstrat
(:require [fogus.data... |
f7777dd12c449de4cfb9d7c28c642c23363a4d7e6de880c9315ff4da40cfe354 | xhtmlboi/yocaml | effect.ml | open Util
type (_, 'a) effects =
| File_exists : Filepath.t -> (< file_exists : unit ; .. >, bool) effects
| Target_exists :
Filepath.t
-> (< target_exists : unit ; .. >, bool) effects
| Get_modification_time :
Filepath.t
-> (< get_modification_time : unit ; .. >, int Try.t) effects
| T... | null | https://raw.githubusercontent.com/xhtmlboi/yocaml/3d169cdaaec6f84f841b4212d232c1ee6f749b01/lib/yocaml/effect.ml | ocaml | open Util
type (_, 'a) effects =
| File_exists : Filepath.t -> (< file_exists : unit ; .. >, bool) effects
| Target_exists :
Filepath.t
-> (< target_exists : unit ; .. >, bool) effects
| Get_modification_time :
Filepath.t
-> (< get_modification_time : unit ; .. >, int Try.t) effects
| T... | |
5eb46b75a6f4aa6f088016b5f2b9bc6136f49563fe4a8342142285ab2d55d946 | tweag/servant-template | Id.hs | {-# LANGUAGE DeriveAnyClass #-}
# LANGUAGE DerivingStrategies #
# LANGUAGE GeneralizedNewtypeDeriving #
module Tagger.Id where
import Data.Aeson (FromJSON, ToJSON)
import Data.OpenApi (ToSchema)
import Data.UUID (UUID)
import Rel8 (DBEq, DBType)
import Servant.Auth.JWT (FromJWT, ToJWT)
-- |
-- An 'Id' is a newtype a... | null | https://raw.githubusercontent.com/tweag/servant-template/e12503efd484b27c483d165c01458f832a495f28/src/Tagger/Id.hs | haskell | # LANGUAGE DeriveAnyClass #
|
An 'Id' is a newtype around a 'UUID' with a phantom type 'a' to keep track what the identifier is actually referring to | # LANGUAGE DerivingStrategies #
# LANGUAGE GeneralizedNewtypeDeriving #
module Tagger.Id where
import Data.Aeson (FromJSON, ToJSON)
import Data.OpenApi (ToSchema)
import Data.UUID (UUID)
import Rel8 (DBEq, DBType)
import Servant.Auth.JWT (FromJWT, ToJWT)
newtype Id a = Id {getUUID :: UUID}
deriving stock (Eq, Ord,... |
a172abbdb6cf5952de1194dece17d5bb8680f7f8012feb3238e212f253cc2e3a | TrustInSoft/tis-kernel | wp_parameters.ml | (**************************************************************************)
(* *)
This file is part of .
(* *)
is a fork of Frama - C. Al... | null | https://raw.githubusercontent.com/TrustInSoft/tis-kernel/748d28baba90c03c0f5f4654d2e7bb47dfbe4e7d/src/plugins/wp/wp_parameters.ml | ocaml | ************************************************************************
... | This file is part of .
is a fork of Frama - C. All the differences are :
Copyright ( C ) 2016 - 2017
is released under GPLv2
This file is part of WP plug - in of Frama - C.
Copyright ( C ) 2007 - 2016 ... |
13c466d0614cf1ff598a80bb9f34cb89ad1328bf0e0356d5fbbcf697427cf927 | roosta/tincture | events.cljs | (ns tincture.events
(:import [goog.dom ViewportSizeMonitor])
(:require [reagent.core :as r]
[goog.events.EventType :as event-type]
[goog.dom :as dom]
[goog.events :as gevents]
[tincture.async :as async]
[tincture.grid :as grid]
[reagent.debug :... | null | https://raw.githubusercontent.com/roosta/tincture/587e68248dae09616942dc23bbd97cb9a1a4caa2/src/tincture/events.cljs | clojure | (ns tincture.events
(:import [goog.dom ViewportSizeMonitor])
(:require [reagent.core :as r]
[goog.events.EventType :as event-type]
[goog.dom :as dom]
[goog.events :as gevents]
[tincture.async :as async]
[tincture.grid :as grid]
[reagent.debug :... | |
c4f1571e27789240c5ef45e46c4964606345d76c6570942170f74271d968ed2c | gren-lang/compiler | Block.hs | # LANGUAGE DeriveFunctor #
# LANGUAGE LambdaCase #
{-# OPTIONS_GHC -Wno-name-shadowing #-}
TODO : Extract Text . PrettyPrint . Avh4 to a separate library
module Text.PrettyPrint.Avh4.Block
( Line,
string7,
lineFromBuilder,
commentByteString,
space,
Block (SingleLine, MustBreak),
blankLine,... | null | https://raw.githubusercontent.com/gren-lang/compiler/7fd91be8a45cef1f3356f8247b409fbbe87e193d/compiler/src/Text/PrettyPrint/Avh4/Block.hs | haskell | # OPTIONS_GHC -Wno-name-shadowing #
and can always be combined horizontally with other `Line`s.
- `Space` is a single horizontal space,
- `Text` brings any text into the data structure. (Uses `ByteString.Builder` for the possibility of optimal performance)
| If you know the String only contains ASCII characters, t... | # LANGUAGE DeriveFunctor #
# LANGUAGE LambdaCase #
TODO : Extract Text . PrettyPrint . Avh4 to a separate library
module Text.PrettyPrint.Avh4.Block
( Line,
string7,
lineFromBuilder,
commentByteString,
space,
Block (SingleLine, MustBreak),
blankLine,
line,
mustBreak,
stack,
... |
ce3ef15803c3085178b447416986101b7a758452f6fa9bcc013b867dc4e8cc18 | binsec/haunted | pmap.mli | (**************************************************************************)
This file is part of BINSEC .
(* *)
Copyright ( C ) 2016 - 2019
CEA ( Co... | null | https://raw.githubusercontent.com/binsec/haunted/7ffc5f4072950fe138f53fe953ace98fff181c73/src/static/pmap.mli | ocaml | ************************************************************************
alternatives)
you can redistribute it an... | This file is part of BINSEC .
Copyright ( C ) 2016 - 2019
CEA ( Commissariat à l'énergie atomique et aux énergies
Lesser General Public License as published by the Free Software
Foundation , ve... |
926ff0ea02dbf4961fcce0e4fab9abb76c706e9c460edea03e74640e25bde3c0 | dsorokin/aivika | MainUsingCairo.hs |
To run , package aivika - experiment - cairo must be installed .
import Simulation.Aivika.Experiment
import Simulation.Aivika.Experiment.Chart
import Simulation.Aivika.Experiment.Chart.Backend.Cairo
import Graphics.Rendering.Chart.Backend.Cairo
import Model
main = runExperiment experiment generators (WebPageRend... | null | https://raw.githubusercontent.com/dsorokin/aivika/7a14f460ab114b0f8cdfcd05d5cc889fdc2db0a4/tests/Random/MainUsingCairo.hs | haskell |
To run , package aivika - experiment - cairo must be installed .
import Simulation.Aivika.Experiment
import Simulation.Aivika.Experiment.Chart
import Simulation.Aivika.Experiment.Chart.Backend.Cairo
import Graphics.Rendering.Chart.Backend.Cairo
import Model
main = runExperiment experiment generators (WebPageRend... | |
ae6a40ccd31bcc10ad0497d150f89b6f91b13c850b621c8d049c27cb1dab79ab | elastic/eui-cljs | icon_vis_text.cljs | (ns eui.icon-vis-text
(:require ["@elastic/eui/lib/components/icon/assets/vis_text.js" :as eui]))
(def visText eui/icon)
| null | https://raw.githubusercontent.com/elastic/eui-cljs/ad60b57470a2eb8db9bca050e02f52dd964d9f8e/src/eui/icon_vis_text.cljs | clojure | (ns eui.icon-vis-text
(:require ["@elastic/eui/lib/components/icon/assets/vis_text.js" :as eui]))
(def visText eui/icon)
| |
88380e23876a6df4d8e53024ae459a2ec9eb7651e21f8e36f57c0825b70df4e4 | alt-romes/hegg | Database.hs | # LANGUAGE ViewPatterns #
{-# LANGUAGE BangPatterns #-}
# LANGUAGE OverloadedLists #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE LambdaCase #
# LANGUAGE TupleSections #
{-|
Custom database implemented with trie-maps specialized to run conjunctive
queries using a (worst-case optimal) generic join algorithm.
Us... | null | https://raw.githubusercontent.com/alt-romes/hegg/db3b3eb3ae05c48e10504115a839b80cab689a48/src/Data/Equality/Matching/Database.hs | haskell | # LANGUAGE BangPatterns #
|
Custom database implemented with trie-maps specialized to run conjunctive
queries using a (worst-case optimal) generic join algorithm.
Used in e-matching ('Data.Equality.Matching') as described by \"Relational
E-Matching\" .
You probably don't need this module.
| A variab... | # LANGUAGE ViewPatterns #
# LANGUAGE OverloadedLists #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE LambdaCase #
# LANGUAGE TupleSections #
module Data.Equality.Matching.Database
(
genericJoin
, Database(..)
, Query(..)
, IntTrie(..)
, Subst
, Var
, Atom(..)
, ClassIdOrVar(..)
) where
import Data... |
defafb930b638718083ac91a8dd61dbef9c3c9c3036a9ca30294f6b9e3227d51 | Chris00/ocaml-mindstorm | ev3_connect.ml | open Printf
type connection = Bluetooth of string | USB
let dev = ref None
type t = {
args : (Arg.key * Arg.spec * Arg.doc) list;
f : 'a. 'a Mindstorm.EV3.conn -> unit;
}
let default_args = [
"--bt", Arg.String(fun n -> dev := Some(Bluetooth n)),
"addr Connects to this bluetooth address";
"--usb", Ar... | null | https://raw.githubusercontent.com/Chris00/ocaml-mindstorm/a96ea45059cafd136c98190674b6214f03357cf8/tests/ev3_connect.ml | ocaml | (match Mindstorm.EV3.USB.bricks() with
| dev :: _ ->
d.f conn;
Mindstorm.EV3.close conn
| [] -> print_endline "No EV3 brick connected to a USB port.") | open Printf
type connection = Bluetooth of string | USB
let dev = ref None
type t = {
args : (Arg.key * Arg.spec * Arg.doc) list;
f : 'a. 'a Mindstorm.EV3.conn -> unit;
}
let default_args = [
"--bt", Arg.String(fun n -> dev := Some(Bluetooth n)),
"addr Connects to this bluetooth address";
"--usb", Ar... |
c41812a0f4d7c26751ed4880396427265b4cfa9c644b5d5af13469d1f31186c6 | calvis/cKanren | quines.rkt | #lang racket
(require
"../ck.rkt"
"../absento.rkt"
"../attributes.rkt"
"../tree-unify.rkt"
"../neq.rkt"
"../tester.rkt"
(for-syntax "../ck.rkt"))
(provide test-quines test-quines-long)
;; (begin-for-syntax
;; (define strat 'dfs)
;; (search-strategy strat))
;; (define-lazy-goal (eval-expo exp env val)
(def... | null | https://raw.githubusercontent.com/calvis/cKanren/8714bdd442ca03dbf5b1d6250904cbc5fd275e68/cKanren/tests/quines.rkt | racket | (begin-for-syntax
(define strat 'dfs)
(search-strategy strat))
(define-lazy-goal (eval-expo exp env val)
(define-lazy-goal proper-listo | #lang racket
(require
"../ck.rkt"
"../absento.rkt"
"../attributes.rkt"
"../tree-unify.rkt"
"../neq.rkt"
"../tester.rkt"
(for-syntax "../ck.rkt"))
(provide test-quines test-quines-long)
(define (eval-expo exp env val)
(conde
((fresh (v)
(== `(quote ,v) exp)
(not-in-envo 'quote env)
(ab... |
7ea0580dcb76497ba16891557459cbfe07d654c22e953b4d4ac14741b59a2566 | emina/rosette | util.rkt | #lang racket
(require rackunit (only-in "../bv.rkt" synthesize-fragment))
(provide (all-defined-out))
(define-syntax-rule (test-fragment (id param ...) expr ...)
(test-case
(symbol->string 'id)
(check-not-exn
(lambda ()
(synthesize-fragment (id param ...) expr ...))
(format "Failed to synthes... | null | https://raw.githubusercontent.com/emina/rosette/a64e2bccfe5876c5daaf4a17c5a28a49e2fbd501/sdsl/bv/test/util.rkt | racket | #lang racket
(require rackunit (only-in "../bv.rkt" synthesize-fragment))
(provide (all-defined-out))
(define-syntax-rule (test-fragment (id param ...) expr ...)
(test-case
(symbol->string 'id)
(check-not-exn
(lambda ()
(synthesize-fragment (id param ...) expr ...))
(format "Failed to synthes... | |
9cb3fc37e90cb39287bab368b3779706ae3b6d88094826d29fad59b41db8ab51 | dieswaytoofast/erlasticsearch | erlasticsearch.erl | %%%-------------------------------------------------------------------
@author < >
( C ) 2013
%%% @doc type definitions and records.
%%% @end
%%%
This source file is subject to the New BSD License . You should have received
%%% a copy of the New BSD license with this software. If not, it can be
%%% retr... | null | https://raw.githubusercontent.com/dieswaytoofast/erlasticsearch/70285a63dd1c2142fb8949458eed16a8389d5636/src/erlasticsearch.erl | erlang | -------------------------------------------------------------------
@doc type definitions and records.
@end
a copy of the New BSD license with this software. If not, it can be
retrieved from: -license.php
------------------------------------------------------------------- | @author < >
( C ) 2013
This source file is subject to the New BSD License . You should have received
-module(erlasticsearch).
-author('Mahesh Paolini-Subramanya <>').
-include("erlasticsearch.hrl").
-export([start/0, start/1]).
-export([stop/0, stop/1]).
-export([stop_pool/1]).
-export([start_pool/1, ... |
a25c3d87dcadc93132dba60d39abe036dc7a86584da20bb0ffd541196a640ee6 | jaspervdj/advent-of-code | 19.hs | module Main where
import AdventOfCode.Main (pureMain)
import AdventOfCode.NanoParser as P
import AdventOfCode.V3 (V3 (..), manhattan, (.+.), (.-.))
import Control.Monad (guard)
import Data.Foldable (foldl')
import Data.List.E... | null | https://raw.githubusercontent.com/jaspervdj/advent-of-code/104b5f947b7f6b5b3a26d3ccb38cfe6ceec7ddda/2021/19.hs | haskell | scan.
| Try to merge a list of scanners | module Main where
import AdventOfCode.Main (pureMain)
import AdventOfCode.NanoParser as P
import AdventOfCode.V3 (V3 (..), manhattan, (.+.), (.-.))
import Control.Monad (guard)
import Data.Foldable (foldl')
import Data.List.E... |
9fa957b13c458639dac3ee425a92d7c5a0b684b5478aacdb05fed867cc9738e9 | glondu/belenios | majority_judgment.ml | (**************************************************************************)
(* BELENIOS *)
(* *)
Copyright © 2012 - 2021
(* ... | null | https://raw.githubusercontent.com/glondu/belenios/404d1b3cc06b545ffbd345a0de5c2a5fe4b29392/src/lib/core/majority_judgment.ml | ocaml | ************************************************************************
BELENIOS
This program is free softw... | Copyright © 2012 - 2021
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation , either version 3 of the
exemption that compiling , linking , and/or using OpenSSL is allowed .
You should have rece... |
ea3d082e98ac8482b7e05652b6e284e7aa242b096c82e8492ad96a96c231ef69 | l3nz/say-cheez | project.clj | (defproject say-cheez "0.2.0"
:description "Takes a snapshot of the environment at build time."
:url "-cheez"
:license {:name "Eclipse Public License"
:url "-v10.html"}
:aliases
{"fix" ["cljfmt" "fix"]
Kondo
"clj-kondo" ["with-profile" "kondo"
"trampoline" "run" "-m"
... | null | https://raw.githubusercontent.com/l3nz/say-cheez/11e2a55f6e623b3957af90aee689004b117c2c32/project.clj | clojure | :tag "..."
Some plugins | (defproject say-cheez "0.2.0"
:description "Takes a snapshot of the environment at build time."
:url "-cheez"
:license {:name "Eclipse Public License"
:url "-v10.html"}
:aliases
{"fix" ["cljfmt" "fix"]
Kondo
"clj-kondo" ["with-profile" "kondo"
"trampoline" "run" "-m"
... |
5d38c6bb9c2fe131a4e6d879cd6c4e2b62b15b67003fd2739ec0dd021043d94b | Vaelatern/necessary-evil | methodresponse.clj | (ns necessary-evil.methodresponse
"This module implementents the methodResponse wire format portion of the
XML-RPC spec. You can find the official spec at
-rpc.com/spec.
A methodResponse may contain either a value or a fault. Unless you are
extending this you should only need the emit-method-respons and ... | null | https://raw.githubusercontent.com/Vaelatern/necessary-evil/e4e8c9ccb0a631b57ef2eed52b8670bf9f705567/src/necessary_evil/methodresponse.clj | clojure | serialising methodResponses to XML | (ns necessary-evil.methodresponse
"This module implementents the methodResponse wire format portion of the
XML-RPC spec. You can find the official spec at
-rpc.com/spec.
A methodResponse may contain either a value or a fault. Unless you are
extending this you should only need the emit-method-respons and ... |
7ed76dcdeda0e53538b80189d1b8ac829ae1552056810fbde76d405d363e3e59 | dongcarl/guix | linux-initrd.scm | ;;; GNU Guix --- Functional package management for GNU
Copyright © 2013 , 2014 , 2015 , 2018 , 2020 < >
;;;
;;; 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 ; ... | null | https://raw.githubusercontent.com/dongcarl/guix/82543e9649da2da9a5285ede4ec4f718fd740fcb/gnu/build/linux-initrd.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 , 2018 , 2020 < >
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 build linux-initrd)
#:use-module ((guix cpio) #:prefix cpio:)
... |
af24a357ac5bae2c768172cccfb3a2eff8edd71dc115c8f40c9b8283e07911b1 | s-expressionists/Eclector | tokens.lisp | (cl:in-package #:eclector.reader)
;;; Token Reading
(defmethod read-token (client input-stream eof-error-p eof-value)
(declare (ignore eof-error-p eof-value))
(with-token-info (push-char (start-escape end-escape) finalize)
(labels ((handle-char (char escapep)
(declare (ignore escapep))
... | null | https://raw.githubusercontent.com/s-expressionists/Eclector/ed4ebd3d03981d225004b5d969db766d49ca16b4/code/reader/tokens.lisp | lisp | Token Reading
Constituent traits
Based on Table 2-8 in 2.1.4.2 Constituent Traits
Token interpretation
*READ-DEFAULT-FLOAT-FORMAT* may be some other type
specifier which the implementation chooses to allow.
next character and returning a symbol and going to tag SYMBOL
in case of an escape and as the default su... | (cl:in-package #:eclector.reader)
(defmethod read-token (client input-stream eof-error-p eof-value)
(declare (ignore eof-error-p eof-value))
(with-token-info (push-char (start-escape end-escape) finalize)
(labels ((handle-char (char escapep)
(declare (ignore escapep))
(push-char ... |
f5490971da44e0ec8064a73060e065378ef9633767239ad9d1ce9b33e4623d43 | coccinelle/coccinelle | item.ml | (******************************************************************************)
(* *)
(* *)
... | null | https://raw.githubusercontent.com/coccinelle/coccinelle/57cbff0c5768e22bb2d8c20e8dae74294515c6b3/bundles/menhirLib/menhir-20181113/src/item.ml | ocaml | ****************************************************************************
file LICEN... |
, Paris
, PPS , Université Paris Diderot
. All rights reserved . This file is distributed under the
terms of the GNU General Public License version 2 , as... |
a14789c0cb8edd0b6d3e41780d8cc4391be0dda180a7b123e9cc31d38275e24d | well-typed/large-records | R000.hs | #if PROFILE_CORESIZE
{-# OPTIONS_GHC -ddump-to-file -ddump-simpl #-}
#endif
#if PROFILE_TIMING
{-# OPTIONS_GHC -ddump-to-file -ddump-timings #-}
#endif
module Experiment.SR_ParseJSON.Sized.R000 where
| null | https://raw.githubusercontent.com/well-typed/large-records/e6941d0c1b34e176323b1ca7f20e96257f10e01f/large-records-benchmarks/bench/superrecord/Experiment/SR_ParseJSON/Sized/R000.hs | haskell | # OPTIONS_GHC -ddump-to-file -ddump-simpl #
# OPTIONS_GHC -ddump-to-file -ddump-timings # | #if PROFILE_CORESIZE
#endif
#if PROFILE_TIMING
#endif
module Experiment.SR_ParseJSON.Sized.R000 where
|
7e27224ad74cacb90c2955d18b433c7956d7fd52b15ab4db0b53bbe6ad2d1497 | stoeckley/Eat-Static | project.clj | (defproject nl.balconystudio/eat-static "0.1.0"
:description "Eat Static, a library for type checking and validation of Clojure maps and functions."
:url "-Static"
:license {:name "Eclipse Public License"
:url "-v10.html"}
:dependencies [[org.clojure/clojure "1.6.0"]])
| null | https://raw.githubusercontent.com/stoeckley/Eat-Static/5a824d4ebb303f7db9a71e4781664ef3672fd518/project.clj | clojure | (defproject nl.balconystudio/eat-static "0.1.0"
:description "Eat Static, a library for type checking and validation of Clojure maps and functions."
:url "-Static"
:license {:name "Eclipse Public License"
:url "-v10.html"}
:dependencies [[org.clojure/clojure "1.6.0"]])
| |
b2fb55d8ab875f32d76b7b184282d53902827a59bb526ff1a8a74bf17b51b0ec | Beyamor/ruin | game.cljs | (ns ruin.game
(:use [cljs.core.async :only [chan sliding-buffer put!]])
(:require [ruin.display :as d]
[ruin.scene :as s])
(:require-macros [lonocloud.synthread :as ->]
[cljs.core.async.macros :refer [go]]))
;
; ACTUAL GAME STUFF
;
(defn create
[width height key-events]
(let ... | null | https://raw.githubusercontent.com/Beyamor/ruin/50a6977430dcbbceecccadbf732298462165b049/src/ruin/game.cljs | clojure |
ACTUAL GAME STUFF
AND THEN LIKE
THE JUNK WHAT ACTUALLY GETS IT GOING
| (ns ruin.game
(:use [cljs.core.async :only [chan sliding-buffer put!]])
(:require [ruin.display :as d]
[ruin.scene :as s])
(:require-macros [lonocloud.synthread :as ->]
[cljs.core.async.macros :refer [go]]))
(defn create
[width height key-events]
(let [display (d/create width h... |
17ed2b43ea1c7824d0171fa6c2dcd36ea6b256a10c749cf928259abd2270322b | lemmih/lhc | Let.hs | module Basic1 where
x = let y = x in y
fn1 0 = let y = 10 in y
fn2 n = let y = fn2 n in y
fn3 n = let even = 0 : odd
odd = 1 : even
in even
| null | https://raw.githubusercontent.com/lemmih/lhc/53bfa57b9b7275b7737dcf9dd620533d0261be66/haskell-crux/tests/Let.hs | haskell | module Basic1 where
x = let y = x in y
fn1 0 = let y = 10 in y
fn2 n = let y = fn2 n in y
fn3 n = let even = 0 : odd
odd = 1 : even
in even
| |
8ffd520f9e47818e20eedeaf035e5494c055589ef6a10ebf642f7d7eab044b91 | brendanhay/gogol | Patch.hs | # LANGUAGE DataKinds #
# LANGUAGE DeriveGeneric #
# LANGUAGE DerivingStrategies #
# LANGUAGE DuplicateRecordFields #
# LANGUAGE FlexibleInstances #
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE LambdaCase #
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE PatternSynonyms #
# LANGUAGE RecordWildCards #
{-# LANGUAGE St... | null | https://raw.githubusercontent.com/brendanhay/gogol/77394c4e0f5bd729e6fe27119701c45f9d5e1e9a/lib/services/gogol-oslogin/gen/Gogol/OSLogin/Users/SshPublicKeys/Patch.hs | haskell | # LANGUAGE OverloadedStrings #
# LANGUAGE StrictData #
|
Stability : auto-generated
/See:/ </ Cloud OS Login API Reference> for @oslogin.users.sshPublicKeys.patch@.
* Resource
** Constructing a Request
'OSLoginUsersSshPublicKeysPatch' request conforms to.
/See:/ 'newOSLoginUsersSshPublicKeysPatch' smart con... | # LANGUAGE DataKinds #
# LANGUAGE DeriveGeneric #
# LANGUAGE DerivingStrategies #
# LANGUAGE DuplicateRecordFields #
# LANGUAGE FlexibleInstances #
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE LambdaCase #
# LANGUAGE PatternSynonyms #
# LANGUAGE RecordWildCards #
# LANGUAGE TypeFamilies #
# LANGUAGE TypeOperators... |
9dc905ce25edc1b1f661ef35cf103af012d88cd5686997a1b5f0a0e68f15bf78 | andreas/ocaml-graphql-server | graphql_async.mli | (** GraphQL schema with Async support *)
module Schema : sig
include
Graphql_intf.Schema
with type 'a Io.t = 'a Async_kernel.Deferred.t
and type 'a Io.Stream.t = 'a Async_kernel.Pipe.Reader.t
and type field_error = string
end
| null | https://raw.githubusercontent.com/andreas/ocaml-graphql-server/d615cbb164d4ddfdc2efeb246a198dfe114adf24/graphql-async/src/graphql_async.mli | ocaml | * GraphQL schema with Async support | module Schema : sig
include
Graphql_intf.Schema
with type 'a Io.t = 'a Async_kernel.Deferred.t
and type 'a Io.Stream.t = 'a Async_kernel.Pipe.Reader.t
and type field_error = string
end
|
81d3bc907db99fe2d8cc4b547e3d70bf54f0c667580020c5a3e6bc87e06bde55 | OlafChitil/hat | Numeric.hs | module Hat.Numeric
(gfromRat, afromRat, hfromRat, gshowSigned,
ashowSigned, hshowSigned, gshowIntAtBase,
ashowIntAtBase, hshowIntAtBase, gshowInt, gshowOct,
gshowHex, greadSigned, areadSigned, hreadSigned,
greadInt, areadInt, hreadInt, greadDec, greadOct,
greadHex, gfloatT... | null | https://raw.githubusercontent.com/OlafChitil/hat/8840a480c076f9f01e58ce24b346850169498be2/Hat/Numeric.hs | haskell | module Hat.Numeric
(gfromRat, afromRat, hfromRat, gshowSigned,
ashowSigned, hshowSigned, gshowIntAtBase,
ashowIntAtBase, hshowIntAtBase, gshowInt, gshowOct,
gshowHex, greadSigned, areadSigned, hreadSigned,
greadInt, areadInt, hreadInt, greadDec, greadOct,
greadHex, gfloatT... | |
b8ca22d4750ed1d6349066a8b806fb489c472d57866d22fe7ab6c04801be9ad1 | ygrek/mldonkey | serverLog.ml | Copyright 2002 b8_bavard , b8_fee_carabine ,
This file is part of mldonkey .
mldonkey is free software ; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation ; either version 2 of the License , or
( at y... | null | https://raw.githubusercontent.com/ygrek/mldonkey/333868a12bb6cd25fed49391dd2c3a767741cb51/src/networks/server/serverLog.ml | ocaml | with _ -> lprintf "vraiment pas cool"; | Copyright 2002 b8_bavard , b8_fee_carabine ,
This file is part of mldonkey .
mldonkey is free software ; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation ; either version 2 of the License , or
( at y... |
af7a31ef96fc002552476b91989dd939797a6df8012c0e4aab6a8e085f8fef9b | racket/typed-racket | list.rkt | #lang racket/base
(require syntax/parse racket/match
"../utils/utils.rkt"
"../types/abbrev.rkt"
"../types/utils.rkt"
"../types/type-table.rkt"
"utils.rkt"
"logging.rkt"
(for-template racket/base racket/unsafe/ops))
(provide list-opt-expr)
(define-syntax-... | null | https://raw.githubusercontent.com/racket/typed-racket/1dde78d165472d67ae682b68622d2b7ee3e15e1e/typed-racket-lib/typed-racket/optimizer/list.rkt | racket | Similar to known-length vectors opts.
If we use `list-ref' or `list-tail' on a known-length list with a
literal index, we can optimize if the index is within bounds.
We know the length of known-length lists statically. | #lang racket/base
(require syntax/parse racket/match
"../utils/utils.rkt"
"../types/abbrev.rkt"
"../types/utils.rkt"
"../types/type-table.rkt"
"utils.rkt"
"logging.rkt"
(for-template racket/base racket/unsafe/ops))
(provide list-opt-expr)
(define-syntax-... |
66301074d74a8c9b8511c0172b0fbb07892bf864346de9b32915fe249147f901 | jamesdabbs/pi-base.hs | Traits.hs | module Form.Traits
( createTraitForm
, updateTraitForm
) where
import Import
import Form
import Yesod.Form.Bootstrap3
createTraitForm :: SpaceId -> Html -> MForm Handler (FormResult Trait, Widget)
createTraitForm sid = renderBootstrap3 fLayout $ Trait
<$> pure sid
<*> areq (propertyField sid) (fs "Property") Not... | null | https://raw.githubusercontent.com/jamesdabbs/pi-base.hs/1c7cb1f87c6525bd4844842b3f9442634f8dccd3/Form/Traits.hs | haskell | module Form.Traits
( createTraitForm
, updateTraitForm
) where
import Import
import Form
import Yesod.Form.Bootstrap3
createTraitForm :: SpaceId -> Html -> MForm Handler (FormResult Trait, Widget)
createTraitForm sid = renderBootstrap3 fLayout $ Trait
<$> pure sid
<*> areq (propertyField sid) (fs "Property") Not... | |
721717a516a10a45562ddefd9318b3266f69416e061937ae2f890f4732403917 | alexandergunnarson/quantum | reg.cljc | (ns quantum.measure.reg)
(defonce reg-units (atom {})) | null | https://raw.githubusercontent.com/alexandergunnarson/quantum/0c655af439734709566110949f9f2f482e468509/src/quantum/measure/reg.cljc | clojure | (ns quantum.measure.reg)
(defonce reg-units (atom {})) | |
53548ff876c75e278a390e46d963c5bfd34fc8c691f1de2bea6fe3673212c666 | ErlyORM/boss_db | boss_cache_adapter_memcached_bin.erl | -module(boss_cache_adapter_memcached_bin).
-behaviour(boss_cache_adapter).
-export([init/1, start/0, start/1, stop/1, terminate/1]).
-export([get/3, set/5, delete/3]).
start() ->
start([]).
start(Options) ->
CacheServers = proplists:get_value(cache_servers, Options, [{"localhost", 11211, 1}]),
erlmc:star... | null | https://raw.githubusercontent.com/ErlyORM/boss_db/20060a061d3c4120929e4a4fedae1bb5e5830426/src/cache_adapters/boss_cache_adapter_memcached_bin.erl | erlang | internal | -module(boss_cache_adapter_memcached_bin).
-behaviour(boss_cache_adapter).
-export([init/1, start/0, start/1, stop/1, terminate/1]).
-export([get/3, set/5, delete/3]).
start() ->
start([]).
start(Options) ->
CacheServers = proplists:get_value(cache_servers, Options, [{"localhost", 11211, 1}]),
erlmc:star... |
41ce7f58f7f9ea0d3b650e5468c126182a67ecab18246476ff278c3f7372ed62 | dleslie/allegro-egg | constants.scm | (define joystick-max-axes (foreign-value "_AL_MAX_JOYSTICK_AXES" integer))
(define joystick-max-sticks (foreign-value "_AL_MAX_JOYSTICK_STICKS" integer))
(define joystick-max-buttons (foreign-value "_AL_MAX_JOYSTICK_BUTTONS" integer))
(define default-display-adapter (foreign-value "ALLEGRO_DEFAULT_DISPLAY_ADAPTER" int... | null | https://raw.githubusercontent.com/dleslie/allegro-egg/0435fb891dda5c64e95aa9dedccddd31b17e27da/constants.scm | scheme | (define native-path-separator (foreign-value "ALLEGRO_NATIVE_PATH_SEP" c-string))
(define native-drive-separator (foreign-value "ALLEGRO_NATIVE_DRIVE_SEP" c-string)) | (define joystick-max-axes (foreign-value "_AL_MAX_JOYSTICK_AXES" integer))
(define joystick-max-sticks (foreign-value "_AL_MAX_JOYSTICK_STICKS" integer))
(define joystick-max-buttons (foreign-value "_AL_MAX_JOYSTICK_BUTTONS" integer))
(define default-display-adapter (foreign-value "ALLEGRO_DEFAULT_DISPLAY_ADAPTER" int... |
7a2e1632bdca17f0baad641459863b97ea233498c1ce16944c49ae6f8f451522 | lindenbaum/lbm_kv | lbm_kv_tests.erl | %%%=============================================================================
%%%
| o _ _ _ | _ _ _ | _ _ _ _ ( TM )
%%% |_ | | | (_| (/_ | | |_) (_| |_| | | |
%%%
( C ) 2014 - 2018 , Lindenbaum GmbH
%%%
%%% Permission to use, copy, modify, and/or distribute t... | null | https://raw.githubusercontent.com/lindenbaum/lbm_kv/121467ae4766753b052b923d202e8b17dc14e054/test/lbm_kv_tests.erl | erlang | =============================================================================
|_ | | | (_| (/_ | | |_) (_| |_| | | |
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission n... | | o _ _ _ | _ _ _ | _ _ _ _ ( TM )
( C ) 2014 - 2018 , Lindenbaum GmbH
THE SOFTWARE IS PROVIDED " AS IS " AND THE AUTHOR DISCLAIMS ALL WARRANTIES
ANY SPECIAL , DIRECT , INDIRECT , OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE , DATA OR PRO... |
717c9cdc46dad0f26805cd7e609023ae7e18b2f754d12d2e58f623cbf978e91b | janestreet/bonsai | type_intf.ml | open! Core
module Auto_generated = Bonsai_web_ui_auto_generated
module T = struct
type record =
{ name : string
; age : int
; market_on_gold : int * int
; likes_cats : bool [@default true]
}
[@@deriving sexp, sexp_grammar, quickcheck]
type binary_tree =
| Leaf of { value : int }
| No... | null | https://raw.githubusercontent.com/janestreet/bonsai/33e9a58fc55ec12095959dc5ef4fd681021c1083/examples/sexp_grammar/type_intf.ml | ocaml | open! Core
module Auto_generated = Bonsai_web_ui_auto_generated
module T = struct
type record =
{ name : string
; age : int
; market_on_gold : int * int
; likes_cats : bool [@default true]
}
[@@deriving sexp, sexp_grammar, quickcheck]
type binary_tree =
| Leaf of { value : int }
| No... | |
f8f38310ca0d02f857e9002cf0f83fe33030ecbfdbc8f42bf9e9dbee2fae5134 | madvas/catlantis | user.cljs | (ns catlantis.ios.screens.user
(:require [re-frame.core :as rf]
[reagent.core :as r]
[print.foo :as pf :include-macros true]
[catlantis.shared.ui :as ui]
[clojure.string :as str]))
(declare styles)
(def bg-img (js/require "./images/login_bg1.jpg"))
(defn invalid-user... | null | https://raw.githubusercontent.com/madvas/catlantis/b8880ec2cab27ecfcb3c0ab30e2bbc7767db0d1c/src/catlantis/ios/screens/user.cljs | clojure | (ns catlantis.ios.screens.user
(:require [re-frame.core :as rf]
[reagent.core :as r]
[print.foo :as pf :include-macros true]
[catlantis.shared.ui :as ui]
[clojure.string :as str]))
(declare styles)
(def bg-img (js/require "./images/login_bg1.jpg"))
(defn invalid-user... | |
ce94266a17adbd24a967a6978eefe7ebc3b4ed57a2335904f7bc37c58540d56d | ondrap/dynamodb-simple | Migration.hs | {-# LANGUAGE DataKinds #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE MultiWayIf #-}
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE ScopedTypeVariables #
# LANGUAGE TupleSections #
# LANGUAGE TypeFamilies #
{-# LANGUAGE TypeOperators #-}
module Database.DynamoDB.Migratio... | null | https://raw.githubusercontent.com/ondrap/dynamodb-simple/fb7e3fe37d7e534161274cfd812cd11a82cc384b/src/Database/DynamoDB/Migration.hs | haskell | # LANGUAGE DataKinds #
# LANGUAGE FlexibleContexts #
# LANGUAGE MultiWayIf #
# LANGUAGE OverloadedStrings #
# LANGUAGE TypeOperators #
| Periodically check state of table, until it is ACTIVE
| Delete specified indices from the database
| Update table with specified new indices
| Compar... | # LANGUAGE ScopedTypeVariables #
# LANGUAGE TupleSections #
# LANGUAGE TypeFamilies #
module Database.DynamoDB.Migration (
runMigration
) where
import Control.Arrow (first)
import Control.Concurrent (threadDelay)
import Control.Lens ... |
8df0aaa314f0510326f855215caf2f95aa44d9cdf9b02ff4fb21abeb56c1b1b8 | irastypain/sicp-on-language-racket | test_exercise_2_03s.rkt | #lang racket
(require rackunit
"../../src/lib/cons-point.rkt"
"../../src/chapter02/exercise_2_03s.rkt")
(define A (make-point 4.0 2.0))
(define ABCD (make-rectangle A 3.0 5.0))
(check-equal? (rectangle-perimeter ABCD) 16.0 (printf "test#1 2.03s passed\n"))
(check-equal? (rectangle-area ABCD) 15.0 ... | null | https://raw.githubusercontent.com/irastypain/sicp-on-language-racket/0052f91d3c2432a00e7e15310f416cb77eeb4c9c/test/chapter02/test_exercise_2_03s.rkt | racket | #lang racket
(require rackunit
"../../src/lib/cons-point.rkt"
"../../src/chapter02/exercise_2_03s.rkt")
(define A (make-point 4.0 2.0))
(define ABCD (make-rectangle A 3.0 5.0))
(check-equal? (rectangle-perimeter ABCD) 16.0 (printf "test#1 2.03s passed\n"))
(check-equal? (rectangle-area ABCD) 15.0 ... | |
f3af7c63fe76d49f431881009d7ab355eab278d9c3c6c03a0d8785083b35a78c | nomaddo/loop | transl.ml | open Batteries
open Etc
open Operand
open Typ
open Ir
open Instr
open Typed_ast
let zero = Operand.new_operand (Iconst 0) I4
let symbol_tbl: (Tident.path, Tyenv.intf Typed_ast.typ) Hashtbl.t = Hashtbl.create 10
let global_intf : Tyenv.intf ref = ref (Obj.magic ())
let transl_typ typ =
match typ with
| Void -> f... | null | https://raw.githubusercontent.com/nomaddo/loop/cd2204208b67b7e1f386b730c953404482ca36d6/ir/transl.ml | ocaml | pre_initial
initial
entrance
terminate
entrance
terminate
epilogue
nextがないときにretがないと駄目 | open Batteries
open Etc
open Operand
open Typ
open Ir
open Instr
open Typed_ast
let zero = Operand.new_operand (Iconst 0) I4
let symbol_tbl: (Tident.path, Tyenv.intf Typed_ast.typ) Hashtbl.t = Hashtbl.create 10
let global_intf : Tyenv.intf ref = ref (Obj.magic ())
let transl_typ typ =
match typ with
| Void -> f... |
a8b76777cdffd2b12845ea64f627087d7fb11d5ff8913bc1d82b7cdff843ce7c | cgrand/macrovich | macrovich.cljc | (ns net.cgrand.macrovich
(:refer-clojure :exclude [case replace]))
(defmacro deftime
"This block will only be evaluated at the correct time for macro definition, at other times its content
are removed.
For Clojure it always behaves like a `do` block.
For Clojurescript/JVM the block is only visible to Cloj... | null | https://raw.githubusercontent.com/cgrand/macrovich/e80fb37cb795201821d0e75f73119802227e9620/src/net/cgrand/macrovich.cljc | clojure | (ns net.cgrand.macrovich
(:refer-clojure :exclude [case replace]))
(defmacro deftime
"This block will only be evaluated at the correct time for macro definition, at other times its content
are removed.
For Clojure it always behaves like a `do` block.
For Clojurescript/JVM the block is only visible to Cloj... | |
84c66a40b59ac93c9f8b5abff62a48c26ec9d63dd00dbcbf4f2826197ba8c2fb | babashka/nbb | example.cljs | (ns example
(:require ["asciidoctor$default" :as asciidoctor]))
(def ascii (asciidoctor))
(def content "[*Asciidoctor*]
running on [_Opal_]
brings AsciiDoc to Node.js!")
(def html (.convert ascii content))
(println html)
;; <div class="paragraph">
;; <p><a href=""><strong>Asciidoctor</strong></a>
;; running on <a... | null | https://raw.githubusercontent.com/babashka/nbb/5f2f25da18376ff8706822c771c30f6299a4bf54/examples/asciidoctor/example.cljs | clojure | <div class="paragraph">
<p><a href=""><strong>Asciidoctor</strong></a>
running on <a href=""><em>Opal</em></a>
</div> | (ns example
(:require ["asciidoctor$default" :as asciidoctor]))
(def ascii (asciidoctor))
(def content "[*Asciidoctor*]
running on [_Opal_]
brings AsciiDoc to Node.js!")
(def html (.convert ascii content))
(println html)
brings AsciiDoc to Node.js!</p >
|
b66d9822ffdf9164ddbcecf5233db84d2c449e99e5c81de3eee6e67aa9389ce2 | matsubara0507/git-plantation | API.hs | # LANGUAGE BlockArguments #
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE LambdaCase #-}
# LANGUAGE MultiParamTypeClasses #
{-# LANGUAGE OverloadedLabels #-}
{-# LANGUAGE TypeOperators #-}
module Git.Plantation.API where
import RIO... | null | https://raw.githubusercontent.com/matsubara0507/git-plantation/7bd7ea01fec83dc02118eefcfeb145a1df4f564e/src/Git/Plantation/API.hs | haskell | # LANGUAGE DataKinds #
# LANGUAGE FlexibleContexts #
# LANGUAGE LambdaCase #
# LANGUAGE OverloadedLabels #
# LANGUAGE TypeOperators # | # LANGUAGE BlockArguments #
# LANGUAGE MultiParamTypeClasses #
module Git.Plantation.API where
import RIO
import qualified RIO.Text as T
import qualified Crypto.Hash as Hash
import qualified Crypto.Random as Random
import qualified Data.Aeson.Text ... |
91bad743af503281db39257f72c71eab44a4012b3dca9ffb97f67a481edb288e | ghc/packages-Cabal | GrammarRegex.hs | {-# LANGUAGE DeriveFoldable #-}
{-# LANGUAGE DeriveFunctor #-}
{-# LANGUAGE DeriveTraversable #-}
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE ScopedTypeVariables #
module Distribution.Utils.GrammarRegex (
-- * Regular expressions
GrammarRegex (..),
reEps,
reChar,
reChars,
reMunc... | null | https://raw.githubusercontent.com/ghc/packages-Cabal/6f22f2a789fa23edb210a2591d74ea6a5f767872/Cabal/Cabal-described/src/Distribution/Utils/GrammarRegex.hs | haskell | # LANGUAGE DeriveFoldable #
# LANGUAGE DeriveFunctor #
# LANGUAGE DeriveTraversable #
# LANGUAGE OverloadedStrings #
* Regular expressions
* Variables
* Pretty-printing
-----------------------------------------------------------------------------
-------------------------------------------------------... | # LANGUAGE ScopedTypeVariables #
module Distribution.Utils.GrammarRegex (
GrammarRegex (..),
reEps,
reChar,
reChars,
reMunchCS,
reMunch1CS,
reVar0,
reVar1,
regexDoc,
) where
import Data.Char (isAlphaNum, isControl, ord)
import Data.Foldable (F... |
5077beb4522634f795881733541efc8b6d40730c6b9d3e6f9a151f0b206e0356 | sellout/haskerwaul | Residual.hs | # language UndecidableInstances
, UndecidableSuperClasses #
, UndecidableSuperClasses #-}
module Haskerwaul.Residual
( module Haskerwaul.Residual
-- * extended modules
, module Haskerwaul.Residual.Left
, module Haskerwaul.Residual.Right
) where
import Haskerwaul.Category.Monoidal.Sym... | null | https://raw.githubusercontent.com/sellout/haskerwaul/cf54bd7ce5bf4f3d1fd0d9d991dc733785b66a73/src/Haskerwaul/Residual.hs | haskell | * extended modules
| This definition is a bit backward. It's more that in a symmetric monoidal
category, either residual implies the other.
= references
- [nLab]()
__NB__: Instances for this are automatically coalesced | # language UndecidableInstances
, UndecidableSuperClasses #
, UndecidableSuperClasses #-}
module Haskerwaul.Residual
( module Haskerwaul.Residual
, module Haskerwaul.Residual.Left
, module Haskerwaul.Residual.Right
) where
import Haskerwaul.Category.Monoidal.Symmetric
import Haskerwaul... |
5cd71f9afe979828a5e3c32f1416cdc1e075c448650b3371a91061bfd4858f36 | henryw374/cljc.java-time | zone_offset.clj | (ns cljc.java-time.zone-offset (:refer-clojure :exclude [abs get range format min max next name resolve short]) (:require [cljc.java-time.extn.calendar-awareness]) (:import [java.time ZoneOffset]))
(def max java.time.ZoneOffset/MAX)
(def min java.time.ZoneOffset/MIN)
(def utc java.time.ZoneOffset/UTC)
(clojure.core/def... | null | https://raw.githubusercontent.com/henryw374/cljc.java-time/2e47e8104bc2ec7f68a01bf751a7b9a2dee391b4/src/cljc/java_time/zone_offset.clj | clojure | (ns cljc.java-time.zone-offset (:refer-clojure :exclude [abs get range format min max next name resolve short]) (:require [cljc.java-time.extn.calendar-awareness]) (:import [java.time ZoneOffset]))
(def max java.time.ZoneOffset/MAX)
(def min java.time.ZoneOffset/MIN)
(def utc java.time.ZoneOffset/UTC)
(clojure.core/def... | |
69acb80f88d4e5718a679e4e9f3fe56fba089cdb64829f3df6226474f937bcf2 | emotiq/emotiq | mock.lisp | ;;;; Wherein we mock the reports of consensus status from a modeled EMTQ chain
(in-package :model/wallet)
(defun mock (notify-hook)
"Run a service that sends json messages to the function of one argument specified via NOTIFY-HOOK"
(let ((epoch (+ 1000 (random 10000)))
(local-epoch 0)
(iterations-un... | null | https://raw.githubusercontent.com/emotiq/emotiq/9af78023f670777895a3dac29a2bbe98e19b6249/src/model/mock.lisp | lisp | Wherein we mock the reports of consensus status from a modeled EMTQ chain | (in-package :model/wallet)
(defun mock (notify-hook)
"Run a service that sends json messages to the function of one argument specified via NOTIFY-HOOK"
(let ((epoch (+ 1000 (random 10000)))
(local-epoch 0)
(iterations-until-sync 20)
(i 0))
(flet ((advance ()
(setf epoch
... |
d72436de391b06195b7a75b6a1854e609953add5e19ff076060bfe5bde266a6e | brendanhay/gogol | Product.hs | # LANGUAGE DataKinds #
# LANGUAGE DeriveGeneric #
# LANGUAGE DerivingStrategies #
# LANGUAGE DuplicateRecordFields #
# LANGUAGE FlexibleInstances #
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE LambdaCase #
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE PatternSynonyms #
# LANGUAGE RecordWildCards #
{-# LANGUAGE St... | null | https://raw.githubusercontent.com/brendanhay/gogol/8cbceeaaba36a3c08712b2e272606161500fbe91/lib/services/gogol-games-configuration/gen/Gogol/GamesConfiguration/Internal/Product.hs | haskell | # LANGUAGE OverloadedStrings #
# LANGUAGE StrictData #
|
Stability : auto-generated
* AchievementConfiguration
* AchievementConfigurationDetail
* AchievementConfigurationListResponse
* GamesNumberAffixConfiguration
* GamesNumberFormatConfiguration
* ImageConfiguration
* LeaderboardConfiguration
* LocalizedS... | # LANGUAGE DataKinds #
# LANGUAGE DeriveGeneric #
# LANGUAGE DerivingStrategies #
# LANGUAGE DuplicateRecordFields #
# LANGUAGE FlexibleInstances #
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE LambdaCase #
# LANGUAGE PatternSynonyms #
# LANGUAGE RecordWildCards #
# LANGUAGE TypeFamilies #
# LANGUAGE TypeOperators... |
166e27edb91cbb80dc9736ef6aa66b47d53e809b7dd91181c35b00d0696e23d1 | samrushing/irken-compiler | bignum.scm | ;; -*- Mode: Irken -*-
;; we use a vector of limbs.
;; this facilitates mutating bignums in place,
;; and is considerably faster than using a list
;; of limbs.
(datatype big
(:zero)
(:pos (vector int))
(:neg (vector int))
)
;; we need some sort of compile-time selector, like %backend,
;; but for word-s... | null | https://raw.githubusercontent.com/samrushing/irken-compiler/690da48852d55497f873738df54f14e8e135d006/demo/bignum.scm | scheme | -*- Mode: Irken -*-
we use a vector of limbs.
this facilitates mutating bignums in place,
and is considerably faster than using a list
of limbs.
we need some sort of compile-time selector, like %backend,
but for word-size - because we do not want to mutate these
values (we want them all inlined).
itera... |
(datatype big
(:zero)
(:pos (vector int))
(:neg (vector int))
)
(define big/bits 60)
(define big/base #x1000000000000000)
(define big/halfbits 30)
(define big/mask #xfffffffffffffff)
(define big/halfmask #x3fffffff)
(define big/repr-width 15)
(define big/decimal... |
86b3d237dadc6f11f575ef31099cae5a4c6fd3c002f6856343a7ff3a60d8ba7b | pascal-knodel/haskell-craft | C'7.hs | --
Chapter 7 .
--
module C'7 where
import Prelude hiding
(
product
, reverse
, unzip
, minimum
, maximum
, and
, or
, getLine
, splitAt
, take
, drop
, zip3
, words
)
import Test.QuickCheck
import QCC ( quickCheckN )
import Test.HUnit
import E'7'35
import E'7'34
import E'7'33
import E'7'32
... | null | https://raw.githubusercontent.com/pascal-knodel/haskell-craft/c03d6eb857abd8b4785b6de075b094ec3653c968/Chapter%207/C'7.hs | haskell | Chapter 7 .
module C'7 where
import Prelude hiding
(
product
, reverse
, unzip
, minimum
, maximum
, and
, or
, getLine
, splitAt
, take
, drop
, zip3
, words
)
import Test.QuickCheck
import QCC ( quickCheckN )
import Test.HUnit
import E'7'35
import E'7'34
import E'7'33
import E'7'32
import... | |
1edad4a592bc3b4c87a7522e962cfff52845b50b8b441d87c015f3dace4ee88c | lantiga/redlock-clj | project.clj | (defproject redlock-clj "0.1.0"
:description "Redlock Redis-based distributed locks implementation in Clojure"
:url "-clj"
:license {:name "Eclipse Public License"
:url "-v10.html"}
:dependencies [[org.clojure/clojure "1.5.1"]
[com.taoensso/carmine "2.6.2"]])
| null | https://raw.githubusercontent.com/lantiga/redlock-clj/97a1add654bd4330979c377f4ea636ce741e8807/project.clj | clojure | (defproject redlock-clj "0.1.0"
:description "Redlock Redis-based distributed locks implementation in Clojure"
:url "-clj"
:license {:name "Eclipse Public License"
:url "-v10.html"}
:dependencies [[org.clojure/clojure "1.5.1"]
[com.taoensso/carmine "2.6.2"]])
| |
8dcecc587e248f9da4067419a221ce226ba751198c4650120f432caea251245f | danoctavian/bit-smuggler | ARQ.hs | # LANGUAGE RecordWildCards #
{-# LANGUAGE OverloadedStrings #-}
module Network.BitSmuggler.ARQ (
recvARQ
, sendARQ
, initGoBackNARQ
, Time (..)
, newClock
, tickSend
, tickRecv
, noARQ
, headerLen
) where
import Prelude as P
import Foreign.Storable
import Data.Word
import Data.Default
import Dat... | null | https://raw.githubusercontent.com/danoctavian/bit-smuggler/4385ed67f1fec4ed441832fc9a119de632b796aa/BitSmuggler/src/Network/BitSmuggler/ARQ.hs | haskell | # LANGUAGE OverloadedStrings #
== Automatic repeat request ARQ protocol ==
protocol to deal with
* disconnects in the bittorrent client connection
* tcp packet tampering by an adversary
type: go-back-n ARQ
implementation is specific to the bitsmuggler design
TODO: it's more imperative and impure... | # LANGUAGE RecordWildCards #
module Network.BitSmuggler.ARQ (
recvARQ
, sendARQ
, initGoBackNARQ
, Time (..)
, newClock
, tickSend
, tickRecv
, noARQ
, headerLen
) where
import Prelude as P
import Foreign.Storable
import Data.Word
import Data.Default
import Data.ByteString as BS
import Data.Dequ... |
983ff17efdd2052cee932a9252ee3fcfba376c4d3156145042513d54ff3ecc00 | ailisp/Graphic-Forms | user32.lisp | (in-package :graphic-forms.uitoolkit.system)
(eval-when (:compile-toplevel :load-toplevel :execute)
(use-package :cffi)
#+cffi-features:no-stdcall
(error "Graphic-Forms requires stdcall support enabled in CFFI."))
(load-foreign-library "user32.dll")
(defcfun
("AdjustWindowRectEx" adjust-window-rect)
BOOL
(... | null | https://raw.githubusercontent.com/ailisp/Graphic-Forms/1e0723d07e1e4e02b8ae375db8f3d65d1b444f11/src/uitoolkit/system/user32.lisp | lisp | which can be used to write code compatible to both Win32
typedef'd to GetClassLong, so that is the function
that actually has to be referenced by this defcfun form.
GetWindowLong is deprecated in favor of GetWindowLongPtr
which can be used to write code compatible to both Win32
that actually has to be referenced... | (in-package :graphic-forms.uitoolkit.system)
(eval-when (:compile-toplevel :load-toplevel :execute)
(use-package :cffi)
#+cffi-features:no-stdcall
(error "Graphic-Forms requires stdcall support enabled in CFFI."))
(load-foreign-library "user32.dll")
(defcfun
("AdjustWindowRectEx" adjust-window-rect)
BOOL
(... |
2d9b2b06a2870574835f79c08a4240af45d9ee3f1f681f1d6acc122480b0a996 | UU-ComputerScience/uhc | Main.hs |
data Integer
foreign import ccall primIntToInteger :: Int -> Integer
foreign import ccall primIntegerToInt :: Integer -> Int
main = <PRINT_INT> (primIntegerToInt (primIntToInteger 37))
| null | https://raw.githubusercontent.com/UU-ComputerScience/uhc/f2b94a90d26e2093d84044b3832a9a3e3c36b129/EHC/test/nofib-jvschie/trivial/opaque/Main.hs | haskell |
data Integer
foreign import ccall primIntToInteger :: Int -> Integer
foreign import ccall primIntegerToInt :: Integer -> Int
main = <PRINT_INT> (primIntegerToInt (primIntToInteger 37))
| |
08af7d0e1b2c137a3e08369582be27ac79f00ae2a597d751e7780e2b871bd495 | spawngrid/htoad | parse_trans_mod.erl | %%============================================================================
Copyright 2011 Erlang Solutions Ltd.
%%
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
%% you may not use this file except in compliance with the License.
%% You may obtain a copy of the License at
%%
%% -2.0
%%
%%... | null | https://raw.githubusercontent.com/spawngrid/htoad/f0c7dfbd911b29fb0c406b7c26606f553af11194/deps/parse_trans/src/parse_trans_mod.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 expr... | Copyright 2011 Erlang Solutions Ltd.
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
distributed under the License is distributed on an " AS IS " BASIS ,
Original author :
-module(parse_trans_mod).
Interface exports
-export([transform_module/3]).
-export([abstract_code/1]).
-export([b... |
8aa143611276dd9e6b450f039f92f16a2130a3b99dfa733b92994f81120d2d53 | dbuenzli/mtime | test.ml | ---------------------------------------------------------------------------
Copyright ( c ) 2015 The programmers . All rights reserved .
Distributed under the ISC license , see terms at the end of the file .
---------------------------------------------------------------------------
Copyright (c) 2015... | null | https://raw.githubusercontent.com/dbuenzli/mtime/e7dc6baa08236288fcc19517f322464aa2f8ef83/test/test.ml | ocaml | ---------------------------------------------------------------------------
Copyright ( c ) 2015 The programmers . All rights reserved .
Distributed under the ISC license , see terms at the end of the file .
---------------------------------------------------------------------------
Copyright (c) 2015... | |
65e850b0ebb76ea963d8572d43b3338b6c486f183ef84d833b0bcc4d66e7b0bd | hiroshi-unno/coar | bcopy3.ml | let make_array n i = assert (0 <= i && i < n); 0
let update des i x j = if i=j then x else des i
let rec bcopy_aux m src des i =
if i >= m
then ()
else
begin
update des i (src i);
bcopy_aux m src des (i+1)
end
let main n m =
let array1 = make_array n in
let array2 = make_array m in
if ... | null | https://raw.githubusercontent.com/hiroshi-unno/coar/90a23a09332c68f380efd4115b3f6fdc825f413d/benchmarks/OCaml/safety/tacas2015/bcopy3.ml | ocaml | let make_array n i = assert (0 <= i && i < n); 0
let update des i x j = if i=j then x else des i
let rec bcopy_aux m src des i =
if i >= m
then ()
else
begin
update des i (src i);
bcopy_aux m src des (i+1)
end
let main n m =
let array1 = make_array n in
let array2 = make_array m in
if ... | |
e52dffe6f9874bf27bfb51395553ca9dc72728a8c581dbefc0ceb799c0a318c9 | anoma/juvix | Dependency.hs | module Juvix.Compiler.Pipeline.Package.Dependency
( RawDependency,
Dependency,
Dependency' (..),
processDependency,
dependencyPath,
rawDependency,
)
where
import Lens . Micro . Platform qualified as Lens
import Data.Aeson.BetterErrors
import Data.Kind qualified as GHC
import Data.Yaml
import ... | null | https://raw.githubusercontent.com/anoma/juvix/c1d85c451e447dd8b1b82fe2fd4677d8ee9a117b/src/Juvix/Compiler/Pipeline/Package/Dependency.hs | haskell | | dependencies paths are canonicalized just after reading the package | module Juvix.Compiler.Pipeline.Package.Dependency
( RawDependency,
Dependency,
Dependency' (..),
processDependency,
dependencyPath,
rawDependency,
)
where
import Lens . Micro . Platform qualified as Lens
import Data.Aeson.BetterErrors
import Data.Kind qualified as GHC
import Data.Yaml
import ... |
4c806e1c40b9a67af655497bc113ae375046a6f252f0d07434aba8d49e003f5f | psibi/tldr-hs | App.hs | # LANGUAGE ScopedTypeVariables #
module Tldr.App
( appMain
) where
import Data.List (intercalate)
import Data.Version (showVersion)
import Options.Applicative
import Paths_tldr (version)
import System.Environment (getArgs)
import Tldr.App.Constant (platformDirs)
import Tldr.App.Handler
import Tldr.Types
import Co... | null | https://raw.githubusercontent.com/psibi/tldr-hs/14117b0dc47524b3ecb7892cfbb70db9899c09d6/src/Tldr/App.hs | haskell | # LANGUAGE ScopedTypeVariables #
module Tldr.App
( appMain
) where
import Data.List (intercalate)
import Data.Version (showVersion)
import Options.Applicative
import Paths_tldr (version)
import System.Environment (getArgs)
import Tldr.App.Constant (platformDirs)
import Tldr.App.Handler
import Tldr.Types
import Co... | |
62f8bf871c28b48ee2dc03fe6c07f78291c00a8f0dc3ce183307bb432ac1bca1 | tweag/asterius | bytearray.hs | # LANGUAGE MagicHash #
# LANGUAGE UnboxedTuples #
{-# OPTIONS_GHC -Wall -ddump-to-file -ddump-simpl -ddump-stg -ddump-cmm-raw -ddump-asm #-}
import Control.Concurrent
import Control.Monad
import Data.Foldable
import GHC.Exts
import GHC.Types
This test case tests the ability of the compiler to handle casts from I8 t... | null | https://raw.githubusercontent.com/tweag/asterius/e7b823c87499656860f87b9b468eb0567add1de8/asterius/test/bytearray/bytearray.hs | haskell | # OPTIONS_GHC -Wall -ddump-to-file -ddump-simpl -ddump-stg -ddump-cmm-raw -ddump-asm # | # LANGUAGE MagicHash #
# LANGUAGE UnboxedTuples #
import Control.Concurrent
import Control.Monad
import Data.Foldable
import GHC.Exts
import GHC.Types
This test case tests the ability of the compiler to handle casts from I8 to
I64 in a real - world example by using the ` ByteArray # ` primitives .
Expected out... |
9351b6db650a4f2350754005dd426cab178275f17b341aec87cef1643d7cf7db | aconchillo/guilescript | decompile-tree-il.scm | ;;; (language javascript decompile-tree-il) --- GuileScript.
Copyright ( C ) 2022 Flaque < >
;;
This file is part of GuileScript .
;;
GuileScript 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 ; eit... | null | https://raw.githubusercontent.com/aconchillo/guilescript/abb77cd7634714470a95e40aaed94546715947ec/language/javascript/decompile-tree-il.scm | scheme | (language javascript decompile-tree-il) --- GuileScript.
either version 3 of the License , or
(at your option) any later version.
GuileScript is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Se... |
Copyright ( C ) 2022 Flaque < >
This file is part of GuileScript .
GuileScript is free software : you can redistribute it and/or modify
it 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 . If not , see /.
... |
7d849f4ab8220ebedfa2109194e92bab434afda47aa7ed4c7e3da62318a1a9fa | ocaml-flambda/ocaml-jst | parser.mli |
(* The type of tokens. *)
type token =
| WITH
| WHILE
| WHEN
| VIRTUAL
| VAL
| UNDERSCORE
| UIDENT of (string)
| TYPE
| TRY
| TRUE
| TO
| TILDE
| THEN
| STRUCT
| STRING of (string * Location.t * string option)
| STAR
| SIG
| SEMISEMI
| SEMI
| RPAREN
| REC
| RBRACKET
| RB... | null | https://raw.githubusercontent.com/ocaml-flambda/ocaml-jst/b0a649516b33b83b7290c6fa5d7cb4c8c343df8c/boot/menhir/parser.mli | ocaml | The type of tokens.
This exception is raised by the monolithic API functions.
The monolithic API.
The incremental API.
The entry point(s) to the incremental API. |
type token =
| WITH
| WHILE
| WHEN
| VIRTUAL
| VAL
| UNDERSCORE
| UIDENT of (string)
| TYPE
| TRY
| TRUE
| TO
| TILDE
| THEN
| STRUCT
| STRING of (string * Location.t * string option)
| STAR
| SIG
| SEMISEMI
| SEMI
| RPAREN
| REC
| RBRACKET
| RBRACE
| QUOTED_STRING_ITE... |
788ca002082fb4154d1525a0c2ec18e1bc848ef93769c0ad15150c14381376cb | gedge-platform/gedge-platform | aten.erl | This Source Code Form is subject to the terms of the Mozilla Public
License , v. 2.0 . If a copy of the MPL was not distributed with this
file , You can obtain one at /.
%%
Copyright ( c ) 2018 - 2020 VMware , Inc. or its affiliates . All rights reserved .
%%
-module(aten).
-export([
start/0,
... | null | https://raw.githubusercontent.com/gedge-platform/gedge-platform/97c1e87faf28ba2942a77196b6be0a952bff1c3e/gs-broker/broker-server/deps/aten/src/aten.erl | erlang | This Source Code Form is subject to the terms of the Mozilla Public
License , v. 2.0 . If a copy of the MPL was not distributed with this
file , You can obtain one at /.
Copyright ( c ) 2018 - 2020 VMware , Inc. or its affiliates . All rights reserved .
-module(aten).
-export([
start/0,
reg... | |
cf65c072939e7e93becac5df9ba405436f21a2352197852bc40b572364b1219b | stevenvar/OMicroB | device_config.ml | let avrcxxopts = ref []
let avrobjcopts = ref []
let avrdudeopts = ref []
let arch_args =
arch_args@[
("-avrcxxopt", Arg.String (fun opt -> avrcxxopts := opt :: !avrcxxopts),
"<option> Pass the given option to the AVR C++ compiler");
("-avrcxxopts", Arg.String (fun opts -> avrcxxopts := ... | null | https://raw.githubusercontent.com/stevenvar/OMicroB/99a2e781f9511137090aaba3c09e2e920c0dbc77/targets/avr/device_config.ml | ocaml | ****************************************************************************
Compile .c to .avr
****************************************************************************
* Choose the correct config according to name
****************************************************************************
*********************... | let avrcxxopts = ref []
let avrobjcopts = ref []
let avrdudeopts = ref []
let arch_args =
arch_args@[
("-avrcxxopt", Arg.String (fun opt -> avrcxxopts := opt :: !avrcxxopts),
"<option> Pass the given option to the AVR C++ compiler");
("-avrcxxopts", Arg.String (fun opts -> avrcxxopts := ... |
54affd03d4a7c7fb3c79a15f8cd9a9b44ab8383e49bf3780f3db6392f0ea6d32 | charlieg/Sparser | marker-pairs.lisp | ;;; -*- Mode:LISP; Syntax:Common-Lisp; Package:(SPARSER LISP) -*-
copyright ( c ) 1994 -- all rights reserved
;;;
;;; File: "marker pairs"
;;; Module: "objects;doc:"
Version : 0.1 June 1994
initiated 5/20/94 v2.3
0.1 ( 6/6 ) promulgated new argument to Populate - section - marker
(in-packag... | null | https://raw.githubusercontent.com/charlieg/Sparser/b9bb7d01d2e40f783f3214fc104062db3d15e608/Sparser/code/s/objects/doc/marker-pairs.lisp | lisp | -*- Mode:LISP; Syntax:Common-Lisp; Package:(SPARSER LISP) -*-
File: "marker pairs"
Module: "objects;doc:"
We implement these as section markers with a variation on
the dispatch through complete so that we separate the initiate
and terminate actions according to which string is involved.
intern aga... | copyright ( c ) 1994 -- all rights reserved
Version : 0.1 June 1994
initiated 5/20/94 v2.3
0.1 ( 6/6 ) promulgated new argument to Populate - section - marker
(in-package :sparser)
(define-category start-section)
(define-category end-section)
(defun define-markup-tag-pair/expr (name
... |
39ca42eca6d2e75fa15d62930999714fff362bba44197ec0e95ed1ef8a4dc3c2 | msgpack/msgpack-haskell | Assoc.hs | {-# LANGUAGE DeriveDataTypeable #-}
# LANGUAGE GeneralizedNewtypeDeriving #
--------------------------------------------------------------------
-- |
-- Module : Data.MessagePack.Assoc
Copyright : ( c ) Daiki Handa , 2010 - 2011
-- License : BSD3
--
-- Maintainer:
-- Stability : experimental
-- Porta... | null | https://raw.githubusercontent.com/msgpack/msgpack-haskell/f52a5d2db620a7be70810eca648fd152141f8b14/msgpack/src/Data/MessagePack/Assoc.hs | haskell | # LANGUAGE DeriveDataTypeable #
------------------------------------------------------------------
|
Module : Data.MessagePack.Assoc
License : BSD3
Maintainer:
Stability : experimental
Portability: portable
------------------------------------------------------------------
not defined for gene... | # LANGUAGE GeneralizedNewtypeDeriving #
Copyright : ( c ) Daiki Handa , 2010 - 2011
MessagePack map labeling type
module Data.MessagePack.Assoc (
Assoc(..)
) where
import Compat.Prelude
newtype Assoc a
= Assoc { unAssoc :: a }
deriving (Show, Read, Eq, Ord, Typeable, NFData)
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.