_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 |
|---|---|---|---|---|---|---|---|---|
5993659823eb2d7a6894ed6aee7c8b392f33a2c97716195365e98abaecce6fd7 | diagrams/svg-builder | Path.hs | # LANGUAGE FlexibleContexts #
{-# LANGUAGE OverloadedStrings #-}
-------------------------------------------------------------------------------
-- |
-- Module : Graphics.Svg.Path
Copyright : ( c ) 2015
-- License : BSD-style (see LICENSE)
-- Maintainer :
--
-- Utility functions to help create... | null | https://raw.githubusercontent.com/diagrams/svg-builder/a4ab859485c64c9336165a7982e9b59bd70f480f/src/Graphics/Svg/Path.hs | haskell | # LANGUAGE OverloadedStrings #
-----------------------------------------------------------------------------
|
Module : Graphics.Svg.Path
License : BSD-style (see LICENSE)
Maintainer :
Utility functions to help create SVG path attributes,
and transforms.
-------------------------------------------... | # LANGUAGE FlexibleContexts #
Copyright : ( c ) 2015
module Graphics.Svg.Path where
import Data.Text (Text)
import qualified Data.Text as T
import Data.Text.Lazy (toStrict)
import Data.Text.Lazy.Builder ... |
7677873bef1cdd22f9833ad7150c81250519094a9122c3c77a976c0bf357af14 | mlabs-haskell/apropos-tx | Int.hs | module Spec.Int (
HasParameterisedGenerator (..),
HasLogicalModel (..),
IntProp (..),
intGenTests,
intPureTests,
intPlutarchTests,
) where
import Apropos
import Apropos.Script
import Test.Tasty (TestTree, testGroup)
import Test.Tasty.Hedgehog (fromGroup)
import Plutarch (compile)
import Plutarch.Prelude
... | null | https://raw.githubusercontent.com/mlabs-haskell/apropos-tx/9734e1e8a4833fc56af350adf07c104cf043aafa/examples/Spec/Int.hs | haskell | module Spec.Int (
HasParameterisedGenerator (..),
HasLogicalModel (..),
IntProp (..),
intGenTests,
intPureTests,
intPlutarchTests,
) where
import Apropos
import Apropos.Script
import Test.Tasty (TestTree, testGroup)
import Test.Tasty.Hedgehog (fromGroup)
import Plutarch (compile)
import Plutarch.Prelude
... | |
0cef217f1bb35a5370f996ef94a1ae79678cd0324dd02a7dfeeee5c3adf4b31a | facebook/duckling | Tests.hs | Copyright ( c ) 2016 - present , Facebook , Inc.
-- All rights reserved.
--
-- This source code is licensed under the BSD-style license found in the
-- LICENSE file in the root directory of this source tree.
module Duckling.Ordinal.RU.Tests
( tests ) where
import Prelude
import Data.String
import Test.Tasty
imp... | null | https://raw.githubusercontent.com/facebook/duckling/72f45e8e2c7385f41f2f8b1f063e7b5daa6dca94/tests/Duckling/Ordinal/RU/Tests.hs | haskell | All rights reserved.
This source code is licensed under the BSD-style license found in the
LICENSE file in the root directory of this source tree. | Copyright ( c ) 2016 - present , Facebook , Inc.
module Duckling.Ordinal.RU.Tests
( tests ) where
import Prelude
import Data.String
import Test.Tasty
import Duckling.Dimensions.Types
import Duckling.Ordinal.RU.Corpus
import Duckling.Testing.Asserts
tests :: TestTree
tests = testGroup "RU Tests"
[ makeCorpusT... |
991970f70c0ddff08c3ee181633aee240e522027c037cc43ff1ff9c7f1fc9552 | spawnfest/eep49ers | shell_SUITE.erl | %%
%% %CopyrightBegin%
%%
Copyright Ericsson AB 2004 - 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/stdlib/test/shell_SUITE.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 2004 - 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 ,
-module(shell_SUITE).
-export([all/0, suite/0,groups/0,init_per_suite/1, end_per_suite/1,
init_per_group/2,end_per... |
009424eda65d812e28dd9278a45bc7473cc78b48ed4b2b9c808e3c1758ea0547 | reborg/clojure-essential-reference | 9.clj | (time (->> (range 50000)
(into [])
(r/map range)
(r/mapcat conj)
< 1 >
(r/filter odd?)
(r/fold +)))
" Elapsed time : 45516.963356 msecs "
10416041675000
(time (->> (range 50000)
(into [])
(r/map range)
(r/mapcat conj)
(r/filter odd?)
(r/fold +... | null | https://raw.githubusercontent.com/reborg/clojure-essential-reference/c37fa19d45dd52b2995a191e3e96f0ebdc3f6d69/ReducersandTransducers/Reducers/reducerandfolder/9.clj | clojure | < 2 > | (time (->> (range 50000)
(into [])
(r/map range)
(r/mapcat conj)
< 1 >
(r/filter odd?)
(r/fold +)))
" Elapsed time : 45516.963356 msecs "
10416041675000
(time (->> (range 50000)
(into [])
(r/map range)
(r/mapcat conj)
(r/filter odd?)
(r/fold +... |
afb41eed08008202199434e6033731fb2a1036ab4550bcd7fdb88872a0418109 | shentufoundation/deepsea | BinPos.mli | open BinNums
open BinPosDef
open Datatypes
open Nat0
open Specif
module Pos :
sig
val succ : positive -> positive
val add : positive -> positive -> positive
val add_carry : positive -> positive -> positive
val pred_double : positive -> positive
val pred_N : positive -> coq_N
type mask = Pos.mask =
... | null | https://raw.githubusercontent.com/shentufoundation/deepsea/970576a97c8992655ed2f173f576502d73b827e1/src/backend/extraction/BinPos.mli | ocaml | open BinNums
open BinPosDef
open Datatypes
open Nat0
open Specif
module Pos :
sig
val succ : positive -> positive
val add : positive -> positive -> positive
val add_carry : positive -> positive -> positive
val pred_double : positive -> positive
val pred_N : positive -> coq_N
type mask = Pos.mask =
... | |
7f8cdcdd405e4c9acb0c6086f8bf0c5551fd15a18c52b24b7167c65e49e74bd7 | heroku/vegur | vegur_proxy.erl | Copyright ( c ) 2013 - 2015 , Heroku Inc < > .
%%% 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,... | null | https://raw.githubusercontent.com/heroku/vegur/26cf07b6d7f12841e529cd2a9fc354a70927a6be/src/vegur_proxy.erl | erlang | 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.
* Redistributions... | Copyright ( c ) 2013 - 2015 , Heroku Inc < > .
" AS IS " AND ANY EXPRESS OR IMPLIED WARRANTIES , INCLUDING , BUT NOT
OWNER OR ANY DIRECT , INDIRECT , INCIDENTAL ,
SPECIAL , EXEMPLARY , OR CONSEQUENTIAL DAMAGES ( INCLUDING , BUT NOT
LIMITED TO , PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES ; LOSS OF USE ,
... |
8408c02de51cc3c3983cbf6a0cfffeb55651b27bd834e36d8ac0cfff04962a3c | janestreet/bonsai | bonsai_web_ui_form_view.mli | [@@@alert
private_bonsai_view_library
{|
This library is private, for use by Bonsai developers in [lib/bonsai/web_ui/view] and
[lib/bonsai/web_ui/form]. If that doesn't apply to you, then you should use the public
[Bonsai_web_ui_form] library, which re-exports this functionality as part of its [View]
module.
|}]
... | null | https://raw.githubusercontent.com/janestreet/bonsai/782fecd000a1f97b143a3f24b76efec96e36a398/web_ui/view/form/bonsai_web_ui_form_view.mli | ocaml | For creating
* [of_vdom'] is like [of_vdom], but allows access to some extra metadata that is stored
in the form's view.
* An [empty] form view.
* [tuple] combines a list of [t] into a single one.
* [record] combines a list of fields (field names and their corresponding views) into a
view representing a re... | [@@@alert
private_bonsai_view_library
{|
This library is private, for use by Bonsai developers in [lib/bonsai/web_ui/view] and
[lib/bonsai/web_ui/form]. If that doesn't apply to you, then you should use the public
[Bonsai_web_ui_form] library, which re-exports this functionality as part of its [View]
module.
|}]
... |
30d388e3281b30d5c59da5bcd95ead067c9c23526949463abeeb7ef06d425fef | mtesseract/nakadi-client | IO.hs | |
Module : Network . Nakadi . Unsafe . IO
Description : Support for MonadNakadi IO Instance
Copyright : ( c ) 2018
License : :
Stability : experimental
Portability : POSIX
This is an experimental API .
- client provides a ' MonadNakadi ' instance for the ' IO ' monad
access... | null | https://raw.githubusercontent.com/mtesseract/nakadi-client/f8eef3ac215459081b01b0b48f0b430ae7701f52/src/Network/Nakadi/Unsafe/IO.hs | haskell | |
Module : Network . Nakadi . Unsafe . IO
Description : Support for MonadNakadi IO Instance
Copyright : ( c ) 2018
License : :
Stability : experimental
Portability : POSIX
This is an experimental API .
- client provides a ' MonadNakadi ' instance for the ' IO ' monad
access... | |
d369e04dce242c6139a27c0391bafdf0f1f8e186d0fc975e6a0ce7f53c43cc02 | subtitle-master/subtitlemaster | reactive_test.cljs | (ns wilkerdev.util.reactive-test
(:require-macros [wilkerdev.util.macros :refer [<? test dochan]]
[cljs.core.async.macros :refer [go]])
(:require [wilkerdev.util.reactive :as r]
[sm.test-helper :refer [alternate-calls]]
[cljs.core.async :refer [<! timeout alts! put! chan c... | null | https://raw.githubusercontent.com/subtitle-master/subtitlemaster/d88c2fb007c6c3d4030fefbd4b7e3eafb0e797a9/test/cljs/wilkerdev/util/reactive_test.cljs | clojure | (ns wilkerdev.util.reactive-test
(:require-macros [wilkerdev.util.macros :refer [<? test dochan]]
[cljs.core.async.macros :refer [go]])
(:require [wilkerdev.util.reactive :as r]
[sm.test-helper :refer [alternate-calls]]
[cljs.core.async :refer [<! timeout alts! put! chan c... | |
1b385a267d9a1af46ce8dce70cfd40af2cd220d1cdba62f251a651cb7b9e7e01 | Shirakumo/kandria | credits.lisp | (in-package #:org.shirakumo.fraf.kandria)
(defclass screen-gap (alloy:layout-element alloy:renderable)
())
(defmethod alloy:suggest-size ((size alloy:size) (screen-gap screen-gap))
(alloy:size (alloy:w size) (alloy:vh 1)))
(defclass paragraph (label)
())
(presentations:define-update (ui paragraph)
(:label
... | null | https://raw.githubusercontent.com/Shirakumo/kandria/0eafe60b5f50c18980a6acc977dc45987e8e26c1/ui/credits.lisp | lisp | show the end screen and the credits panel, which will hide to reveal the end screen.
Reset the camera and remove the region to reduce lag | (in-package #:org.shirakumo.fraf.kandria)
(defclass screen-gap (alloy:layout-element alloy:renderable)
())
(defmethod alloy:suggest-size ((size alloy:size) (screen-gap screen-gap))
(alloy:size (alloy:w size) (alloy:vh 1)))
(defclass paragraph (label)
())
(presentations:define-update (ui paragraph)
(:label
... |
7315cffc0ca83c945a5c0ef5919b4579abfd488d826a98657bfa6b4888fda908 | otabat/couchbase-clj | client.clj | (ns couchbase-clj.test.client
(:import [net.spy.memcached
PersistTo ReplicateTo CASValue CASResponse
FailureMode DefaultHashAlgorithm]
[net.spy.memcached.auth AuthDescriptor PlainCallbackHandler]
[net.spy.memcached.transcoders
Transcoder LongTranscoder Seriali... | null | https://raw.githubusercontent.com/otabat/couchbase-clj/5f975dc85d0eec554034eefa9d97f1ee7ad9e84a/test/couchbase_clj/test/client.clj | clojure | (use-fixtures :once tf/setup-client tf/flush-data)
Test failed, not working.
(deftest get-min-reconnect-interval-test
(testing "Get the min reconnect interval."
(deftest async-get-views-test
(testing "Asynchronously get a sequence of views."
(is (instance? couchbase_clj.future.CouchbaseCljHttpFuture fut))
(... | (ns couchbase-clj.test.client
(:import [net.spy.memcached
PersistTo ReplicateTo CASValue CASResponse
FailureMode DefaultHashAlgorithm]
[net.spy.memcached.auth AuthDescriptor PlainCallbackHandler]
[net.spy.memcached.transcoders
Transcoder LongTranscoder Seriali... |
8c01c3dcb7e54530df474ea347b29158165f81561bfb1fe298366c843c1d1128 | ocsigen/js_of_ocaml | findlib.mli | Js_of_ocaml compiler
* /
*
* 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 , with linking exception ;
* either version 2.1 of the License , or ( at your option ) any l... | null | https://raw.githubusercontent.com/ocsigen/js_of_ocaml/9141d50d34d64bb02bc8e954a7549be6fb58a0a5/compiler/lib/findlib.mli | ocaml | Js_of_ocaml compiler
* /
*
* 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 , with linking exception ;
* either version 2.1 of the License , or ( at your option ) any l... | |
6a067e4a1489c9c93382e1ac20172ab0ed3f186c0006a88c24b2f39685c483e2 | yakaz/yamerl | unicode_string.erl | -module(unicode_string).
-include_lib("eunit/include/eunit.hrl").
-define(FILENAME, "test/construction/" ?MODULE_STRING ".yaml").
setup() ->
application:start(yamerl).
schema_failsafe_simple_test_() ->
{setup,
fun setup/0,
[
?_assertMatch(
[
[[12356, 12429, 12399]]
... | null | https://raw.githubusercontent.com/yakaz/yamerl/0032607a7b27fa2b548fc9a02d7ae6b53469c0c5/test/construction/unicode_string.erl | erlang | -module(unicode_string).
-include_lib("eunit/include/eunit.hrl").
-define(FILENAME, "test/construction/" ?MODULE_STRING ".yaml").
setup() ->
application:start(yamerl).
schema_failsafe_simple_test_() ->
{setup,
fun setup/0,
[
?_assertMatch(
[
[[12356, 12429, 12399]]
... | |
d253f6c2e1e344e1ffbecd2dd603379a97c32c57b3ea9b04bb059de2b16dc0b2 | dvcrn/proton | core.cljs | (ns proton.layers.lang.jade.core
(:require [proton.lib.mode :as mode]
[proton.lib.helpers :refer [console!]])
(:use [proton.layers.base :only [init-layer! get-packages init-package register-layer-dependencies describe-mode]]))
(defmethod get-packages :lang/jade []
[:language-jade])
(defmethod init-l... | null | https://raw.githubusercontent.com/dvcrn/proton/427d83ffdb61d84a04e3d30032b792a9cfbfc53f/src/cljs/proton/layers/lang/jade/core.cljs | clojure | (ns proton.layers.lang.jade.core
(:require [proton.lib.mode :as mode]
[proton.lib.helpers :refer [console!]])
(:use [proton.layers.base :only [init-layer! get-packages init-package register-layer-dependencies describe-mode]]))
(defmethod get-packages :lang/jade []
[:language-jade])
(defmethod init-l... | |
2d79369a603cc406a2565c918e17c7137a104bd13c42ad859e15b97de99667f6 | fakedata-haskell/fakedata | JackHandey.hs | # LANGUAGE TemplateHaskell #
{-# LANGUAGE OverloadedStrings #-}
| @since 1.0
module Faker.Quote.JackHandey where
import Data.Text (Text)
import Faker (Fake(..))
import Faker.Provider.JackHandey
import Faker.TH
$(generateFakeField "jackHandey" "jack_handey")
| null | https://raw.githubusercontent.com/fakedata-haskell/fakedata/ea938c38845b274e28abe7f4e8e342f491e83c89/src/Faker/Quote/JackHandey.hs | haskell | # LANGUAGE OverloadedStrings # | # LANGUAGE TemplateHaskell #
| @since 1.0
module Faker.Quote.JackHandey where
import Data.Text (Text)
import Faker (Fake(..))
import Faker.Provider.JackHandey
import Faker.TH
$(generateFakeField "jackHandey" "jack_handey")
|
c662acd94de182f348c50844e5e2cc47f2398366ccef85af1ef895831d9c9d72 | kappamodeler/kappa | random_tree.ml | module type Random_tree =
sig
type tree
type val_type
val create:int -> tree
val copy:tree -> tree
val copy_in: tree -> tree -> tree
val update_event: int -> float -> tree -> tree
val random: tree -> int
val update_structure: tree -> tree
end
module Random_tr... | null | https://raw.githubusercontent.com/kappamodeler/kappa/de63d1857898b1fc3b7f112f1027768b851ce14d/simplx_rep/src/data_structures/random_tree.ml | ocaml | module type Random_tree =
sig
type tree
type val_type
val create:int -> tree
val copy:tree -> tree
val copy_in: tree -> tree -> tree
val update_event: int -> float -> tree -> tree
val random: tree -> int
val update_structure: tree -> tree
end
module Random_tr... | |
05758f27cbc7f57707796fc6c3fab81fb203b8fd85fbfe1c0acfa429ed6407e5 | MyDataFlow/ttalk-server | ejabberd_auth_odbc.erl | %%%----------------------------------------------------------------------
%%% File : ejabberd_auth_odbc.erl
Author : < >
Purpose : Authentification via ODBC
Created : 12 Dec 2004 by < >
%%%
%%%
ejabberd , Copyright ( C ) 2002 - 2011 ProcessOne
%%%
%%% This program is free software; you can redistr... | null | https://raw.githubusercontent.com/MyDataFlow/ttalk-server/07a60d5d74cd86aedd1f19c922d9d3abf2ebf28d/apps/ejabberd/src/ejabberd_auth_odbc.erl | erlang | ----------------------------------------------------------------------
File : ejabberd_auth_odbc.erl
This program is free software; you can redistribute it and/or
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without... | Author : < >
Purpose : Authentification via ODBC
Created : 12 Dec 2004 by < >
ejabberd , Copyright ( C ) 2002 - 2011 ProcessOne
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation ; either version 2 of the
You should have received a copy of t... |
ba8a3e3f8655007205f4f5573d117fb8937743cf2c6c4bfa90ad39c7a968f4d0 | gvolpe/musikell | Server.hs | {-# LANGUAGE OverloadedStrings, RecordWildCards #-}
module Http.Server where
import Api.Dependencies ( Deps )
import Api.Root ( gqlApi
, gqlDoc
)
import Con... | null | https://raw.githubusercontent.com/gvolpe/musikell/2ec837b605b87b268e460cd6e13b82e7eea8169b/src/Http/Server.hs | haskell | # LANGUAGE OverloadedStrings, RecordWildCards # |
module Http.Server where
import Api.Dependencies ( Deps )
import Api.Root ( gqlApi
, gqlDoc
)
import Config ( HttpServerConfig(..) )... |
d5a05cd368fc1e15089863ed27145155db0b0f2aa75e6becf005d33dd8ac85ce | clojure-interop/java-jdk | SynthEditorPaneUI.clj | (ns javax.swing.plaf.synth.SynthEditorPaneUI
"Provides the Synth L&F UI delegate for
JEditorPane."
(:refer-clojure :only [require comment defn ->])
(:import [javax.swing.plaf.synth SynthEditorPaneUI]))
(defn ->synth-editor-pane-ui
"Constructor."
(^SynthEditorPaneUI []
(new SynthEditorPaneUI )))
(defn ... | null | https://raw.githubusercontent.com/clojure-interop/java-jdk/8d7a223e0f9a0965eb0332fad595cf7649d9d96e/javax.swing/src/javax/swing/plaf/synth/SynthEditorPaneUI.clj | clojure | (ns javax.swing.plaf.synth.SynthEditorPaneUI
"Provides the Synth L&F UI delegate for
JEditorPane."
(:refer-clojure :only [require comment defn ->])
(:import [javax.swing.plaf.synth SynthEditorPaneUI]))
(defn ->synth-editor-pane-ui
"Constructor."
(^SynthEditorPaneUI []
(new SynthEditorPaneUI )))
(defn ... | |
d90fc387246d26b51c349f8403ec284d918e599f478a0ac1f7369276e5054583 | jmid/mirage-hole | config.ml | Copyright Robur , 2020
open Mirage
type http_client = HTTP_client
let http_client = typ HTTP_client
let dns_upstream =
let doc = Key.Arg.info ~doc:"Upstream DNS resolver IP" ["dns-upstream"] in
Key.(create "dns-upstream" Arg.(opt (some ip_address) None doc))
let dns_port =
let doc = Key.Arg.info ~doc:"Upstr... | null | https://raw.githubusercontent.com/jmid/mirage-hole/4eb70baf8c6fce215f7110e1ddd5f6904d658d67/config.ml | ocaml | Copyright Robur , 2020
open Mirage
type http_client = HTTP_client
let http_client = typ HTTP_client
let dns_upstream =
let doc = Key.Arg.info ~doc:"Upstream DNS resolver IP" ["dns-upstream"] in
Key.(create "dns-upstream" Arg.(opt (some ip_address) None doc))
let dns_port =
let doc = Key.Arg.info ~doc:"Upstr... | |
b1c37fcdb81f5e8c51a72b02ff749b403e921a95eaabe869ae7d9717a2ae9e95 | pixlsus/registry.gimp.org_static | parchmenttexturebynaeddyr_0.scm | Copyright 2009 - 2011
version 2.0 of my paper texture script , renamed Parchment Texture Script
Licensed under Creative Commons Attribution Share - alike license 3.0
; Disclaimer: I've studied programming since I was a little kid, mostly reading books and maybe doing a small program in whatever flavour of langu... | null | https://raw.githubusercontent.com/pixlsus/registry.gimp.org_static/ffcde7400f402728373ff6579947c6ffe87d1a5e/registry.gimp.org/files/parchmenttexturebynaeddyr_0.scm | scheme | Disclaimer: I've studied programming since I was a little kid, mostly reading books and maybe doing a small program in whatever flavour of language I was interested in...
I never used them to actually program, so I have very, very little actual experience. The results can be seen below. I know, I know. If I could bot... | Copyright 2009 - 2011
version 2.0 of my paper texture script , renamed Parchment Texture Script
Licensed under Creative Commons Attribution Share - alike license 3.0
The disclaimer part is this : even though I 'd study a language ( ranging from Basic to in school to Inform 6 which was a C - syntax - y Z - en... |
7b8ff8fb331a926d3eea12ac7845b70000a790f5b7cee570c36e171901ca85c0 | hackclub/dungeon-of-the-slack | TH.hs | # LANGUAGE NoImplicitPrelude #
# LANGUAGE TemplateHaskell #
# LANGUAGE TupleSections #
-- legally this has to be in a different module
module Game.TH
( defComponent
, mkType
, localComponentNames
, componentNames
, mkDelete
, mkListComponents
, pb
) where
import Apecs
import ... | null | https://raw.githubusercontent.com/hackclub/dungeon-of-the-slack/327a4ca28eeb871990e809c9daa5c1538b0443fb/src/Game/TH.hs | haskell | legally this has to be in a different module
FOR DEBUGGING | # LANGUAGE NoImplicitPrelude #
# LANGUAGE TemplateHaskell #
# LANGUAGE TupleSections #
module Game.TH
( defComponent
, mkType
, localComponentNames
, componentNames
, mkDelete
, mkListComponents
, pb
) where
import Apecs
import Relude hiding ( Type )
impo... |
4adec39e48eb63e154752f8fff386611e9042206fc6422986adc247e13c7691a | haskell-beam/beam | Migrate.hs | module Database.Beam.Sqlite.Test.Migrate (tests) where
import Database.SQLite.Simple
import Test.Tasty
import Test.Tasty.HUnit
import Database.Beam
import Database.Beam.Sqlite
import Database.Beam.Sqlite.Migrate
import Database.Beam.Migrate
import Database.Beam.Migrate.Simple
import Database.Beam.Sqlite.Test
tests ... | null | https://raw.githubusercontent.com/haskell-beam/beam/596981a1ea6765b9f311d48a2ec4d8460ebc4b7e/beam-sqlite/test/Database/Beam/Sqlite/Test/Migrate.hs | haskell | module Database.Beam.Sqlite.Test.Migrate (tests) where
import Database.SQLite.Simple
import Test.Tasty
import Test.Tasty.HUnit
import Database.Beam
import Database.Beam.Sqlite
import Database.Beam.Sqlite.Migrate
import Database.Beam.Migrate
import Database.Beam.Migrate.Simple
import Database.Beam.Sqlite.Test
tests ... | |
4a70422dcaea5cf61d4d50f76345655294f78634d9b732cd15799dc8b3cd95c5 | ocsigen/ocaml-eliom | manyargs.ml | (**************************************************************************)
(* *)
(* OCaml *)
(* *)
... | null | https://raw.githubusercontent.com/ocsigen/ocaml-eliom/497c6707f477cb3086dc6d8124384e74a8c379ae/testsuite/tests/basic-manyargs/manyargs.ml | ocaml | ************************************************************************
OCaml
... | , projet Cristal , INRIA Rocquencourt
Copyright 1995 Institut National de Recherche en Informatique et
the GNU Lesser General Public License version 2.1 , with the
let manyargs a b c d e f g h i j k l m n o =
print_string "a = "; print_int a; print_newline();
print... |
77e86c1217a66ba5d4c35bb6d8f7eebb8caa0b38b43faaa299b281e95269ee7f | myuon/ghc-compiler-notes | Internal.hs | {-# LANGUAGE OverloadedStrings #-}
module GHC.Compiler.Notes.Parser.Internal where
import Control.Applicative
import Control.Monad
import Control.Monad.Trans.Class
import Control.Monad.Trans.State
import qualified Data.Char as Char
import Data.Coerc... | null | https://raw.githubusercontent.com/myuon/ghc-compiler-notes/1ac7d051acac420f481d34e860040da99a768e43/src/GHC/Compiler/Notes/Parser/Internal.hs | haskell | # LANGUAGE OverloadedStrings #
, '*' -- for sub section
TODO: indentation parsing
TODO: indentation parsing
TODO: indentation parsing
skip layout tokens |
module GHC.Compiler.Notes.Parser.Internal where
import Control.Applicative
import Control.Monad
import Control.Monad.Trans.Class
import Control.Monad.Trans.State
import qualified Data.Char as Char
import Data.Coerce
import Data.Conduit
im... |
d177c6ba85eb2067cdc3cab467c0c387d108c81aa3a4189f28ee423a3ef2a70c | j3pic/lisp-binary | run-tests.lisp | (format t "~%>>>>>>>>>>> Test program loading~%")
(load "init.lisp")
(load "fake-asdf.lisp")
(format t "~%>>>>>>>>>>>>> Loaded init file~%")
(ql:quickload :asdf)
(push '*default-pathname-defaults* asdf:*central-registry*)
(defmacro warnings-to-errors (&body body)
`(handler-bind (((and warning
#-ccl (not asdf/pars... | null | https://raw.githubusercontent.com/j3pic/lisp-binary/02ce88f285ef4c8e8b3c2be3385217490fab9628/test/run-tests.lisp | lisp | (format t "~%>>>>>>>>>>> Test program loading~%")
(load "init.lisp")
(load "fake-asdf.lisp")
(format t "~%>>>>>>>>>>>>> Loaded init file~%")
(ql:quickload :asdf)
(push '*default-pathname-defaults* asdf:*central-registry*)
(defmacro warnings-to-errors (&body body)
`(handler-bind (((and warning
#-ccl (not asdf/pars... | |
209006c9980bcd3e2e95577dd94ba183b396a8602bae9c27cc3aa599df0f232f | li-clutter-org/http2-test | VeryBasic.hs | {-# LANGUAGE OverloadedStrings #-}
module Rede.Workers.VeryBasic(
veryBasic
,bad404ResponseData
,bad404ResponseHeaders
) where
import qualified Data.ByteString as B
import Data.Conduit
import Data.ByteString.Char8 (pack)
import Rede.MainLoop.CoherentWorker
trivialHeaders :: ... | null | https://raw.githubusercontent.com/li-clutter-org/http2-test/38d6706511f93af875273f7702fa0ea8582d5d8e/hs-src/Rede/Workers/VeryBasic.hs | haskell | # LANGUAGE OverloadedStrings # |
module Rede.Workers.VeryBasic(
veryBasic
,bad404ResponseData
,bad404ResponseHeaders
) where
import qualified Data.ByteString as B
import Data.Conduit
import Data.ByteString.Char8 (pack)
import Rede.MainLoop.CoherentWorker
trivialHeaders :: [(B.ByteString, B.ByteString)]
tri... |
2f9713d5c18d95c6eeef34f19372e0f63725157a4d8ca50f3dc0cd50ee1c15bc | antono/guix-debian | scheme.scm | ;;; GNU Guix --- Functional package management for GNU
Copyright © 2013 , 2014 < >
;;;
;;; This file is part of GNU Guix.
;;;
GNU is free software ; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by
the Free Software Foundation ; either version 3 of t... | null | https://raw.githubusercontent.com/antono/guix-debian/85ef443788f0788a62010a942973d4f7714d10b4/gnu/packages/scheme.scm | scheme | GNU Guix --- Functional package management for GNU
This file is part of GNU Guix.
you can redistribute it and/or modify it
either version 3 of the License , or ( at
your option) any later version.
GNU Guix is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied wa... | Copyright © 2013 , 2014 < >
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 scheme)
#:use-module (gnu packages)
#:use-module (guix licenses)
#:use-m... |
e0b7e9531a0bce9d8266e72dce15cde1ce86d4071247782e812abddaf5852372 | pallix/lacij | segmented.clj | (ns lacij.examples.segmented
(:require [lacij.edit.graph :refer :all]
[lacij.model.graph :refer :all]
[lacij.view.graphview :refer [export]]
[lacij.layouts.layout :refer :all]
[lacij.layouts.utils.cycle :refer [break-cycles]]
[lacij.utils.core :refer :all]))... | null | https://raw.githubusercontent.com/pallix/lacij/ee9b7dcda13f25f7460acb5995b7970a7564c11e/src/lacij/examples/segmented.clj | clojure | (ns lacij.examples.segmented
(:require [lacij.edit.graph :refer :all]
[lacij.model.graph :refer :all]
[lacij.view.graphview :refer [export]]
[lacij.layouts.layout :refer :all]
[lacij.layouts.utils.cycle :refer [break-cycles]]
[lacij.utils.core :refer :all]))... | |
113dfd62dc390e6d2fac600fe9563d66bd5837ef6d5b4cbf5dfaa5abdae452a6 | korya/efuns | syntax.ml | (***********************************************************************)
(* *)
(* Objective Caml *)
(* *)
, projet ... | null | https://raw.githubusercontent.com/korya/efuns/78b21d9dff45b7eec764c63132c7a564f5367c30/inliner/perf/Lex/syntax.ml | ocaml | *********************************************************************
Objective Caml
... | , projet Cristal , INRIA Rocquencourt
Copyright 1996 Institut National de Recherche en Informatique et
Automatique . Distributed only by permission .
$ I d : syntax.ml , v 1.1 1999/11/22 10:36:01 lefessan Exp $
type location =
Location of int * int
type... |
275758a2ab7147c792c44021a1fe0244eb91b42df68bfb7041a64fba2b70a2bb | peterschwarz/clj-gpio | io.cljc | (ns gpio.io
#?(:cljs (:require [cljs.nodejs :as nodejs])))
#?(:cljs (defonce ^:private fs (nodejs/require "fs")))
(defn write-file [filename content]
#?(:clj (spit filename content)
:cljs (.writeFileSync fs filename content #js {:encoding "ascii"})))
(defn read-file [filename]
#?(:clj (slurp filename)
... | null | https://raw.githubusercontent.com/peterschwarz/clj-gpio/88fedec2605f6ff6713bfca382a9451538e99fe2/src/main/clojure/gpio/io.cljc | clojure | (ns gpio.io
#?(:cljs (:require [cljs.nodejs :as nodejs])))
#?(:cljs (defonce ^:private fs (nodejs/require "fs")))
(defn write-file [filename content]
#?(:clj (spit filename content)
:cljs (.writeFileSync fs filename content #js {:encoding "ascii"})))
(defn read-file [filename]
#?(:clj (slurp filename)
... | |
6ffaffa9676fee65f31e68bf949ed8232cc77910ce69fed289fd5be3d92df9ba | mukul-rathi/bolt | good_immutable_refs_in_multiple_threads.ml | open Core
open Print_data_race_checker_ast
let%expect_test "Immutable refs in multiple locals" =
print_data_race_checker_ast
"
class Foo {
capability read Bar, linear Baz;
const int f : Bar, Baz;
}
function int test() {
5
}
void main() {
let x = new Foo(f:5);
... | null | https://raw.githubusercontent.com/mukul-rathi/bolt/1faf19d698852fdb6af2ee005a5f036ee1c76503/tests/frontend/expect/data_race_checker/good_immutable_refs_in_multiple_threads.ml | ocaml | open Core
open Print_data_race_checker_ast
let%expect_test "Immutable refs in multiple locals" =
print_data_race_checker_ast
"
class Foo {
capability read Bar, linear Baz;
const int f : Bar, Baz;
}
function int test() {
5
}
void main() {
let x = new Foo(f:5);
... | |
d36bb22602410afabc53e8793ac2dc0a53437949e7bb0466d691d4e6ddb9545f | VitalLabs/nativestore | internal.cljs | (ns nativestore.internal
(:require [cljs.test :as t :refer-macros [deftest is]]
[clojure.set :as set]
[derive.core :refer-macros [defnd with-tracked-dependencies]]
[derive.core :as d]
[nativestore.core :as store]))
(defn insert-population [store]
(doto store
(sto... | null | https://raw.githubusercontent.com/VitalLabs/nativestore/d5abf5789782db9c353d344aa58b1d4f1293431d/test/nativestore/internal.cljs | clojure | With a DB index
With a simple index
With a compound index
Test deletion
(deftest multi-index | (ns nativestore.internal
(:require [cljs.test :as t :refer-macros [deftest is]]
[clojure.set :as set]
[derive.core :refer-macros [defnd with-tracked-dependencies]]
[derive.core :as d]
[nativestore.core :as store]))
(defn insert-population [store]
(doto store
(sto... |
472f14aa180f0f27e408e23d3bf2472bc52d7cd12a5abe63e94e24519545c156 | candera/vmt | filesystem.cljs | (ns weathergen.interop.node.filesystem
(:require-macros [weathergen.interop.node :refer [defimports]]))
(defimports "fs"
readdirSync
existsSync
readFileSync
statSync
mkdirSync
writeFileSync)
| null | https://raw.githubusercontent.com/candera/vmt/8cf450e6c34af87d748152afd7f547b92ae9b38e/src/weathergen/interop/node/filesystem.cljs | clojure | (ns weathergen.interop.node.filesystem
(:require-macros [weathergen.interop.node :refer [defimports]]))
(defimports "fs"
readdirSync
existsSync
readFileSync
statSync
mkdirSync
writeFileSync)
| |
518a41dde38baf9cb9c3402138258a89b8fe59ec78079cd5d6ed65c4fca7fdc9 | inaka/elvis_core | fail_nesting_level.erl | -module(fail_nesting_level).
-dialyzer(no_match).
%% Used so that the line positions don't change for tests.
-compile([export_all, nowarn_export_all]).
exceed_with_four_levels() ->
case 1 of
1 -> case 2 of
2 -> case 3 of
3 -> fourth
end
... | null | https://raw.githubusercontent.com/inaka/elvis_core/468bd3498f1782fd74ef3d8eb1b36217b0b76c11/test/examples/fail_nesting_level.erl | erlang | Used so that the line positions don't change for tests. | -module(fail_nesting_level).
-dialyzer(no_match).
-compile([export_all, nowarn_export_all]).
exceed_with_four_levels() ->
case 1 of
1 -> case 2 of
2 -> case 3 of
3 -> fourth
end
end
end,
case 1 of
1 -> case 2 of... |
f7af840faa065b20ce434ddafede712f25779e245f5bc38b90dde0514d6d153c | camllight/camllight | nat.ml | #open "exc";;
#open "bool";;
#open "fstring";;
#open "fchar";;
#open "fvect";;
#open "list";;
#open "pair";;
#open "ref";;
#open "float";;
#open "int";;
#open "eq";;
#open "io";;
#open "printf";;
let badcarry name carry =
sprintf "%s: Bad carry or borrow (%d) must be 0 or 1" name carry;;
let badresplen name len1... | null | https://raw.githubusercontent.com/camllight/camllight/0cc537de0846393322058dbb26449427bfc76786/windows/src/lib/nat.ml | ocaml | Reste à faire | #open "exc";;
#open "bool";;
#open "fstring";;
#open "fchar";;
#open "fvect";;
#open "list";;
#open "pair";;
#open "ref";;
#open "float";;
#open "int";;
#open "eq";;
#open "io";;
#open "printf";;
let badcarry name carry =
sprintf "%s: Bad carry or borrow (%d) must be 0 or 1" name carry;;
let badresplen name len1... |
7ef0695c457e6c56926dbfa05ebc0990acfb10b41f8c87c0a8a5e4259a5e7bab | WorksHub/client | db.cljs | (ns wh.profile.update-public.db
(:require [cljs.spec.alpha :as s]
[clojure.string :as str]
[wh.common.specs.primitives :as specs]))
(s/def ::id string?)
(s/def ::name string?)
(s/def ::summary string?)
(s/def ::image-url string?)
(s/def ::other-urls (s/keys :req-un [::specs/url]))
(s/def ::ed... | null | https://raw.githubusercontent.com/WorksHub/client/a51729585c2b9d7692e57b3edcd5217c228cf47c/client/src/wh/profile/update_public/db.cljs | clojure | (ns wh.profile.update-public.db
(:require [cljs.spec.alpha :as s]
[clojure.string :as str]
[wh.common.specs.primitives :as specs]))
(s/def ::id string?)
(s/def ::name string?)
(s/def ::summary string?)
(s/def ::image-url string?)
(s/def ::other-urls (s/keys :req-un [::specs/url]))
(s/def ::ed... | |
f946f6c30b01d5a72ed061fb12a430b81b383e64885ac84159c27414358c756f | CardanoSolutions/kupo | NativeScript.hs | # LANGUAGE PatternSynonyms #
module Kupo.Data.Cardano.NativeScript
( NativeScript
, pattern Ledger.RequireSignature
, pattern Ledger.RequireAllOf
, pattern Ledger.RequireAnyOf
, pattern Ledger.RequireMOf
, pattern Ledger.RequireTimeExpire
, pattern Ledger.RequireTimeStart
, KeyHash(..)
... | null | https://raw.githubusercontent.com/CardanoSolutions/kupo/4904123abeed53f672eb34e0ef10c6c710bda61b/src/Kupo/Data/Cardano/NativeScript.hs | haskell | # LANGUAGE PatternSynonyms #
module Kupo.Data.Cardano.NativeScript
( NativeScript
, pattern Ledger.RequireSignature
, pattern Ledger.RequireAllOf
, pattern Ledger.RequireAnyOf
, pattern Ledger.RequireMOf
, pattern Ledger.RequireTimeExpire
, pattern Ledger.RequireTimeStart
, KeyHash(..)
... | |
21f4d3cb14fdf8ef3221e36f81e2a51b97e069a61bcf42b47370da3db66a3fec | cirodrig/triolet | InitializeBuiltins.hs |
# LANGUAGE TemplateHaskell #
module LowLevel.InitializeBuiltins(initializeLowLevelBuiltins)
where
import Prelude hiding(catch)
import Control.Exception
import Control.Monad
import qualified Data.Map as Map
import Data.Maybe
import qualified Language.Haskell.TH as TH
import Common.Error
import Common.Identifier
imp... | null | https://raw.githubusercontent.com/cirodrig/triolet/e515a1dc0d6b3e546320eac7b71fb36cea5b53d0/src/program/LowLevel/InitializeBuiltins.hs | haskell | import {-# SOURCE #-} SystemF.Lowering.Datatypes2
Global variables are used by reference , so they must have pointer type
or owned type
Global variables are used by reference, so they must have pointer type
or owned type
| Given an identifier supply, and the memory-annotated type environment,
initialize the... |
# LANGUAGE TemplateHaskell #
module LowLevel.InitializeBuiltins(initializeLowLevelBuiltins)
where
import Prelude hiding(catch)
import Control.Exception
import Control.Monad
import qualified Data.Map as Map
import Data.Maybe
import qualified Language.Haskell.TH as TH
import Common.Error
import Common.Identifier
imp... |
a85ad7cb0cd242b80cb508d565eb20b829768b9880b791c582d47cfad32b9cc1 | 2600hz/kazoo | kzd_freeswitch.erl | %%%-----------------------------------------------------------------------------
( C ) 2010 - 2020 , 2600Hz
%%% @doc FreeSWITCH proplists
@author
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 o... | null | https://raw.githubusercontent.com/2600hz/kazoo/24519b9af9792caa67f7c09bbb9d27e2418f7ad6/core/kazoo_documents/src/kzd_freeswitch.erl | erlang | -----------------------------------------------------------------------------
@doc FreeSWITCH proplists
@end
-----------------------------------------------------------------------------
Extract custom channel variables to include in the event | ( C ) 2010 - 2020 , 2600Hz
@author
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(kzd_freeswitch).
-export([account_id/1, account_billing/1, account_trunk_usage/1
,app... |
210ac1b119ee5eb924c23192c862a27ef51ed66054650f0c36ed436459179646 | aantron/dream | client.ml | open Js_of_ocaml
let () =
let body = Dom_html.getElementById_exn "body" in
let p = Dom_html.(createP document) in
p##.innerHTML := Js.string (Common.greet `Client);
Dom.appendChild body p
| null | https://raw.githubusercontent.com/aantron/dream/801745075b22b4506de537ec789482e759b86952/example/w-fullstack-jsoo/client/client.ml | ocaml | open Js_of_ocaml
let () =
let body = Dom_html.getElementById_exn "body" in
let p = Dom_html.(createP document) in
p##.innerHTML := Js.string (Common.greet `Client);
Dom.appendChild body p
| |
d626fb0499c1d05597fedd8eb8737c98d58e0d83d4e6c9dfb7abff4ad8d2c4dc | oden-lang/oden | Unification.hs | module Oden.Output.Unification where
import Text.PrettyPrint.Leijen
import Oden.Infer.Unification
import Oden.Output
import Oden.Pretty ()
instance OdenOutput UnificationError where
outputType _ = Error
name UnificationFail{} = "Infer.UnificationFail"
... | null | https://raw.githubusercontent.com/oden-lang/oden/10c99b59c8b77c4db51ade9a4d8f9573db7f4d14/src/Oden/Output/Unification.hs | haskell | module Oden.Output.Unification where
import Text.PrettyPrint.Leijen
import Oden.Infer.Unification
import Oden.Output
import Oden.Pretty ()
instance OdenOutput UnificationError where
outputType _ = Error
name UnificationFail{} = "Infer.UnificationFail"
... | |
2af755e5f233e35b28b5178d03cbf4504cf07e3c6df673410a3190638f911c89 | avh4/elm-format | ExpressionTest.hs | # LANGUAGE DataKinds #
module Parse.ExpressionTest where
import Test.Tasty
import Test.Tasty.HUnit
import Parse.Expression
import AST.V0_16
import AST.Structure
import qualified Box
import qualified Data.Bimap as Bimap
import Data.Coapplicative
import Data.Functor.Identity
import qualified Data.Indexed as I
import qu... | null | https://raw.githubusercontent.com/avh4/elm-format/73f55ab5940364456d72a7b7e4e23bec785e1a38/elm-format-lib/test/Parse/ExpressionTest.hs | haskell | A
B
C
D
E | # LANGUAGE DataKinds #
module Parse.ExpressionTest where
import Test.Tasty
import Test.Tasty.HUnit
import Parse.Expression
import AST.V0_16
import AST.Structure
import qualified Box
import qualified Data.Bimap as Bimap
import Data.Coapplicative
import Data.Functor.Identity
import qualified Data.Indexed as I
import qu... |
8b7c994c66c9dc46b63281eb220184efd9f38be9a1f0f78f956cb6b93d5a9da2 | braidchat/braid | subs.cljs | (ns braid.core.client.group-admin.subs)
| null | https://raw.githubusercontent.com/braidchat/braid/2e44eb6e77f1d203115f9b9c529bd865fa3d7302/src/braid/core/client/group_admin/subs.cljs | clojure | (ns braid.core.client.group-admin.subs)
| |
0ab83b227a0f9a49b99860b47fbd715592243d5536216b456c435ce2df7ea51a | onedata/op-worker | storage_sync_links_test_utils.erl | %%%-------------------------------------------------------------------
@author
( C ) 2019 ACK CYFRONET AGH
This software is released under the MIT license
cited in ' LICENSE.txt ' .
%%% @end
%%%-------------------------------------------------------------------
%%% @doc
%%%
%%% @end
%%%---------------------... | null | https://raw.githubusercontent.com/onedata/op-worker/b09f05b6928121cec4d6b41ce8037fe056e6b4b3/test_distributed/storage_sync_links_test_utils.erl | erlang | -------------------------------------------------------------------
@end
-------------------------------------------------------------------
@doc
@end
-------------------------------------------------------------------
API
===================================================================
API functions
========... | @author
( C ) 2019 ACK CYFRONET AGH
This software is released under the MIT license
cited in ' LICENSE.txt ' .
-module(storage_sync_links_test_utils).
-author("Jakub Kudzia").
-include_lib("cluster_worker/include/modules/datastore/datastore_links.hrl").
-export([
add_link/4, add_link/5,
get_link/3,... |
7c6dc42e84ee81eb8a3d28b8ffb5b72b854ab74c0bda9081918100d2c48f24b6 | petertseng/adventofcode-hs-2022 | 21_monkey_math.hs | import AdventOfCode (readInputFile)
import AdventOfCode.Split (splitOnOne)
import Control.Arrow (second)
import Data.Map (Map)
import qualified Data.Map as Map
import Data.Ratio ((%), Ratio, denominator, numerator)
Some of my numerators / denominators exceed Int range , so I actually need Integer here .
type Rat = ... | null | https://raw.githubusercontent.com/petertseng/adventofcode-hs-2022/d9a2d89adba9dcdfee6629d08e3ed4a542482e54/bin/21_monkey_math.hs | haskell | import AdventOfCode (readInputFile)
import AdventOfCode.Split (splitOnOne)
import Control.Arrow (second)
import Data.Map (Map)
import qualified Data.Map as Map
import Data.Ratio ((%), Ratio, denominator, numerator)
Some of my numerators / denominators exceed Int range , so I actually need Integer here .
type Rat = ... | |
b1e91ce5c3d261dd36bffc4217ec4fefb2b0c20c46aba012177833f3199da5cd | rogeriochaves/npm-force-resolutions | clojurescript-repl.clj | (require '[cljs.repl :as repl])
(require '[cljs.repl.node :as node])
(def env (node/repl-env))
(repl/repl env)
(js/console.log "Hello CLJS!") | null | https://raw.githubusercontent.com/rogeriochaves/npm-force-resolutions/fe40f65ba8a70772b29be8716bbde7d80b0879c4/clojurescript-repl.clj | clojure | (require '[cljs.repl :as repl])
(require '[cljs.repl.node :as node])
(def env (node/repl-env))
(repl/repl env)
(js/console.log "Hello CLJS!") | |
56c1cabc01a0af92c3eeb5972e85e233680937941ea65cc2cee6a192e2b7b88d | spurious/sagittarius-scheme-mirror | %3a13.scm | ;; -*- scheme -*-
(library (srfi :13)
(export
list->string
make-string
reverse-list->string
string
string->list
string-any
string-append
string-append/shared
string-ci<
string-ci<=
string-ci<>
string-ci=
string-ci>
string-ci>=
string-compare... | null | https://raw.githubusercontent.com/spurious/sagittarius-scheme-mirror/53f104188934109227c01b1e9a9af5312f9ce997/sitelib/srfi/%253a13.scm | scheme | -*- scheme -*-
low level | (library (srfi :13)
(export
list->string
make-string
reverse-list->string
string
string->list
string-any
string-append
string-append/shared
string-ci<
string-ci<=
string-ci<>
string-ci=
string-ci>
string-ci>=
string-compare
string-compa... |
e6fced6059f02fdf45e43756838487110ddf38f8c0d348f067484aaf4660f624 | trptcolin/tictactoe-clojure | test_core.clj | (ns tictactoe.test_core
(:use
[clojure.test]
[tictactoe.core]))
(deftest test-make-board
(is (= [" " " " " "
" " " " " "
" " " " " "]
(make-board))))
(deftest test-empty-square
(is (empty-square? " ")))
(deftest test-nonempty-square
(is (not (empty-square? "X"))))
(deftest te... | null | https://raw.githubusercontent.com/trptcolin/tictactoe-clojure/758fbfaad5bf1075bb8a71fe852848467ea5b142/test/tictactoe/test_core.clj | clojure | (ns tictactoe.test_core
(:use
[clojure.test]
[tictactoe.core]))
(deftest test-make-board
(is (= [" " " " " "
" " " " " "
" " " " " "]
(make-board))))
(deftest test-empty-square
(is (empty-square? " ")))
(deftest test-nonempty-square
(is (not (empty-square? "X"))))
(deftest te... | |
2bdd770776d127ed76bd444be435154b83efc1ea47d11823a79334b44f27e503 | synduce/Synduce | sndmax_empty_base_case.ml | * @synduce -NB -n 30 -l
Target type .
type clist =
| Empty
| Elt of int
| Concat of clist * clist
(* Origin type. *)
type list =
| Nil
| Cons of int * list
(* Invariant: all elements are positive. *)
let rec allpos = function
| Empty -> true
| Elt x -> x > 0
| Concat (x, y) -> allpos x && allpos y
... | null | https://raw.githubusercontent.com/synduce/Synduce/d453b04cfb507395908a270b1906f5ac34298d29/benchmarks/constraints/sortedlist/sndmax_empty_base_case.ml | ocaml | Origin type.
Invariant: all elements are positive.
Representation function
Invariant: the list is sorted in decreasing order. | * @synduce -NB -n 30 -l
Target type .
type clist =
| Empty
| Elt of int
| Concat of clist * clist
type list =
| Nil
| Cons of int * list
let rec allpos = function
| Empty -> true
| Elt x -> x > 0
| Concat (x, y) -> allpos x && allpos y
;;
let rec repr = function
| Empty -> Nil
| Elt x -> Cons ... |
0b38c69aec697e663a6e29affbf8a89bf37ce6a0a43684ab94c048ae908859d3 | may-liu/qtalk | mod_privacy.erl | %%%----------------------------------------------------------------------
File :
Author : < >
%%% Purpose : jabber:iq:privacy support
Created : 21 Jul 2003 by < >
%%%
%%%
ejabberd , Copyright ( C ) 2002 - 2014 ProcessOne
%%%
%%% This program is free software; you can redistribute it and/or
mod... | null | https://raw.githubusercontent.com/may-liu/qtalk/f5431e5a7123975e9656e7ab239e674ce33713cd/qtalk_opensource/src/mod_privacy.erl | erlang | ----------------------------------------------------------------------
Purpose : jabber:iq:privacy support
This program is free software; you can redistribute it and/or
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; with... | File :
Author : < >
Created : 21 Jul 2003 by < >
ejabberd , Copyright ( C ) 2002 - 2014 ProcessOne
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation ; either version 2 of the
You should have received a copy of the GNU General Public Li... |
e1bea3300525a6bb0ac463439500a85847221afe25e1f54bd0931d509239d3c7 | astanin/moo | ExampleMain.hs | -- | The boring part common to many examples: command line options
-- and pretty-printing the results.
module ExampleMain
( exampleMain
, ExampleDefaults(..)
, exampleDefaults
) where
import Moo.GeneticAlgorithm.Binary
import Moo.GeneticAlgorithm.Continuous
import Moo.GeneticAlgorithm.Multiobjective
i... | null | https://raw.githubusercontent.com/astanin/moo/2e77a94a543d21360f7610c1ee0dda52813997c4/examples/ExampleMain.hs | haskell | | The boring part common to many examples: command line options
and pretty-printing the results.
stats overrid , and vice versa
print the best solution last;
(for scatter-plotting it above the others)
Process command line options to change the number of iterations
and logging behaviour. | module ExampleMain
( exampleMain
, ExampleDefaults(..)
, exampleDefaults
) where
import Moo.GeneticAlgorithm.Binary
import Moo.GeneticAlgorithm.Continuous
import Moo.GeneticAlgorithm.Multiobjective
import Moo.GeneticAlgorithm.Statistics
import Control.Monad (liftM, when)
import Data.List (intercalat... |
f2c85c256536ee32c3ea3fbb54a6e8a9bffe0fae1440fc5548268f92341b447b | huangz1990/real-world-haskell-cn | myFoldl.hs | -- file: ch04/myFoldl.hs
myFoldl :: (a -> b -> a) -> a -> [b] -> a
myFoldl f z xs = foldr step id xs z
where step x g a = g (f a x)
| null | https://raw.githubusercontent.com/huangz1990/real-world-haskell-cn/f67b07dd846b1950d17ff941d650089fcbbe9586/code/ch04/myFoldl.hs | haskell | file: ch04/myFoldl.hs |
myFoldl :: (a -> b -> a) -> a -> [b] -> a
myFoldl f z xs = foldr step id xs z
where step x g a = g (f a x)
|
eabcada47e96a44a37d2d739daff93b012ea0cc3d7f6d7cefe7ad1b612b04bc8 | jarohen/advent-of-code | day11.clj | (ns aoc2020.day11
(:require [aoc2020.util :as util]
[clojure.test :as t]
[sss.arrows :refer [->% ->>%]]))
(defn parse-seats [rows]
(vec (for [row rows]
(vec (for [col row]
(case col
\. :no-seat
\L :empty
\# :occu... | null | https://raw.githubusercontent.com/jarohen/advent-of-code/3fa1d87a539fb9163b05b732973bbd415dd21312/2020/src/aoc2020/day11.clj | clojure | stop when we've gone off the map | (ns aoc2020.day11
(:require [aoc2020.util :as util]
[clojure.test :as t]
[sss.arrows :refer [->% ->>%]]))
(defn parse-seats [rows]
(vec (for [row rows]
(vec (for [col row]
(case col
\. :no-seat
\L :empty
\# :occu... |
81aa272d49e1651ee36f7fafceb46e308533e7dd8846177d12ad7bd4e307b6eb | spacegangster/space-ui | reset_css.cljc | (ns space-ui.reset-css)
(def reset
"html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset... | null | https://raw.githubusercontent.com/spacegangster/space-ui/95639627e206aaf6d8b2289ae4ab26e00ca10677/src/space_ui/reset_css.cljc | clojure | (ns space-ui.reset-css)
(def reset
"html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset... | |
a7065c9091deef9c85126f5eb96ca4c3aae7d02abf84d4975ca6da9a81dd862a | reach-sh/reach-lang | Freshen.hs | module Reach.Freshen
( freshen
, freshen_
, freshen_top
, Freshen
)
where
import Control.Monad.Reader
import qualified Data.Aeson as AS
import Data.IORef
import qualified Data.Map.Strict as M
import Data.Maybe
import Reach.AST.DLBase
import Reach.AST.LL
import Reach.AST.EP
import Reach.Counter
import Reach.U... | null | https://raw.githubusercontent.com/reach-sh/reach-lang/f79282c49705c66fc10489045d502d17621d60c5/hs/src/Reach/Freshen.hs | haskell | # OVERLAPPABLE #
If we can ever recover the label information, replace the key. | module Reach.Freshen
( freshen
, freshen_
, freshen_top
, Freshen
)
where
import Control.Monad.Reader
import qualified Data.Aeson as AS
import Data.IORef
import qualified Data.Map.Strict as M
import Data.Maybe
import Reach.AST.DLBase
import Reach.AST.LL
import Reach.AST.EP
import Reach.Counter
import Reach.U... |
485c7f8e7495c220ee39a6721d998ff1d201e8af8ce2d5d77187d8baef5778fc | whamtet/Excel-REPL | server.clj | (ns ^{:doc "Default server implementations"
:author "Chas Emerick"}
clojure.tools.nrepl.server
(:require [clojure.tools.nrepl :as repl]
[clojure.tools.nrepl.debug :as debug]
(clojure.tools.nrepl [ack :as ack]
[transport :as t]
... | null | https://raw.githubusercontent.com/whamtet/Excel-REPL/cae2ef8e423e2f2723c60e4758785973f06c6ba4/Excel-REPL/nrepl/clojure/tools/nrepl/server.clj | clojure | DEBUG
DEBUG
DEBUG
DEBUG
DEBUG
DEBUG
should always be true for the socket server...
(t/send transport (response-for msg :status #{:error :unknown-op :done} :op op))
these
drop for 0.3.0 ; this is what 's
causing the print-method silliness below
DM:(InetSocketAddress. bind port) (InetSocketAddress. port... | (ns ^{:doc "Default server implementations"
:author "Chas Emerick"}
clojure.tools.nrepl.server
(:require [clojure.tools.nrepl :as repl]
[clojure.tools.nrepl.debug :as debug]
(clojure.tools.nrepl [ack :as ack]
[transport :as t]
... |
7d3531721a8e9e05237387675f01199e4979a8b3dd711e217040cca5d18cbc5a | zotonic/zotonic | filter_pickle.erl | @author < >
2013 - 2023
%% @doc Pickle a term, for inclusion in an input field or query argument.
%% @end
Copyright 2013 - 2023
%%
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 Li... | null | https://raw.githubusercontent.com/zotonic/zotonic/62d959610061e6d2a8aed316b63fc1dafa3dd058/apps/zotonic_mod_base/src/filters/filter_pickle.erl | erlang | @doc Pickle a term, for inclusion in an input field or query argument.
@end
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... | @author < >
2013 - 2023
Copyright 2013 - 2023
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
distributed under the License is distributed on an " AS IS " BASIS ,
-module(filter_pickle).
-export([pickle/2]).
pickle(Data, Context) ->
z_crypto:pickle(Data, Context).
|
87130dc9e76df9a97a652e3124405d096d3044d37ee7541e51de8256a8bbb0ee | moby/datakit | store.mli | module type S0 =
Irmin.S
with type metadata = Metadata.t
and type Commit.Hash.t = Irmin.Hash.SHA1.t
and type Tree.Hash.t = Irmin.Hash.SHA1.t
and type Contents.Hash.t = Irmin.Hash.SHA1.t
module type S =
S0
with type contents = Blob.t
and type key = Path.t
and type step = Path.step
... | null | https://raw.githubusercontent.com/moby/datakit/e047e55a2dfa3aaec02398d7d7699f4f7afd2b47/src/datakit/store.mli | ocaml | module type S0 =
Irmin.S
with type metadata = Metadata.t
and type Commit.Hash.t = Irmin.Hash.SHA1.t
and type Tree.Hash.t = Irmin.Hash.SHA1.t
and type Contents.Hash.t = Irmin.Hash.SHA1.t
module type S =
S0
with type contents = Blob.t
and type key = Path.t
and type step = Path.step
... | |
7fb3150a4c105e970cec07bfd7be104771bc8f6340c113ba7646a641d2b41d58 | deltam/neuro | core_test.clj | (ns spiral.core-test
(:require [clojure.test :refer :all]
[spiral.core :refer :all]))
(deftest a-test
(testing "FIXME, I fail."
(is (= 0 1))))
| null | https://raw.githubusercontent.com/deltam/neuro/a8936bb72f0901678fb1556875c49f95f2bc3ce4/examples/spiral/test/spiral/core_test.clj | clojure | (ns spiral.core-test
(:require [clojure.test :refer :all]
[spiral.core :refer :all]))
(deftest a-test
(testing "FIXME, I fail."
(is (= 0 1))))
| |
4e09bb74733d9e395ba3080666dfe0862b4e6451af128f5ab325b0da978825a2 | umd-cmsc330/cmsc330spring22 | pbt.ml | open OUnit2
open QCheck
open P4a.MicroCamlTypes
open P4a.Lexer
open P4a.Parser
let test_simple_def =
Test.make
~name:"test_simple_def"
~count:1000
(small_int)
(fun x ->
let def_string = "def " ^ "validstring" ^ " = " ^ string_of_int x ^ ";;" in
let ast = def_string |> tokenize |> parse_mutop in
... | null | https://raw.githubusercontent.com/umd-cmsc330/cmsc330spring22/3497b00e0b6449e6af5f78a9b0718c959b6c26fb/project4a/test/pbt/pbt.ml | ocaml | open OUnit2
open QCheck
open P4a.MicroCamlTypes
open P4a.Lexer
open P4a.Parser
let test_simple_def =
Test.make
~name:"test_simple_def"
~count:1000
(small_int)
(fun x ->
let def_string = "def " ^ "validstring" ^ " = " ^ string_of_int x ^ ";;" in
let ast = def_string |> tokenize |> parse_mutop in
... | |
e7b569180231d8e5ad795dde463762080000a07b29f1869af3176bfe5f7778c3 | NorfairKing/smos | Work.hs | # LANGUAGE DeriveGeneric #
# LANGUAGE RecordWildCards #
# OPTIONS_GHC -fno - warn - unused - pattern - binds #
module Smos.Cursor.Report.Work where
import Control.DeepSeq
import Cursor.Map.KeyValue (keyValueCursorTraverseKeyCase)
import Cursor.Simple.Forest
import Cursor.Simple.List.NonEmpty
import Cursor.Simple.Map
... | null | https://raw.githubusercontent.com/NorfairKing/smos/3b7021c22915ae16ae721c7da60d715e24f4e6bb/smos-report-cursor/src/Smos/Cursor/Report/Work.hs | haskell | Results can be empty, otherwise an empty report is not valid.
declare "The work report cursor determines the selections of unselected parts" $ case workReportCursorSelection of
should not fail.
The order of these constructors matters for shrinking
If there are no entries without context, keep going.
If there were... | # LANGUAGE DeriveGeneric #
# LANGUAGE RecordWildCards #
# OPTIONS_GHC -fno - warn - unused - pattern - binds #
module Smos.Cursor.Report.Work where
import Control.DeepSeq
import Cursor.Map.KeyValue (keyValueCursorTraverseKeyCase)
import Cursor.Simple.Forest
import Cursor.Simple.List.NonEmpty
import Cursor.Simple.Map
... |
e65eaedbe92a111138185cda11fefc3c0bdbc13951b83524673edfab74dcffb9 | RickMoynihan/lein-tools-deps | core.clj | (ns criterium.core)
(defn foo
"I don't do a whole lot."
[]
:it-works!) | null | https://raw.githubusercontent.com/RickMoynihan/lein-tools-deps/ee3acdfb9b03b1891618acb8eaee5956886f1743/example/criterium/src/criterium/core.clj | clojure | (ns criterium.core)
(defn foo
"I don't do a whole lot."
[]
:it-works!) | |
d4367d11e851a16dad04e55b025ca8980bd12168f9537c320d72519e3309487a | ocaml-multicore/ocaml-tsan | odoc_class.mli | (**************************************************************************)
(* *)
(* OCaml *)
(* *)
... | null | https://raw.githubusercontent.com/ocaml-multicore/ocaml-tsan/f54002470cc6ab780963cc81b11a85a820a40819/ocamldoc/odoc_class.mli | ocaml | ************************************************************************
OCaml
... | , projet Cambium , INRIA Paris
Copyright 2022 Institut National de Recherche en Informatique et
the GNU Lesser General Public License version 2.1 , with the
module Name = Odoc_name
type class_element =
Class_attribute of Odoc_value.t_attribute
| Class_method ... |
d82afc5d0370efbfa7df8c48418bfca18afb35e9bfbaeb50df90bce3a1c1d798 | msakai/toysolver | Simple.hs | # LANGUAGE ScopedTypeVariables #
# OPTIONS_GHC -Wall #
{-# OPTIONS_HADDOCK show-extensions #-}
-----------------------------------------------------------------------------
-- |
Module : ToySolver . Arith . Simplex . Textbook . LPSolver . Simple
Copyright : ( c ) 2011
-- License : BSD-style
--
-... | null | https://raw.githubusercontent.com/msakai/toysolver/6233d130d3dcea32fa34c26feebd151f546dea85/src/ToySolver/Arith/Simplex/Textbook/LPSolver/Simple.hs | haskell | # OPTIONS_HADDOCK show-extensions #
---------------------------------------------------------------------------
|
License : BSD-style
Maintainer :
Stability : provisional
Portability : non-portable
High-Level API for LPSolver.hs
----------------------------------------------------------------------... | # LANGUAGE ScopedTypeVariables #
# OPTIONS_GHC -Wall #
Module : ToySolver . Arith . Simplex . Textbook . LPSolver . Simple
Copyright : ( c ) 2011
module ToySolver.Arith.Simplex.Textbook.LPSolver.Simple
( OptResult (..)
, minimize
, maximize
, optimize
, solve
) where
import Control.Mona... |
e1861da73ff75e0368fbb8756b4c17de52c45b42732542550ae75b5a032f302d | Perry961002/SICP | exa2.2.2-hierachical-structure.scm | ;统计树中树叶的个数
(define (count-leaves x)
(cond ((null? x) 0)
((not (pair? x)) 1)
(else (+ (count-leaves (car x))
(count-leaves (cdr x))))))
;树tree中的每个数值都乘以factor
(define (scale-tree tree factor)
(cond ((null? tree) '())
((not (pair? tree)) (* tree factor))
... | null | https://raw.githubusercontent.com/Perry961002/SICP/89d539e600a73bec42d350592f0ac626e041bf16/Chap2/example/exa2.2.2-hierachical-structure.scm | scheme | 统计树中树叶的个数
树tree中的每个数值都乘以factor
用map迭代实现 | (define (count-leaves x)
(cond ((null? x) 0)
((not (pair? x)) 1)
(else (+ (count-leaves (car x))
(count-leaves (cdr x))))))
(define (scale-tree tree factor)
(cond ((null? tree) '())
((not (pair? tree)) (* tree factor))
(else
(cons (scale-t... |
38724207b02b4241e6c8c25fddffcee9b9b940d103299cd1253c2d6a7545db84 | losfair/Violet | PC.hs | module Violet.Frontend.PC where
import Clash.Prelude
import qualified Violet.Types.Fetch as FetchT
import qualified Violet.Types.Fifo as FifoT
import qualified Violet.Types.Gpr as GprT
import qualified Violet.Config as Config
data DeferredBranchApplication = Deferred | NotDeferred
deriving (Generic, NFDataX)
pc ... | null | https://raw.githubusercontent.com/losfair/Violet/dcdd05f8dc08a438a157347f424966da73ccc9b8/src/Violet/Frontend/PC.hs | haskell | An applied branch from backend implies early rectification resolution.
Early rectifications between backend branch request and ack should be ignored.
And responses from predecode are only valid when the gated registers are enabled (FifoT.CanPush). | module Violet.Frontend.PC where
import Clash.Prelude
import qualified Violet.Types.Fetch as FetchT
import qualified Violet.Types.Fifo as FifoT
import qualified Violet.Types.Gpr as GprT
import qualified Violet.Config as Config
data DeferredBranchApplication = Deferred | NotDeferred
deriving (Generic, NFDataX)
pc ... |
41ae5afaa14d2962aa9e6501272281c667281a98e7d735a3f9d7bb3f67d0b06f | racket/eopl | tests.rkt | #lang eopl
(require eopl/tests/private/utils)
(require "data-structures.rkt") ; for expval constructors
(require "lang.rkt") ; for scan&parse
(require "interp.rkt") ; for value-of-program
run : String - > ExpVal
Page : 71
(define run
(lambda (string)
(value-of-program (scan&parse stri... | null | https://raw.githubusercontent.com/racket/eopl/43575d6e95dc34ca6e49b305180f696565e16e0f/tests/chapter3/let-lang/tests.rkt | racket | for expval constructors
for scan&parse
for value-of-program
tests ;;;;;;;;;;;;;;;;
simple arithmetic
nested arithmetic
simple variables
simple unbound variables
simple conditionals
test dynamic typechecking
make sure that the test and both arms get evaluated
properly.
and make sure the other arm doesn't g... | #lang eopl
(require eopl/tests/private/utils)
run : String - > ExpVal
Page : 71
(define run
(lambda (string)
(value-of-program (scan&parse string))))
(define equal-answer?
(lambda (ans correct-ans)
(equal? ans (sloppy->expval correct-ans))))
(define sloppy->expval
(lambda (sloppy-val)
(cond
... |
b447f8707284443540241b8f56db6a87ea0a0c09b9e0a1ce6dd76e6a0d1e54c4 | SquidDev/illuaminate | locate.mli | open IlluaminateCore.Syntax
type node =
| DotArg of token
| Expr of expr
| FunctionName of function_name
| Name of name
| Program of program
| Stmt of stmt
| TableItem of table_item
| Var of var
val pp_node : Format.formatter -> node -> unit
val pp_node_short : Format.formatter -> node -> unit
(** At... | null | https://raw.githubusercontent.com/SquidDev/illuaminate/06a499ba9ac51b605249add0ab2987d1868f8836/src/bin/lsp/locate.mli | ocaml | * Attempt to locate the node the cursor is currently within. | open IlluaminateCore.Syntax
type node =
| DotArg of token
| Expr of expr
| FunctionName of function_name
| Name of name
| Program of program
| Stmt of stmt
| TableItem of table_item
| Var of var
val pp_node : Format.formatter -> node -> unit
val pp_node_short : Format.formatter -> node -> unit
val lo... |
fc790d0d8628560f07c1b7799cc24d8dcbad242b81b66084ce681fc4cda0103b | jackfirth/rebellion | transposing.rkt | #lang racket/base
(require racket/contract/base)
(provide
(contract-out
[transposing
(->* (#:into reducer?) (#:ordered? boolean?) (transducer/c (sequence/c any/c) any/c))]))
(require racket/match
racket/sequence
rebellion/base/variant
rebellion/collection/vector
rebellion... | null | https://raw.githubusercontent.com/jackfirth/rebellion/5e2e10817016b0abbb251ed743597e8895a225c3/streaming/transducer/private/transposing.rkt | racket | @---------------------------------------------------------------------------------------------------- | #lang racket/base
(require racket/contract/base)
(provide
(contract-out
[transposing
(->* (#:into reducer?) (#:ordered? boolean?) (transducer/c (sequence/c any/c) any/c))]))
(require racket/match
racket/sequence
rebellion/base/variant
rebellion/collection/vector
rebellion... |
b8b34962d3eca1c8e31338b976b6bc002cb9504d681c45b06258e88979ef2aa9 | CREATe-centre/sociaml-tumblr-api | myocamlbuild.ml | OASIS_START
(* DO NOT EDIT (digest: f47e096ebff1c2edb0cae4a441bfcb39) *)
module OASISGettext = struct
# 22 " src / oasis / OASISGettext.ml "
let ns_ str =
str
let s_ str =
str
let f_ (str: ('a, 'b, 'c, 'd) format4) =
str
let fn_ fmt1 fmt2 n =
if n = 1 then
fmt1^^""
else
... | null | https://raw.githubusercontent.com/CREATe-centre/sociaml-tumblr-api/0d90ba119ce8ce0663fe605688eca2bbee35d549/myocamlbuild.ml | ocaml | DO NOT EDIT (digest: f47e096ebff1c2edb0cae4a441bfcb39)
these functions are not really officially exported
ocamlfind command
This lists all supported packages.
Mock to list available syntaxes.
By using Before_options one let command line options have an higher
* priority on the contrary using After... | OASIS_START
module OASISGettext = struct
# 22 " src / oasis / OASISGettext.ml "
let ns_ str =
str
let s_ str =
str
let f_ (str: ('a, 'b, 'c, 'd) format4) =
str
let fn_ fmt1 fmt2 n =
if n = 1 then
fmt1^^""
else
fmt2^^""
let init =
[]
end
module OASISExpr = s... |
a41dd54ccdcf73f4dfc8c4601df5e06fbca924e1035382ca58a35723759b200a | roddyyaga/quests | session.ml | type t = {
max_pool_size: int;
table:
( string,
( Cohttp.Request.t * Cohttp_lwt.Body.t,
Cohttp.Response.t * Cohttp_lwt.Body.t )
Lwt_streams_queue.t
Queue.t )
Hashtbl.t;
table_lock: Lwt_mutex.t;
}
let create ?(max_pool_size = 16) () =
{ max_pool_size; table = Hashtbl.create 16;... | null | https://raw.githubusercontent.com/roddyyaga/quests/72395040b5da1f02a6fe3a0fe0d1e96e9f8d50cd/lib/session.ml | ocaml | If an exception occured in [Lwt_streams_queue.process]
(because of a closed connection) this won't be called,
so the handler won't be reused. | type t = {
max_pool_size: int;
table:
( string,
( Cohttp.Request.t * Cohttp_lwt.Body.t,
Cohttp.Response.t * Cohttp_lwt.Body.t )
Lwt_streams_queue.t
Queue.t )
Hashtbl.t;
table_lock: Lwt_mutex.t;
}
let create ?(max_pool_size = 16) () =
{ max_pool_size; table = Hashtbl.create 16;... |
113eb80e6bf57601580a83aacc0335f6f55b82e76adc1d289e7c06b3c1b643b5 | ice1000/learn | alternate-case.hs | module AlternateCase where
import Data.Char
alternateCase :: String -> String
alternateCase = ((\x -> if isUpper x then toLower x else toUpper x) <$>)
| null | https://raw.githubusercontent.com/ice1000/learn/4ce5ea1897c97f7b5b3aee46ccd994e3613a58dd/Haskell/CW-Kata/alternate-case.hs | haskell | module AlternateCase where
import Data.Char
alternateCase :: String -> String
alternateCase = ((\x -> if isUpper x then toLower x else toUpper x) <$>)
| |
c7aab434ad57ec923a393cdb444b49ca3b41dee1f802473a7a1032453f6580e1 | fragnix/fragnix | CyclesData.hs | module CyclesData where
import {-# SOURCE #-} CyclesInstance
data D = D deriving (Show)
| null | https://raw.githubusercontent.com/fragnix/fragnix/b9969e9c6366e2917a782f3ac4e77cce0835448b/tests/quick/Cycles/CyclesData.hs | haskell | # SOURCE # | module CyclesData where
data D = D deriving (Show)
|
e520ba3e60ce9e5d9e58f697627b9e8c798a31ced3114a9dff582eeb35c318a1 | rohitjha/DiMPL | Set.hs | |
Module : Set
Description : Set module for the DiMPL DSL
Copyright : ( c ) , 2016
License : BSD2
Maintainer :
Stability : Stable
Functionality for :
* Union
* Intersection
* Difference
* Membership
* Cardinality
* Null set verification
* Su... | null | https://raw.githubusercontent.com/rohitjha/DiMPL/087c499ba104dec897fe325f86580e6d623c86ee/src/Set.hs | haskell | |
The 'listToSet' function converts a list to 'Set'.
For example:
>>> let l = [1,2,3]
>>> let s = listToSet l
>>> s
Set {1,2,3}
|
The 'isNotNullSet' function checks if a 'Set' is not null/empty.
For example:
>>> isNotNullSet (Set [1,2,3])
True
>>> isNotNullSet (Set [])
... | |
Module : Set
Description : Set module for the DiMPL DSL
Copyright : ( c ) , 2016
License : BSD2
Maintainer :
Stability : Stable
Functionality for :
* Union
* Intersection
* Difference
* Membership
* Cardinality
* Null set verification
* Su... |
bf121887d62dc99b9f1167e29a9329bd6fcc698b6c468aa31abd2118decaaf6f | incoherentsoftware/defect-process | Behavior.hs | module Enemy.All.Blob.Behavior
( BlobEnemyBehaviorInstr(..)
, HurtType(..)
, BlobEnemyBehavior(..)
, isHurtBehavior
, isFallenBehavior
, isFallenHurtBehavior
, isWallSplatBehavior
, isWallHurtBehavior
, isLaunchedBehavior
, isIdleBehavior
) where
import Util
data BlobEnemyB... | null | https://raw.githubusercontent.com/incoherentsoftware/defect-process/8797aad1d93bff5aadd7226c39a48f45cf76746e/src/Enemy/All/Blob/Behavior.hs | haskell | module Enemy.All.Blob.Behavior
( BlobEnemyBehaviorInstr(..)
, HurtType(..)
, BlobEnemyBehavior(..)
, isHurtBehavior
, isFallenBehavior
, isFallenHurtBehavior
, isWallSplatBehavior
, isWallHurtBehavior
, isLaunchedBehavior
, isIdleBehavior
) where
import Util
data BlobEnemyB... | |
beb44caad7c0001d432ccd1ce482629ec3f6b2c3de1748270412b8fd0c16221b | coq/coq | comExtraDeps.ml | (************************************************************************)
(* * The Coq Proof Assistant / The Coq Development Team *)
v * Copyright INRIA , CNRS and contributors
< O _ _ _ , , * ( see version control and CREDITS file for authors & dates )
\VV/ * * *... | null | https://raw.githubusercontent.com/coq/coq/ed7237f7435e03043a4ef2f096777f0a93da1102/vernac/comExtraDeps.ml | ocaml | **********************************************************************
* The Coq Proof Assistant / The Coq Development Team
// * This file is distributed under the terms of the
* (see LICENSE file for the text of the license)
************************************... | v * Copyright INRIA , CNRS and contributors
< O _ _ _ , , * ( see version control and CREDITS file for authors & dates )
\VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* GNU Lesser Gener... |
f91ab136d2e9c2f5e713e62b0097f464c0b1b018494281c9dd209fc687208283 | tarides/opam-monorepo | depext.mli | val cmd : int Cmdliner.Cmd.t
| null | https://raw.githubusercontent.com/tarides/opam-monorepo/9262e7f71d749520b7e046fbd90a4732a43866e9/cli/depext.mli | ocaml | val cmd : int Cmdliner.Cmd.t
| |
2c378cd8ce800074c361085f0dc4572127cab020c3d79f4eaf7c1a26dfa27089 | sebsheep/elm2node | Number.hs | # OPTIONS_GHC -Wall #
# LANGUAGE BangPatterns , UnboxedTuples #
module Parse.Number
( Number(..)
, number
, Outcome(..)
, chompInt
, chompHex
, precedence
)
where
import Data.Word (Word8)
import Foreign.Ptr (Ptr, plusPtr, minusPtr)
import qualified AST.Utils.Binop as Binop
import qualified Elm.Float ... | null | https://raw.githubusercontent.com/sebsheep/elm2node/602a64f48e39edcdfa6d99793cc2827b677d650d/compiler/src/Parse/Number.hs | haskell | HELPERS
NUMBERS
.
e
E
e
E
+
-
x
.
Return -1 if it has NO digits
Return -2 if it has BAD digits
# INLINE stepHex #
a
f
a
A
F
A | # OPTIONS_GHC -Wall #
# LANGUAGE BangPatterns , UnboxedTuples #
module Parse.Number
( Number(..)
, number
, Outcome(..)
, chompInt
, chompHex
, precedence
)
where
import Data.Word (Word8)
import Foreign.Ptr (Ptr, plusPtr, minusPtr)
import qualified AST.Utils.Binop as Binop
import qualified Elm.Float ... |
0da6e151b8a3d811863f1a992d993c9e778bdea5efd61fce3725101b2bdf5349 | xsc/invariant | predicate.clj | (ns invariant.core.predicate
(:require [invariant.core.protocols :refer :all]))
(deftype Predicate [name predicate]
Invariant
(run-invariant [_ path state value]
(if (predicate state value)
(invariant-holds path state value)
(invariant-failed name path state value))))
(deftype SeqPredicate [name... | null | https://raw.githubusercontent.com/xsc/invariant/45425bcc69d0bc896efd5307a640dbdb06b61797/src/invariant/core/predicate.clj | clojure | (ns invariant.core.predicate
(:require [invariant.core.protocols :refer :all]))
(deftype Predicate [name predicate]
Invariant
(run-invariant [_ path state value]
(if (predicate state value)
(invariant-holds path state value)
(invariant-failed name path state value))))
(deftype SeqPredicate [name... | |
b0293be9eb1562d87231766512e7334b8143560f4a2744b24ed0975678b7595c | patrikja/AFPcourse | Gen.hs | module Expr.Gen where
import Expr
import Test.QuickCheck
import Control.Applicative
instance Arbitrary Expr where
arbitrary = sized arbExpr
Exercise1 : generate " well - typed " expressions ( in ExprB & ExprI )
arbExpr :: Int -> Gen Expr
arbExpr n | n <= 0 = basecases
arbExpr n | otherwise = oneof
[ basecases... | null | https://raw.githubusercontent.com/patrikja/AFPcourse/1a079ae80ba2dbb36f3f79f0fc96a502c0f670b6/L11/src/Expr/Gen.hs | haskell | module Expr.Gen where
import Expr
import Test.QuickCheck
import Control.Applicative
instance Arbitrary Expr where
arbitrary = sized arbExpr
Exercise1 : generate " well - typed " expressions ( in ExprB & ExprI )
arbExpr :: Int -> Gen Expr
arbExpr n | n <= 0 = basecases
arbExpr n | otherwise = oneof
[ basecases... | |
5518c9e318b758792657aa8eea0a0702604e824dfd5d792cbd1caa1a9ff202cf | juspay/atlas | OnSearch.hs | |
Copyright 2022 Juspay Technologies Pvt Ltd
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
you may not use this file except in compliance with the License .
You may obtain a copy of the License at
-2.0
Unless required by applicable law or agreed to in writing , software
dis... | null | https://raw.githubusercontent.com/juspay/atlas/e64b227dc17887fb01c2554db21c08284d18a806/app/parking-bap/src/Core/API/OnSearch.hs | haskell | |
Copyright 2022 Juspay Technologies Pvt Ltd
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
you may not use this file except in compliance with the License .
You may obtain a copy of the License at
-2.0
Unless required by applicable law or agreed to in writing , software
dis... | |
9bb243c6f08c7b33669bdbd92f89f8cce0a042354fb1fb0033fdb9381a6c3a22 | huangz1990/SICP-answers | 77-louis-complex.scm | 77-louis-complex.scm
(load "p123-install-rectangular-package.scm")
(load "p124-install-polar-package.scm")
(load "p130-install-complex-package.scm")
(load "p125-generic-selector.scm")
(install-polar-package)
(install-rectangular-package)
(install-complex-package)
| null | https://raw.githubusercontent.com/huangz1990/SICP-answers/15e3475003ef10eb738cf93c1932277bc56bacbe/chp2/code/77-louis-complex.scm | scheme | 77-louis-complex.scm
(load "p123-install-rectangular-package.scm")
(load "p124-install-polar-package.scm")
(load "p130-install-complex-package.scm")
(load "p125-generic-selector.scm")
(install-polar-package)
(install-rectangular-package)
(install-complex-package)
| |
5725ffdc4638d3d57c2fcfc4238bf7b82ea4bc8adc9c388cb85ebcdbaad59df7 | UU-ComputerScience/uhc | deriv1.hs | basic case : deriving for for some data type , expected outcome : 2121
% % inline test ( ) --
class Eq x where
(==) :: x -> x -> Bool
(/=) :: x -> x -> Bool
x /= y = not (x == y)
instance Eq Int where
(==) = primEqInt
data X a = XX a Int | YY a
deriving (Eq)
main
= (if XX 3 4 /= XX 3 3 then 1 else... | null | https://raw.githubusercontent.com/UU-ComputerScience/uhc/f2b94a90d26e2093d84044b3832a9a3e3c36b129/EHC/test/regress/95/deriv1.hs | haskell | basic case : deriving for for some data type , expected outcome : 2121
class Eq x where
(==) :: x -> x -> Bool
(/=) :: x -> x -> Bool
x /= y = not (x == y)
instance Eq Int where
(==) = primEqInt
data X a = XX a Int | YY a
deriving (Eq)
main
= (if XX 3 4 /= XX 3 3 then 1 else 2)
`primAddInt`
(... | |
f017b73119a644c219b979fffc958bc7275b76ac0ffb53eb70a32f7c3ee4c446 | zanderso/cil-template | tut5.ml |
open Cil
open Pretty
open Tututil
module L = List
module E = Errormsg
let compinfoOfLval (blv : lval) : compinfo =
match unrollType(typeOfLval blv) with
| TComp (ci, _) -> ci
| _ -> E.s(E.bug "Expected TComp for type of %a" d_lval blv)
let zeroPtr (fd : fundec) (blv : lval) : stmt list =
[i2s (Set(b... | null | https://raw.githubusercontent.com/zanderso/cil-template/fc2a0548b2644c53c4840df2a09c1c90b2af2aee/src/tut5.ml | ocaml |
open Cil
open Pretty
open Tututil
module L = List
module E = Errormsg
let compinfoOfLval (blv : lval) : compinfo =
match unrollType(typeOfLval blv) with
| TComp (ci, _) -> ci
| _ -> E.s(E.bug "Expected TComp for type of %a" d_lval blv)
let zeroPtr (fd : fundec) (blv : lval) : stmt list =
[i2s (Set(b... | |
ebf40e4719fca93537790d4335f6384445e6b889b09838a88d1b17e5ac91fa2b | dbuenzli/tgls | linkgl3.ml | ---------------------------------------------------------------------------
Copyright ( c ) 2013 . All rights reserved .
Distributed under the ISC license , see terms at the end of the file .
% % NAME%% % % ---------------------------------------------------------------------------
Copyright (c) ... | null | https://raw.githubusercontent.com/dbuenzli/tgls/58bf47d393da00f24fa8e58521ddb9e3afb08d1d/test/linkgl3.ml | ocaml | just make sure the library is linked | ---------------------------------------------------------------------------
Copyright ( c ) 2013 . All rights reserved .
Distributed under the ISC license , see terms at the end of the file .
% % NAME%% % % ---------------------------------------------------------------------------
Copyright (c) ... |
f2b26639fddf54a81362ffd25c0e0c4b5f3a4a5091d401a5ec825a494bbe1f39 | locusmath/locus | object.clj | (ns locus.order.lattice.core.object
(:require [locus.set.logic.core.set :refer :all]
[locus.set.logic.limit.product :refer :all]
[locus.con.core.setpart :refer :all]
[locus.set.mapping.general.core.object :refer :all]
[locus.set.logic.structure.protocols :refer :all]
... | null | https://raw.githubusercontent.com/locusmath/locus/fb6068bd78977b51fd3c5783545a5f9986e4235c/src/clojure/locus/order/lattice/core/object.clj | clojure | A lattice is a thin category C containing all binary products and coproducts.
The coproducts are joins and the products are meets.
Ontology of lattices as categories
We need some special way of getting the underlying relation of lattice
We need to be able to have some means of visualizing lattices
Create a lattic... | (ns locus.order.lattice.core.object
(:require [locus.set.logic.core.set :refer :all]
[locus.set.logic.limit.product :refer :all]
[locus.con.core.setpart :refer :all]
[locus.set.mapping.general.core.object :refer :all]
[locus.set.logic.structure.protocols :refer :all]
... |
4fd7489457c64b1b6a29976fc4e987c3e98e7c713fd460ca7a914022f59db032 | ice1000/learn | snail.hs | module Snail where
exampleArray :: [[Int]]
exampleArray = [[1,2,3],
[8,9,4],
[7,6,5]]
--
exampleArray2 :: [[Int]]
exampleArray2 = [[1,2,3],
[4,5,6],
[7,8,9]]
--
snail :: [[Int]] -> [Int]
snail [] = []
snail [[a]] = [a]
snail [[a, b], [c, d]] = [a, b, ... | null | https://raw.githubusercontent.com/ice1000/learn/4ce5ea1897c97f7b5b3aee46ccd994e3613a58dd/Haskell/CW-Kata/snail.hs | haskell |
- | module Snail where
exampleArray :: [[Int]]
exampleArray = [[1,2,3],
[8,9,4],
[7,6,5]]
exampleArray2 :: [[Int]]
exampleArray2 = [[1,2,3],
[4,5,6],
[7,8,9]]
snail :: [[Int]] -> [Int]
snail [] = []
snail [[a]] = [a]
snail [[a, b], [c, d]] = [a, b, d, c]
... |
c45716e379427451a2c117f87d4acfde930113af814de5f8c014cf6c343c1737 | athos/admin-kit | handlers.cljs | (ns admin-kit.handlers
(:require [re-frame.core :as r]
[ajax.core :as ajax]
[clojure.string :as str]
[admin-kit.utils :as utils]
[admin-kit.transit :as transit]))
(r/register-handler
:request
[r/trim-v]
(fn [{:keys [base-path] :as db} [paths {:keys [method data]} ca... | null | https://raw.githubusercontent.com/athos/admin-kit/0c18d85ea5c5d187a5712a9741e6c9cc776d3afb/src/cljs/lib/admin_kit/handlers.cljs | clojure | this should not happen | (ns admin-kit.handlers
(:require [re-frame.core :as r]
[ajax.core :as ajax]
[clojure.string :as str]
[admin-kit.utils :as utils]
[admin-kit.transit :as transit]))
(r/register-handler
:request
[r/trim-v]
(fn [{:keys [base-path] :as db} [paths {:keys [method data]} ca... |
3f8bf1a75d4f324c139754a1557dfb987b0d2e07b4ffe2283a37fd9672edb2cc | Workiva/eva | metrics.clj | Copyright 2015 - 2019 Workiva Inc.
;;
;; Licensed under the Eclipse Public License 1.0 (the "License");
;; you may not use this file except in compliance with the License.
;; You may obtain a copy of the License at
;;
;; -1.0.php
;;
;; Unless required by applicable law or agreed to in writing, software
dist... | null | https://raw.githubusercontent.com/Workiva/eva/b7b8a6a5215cccb507a92aa67e0168dc777ffeac/core/src/eva/contextual/metrics.clj | clojure |
Licensed under the Eclipse Public License 1.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
-1.0.php
Unless required by applicable law or agreed to in writing, software
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either expre... | Copyright 2015 - 2019 Workiva Inc.
distributed under the License is distributed on an " AS IS " BASIS ,
(ns eva.contextual.metrics
(:require
[eva.contextual.logging :as logging]
[eva.contextual.utils :as utils]
[clojure.string :as str]
[recide.sanex.logging :as log]
[barometer.core]
[quartermas... |
e74ab0d77d9113327a6bf57ac30cc0f38114daeaaf3aaccfd11307e47c819e18 | facebook/flow | flow_polymorphic_ast_mapper.mli |
* 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/3087a6613a614e5a08f1fe2a7cb2b65edd07fff8/src/parser_utils/flow_polymorphic_ast_mapper.mli | 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... | |
298b97c4c28b8438a2fa783470afac00682d46ed7cc05956ab87777897b250e1 | NorfairKing/the-notes | Terms.hs | module Relations.Orders.Terms where
import Notes
makeDefs [
"antisymmetric"
, "partial order"
, "order"
, "comparable"
, "incomparable"
, "chain"
, "height"
, "antichain"
, "width"
, "greatest element"
, "smallest element"
, "least element"
, "maximal el... | null | https://raw.githubusercontent.com/NorfairKing/the-notes/ff9551b05ec3432d21dd56d43536251bf337be04/src/Relations/Orders/Terms.hs | haskell | module Relations.Orders.Terms where
import Notes
makeDefs [
"antisymmetric"
, "partial order"
, "order"
, "comparable"
, "incomparable"
, "chain"
, "height"
, "antichain"
, "width"
, "greatest element"
, "smallest element"
, "least element"
, "maximal el... | |
30919a78ed8843eeeae3ced1d682dcaf36c7c35975487847e145050d9c3f656d | MyDataFlow/ttalk-server | mod_muc_iq.erl | %% @doc Stores a table of custom IQ-handlers for mod_muc_room.
-module(mod_muc_iq).
-export([start_link/0,
process_iq/4,
register_iq_handler/4,
register_iq_handler/5,
unregister_iq_handler/2]).
%% gen_server callbacks
-export([init/1, handle_call/3, handle_cast/2, handle_info/2,
... | null | https://raw.githubusercontent.com/MyDataFlow/ttalk-server/07a60d5d74cd86aedd1f19c922d9d3abf2ebf28d/apps/ejabberd/src/group/mod_muc_iq.erl | erlang | @doc Stores a table of custom IQ-handlers for mod_muc_room.
gen_server callbacks
====================================================================
API
====================================================================
@doc Handle custom IQ.
Called from mod_muc_room.
TODO: Introduce some stricter type checkin... | -module(mod_muc_iq).
-export([start_link/0,
process_iq/4,
register_iq_handler/4,
register_iq_handler/5,
unregister_iq_handler/2]).
-export([init/1, handle_call/3, handle_cast/2, handle_info/2,
terminate/2, code_change/3]).
-compile({inline, [srv_name/0, tbl_name/0]}).
-in... |
8e767a5be0506dc07ac55524ec05db613e4afa700acddcb70f2287bbd3ea93d5 | robert-strandh/SICL | type-proclamations.lisp | (cl:in-package #:sicl-cons)
(declaim (ftype (function (t) t)
car cdr caar cadr cdar cddr
caaar caadr cadar caddr cdaar cdadr cddar cdddr
caaaar caaadr caadar caaddr cadaar cadadr caddar cadddr
cdaaar cdaadr cdadar cdaddr cddaar cddadr cdddar cddddr
... | null | https://raw.githubusercontent.com/robert-strandh/SICL/e8dc36d3486241809067986d6ea4bd0d221c1cbd/Code/Cons/type-proclamations.lisp | lisp | (cl:in-package #:sicl-cons)
(declaim (ftype (function (t) t)
car cdr caar cadr cdar cddr
caaar caadr cadar caddr cdaar cdadr cddar cdddr
caaaar caaadr caadar caaddr cadaar cadadr caddar cadddr
cdaaar cdaadr cdadar cdaddr cddaar cddadr cdddar cddddr
... | |
e426700e1123f9adcb545a85712b392ff8195c30cf064e9a3a0fe5b3adf0f47d | samcf/ogres | session.cljs | (ns ogres.app.session
(:require [clojure.set :refer [difference]]
[cognitect.transit :as transit]
[clojure.core.async :refer [chan sliding-buffer]]
[datascript.core :as ds]
[datascript.transit :as dst]
[ogres.app.env :as env]
[ogres.app.hooks :re... | null | https://raw.githubusercontent.com/samcf/ogres/1fd51eaf86504e33f81d1324676c1c9fdef7c856/src/main/ogres/app/session.cljs | clojure | Selectively merge parts of the previous local entity into the
next local entity.
Replace host as the local user, swap places in session
connections.
Maintain local window state when reconnecting and starting
with a window that references the same canvas.
Handles messages that are sent by the server, some of whic... | (ns ogres.app.session
(:require [clojure.set :refer [difference]]
[cognitect.transit :as transit]
[clojure.core.async :refer [chan sliding-buffer]]
[datascript.core :as ds]
[datascript.transit :as dst]
[ogres.app.env :as env]
[ogres.app.hooks :re... |
c7c3249a2086d4d4d3b1b19e60f4640aef712b886cc52655843dcbe81d872333 | ocsigen/js_of_ocaml | util.ml | Js_of_ocaml tests
* /
* Copyright ( C ) 2019
*
* This program is free software ; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation ; either version 2 of the License , or
* ( at your option ) any later vers... | null | https://raw.githubusercontent.com/ocsigen/js_of_ocaml/eae34864ebe70c3e93d373e87fcd7432f5a6d1d4/compiler/tests-compiler/util/util.ml | ocaml | this print shouldn't do anything, so if
something weird happens, we'll get the results here
this print shouldn't do anything, so if
something weird happens, we'll get the results here
this print shouldn't do anything, so if
something weird happens, we'll get the results here
This final comment sho... | Js_of_ocaml tests
* /
* Copyright ( C ) 2019
*
* This program is free software ; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation ; either version 2 of the License , or
* ( at your option ) any later vers... |
93d230eaf1241c8539d00277124b97f8d57111f934ff647cfdb4246001258a0f | quephird/fun-with-quil | fade-and-emerge.clj | (ns fun-with-quil.animations.fade-and-emerge
(:require [quil.core :as q :include-macros true]))
(defn setup []
(q/smooth)
; (q/no-loop)
)
(defn draw []
(let [fc (q/frame-count)
w (q/width)
h (q/height)]
(q/no-stroke)
(q/fill 0 5)
(q/rect 0 0 w h)
(q/translate (* 0.5 w) (* 0.... | null | https://raw.githubusercontent.com/quephird/fun-with-quil/3b3a6885771f5a1a4cffeb8379f05a28048a1616/src/fun_with_quil/animations/fade-and-emerge.clj | clojure | (q/no-loop) | (ns fun-with-quil.animations.fade-and-emerge
(:require [quil.core :as q :include-macros true]))
(defn setup []
(q/smooth)
)
(defn draw []
(let [fc (q/frame-count)
w (q/width)
h (q/height)]
(q/no-stroke)
(q/fill 0 5)
(q/rect 0 0 w h)
(q/translate (* 0.5 w) (* 0.5 h))
(q/ro... |
a6637f60acd47073013eb4e60f1c61e35cca319f618c3b566a1cfbef1f045b9d | deadpendency/deadpendency | Pipfile.hs | module DD.Effect.DetermineDependencies.Backend.LanguageFiles.Python.Pipfile
( PipfileInput (..),
ParsedPipfile (..),
parsedPipfileCodec,
)
where
import Common.Model.Dependency.Basic.BasicDependency
import Common.Model.Dependency.DependencyIdentifier
import Common.Model.Dependency.DependencyName
import Comm... | null | https://raw.githubusercontent.com/deadpendency/deadpendency/170d6689658f81842168b90aa3d9e235d416c8bd/apps/dependency-determiner/src/DD/Effect/DetermineDependencies/Backend/LanguageFiles/Python/Pipfile.hs | haskell | module DD.Effect.DetermineDependencies.Backend.LanguageFiles.Python.Pipfile
( PipfileInput (..),
ParsedPipfile (..),
parsedPipfileCodec,
)
where
import Common.Model.Dependency.Basic.BasicDependency
import Common.Model.Dependency.DependencyIdentifier
import Common.Model.Dependency.DependencyName
import Comm... | |
ca5a8026d051a8a8a5a9f11b0e01ad1f6af5cdbba12ac2934d1a11f2ff7ec93f | johnlawrenceaspden/hobby-code | nakkaya-xml-pprint.clj | ;; I like my html readable:
Nakkaya shows us the way in
;; -printing-xml-with-clojure/
(defn ppxml [xml]
(let [in (javax.xml.transform.stream.StreamSource. (java.io.StringReader. xml))
out (javax.xml.transform.stream.StreamResult. (java.io.StringWriter.))
transformer (.newTransformer
... | null | https://raw.githubusercontent.com/johnlawrenceaspden/hobby-code/48e2a89d28557994c72299962cd8e3ace6a75b2d/nakkaya-xml-pprint.clj | clojure | I like my html readable:
-printing-xml-with-clojure/ | Nakkaya shows us the way in
(defn ppxml [xml]
(let [in (javax.xml.transform.stream.StreamSource. (java.io.StringReader. xml))
out (javax.xml.transform.stream.StreamResult. (java.io.StringWriter.))
transformer (.newTransformer
(javax.xml.transform.TransformerFactory/newInstanc... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.