_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 |
|---|---|---|---|---|---|---|---|---|
672d9c350fcae7707e0e75dd576ba6b73389e3cd1fe62fd77472588a63fc8357 | kupl/LearnML | original.ml | type formula =
| True
| False
| Not of formula
| AndAlso of (formula * formula)
| OrElse of (formula * formula)
| Imply of (formula * formula)
| Equal of (exp * exp)
and exp = Num of int | Plus of (exp * exp) | Minus of (exp * exp)
let rec eval (f : formula) : bool =
match f with
| True -> true
| ... | null | https://raw.githubusercontent.com/kupl/LearnML/c98ef2b95ef67e657b8158a2c504330e9cfb7700/result/cafe2/formula/sub75/original.ml | ocaml | type formula =
| True
| False
| Not of formula
| AndAlso of (formula * formula)
| OrElse of (formula * formula)
| Imply of (formula * formula)
| Equal of (exp * exp)
and exp = Num of int | Plus of (exp * exp) | Minus of (exp * exp)
let rec eval (f : formula) : bool =
match f with
| True -> true
| ... | |
55c8a3e9ac414a532f2987774ee4cd469ab7c286ff563793fe8c7d98e26cbed6 | digitallyinduced/ihp | Main.hs | module Main where
import IHP.Prelude
import IHP.Environment
import IHP.FrameworkConfig
import qualified IHP.Server
import IHP.RouterSupport
import IHP.ControllerPrelude
import IHP.Mail
--import IHP.GenericController
data DemoController = DemoAction deriving (Eq, Show, Data)
instance AutoRoute DemoController
instance... | null | https://raw.githubusercontent.com/digitallyinduced/ihp/46c6c1299feb9a1361cd79a75c093df5e3819a24/Main.hs | haskell | import IHP.GenericController | module Main where
import IHP.Prelude
import IHP.Environment
import IHP.FrameworkConfig
import qualified IHP.Server
import IHP.RouterSupport
import IHP.ControllerPrelude
import IHP.Mail
data DemoController = DemoAction deriving (Eq, Show, Data)
instance AutoRoute DemoController
instance InitControllerContext RootAppl... |
900cd63dcc67a2814615c464c1f98577837e1c2fa73f4432c0339e2842615a14 | shop-planner/shop3 | p15.lisp |
(IN-PACKAGE :SHOP-USER)
(DEFPROBLEM STRIPS-SAT-X-1
((SATELLITE SATELLITE0) (INSTRUMENT INSTRUMENT0)
(INSTRUMENT INSTRUMENT1) (SATELLITE SATELLITE1)
(INSTRUMENT INSTRUMENT2) (INSTRUMENT INSTRUMENT3)
(SATELLITE SATELLITE2) (INSTRUMENT INSTRUMENT4)
(INSTRUMENT INSTRUMENT5) (SATELLITE SATELLITE3)
(INSTRUMENT I... | null | https://raw.githubusercontent.com/shop-planner/shop3/ba429cf91a575e88f28b7f0e89065de7b4d666a6/shop3/examples/satellite/strips/p15.lisp | lisp |
(IN-PACKAGE :SHOP-USER)
(DEFPROBLEM STRIPS-SAT-X-1
((SATELLITE SATELLITE0) (INSTRUMENT INSTRUMENT0)
(INSTRUMENT INSTRUMENT1) (SATELLITE SATELLITE1)
(INSTRUMENT INSTRUMENT2) (INSTRUMENT INSTRUMENT3)
(SATELLITE SATELLITE2) (INSTRUMENT INSTRUMENT4)
(INSTRUMENT INSTRUMENT5) (SATELLITE SATELLITE3)
(INSTRUMENT I... | |
e52ea2b0cd1f5380990a2e16e8a2ab822408a07e0fd179a4e06d0821a2b206f7 | robrix/Manifold | Module.hs | # LANGUAGE GeneralizedNewtypeDeriving #
module Manifold.Module where
import Control.Monad ((<=<))
import qualified Data.Map as Map
import Data.Semilattice.Lower
import Manifold.Constraint
import Manifold.Declaration
import Manifold.Name
import Manifold.Pretty
import Manifold.Type
data Module var def = Module
{ modu... | null | https://raw.githubusercontent.com/robrix/Manifold/3cc7a49c90b9cc7d1da61c532d0ee526ccdd3474/src/Manifold/Module.hs | haskell | # LANGUAGE GeneralizedNewtypeDeriving #
module Manifold.Module where
import Control.Monad ((<=<))
import qualified Data.Map as Map
import Data.Semilattice.Lower
import Manifold.Constraint
import Manifold.Declaration
import Manifold.Name
import Manifold.Pretty
import Manifold.Type
data Module var def = Module
{ modu... | |
b97e3c62d5e382118460e072430e9f9fe335602ef3d9dbb64dc645e602372289 | jwarlander/everex | thrift1151_types.erl | %%
Autogenerated by Thrift Compiler ( 1.0.0 - dev )
%%
%% DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
%%
-module(thrift1151_types).
-include("thrift1151_types.hrl").
-export([struct_info/1, struct_info_ext/1]).
struct_info('StructA') ->
{struct, [{1, i16}]}
;
struct_info('StructB') ->
{s... | null | https://raw.githubusercontent.com/jwarlander/everex/559a18e45054abd7d2adfeb3ef060f79b58308e9/test/thrift/gen-erl/thrift1151_types.erl | erlang |
DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
| Autogenerated by Thrift Compiler ( 1.0.0 - dev )
-module(thrift1151_types).
-include("thrift1151_types.hrl").
-export([struct_info/1, struct_info_ext/1]).
struct_info('StructA') ->
{struct, [{1, i16}]}
;
struct_info('StructB') ->
{struct, [{1, i32}]}
;
struct_info('StructC') ->
{struct, [{1, {struct, {'th... |
c656306e718f543f97ebe67b85350af5958beec4efbb87358177d4a6fa83a8f9 | logaan/bt.clj | core_test.clj | (ns testing-gloss.core-test
(:require [clojure.test :refer :all]
[testing-gloss.core :refer :all]))
(deftest a-test
(testing "FIXME, I fail."
(is (= 0 0))))
| null | https://raw.githubusercontent.com/logaan/bt.clj/44831af16c4b987db16d0d85eee9cd79cb4fa757/test/testing_gloss/core_test.clj | clojure | (ns testing-gloss.core-test
(:require [clojure.test :refer :all]
[testing-gloss.core :refer :all]))
(deftest a-test
(testing "FIXME, I fail."
(is (= 0 0))))
| |
c725106c5318adabcbbb996b4c71b1a50948062dc28d43c3853670d94b01c516 | osstotalsoft/functional-guy | 04.MindTrick.hs | -- Think of any number.
-- Double the number.
Add 9 with result .
Subtract 3 with the result .
Divide the result by 2 .
Subtract the number with the first number started with .
The answer will always be 3 .
mindTrick :: Integer -> Integer
mindTrick x = (x * 2 + 9 -3) `div` 2 - x
-- rewrite it as a pipeline ... | null | https://raw.githubusercontent.com/osstotalsoft/functional-guy/c02a8b22026c261a9722551f3641228dc02619ba/Chapter6.%20Computational%20effects/Examples/Reader/04.MindTrick.hs | haskell | Think of any number.
Double the number.
rewrite it as a pipeline of functions | Add 9 with result .
Subtract 3 with the result .
Divide the result by 2 .
Subtract the number with the first number started with .
The answer will always be 3 .
mindTrick :: Integer -> Integer
mindTrick x = (x * 2 + 9 -3) `div` 2 - x
thinkOfANumber :: Integer -> Integer
thinkOfANumber = id
doubleTheNumber ... |
7c110f3684135ecc8691e20ac294c87dbea47858e44cc8caa13d47d8b8cfb19b | mRrvz/bmstu-ca | Interpolation.hs | module Interpolation (
interpolation2
) where
import Data.List
import Data.Maybe
type TableXY = [(Double, Double)]
type Matrix = [[Double]]
type ValueTable = [[Double]]
type Point = (Double, Double)
type PolynomDegrees = (Int, Int)
slice :: TableXY -> Int -> Int -> TableXY
slice table n pos = take n $ drop pos ... | null | https://raw.githubusercontent.com/mRrvz/bmstu-ca/866a32b37878d45006ec3c4f99f67983ae681717/lab_02/src/Interpolation.hs | haskell | module Interpolation (
interpolation2
) where
import Data.List
import Data.Maybe
type TableXY = [(Double, Double)]
type Matrix = [[Double]]
type ValueTable = [[Double]]
type Point = (Double, Double)
type PolynomDegrees = (Int, Int)
slice :: TableXY -> Int -> Int -> TableXY
slice table n pos = take n $ drop pos ... | |
675ec0bddd64e76083df9743abc4feafcbfb7ea8fcd4e2783b44208c3adb0a6e | janestreet/noise-wireguard-ocaml | messages.ml | open Core
module Handshake_initiation = struct include Handshake_initiation end
module Handshake_response = struct include Handshake_response end
module Cookie_reply = struct include Cookie_reply end
module Transport = struct include Transport end
type mac_message =
| Handshake_initiation of Handshake_initiation.t
... | null | https://raw.githubusercontent.com/janestreet/noise-wireguard-ocaml/4ec7a34d1778ab5c8ec16a6129277d4f77406616/messages/messages.ml | ocaml | open Core
module Handshake_initiation = struct include Handshake_initiation end
module Handshake_response = struct include Handshake_response end
module Cookie_reply = struct include Cookie_reply end
module Transport = struct include Transport end
type mac_message =
| Handshake_initiation of Handshake_initiation.t
... | |
3bbd5134e5c0429e6a43c55575537a94e8e35484ec75b2ae4abd80ca7949b3b3 | ghcjs/ghcjs-dom | SVGRectElement.hs | # LANGUAGE PatternSynonyms #
# LANGUAGE ForeignFunctionInterface #
# LANGUAGE JavaScriptFFI #
-- For HasCallStack compatibility
{-# LANGUAGE ImplicitParams, ConstraintKinds, KindSignatures #-}
module GHCJS.DOM.JSFFI.Generated.SVGRectElement
(js_getX, getX, js_getY, getY, js_getWidth, getWidth, js_getHeight,
... | null | https://raw.githubusercontent.com/ghcjs/ghcjs-dom/749963557d878d866be2d0184079836f367dd0ea/ghcjs-dom-jsffi/src/GHCJS/DOM/JSFFI/Generated/SVGRectElement.hs | haskell | For HasCallStack compatibility
# LANGUAGE ImplicitParams, ConstraintKinds, KindSignatures # | # LANGUAGE PatternSynonyms #
# LANGUAGE ForeignFunctionInterface #
# LANGUAGE JavaScriptFFI #
module GHCJS.DOM.JSFFI.Generated.SVGRectElement
(js_getX, getX, js_getY, getY, js_getWidth, getWidth, js_getHeight,
getHeight, js_getRx, getRx, js_getRy, getRy, SVGRectElement(..),
gTypeSVGRectElement)
... |
82b333902d79b3d8852ce4694df952ac5b2f195feb4f309758d1a8eeb5505e8f | protz/mezzo | UntypedMezzo2UntypedOCaml.ml | open SurfaceSyntax
open UntypedMezzo
module O = UntypedOCaml
This is the translation of to .
(* TEMPORARY think about [open]: when we mention a data constructor
or field name in OCaml, is it always in scope? or must we qualify
it? can we use qualified names everywhere? *)
(* -----------------------------... | null | https://raw.githubusercontent.com/protz/mezzo/4e9d917558bd96067437116341b7a6ea02ab9c39/compiler/UntypedMezzo2UntypedOCaml.ml | ocaml | TEMPORARY think about [open]: when we mention a data constructor
or field name in OCaml, is it always in scope? or must we qualify
it? can we use qualified names everywhere?
----------------------------------------------------------------------------
When printing a (variable, type, field) name, we must make... | open SurfaceSyntax
open UntypedMezzo
module O = UntypedOCaml
This is the translation of to .
let identifier (x : string) =
if Hashtbl.mem OCamlKeywords.keyword_table x then
"__ok_" ^ x
else
x
We translate Mezzo module names in such a way that they are unlikely to be
confused with a nativ... |
41207de7c89fed2bfa0e092cc0f74e6400507d363d74ff72e4eec29f46dcdfb0 | janestreet/core | ofday_float.mli | open! Import
include Ofday_intf.S with type underlying = float and module Span := Span_float
module Stable : sig
module V1 : sig
type nonrec t = t
[@@deriving bin_io, compare, hash, sexp, sexp_grammar, stable_witness]
end
end
| null | https://raw.githubusercontent.com/janestreet/core/4b6635d206f7adcfac8324820d246299d6f572fe/core/src/ofday_float.mli | ocaml | open! Import
include Ofday_intf.S with type underlying = float and module Span := Span_float
module Stable : sig
module V1 : sig
type nonrec t = t
[@@deriving bin_io, compare, hash, sexp, sexp_grammar, stable_witness]
end
end
| |
1eaadaa69578933db7f684c590f21f2d344a6a8f0dc04659da9bf0c720045a0c | cubicle-model-checker/cubicle | smt.ml | (**************************************************************************)
(* *)
Cubicle
(* *)
... | null | https://raw.githubusercontent.com/cubicle-model-checker/cubicle/00f09bb2d4bb496549775e770d7ada08bc1e4866/smt/smt.ml | ocaml | ************************************************************************
... | Cubicle
Copyright ( C ) 2011 - 2014
and
Universite Paris - Sud 11
This file is distributed under the terms ... |
0bae79d3804ac90f27120910725d7b75fa5dd13a058dbdd3cad92db20549d0b4 | pavankumarbn/DroneGUIROS | navdata_watchdog.lisp | ; Auto-generated. Do not edit!
(cl:in-package ardrone_autonomy-msg)
// ! \htmlinclude navdata_watchdog.msg.html
(cl:defclass <navdata_watchdog> (roslisp-msg-protocol:ros-message)
((header
:reader header
:initarg :header
:type std_msgs-msg:Header
:initform (cl:make-instance 'std_msgs-msg:Header))
... | null | https://raw.githubusercontent.com/pavankumarbn/DroneGUIROS/745320d73035bc50ac4fea2699e22586e10be800/devel/share/common-lisp/ros/ardrone_autonomy/msg/navdata_watchdog.lisp | lisp | Auto-generated. Do not edit! |
(cl:in-package ardrone_autonomy-msg)
// ! \htmlinclude navdata_watchdog.msg.html
(cl:defclass <navdata_watchdog> (roslisp-msg-protocol:ros-message)
((header
:reader header
:initarg :header
:type std_msgs-msg:Header
:initform (cl:make-instance 'std_msgs-msg:Header))
(drone_time
:reader dron... |
6d41744523edaa641620e420b41b2cbac3c9caa9e28f630e08bdbc13858d2eab | MLstate/opalang | tree.ml |
Copyright © 2011 MLstate
This file is part of .
is free software : you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License , version 3 , as published by
the Free Software Foundation .
is distributed in the hope that it will be useful , ... | null | https://raw.githubusercontent.com/MLstate/opalang/424b369160ce693406cece6ac033d75d85f5df4f/ocamllib/libbase/tree.ml | ocaml | * A module for general non empty tree.
If you need trees that may be empty, you can use an option on this type.
* defines map, fold, etc. |
Copyright © 2011 MLstate
This file is part of .
is free software : you can redistribute it and/or modify it under the
terms of the GNU Affero General Public License , version 3 , as published by
the Free Software Foundation .
is distributed in the hope that it will be useful , ... |
bb8fc7bf689fa18e365a46e0c1b5d26fbfac014a4ddc362735590cff6a281007 | caradoc-org/caradoc | selectview.ml | (*****************************************************************************)
(* Caradoc: a PDF parser and validator *)
Copyright ( C ) 2017
(* *)
(* This program is... | null | https://raw.githubusercontent.com/caradoc-org/caradoc/100f53bc55ef682049e10fabf24869bc019dc6ce/src/ui/selectview.ml | ocaml | ***************************************************************************
Caradoc: a PDF parser and validator
This program is free software; you can redistribute it and/or modify
... | Copyright ( C ) 2017
it under the terms of the GNU General Public License version 2 as
published by the Free Software Foundation .
You should have received a copy of the GNU General Public License along
with this program ; if n... |
7f1e7c93897d65f1bfcae1cf1f7a9a8d0553e8bf9164e0d59f73c822b419fc0a | huangjs/cl | mcstep.lisp | ;;; Compiled by f2cl version:
( " f2cl1.l , v 1.215 2009/04/07 22:05:21 rtoy Exp $ "
" f2cl2.l , v 1.37 2008/02/22 22:19:33 rtoy Exp $ "
" f2cl3.l , v 1.6 2008/02/22 22:19:33 rtoy Exp $ "
" f2cl4.l , v 1.7 2008/02/22 22:19:34 rtoy Exp $ "
" f2cl5.l , v 1.200 2009/01/19 02:38:17 rtoy Exp $ "
" f2cl6.l ,... | null | https://raw.githubusercontent.com/huangjs/cl/96158b3f82f82a6b7d53ef04b3b29c5c8de2dbf7/lib/maxima/share/lbfgs/mcstep.lisp | lisp | Compiled by f2cl version:
Options: ((:prune-labels nil) (:auto-save t) (:relaxed-array-decls t)
(:coerce-assigns :as-needed) (:array-type ':array)
(:array-slicing t) (:declare-common nil)
(:float-format double-float)) | ( " f2cl1.l , v 1.215 2009/04/07 22:05:21 rtoy Exp $ "
" f2cl2.l , v 1.37 2008/02/22 22:19:33 rtoy Exp $ "
" f2cl3.l , v 1.6 2008/02/22 22:19:33 rtoy Exp $ "
" f2cl4.l , v 1.7 2008/02/22 22:19:34 rtoy Exp $ "
" f2cl5.l , v 1.200 2009/01/19 02:38:17 rtoy Exp $ "
" f2cl6.l , v 1.48 2008/08/24 00:56:27 rt... |
19664604ef6ee5428cbee81ad813e9ad45c6c0a95b12dd2291a07e30c7dd7da2 | zellige/zellige | MapnikVectorTile.hs | # LANGUAGE FlexibleContexts #
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE RecordWildCards #
module Data.Geometry.MapnikVectorTile where
import qualified Control.Monad.ST as ST
import qualified Data.Aeson as Aeson
import qualified Data.ByteString a... | null | https://raw.githubusercontent.com/zellige/zellige/87e6dab11ac4c1843009043580f14422a1d83ebf/src/Data/Geometry/MapnikVectorTile.hs | haskell | # LANGUAGE OverloadedStrings #
Command line
Lib | # LANGUAGE FlexibleContexts #
# LANGUAGE RecordWildCards #
module Data.Geometry.MapnikVectorTile where
import qualified Control.Monad.ST as ST
import qualified Data.Aeson as Aeson
import qualified Data.ByteString as ByteString
import qualified Data.... |
2285036a429982af5393083786f218eddeab662b131a0e81807a2e717ffcb3dc | xvw/planet | lib.ml | open Bedrock
open Baremetal
let stamp task action message () =
let filename =
Filename.concat
Glue.(Database.path Task.database)
(Shapes.Task.(task.uuid) ^ ".qube")
in
let open Result.Infix in
let open Shapes.Task in
Glue.Git.stage [ filename ]
>>= fun () ->
Glue.Git.commit ~desc:message ... | null | https://raw.githubusercontent.com/xvw/planet/c2a77ea66f61cc76df78b9c2ad06d114795f3053/src/bin/todo/lib.ml | ocaml | open Bedrock
open Baremetal
let stamp task action message () =
let filename =
Filename.concat
Glue.(Database.path Task.database)
(Shapes.Task.(task.uuid) ^ ".qube")
in
let open Result.Infix in
let open Shapes.Task in
Glue.Git.stage [ filename ]
>>= fun () ->
Glue.Git.commit ~desc:message ... | |
6e787ccaccf28774f7d1ce8de9e739eaa0e33023a2db1aeaedeaa933fa17aa8a | bytekid/mkbtt | yices.ml | Copyright 2008 , Christian Sternagel ,
* GNU Lesser General Public License
*
* This file is part of TTT2 .
*
* TTT2 is free software : you can redistribute it and/or modify it under
* the terms of the GNU Lesser General Public License as published by the
* Free Software Foundation , either ve... | null | https://raw.githubusercontent.com/bytekid/mkbtt/c2f8e0615389b52eabd12655fe48237aa0fe83fd/src/logic/src/yices.ml | ocaml | ** FUNCTIONS ***************************************************************
create and delete context
comparisons
boolean operators
arithmetic
rat is subsumed by real
| F.Implies (x, y) -> impl ctx (tfc ctx x) (tfc ctx y)
| F.SMul (i, b) -> mul ctx (of_int ctx i) (t ctx b)
Format.eprintf "Before transformi... | Copyright 2008 , Christian Sternagel ,
* GNU Lesser General Public License
*
* This file is part of TTT2 .
*
* TTT2 is free software : you can redistribute it and/or modify it under
* the terms of the GNU Lesser General Public License as published by the
* Free Software Foundation , either ve... |
13b1b099623951a76503408f40052f61063ef53c4844de4de1ebdf35dac5d89b | spawnfest/eep49ers | tls_bloom_filter.erl | %%
%% %CopyrightBegin%
%%
Copyright Ericsson AB 2007 - 2019 . 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/spawnfest/eep49ers/d1020fd625a0bbda8ab01caf0e1738eb1cf74886/lib/ssl/src/tls_bloom_filter.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 2007 - 2019 . All Rights Reserved .
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
distributed under the License is distributed on an " AS IS " BASIS ,
in TLS 1.3 ( stateless tickets )
-module(tls_bloom_filter).
-export([add_elem/2,
contains/2,
... |
e7540174c09611f909a77205b46f54c810312d0a3c7bd6f1e01b392221c06792 | perf101/rage | html_handler.ml | open! Core.Std
class t = fun ~args ->
object (self)
inherit Handler.t ~args
method private include_javascript =
printf "<script src='rage.js'></script>"
method private write_404 =
printf "Status: 404 Not Found\n";
printf "Content-Type: text/html\n\n";
printf "<h1>404 --- this is not the page yo... | null | https://raw.githubusercontent.com/perf101/rage/e8630659b2754b6621df7c49f3663fa7c4fac5eb/src/html_handler.ml | ocaml | open! Core.Std
class t = fun ~args ->
object (self)
inherit Handler.t ~args
method private include_javascript =
printf "<script src='rage.js'></script>"
method private write_404 =
printf "Status: 404 Not Found\n";
printf "Content-Type: text/html\n\n";
printf "<h1>404 --- this is not the page yo... | |
42b99c6d98c7def3fa13a73a6a835e8bd72ffc6ae127ed3c5fcb0824782c8837 | clojure-interop/google-cloud-clients | MetricsClient.clj | (ns com.google.cloud.logging.v2.MetricsClient
"Service Description: Service for configuring logs-based metrics.
This class provides the ability to make remote calls to the backing service through method
calls that map to API methods. Sample code to get started:
try (MetricsClient metricsClient = MetricsClie... | null | https://raw.githubusercontent.com/clojure-interop/google-cloud-clients/80852d0496057c22f9cdc86d6f9ffc0fa3cd7904/com.google.cloud.logging/src/com/google/cloud/logging/v2/MetricsClient.clj | clojure |
"
| (ns com.google.cloud.logging.v2.MetricsClient
"Service Description: Service for configuring logs-based metrics.
This class provides the ability to make remote calls to the backing service through method
calls that map to API methods. Sample code to get started:
try (MetricsClient metricsClient = MetricsClie... |
5816769fa0492301ab54ba8987d2e7923e513ec0beed4c800f3bd49a72e6ec17 | haskell/cabal | Prelude.hs | # LANGUAGE CPP #
# LANGUAGE FlexibleContexts #
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE Trustworthy #-}
{-# LANGUAGE TypeOperators #-}
#ifdef MIN_VERSION_base
#define MINVER_base_411 MIN_VERSION_base(4,11,0)
#else
#define MINVER_base_411 (__GLASGOW_HASKELL__ >= 804)
#endif
| This module ... | null | https://raw.githubusercontent.com/haskell/cabal/c53acf5280014ba37337a78967191e1ddd0507cc/Cabal-syntax/src/Distribution/Compat/Prelude.hs | haskell | # LANGUAGE RankNTypes #
# LANGUAGE Trustworthy #
# LANGUAGE TypeOperators #
* Provides commonly used imports.
* Prelude
* Common type-classes
* Some types
* Data.Either
* Data.Maybe
* Data.List
* Data.Foldable
* Data.Function
* Data.Ord
* Control.Arrow
* Control.Monad
* Control.Exception
... | # LANGUAGE CPP #
# LANGUAGE FlexibleContexts #
#ifdef MIN_VERSION_base
#define MINVER_base_411 MIN_VERSION_base(4,11,0)
#else
#define MINVER_base_411 (__GLASGOW_HASKELL__ >= 804)
#endif
| This module does two things :
* Acts as a compatibility layer , like @base - compat@.
module Distribution.Compat... |
a185f2b3e38eaf73e540a8549dcacd68a3d945d27135341fd0dd4874f806e547 | kappelmann/engaging-large-scale-functional-programming | Interface.hs | module Interface(main) where
import qualified Exercise12 as E
main :: IO ()
main = E.main
| null | https://raw.githubusercontent.com/kappelmann/engaging-large-scale-functional-programming/28905255605b55353de2d06239f79448c6fe4230/resources/io_mocking/stocks/test/Interface.hs | haskell | module Interface(main) where
import qualified Exercise12 as E
main :: IO ()
main = E.main
| |
5f1ef95bb57421b2aa36f437c7acf16fdfeb56c3e5397cb0ce1b35b3db01a35c | RyanMcG/chic-text | project.clj | (defproject chic-text "0.2.0"
:description "Helpful functions for formatting text into tables."
:url "-text"
:license {:name "Eclipse Public License"
:url "-v10.html"}
:dependencies [[org.clojure/clojure "1.6.0"]
[jline "2.12"]]
:profiles {:dev {:plugins [[lein-repack "0.2.7"]]
... | null | https://raw.githubusercontent.com/RyanMcG/chic-text/2d901b6ddfb6f2703bedef7230160c1c782fc326/project.clj | clojure | (defproject chic-text "0.2.0"
:description "Helpful functions for formatting text into tables."
:url "-text"
:license {:name "Eclipse Public License"
:url "-v10.html"}
:dependencies [[org.clojure/clojure "1.6.0"]
[jline "2.12"]]
:profiles {:dev {:plugins [[lein-repack "0.2.7"]]
... | |
d4c1c862a834bf7fbe638e70fcfd861049d8c218f454479697b421c80ddd6810 | wavejumper/rehook | todo_test.cljs | (ns todo-test
(:require [rehook.test :as rehook.test :refer-macros [defuitest is io initial-render next-render]]
[todomvc.core :as todo]))
(defn test-ctx [component]
{:system todo/ctx
:system-args []
:shutdown-f #(when-let [f (some-> % meta :stop)]
(f))
:ctx-f (f... | null | https://raw.githubusercontent.com/wavejumper/rehook/c1a4207918827f4b738cdad9a9645385e5e10ff4/examples/todomvc/src/test/todo_test.cljs | clojure | This example shows how we can use the 'data layer' -- eg our dispatch and subscribe
This example shows how we can inspect the output of our components hiccup
to write tests against our components
defuitest isn't limited to just top-level components!
we can test child components as well :) | (ns todo-test
(:require [rehook.test :as rehook.test :refer-macros [defuitest is io initial-render next-render]]
[todomvc.core :as todo]))
(defn test-ctx [component]
{:system todo/ctx
:system-args []
:shutdown-f #(when-let [f (some-> % meta :stop)]
(f))
:ctx-f (f... |
b89a92879eeebcc28628cecc0ef0327c66a2b49ed8b068c5519eb5969e076224 | jellelicht/guix | pkg-config.scm | ;;; GNU Guix --- Functional package management for GNU
Copyright © 2012 , 2013 , 2014 , 2016 < >
;;;
;;; This file is part of GNU Guix.
;;;
GNU is free software ; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by
the Free Software Foundation ; either ... | null | https://raw.githubusercontent.com/jellelicht/guix/83cfc9414fca3ab57c949e18c1ceb375a179b59c/gnu/packages/pkg-config.scm | scheme | GNU Guix --- Functional package management for GNU
This file is part of GNU Guix.
you can redistribute it and/or modify it
either version 3 of the License , or ( at
your option) any later version.
GNU Guix is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied wa... | Copyright © 2012 , 2013 , 2014 , 2016 < >
under the terms of the GNU General Public License as published by
You should have received a copy of the GNU General Public License
along with GNU . If not , see < / > .
(define-module (gnu packages pkg-config)
#:use-module (guix licenses)
#:use-module (guix ... |
ff532027260d874bdf885d9879972ac132cce65ddb5492254e78d4ff1d7acc41 | paoloo/blockchainPOC | project.clj | (defproject bcpoc "0.5.0-HOTASHELL"
:description "BCPOC: a proof-of-concept blockchain-based wallet API"
:url ""
:min-lein-version "2.0.0"
:dependencies [[org.clojure/clojure "1.8.0"]
[compojure "1.5.1"]
[com.chain/chain-sdk-java "1.2.1"]
[ring/ring-defaults "0... | null | https://raw.githubusercontent.com/paoloo/blockchainPOC/18593423a70ec4294a66a40ada562d7dc23612d8/project.clj | clojure | (defproject bcpoc "0.5.0-HOTASHELL"
:description "BCPOC: a proof-of-concept blockchain-based wallet API"
:url ""
:min-lein-version "2.0.0"
:dependencies [[org.clojure/clojure "1.8.0"]
[compojure "1.5.1"]
[com.chain/chain-sdk-java "1.2.1"]
[ring/ring-defaults "0... | |
efc094dd155f915a6cbebbaf031be2438bf903678ca49cf431949898b0e53739 | ruhler/smten | StableNameEq.hs |
-- | Fast equality by pointer comparison.
module Smten.Runtime.StableNameEq (
stableNameEq,
) where
import System.IO.Unsafe
import System.Mem.StableName
| Return true if the two arguments point to the same location in the heap .
-- If this returns True, it means the arguments are one and the same.
stable... | null | https://raw.githubusercontent.com/ruhler/smten/16dd37fb0ee3809408803d4be20401211b6c4027/smten-base/Smten/Runtime/StableNameEq.hs | haskell | | Fast equality by pointer comparison.
If this returns True, it means the arguments are one and the same. |
module Smten.Runtime.StableNameEq (
stableNameEq,
) where
import System.IO.Unsafe
import System.Mem.StableName
| Return true if the two arguments point to the same location in the heap .
stableNameEq :: a -> a -> Bool
stableNameEq x y = unsafeDupablePerformIO $ do
xnm <- makeStableName x
ynm <- m... |
030461f1776ce4fb75fac7c1cdf8ceea9709d3ed4608a86e36955c95cc6fac0a | fgalassi/cs61a-sp11 | 3.50.scm | (define (stream-map proc . argstreams)
(if (stream-null? (car argstreams))
the-empty-stream
(cons-stream
(apply proc (map stream-car argstreams))
(apply stream-map
(cons proc (map stream-cdr argstreams))))))
| null | https://raw.githubusercontent.com/fgalassi/cs61a-sp11/66df3b54b03ee27f368c716ae314fd7ed85c4dba/homework/3.50.scm | scheme | (define (stream-map proc . argstreams)
(if (stream-null? (car argstreams))
the-empty-stream
(cons-stream
(apply proc (map stream-car argstreams))
(apply stream-map
(cons proc (map stream-cdr argstreams))))))
| |
05fde558e74f47b1963c816959dc8f1fa6abed85d8fca91e68bc703728532e4b | manuel-serrano/bigloo | depend.scm | ;*---------------------------------------------------------------------*/
* serrano / prgm / project / bigloo / examples / Depend / depend.scm * /
;* */
* Author : * /
* Creation ... | null | https://raw.githubusercontent.com/manuel-serrano/bigloo/eb650ed4429155f795a32465e009706bbf1b8d74/examples/Depend/depend.scm | scheme | *---------------------------------------------------------------------*/
* */
* */
* On genere des dependances (d'apres les includes). */
*---------------------------... | * serrano / prgm / project / bigloo / examples / Depend / depend.scm * /
* Author : * /
* Creation : We d Mar 17 10:49:15 1993 * /
* Last change : Thu Sep 26 09:47:28 1996 ( serrano ) * /
(module... |
b0a153beb1924b9f5a1fe8779ba8f3aa7ee188a47451f4d889d3b7cbe43d06f1 | pflanze/chj-schemelib | seq.scm | Copyright 2019 - 2020 by < >
;;; This file is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License ( GPL ) as published
by the Free Software Foundation , either version 2 of the License , or
;;; (at your option) any later version.
(require (cj... | null | https://raw.githubusercontent.com/pflanze/chj-schemelib/59ff8476e39f207c2f1d807cfc9670581c8cedd3/seq.scm | scheme | This file is free software; you can redistribute it and/or modify
(at your option) any later version.
ever hack
test
XX what is this again, for? | Copyright 2019 - 2020 by < >
it under the terms of the GNU General Public License ( GPL ) as published
by the Free Software Foundation , either version 2 of the License , or
(require (cj-functional-2 either)
(lazy FV)
(scheme-meta homogenous-vector?)
(cj-struct-tag cj-struct... |
b1a1a178e2acac18dbcb59f2417c7dceb111f60bb8dffa98365772ba4e82a938 | jonase/eastwood | clojure_1_11.clj | (ns testcases.clojure-1-11
"A namespace that exercises all new features in Clojure 1.11.0."
(:require
[clojure.math :as math]
[clojure.test :refer [deftest is]]
[totally-does-not-exist :as-alias does-not-exist]))
;; -serving-people-and-programs
(defn destr [& {:keys [a b] :as opts}]
[a b opts])
(defn u... | null | https://raw.githubusercontent.com/jonase/eastwood/a983a04045ac9e0c4540693eade5a2e47193fc3c/cases/testcases/clojure_1_11.clj | clojure | -serving-people-and-programs
equivalence to line-seq
paginated API | (ns testcases.clojure-1-11
"A namespace that exercises all new features in Clojure 1.11.0."
(:require
[clojure.math :as math]
[clojure.test :refer [deftest is]]
[totally-does-not-exist :as-alias does-not-exist]))
(defn destr [& {:keys [a b] :as opts}]
[a b opts])
(defn uses-destr []
[(destr :a 1)
... |
8647882ce6cb4c4f4ae6ea76f4194b0e7d036abbbafc5dbe3c41ae971d841f38 | coord-e/mlml | bundler_dune.ml | let () =
(* TODO: Remove hardcoded path *)
let current_dir = "../../../test/" in
Tester.file (Filename.concat current_dir "./bundler_dune/bin/exec.ml") "18490"
;;
| null | https://raw.githubusercontent.com/coord-e/mlml/ec34b1fe8766901fab6842b790267f32b77a2861/test/bundler_dune.ml | ocaml | TODO: Remove hardcoded path | let () =
let current_dir = "../../../test/" in
Tester.file (Filename.concat current_dir "./bundler_dune/bin/exec.ml") "18490"
;;
|
f146ee4c3b295ff08e7e3cbd687af8c7357ffcd5128fc185cc04a9e8bd7db841 | blitz/stumpwm | kmap.lisp | Copyright ( C ) 2003 - 2008
;;
This file is part of stumpwm .
;;
stumpwm is free software ; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation ; either version 2 , or ( at your option )
;; any later version.
stumpwm is ... | null | https://raw.githubusercontent.com/blitz/stumpwm/439180985920a628b18d4426f1a29b1c36576531/kmap.lisp | lisp |
you can redistribute it and/or modify
either version 2 , or ( at your option )
any later version.
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
along with this software; see the file COPY... | Copyright ( C ) 2003 - 2008
This file is part of stumpwm .
it under the terms of the GNU General Public License as published by
stumpwm is distributed in the hope that it will be useful ,
You should have received a copy of the GNU General Public License
the Free Software Foundation , Inc. , 59 Temple P... |
2a138538f3694f7a0143a05ad6d231ef3f08ce73cc9e4a29ca6b1b11a50c27cd | haskell-tools/haskell-tools | Renamed_res.hs | module Refactor.OrganizeImports.MakeExplicit.Renamed where
import Refactor.OrganizeImports.MakeExplicit.Source as Src (A(..))
x = B
| null | https://raw.githubusercontent.com/haskell-tools/haskell-tools/b1189ab4f63b29bbf1aa14af4557850064931e32/src/builtin-refactorings/examples/Refactor/OrganizeImports/MakeExplicit/Renamed_res.hs | haskell | module Refactor.OrganizeImports.MakeExplicit.Renamed where
import Refactor.OrganizeImports.MakeExplicit.Source as Src (A(..))
x = B
| |
f1b6641c6d4867081aa3cfc1c501024b0c305b8fe6177a331e034128d2d437b0 | chetmurthy/poly-protobuf | test24_ml.ml | module T = Test24_types
module Pb = Test24_pb
module Pp = Test24_pp
let decode_ref_data () = (T.Value "value" : T.a)
let () =
let mode = Test_util.parse_args () in
match mode with
| Test_util.Decode ->
Test_util.decode "test24.c2ml.data" Pb.decode_a Pp.pp_a (decode_ref_data ())
| Test_util.E... | null | https://raw.githubusercontent.com/chetmurthy/poly-protobuf/1f80774af6472fa30ee2fb10d0ef91905a13a144/tests/testdata/integration-tests/test24_ml.ml | ocaml | module T = Test24_types
module Pb = Test24_pb
module Pp = Test24_pp
let decode_ref_data () = (T.Value "value" : T.a)
let () =
let mode = Test_util.parse_args () in
match mode with
| Test_util.Decode ->
Test_util.decode "test24.c2ml.data" Pb.decode_a Pp.pp_a (decode_ref_data ())
| Test_util.E... | |
e60b43c8d50e74f3a13dd2f8f00e07acf77bf74824a09d43f1d367d2ac3dfcf4 | alura-cursos/datomic-introducao | db.clj | (ns ecommerce.db
(:use clojure.pprint)
(:require [datomic.api :as d]))
(def db-uri "datomic:dev:4334/ecommerce")
(defn abre-conexao []
(d/create-database db-uri)
(d/connect db-uri))
(defn apaga-banco []
(d/delete-database db-uri))
; Produtos
; id?
nome String 1 = = > Computador Novo
; slug String 1 ==> ... | null | https://raw.githubusercontent.com/alura-cursos/datomic-introducao/cfb214135fed0670ee90090b63a38d8287673ac6/aula2.1/ecommerce/src/ecommerce/db.clj | clojure | Produtos
id?
slug String 1 ==> /computador_novo
id_entidade atributo valor | (ns ecommerce.db
(:use clojure.pprint)
(:require [datomic.api :as d]))
(def db-uri "datomic:dev:4334/ecommerce")
(defn abre-conexao []
(d/create-database db-uri)
(d/connect db-uri))
(defn apaga-banco []
(d/delete-database db-uri))
nome String 1 = = > Computador Novo
preco ponto flutuante 1 = = > 3500.... |
3e55bd75cef2542a9c81269d6d469e0c18d5d5fcbd530fbc1869b6c84e0aa514 | karamellpelle/grid | FriendsObject.hs | grid is a game written in Haskell
Copyright ( C ) 2018
--
-- This file is part of grid.
--
-- grid is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation , either version 3 of the License , or
-- (at your optio... | null | https://raw.githubusercontent.com/karamellpelle/grid/56729e63ed6404fd6cfd6d11e73fa358f03c386f/designer/source/MEnv/Env/FriendsObject.hs | haskell |
This file is part of grid.
grid is free software: you can redistribute it and/or modify
(at your option) any later version.
grid is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GN... | grid is a game written in Haskell
Copyright ( C ) 2018
it under the terms of the GNU General Public License as published by
the Free Software Foundation , either version 3 of the License , or
You should have received a copy of the GNU General Public License
module MEnv.Env.FriendsObject
(
module MEnv... |
2322631cc4c34179d455fc9668dc3dae548d7e76bdbef456ff954b9237c854a1 | yuriy-chumak/ol | srfi-87.scm | (define-library (scheme srfi-87)
(import (scheme core) (srfi 87))
(export
(exports (srfi 87))) )
| null | https://raw.githubusercontent.com/yuriy-chumak/ol/0a38b3f9dbb720aa3fbc3e8219429ebe240c86bf/libraries/scheme/srfi-87.scm | scheme | (define-library (scheme srfi-87)
(import (scheme core) (srfi 87))
(export
(exports (srfi 87))) )
| |
15adf356ada2541eba555eb4a8e5d89ecebf3914046a229c85de2391771dc8e8 | herd/herdtools7 | LISALang.ml | (****************************************************************************)
(* the diy toolsuite *)
(* *)
, University College London , UK .
, INRIA Par... | null | https://raw.githubusercontent.com/herd/herdtools7/aef181181408f40dbdb4ed35c5338335a83d983f/litmus/LISALang.ml | ocaml | **************************************************************************
the diy toolsuite
en Automatique and ... | , University College London , UK .
, INRIA Paris - Rocquencourt , France .
Copyright 2017 - 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... |
7c1993094a0671f3a7e7dfa18326c1bff6d494ece4a1e2abea2e115ec18dadf1 | avelino/awesome-racket | main.rkt | #lang racket
(require markdown
racket/file
2htdp/batch-io)
(define readmemd (parse-markdown (file->string "./README.md")))
(define markdown2html (xexpr->string `
(html ()
(head () (title "A curated list of awesome Racket frameworks, libraries and software, maintained by Community - Awesome Racket"))
(body () ,... | null | https://raw.githubusercontent.com/avelino/awesome-racket/a9a58baf31484d555d986301d725c6a0eef70d44/main.rkt | racket | #lang racket
(require markdown
racket/file
2htdp/batch-io)
(define readmemd (parse-markdown (file->string "./README.md")))
(define markdown2html (xexpr->string `
(html ()
(head () (title "A curated list of awesome Racket frameworks, libraries and software, maintained by Community - Awesome Racket"))
(body () ,... | |
6cfde331926640a41ffceb81f226a83bddddc47e9bf3442dd88b971821972b3d | static-analysis-engineering/codehawk | bCHBCFunDeclarations.mli | = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
CodeHawk Binary Analyzer C Parser using CIL
Author : ------------------------------------------------------------------------------
The MIT Licens... | null | https://raw.githubusercontent.com/static-analysis-engineering/codehawk/418c95f77e6ece464df2ade519f27d95aa0119d6/CodeHawk/CHB/bchcil/bCHBCFunDeclarations.mli | ocaml | = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
CodeHawk Binary Analyzer C Parser using CIL
Author : ------------------------------------------------------------------------------
The MIT Licens... | |
1c1deb1d713fb0d2121c77373d128b527afd99e1317730a9bd57eff2cc8569f1 | manu291/dypgen | parse_tree.ml | (* parse_tree.ml *)
type expr =
| Lident of string
| Int of int
| Pair of (expr * expr)
| Cons of string * (int * (expr list))
type rhs = Token of string | Nt of (string * string)
let rec str_expr exp = match exp with
| Int i -> string_of_int i
| Pair (a,b) -> "("^(str_expr a)^","^(str_expr b)^")"
| Co... | null | https://raw.githubusercontent.com/manu291/dypgen/59d11b4c70b8d0971348ca6913839ff1fb4f9b5f/demos/demo_ocamllex/parse_tree.ml | ocaml | parse_tree.ml |
type expr =
| Lident of string
| Int of int
| Pair of (expr * expr)
| Cons of string * (int * (expr list))
type rhs = Token of string | Nt of (string * string)
let rec str_expr exp = match exp with
| Int i -> string_of_int i
| Pair (a,b) -> "("^(str_expr a)^","^(str_expr b)^")"
| Cons (cons,(0,_)) -> c... |
a90001da6be96fb23272750441420f7efa12639fff230834d4908233b339d530 | haskell/text | Lazy.hs | # LANGUAGE BangPatterns , DeriveDataTypeable #
# OPTIONS_HADDOCK not - home #
-- |
-- Module : Data.Text.Internal.Lazy
Copyright : ( c ) 2009 , 2010
--
-- License : BSD-style
-- Maintainer :
-- Stability : experimental
Portability : GHC
--
-- /Warning/: this is an internal module, and does not ha... | null | https://raw.githubusercontent.com/haskell/text/3488190f25e1ee5a5dea6b1a593d8a5819e76a1e/src/Data/Text/Internal/Lazy.hs | haskell | |
Module : Data.Text.Internal.Lazy
License : BSD-style
Maintainer :
Stability : experimental
/Warning/: this is an internal module, and does not have a stable
API or name. Functions in this module may not check or enforce
preconditions expected by public modules. Use at your own risk!
A module ... | # LANGUAGE BangPatterns , DeriveDataTypeable #
# OPTIONS_HADDOCK not - home #
Copyright : ( c ) 2009 , 2010
Portability : GHC
module Data.Text.Internal.Lazy
(
Text(..)
, chunk
, empty
, foldrChunks
, foldlChunks
, strictInvariant
, lazyInvariant
, showStructure
, d... |
cd05ffb193a0f2e93a9c3c0c5680c08f2ddceeed575ca5a715903c483e02b756 | reborg/clojure-essential-reference | 1.clj | < 1 >
(def document
(xml/parse
< 2 >
(keys document) ; <3>
(: tag : attrs : content ) | null | https://raw.githubusercontent.com/reborg/clojure-essential-reference/c37fa19d45dd52b2995a191e3e96f0ebdc3f6d69/TheToolbox/clojure.xml/1.clj | clojure | <3> | < 1 >
(def document
(xml/parse
< 2 >
(: tag : attrs : content ) |
f1ca43bdbc2ba7f6a9c8ce6cc528bed104c4d1930f1b63022f915850a788d5a5 | Bogdanp/racket-component | run-all-tests.rkt | #lang racket/base
(require rackunit
rackunit/text-ui)
(require "graph-tests.rkt"
"system-tests.rkt"
"testing-tests.rkt")
(define all-component-tests
(test-suite
"component"
graph-tests
system-tests
testing-tests))
(module+ main
(run-tests all-component-tests))
| null | https://raw.githubusercontent.com/Bogdanp/racket-component/3ca0ce9f27f7d2f0bc4e71434b558e3088d7da84/component-test/tests/component/run-all-tests.rkt | racket | #lang racket/base
(require rackunit
rackunit/text-ui)
(require "graph-tests.rkt"
"system-tests.rkt"
"testing-tests.rkt")
(define all-component-tests
(test-suite
"component"
graph-tests
system-tests
testing-tests))
(module+ main
(run-tests all-component-tests))
| |
9cd8c28fb11e555d3466527d8812b6bbeff43b07e7f514fb5d317dd2528b7b13 | rmculpepper/crypto | age.rkt | #lang racket/base
(require rackunit
racket/match
racket/file
racket/port
racket/class
racket/system
crypto
crypto/libcrypto
crypto/util/age
(submod crypto/util/age private-for-testing))
(crypto-factories libcrypto-factory)
(define sk1 (g... | null | https://raw.githubusercontent.com/rmculpepper/crypto/63e131c06d54756c3f36833ad0b700d56d6a75c8/crypto-test/tests/age.rkt | racket | ----------------------------------------
Fixed key generated by age-keygen:
----------------------------------------
Compatibility with age and age-keygen:
Apparently age-keygen prints public key to
stderr if stdout is not terminal.
------------------------------------------------------------
Reject low scrypt ... | #lang racket/base
(require rackunit
racket/match
racket/file
racket/port
racket/class
racket/system
crypto
crypto/libcrypto
crypto/util/age
(submod crypto/util/age private-for-testing))
(crypto-factories libcrypto-factory)
(define sk1 (g... |
4ffcea7ac2938fbb0c5be2447294aeb3f7dc04f5780aafe1c8944c01e9a6812f | 2600hz-archive/whistle | rebar_rel_utils.erl | -*- erlang - indent - level : 4;indent - tabs - mode : nil -*-
%% ex: ts=4 sw=4 et
%% -------------------------------------------------------------------
%%
rebar : Erlang Build Tools
%%
Copyright ( c ) 2009 ( )
%%
%% Permission is hereby granted, free of charge, to any person obtaining a copy
%% of this softw... | null | https://raw.githubusercontent.com/2600hz-archive/whistle/1a256604f0d037fac409ad5a55b6b17e545dcbf9/utils/rebar/src/rebar_rel_utils.erl | erlang | ex: ts=4 sw=4 et
-------------------------------------------------------------------
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
to use, copy, modify, merge, publish, distribute, sublicense, and/or sel... | -*- erlang - indent - level : 4;indent - tabs - mode : nil -*-
rebar : Erlang Build Tools
Copyright ( c ) 2009 ( )
in the Software without restriction , including without limitation the rights
copies of the Software , and to permit persons to whom the Software is
all copies or substantial portions of the... |
241078823e81541bf4aeae0edb3bafb95d582977cf685b8e027f2d2556ac185a | kadena-io/chainweb-node | MerkleLog.hs | # LANGUAGE AllowAmbiguousTypes #
{-# LANGUAGE BangPatterns #-}
{-# LANGUAGE ConstraintKinds #-}
# LANGUAGE DataKinds #
# LANGUAGE FlexibleContexts #
# LANGUAGE FlexibleInstances #
# LANGUAGE FunctionalDependencies #
{-# LANGUAGE GADTs #-}
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE PolyKinds #
{-# LANGUAGE RankNTypes... | null | https://raw.githubusercontent.com/kadena-io/chainweb-node/3358be570b3552aad8c75d685f6e250fd360feda/src/Chainweb/Crypto/MerkleLog.hs | haskell | # LANGUAGE BangPatterns #
# LANGUAGE ConstraintKinds #
# LANGUAGE GADTs #
# LANGUAGE OverloadedStrings #
# LANGUAGE RankNTypes #
|
Stability: experimental
This module provides a framework for hashing structured data and creating
inclusion proofs for hashed data.
An example of how to use this module can be found ... | # LANGUAGE AllowAmbiguousTypes #
# LANGUAGE DataKinds #
# LANGUAGE FlexibleContexts #
# LANGUAGE FlexibleInstances #
# LANGUAGE FunctionalDependencies #
# LANGUAGE PolyKinds #
# LANGUAGE RoleAnnotations #
# LANGUAGE ScopedTypeVariables #
# LANGUAGE TypeApplications #
# LANGUAGE TypeFamilies #
# LANGUAGE TypeOperators #... |
2648eedcc9e2ee76c192f566831985d65aacd15bcc6b102edff3b527f8d53c4f | zmaril/callcongressnow | index.cljs | (ns callcongressnow.index
(:require-macros [cljs.core.async.macros :refer [go]])
(:require [callcongressnow.legislators :refer [legislator-box]]
[cljs.core.async :refer [<!]]
[om.core :as om :include-macros true]
[om.dom :as dom :include-macros true]
[callcongressnow.... | null | https://raw.githubusercontent.com/zmaril/callcongressnow/c6a9eef9fd02b8141e87f34ff73a128c0d9cdc7f/src/cljs/callcongressnow/index.cljs | clojure | (ns callcongressnow.index
(:require-macros [cljs.core.async.macros :refer [go]])
(:require [callcongressnow.legislators :refer [legislator-box]]
[cljs.core.async :refer [<!]]
[om.core :as om :include-macros true]
[om.dom :as dom :include-macros true]
[callcongressnow.... | |
83771f5a2d8bd59706f7b2af4b722042a3b777b57f958ccfea9ea49969eb2e2d | BranchTaken/Hemlock | test_is_pow2.ml | open! Basis.Rudiments
open! Basis
open Zint
let test () =
let rec test = function
| [] -> ()
| u :: us' -> begin
File.Fmt.stdout
|> Fmt.fmt "is_pow2 "
|> fmt ~alt:true ~radix:Radix.Hex u
|> Fmt.fmt " -> "
|> Bool.fmt (is_pow2 u)
|> Fmt.fmt "\n"
|> ignor... | null | https://raw.githubusercontent.com/BranchTaken/Hemlock/a07e362d66319108c1478a4cbebab765c1808b1a/bootstrap/test/basis/zint/test_is_pow2.ml | ocaml | open! Basis.Rudiments
open! Basis
open Zint
let test () =
let rec test = function
| [] -> ()
| u :: us' -> begin
File.Fmt.stdout
|> Fmt.fmt "is_pow2 "
|> fmt ~alt:true ~radix:Radix.Hex u
|> Fmt.fmt " -> "
|> Bool.fmt (is_pow2 u)
|> Fmt.fmt "\n"
|> ignor... | |
80893d86e09e5602c2f7d89e22e4a2496c5c1b81ab34614d631eb6efa536d73c | cram-code/cram_core | equate-notification-mixin.lisp | Copyright ( c ) 2012 , < >
;;; 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 o... | null | https://raw.githubusercontent.com/cram-code/cram_core/984046abe2ec9e25b63e52007ed3b857c3d9a13c/cram_designators/src/cram-designators/equate-notification-mixin.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.
* Red... | Copyright ( c ) 2012 , < >
* Neither the name of the Intelligent Autonomous Systems Group/
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 ... |
8f90d8757834f9f28ae153fda426fef7b273120a9cc3e282eb11016c11ac5df9 | Frama-C/headache | skip.ml | (**************************************************************************)
(* *)
(* Headache *)
(* *)
... | null | https://raw.githubusercontent.com/Frama-C/headache/e9f5e89041e9949198e096bb8ca764731109b6a0/skip.ml | ocaml | ************************************************************************
Headache
... | , Projet Cristal , INRIA Rocquencourt
Copyright 2002
Institut National de Recherche en Informatique et en Automatique .
the GNU Library General Public License .
/~simonet/
type... |
94c123a254e9cc0035c40461337e1bae1ad7863943431fdb499b5269c91e7ac0 | snmsts/cl-langserver | listeners.lisp | (in-package :ls-base)
;;; Listeners
(defclass listener ()
((out :initarg :out :type stream :reader listener-out)
(in :initarg :in :type stream :reader listener-in)
(env)))
(defmacro listeners () `(connection-listeners *emacs-connection*))
(defmethod initialize-instance :after ((l listener) &key initial-env)... | null | https://raw.githubusercontent.com/snmsts/cl-langserver/3b1246a5d0bd58459e7a64708f820bf718cf7175/src/helitage/listeners.lisp | lisp | Listeners
here. | (in-package :ls-base)
(defclass listener ()
((out :initarg :out :type stream :reader listener-out)
(in :initarg :in :type stream :reader listener-in)
(env)))
(defmacro listeners () `(connection-listeners *emacs-connection*))
(defmethod initialize-instance :after ((l listener) &key initial-env)
(with-slot... |
947e32e7ae7f72089c80763e30e8cd91fdd76a5ded5ae777f93c3e2dbf4f3a9d | silky/quipper | Unboxing.hs | This file is part of Quipper . Copyright ( C ) 2011 - 2016 . Please see the
-- file COPYRIGHT for a list of authors, copyright holders, licensing,
-- and other details. All rights reserved.
--
-- ======================================================================
{-# LANGUAGE Rank2Types #-}
-- | This library pr... | null | https://raw.githubusercontent.com/silky/quipper/1ef6d031984923d8b7ded1c14f05db0995791633/QuipperLib/Unboxing.hs | haskell | file COPYRIGHT for a list of authors, copyright holders, licensing,
and other details. All rights reserved.
======================================================================
# LANGUAGE Rank2Types #
| This library provides functions for “unboxing” hierarchical circuits,
replacing calls to named subroutines b... | This file is part of Quipper . Copyright ( C ) 2011 - 2016 . Please see the
module QuipperLib.Unboxing where
import Quipper
import Quipper.Internal
import Quipper.Circuit (BoxId (..), RepeatFlag (..))
import Quipper.Monad (endpoints_of_wires_in_arity)
import Quipper.Generic (inline_subroutine, transform_unary)
... |
3732ec9fefa9b87019285258c64582775639f89ea05ff302f195d53250aa41ec | eamsden/Animas | TestElevatorMain.hs |
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* A F R P *
* *
* Example : Elevator *
* Purpose : Tes... | null | https://raw.githubusercontent.com/eamsden/Animas/2404d1de20982a337109fc6032cb77b022514f9d/examples/Elevator/TestElevatorMain.hs | haskell | Just for testing purposes.
Looks for interesting events by inspecting the input events
and the elevator position over the interval [0, t_max]. |
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* A F R P *
* *
* Example : Elevator *
* Purpose : Tes... |
06aeb411f0da1f1f740fccc0cc5eb3af86728fb029967f2881f54c1398726325 | Fresheyeball/Shpadoinkle | Example.hs | {-# LANGUAGE DeriveAnyClass #-}
# LANGUAGE DeriveGeneric #
# LANGUAGE DerivingStrategies #
module Shpadoinkle.Website.Types.Example where
import Data.Aeson (FromJSON, ToJSON)
import GHC.Generics (Generic)
import Shpadoinkl... | null | https://raw.githubusercontent.com/Fresheyeball/Shpadoinkle/5e5fb636fb0b0e99f04bae0d75cff722a10463ae/website/Shpadoinkle/Website/Types/Example.hs | haskell | # LANGUAGE DeriveAnyClass # | # LANGUAGE DeriveGeneric #
# LANGUAGE DerivingStrategies #
module Shpadoinkle.Website.Types.Example where
import Data.Aeson (FromJSON, ToJSON)
import GHC.Generics (Generic)
import Shpadoinkle (NFData... |
5a3bf5fcc191b73884f10a7bb23621a684f079f8266d3d013d2e2f971a230649 | ksaaskil/functional-programming-examples | Sphere.hs | module Geometry.Sphere
( volume
, area
)
where
volume :: Float -> Float
volume radius = (4.0 / 3.0) * pi * (radius ^ 3)
area :: Float -> Float
area radius = 4 * pi * (radius ^ 2)
| null | https://raw.githubusercontent.com/ksaaskil/functional-programming-examples/cbeb90f200d42e4a464dfb02fa5d7424bc12dd00/learn-you-a-haskell/src/Geometry/Sphere.hs | haskell | module Geometry.Sphere
( volume
, area
)
where
volume :: Float -> Float
volume radius = (4.0 / 3.0) * pi * (radius ^ 3)
area :: Float -> Float
area radius = 4 * pi * (radius ^ 2)
| |
312a5f73c64c2c6942baa75b3e18a22733cc076d31f33c0070689d374bd1d20f | herd/herdtools7 | key.ml | (****************************************************************************)
(* the diy toolsuite *)
(* *)
, University College London , UK .
, INRIA Par... | null | https://raw.githubusercontent.com/herd/herdtools7/b86aec8db64f8812e19468893deb1cdf5bbcfb83/tools/key.ml | ocaml | **************************************************************************
the diy toolsuite
en Automatique and ... | , University College London , UK .
, INRIA Paris - Rocquencourt , France .
Copyright 2010 - 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... |
2df148be5a841628a0058c2087707145e1711649336f4773e202af1132d4dd99 | clojure-interop/java-jdk | AttributeSet$CharacterAttribute.clj | (ns javax.swing.text.AttributeSet$CharacterAttribute
"This interface is the type signature that is expected
to be present on any attribute key that contributes to
character level presentation. This would be any attribute
that applies to a so-called run of
style."
(:refer-clojure :only [require comment defn... | null | https://raw.githubusercontent.com/clojure-interop/java-jdk/8d7a223e0f9a0965eb0332fad595cf7649d9d96e/javax.swing/src/javax/swing/text/AttributeSet%24CharacterAttribute.clj | clojure | (ns javax.swing.text.AttributeSet$CharacterAttribute
"This interface is the type signature that is expected
to be present on any attribute key that contributes to
character level presentation. This would be any attribute
that applies to a so-called run of
style."
(:refer-clojure :only [require comment defn... | |
916dcc4a29407daf647005662ed172aa3109923f798bac798c8e5c0446ecac2c | russmatney/reframe-games | views.cljs | (ns games.tetris.views
(:require
[re-frame.core :as rf]
[games.grid.views :as grid.views]
[games.subs :as subs]
[games.color :as color]))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Cells
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;... | null | https://raw.githubusercontent.com/russmatney/reframe-games/ff05f6ad4794e4505b6231522af0c90c3e212631/src/games/tetris/views.cljs | clojure |
Cells
Grid
Select game
| (ns games.tetris.views
(:require
[re-frame.core :as rf]
[games.grid.views :as grid.views]
[games.subs :as subs]
[games.color :as color]))
(defn cell->style [game-opts {:keys [color] :as c}]
(merge
(or (:cell-style game-opts) {})
(if color
{:background (color/cell->piece-color c)}
... |
b1248311dcb812056dc97e0b39df85c5752dac3984331baa497aeac57d5221d6 | ocaml/dune | client.ml | open Import
let client ?handler connection init ~f =
Client.client ?handler
~private_menu:[ Request Decl.build; Request Decl.status ]
connection init ~f
| null | https://raw.githubusercontent.com/ocaml/dune/20180d12149343d073cdea5860d01dc181702e6a/src/dune_rpc_impl/client.ml | ocaml | open Import
let client ?handler connection init ~f =
Client.client ?handler
~private_menu:[ Request Decl.build; Request Decl.status ]
connection init ~f
| |
0a7772e825e97b14b61107e060bcd9bd68380d62748be1721720652f9313c62e | borkdude/jet | project.clj | (defproject borkdude/jet
#=(clojure.string/trim
#=(slurp "resources/JET_VERSION"))
:description "jet"
:url ""
:scm {:name "git"
:url ""}
:license {:name "Eclipse Public License 1.0"
:url "-1.0.php"}
:source-paths ["src"]
:dependencies [[org.clojure/clojure "1.11.1"]
... | null | https://raw.githubusercontent.com/borkdude/jet/fea03680f50846a808afbb22b00dc732f98ebaeb/project.clj | clojure | (defproject borkdude/jet
#=(clojure.string/trim
#=(slurp "resources/JET_VERSION"))
:description "jet"
:url ""
:scm {:name "git"
:url ""}
:license {:name "Eclipse Public License 1.0"
:url "-1.0.php"}
:source-paths ["src"]
:dependencies [[org.clojure/clojure "1.11.1"]
... | |
45fcadcd812d15ae9a400da90a3fe6eacb0a262514c7a319125f38ee5d166f1f | gklijs/bkes-demo | project.clj | (defproject nl.openweb/projector "0.1.0-SNAPSHOT"
:description "FIXME: write description"
:url ""
:license {:name "Eclipse Public License"
:url "-v10.html"}
:plugins [[walmartlabs/shared-deps "0.2.8"]]
:dependencies [[org.apache.logging.log4j/log4j-slf4j-impl "2.14.0"]]
:dependency-sets [:cloju... | null | https://raw.githubusercontent.com/gklijs/bkes-demo/43d78683b41c2c8a1d06ab9fe4e6bea0c67cf16b/projector/project.clj | clojure | (defproject nl.openweb/projector "0.1.0-SNAPSHOT"
:description "FIXME: write description"
:url ""
:license {:name "Eclipse Public License"
:url "-v10.html"}
:plugins [[walmartlabs/shared-deps "0.2.8"]]
:dependencies [[org.apache.logging.log4j/log4j-slf4j-impl "2.14.0"]]
:dependency-sets [:cloju... | |
b51c70aee52748c80f72b45beae0549a5557f0d5d6a0853ed3989cfcc1547007 | gsakkas/rite | 0031.ml | BopG VarG VarG
depth - num
a + x
x * x
wList = wReverse
length2 > length1
pi *. x
a * a
pi *. y
i + j
a < b
a * x
| null | https://raw.githubusercontent.com/gsakkas/rite/958a0ad2460e15734447bc07bd181f5d35956d3b/data/sp14/clusters/0031.ml | ocaml | BopG VarG VarG
depth - num
a + x
x * x
wList = wReverse
length2 > length1
pi *. x
a * a
pi *. y
i + j
a < b
a * x
| |
1941ff9417df1e4ac153f1828486b59c8e745adcb99fb1e927393bdb68a56f32 | GaloisInc/ivory | Control.hs | # LANGUAGE DataKinds #
# LANGUAGE TypeOperators #
# LANGUAGE FlexibleContexts #
# LANGUAGE TypeFamilies #
module Ivory.Stdlib.Control
( ifte
, when
, unless
, cond_, cond, (==>), Cond()
) where
import Ivory.Language
ifte :: ( IvoryStore a
, IvoryZero ('Stored a)
, GetAlloc eff ~ 'Scope s
... | null | https://raw.githubusercontent.com/GaloisInc/ivory/53a0795b4fbeb0b7da0f6cdaccdde18849a78cd6/ivory-stdlib/src/Ivory/Stdlib/Control.hs | haskell | | A multi-way if. This is useful for avoiding an explosion of
nesting and parentheses in complex conditionals.
Instead of writing nested chains of ifs:
> (ifte_ (x >? 0)
> (store result 0)))
You can write:
> cond_
> , true ==> store result 0
> ]
Note that "==>" is non-associative and h... | # LANGUAGE DataKinds #
# LANGUAGE TypeOperators #
# LANGUAGE FlexibleContexts #
# LANGUAGE TypeFamilies #
module Ivory.Stdlib.Control
( ifte
, when
, unless
, cond_, cond, (==>), Cond()
) where
import Ivory.Language
ifte :: ( IvoryStore a
, IvoryZero ('Stored a)
, GetAlloc eff ~ 'Scope s
... |
d82aa3d830f257a4bfc0f0b50678d2487544e383e14c450cd10c5b60659e40a9 | gildor478/ocaml-fileutils | FileUtilWHICH.ml | (******************************************************************************)
(* ocaml-fileutils: files and filenames common operations *)
(* *)
Copyright ( C ) 2003 - 2014 ,
(* ... | null | https://raw.githubusercontent.com/gildor478/ocaml-fileutils/9ad8d2ee342c551391f2a9873de01982d24b36d5/src/lib/fileutils/FileUtilWHICH.ml | ocaml | ****************************************************************************
ocaml-fileutils: files and filenames common operations
This libra... | Copyright ( C ) 2003 - 2014 ,
the Free Software Foundation ; either version 2.1 of the License , or ( at
You should have received a copy of the GNU Lesser General Public License
along with this library ; if not , write to the Free Software Foundation ,
Inc. , 51 Franklin St , Fifth Floor , Bo... |
add0d420475e622cdb3ae43cdd1f6444a25400da5507580bf3a3baa955e95358 | jackrusher/sparkledriver | project.clj | (defproject sparkledriver "0.2.4"
:description "A clojure wrapper for jBrowserDriver, which is a Selenium-compatible wrapper around JFX embedded WebKit."
:url ""
:license {:name "Eclipse Public License"
:url "-v10.html"}
:dependencies [[org.clojure/clojure "1.9.0"]
[com.machinepubli... | null | https://raw.githubusercontent.com/jackrusher/sparkledriver/375885dcad85e37ae2e0d624bc005016ada2982e/project.clj | clojure | (defproject sparkledriver "0.2.4"
:description "A clojure wrapper for jBrowserDriver, which is a Selenium-compatible wrapper around JFX embedded WebKit."
:url ""
:license {:name "Eclipse Public License"
:url "-v10.html"}
:dependencies [[org.clojure/clojure "1.9.0"]
[com.machinepubli... | |
ac49aaf49f2d7a2714bf42c86dbf9ef9ebfa606050d63f35dd6d79e3f2b10014 | racket/gui | gui.rkt | (module gui scheme
(require scheme/gui/base)
(provide (all-from-out scheme)
(all-from-out scheme/gui/base)))
| null | https://raw.githubusercontent.com/racket/gui/d1fef7a43a482c0fdd5672be9a6e713f16d8be5c/gui-lib/scheme/gui.rkt | racket | (module gui scheme
(require scheme/gui/base)
(provide (all-from-out scheme)
(all-from-out scheme/gui/base)))
| |
7c0b094b032f5bfefe41e051e750385d51759ed761686a969d2f6beba5c7e309 | freckle/stackctl | Deploy.hs | module Stackctl.Spec.Deploy
( DeployOptions(..)
, DeployConfirmation(..)
, parseDeployOptions
, runDeploy
) where
import Stackctl.Prelude
import Blammo.Logging.Logger (pushLoggerLn)
import qualified Data.Text as T
import Data.Time (defaultTimeLocale, formatTime, utcToLocalZonedTime)
import Options.Applicati... | null | https://raw.githubusercontent.com/freckle/stackctl/fdb99c911dd118dee4a46358da98ceedcebc2e09/src/Stackctl/Spec/Deploy.hs | haskell | brittany-disable-next-binding
tailing from, so do that part synchronously
^ StackEventId
Without this small delay before looping, our requests seem to hang
intermittently (without errors) and often we miss events.
Tail from the next "last id". If we got no events, be sure to pass along
any last-id we were given | module Stackctl.Spec.Deploy
( DeployOptions(..)
, DeployConfirmation(..)
, parseDeployOptions
, runDeploy
) where
import Stackctl.Prelude
import Blammo.Logging.Logger (pushLoggerLn)
import qualified Data.Text as T
import Data.Time (defaultTimeLocale, formatTime, utcToLocalZonedTime)
import Options.Applicati... |
99ddcdb33707eed0c8b1dc700868e233c8986e7acff5bf055447d6a6ca586248 | hdbc/hdbc-odbc | ODBC.hs | |
Module : Database . HDBC.ODBC
Copyright : Copyright ( C ) 2005
License : BSD3
Maintainer : < >
Stability : provisional
Portability : portable
HDBC driver interface for ODBC 3.x
Written by , jgoerzen\@complete.org
Module : Database.HDBC.ODBC
Copyri... | null | https://raw.githubusercontent.com/hdbc/hdbc-odbc/06833d77799f16634d2038bcdc308c35d4752cdd/Database/HDBC/ODBC.hs | haskell | |
Module : Database . HDBC.ODBC
Copyright : Copyright ( C ) 2005
License : BSD3
Maintainer : < >
Stability : provisional
Portability : portable
HDBC driver interface for ODBC 3.x
Written by , jgoerzen\@complete.org
Module : Database.HDBC.ODBC
Copyri... | |
be5f6c03802ea99f13bd8d0e32d76bfe14d943352ddde663b6f6e2057c79692c | skanev/playground | 45-tests.scm | (require rackunit rackunit/text-ui)
(load "../45.scm")
(define sicp-1.45-tests
(test-suite
"Tests for SICP exercise 1.45"
(check-= (nth-root 2 4) 2 0.000001)
(check-= (nth-root 3 8) 2 0.000001)
(check-= (nth-root 4 16) 2 0.000001)
(check-= (nth-root 5 32) 2 0.000001)
(check-= (nth-root 8 256... | null | https://raw.githubusercontent.com/skanev/playground/d88e53a7f277b35041c2f709771a0b96f993b310/scheme/sicp/01/tests/45-tests.scm | scheme | (require rackunit rackunit/text-ui)
(load "../45.scm")
(define sicp-1.45-tests
(test-suite
"Tests for SICP exercise 1.45"
(check-= (nth-root 2 4) 2 0.000001)
(check-= (nth-root 3 8) 2 0.000001)
(check-= (nth-root 4 16) 2 0.000001)
(check-= (nth-root 5 32) 2 0.000001)
(check-= (nth-root 8 256... | |
1e06d87a6295b1213adcf411f5fb8c5e2e361d9df72586e611df8bcadcc5ad37 | ghilesZ/geoml | constraint.ml | (**The linear constraint module*)
type comp = Lt | Gt | Leq | Geq
let neg = function
| Lt -> Geq
| Leq -> Gt
| Gt -> Leq
| Geq -> Lt
let compf = function
| Lt -> ( < )
| Leq -> ( <= )
| Gt -> ( > )
| Geq -> ( >= )
type t = Line.t * comp
let print fmt ((l,cmp):t) =
let comp_to_string (c:comp) =... | null | https://raw.githubusercontent.com/ghilesZ/geoml/a239499dabbbfbf74bae73a105ed567546f43312/src/constraint.ml | ocaml | *The linear constraint module | type comp = Lt | Gt | Leq | Geq
let neg = function
| Lt -> Geq
| Leq -> Gt
| Gt -> Leq
| Geq -> Lt
let compf = function
| Lt -> ( < )
| Leq -> ( <= )
| Gt -> ( > )
| Geq -> ( >= )
type t = Line.t * comp
let print fmt ((l,cmp):t) =
let comp_to_string (c:comp) =
match c with
| Lt -> "<"
... |
9e5796d96d2da12fe4e5b3c9fc1312250fae7b1ed2841b9fcc55a41718726979 | inhabitedtype/ocaml-aws | getMaintenanceWindowTask.mli | open Types
type input = GetMaintenanceWindowTaskRequest.t
type output = GetMaintenanceWindowTaskResult.t
type error = Errors_internal.t
include
Aws.Call with type input := input and type output := output and type error := error
| null | https://raw.githubusercontent.com/inhabitedtype/ocaml-aws/3bc554af7ae7ef9e2dcea44a1b72c9e687435fa9/libraries/ssm/lib/getMaintenanceWindowTask.mli | ocaml | open Types
type input = GetMaintenanceWindowTaskRequest.t
type output = GetMaintenanceWindowTaskResult.t
type error = Errors_internal.t
include
Aws.Call with type input := input and type output := output and type error := error
| |
631a2d5f2778c18a29ddc4289c5bf8227abe03f6cab1c75121cfd97c973489e5 | stackbuilders/tutorials | Main.hs | module Main (main) where
import Shortener (shortener)
main :: IO ()
main =
shortener
| null | https://raw.githubusercontent.com/stackbuilders/tutorials/d80de4b31407754c2a01eff7eeed65550d9baac8/tutorials/haskell/getting-started-with-haskell-projects-using-scotty/code/app/Main.hs | haskell | module Main (main) where
import Shortener (shortener)
main :: IO ()
main =
shortener
| |
09765f9c6705e839a7fea389abd7710cadd7d63974bb932fc3b98181566b812b | valerauko/kitsune-alpha | common.clj | (ns kitsune.spec.common
(:require [clojure.spec.alpha :as s]
[org.bovinegenius [exploding-fish :refer [absolute?]]]))
(s/def ::id pos-int?)
(s/def ::url
(s/with-gen
absolute?
#(s/gen uri?)))
(s/def ::bool
(s/or :bool boolean?
:str #{"true" "false"}))
(s/def ::created-at inst?)
| null | https://raw.githubusercontent.com/valerauko/kitsune-alpha/34ca08e4013541aeaf1a5a5786f3189ff17c1a58/src/kitsune/spec/common.clj | clojure | (ns kitsune.spec.common
(:require [clojure.spec.alpha :as s]
[org.bovinegenius [exploding-fish :refer [absolute?]]]))
(s/def ::id pos-int?)
(s/def ::url
(s/with-gen
absolute?
#(s/gen uri?)))
(s/def ::bool
(s/or :bool boolean?
:str #{"true" "false"}))
(s/def ::created-at inst?)
| |
3cff6b03994c880793785b319577e05959583383fc1e9cd6ca3a24136b6d382b | chrisdone/prana | Eval.hs | # LANGUAGE NamedFieldPuns #
{-# LANGUAGE BangPatterns #-}
# LANGUAGE TemplateHaskell #
# LANGUAGE UnboxedTuples #
# LANGUAGE MagicHash #
# LANGUAGE RecursiveDo #
# LANGUAGE FlexibleInstances #
# LANGUAGE LambdaCase #
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE StandaloneDeriving #
-- |
module Prana.Interpreter.Eval... | null | https://raw.githubusercontent.com/chrisdone/prana/f2e45538937d326aff562b6d49296eaedd015662/prana-interpreter/src/Prana/Interpreter/Eval.hs | haskell | # LANGUAGE BangPatterns #
# LANGUAGE OverloadedStrings #
|
Yes, this is a function, and it's weird. I've
observed a case where the scrutinee binding is
shadowed by a pattern binding. Weird, but
guarantee. In any case, rewrite this
later. There is now a test case for this code,
so that's OK.
putStrLn ("altDataC... | # LANGUAGE NamedFieldPuns #
# LANGUAGE TemplateHaskell #
# LANGUAGE UnboxedTuples #
# LANGUAGE MagicHash #
# LANGUAGE RecursiveDo #
# LANGUAGE FlexibleInstances #
# LANGUAGE LambdaCase #
# LANGUAGE StandaloneDeriving #
module Prana.Interpreter.Eval where
import Control.Monad.Reader
import qualified Data.By... |
28e5695c2bc43a001d423bd22143f6331de86eff038f0f427f7b042211c0b38c | racket/typed-racket | tc-app-eq.rkt | #lang racket/unit
(require "../../utils/utils.rkt"
"signatures.rkt"
"utils.rkt"
(only-in "../../infer/infer.rkt" intersect)
syntax/parse syntax/stx racket/match racket/unsafe/undefined
"../signatures.rkt"
"../tc-funapp.rkt"
"../../types/abbrev.rkt"
... | null | https://raw.githubusercontent.com/racket/typed-racket/6ea20bec8d41e1a188d7f831c35423293a89c98e/typed-racket-lib/typed-racket/typecheck/tc-app/tc-app-eq.rkt | racket | comparators that inform the type system
`=' is not included. Its type is more useful than this typing rule.
make sure the whole expression is type correct
typecheck eq? applications
identifier expr expr -> tc-results
In this case, try to find there is an overlap between t1 and t2
the overlap doesn't exist so we ... | #lang racket/unit
(require "../../utils/utils.rkt"
"signatures.rkt"
"utils.rkt"
(only-in "../../infer/infer.rkt" intersect)
syntax/parse syntax/stx racket/match racket/unsafe/undefined
"../signatures.rkt"
"../tc-funapp.rkt"
"../../types/abbrev.rkt"
... |
f9af15a81ccf534aa8ac841b79aaea791fe5a4bf3c3ef2cae3cce51b9cfd0a31 | hypernumbers/hypernumbers | factory.erl | %%%-------------------------------------------------------------------
@author
( C ) 2011 - 2014 , Hypernumbers.com
@doc provisions Hypernumbers websites
%%% @end
%%% Created : by
%%%-------------------------------------------------------------------
%%%-------------------------------------------... | null | https://raw.githubusercontent.com/hypernumbers/hypernumbers/281319f60c0ac60fb009ee6d1e4826f4f2d51c4e/lib/hypernumbers-1.0/src/factory.erl | erlang | -------------------------------------------------------------------
@end
Created : by
-------------------------------------------------------------------
-------------------------------------------------------------------
LICENSE
This program is free software: you can redistribute it and/or modify
This progra... | @author
( C ) 2011 - 2014 , Hypernumbers.com
@doc provisions Hypernumbers websites
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation version 3
You should have received a copy of the GNU Affero General Public License
-module(factory).
-e... |
cc38ed5ade1ed64540dc747d89fd1598a0fc0860a997e80344439be9c50a82e6 | scrintal/heroicons-reagent | folder.cljs | (ns com.scrintal.heroicons.outline.folder)
(defn render []
[:svg {:xmlns ""
:fill "none"
:viewBox "0 0 24 24"
:strokeWidth "1.5"
:stroke "currentColor"
:aria-hidden "true"}
[:path {:strokeLinecap "round"
:strokeLinejoin "round"
... | null | https://raw.githubusercontent.com/scrintal/heroicons-reagent/572f51d2466697ec4d38813663ee2588960365b6/src/com/scrintal/heroicons/outline/folder.cljs | clojure | (ns com.scrintal.heroicons.outline.folder)
(defn render []
[:svg {:xmlns ""
:fill "none"
:viewBox "0 0 24 24"
:strokeWidth "1.5"
:stroke "currentColor"
:aria-hidden "true"}
[:path {:strokeLinecap "round"
:strokeLinejoin "round"
... | |
812dc65c3eee9dd62fadeba4452d0840c6bad8ec879f498343ef7e4546411ed2 | sheyll/newtype-zoo | Wanted.hs | -- | Indicate that something is `Wanted`.
module NewtypeZoo.Wanted
( Wanted(Wanted)
, _theWanted
, theWanted
) where
import Control.DeepSeq (NFData)
import Control.Monad.Fix (MonadFix)
import Control.Monad.Zip (MonadZip)
import Data.Bits (Bits,FiniteBits)
import ... | null | https://raw.githubusercontent.com/sheyll/newtype-zoo/0e67717cbcd9233d9c26b6aacb4c6f8bba6ef5f7/src/NewtypeZoo/Wanted.hs | haskell | | Indicate that something is `Wanted`. | module NewtypeZoo.Wanted
( Wanted(Wanted)
, _theWanted
, theWanted
) where
import Control.DeepSeq (NFData)
import Control.Monad.Fix (MonadFix)
import Control.Monad.Zip (MonadZip)
import Data.Bits (Bits,FiniteBits)
import Data.Copointed (Copointed)
import... |
16ea9c7eeead9449266452811cbb9c683f96661cf7187194e7216d65905e73b3 | jwiegley/notes | Delta.hs | # LANGUAGE TypeFamilies #
module Delta where
class Delta a where
type Change a
data Delta a => Changed a = Unchanged | Changed (Change a)
assertChanges :: Delta a => a -> a -> Changed a -> IO ()
assertChanges = undefined
data IntChange = IntChange Int Int
data Product = Product
{ foo :: Int,
bar :: Int,
... | null | https://raw.githubusercontent.com/jwiegley/notes/762c803de16743df4f52a5762437dcf9252b31cd/haskell/Delta.hs | haskell | GENERATED
GENERATED
GENERATED
GENERATED
GENERATED | # LANGUAGE TypeFamilies #
module Delta where
class Delta a where
type Change a
data Delta a => Changed a = Unchanged | Changed (Change a)
assertChanges :: Delta a => a -> a -> Changed a -> IO ()
assertChanges = undefined
data IntChange = IntChange Int Int
data Product = Product
{ foo :: Int,
bar :: Int,
... |
27f6767eaf741fca4fc32e48a11be241662468a9ed84940a914a21dfe2cdaa8e | B-Lang-org/bsc | ACleanup.hs | module ACleanup(aCleanup) where
import ASyntax
import ASyntaxUtil
import Prim
import DisjointTest(DisjointTestState, initDisjointTestState,
addADefToDisjointTestState, checkDisjointExprWithCtx)
import Data.Maybe
import Flags(Flags)
import Control.Monad.State
import FStringCompat(mkFString)
import Po... | null | https://raw.githubusercontent.com/B-Lang-org/bsc/bd141b505394edc5a4bdd3db442a9b0a8c101f0f/src/comp/ACleanup.hs | haskell | =====
Naming conventions
=====
A state monad for generating identifiers and capturing definitions during the cleanup pass
prefix is acleanupPref
the state monad itself
definitions of the value methods in the interface
then we need to include the method's ready condiion
don't cleanup assumption actions because ... | module ACleanup(aCleanup) where
import ASyntax
import ASyntaxUtil
import Prim
import DisjointTest(DisjointTestState, initDisjointTestState,
addADefToDisjointTestState, checkDisjointExprWithCtx)
import Data.Maybe
import Flags(Flags)
import Control.Monad.State
import FStringCompat(mkFString)
import Po... |
c74832701727648dacddbf589378e89c1ff949d887c04b7ffdd3e7430ca9e3be | vaclavsvejcar/headroom | Readers.hs | {-# LANGUAGE OverloadedStrings #-}
# LANGUAGE TypeApplications #
# LANGUAGE NoImplicitPrelude #
-- |
-- Module : Headroom.Command.Readers
-- Description : Custom readers for /optparse-applicative/ library
Copyright : ( c ) 2019 - 2022
-- License : BSD-3-Clause
-- Maintainer :
-- Stability : experim... | null | https://raw.githubusercontent.com/vaclavsvejcar/headroom/3b20a89568248259d59f83f274f60f6e13d16f93/src/Headroom/Command/Readers.hs | haskell | # LANGUAGE OverloadedStrings #
|
Module : Headroom.Command.Readers
Description : Custom readers for /optparse-applicative/ library
License : BSD-3-Clause
Maintainer :
Stability : experimental
Portability : POSIX
This module contains custom readers required by the /optparse-applicative/
| Reader f... | # LANGUAGE TypeApplications #
# LANGUAGE NoImplicitPrelude #
Copyright : ( c ) 2019 - 2022
library to parse data types such as ' LicenseType ' or ' FileType ' .
module Headroom.Command.Readers
( licenseReader
, licenseTypeReader
, regexReader
, templateRefReader
, parseLicense
)
where
... |
0d689c1a139cefdedf8fe16ca8cd98ec73f27c57f0183cfcfe62d6bfa22e7cce | josefs/Gradualizer | map_update_with_record_field.erl | -module(map_update_with_record_field).
-export([mapup3/2]).
%% When record `r' is defined or included and used directly in the map type definition,
then ` mapup3 ' passes typechecking .
%-record(r, {}).
%-type m() :: #{rec := #r{}}.
%% However, when the actual remote type and corresponding remote record is used,
%... | null | https://raw.githubusercontent.com/josefs/Gradualizer/208f5816b0157f282212fc036ba7560f0822f9fc/test/should_pass/map_update_with_record_field.erl | erlang | When record `r' is defined or included and used directly in the map type definition,
-record(r, {}).
-type m() :: #{rec := #r{}}.
However, when the actual remote type and corresponding remote record is used,
then `mapup3' fails to typecheck, although it still should. | -module(map_update_with_record_field).
-export([mapup3/2]).
then ` mapup3 ' passes typechecking .
-type m() :: #{rec := user_types:my_empty_record()}.
-spec mapup3(m(), user_types:my_empty_record()) -> m().
mapup3(TypedMap, R) ->
TypedMap#{rec => R}.
|
0835efdc83cedd91ebef9b68146759698b0703f0c496678b0f448a5e0d2872e6 | kmi/irs | new-ontology.lisp | ;;; Mode: Lisp; Package: web-onto
Author :
The Open University
(in-package "WEB-ONTO")
(defun get-undefined-ontology-uses (ontologies)
(mapcan #'(lambda (ontology)
(unless (get-ontology ontology)
(list ontology)))
ontologies))
(defun new-ontology (stream request-str... | null | https://raw.githubusercontent.com/kmi/irs/e1b8d696f61c6b6878c0e92d993ed549fee6e7dd/src/webonto/new-ontology.lisp | lisp | Mode: Lisp; Package: web-onto
(add-to-list-of-ontology-home-pathnames ontology-name ontology-type)
(io::io-mkdir
(namestring directory)
directory))
(defun setup-load-files ()
(mapc #'(lambda (ontology-and-load-file)
(cdr ontology-and-load-file)))
*load-files*))
:allowed-editors (~{~s ~}~... |
Author :
The Open University
(in-package "WEB-ONTO")
(defun get-undefined-ontology-uses (ontologies)
(mapcan #'(lambda (ontology)
(unless (get-ontology ontology)
(list ontology)))
ontologies))
(defun new-ontology (stream request-string)
(with-input-from-string (re... |
0ec7cc6db9b8da9cdb5a2a355038bcd8cce743b9821698ad414e8c4d1194930f | fumieval/extensible | Bits.hs | # LANGUAGE UndecidableInstances , ScopedTypeVariables , MultiParamTypeClasses , TypeFamilies #
# LANGUAGE GeneralizedNewtypeDeriving , DeriveGeneric #
#if __GLASGOW_HASKELL__ < 806
{-# LANGUAGE TypeInType #-}
#endif
-----------------------------------------------------------------------
-- |
-- Module : Data.Exte... | null | https://raw.githubusercontent.com/fumieval/extensible/6b119e922c1c109c2812d4ad3a2153838528c39d/src/Data/Extensible/Bits.hs | haskell | # LANGUAGE TypeInType #
---------------------------------------------------------------------
|
Module : Data.Extensible.Bits
License : BSD3
Bit-packed records
---------------------------------------------------------------------
| Conversion between a value and a bit representation.
Instances of `F... | # LANGUAGE UndecidableInstances , ScopedTypeVariables , MultiParamTypeClasses , TypeFamilies #
# LANGUAGE GeneralizedNewtypeDeriving , DeriveGeneric #
#if __GLASGOW_HASKELL__ < 806
#endif
Copyright : ( c ) 2018
Maintainer : < >
module Data.Extensible.Bits (BitProd(..)
, FromBits(..)
, TotalBits
... |
6cc28dc7369d9948ef974b2eaf740fef13a5d39d37426ddee0d848662ed58de3 | orchid-hybrid/microKanren-sagittarius | t1.scm | (import (scheme base)
(test-check)
(miruKanren mk-basic)
(examples closure))
(test-check "record #1"
(run* (lambda (q) (== q 'x)))
'((x where)))
(test-check "record #2"
(run* (lambda (q) (== (closure q) 'x)))
'())
(test-check "record #3"
(run* (lambda (q) (== (closure q) q)... | null | https://raw.githubusercontent.com/orchid-hybrid/microKanren-sagittarius/9e740bbf94ed2930f88bbcf32636d3480934cfbb/t/records/t1.scm | scheme |
(run* (lambda (q) (== (closure 'x) q)))
`((,(closure 'x) where))) | (import (scheme base)
(test-check)
(miruKanren mk-basic)
(examples closure))
(test-check "record #1"
(run* (lambda (q) (== q 'x)))
'((x where)))
(test-check "record #2"
(run* (lambda (q) (== (closure q) 'x)))
'())
(test-check "record #3"
(run* (lambda (q) (== (closure q) q)... |
34919915a5ed994b8c3ebe4cab13967006c53e89c67b2415983dc7aed64f9559 | hyperfiddle/electric | reactor1.clj | (ns dustin.reactor1
(:require
[minitest :refer [tests]]
[missionary.core :as m :refer [? ?? ?! ap]]))
(defn sleep-emit [delays]
(ap (let [n (?? (m/enumerate delays))]
(? (m/sleep n n)))))
(do
(def !x (atom 0))
(def effect (partial println 'effect))
(def process (m/reactor
(... | null | https://raw.githubusercontent.com/hyperfiddle/electric/1c6c3891cbf13123fef8d33e6555d300f0dac134/scratch/dustin/y2021/missionary/reactor1.clj | clojure | reactors produce effects
(def !out (>out #(prn :ready) #(prn :done)))
(def process-cancel (process #(prn :process/success) #()))
cancelled | (ns dustin.reactor1
(:require
[minitest :refer [tests]]
[missionary.core :as m :refer [? ?? ?! ap]]))
(defn sleep-emit [delays]
(ap (let [n (?? (m/enumerate delays))]
(? (m/sleep n n)))))
(do
(def !x (atom 0))
(def effect (partial println 'effect))
(def process (m/reactor
(... |
110056419a5a96cd43dadd05b6e5d0d344b07bd9f01d8cbfb882ec8576413103 | lisp/de.setf.xml | namespace.lisp | -*- Mode : lisp ; Syntax : ansi - common - lisp ; Base : 10 ; Package : xml - query - data - model ; -*-
(in-package :xml-query-data-model)
(setq xml-query-data-model:*namespace*
(xml-query-data-model:defnamespace "#"
(:use)
(:ni... | null | https://raw.githubusercontent.com/lisp/de.setf.xml/827681c969342096c3b95735d84b447befa69fa6/namespaces/www-w3-org/2004/02/skos/core/namespace.lisp | lisp | Syntax : ansi - common - lisp ; Base : 10 ; Package : xml - query - data - model ; -*-
(xqdm:find-namespace "#" :if-does-not-exist :load) |
(in-package :xml-query-data-model)
(setq xml-query-data-model:*namespace*
(xml-query-data-model:defnamespace "#"
(:use)
(:nicknames)
(:export
"altLa... |
8e57cf5f4efcd83085b761a7a3cf27d6830b44d22feeb8b62168e4cb1e079003 | benjaminselfridge/logix | Main.hs | |
Module : Main
Description : Command line logix tool .
Copyright : ( c ) , 2017
License : :
Stability : experimental
Module : Main
Description : Command line logix tool.
Copyright : (c) Ben Selfridge, 2017
License : BSD3
Maintainer :
Stability : experimental
-}
mo... | null | https://raw.githubusercontent.com/benjaminselfridge/logix/4c19c1cf036b1d4ceb4fe05e7d43c9cff32e80a1/src/Main.hs | haskell | TODO: Add utility to hide/show left-hand assumptions, and another utility to
specifically list them
TODO: make help more readable by splitting it into sections
of printing it as [no free], just add a little qualifier string at the end.
TODO: add "assume" command, maintaining a list of formulas as assumptions that ... | |
Module : Main
Description : Command line logix tool .
Copyright : ( c ) , 2017
License : :
Stability : experimental
Module : Main
Description : Command line logix tool.
Copyright : (c) Ben Selfridge, 2017
License : BSD3
Maintainer :
Stability : experimental
-}
mo... |
389167be2df25c0f00f77e6b5abc220dbe98a1b8867d7560566850de011eb5a3 | facebook/flow | modulename.ml |
* Copyright ( c ) Meta Platforms , Inc. and affiliates .
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree .
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in t... | null | https://raw.githubusercontent.com/facebook/flow/741104e69c43057ebd32804dd6bcc1b5e97548ea/src/common/modulename/modulename.ml | ocaml |
* Copyright ( c ) Meta Platforms , Inc. and affiliates .
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree .
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in t... | |
eba8ab543936f0f580bef4e2b9600c0a32b41a00abfeb5a7dfae32f0039cbebb | kfish/const-math-ghc-plugin | 4383.hs | main = print (0.5 ^ 1030)
| null | https://raw.githubusercontent.com/kfish/const-math-ghc-plugin/c1d269e0ddc72a782c73cca233ec9488f69112a9/tests/ghc-7.4/4383.hs | haskell | main = print (0.5 ^ 1030)
| |
c7cb74a4d91be510052ecf97bb79a7edc7fb99a9d34a62087258b7b1b01a46c4 | runa-labs/clj-hazelcast | project.clj | (defproject org.clojars.runa/clj-hazelcast "1.2.1"
:description "Clojure library for the Hazelcast p2p cluster"
:dependencies [[org.clojure/clojure "1.6.0"]
[org.clojars.runa/clj-kryo "1.5.0"]
[com.hazelcast/hazelcast "3.4"]]
:profiles {:provided {:dependencies [[org.clojure/tool... | null | https://raw.githubusercontent.com/runa-labs/clj-hazelcast/ba577984796e6e8e876554b10c6ebbb763ca5b44/project.clj | clojure | (defproject org.clojars.runa/clj-hazelcast "1.2.1"
:description "Clojure library for the Hazelcast p2p cluster"
:dependencies [[org.clojure/clojure "1.6.0"]
[org.clojars.runa/clj-kryo "1.5.0"]
[com.hazelcast/hazelcast "3.4"]]
:profiles {:provided {:dependencies [[org.clojure/tool... | |
c08938f352149058d05802352e6bb807277ecd8c28cf94dd79d09b981a0ae6ca | bobatkey/CS316-17 | Lec15.hs | module Lec15 where
import Control.Applicative hiding (some, many)
import Control.Monad
import Data.Char
LECTURE 15 : MORE MONADIC PARSING
First we 'll recap the ' Parser ' type we defined in the last lecture .
Parsers of things are functions from strings to the possibility of
pairs of things and s... | null | https://raw.githubusercontent.com/bobatkey/CS316-17/36eb67c335cd0e6f5b7a4b8eafdea3cd4b715e0c/lectures/Lec15.hs | haskell | fmap :: (a -> b) -> Parser a -> Parser b
pure :: a -> Parser a
So far, we haven't yet defined anything that actually consumes any
input. We do this by defining the 'char' parser. This reads a
single character from the input, or fails if that is not possible.
---------------------------------------------------... | module Lec15 where
import Control.Applicative hiding (some, many)
import Control.Monad
import Data.Char
LECTURE 15 : MORE MONADIC PARSING
First we 'll recap the ' Parser ' type we defined in the last lecture .
Parsers of things are functions from strings to the possibility of
pairs of things and s... |
d2bb9d652c23453f4f8d1583cc6304513abc8e0fed1564ea4b13df3acb95d4f3 | tolysz/ghcjs-stack | ConfiguredConversion.hs | module Distribution.Client.Dependency.Modular.ConfiguredConversion
( convCP
) where
import Data.Maybe
import Prelude hiding (pi)
import Distribution.Package (UnitId)
import Distribution.Client.Types
import Distribution.Client.Dependency.Types (ResolverPackage(..))
import qualified Distribution.Client.Package... | null | https://raw.githubusercontent.com/tolysz/ghcjs-stack/83d5be83e87286d984e89635d5926702c55b9f29/special/cabal/cabal-install/Distribution/Client/Dependency/Modular/ConfiguredConversion.hs | haskell | | Converts from the solver specific result @CP QPN@ into
a 'ResolverPackage', which can then be converted into
the install plan. | module Distribution.Client.Dependency.Modular.ConfiguredConversion
( convCP
) where
import Data.Maybe
import Prelude hiding (pi)
import Distribution.Package (UnitId)
import Distribution.Client.Types
import Distribution.Client.Dependency.Types (ResolverPackage(..))
import qualified Distribution.Client.Package... |
a48b5a8a2959b1a74b4937a9d586929bafe8e8625a3114ffd26abe7ddf17b9ea | lulf/hcoap | Main.hs | import Network.CoAP.Client
import Network.CoAP.Transport
import Network.Socket
import Network.URI
import System.Environment
import qualified Data.ByteString.Char8 as B
main :: IO ()
main = do
args <- getArgs
if length args < 2
then printUsage
else runClient args
runClient :: [String] -> IO ()
runClient (meth... | null | https://raw.githubusercontent.com/lulf/hcoap/8127520b767430b5513be6cfe646894ae7a2e616/example-client/Main.hs | haskell | import Network.CoAP.Client
import Network.CoAP.Transport
import Network.Socket
import Network.URI
import System.Environment
import qualified Data.ByteString.Char8 as B
main :: IO ()
main = do
args <- getArgs
if length args < 2
then printUsage
else runClient args
runClient :: [String] -> IO ()
runClient (meth... | |
0e7993983fbc3c8253acc6fc3439ef21e8540fb13420fe911caa266783676f36 | septract/jstar-old | unused.ml | * Finds stuff declared in mli that is not used in * other *
open Format
type file_info = {
path : string;
declarations : string list; (* ids appearing in mli *)
uses : string list (* ids appearing in ml *)
}
let list_of_hashtbl h = Hashtbl.fold (fun x () xs -> x :: xs) h []
let get_ids fn lexer =
let h =... | null | https://raw.githubusercontent.com/septract/jstar-old/c3b4fc6c1efc098efcdb864edbf0c666130f5fe5/scripts/unused.ml | ocaml | ids appearing in mli
ids appearing in ml | * Finds stuff declared in mli that is not used in * other *
open Format
type file_info = {
path : string;
}
let list_of_hashtbl h = Hashtbl.fold (fun x () xs -> x :: xs) h []
let get_ids fn lexer =
let h = Hashtbl.create 101 in
try
let c = open_in fn in
let lb = Lexing.from_channel (open_in fn) in
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.