_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 |
|---|---|---|---|---|---|---|---|---|
cc0b41d79f49fe5e26f7540dd0632f9f56002a4734a4856596a9c8f1358daec0 | GaloisInc/pate | SimState.hs | |
Module : . SimState
Copyright : ( c ) Galois , Inc 2020
Maintainer : < >
Functionality for handling the inputs and outputs of crucible .
Module : Pate.SimState
Copyright : (c) Galois, Inc 2020
Maintainer : Daniel Matichuk <>
Functionality for handling t... | null | https://raw.githubusercontent.com/GaloisInc/pate/a48c447156d95686c308a6d5ec696464120e0970/src/Pate/SimState.hs | haskell | # LANGUAGE GADTs #
# LANGUAGE RankNTypes #
# LANGUAGE ConstraintKinds #
# LANGUAGE TypeSynonymInstances #
# LANGUAGE OverloadedStrings #
# LANGUAGE NoMonoLocalBinds #
simulator state
variable binding
----------------------------------
Crucible inputs and outputs
| The most recent region allocated by malloc. Ideal... | |
Module : . SimState
Copyright : ( c ) Galois , Inc 2020
Maintainer : < >
Functionality for handling the inputs and outputs of crucible .
Module : Pate.SimState
Copyright : (c) Galois, Inc 2020
Maintainer : Daniel Matichuk <>
Functionality for handling t... |
293da30786cb138161a32ad30868ef382ba7403649921ce72b2643ed882bf86e | bartima3us/erline-dht | erline_dht_message_tests.erl | %%%-------------------------------------------------------------------
@author
( C ) 2019 ,
%%% @doc
%%% erline_dht_message module unit tests.
%%% @end
Created : 18 . Aug 2019 16.11
%%%-------------------------------------------------------------------
-module(erline_dht_message_tests).
-author("bartimaeus").
... | null | https://raw.githubusercontent.com/bartima3us/erline-dht/7de9bee0b5b86a347b9527369877e3d97b863d9d/test/erline_dht_message_tests.erl | erlang | -------------------------------------------------------------------
@doc
erline_dht_message module unit tests.
@end
-------------------------------------------------------------------
| @author
( C ) 2019 ,
Created : 18 . Aug 2019 16.11
-module(erline_dht_message_tests).
-author("bartimaeus").
-include_lib("eunit/include/eunit.hrl").
do_ping_test_() ->
{setup,
fun() -> ok end,
fun(_) -> ok end,
[{"Ping request.",
fun() ->
?assertEqual(... |
135eb7d0afaf3e700050c3e0abc9a7cd1bfd043d7630865ce8434616fa93f666 | ghc/ghc | T23068.hs | # LANGUAGE MagicHash , UnboxedTuples #
module T23068 where
import GHC.Exts
f :: () -> (# Int, Int #)
f () = (# 0, 0 #)
g :: () -> (# Int#, Int#, Int #)
g () = (# 0#, 0#, 0 #)
| null | https://raw.githubusercontent.com/ghc/ghc/bed3a292df532935426987e1f0c5eaa4f605407e/testsuite/tests/bytecode/T23068.hs | haskell | # LANGUAGE MagicHash , UnboxedTuples #
module T23068 where
import GHC.Exts
f :: () -> (# Int, Int #)
f () = (# 0, 0 #)
g :: () -> (# Int#, Int#, Int #)
g () = (# 0#, 0#, 0 #)
| |
2fb918f3e5d5e491e18c17d4b3c2354baaec2750f0661d4e464d433763de127e | jobjo/popper | fail_with_location.ml | open Popper
type int_list = int list [@@deriving show, ord, popper]
let test_rev =
test @@ fun () ->
equal ~loc:__LOC__ int_list_comparator (List.rev [ 1; 2; 3 ]) [ 2; 3; 1 ]
let () = Clean.run test_rev
| null | https://raw.githubusercontent.com/jobjo/popper/32c1ce0ff5ea24a5d3402f08c7966281521d5d57/test/expect/fail_with_location.ml | ocaml | open Popper
type int_list = int list [@@deriving show, ord, popper]
let test_rev =
test @@ fun () ->
equal ~loc:__LOC__ int_list_comparator (List.rev [ 1; 2; 3 ]) [ 2; 3; 1 ]
let () = Clean.run test_rev
| |
953f287c619328e95971db557245cf57886d5c3670b7472bdb81a3b03cbf638f | triffon/fp-2022-23 | 03-signum.rkt | #lang racket
(define (signum number)
(cond
((< number 0) -1)
((= number 0) 0)
((> number 0) 1))) | null | https://raw.githubusercontent.com/triffon/fp-2022-23/83f5f63c671ef3fbdb68fdfc7eb3f69a458f7f73/exercises/inf2/01/03-signum.rkt | racket | #lang racket
(define (signum number)
(cond
((< number 0) -1)
((= number 0) 0)
((> number 0) 1))) | |
69dcbe911f2502457d49e3e2a459a260a2c440d010113d0b16107610650ed932 | 2600hz/kazoo | kazoo_bindings_app.erl | %%%-----------------------------------------------------------------------------
( C ) 2014 - 2020 , 2600Hz
%%% @doc
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 /.
%%%
%%% @end
%%%--------... | null | https://raw.githubusercontent.com/2600hz/kazoo/24519b9af9792caa67f7c09bbb9d27e2418f7ad6/core/kazoo_bindings/src/kazoo_bindings_app.erl | erlang | -----------------------------------------------------------------------------
@doc
@end
-----------------------------------------------------------------------------
------------------------------------------------------------------------------
@doc Implement the application start behaviour.
@end
-----------------... | ( C ) 2014 - 2020 , 2600Hz
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 /.
-module(kazoo_bindings_app).
-behaviour(application).
-include_lib("kazoo_stdlib/include/kz_types.hrl").
-expor... |
a32d26d839a627e1c30d9c7f8d27a7d8ad74f0af196ed45968edba8dedb3ed67 | caradoc-org/caradoc | runlength.ml | (*****************************************************************************)
(* Caradoc: a PDF parser and validator *)
Copyright ( C ) 2015 ANSSI
Copyright ( C ) 2015 - 2017
(* ... | null | https://raw.githubusercontent.com/caradoc-org/caradoc/100f53bc55ef682049e10fabf24869bc019dc6ce/src/stream/runlength.ml | ocaml | ***************************************************************************
Caradoc: a PDF parser and validator
This program is free software; you can redistribute it and/or modify
... | Copyright ( C ) 2015 ANSSI
Copyright ( C ) 2015 - 2017
it under the terms of the GNU General Public License version 2 as
published by the Free Software Foundation .
You should have rece... |
a3e9954f4c120d1d3ea44673544b8dd09369d28aa5425121dabd2dc92ced396c | danilkolikov/dfl | ToSimpleClassTest.hs | |
Module : Frontend . Desugaring . Initial . ToSimpleClassTest
Description : Tests for desugaring of object to SimpleClass - s
Copyright : ( c ) , 2019
License : MIT
Test suite for desugaring of objects to SimpleClass - s
Module : Frontend.Desugaring.Initial.ToSimpleClassTes... | null | https://raw.githubusercontent.com/danilkolikov/dfl/698a8f32e23b381afe803fc0e353293a3bf644ba/test/Frontend/Desugaring/Initial/ToSimpleClassTest.hs | haskell | |
Module : Frontend . Desugaring . Initial . ToSimpleClassTest
Description : Tests for desugaring of object to SimpleClass - s
Copyright : ( c ) , 2019
License : MIT
Test suite for desugaring of objects to SimpleClass - s
Module : Frontend.Desugaring.Initial.ToSimpleClassTes... | |
7312b004c728cd5ba83c6f333e6e96b1a5c456c9310b4c0f410340fc4f07f96b | input-output-hk/plutus-apps | Chain.hs | {-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveAnyClass #-}
{-# LANGUAGE FlexibleContexts #-}
# LANGUAGE GADTs #
# LANGUAGE LambdaCase #
# LANGUAGE NamedFieldPuns #
{-# LANGUAGE RankNTypes #-}
# LANGUAGE ScopedTypeVariables #
# LANGUAGE TemplateHaskell #
# L... | null | https://raw.githubusercontent.com/input-output-hk/plutus-apps/8706e6c7c525b4973a7b6d2ed7c9d0ef9cd4ef46/plutus-pab/src/Cardano/Chain.hs | haskell | # LANGUAGE DataKinds #
# LANGUAGE DeriveAnyClass #
# LANGUAGE FlexibleContexts #
# LANGUAGE RankNTypes #
# LANGUAGE TypeOperators #
Skip showing the full chain
Get the current tip or wait for one if there are no blocks.
Wait for the initial block.
| Fetch the currently stored chain ... | # LANGUAGE GADTs #
# LANGUAGE LambdaCase #
# LANGUAGE NamedFieldPuns #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE TemplateHaskell #
# LANGUAGE TypeApplications #
module Cardano.Chain where
import Cardano.Node.Emulator.Chain qualified as EC
import Cardano.Node.Emulator.Params (... |
80a26ed28185eef8f9be6fffe1fde475e37531a343976f5ea630f179d33e5cb0 | aeternity/aesim | aesim_scenario_gossip_time.erl | -module(aesim_scenario_gossip_time).
%% @doc Default simulation scenario.
%%
%% - Starts a cluster of configurable size.
%% - Wait for all nodes to know a configurable percentage of the other nodes.
%% - Start a single node and measure the time for it to get to know a
%% configurable percentage of the other nodes.
... | null | https://raw.githubusercontent.com/aeternity/aesim/20d89621a0994e1b6cf2b766d188ec29283e77e1/src/scenarios/aesim_scenario_gossip_time.erl | erlang | @doc Default simulation scenario.
- Starts a cluster of configurable size.
- Wait for all nodes to know a configurable percentage of the other nodes.
- Start a single node and measure the time for it to get to know a
configurable percentage of the other nodes.
Configuration:
- `gossip_percent`: The percentag... | -module(aesim_scenario_gossip_time).
- Repeate multiple times and report the min / average / median / max time .
- ` start_period ` : The period between new nodes are started ; default : 30s .
- ` max_nodes ` : The maximum number of node that get started ; default : 150 .
-behaviour(aesim_scenario).
-include_... |
be23acb6530502d2d38293825bd8f09e4cfab7dceda6060867f15afd985582af | technomancy/leiningen | run.clj | (ns leiningen.test.run
(:require [leiningen.core.project :as project]
[leiningen.javac]
[clojure.java.io :as io]
[leiningen.test.helper :as helper
:refer [bad-require-project tmp-dir tricky-name-project
java-main-project file-not-found-thrower-proj... | null | https://raw.githubusercontent.com/technomancy/leiningen/24fb93936133bd7fc30c393c127e9e69bb5f2392/test/leiningen/test/run.clj | clojure | Do show a relevant error message
To avoid os-specific newline handling
Regression test for
testing that the true exception is printed immediately and
the inappropriate error message "Can't find
please check the spelling." is not | (ns leiningen.test.run
(:require [leiningen.core.project :as project]
[leiningen.javac]
[clojure.java.io :as io]
[leiningen.test.helper :as helper
:refer [bad-require-project tmp-dir tricky-name-project
java-main-project file-not-found-thrower-proj... |
54950474a25090c3cd7ebff9e8f33c3c3cfcaa2d744f768a0b9b1bfb8acb1ad6 | gfngfn/Sesterl | list2.mli |
type 'a t
* [ ' a t ] is the type for lists ( of values of type [ ' a ] ) the length of which is more than or equal to 2 .
val make : 'a -> 'a -> 'a list -> 'a t
(** [make e1 e2 es] corresponds to [e1 :: e2 :: es]. *)
val map : ('a -> 'b) -> 'a t -> 'b t
val map_and_fold : ('c -> 'a -> 'c * 'b) -> 'c -> 'a t -> 'c ... | null | https://raw.githubusercontent.com/gfngfn/Sesterl/3f7ded3d97bb5671e6b526d3e48236f53590d426/src/list2.mli | ocaml | * [make e1 e2 es] corresponds to [e1 :: e2 :: es].
* [to_list] forgets the constraint of the length. |
type 'a t
* [ ' a t ] is the type for lists ( of values of type [ ' a ] ) the length of which is more than or equal to 2 .
val make : 'a -> 'a -> 'a list -> 'a t
val map : ('a -> 'b) -> 'a t -> 'b t
val map_and_fold : ('c -> 'a -> 'c * 'b) -> 'c -> 'a t -> 'c * 'b t
val to_list : 'a t -> 'a list
val decompose : '... |
e4d57002fd1ca269fe4470177b859bc2336a8d78844ddb978fac81654cd01782 | tech-sketch/functional_programming_parallelism_sample | project.clj | (defproject par2 "0.1"
:description "clojure parallelism sample (clojure.core.reducers)"
:url "-sketch.jp"
:license {:name "GNU GPL V3"
:url "/"}
:dependencies [[org.clojure/clojure "1.5.1"]
[org.atilika.kuromoji/kuromoji "0.7.7"]]
:repositories [["Atilika Open Source repository" ... | null | https://raw.githubusercontent.com/tech-sketch/functional_programming_parallelism_sample/7d045754363aaa7768e2732dba13cd56ccab120f/clojure/par2/project.clj | clojure | (defproject par2 "0.1"
:description "clojure parallelism sample (clojure.core.reducers)"
:url "-sketch.jp"
:license {:name "GNU GPL V3"
:url "/"}
:dependencies [[org.clojure/clojure "1.5.1"]
[org.atilika.kuromoji/kuromoji "0.7.7"]]
:repositories [["Atilika Open Source repository" ... | |
30c2a751754a97637d50da589664a898a86b19320e991bcba00a7da6c2d08fc7 | cloudant-labs/dreyfus | dreyfus_fabric_search.erl | 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
distributed under the License is distributed on an " AS ... | null | https://raw.githubusercontent.com/cloudant-labs/dreyfus/243d451a1f8c941bdfbeceb983419cba8e540c0b/src/dreyfus_fabric_search.erl | erlang | 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
WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
License for the specific language governing permissions and limitations u... | Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not
distributed under the License is distributed on an " AS IS " BASIS , WITHOUT
-*- erlang - indent - level : 4;indent - tabs - mode : nil -*-
-module(dreyfus_fabric_search).
-include("dreyfus.hrl").
-include_lib("mem3/include/mem3... |
f0afaa13c82741b33953c48ba2022ca2a5882f735da6808fa0589696360c3b25 | blindglobe/lisp-matrix | unittests-matrix-view.lisp | ;;; -*- mode: lisp -*-
Copyright ( c ) 2007 , by < >
;;; See COPYRIGHT file for any additional restrictions (BSD license).
Since 1991 , ANSI was finally finished . Edited for ANSI Common Lisp .
;;; This is semi-external to lisp-matrix core package. The dependency
;;; should be that lisp-matrix packages are d... | null | https://raw.githubusercontent.com/blindglobe/lisp-matrix/f9c88dae132baf52884dd54612581d1331b82b40/src/unittests/unittests-matrix-view.lisp | lisp | -*- mode: lisp -*-
See COPYRIGHT file for any additional restrictions (BSD license).
This is semi-external to lisp-matrix core package. The dependency
should be that lisp-matrix packages are dependencies for the unit
tests. However, where they will end up is still to be
determined.
TEST SUITES
SUPPORT FUNCTI... | Copyright ( c ) 2007 , by < >
Since 1991 , ANSI was finally finished . Edited for ANSI Common Lisp .
(in-package :lisp-matrix-unittests)
See file : test.lisp in this directory for debugging with LIFT .
EXTERNAL
(deftestsuite lisp-matrix-ut-matrix-views (lisp-matrix-ut-matrix) ())
(addtest (lisp-m... |
8e124c11483dea8263c1183af08b84b7d2ea6dfa837ca300897d53bdb958ef9e | rabbitmq/ra-kv-store | rakvstore.clj | Copyright ( c ) 2018 Pivotal Software Inc , All Rights Reserved .
;;
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
;; you may not use this file except in compliance with the License.
;; You may obtain a copy of the License at
;;
;; -2.0
;;
;; Unless required by applicable law or agreed... | null | https://raw.githubusercontent.com/rabbitmq/ra-kv-store/0e27d530d565356dacf6a5ab851ce1c7b57292ab/jepsen/jepsen.rakvstore/src/main/clojure/jepsen/rakvstore.clj | clojure |
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 p... | Copyright ( c ) 2018 Pivotal Software Inc , All Rights Reserved .
distributed under the License is distributed on an " AS IS " BASIS ,
(ns jepsen.rakvstore
(:require [clojure.tools.logging :refer :all]
[clojure.string :as str]
[knossos.model :as model]
[slingshot.slingshot :refer [try+]]
... |
f4ec1bea9599bd08662c5eed9fbf0776e846af594360381036dfce342463c989 | jumarko/web-development-with-clojure | user.clj | (ns user
(:require [mount.core :as mount]
reporting-examples.core))
(defn start []
(mount/start-without #'reporting-examples.core/http-server
#'reporting-examples.core/repl-server))
(defn stop []
(mount/stop-except #'reporting-examples.core/http-server
#'r... | null | https://raw.githubusercontent.com/jumarko/web-development-with-clojure/dfff6e40c76b64e9fcd440d80c7aa29809601b6b/examples/reporting-examples/env/dev/clj/user.clj | clojure | (ns user
(:require [mount.core :as mount]
reporting-examples.core))
(defn start []
(mount/start-without #'reporting-examples.core/http-server
#'reporting-examples.core/repl-server))
(defn stop []
(mount/stop-except #'reporting-examples.core/http-server
#'r... | |
1928cca09334db861957cde3df35d4056ab6bc25f705141c2c5ceb281e97d32d | fyquah/hardcaml_zprize | merge_axi_streams.ml | open Core
open Hardcaml
open Signal
module Axi512 = Hardcaml_axi.Axi512
module Make (Config : Config.S) = struct
module I = struct
type 'a t =
{ clock : 'a
; clear : 'a
; host_scalars_to_fpga : 'a Axi512.Stream.Source.t
[@rtlprefix "host_scalars_to_fpga$src$"]
; ddr_points_to_f... | null | https://raw.githubusercontent.com/fyquah/hardcaml_zprize/553b1be10ae9b977decbca850df6ee2d0595e7ff/zprize/msm_pippenger/hardcaml/src/merge_axi_streams.ml | ocaml | combinationally pass through the points stream
it's fine to just take tlast from the point stream because they should be in lock-step | open Core
open Hardcaml
open Signal
module Axi512 = Hardcaml_axi.Axi512
module Make (Config : Config.S) = struct
module I = struct
type 'a t =
{ clock : 'a
; clear : 'a
; host_scalars_to_fpga : 'a Axi512.Stream.Source.t
[@rtlprefix "host_scalars_to_fpga$src$"]
; ddr_points_to_f... |
e37b3dee92502d7b3b70368c67cfda9d452e3de52403b4d1d11fe01c6e73c1d4 | arrdem/sad | jnw_ebnf.clj | (ns ^{:doc "An implementation of a lexer, parser and code gen for EBNF as
used in The Pascal User Manual and Report 4th ed. by Wirth and
Jensen. Hence the name jnw-ebnf."
:author "Reid McKenzie"
:added "0.1.0"}
me.arrdem.sad.grammars.jnw-ebnf
(:require [lexington.lexer ... | null | https://raw.githubusercontent.com/arrdem/sad/11aca91ec38009069d6d7f50de7fd2326cc627b8/src/me/arrdem/sad/grammars/jnw_ebnf.clj | clojure | ------------------------------------------------------------------------------
Declare & define productions
------------------------------------------------------------------------------
And throw a run interface on this grammar | (ns ^{:doc "An implementation of a lexer, parser and code gen for EBNF as
used in The Pascal User Manual and Report 4th ed. by Wirth and
Jensen. Hence the name jnw-ebnf."
:author "Reid McKenzie"
:added "0.1.0"}
me.arrdem.sad.grammars.jnw-ebnf
(:require [lexington.lexer ... |
e597f3f164d538e1725ce24ea2898d918be233d2cf4c46c1d5516563b9c1586d | ocaml-multicore/ocaml-tsan | open_arg.ml | (* TEST
flags = "-dshape"
* expect
*)
module type Make = functor (I : sig end) -> sig
open I
end
;;
[%%expect{|
{
"Make"[module type] -> <.1>;
}
module type Make = functor (I : sig end) -> sig end
|}]
module Make (I : sig end) : sig
open I
end = struct end
;;
[%%expect{|
{
"Make"[module] -> Abs<.3>(I/2... | null | https://raw.githubusercontent.com/ocaml-multicore/ocaml-tsan/f54002470cc6ab780963cc81b11a85a820a40819/testsuite/tests/shapes/open_arg.ml | ocaml | TEST
flags = "-dshape"
* expect
|
module type Make = functor (I : sig end) -> sig
open I
end
;;
[%%expect{|
{
"Make"[module type] -> <.1>;
}
module type Make = functor (I : sig end) -> sig end
|}]
module Make (I : sig end) : sig
open I
end = struct end
;;
[%%expect{|
{
"Make"[module] -> Abs<.3>(I/280, {
});... |
61c3ef47d4f4d5c41b38f779f0591d1889c154c64ec307335931c6f9e59deaa7 | HunterYIboHu/htdp2-solution | ex211-in-dict.rkt | The first three lines of this file were inserted by . They record metadata
;; about the language level of this file in a form that our tools can easily process.
#reader(lib "htdp-beginner-abbr-reader.ss" "lang")((modname ex211-in-dict) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeatin... | null | https://raw.githubusercontent.com/HunterYIboHu/htdp2-solution/6182b4c2ef650ac7059f3c143f639d09cd708516/Chapter2/Section13-project-list/ex211-in-dict.rkt | racket | about the language level of this file in a form that our tools can easily process.
constants
data difinitions
A Word is one of:
- '() or
- (cons 1String Word)
A Dictionary is a List-of-strings
(define DICTIONARY-AS-LIST-S (read-lines SMALL-DIC))
- "a"
- ...
- "z"
or, equivalently, a member? of this list:
ma... | The first three lines of this file were inserted by . They record metadata
#reader(lib "htdp-beginner-abbr-reader.ss" "lang")((modname ex211-in-dict) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #f #t none #f () #f)))
(require 2htdp/batch-io)
(define DICTIONARY-LOCATIO... |
fc70a84a6a5078ef117c94e86b6ab213ca66409a20703c0eb7dbbb910a21fed9 | irastypain/sicp-on-language-racket | exercise_2_33.rkt | #lang racket
(require (only-in "../lib/lists.rkt"
accumulate))
Отображение последовательности
(define (map p sequence)
(accumulate (lambda (x y) (cons (p x) y)) `() sequence))
последовательностей
(define (append seq1 seq2)
(accumulate cons seq2 seq1))
Длина последовательности
(define (l... | null | https://raw.githubusercontent.com/irastypain/sicp-on-language-racket/0052f91d3c2432a00e7e15310f416cb77eeb4c9c/src/chapter02/exercise_2_33.rkt | racket | #lang racket
(require (only-in "../lib/lists.rkt"
accumulate))
Отображение последовательности
(define (map p sequence)
(accumulate (lambda (x y) (cons (p x) y)) `() sequence))
последовательностей
(define (append seq1 seq2)
(accumulate cons seq2 seq1))
Длина последовательности
(define (l... | |
9ce7b01006ee0f873802bb68301030efcab3bc92195a936666fcf2ad7c9ed756 | blynn/compiler | Base1.hs | -- Use `deriving`.
Change ` isEOF ` and ` getChar ` to behave more like 's .
module Base where
infixr 9 .
infixl 7 * , `div` , `mod`
infixl 6 + , -
infixr 5 ++
infixl 4 <*> , <$> , <* , *>
infix 4 == , /= , <= , < , >= , >
infixl 3 && , <|>
infixl 2 ||
infixl 1 >> , >>=
infixr 1 =<<
infixr 0 $
class Functor f wher... | null | https://raw.githubusercontent.com/blynn/compiler/a459e11fea0b726e0fbde5f3224856caddfa4503/inn/Base1.hs | haskell | Use `deriving`. | Change ` isEOF ` and ` getChar ` to behave more like 's .
module Base where
infixr 9 .
infixl 7 * , `div` , `mod`
infixl 6 + , -
infixr 5 ++
infixl 4 <*> , <$> , <* , *>
infix 4 == , /= , <= , < , >= , >
infixl 3 && , <|>
infixl 2 ||
infixl 1 >> , >>=
infixr 1 =<<
infixr 0 $
class Functor f where fmap :: (a -> b) ... |
344dec767a19d495904a0825da237de7b481d96a78dd42923d37a9910668e189 | roman01la/cljs-rum-realworld-example-app | tags.cljs | (ns conduit.controllers.tags)
(def initial-state
[])
(defmulti control (fn [event] event))
(defmethod control :default [_ _ state]
{:state state})
(defmethod control :init []
{:state initial-state})
(defmethod control :load [_ _ state]
{:http {:endpoint :tags
:on-load :load-ready}})
(defmethod ... | null | https://raw.githubusercontent.com/roman01la/cljs-rum-realworld-example-app/962695bd391806a7066340461c3e02f2215fdc48/src/conduit/controllers/tags.cljs | clojure | (ns conduit.controllers.tags)
(def initial-state
[])
(defmulti control (fn [event] event))
(defmethod control :default [_ _ state]
{:state state})
(defmethod control :init []
{:state initial-state})
(defmethod control :load [_ _ state]
{:http {:endpoint :tags
:on-load :load-ready}})
(defmethod ... | |
982d78225bebd360137138cc02736162d2579a199b40a6f9790459804580e1f3 | jimcrayne/jhc | tc125.hs | {-# OPTIONS_GHC -fglasgow-exts #-}
# LANGUAGE UndecidableInstances #
UndecidableInstances now needed because the Coverage Condition fails
! ! ! Functional dependency test . Hugs [ Apr 2001 ] fails to typecheck this
-- We should infer this type for foo
foo : : Q ( S ( S Z ) ) ( S Z )
module ShouldCompile where
... | null | https://raw.githubusercontent.com/jimcrayne/jhc/1ff035af3d697f9175f8761c8d08edbffde03b4e/regress/tests/1_typecheck/2_pass/ghc/tc125.hs | haskell | # OPTIONS_GHC -fglasgow-exts #
We should infer this type for foo
Problem here. This is the addition of rational
numbers: (a/b) + (c/d) = (ad+bc)/bd | # LANGUAGE UndecidableInstances #
UndecidableInstances now needed because the Coverage Condition fails
! ! ! Functional dependency test . Hugs [ Apr 2001 ] fails to typecheck this
foo : : Q ( S ( S Z ) ) ( S Z )
module ShouldCompile where
data Z = Z
data S a = S a
class Add a b c | a b -> c where add :: a -> ... |
8a58c794b3b582d5623158919682fc949bdfabd1a2d81143f925507a499d2a18 | tweag/ormolu | type-family-instances.hs | # LANGUAGE TypeFamilies #
type instance Foo Int = Int
type instance
Foo
[Int] = ( Int,
Int
)
type instance Bar Int [Int] Double = ( Int, Double )
type instance
Bar
[Int]
[Int]
Double
= (
Int,
Double
)
| null | https://raw.githubusercontent.com/tweag/ormolu/34bdf62429768f24b70d0f8ba7730fc4d8ae73ba/data/examples/declaration/instance/type-family-instances.hs | haskell | # LANGUAGE TypeFamilies #
type instance Foo Int = Int
type instance
Foo
[Int] = ( Int,
Int
)
type instance Bar Int [Int] Double = ( Int, Double )
type instance
Bar
[Int]
[Int]
Double
= (
Int,
Double
)
| |
6d9e82d97066a666df45dbcd55b489ceb1a5fff54e8178f151304231b0627422 | termite-analyser/termite | lp.mli | (**
Module used for LP solving.
*)
(**
[lp c cons_I] solves the LP(c, cons_I) instance and returns [lambda] and [delta].
*)
val lp_one_control_point : ?verbose:bool -> Q.t array list -> Z.t array array -> (Q.t array * Q.t array)
| null | https://raw.githubusercontent.com/termite-analyser/termite/285d92215a28fcce55614f6d04b44886f253a894/src/lp.mli | ocaml | *
Module used for LP solving.
*
[lp c cons_I] solves the LP(c, cons_I) instance and returns [lambda] and [delta].
|
val lp_one_control_point : ?verbose:bool -> Q.t array list -> Z.t array array -> (Q.t array * Q.t array)
|
ebea400fc74c3be600ae27126837a4ba2b6bf92748004911b6b0bf038e00245d | andorp/bead | Pages.hs | # LANGUAGE CPP #
# LANGUAGE DeriveFunctor #
module Bead.Controller.Pages where
import Control.Monad (join)
import qualified Bead.Domain.Entities as E
import Bead.Domain.Relationships as R
#ifdef TEST
import Control.Applicative
import Test.Tasty.TestSet
import Te... | null | https://raw.githubusercontent.com/andorp/bead/280dc9c3d5cfe1b9aac0f2f802c705ae65f02ac2/src/Bead/Controller/Pages.hs | haskell | View pages are rendered using the data stored in the
persistence layer. Mainly for information propagation
for the user.
login
logout
home
evaluationTable
viewAssignment
administration
courseAdmin
viewAssessment
notifications
Pages that extract information from the persistence
and all the data will be ren... | # LANGUAGE CPP #
# LANGUAGE DeriveFunctor #
module Bead.Controller.Pages where
import Control.Monad (join)
import qualified Bead.Domain.Entities as E
import Bead.Domain.Relationships as R
#ifdef TEST
import Control.Applicative
import Test.Tasty.TestSet
import Te... |
210fc46c9853009d7db1165f1918fa8ccc07b5e2aee47c12616cca17a763eac2 | ucsd-progsys/liquid-sf | SearchTree.hs | {-@ LIQUID "--exact-data-con" @-}
{-@ LIQUID "--higherorder" @-}
{-@ LIQUID "--totality" @-}
{- LIQUID "--automatic-instances=liquidinstances" @-}
{- LIQUID "--diff" @-}
module SearchTree where
import Language.Hask... | null | https://raw.githubusercontent.com/ucsd-progsys/liquid-sf/10f864e0521ef5920bb35af40a14c086f94370dd/SearchTree.hs | haskell | @ LIQUID "--exact-data-con" @
@ LIQUID "--higherorder" @
@ LIQUID "--totality" @
LIQUID "--automatic-instances=liquidinstances" @
LIQUID "--diff" @
| Options --------------------------------------------------------... |
module SearchTree where
import Language.Haskell.Liquid.ProofCombinators
import Prelude hiding (max)
data Option a = None | Some a
@ data Map [ size ] k v =
Leaf
| Node { mKey : : k
, mVal : : v
, mLeft : : Map k v
, mRigsize : : Map k v }
@
L... |
619f3bfbc2b64870d483cdd581bf890331d07bc2407f4f083b006dfd16ddcc83 | tarides/opam-monorepo | parallel.mli | val map : f:('a -> 'b) -> 'a list -> 'b list
* [ map ~f lst ] Applies f to each element of lst and returns the resulting list .
This is done concurrently using threads , so f needs to be thread - safe . Also
the list order might not be preserved .
This is done concurrently using threads, so f needs to b... | null | https://raw.githubusercontent.com/tarides/opam-monorepo/9262e7f71d749520b7e046fbd90a4732a43866e9/lib/parallel.mli | ocaml | val map : f:('a -> 'b) -> 'a list -> 'b list
* [ map ~f lst ] Applies f to each element of lst and returns the resulting list .
This is done concurrently using threads , so f needs to be thread - safe . Also
the list order might not be preserved .
This is done concurrently using threads, so f needs to b... | |
990e73baaa2b2191e5c4527e94e5e16d740c8f7788073f64728a4b664c29300b | racket/web-server | digest-auth-test.rkt | #lang racket
(require rackunit
web-server/http
net/url)
(provide digest-auth-tests)
(module+ main
(require rackunit/text-ui)
(run-tests digest-auth-tests))
(define RFC-Example-bytes
(string->bytes/utf-8 #<<END
Digest username="Mufasa",
realm="",
nonc... | null | https://raw.githubusercontent.com/racket/web-server/f718800b5b3f407f7935adf85dfa663c4bba1651/web-server-test/tests/web-server/http/digest-auth-test.rkt | racket | #lang racket
(require rackunit
web-server/http
net/url)
(provide digest-auth-tests)
(module+ main
(require rackunit/text-ui)
(run-tests digest-auth-tests))
(define RFC-Example-bytes
(string->bytes/utf-8 #<<END
Digest username="Mufasa",
realm="",
nonc... | |
e79833d1d9dc1ee5885f3faf5f63180af802823338e7b6d7b4ee94e8fdcdd72e | amnh/PCG | Class.hs | -----------------------------------------------------------------------------
-- |
-- Module : Bio.Metadata.Dynamic.Class
Copyright : ( c ) 2015 - 2021 Ward Wheeler
-- License : BSD-style
--
-- Maintainer :
-- Stability : provisional
-- Portability : portable
--
--------------------------------... | null | https://raw.githubusercontent.com/amnh/PCG/9341efe0ec2053302c22b4466157d0a24ed18154/lib/core/data-structures/src/Bio/Metadata/Dynamic/Class.hs | haskell | ---------------------------------------------------------------------------
|
Module : Bio.Metadata.Dynamic.Class
License : BSD-style
Maintainer :
Stability : provisional
Portability : portable
---------------------------------------------------------------------------
# LANGUAGE FlexibleConte... | Copyright : ( c ) 2015 - 2021 Ward Wheeler
# LANGUAGE FlexibleInstances #
# LANGUAGE FunctionalDependencies #
# LANGUAGE MultiParamTypeClasses #
module Bio.Metadata.Dynamic.Class
( DenseTransitionCostMatrix
, GetDenseTransitionCostMatrix(..)
, GetSymbolChangeMatrix(..)
, GetPairwiseTransitionCo... |
95fc1d267b9759c293f88909ac813a38e17ba1c5d7aca6203d93fc73856325d2 | static-analysis-engineering/codehawk | jCHParse.mli | = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
CodeHawk Java Analyzer
Author : ------------------------------------------------------------------------------
The MIT License ( MIT )
Copy... | null | https://raw.githubusercontent.com/static-analysis-engineering/codehawk/98ced4d5e6d7989575092df232759afc2cb851f6/CodeHawk/CHJ/jchlib/jCHParse.mli | ocaml | jchlib
Code
method_info
field_info | = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
CodeHawk Java Analyzer
Author : ------------------------------------------------------------------------------
The MIT License ( MIT )
Copy... |
8cbec59612b3a44b999c9a804e05a39ae092112a081b818b159da726964907bc | xapi-project/xen-api | xapi_vm.mli |
* Copyright ( C ) 2006 - 2009 Citrix Systems Inc.
*
* This program is free software ; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation ; version 2.1 only . with the special
* exception on linking describe... | null | https://raw.githubusercontent.com/xapi-project/xen-api/e8c3575316226ac6324e94aa4f9e040a662e279a/ocaml/xapi/xapi_vm.mli | ocaml | * Module that defines API functions for VM objects
* @group XenAPI functions
* Copy the BIOS strings from a host to the VM, unless the VM's BIOS strings
* had already been set.
* [query_services __context self] returns a Map of service type -> name label provided
by the specific VM. |
* Copyright ( C ) 2006 - 2009 Citrix Systems Inc.
*
* This program is free software ; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation ; version 2.1 only . with the special
* exception on linking describe... |
913fb74235288681ff19976e5f62489e87e43aa6a14637394cac15d4d2182f99 | NorfairKing/sydtest | Synchronous.hs | module Test.Syd.Runner.Synchronous
( runSpecForestSynchronously,
runSpecForestInterleavedWithOutputSynchronously,
)
where
import Test.Syd.Runner.Synchronous.Interleaved
import Test.Syd.Runner.Synchronous.Separate
| null | https://raw.githubusercontent.com/NorfairKing/sydtest/61f8cc4bc010140cca1613b9aee173c87e3cfe9d/sydtest/src/Test/Syd/Runner/Synchronous.hs | haskell | module Test.Syd.Runner.Synchronous
( runSpecForestSynchronously,
runSpecForestInterleavedWithOutputSynchronously,
)
where
import Test.Syd.Runner.Synchronous.Interleaved
import Test.Syd.Runner.Synchronous.Separate
| |
a54899105f8de47560fe1a46c87312d5c51e870c0f62012bdae48d2967802dba | rmloveland/scheme48-0.53 | annotate.scm | Copyright ( c ) 1993 - 1999 by and . See file COPYING .
; Derived from
( lambda ( x y ) ( cons ( car x ) ) ) )
(define annotate-procedure
(lap annotate-procedure ()
0 (check-nargs= 2)
2 (make-env 2)
4 (local0 2)
6 (stored-object-ref closure 0)
9 (push)
10 (loc... | null | https://raw.githubusercontent.com/rmloveland/scheme48-0.53/1ae4531fac7150bd2af42d124da9b50dd1b89ec1/scheme/misc/annotate.scm | scheme | Derived from
Derived from | Copyright ( c ) 1993 - 1999 by and . See file COPYING .
( lambda ( x y ) ( cons ( car x ) ) ) )
(define annotate-procedure
(lap annotate-procedure ()
0 (check-nargs= 2)
2 (make-env 2)
4 (local0 2)
6 (stored-object-ref closure 0)
9 (push)
10 (local0 2)
1... |
fd235ea0c9089e013d972ebda70f60b7138b6fa3ab27e2120f973cf7d4650e8b | TheLortex/mirage-monorepo | ppxlib_metaquot_lifters.ml | open Stdppx
open Ppxlib
open Ast_builder.Default
class expression_lifters loc =
let loc = { loc with loc_ghost = true } in
object
inherit [expression] Ppxlib_traverse_builtins.lift
method record flds =
pexp_record ~loc
(List.map flds ~f:(fun (lab, e) -> ({ loc; txt = Lident lab }, e)))
... | null | https://raw.githubusercontent.com/TheLortex/mirage-monorepo/b557005dfe5a51fc50f0597d82c450291cfe8a2a/duniverse/ppxlib/metaquot_lifters/ppxlib_metaquot_lifters.ml | ocaml | open Stdppx
open Ppxlib
open Ast_builder.Default
class expression_lifters loc =
let loc = { loc with loc_ghost = true } in
object
inherit [expression] Ppxlib_traverse_builtins.lift
method record flds =
pexp_record ~loc
(List.map flds ~f:(fun (lab, e) -> ({ loc; txt = Lident lab }, e)))
... | |
30e1c00bbe5fec4fbd0681154f32b7f94ac0a133800f35e7183e3d8d36ade51c | exercism/haskell | Robot.hs | module Robot (Robot, initialState, mkRobot, resetName, robotName) where
import Control.Concurrent.MVar (MVar, newMVar, readMVar, swapMVar)
import Control.Monad (void)
import Control.Monad.State (StateT)
import Control.Monad.Trans (lift)
import System.... | null | https://raw.githubusercontent.com/exercism/haskell/ae17e9fc5ca736a228db6dda5e3f3b057fa6f3d0/exercises/practice/robot-name/.meta/examples/fail-no-collision-testing/src/Robot.hs | haskell | module Robot (Robot, initialState, mkRobot, resetName, robotName) where
import Control.Concurrent.MVar (MVar, newMVar, readMVar, swapMVar)
import Control.Monad (void)
import Control.Monad.State (StateT)
import Control.Monad.Trans (lift)
import System.... | |
15e286c743335368bf8eed4e3090c8146be527166a25512b5be9b91870ab4ba5 | racket/frtime | delay-mouse.rkt | #lang frtime
(require frtime/animation)
; the mouse position delayed
(display-shapes
(let* ([n 4]
[n-1 (sub1 n)])
(build-list
n
(lambda (i)
(make-circle (delay-by mouse-pos (* 200 (- n-1 i)))
(+ 7 i)
(make-rgb (/ (- n-1 i) n) (/ (- n-1 i) n) 1.0))))))
| null | https://raw.githubusercontent.com/racket/frtime/9b9db67581107f4d7b995541c70f2d08f03ae89e/demos/delay-mouse.rkt | racket | the mouse position delayed | #lang frtime
(require frtime/animation)
(display-shapes
(let* ([n 4]
[n-1 (sub1 n)])
(build-list
n
(lambda (i)
(make-circle (delay-by mouse-pos (* 200 (- n-1 i)))
(+ 7 i)
(make-rgb (/ (- n-1 i) n) (/ (- n-1 i) n) 1.0))))))
|
fd2364a925c255bceebb5ac25014496464dbed7fc45eef41c18577b47c0aa16c | zenunomacedo/Tetris | singleplayer.hs | module SinglePlayer where
variaveis globais
import Control.Concurrent (threadDelay)
import System.Random hiding (next)
import Control.Monad (when)
import Rotate
import Types
RENDER PRIMITIVE MAS NAO PODE DAR EXCEPTION SENAO FUGGG : EFICAZ xDedos
heigth :: GLsizei
heigthf :: GLfloat
heigthf = fromIntegral hei... | null | https://raw.githubusercontent.com/zenunomacedo/Tetris/2b9c660bb79001d553b592d80aa75dbb191b5baf/Tetris/singleplayer.hs | haskell | vert for game grid
horiz for game grid
vert for next piece
horiz for next piece
vert for stored piece
horiz for stored piece
ghosting the piece
|Desenha uma linha de quadrados
(GLfloat, GLfloat)
crandom = colours !! n
desloca as cenas na
no resizing
limpa as linhas | module SinglePlayer where
variaveis globais
import Control.Concurrent (threadDelay)
import System.Random hiding (next)
import Control.Monad (when)
import Rotate
import Types
RENDER PRIMITIVE MAS NAO PODE DAR EXCEPTION SENAO FUGGG : EFICAZ xDedos
heigth :: GLsizei
heigthf :: GLfloat
heigthf = fromIntegral hei... |
3741f8583bef5bf06b24618b51352a4aa6dc4f909b1e496227405f54de62920a | snapframework/snap-static-pages | Types.hs | # LANGUAGE GeneralizedNewtypeDeriving #
{-# LANGUAGE OverloadedStrings #-}
# OPTIONS_GHC -fno - warn - orphans #
module Snap.StaticPages.Internal.Types
( module Snap.StaticPages.Internal.Exception
, Post(..)
, getPostTime
, ContentMap
, ContentItem(..)
, StaticPages(..)
)
where
-------------... | null | https://raw.githubusercontent.com/snapframework/snap-static-pages/01a538e1885c9756cda6f65d231b9cdcad21827e/src/Snap/StaticPages/Internal/Types.hs | haskell | # LANGUAGE OverloadedStrings #
----------------------------------------------------------------------------
----------------------------------------------------------------------------
to make things super-easy on us, we'll define our internal post
^ a post
^ a path prefix + content
mapping
^ a static f... | # LANGUAGE GeneralizedNewtypeDeriving #
# OPTIONS_GHC -fno - warn - orphans #
module Snap.StaticPages.Internal.Types
( module Snap.StaticPages.Internal.Exception
, Post(..)
, getPostTime
, ContentMap
, ContentItem(..)
, StaticPages(..)
)
where
import Data.ByteString.Char8 (ByteString)
impor... |
7ac9f086fffff26f1b4e7f81b763166470e8bc8ea9f32329138cccf5d6f65121 | mzp/coq-ruby | unification.mli | (************************************************************************)
v * The Coq Proof Assistant / The Coq Development Team
< O _ _ _ , , * CNRS - Ecole Polytechnique - INRIA Futurs - Universite Paris Sud
\VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *... | null | https://raw.githubusercontent.com/mzp/coq-ruby/99b9f87c4397f705d1210702416176b13f8769c1/pretyping/unification.mli | ocaml | **********************************************************************
// * This file is distributed under the terms of the
* GNU Lesser General Public License Version 2.1
**********************************************************************
i
i
The "unique" unification foncti... | v * The Coq Proof Assistant / The Coq Development Team
< O _ _ _ , , * CNRS - Ecole Polytechnique - INRIA Futurs - Universite Paris Sud
\VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
i $ I d : unification.mli 1... |
014b23e178d81521e92e434c08d7b02d1fe0a5b025d611b85a256e5a9edbaecf | xh4/web-toolkit | object.lisp | (in-package :json)
(defclass object ()
((properties
:initarg :properties
:initform nil
:accessor object-properties)))
(defun object-form (object)
(check-type object object)
(labels ((value-expr (value)
(typecase value
(object
(let ((properties (slot-value ... | null | https://raw.githubusercontent.com/xh4/web-toolkit/e510d44a25b36ca8acd66734ed1ee9f5fe6ecd09/json/object.lisp | lisp | (in-package :json)
(defclass object ()
((properties
:initarg :properties
:initform nil
:accessor object-properties)))
(defun object-form (object)
(check-type object object)
(labels ((value-expr (value)
(typecase value
(object
(let ((properties (slot-value ... | |
4f5392fec593d20922836a0ef0333fd533d67f849bd77c34566c2b7773bd5ffb | svdm/ClojureGP | nth_exp.clj | 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/svdm/ClojureGP/266e501411b37297bdeb082913df63ececa8515c/examples/nth_exp.clj | clojure | 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 any other, from
this software.
The canonical STGP nth experiment ai... | Copyright ( c ) . All rights reserved .
The use and distribution terms for this software are covered by the Eclipse
(ns nth-exp
"Example 01: an attempt at evolving the nth function, similar to an experiment
in the original STGP article [1]. The design of that experiment is followed
quite closely... |
10b7d7f0013271022eca5e81675cf242fa64a84e6ae092cb6720eb7794c0266b | jrm-code-project/LISP-Machine | lmscreen-methods.lisp | -*- Mode : LISP ; Syntax : ; Package : DVI ; Base : 10 ; -*-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
This file contains the methods for translation of DVI commands
;; to display on the screen
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
... | null | https://raw.githubusercontent.com/jrm-code-project/LISP-Machine/0a448d27f40761fafabe5775ffc550637be537b2/lambda/gjc/dvi/lmscreen-methods.lisp | lisp | Syntax : ; Package : DVI ; Base : 10 ; -*-
to display on the screen
The following methods are defined.
:set-char
:set-rule
:put-char
:put-rule
:bop
:eop
:push - handled by document :push-stack method
:pop - handled by document :pop-stack method
:right
:w
... |
This file contains the methods for translation of DVI commands
(defflavor screen-dvi-document
(image-width
image-height
(origin-x 5)
(origin-y 5)
previous-page-ptr)
(document))
(defvar *screen-resolution* 160)
(defresource sheet-bit-array (w h)
:constru... |
c8e32678fd66adba11125a9efe0dd820140ffb9e34dfe767a500d347417b1237 | roburio/builder-web | router.ml |
module Param_verification = struct
(*> None is 'verified'*)
type t = wrong_type option
[@@deriving yojson,show,eq]
and wrong_type = {
param : string;
expected : string;
}
let alcotyp = Alcotest.testable pp equal
module P = struct
let is_string : (string * string) option -> _ option = f... | null | https://raw.githubusercontent.com/roburio/builder-web/f666c9d0d1065e94cd401a493bbbd658d0b5b838/test/router.ml | ocaml | > None is 'verified'
XXX: this relies on [Builder_web.routes] only using {data,cache,config}dir
* in the handlers which are never called here. The path /nonexistant is
* assumed to not exist.
XXX: we test without remove_trailing_url_slash to ensure we don't produce
* urls with trailing slashes:
this doesn... |
module Param_verification = struct
type t = wrong_type option
[@@deriving yojson,show,eq]
and wrong_type = {
param : string;
expected : string;
}
let alcotyp = Alcotest.testable pp equal
module P = struct
let is_string : (string * string) option -> _ option = function
| Some _ -> N... |
22d618ae943987eea2fc921843a5e6a70003709b7b225737586b9a0eb2ec134c | ml4tp/tcoq | retyping.mli | (************************************************************************)
v * The Coq Proof Assistant / The Coq Development Team
< O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2017
\VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *... | null | https://raw.githubusercontent.com/ml4tp/tcoq/7a78c31df480fba721648f277ab0783229c8bece/pretyping/retyping.mli | ocaml | **********************************************************************
// * This file is distributed under the terms of the
* GNU Lesser General Public License Version 2.1
**********************************************************************
* This family of functions assumes i... | v * The Coq Proof Assistant / The Coq Development Team
< O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2017
\VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
open Term
open Evd
open Envir... |
cceddd8b6feb226c44167dc6a1f7735d7c19b69cfc465bd0ababa48158fd64d7 | gilith/hol-light | struct_equal.ml | (******************************************************************************)
(* FILE : struct_equal.ml *)
DESCRIPTION : Proof procedure for simplifying an equation between two
(* data-structures of the same type. *... | null | https://raw.githubusercontent.com/gilith/hol-light/f3f131963f2298b4d65ee5fead6e986a4a14237a/Boyer_Moore/struct_equal.ml | ocaml | ****************************************************************************
FILE : struct_equal.ml
data-structures of the same type.
READS FILES... | DESCRIPTION : Proof procedure for simplifying an equation between two
AUTHOR : R.J.Boulton & T.F.Melham
DATE : 4th June 1992
LAST MODIFIED : R.J.Boulton
DAT... |
c610daf118cbcc5bc812f0fc8ca1849c0154f97262ee267da3d69e1920a28e19 | apache/couchdb-global-changes | global_changes_httpd.erl | 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
distributed under the License is distributed on an " AS ... | null | https://raw.githubusercontent.com/apache/couchdb-global-changes/4aa1fc4b20ee029c93e796309887d66432fdf959/src/global_changes_httpd.erl | erlang | 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
WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
License for the specific language governing permissions and limitations u... | Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not
distributed under the License is distributed on an " AS IS " BASIS , WITHOUT
-module(global_changes_httpd).
-export([handle_global_changes_req/1]).
-export([default_transform_change/2]).
-include_lib("couch/include/couch_db.hrl").
... |
301077c347a49f7b06c097df979180ae2ba00b246c166ab29f3bce32d5f5f04e | Lambda-Logan/faker | HackerSpec.hs | module Faker.HackerSpec where
import Faker.Hacker
import Helper
import Test.Hspec
spec :: Spec
spec = do
describe "saySomethingSmart" $
deterministicOutput saySomethingSmart
describe "abbreviation" $
deterministicOutput abbreviation
describe "adjective" $
deterministi... | null | https://raw.githubusercontent.com/Lambda-Logan/faker/8935346192e67631b97c1a52f6644ba5ed48a1a2/test/Faker/HackerSpec.hs | haskell | module Faker.HackerSpec where
import Faker.Hacker
import Helper
import Test.Hspec
spec :: Spec
spec = do
describe "saySomethingSmart" $
deterministicOutput saySomethingSmart
describe "abbreviation" $
deterministicOutput abbreviation
describe "adjective" $
deterministi... | |
ffd149ec486c7f2550101163a2fcaa936edf9f903bc63e6a8bcba59428342152 | kind2-mc/kind2 | lustreAstInlineConstants.ml | This file is part of the Kind 2 model checker .
Copyright ( c ) 2020 by the Board of Trustees of the University of Iowa
Licensed under the Apache License , Version 2.0 ( the " License " ) ; you
may not use this file except in compliance with the License . You
may obtain a copy of the License a... | null | https://raw.githubusercontent.com/kind2-mc/kind2/d34694b4461323322fdcc291aa3c3d9c453fc098/src/lustre/lustreAstInlineConstants.ml | ocaml | * [type_error] returns an [Error] of [tc_result]
* is the expression in a normal form?
* try and evalutate expression to int, return error otherwise
* try and evalutate binary op expression to int, return error otherwise
* try and evalutate expression to bool, return error otherwise
* try and evalutate binary op e... | This file is part of the Kind 2 model checker .
Copyright ( c ) 2020 by the Board of Trustees of the University of Iowa
Licensed under the Apache License , Version 2.0 ( the " License " ) ; you
may not use this file except in compliance with the License . You
may obtain a copy of the License a... |
8dfc7213b6a654bd3c83c7779a24da0c474da558264e32e3c7afd0b833d33c52 | John-Nagle/nqthm | sloop.lisp | ;;; -*- Mode:LISP; Package:(SLOOP LISP);Syntax:COMMON-LISP;Base:10 -*- ;;;;;
;;; ;;;;;
Copyright ( c ) 1985,86 by , ; ; ; ; ;
;;; All rights reserved ;;;;;
;;;;;;;;;;;;;;;;;;;;;... | null | https://raw.githubusercontent.com/John-Nagle/nqthm/aeafa016e424e9fba968a48bf7dab45ab96a3020/nqthm-1992/sloop.lisp | lisp | -*- Mode:LISP; Package:(SLOOP LISP);Syntax:COMMON-LISP;Base:10 -*- ;;;;;
;;;;;
; ; ; ;
All rights reserved ;;;;;
Report bugs to
It comes with ABSOLUTELY NO WARRANTY but we hope it is useful.
The fo... |
ANY changes to the file unless he is . He may change
( defmacro loop ( & body body ) ( parse - loop body ) )
Sloop is extremely user extensible so that you may easily redefine
.. v ..
( sloop for u in l with v = 0
Compile notes : For dec-20 clisp load the lisp file before compili... |
7e473929ab8b568e92a9d62449dc42257e4d213efec49bd822ba9c42dbecb2f1 | jtkDvlp/re-frame-readfile-fx | readfile_fx_test.cljs | (ns jtk-dvlp.re-frame.readfile-fx-test
(:require
[reagent.core :as reagent]
[re-frame.core :as re-frame]
[jtk-dvlp.re-frame.readfile-fx]))
(defn- col->array
[col]
(-> js/Array
.-prototype
.-slice
(.call col)))
(re-frame/reg-event-fx
:on-readfile-fx-success
(fn [_ [_ result]]
(... | null | https://raw.githubusercontent.com/jtkDvlp/re-frame-readfile-fx/fd05db2741488f45ea2b6a77da75b4f3d3ec49e8/test/jtk_dvlp/re_frame/readfile_fx_test.cljs | clojure | (ns jtk-dvlp.re-frame.readfile-fx-test
(:require
[reagent.core :as reagent]
[re-frame.core :as re-frame]
[jtk-dvlp.re-frame.readfile-fx]))
(defn- col->array
[col]
(-> js/Array
.-prototype
.-slice
(.call col)))
(re-frame/reg-event-fx
:on-readfile-fx-success
(fn [_ [_ result]]
(... | |
536f9184b3d28c6ae03e3bae04e28b368af9bbc7b3f3bd1cab835795f56c062b | herd/herdtools7 | ASLSem.ml | (****************************************************************************)
(* the diy toolsuite *)
(* *)
, University College London , UK .
, INRIA Par... | null | https://raw.githubusercontent.com/herd/herdtools7/daedd7431cb00884afea2ec39749222e2c367c6b/herd/ASLSem.ml | ocaml | **************************************************************************
the diy toolsuite
en Automatique and ... | , University College London , UK .
, INRIA Paris - Rocquencourt , France .
Copyright 2015 - present Institut National de Recherche en Informatique et
This software is governed by the CeCILL - B license under French law and
modify and/ or redistribu... |
4d1f5753fdecbc36d4fe3fdf83df1238f3a8bcc32677677f76cf59f14e13e544 | LdBeth/star-lisp | internal-addressing.lisp | ;; -*- Mode:Lisp; Syntax:Common-Lisp; Package: (*SIM-I COMMON-LISP-GLOBAL); Muser: yes -*-
(in-package :*sim-i)
;;;> *+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+
;;;>
;;;> The Thinking Machines *Lisp Simulator is in the public domain.
;;;> You are free to do whatever you l... | null | https://raw.githubusercontent.com/LdBeth/star-lisp/034fb97fe8780d6e9fbff7c1d8c4a6b8c331797b/source/internal-addressing.lisp | lisp | -*- Mode:Lisp; Syntax:Common-Lisp; Package: (*SIM-I COMMON-LISP-GLOBAL); Muser: yes -*-
> *+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+*+
>
> The Thinking Machines *Lisp Simulator is in the public domain.
> You are free to do whatever you like with it, including but
> not limi... |
(in-package :*sim-i)
> . Other than to Thinking Machines '
(defun vp-set-check (vp-set function-name)
(assert (vp-set-p vp-set) ()
"The vp set argument to the function ~S was not a vp set, but has the value ~A"
function-name vp-set
))
(defun validate-all-pvars (pvar-index-list function-name)
(... |
06d4db67309cf67bc4f37533fd29ed6dd03320d425b779bb66a84e8014acb24b | haskell/ThreadScope | KeyView.hs | module GUI.KeyView (
KeyView,
keyViewNew,
) where
import GUI.ViewerColours
import GUI.Timeline.Render.Constants
import Graphics.UI.Gtk
import qualified Graphics.UI.Gtk.ModelView.TreeView.Compat as Compat
import qualified Graphics.Rendering.Cairo as C
-------------------------------------------------------... | null | https://raw.githubusercontent.com/haskell/ThreadScope/8f51f5ca445ab335c6e2ac44f05c44ae6c48d5cc/GUI/KeyView.hs | haskell | -------------------------------------------------------------------------
| Abstract key view object.
-------------------------------------------------------------------------
-------------------------------------------------------------------------
--------------------------------------------------------------------... | module GUI.KeyView (
KeyView,
keyViewNew,
) where
import GUI.ViewerColours
import GUI.Timeline.Render.Constants
import Graphics.UI.Gtk
import qualified Graphics.UI.Gtk.ModelView.TreeView.Compat as Compat
import qualified Graphics.Rendering.Cairo as C
data KeyView = KeyView
keyViewNew :: Builder -> IO K... |
173cd5c40518356cfaf6565ecd9f90baf9b008512334c3688b1937d723bf35a4 | camlp5/camlp5 | reloc.mli | (* camlp5r *)
(* reloc.mli,v *)
Copyright ( c ) INRIA 2007 - 2017
value expr : (MLast.loc -> MLast.loc) -> int -> MLast.expr -> MLast.expr;
value longid : (MLast.loc -> MLast.loc) -> int -> MLast.longid -> MLast.longid;
value longid_lident : (MLast.loc -> MLast.loc) -> int -> MLast.longid_lident -> MLast.longid_lide... | null | https://raw.githubusercontent.com/camlp5/camlp5/15e03f56f55b2856dafe7dd3ca232799069f5dda/main/reloc.mli | ocaml | camlp5r
reloc.mli,v
Equality over syntax trees | Copyright ( c ) INRIA 2007 - 2017
value expr : (MLast.loc -> MLast.loc) -> int -> MLast.expr -> MLast.expr;
value longid : (MLast.loc -> MLast.loc) -> int -> MLast.longid -> MLast.longid;
value longid_lident : (MLast.loc -> MLast.loc) -> int -> MLast.longid_lident -> MLast.longid_lident;
value patt : (MLast.loc -> M... |
0d46c8004b284d7a6cf90789099aee9315bfe0e5c3678aca671f99558c0497cf | elm-lang/elm-repl | Flags.hs | {-# LANGUAGE DeriveDataTypeable #-}
module Flags where
import System.Console.CmdArgs
( Data, Typeable, (&=), explicit, help, helpArg
, name, summary, typFile, versionArg
)
import qualified Elm.Compiler as Compiler
import qualified Elm.Package as Pkg
version :: String
version =
Pkg.versionToString Comp... | null | https://raw.githubusercontent.com/elm-lang/elm-repl/cc258c37636e04b6f3d4a4840881910f5effe119/src/Flags.hs | haskell | # LANGUAGE DeriveDataTypeable # | module Flags where
import System.Console.CmdArgs
( Data, Typeable, (&=), explicit, help, helpArg
, name, summary, typFile, versionArg
)
import qualified Elm.Compiler as Compiler
import qualified Elm.Package as Pkg
version :: String
version =
Pkg.versionToString Compiler.version
data Flags = Flags
... |
e48f418af70ca38db14685f9bd939a12ab30ca97ebc6cf000b2d2f4938073117 | input-output-hk/cardano-sl | Instances.hs | # LANGUAGE CPP #
-- | Helper instances for acid-state to remove boilerplate and introduce
-- redundant instances for other data types.
module Serokell.AcidState.Instances where
import Control.Exception (throw)
import Control.Monad.Catch (MonadThrow (throwM))
import Data.Acid (Update)
i... | null | https://raw.githubusercontent.com/input-output-hk/cardano-sl/1499214d93767b703b9599369a431e67d83f10a2/acid-state-exts/src/Serokell/AcidState/Instances.hs | haskell | | Helper instances for acid-state to remove boilerplate and introduce
redundant instances for other data types. | # LANGUAGE CPP #
module Serokell.AcidState.Instances where
import Control.Exception (throw)
import Control.Monad.Catch (MonadThrow (throwM))
import Data.Acid (Update)
import Data.SafeCopy (SafeCopy (..), contain, safeGet, safePut)
import qualified Data.Time.Units as Time
ins... |
38fa37ed400a75d9d360a0996e74feab58d8a433877508c8bdaec5ab8c581d25 | soulomoon/SICP | Exercise5.10.scm | Exercise 5.10 : Design a new syntax for register - machine instructions and modify the simulator to use your new syntax . Can you implement your new syntax without changing any part of the simulator except the syntax procedures in this section ?
(load "/Users/soulomoon/git/SICP/Chapter5/ch5-regsim.scm")
(define (print ... | null | https://raw.githubusercontent.com/soulomoon/SICP/1c6cbf5ecf6397eaeb990738a938d48c193af1bb/Chapter5/Exercise5.10.scm | scheme | Exercise 5.10 : Design a new syntax for register - machine instructions and modify the simulator to use your new syntax . Can you implement your new syntax without changing any part of the simulator except the syntax procedures in this section ?
(load "/Users/soulomoon/git/SICP/Chapter5/ch5-regsim.scm")
(define (print ... | |
2b522281fcae8aba0a7a803f1a6e55b8b50f0de4e9fd6753ec083dc68ed0e89a | birthevdb/Latent-Effect-and-Handlers | CallByName.hs | # LANGUAGE TypeOperators #
{-# LANGUAGE RankNTypes #-}
# LANGUAGE ScopedTypeVariables #
# LANGUAGE FlexibleContexts #
module Features.CallByName where
import General
import Effects.Abstraction
import Effects.Delay
import Effects.Reader
data LamExpr e = VarExpr Int | AbsExpr e | AppExpr e e
cbnAlg :: ( Reading [v]... | null | https://raw.githubusercontent.com/birthevdb/Latent-Effect-and-Handlers/398167aa3a18572afa1ecc9ecdd6b37c97495f90/Features/CallByName.hs | haskell | # LANGUAGE RankNTypes # | # LANGUAGE TypeOperators #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE FlexibleContexts #
module Features.CallByName where
import General
import Effects.Abstraction
import Effects.Delay
import Effects.Reader
data LamExpr e = VarExpr Int | AbsExpr e | AppExpr e e
cbnAlg :: ( Reading [v] :<<: σ, Suspending v :<<: σ... |
62935194d4151c4e6dc8d87232e29ef3cd16a9ed3e00150af196b284067ef5d3 | softwarelanguageslab/maf | R5RS_WeiChenRompf2019_the-little-schemer_ch3-1.scm | ; Changes:
* removed : 1
* added : 1
* swaps : 0
; * negated predicates: 0
* swapped branches : 1
* calls to i d fun : 3
(letrec ((rember (lambda (a lat)
(<change>
(if (null? lat)
()
(if (eq? (car lat) a)
... | null | https://raw.githubusercontent.com/softwarelanguageslab/maf/11acedf56b9bf0c8e55ddb6aea754b6766d8bb40/test/changes/scheme/generated/R5RS_WeiChenRompf2019_the-little-schemer_ch3-1.scm | scheme | Changes:
* negated predicates: 0 | * removed : 1
* added : 1
* swaps : 0
* swapped branches : 1
* calls to i d fun : 3
(letrec ((rember (lambda (a lat)
(<change>
(if (null? lat)
()
(if (eq? (car lat) a)
(cdr lat)
... |
1037f01f1da79ffbe49fcbb7f26535b0124b31644b2f8c7d00223842506926cf | mzp/bs-lwt | lwt_preemptive.mli | Ocsigen
*
* Module lwt_preemptive.ml
* Copyright ( C ) 2005 , ,
* Laboratoire PPS - CNRS Université Paris Diderot
* 2009
*
* This program is free software ; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published ... | null | https://raw.githubusercontent.com/mzp/bs-lwt/f37a3c47d038f4efcd65912c41fab95d1e6633ce/lwt/src/preemptive/lwt_preemptive.mli | ocaml | * [detach f x] runs the computation [f x] in a separate preemptive thread.
[detach] evaluates to an Lwt thread, which waits for the preemptive thread
to complete.
Note that Lwt thread-local storage (i.e., {!Lwt.with_value}) cannot be
safely used from within [f]. The same goes for most of the re... | Ocsigen
*
* Module lwt_preemptive.ml
* Copyright ( C ) 2005 , ,
* Laboratoire PPS - CNRS Université Paris Diderot
* 2009
*
* This program is free software ; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published ... |
cf9b75b4bbc3c4302e8fd596e62cf15df1f8e89d171d34f3106a91fc69f791dc | peak6/mmd_core | security_id_cache.erl | -module(security_id_cache).
-export([start_link/0]).
-export([stats/0]).
-export([getById/1,getByKey/1]).
-export([store/2]).
-export([init/1, handle_call/3, handle_cast/2, handle_info/2,
terminate/2, code_change/3]).
-behaviour(gen_server2).
-define(SERVER,?MODULE).
-define(ID_TO_KEY,security_id_to_key).
-d... | null | https://raw.githubusercontent.com/peak6/mmd_core/f90469ea9eac8cd607aa6ec5b9ad6ff003a35572/src/security_id_cache.erl | erlang | ===================================================================
gen_server2 callbacks
=================================================================== | -module(security_id_cache).
-export([start_link/0]).
-export([stats/0]).
-export([getById/1,getByKey/1]).
-export([store/2]).
-export([init/1, handle_call/3, handle_cast/2, handle_info/2,
terminate/2, code_change/3]).
-behaviour(gen_server2).
-define(SERVER,?MODULE).
-define(ID_TO_KEY,security_id_to_key).
-d... |
2ebf8651c166607588c3f2fc7a9f1a6f741595731edb37766e8f6bdcc14fc14f | yziquel/OCaml-R | allocation.ml | (*********************************************************************************)
(* OCaml-R *)
(* *)
Copyright ( C ) 2008 - 2010 Institut National de Recherche en ... | null | https://raw.githubusercontent.com/yziquel/OCaml-R/4690dd0ede4858d7048f573d75519e4643a40532/src/allocation.ml | ocaml | *******************************************************************************
OCaml-R
... | Copyright ( C ) 2008 - 2010 Institut National de Recherche en
Informatique et en Automatique . All rights reserved .
Copyright ( C ) 2009 - 2010 . All rights reserved .
it under the terms of the GNU General Public License as
... |
6053260543992f828728cc126d09ef021b1fcf37ce299d3e65a5bc7c73ca1415 | OCamlPro/liquidity | liquidFromMicheline.mli | (****************************************************************************)
(* Liquidity *)
(* *)
Copyright ( C ) 2017 - 2020 OCamlPro SAS
(* ... | null | https://raw.githubusercontent.com/OCamlPro/liquidity/3578de34cf751f54b9e4c001a95625d2041b2962/tools/liquidity/without-dune-network/liquidFromMicheline.mli | ocaml | **************************************************************************
Liquidity
... | Copyright ( C ) 2017 - 2020 OCamlPro SAS
it under the terms of the GNU General Public License as published by
... |
f07fdc6a3cdcb384744fb0ad8ba56ac866297e9f6f7e3b9806b7c66c3c4d24cc | janestreet/bonsai | bonsai_testing_example_lib.ml | open! Core
include App
| null | https://raw.githubusercontent.com/janestreet/bonsai/761d04847d5f947318b64c0a46dffa17ad413536/examples/testing_example/lib/bonsai_testing_example_lib.ml | ocaml | open! Core
include App
| |
98d905dc3e6d13190ac9070ac9c6b55fec1d9838b8a3060abf07f54a2d286990 | ocsigen/js_of_ocaml | run.ml | open Js_of_ocaml_compiler
open Stdlib
let failure_expected = ref false
let flags, files =
Sys.argv
|> Array.to_list
|> List.tl
|> List.partition ~f:(fun x -> Char.equal (String.get x 0) '-')
let () =
List.iter flags ~f:(function
| "-fail" -> failure_expected := true
| f -> failwith ("unrecognis... | null | https://raw.githubusercontent.com/ocsigen/js_of_ocaml/eae34864ebe70c3e93d373e87fcd7432f5a6d1d4/compiler/tests-js-parser/run.ml | ocaml | open Js_of_ocaml_compiler
open Stdlib
let failure_expected = ref false
let flags, files =
Sys.argv
|> Array.to_list
|> List.tl
|> List.partition ~f:(fun x -> Char.equal (String.get x 0) '-')
let () =
List.iter flags ~f:(function
| "-fail" -> failure_expected := true
| f -> failwith ("unrecognis... | |
71427ff70abe4260a068cc45e1c17c2079d2f50e840b59004a88722b88000a25 | yahoojapan/big3store | query_tree.erl | %%
%% Query Tree process
%%
2014 - 2019 UP FAMNIT and Yahoo Japan Corporation
%% @version 0.3
@since May , 2014
@author < >
@author < >
%%
%% @doc Query tree module implements process that serves as front-end
%% of query tree represented as tree of inter-connected processes running
%% on array of serv... | null | https://raw.githubusercontent.com/yahoojapan/big3store/c4142395695a836fec60b7c202f9f12d46a8ed01/src/query_tree.erl | erlang |
Query Tree process
@version 0.3
@doc Query tree module implements process that serves as front-end
of query tree represented as tree of inter-connected processes running
on array of servers. Message start initializes query tree. Message
eval starts evaluation of query tree.
Query tree process determines ... | 2014 - 2019 UP FAMNIT and Yahoo Japan Corporation
@since May , 2014
@author < >
@author < >
Secondly , rows in given columns are selected dynamically based on
dictionary entry query_tree . First element of
< table " >
< tr > < td > > < td > boolean()</td > < td > true denotes that
< tr > < td... |
811874a658529f45763f5e7519bee7a2a255773804f513192fceec87240b530e | TrustInSoft/tis-kernel | VC.mli | (**************************************************************************)
(* *)
This file is part of .
(* *)
is a fork of Frama - C. Al... | null | https://raw.githubusercontent.com/TrustInSoft/tis-kernel/748d28baba90c03c0f5f4654d2e7bb47dfbe4e7d/src/plugins/wp/VC.mli | 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 - 2015 ... |
b2000b333273e6a7d6aeac1244af6cdd16110bc1c1fe4621df70f88735ffb7a4 | patricoferris/ocaml-multicore-monorepo | unikernel.ml |
* This code was adapted from
* -www/blob/master/src/dispatch_tls.ml .
*
* Its copyright header is retained below .
*
* Copyright ( c ) 2015 < >
*
* Permission to use , copy , modify , and distribute this software for any
* purpose with or without fee is hereby granted , provided that the a... | null | https://raw.githubusercontent.com/patricoferris/ocaml-multicore-monorepo/22b441e6727bc303950b3b37c8fbc024c748fe55/duniverse/dream/src/vendor/h2/examples/alpn/mirage/unikernel.ml | ocaml | accept h2 before http/1.1
Unable to negotiate a protocol |
* This code was adapted from
* -www/blob/master/src/dispatch_tls.ml .
*
* Its copyright header is retained below .
*
* Copyright ( c ) 2015 < >
*
* Permission to use , copy , modify , and distribute this software for any
* purpose with or without fee is hereby granted , provided that the a... |
e29f85b2cb7a176031ce3868bfbcc8633e7766157a50ec869205908ae095b8b9 | anurudhp/CPHaskell | learningtocode.hs | --
{-# LANGUAGE Safe #-}
import safe Control.Arrow ((>>>))
import safe Data.Functor (($>))
import safe qualified Data.Map as M
import safe Data.Maybe (catMaybes)
import safe Text.Parsec
( (<|>)
, anyChar
, char
, choice
, many
, many1
, manyTill
, parse
, spaces
, string
, try
)
main :: IO ()... | null | https://raw.githubusercontent.com/anurudhp/CPHaskell/01ae8dde6aab4f6ddfebd122ded0b42779dd16f1/contests/kattis/learningtocode.hs | haskell |
# LANGUAGE Safe #
variable: value
variable
string literal
template literal
`var x = e`
`print e` |
import safe Control.Arrow ((>>>))
import safe Data.Functor (($>))
import safe qualified Data.Map as M
import safe Data.Maybe (catMaybes)
import safe Text.Parsec
( (<|>)
, anyChar
, char
, choice
, many
, many1
, manyTill
, parse
, spaces
, string
, try
)
main :: IO ()
main = interact $ lines >... |
b7400cc8894fcd0af386eebdabd151cf6623f1fe68275c5a020a0c69e3e2cefa | sky-big/RabbitMQ | gm.erl | The contents of this file are subject to the Mozilla Public License
%% Version 1.1 (the "License"); you may not use this file except in
%% compliance with the License. You may obtain a copy of the License at
%% /
%%
Software distributed under the License is distributed on an " AS IS "
%% basis, WITHOUT WARRANTY OF ... | null | https://raw.githubusercontent.com/sky-big/RabbitMQ/d7a773e11f93fcde4497c764c9fa185aad049ce2/src/gm.erl | erlang | Version 1.1 (the "License"); you may not use this file except in
compliance with the License. You may obtain a copy of the License at
/
basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
License for the specific language governing rights and limitations
under the License.
Guaranteed(保证) ... | The contents of this file are subject to the Mozilla Public License
Software distributed under the License is distributed on an " AS IS "
The Original Code is RabbitMQ .
The Initial Developer of the Original Code is GoPivotal , Inc.
Copyright ( c ) 2007 - 2014 GoPivotal , Inc. All rights reserved .
-module... |
133e901dbfeac00aad91fd164a39eb4f8b9f1a0209c6dbc52d663a03830bcc43 | penpot/penpot | rpc_viewer_test.clj | 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) KALEIDOS INC
(ns backend-tests.rpc-viewer-test
(:require
[backend-tests.helpers :as th]
[app.common.uuid :as uuid]
... | null | https://raw.githubusercontent.com/penpot/penpot/fe11b37b8f79bf58cde6317c36b6d86233cf9d3a/backend/test/backend_tests/rpc_viewer_test.clj | clojure |
Copyright (c) KALEIDOS INC
(th/print-result! out)
(th/print-result! out)
(th/print-result! out)
(th/print-result! out)
(th/print-result! out) | 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 /.
(ns backend-tests.rpc-viewer-test
(:require
[backend-tests.helpers :as th]
[app.common.uuid :as uuid]
[app.db :as db]
[clojure.te... |
ab7db9195bcbe1906bec6bd3fc0c6455d8fc0aad5570d4b37e42d50e61ef047a | niquola/json-schema.clj | v5_test.clj | (ns json-schema.v5-test
(:refer-clojure :exclude [compile])
(:require
[json-schema.core :as sut]
[json-schema.utils :as u]
[clojure.test :refer :all]))
(def re-filter #"^.*$")
(deftest draft5-test
"property name is the format for the property value"
(let [validator (sut/compile {:additionalPropertie... | null | https://raw.githubusercontent.com/niquola/json-schema.clj/85ca313d1b64b0005b4f783c2f58c0a47ec8d009/test/json_schema/v5_test.clj | clojure | (ns json-schema.v5-test
(:refer-clojure :exclude [compile])
(:require
[json-schema.core :as sut]
[json-schema.utils :as u]
[clojure.test :refer :all]))
(def re-filter #"^.*$")
(deftest draft5-test
"property name is the format for the property value"
(let [validator (sut/compile {:additionalPropertie... | |
dff1574f1d6b90dc69f054d6bfac8ef45f9c9427dff327f2395f14732c959a00 | erlang/otp | mnesia_lib.erl | %%
%% %CopyrightBegin%
%%
Copyright Ericsson AB 1996 - 2023 . All Rights Reserved .
%%
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
%% you may not use this file except in compliance with the License.
%% You may obtain a copy of the License at
%%
%% -2.0
%%
%% Unless required by applicab... | null | https://raw.githubusercontent.com/erlang/otp/2b397d7e5580480dc32fa9751db95f4b89ff029e/lib/mnesia/src/mnesia_lib.erl | erlang |
%CopyrightBegin%
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 lan... | Copyright Ericsson AB 1996 - 2023 . All Rights Reserved .
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
distributed under the License is distributed on an " AS IS " BASIS ,
-module(mnesia_lib).
-include("mnesia.hrl").
-include_lib("kernel/include/file.hrl").
-export([core_file/0]).
-e... |
3511bf68d218cc16e32043f3d78fe130f38a24b2835580a61adfedb9613fc12f | ucsd-progsys/liquidhaskell | Bag.hs | module Bag where
import Language.Haskell.Liquid.Bag as B
{-@ measure bag @-}
bag :: (Ord a) => [a] -> B.Bag a
bag [] = B.empty
bag (x:xs) = B.put x (bag xs)
{-@ prop0 :: x:_ -> TT @-}
prop0 :: Int -> Bool
prop0 x = (B.get x a == 2)
where
a = bag [x, x, x + 1]
{-@ prop1 :: x:_ -> TT @-}
prop1 :: Int -> B... | null | https://raw.githubusercontent.com/ucsd-progsys/liquidhaskell/20cd67af038930cb592d68d272c8eb1cbe3cb6bf/tests/measure/pos/Bag.hs | haskell | @ measure bag @
@ prop0 :: x:_ -> TT @
@ prop1 :: x:_ -> TT @
@ prop2 :: x:_ -> y:_ -> TT @ | module Bag where
import Language.Haskell.Liquid.Bag as B
bag :: (Ord a) => [a] -> B.Bag a
bag [] = B.empty
bag (x:xs) = B.put x (bag xs)
prop0 :: Int -> Bool
prop0 x = (B.get x a == 2)
where
a = bag [x, x, x + 1]
prop1 :: Int -> Bool
prop1 x = (B.get (x + 1) a == 1)
where
a = bag [x, x, x + 1]
... |
82581b1b9d26de080af7902d66f2d9d61d10714a1b692e28bb372714bd221adf | zcaudate/hara | arg.clj | (ns hara.function.base.arg
(:import (clojure.lang Fn RestFn)
(java.lang.reflect Method)))
(defn vargs?
"checks that function contain variable arguments
(vargs? (fn [x])) => false
(vargs? (fn [x & xs])) => true"
{:added "3.0"}
[^Fn f]
(if (some (fn [^Method mthd]
(= "getRequ... | null | https://raw.githubusercontent.com/zcaudate/hara/481316c1f5c2aeba5be6e01ae673dffc46a63ec9/src/hara/function/base/arg.clj | clojure | (ns hara.function.base.arg
(:import (clojure.lang Fn RestFn)
(java.lang.reflect Method)))
(defn vargs?
"checks that function contain variable arguments
(vargs? (fn [x])) => false
(vargs? (fn [x & xs])) => true"
{:added "3.0"}
[^Fn f]
(if (some (fn [^Method mthd]
(= "getRequ... | |
c81141b293289d12f2d4a1dcf2d6247fdc9ecdc3a25bf1085eaf1b43e90f1570 | ssor/erlangDemos | sellarea_app.erl | -module(sellarea_app).
-behaviour(application).
-export([start/2,stop/1]).
start(_Type,StartArgs)->
sellarea_supervisor:start_link(StartArgs).
stop(_State)->
ok. | null | https://raw.githubusercontent.com/ssor/erlangDemos/632cd905be2c4f275f1c1ae15238e711d7bb9147/demos/otp_demo_no_alarm/sellarea_app.erl | erlang | -module(sellarea_app).
-behaviour(application).
-export([start/2,stop/1]).
start(_Type,StartArgs)->
sellarea_supervisor:start_link(StartArgs).
stop(_State)->
ok. | |
929492b38437ff1b11aa7d66515f1b0ffcdd471b4fffdd9e2b6c4968a5185ecf | Kakadu/fp2022 | parsertest.ml | * Copyright 2021 - 2022 ,
* SPDX - License - Identifier : LGPL-3.0 - or - later
open Ast
open Parser
let test_parse ~code ~expected =
match parse code with
| Ok ok ->
(match List.equal equal_declaration ok expected with
| true -> true
| false ->
Format.printf "Expected: %a\nActual: %a\n" p... | null | https://raw.githubusercontent.com/Kakadu/fp2022/6831c4dc3a0f010e27cc2609aa415309bda7ff71/OcamlObj/lib/parsertest.ml | ocaml | * Copyright 2021 - 2022 ,
* SPDX - License - Identifier : LGPL-3.0 - or - later
open Ast
open Parser
let test_parse ~code ~expected =
match parse code with
| Ok ok ->
(match List.equal equal_declaration ok expected with
| true -> true
| false ->
Format.printf "Expected: %a\nActual: %a\n" p... | |
944375cfc4baa01b0f5b99d9bf6a653f8a1e50a010b922b27c83253dccbe776f | pink-gorilla/webly | routes.cljs | (ns frontend.routes
(:require
[clojure.string :as str]
[taoensso.timbre :refer-macros [info infof error]]
[reagent.core :as r]
[bidi.bidi :as bidi]
[pushy.core :as pushy]
[cemerick.url :as url]))
(defonce static-main-path-atom (atom ""))
(defn set-main-path! [path]
(let [safe-path (if (... | null | https://raw.githubusercontent.com/pink-gorilla/webly/54798e86f74989fa4d789b2e06e3d5501a3c845f/frontend/src/frontend/routes.cljs | clojure | bidi does not handle query params
idea how to solve the problem:
(url/query->map)
not yet used
todo : hard redirects for backend routes or exernal links
(info "link for handler: " handler "no-route-params")
(info "bidi link url: " url)
(info "link for handler: " handler "route-params: " route-params)
(info "bidi ... | (ns frontend.routes
(:require
[clojure.string :as str]
[taoensso.timbre :refer-macros [info infof error]]
[reagent.core :as r]
[bidi.bidi :as bidi]
[pushy.core :as pushy]
[cemerick.url :as url]))
(defonce static-main-path-atom (atom ""))
(defn set-main-path! [path]
(let [safe-path (if (... |
98c16b02c1809290e6f8870c0187994a21c742cdf3ebcdba4f2b7d0e60348210 | lachenmayer/arrowsmith | Type.hs | module AST.Type
( Type(..), AliasType(..)
, RawType, CanonicalType
, PortType(..), portType
, fieldMap, recordOf, listOf, tupleOf
, deepDealias, dealias
, collectLambdas
, prettyParens
) where
import Control.Applicative ((<$>), (<*>))
import Control.Arrow (second)
import Data.Binary
imp... | null | https://raw.githubusercontent.com/lachenmayer/arrowsmith/34b6bdeddddb2d8b9c6f41002e87ec65ce8a701a/elm-compiler/src/AST/Type.hs | haskell | DEFINITION
DEALIASING
PRETTY PRINTING
BINARY | module AST.Type
( Type(..), AliasType(..)
, RawType, CanonicalType
, PortType(..), portType
, fieldMap, recordOf, listOf, tupleOf
, deepDealias, dealias
, collectLambdas
, prettyParens
) where
import Control.Applicative ((<$>), (<*>))
import Control.Arrow (second)
import Data.Binary
imp... |
c90e72ff3cb911a7629c7a79e319003be92815e8109f8526b5986ff2270f3f60 | debug-ito/net-spider | PangraphSpec.hs | {-# LANGUAGE OverloadedStrings #-}
module NetSpider.PangraphSpec (main, spec) where
import Data.List (sort)
import Data.Text (Text)
import NetSpider.Snapshot.Internal (SnapshotNode(..), SnapshotLink(..))
import NetSpider.Timestamp (fromS)
import qualified Pangraph as P
import Test.Hspec
import NetSpider.Pangraph (mak... | null | https://raw.githubusercontent.com/debug-ito/net-spider/82dfbdca1add1edfd54ef36cb1ca5129d528b814/net-spider-pangraph/test/NetSpider/PangraphSpec.hs | haskell | # LANGUAGE OverloadedStrings # | module NetSpider.PangraphSpec (main, spec) where
import Data.List (sort)
import Data.Text (Text)
import NetSpider.Snapshot.Internal (SnapshotNode(..), SnapshotLink(..))
import NetSpider.Timestamp (fromS)
import qualified Pangraph as P
import Test.Hspec
import NetSpider.Pangraph (makeVertex, ToAttributes(..), makeEdge... |
07bd76ab6a6db92b1f34f43dca496e1fbaac4a65f78d8178c3e09369787d362e | jspahrsummers/ScrumBut | DevelMain.hs | -- | Running your app inside GHCi.
--
To start up GHCi for usage with Yesod , first make sure you are in dev mode :
--
-- > cabal configure -fdev
--
Note that @yesod devel@ automatically sets the dev flag .
-- Now launch the repl:
--
> cabal repl -fobject - code "
--
-- To start your app, run:
--
-- > :l Devel... | null | https://raw.githubusercontent.com/jspahrsummers/ScrumBut/4e2a8dce520b713c4c618c085123075b5b7bed4d/app/DevelMain.hs | haskell | | Running your app inside GHCi.
> cabal configure -fdev
Now launch the repl:
To start your app, run:
> :l DevelMain
> DevelMain.update
You can also call @DevelMain.shutdown@ to stop the app
You will need to add the foreign-store package to your .cabal file.
It is very light-weight.
If you don't use c... | To start up GHCi for usage with Yesod , first make sure you are in dev mode :
Note that @yesod devel@ automatically sets the dev flag .
> cabal repl -fobject - code "
module DevelMain where
import Prelude
import Application (getApplicationRepl, shutdownApp)
import Control.Exception (finally)
import Control.... |
b7a0edb3b1b25b7212c88ddc243205e01ad1a303386fc1677c2b89205e40ab41 | spechub/Hets | Print_AS.hs | |
Module : ./ConstraintCASL / Print_AS.hs
Copyright : ( c ) , , Uni Bremen 2004 - 2006
License : GPLv2 or higher , see LICENSE.txt
Maintainer :
Stability : provisional
Portability : portable
printing AS_ConstraintCASL ConstraintCASLSign data types
Module : .... | null | https://raw.githubusercontent.com/spechub/Hets/af7b628a75aab0d510b8ae7f067a5c9bc48d0f9e/ConstraintCASL/Print_AS.hs | haskell | |
Module : ./ConstraintCASL / Print_AS.hs
Copyright : ( c ) , , Uni Bremen 2004 - 2006
License : GPLv2 or higher , see LICENSE.txt
Maintainer :
Stability : provisional
Portability : portable
printing AS_ConstraintCASL ConstraintCASLSign data types
Module : .... | |
70a4773c1d41376f7a41bb2871c774c6c3957aa2356c28e1d552501586740a81 | input-output-hk/plutus | Common.hs | {-# LANGUAGE EmptyCase #-}
{-# LANGUAGE EmptyDataDeriving #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE RecordWildCards #-}
# LANGUAGE ScopedTypeVariables #
module PlutusCore.Generators.NEAT.Common where
! ! ! THIS FILE IS GENERATED FROM
! ! ! DO NOT EDIT THIS FILE . EDIT
! ! ! AND THE... | null | https://raw.githubusercontent.com/input-output-hk/plutus/097f3e65789a51721152817b5c1c8eb0efedb441/plutus-core/testlib/PlutusCore/Generators/NEAT/Common.hs | haskell | # LANGUAGE EmptyCase #
# LANGUAGE EmptyDataDeriving #
# LANGUAGE FlexibleContexts #
# LANGUAGE RecordWildCards #
* Namespaces
|Create an empty name state from a stream of text names.
|Extend name state with a fresh name.
|Create an empty name state from a stream of text names.
|Extend type name ... | # LANGUAGE ScopedTypeVariables #
module PlutusCore.Generators.NEAT.Common where
! ! ! THIS FILE IS GENERATED FROM
! ! ! DO NOT EDIT THIS FILE . EDIT
! ! ! AND THEN RUN agda2hs ON IT .
!!! THIS FILE IS GENERATED FROM Common.agda
!!! DO NOT EDIT THIS FILE. EDIT Common.agda
!!! AND THEN RUN agda2hs ON IT.
-}
... |
2c89446d1b4a72272fea23784985c55731198d408af5ae2b05fb6cbb2b1a3865 | 15Galan/asignatura-204 | VectorialCairo.hs | -------------------------------------------------------------------------------
Data Structures . en Informática . UMA .
@
--
Vectorial graphics
--
-------------------------------------------------------------------------------
module DataStructures.Graphics.VectorialCairo
( Percent
, Color
, rgb
,... | null | https://raw.githubusercontent.com/15Galan/asignatura-204/894f33ff8e0f52a75d8f9ff15155c656f1a8f771/Recursos/data.structures/haskell/DataStructures/Graphics/VectorialCairo.hs | haskell | -----------------------------------------------------------------------------
-----------------------------------------------------------------------------
desde el origen al point
min scX scY * n
; rotate (pi/2)
; translate (widthD/2) (-heightD/2)
; scale (widthD/2) (heightD/2)
surfaceWriteToPNG sfc fich
when (n... | Data Structures . en Informática . UMA .
@
Vectorial graphics
module DataStructures.Graphics.VectorialCairo
( Percent
, Color
, rgb
, blue
, red
, green
, yellow
, magenta
, cyan
, black
, white
, gray
, orange
, Point(..)
, Radius
, Modifier(..)
, Transformation(..)
... |
497161a0573e955ac90378284e353be5633622d57a4fbba81c697dadd8e3a1b4 | yqrashawn/GokuRakuJoudo | layers_test.clj | (ns karabiner-configurator.layers-test
(:require [clojure.test :as t]
[karabiner-configurator.data :refer [conf-data init-conf-data update-conf-data]]
[karabiner-configurator.layers :as sut]))
(def layers-example {:tab-mode {:key :tab :afterup [{:set ["chunkwm-move-mode" 0]}
... | null | https://raw.githubusercontent.com/yqrashawn/GokuRakuJoudo/2295ee42923d439ec5c60bb9ff1655becfad273d/test/karabiner_configurator/layers_test.clj | clojure | (t/testing | (ns karabiner-configurator.layers-test
(:require [clojure.test :as t]
[karabiner-configurator.data :refer [conf-data init-conf-data update-conf-data]]
[karabiner-configurator.layers :as sut]))
(def layers-example {:tab-mode {:key :tab :afterup [{:set ["chunkwm-move-mode" 0]}
... |
43225592ac13bf694a3ce1b2a2d10e63dd25c44fc36832f32f4c036027499e82 | cram2/cram | motion-designators.lisp | ;;;
Copyright ( c ) 2017 , < >
;;; All rights reserved.
;;;
;;; Redistribution and use in source and binary forms, with or without
;;; modification, are permitted provided that the following conditions are met:
;;;
;;; * Redistributions of source code must retain the above copyright
;;; notice, this list... | null | https://raw.githubusercontent.com/cram2/cram/dcb73031ee944d04215bbff9e98b9e8c210ef6c5/cram_tutorials/cram_beginner_tutorial/src/motion-designators.lisp | lisp |
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redi... | Copyright ( c ) 2017 , < >
* Neither the name of the Institute for Artificial Intelligence/
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS " AS IS "
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED . IN NO EVENT SHALL THE COPYRIGHT OWNER OR ... |
97e856625441def2c84481cf25631e5daa4a49dbc75456484d98185def5d1718 | achirkin/vulkan | VK_EXT_separate_stencil_usage.hs | # OPTIONS_GHC -fno - warn - missing - pattern - synonym - signatures #
# OPTIONS_HADDOCK not - home #
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE MagicHash #-}
# LANGUAGE PatternSynonyms #
{-# LANGUAGE Strict #-}
{-# LANGUAGE ViewPatterns #-}
module Graphics.Vulkan.Ext.VK_EXT_separate_stencil_usage
... | null | https://raw.githubusercontent.com/achirkin/vulkan/b2e0568c71b5135010f4bba939cd8dcf7a05c361/vulkan-api/src-gen/Graphics/Vulkan/Ext/VK_EXT_separate_stencil_usage.hs | haskell | # LANGUAGE DataKinds #
# LANGUAGE MagicHash #
# LANGUAGE Strict #
# LANGUAGE ViewPatterns #
|
supported: @vulkan@
contact: @Daniel Rakos @drakos-amd@
author: @EXT@
type: @device@
Extension number: @247@ | # OPTIONS_GHC -fno - warn - missing - pattern - synonym - signatures #
# OPTIONS_HADDOCK not - home #
# LANGUAGE PatternSynonyms #
module Graphics.Vulkan.Ext.VK_EXT_separate_stencil_usage
* Vulkan extension : @VK_EXT_separate_stencil_usage@
VkImageStencilUsageCreateInfoEXT,
VK_EXT_SEPARATE_STENCIL_USA... |
f3a808635d42fd95c9c189229025629eb8d444b992925fc8f18faf568142cccf | spurious/sagittarius-scheme-mirror | cond-expand.scm | -*- mode : scheme ; coding : utf-8 ; -*-
;;;
;;; SRFI-0 cond-expand
;;;
Copyright ( c ) 2010 - 2011 < >
;;;
;;; Redistribution and use in source and binary forms, with or without
;;; modification, are permitted provided that the following conditions
;;; are met:
;;;
;;; 1. Redistributions o... | null | https://raw.githubusercontent.com/spurious/sagittarius-scheme-mirror/53f104188934109227c01b1e9a9af5312f9ce997/sitelib/srfi/%253a0/cond-expand.scm | scheme | coding : utf-8 ; -*-
SRFI-0 cond-expand
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the... | Copyright ( c ) 2010 - 2011 < >
" AS IS " AND ANY EXPRESS OR IMPLIED WARRANTIES , INCLUDING , BUT NOT
SPECIAL , EXEMPLARY , OR CONSEQUENTIAL DAMAGES ( INCLUDING , BUT NOT LIMITED
LIABILITY , WHETHER IN CONTRACT , STRICT LIABILITY , OR TORT ( INCLUDING
(library (srfi :0 cond-expand)
(export cond... |
0398068e5975beb5c6d30a789d0d844ace6cc3387b5e68088c4f2c7f82fa6501 | ghuysmans/api-cohttp-lwt | string_or_empty.ml | open Tiny_json.Json
type t = string option
let json_of_t = function
| None -> String ""
| Some s -> String s
let t_of_json =
let f_exn ?trace js =
match Json_conv.(exn string_of_json) ?trace js with
| "" -> None
| s -> Some s
in
Json_conv.result f_exn
| null | https://raw.githubusercontent.com/ghuysmans/api-cohttp-lwt/4edfcb4d24deeeaca5786cb0e440fe295ef05b6f/demo/conv/pmc/string_or_empty.ml | ocaml | open Tiny_json.Json
type t = string option
let json_of_t = function
| None -> String ""
| Some s -> String s
let t_of_json =
let f_exn ?trace js =
match Json_conv.(exn string_of_json) ?trace js with
| "" -> None
| s -> Some s
in
Json_conv.result f_exn
| |
36f96d46b86e7d041b527ab6090d6db1defc533afde040e47dcfd5af6e03e782 | rdnetto/powerline-hs | Paths.hs | # LANGUAGE GeneralizedNewtypeDeriving #
module Config.Paths (CfgM, runCfg, mainConfigPaths, colorsPaths, colorschemePaths, themePaths) where
import Control.Monad.IO.Class (MonadIO)
import Control.Monad.Reader (MonadReader, ReaderT, runReaderT, asks)
import qualified Data.Map.Lazy as Map
import Data.Maybe (maybeToList... | null | https://raw.githubusercontent.com/rdnetto/powerline-hs/6569a88455e8d98d0327743df13b05947f35efb3/src/Config/Paths.hs | haskell | Caches result of looking up paths
Returns the config_files directory that is part of the powerline package installation.
Paths to config.json
Paths to colors.json
Paths to color schemes
list monad
Paths to themes (define list of segments)
list monad
Local themes are used for select, continuation modes (PS3, PS... | # LANGUAGE GeneralizedNewtypeDeriving #
module Config.Paths (CfgM, runCfg, mainConfigPaths, colorsPaths, colorschemePaths, themePaths) where
import Control.Monad.IO.Class (MonadIO)
import Control.Monad.Reader (MonadReader, ReaderT, runReaderT, asks)
import qualified Data.Map.Lazy as Map
import Data.Maybe (maybeToList... |
e30b6c0376fa8269a441005549ee3f60365998a355d52d1adb1b0e48fb50ea83 | haskell/cabal | Get.hs | -----------------------------------------------------------------------------
-- |
-- Module : Distribution.Client.Get
Copyright : ( c ) 2008
2011
2012
-- License : BSD-like
--
-- Maintainer :
-- Stability : provisional
-- Portability : portable
-... | null | https://raw.githubusercontent.com/haskell/cabal/5159ffbc8ab42e242ccd404cef594787bb08d65e/cabal-install/src/Distribution/Client/Get.hs | haskell | ---------------------------------------------------------------------------
|
Module : Distribution.Client.Get
License : BSD-like
Maintainer :
Stability : provisional
Portability : portable
The 'cabal get' command.
---------------------------------------------------------------------------
|... | Copyright : ( c ) 2008
2011
2012
module Distribution.Client.Get (
get,
* Cloning ' SourceRepo 's
clonePackagesFromSourceRepo,
ClonePackageException(..),
) where
import Prelude ()
import Distribution.Client.Compat.Prelude hiding (get)
import Distr... |
c24be81d094474bf716678894ced8b2a214edc315749380de2624bbc1ec9c3f8 | malcolmsparks/up | pedestal_webapp.clj | (ns up.pedestal-webapp
(:require
[lamina.core :refer (receive-all filter*)]
[io.pedestal.service.impl.interceptor :refer (resume)])
(:import (up.start Lifecycle)))
(defrecord PedestalWebapp [pctx]
Lifecycle
(start [_]
(let [bus (-> pctx :bus)
handler (-> pctx :options :handler)]
(requ... | null | https://raw.githubusercontent.com/malcolmsparks/up/4ce578f60f6d60661d32965026bf3c2a854a0d52/up-pedestal-webapp/src/up/pedestal_webapp.clj | clojure | (ns up.pedestal-webapp
(:require
[lamina.core :refer (receive-all filter*)]
[io.pedestal.service.impl.interceptor :refer (resume)])
(:import (up.start Lifecycle)))
(defrecord PedestalWebapp [pctx]
Lifecycle
(start [_]
(let [bus (-> pctx :bus)
handler (-> pctx :options :handler)]
(requ... | |
e9531e22426d87fbbb0e22dcafe21722dccbc25385c41f3a0b00681fee4df160 | HaskellForCats/HaskellForCats | 2014-0328hngmn.hs | module Main where
-- a need primative pulled from C
FFI is how we connect with other languages
import System.IO
getCh :: IO Char
getCh = do {hSetEcho stdin False
; c <- getChar
; hSetEcho stdin True
; return c
}
hangman :: IO ()
hangman =
do putStrLn "Think of a word: "
w... | null | https://raw.githubusercontent.com/HaskellForCats/HaskellForCats/2d7a15c0cdaa262c157bbf37af6e72067bc279bc/MenaBeginning/Ch009/2014-0328hngmn.hs | haskell | a need primative pulled from C | module Main where
FFI is how we connect with other languages
import System.IO
getCh :: IO Char
getCh = do {hSetEcho stdin False
; c <- getChar
; hSetEcho stdin True
; return c
}
hangman :: IO ()
hangman =
do putStrLn "Think of a word: "
word <- sgetLine
putStrLn "Try to g... |
8f69fd952915a9469aea6e771a47a611ffaa56335e4d8e6f22d2abb208d48e28 | clj-easy/stub | utils.clj | (ns clj-easy.stub.utils)
(defn assoc-some
"Assoc[iate] if the value is not nil. "
([m k v]
(if (nil? v) m (assoc m k v)))
([m k v & kvs]
(let [ret (assoc-some m k v)]
(if kvs
(if (next kvs)
(recur ret (first kvs) (second kvs) (nnext kvs))
(throw (IllegalArgumentException.
... | null | https://raw.githubusercontent.com/clj-easy/stub/a9382bd40110685355f9d5b04a78a25879673608/src/lib/clj_easy/stub/utils.clj | clojure | (ns clj-easy.stub.utils)
(defn assoc-some
"Assoc[iate] if the value is not nil. "
([m k v]
(if (nil? v) m (assoc m k v)))
([m k v & kvs]
(let [ret (assoc-some m k v)]
(if kvs
(if (next kvs)
(recur ret (first kvs) (second kvs) (nnext kvs))
(throw (IllegalArgumentException.
... | |
e33205d9c68aafd0689cd3c88548e78bc658a2b1a3134ba4720d5723f00024e2 | monadfix/ormolu-live | SrcLoc.hs | ( c ) The University of Glasgow , 1992 - 2006
{-# LANGUAGE DeriveDataTypeable #-}
# LANGUAGE StandaloneDeriving #
{-# LANGUAGE DeriveFunctor #-}
{-# LANGUAGE DeriveFoldable #-}
{-# LANGUAGE DeriveTraversable #-}
# LANGUAGE FlexibleInstances #
# LANGUAGE RecordWildCards #
{-# LANGUAGE TypeFamilies ... | null | https://raw.githubusercontent.com/monadfix/ormolu-live/d8ae72ef168b98a8d179d642f70352c88b3ac226/ghc-lib-parser-8.10.1.20200412/compiler/basicTypes/SrcLoc.hs | haskell | # LANGUAGE DeriveDataTypeable #
# LANGUAGE DeriveFunctor #
# LANGUAGE DeriveFoldable #
# LANGUAGE DeriveTraversable #
# LANGUAGE TypeFamilies #
# LANGUAGE ViewPatterns #
# LANGUAGE PatternSynonyms #
| This module contains types that relate to the positions of things
in source files, and allow... | ( c ) The University of Glasgow , 1992 - 2006
# LANGUAGE StandaloneDeriving #
# LANGUAGE FlexibleInstances #
# LANGUAGE RecordWildCards #
# LANGUAGE FlexibleContexts #
module SrcLoc (
SrcLoc(..),
mkSrcLoc, mkRealSrcLoc, mkGeneralSrcLoc,
advanceSrcLoc,
* * Unsafely deconstruct... |
1344fa3afd04cf787d22044bc22fe9a0a9a243b7b549592524fa9f0118d07e9a | reborg/clojure-essential-reference | 2.clj | < 1 >
< 2 >
499999500000 | null | https://raw.githubusercontent.com/reborg/clojure-essential-reference/c37fa19d45dd52b2995a191e3e96f0ebdc3f6d69/ReducersandTransducers/Reducers/fold/2.clj | clojure | < 1 >
< 2 >
499999500000 | |
96aab1012bd7c50e2409dfd97782aa393a0fff78b767d1a7a8c641543c83630a | tibbe/event | PSQ.hs | # LANGUAGE ScopedTypeVariables #
module PSQ (tests) where
import System.Event.PSQ (Elem(..), PSQ)
import qualified System.Event.PSQ as Q
import System.Event.Unique (Unique(..))
import Control.Monad (liftM3)
import Data.Function (on)
import Data.Int (Int64)
import qualified Data.List as L
import Test.Framework (Test,... | null | https://raw.githubusercontent.com/tibbe/event/2ca43e49327aa7854396b800ff4184d8b00a69f0/tests/PSQ.hs | haskell | ----------------------------------------------------------------------
Simple priority queue model implemented using sorted lists.
A priority queue model. Keys are uniqueue and kept in ascending
order. | # LANGUAGE ScopedTypeVariables #
module PSQ (tests) where
import System.Event.PSQ (Elem(..), PSQ)
import qualified System.Event.PSQ as Q
import System.Event.Unique (Unique(..))
import Control.Monad (liftM3)
import Data.Function (on)
import Data.Int (Int64)
import qualified Data.List as L
import Test.Framework (Test,... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.