_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 |
|---|---|---|---|---|---|---|---|---|
6fb419b375f70e8b6f37d91abd0972e692606c9125c8066c63b48b2ac40854d9 | synduce/Synduce | mps_nosum.ml | * @synduce --no - lifting
type 'a clist =
| CNil
| Single of 'a
| Concat of 'a clist * 'a clist
type 'a list =
| Nil
| Cons of 'a * 'a list
(*
The maximum prefix sum without the sum auxiliary.
The function needs to be lifted for the problem to
be solvable.
See list/mps.ml for the version that inclu... | null | https://raw.githubusercontent.com/synduce/Synduce/d453b04cfb507395908a270b1906f5ac34298d29/benchmarks/unrealizable/mps_nosum.ml | ocaml |
The maximum prefix sum without the sum auxiliary.
The function needs to be lifted for the problem to
be solvable.
See list/mps.ml for the version that includes the lifting.
| * @synduce --no - lifting
type 'a clist =
| CNil
| Single of 'a
| Concat of 'a clist * 'a clist
type 'a list =
| Nil
| Cons of 'a * 'a list
let rec mps = function
| Nil -> 0
| Cons (hd, tl) ->
let _mps = mps tl in
max (_mps + hd) 0
[@@ensures fun x -> x >= 0]
;;
let rec clist_to_list = funct... |
979df5a9fda5705ed1c05df7c37abf00a1dd7b04c6a6aa4c819316ef223c8ecc | lispbuilder/lispbuilder | globals.lisp |
(in-package #:sdl-gfx-bin)
(defvar *dll-path* (make-pathname
:host (pathname-host #.(or *compile-file-truename*
*load-truename*))
:directory (pathname-directory #.(or *compile-file-truename*
... | null | https://raw.githubusercontent.com/lispbuilder/lispbuilder/589b3c6d552bbec4b520f61388117d6c7b3de5ab/lispbuilder-sdl-gfx/bin/globals.lisp | lisp |
(in-package #:sdl-gfx-bin)
(defvar *dll-path* (make-pathname
:host (pathname-host #.(or *compile-file-truename*
*load-truename*))
:directory (pathname-directory #.(or *compile-file-truename*
... | |
9c90d3efbce70ee5710ea237ec1d488e10bbdb56f84e38913a8e8485a747917f | agentm/project-m36 | RODatabaseContextOperator.hs | {-# LANGUAGE GADTs #-}
module TutorialD.Interpreter.RODatabaseContextOperator where
import ProjectM36.Base
import ProjectM36.Relation
import qualified ProjectM36.DataFrame as DF
import ProjectM36.Error
import ProjectM36.Tuple
import ProjectM36.InclusionDependency
import qualified ProjectM36.Client as C
import TutorialD... | null | https://raw.githubusercontent.com/agentm/project-m36/d35de3f5ae72deedc483bd35a2e19523608e821b/src/bin/TutorialD/Interpreter/RODatabaseContextOperator.hs | haskell | # LANGUAGE GADTs #
operators which only rely on database context reading
logically, these read-only operations could happen purely, but not if a remote call is required
render RelationalExprAtoms as TutorialD | module TutorialD.Interpreter.RODatabaseContextOperator where
import ProjectM36.Base
import ProjectM36.Relation
import qualified ProjectM36.DataFrame as DF
import ProjectM36.Error
import ProjectM36.Tuple
import ProjectM36.InclusionDependency
import qualified ProjectM36.Client as C
import TutorialD.Interpreter.Base
impor... |
b4c38f5967c3210e5a60aefa0140cf38320c23732dcd631bb8e1dd561640255d | tonyday567/readme-lhs | test.hs | # LANGUAGE RebindableSyntax #
# OPTIONS_GHC -Wall #
# OPTIONS_GHC -fno - warn - unused - imports #
module Main where
import NumHask.Prelude
import Test.DocTest
import Readme.Lhs
main :: IO ()
main =
doctest
[ "src/Readme/Lhs.hs"
]
| null | https://raw.githubusercontent.com/tonyday567/readme-lhs/40e76611f812afc7a5055122dc4ca112a6dd5bd3/test/test.hs | haskell | # LANGUAGE RebindableSyntax #
# OPTIONS_GHC -Wall #
# OPTIONS_GHC -fno - warn - unused - imports #
module Main where
import NumHask.Prelude
import Test.DocTest
import Readme.Lhs
main :: IO ()
main =
doctest
[ "src/Readme/Lhs.hs"
]
| |
e1bca3aaf37857b705cc58122b09ad5bebd2aa5e414d28943aeca68ec76d935a | matterhorn-chat/matterhorn | Constants.hs | module Matterhorn.Constants
( pageAmount
, userTypingExpiryInterval
, numScrollbackPosts
, previewMaxHeight
, normalChannelSigil
, normalChannelSigilChar
, userSigil
, userSigilChar
, editMarking
)
where
import Prelude ()
import Matterhorn.Prelude
import qualified Data.Text as T
-- | The number ... | null | https://raw.githubusercontent.com/matterhorn-chat/matterhorn/86fb97fae9aea66a2434fc085c1ff49c5bd96b86/src/Matterhorn/Constants.hs | haskell | | The number of rows to consider a "page" when scrolling
| The maximum height of the message preview, in lines.
Sigils | module Matterhorn.Constants
( pageAmount
, userTypingExpiryInterval
, numScrollbackPosts
, previewMaxHeight
, normalChannelSigil
, normalChannelSigilChar
, userSigil
, userSigilChar
, editMarking
)
where
import Prelude ()
import Matterhorn.Prelude
import qualified Data.Text as T
pageAmount :: In... |
6b30c405dd8f7c650f504d7fc835fff940c88e03f5cb68469d1604d7d28a908f | janestreet/universe | unordered_array_fold.ml | open Core_kernel
open Import
open Types.Kind
module Node = Types.Node
module Update = struct
type ('a, 'b) t =
| F_inverse of ('b -> 'a -> 'b)
| Update of ('b -> old_value:'a -> new_value:'a -> 'b)
[@@deriving sexp_of]
let update t ~f =
match t with
| Update update -> update
| F_inverse f_in... | null | https://raw.githubusercontent.com/janestreet/universe/b6cb56fdae83f5d55f9c809f1c2a2b50ea213126/incremental/src/unordered_array_fold.ml | ocaml | We make [num_changes_since_last_full_compute = full_compute_every_n_changes]
so that there will be a full computation the next time the node is computed.
We only reach this case if we have already done a full compute, in which case
[Uopt.is_some t.fold_value] and [Uopt.is_some old_value_opt]. | open Core_kernel
open Import
open Types.Kind
module Node = Types.Node
module Update = struct
type ('a, 'b) t =
| F_inverse of ('b -> 'a -> 'b)
| Update of ('b -> old_value:'a -> new_value:'a -> 'b)
[@@deriving sexp_of]
let update t ~f =
match t with
| Update update -> update
| F_inverse f_in... |
23e8c1f8a3936ab8cabc7df1e9df572f3edadd14796759faed59b1b6f5ee6e24 | objecthub/swift-lispkit | Queens.scm | ;;; Solve n-queens problem
;;;
Author :
Copyright © 2017 . 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 appl... | null | https://raw.githubusercontent.com/objecthub/swift-lispkit/a952f80bb85e6fd084770033141ed8edd2f46500/Sources/LispKit/Resources/Examples/Queens.scm | scheme | Solve n-queens problem
you may not use this file
except in compliance with the License. You may obtain a copy of the License at
-2.0
Unless required by applicable law or agreed to in writing, software distributed under the
either express or implied. See the License for the specific language governing permis... | Author :
Copyright © 2017 . All rights reserved .
License is distributed on an " AS IS " BASIS , WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND ,
(import (lispkit base))
(define (queens n)
(let try ((x 0) (y 0) (ps '()) (pss '()))
pss)
(cons (reverse ps) pss))
(try x (+ y... |
ca80a7d15f306d40dde2c97ca4674b4afd8080195f4d1e325f668f20660a668b | skyzh/mips-simulator | TestUtils.hs | module TestUtils where
import Data.Vector
import Registers
import RegisterFile
rf_vec r = let RegisterFile f = rf r in f
at r = (rf_vec r) ! 1
v0 r = (rf_vec r) ! 2
v1 r = (rf_vec r) ! 3
a0 r = (rf_vec r) ! 4
a1 r = (rf_vec r) ! 5
a2 r = (rf_vec r) ! 6
a3 r = (rf_vec r) ! 7
tN r n | n <... | null | https://raw.githubusercontent.com/skyzh/mips-simulator/61a319ab776fa30831e75aab906c6ef22bb7755e/test/TestUtils.hs | haskell | module TestUtils where
import Data.Vector
import Registers
import RegisterFile
rf_vec r = let RegisterFile f = rf r in f
at r = (rf_vec r) ! 1
v0 r = (rf_vec r) ! 2
v1 r = (rf_vec r) ! 3
a0 r = (rf_vec r) ! 4
a1 r = (rf_vec r) ! 5
a2 r = (rf_vec r) ! 6
a3 r = (rf_vec r) ! 7
tN r n | n <... | |
4ad5b33e6d195231ee3d492849523c9f435045e0e91a603bcabf806906528db8 | fp-works/2019-winter-Haskell-school | TestHelpers.hs | module CIS194.Homework06.TestHelpers (streamTake) where
import CIS194.Homework06.Exercise03 (Stream, streamToList)
streamTake :: Int -> Stream a -> [a]
streamTake n = take n . streamToList
| null | https://raw.githubusercontent.com/fp-works/2019-winter-Haskell-school/823b67f019b9e7bc0d3be36711c0cc7da4eba7d2/cis194/week6/daniel-deng/test/TestHelpers.hs | haskell | module CIS194.Homework06.TestHelpers (streamTake) where
import CIS194.Homework06.Exercise03 (Stream, streamToList)
streamTake :: Int -> Stream a -> [a]
streamTake n = take n . streamToList
| |
173515e7fac6d57b2f9cb83acf4ffb8404603bf6571df3be25a7bd820c2d7cda | realworldocaml/book | subst_config.ml | open Dune_lang.Decoder
(* Can be extended later if needed *)
type t =
| Disabled
| Enabled
let is_enabled = function
| Enabled -> true
| Disabled -> false
let to_string = function
| Disabled -> "disabled"
| Enabled -> "enabled"
let to_dyn conf = to_string conf |> Dyn.string
let encode t = Dune_lang.Enc... | null | https://raw.githubusercontent.com/realworldocaml/book/d822fd065f19dbb6324bf83e0143bc73fd77dbf9/duniverse/dune_/src/dune_engine/subst_config.ml | ocaml | Can be extended later if needed | open Dune_lang.Decoder
type t =
| Disabled
| Enabled
let is_enabled = function
| Enabled -> true
| Disabled -> false
let to_string = function
| Disabled -> "disabled"
| Enabled -> "enabled"
let to_dyn conf = to_string conf |> Dyn.string
let encode t = Dune_lang.Encoder.string (to_string t)
let decoder... |
92dcefa0b3de2d417c702082b31c1e53b012528510b8561ff646380df7bd96ad | gregnwosu/haskellbook | Patience.hs | module Patience where
import Control.Monad
import Data.Monoid
import Test.QuickCheck
monoidAssoc :: (Monoid a, Eq a) => a -> a -> a -> Bool
monoidAssoc a b c = (a <> b) <> c == (a <> (b <> c))
monoidLeftIdentity :: (Eq m, Monoid m ) => m -> Bool
monoidLeftIdentity a = (mempty <> a) == a
monoidRightIdentity :: (Eq ... | null | https://raw.githubusercontent.com/gregnwosu/haskellbook/b21fb6772e58f07cff334d9c551d0477ec856897/chapter15/tests/Patience.hs | haskell | module Patience where
import Control.Monad
import Data.Monoid
import Test.QuickCheck
monoidAssoc :: (Monoid a, Eq a) => a -> a -> a -> Bool
monoidAssoc a b c = (a <> b) <> c == (a <> (b <> c))
monoidLeftIdentity :: (Eq m, Monoid m ) => m -> Bool
monoidLeftIdentity a = (mempty <> a) == a
monoidRightIdentity :: (Eq ... | |
1892b1b3167725ebe99072a796800486cc665aa4cd7ce6acc9aa9d9b35ff43f1 | milankinen/cuic | screenshot_tests.clj | (ns cuic.screenshot-tests
(:require [clojure.test :refer :all]
[clojure.string :as string]
[cuic.core :as c]
[cuic.test :refer [deftest* browser-test-fixture]]
[test-common :refer [todos-url]])
(:import (javax.imageio ImageIO)
(java.io ByteArrayInputStream)... | null | https://raw.githubusercontent.com/milankinen/cuic/94718c0580da2aa127d967207f163c7a546b6fb1/test/cuic/screenshot_tests.clj | clojure | (ns cuic.screenshot-tests
(:require [clojure.test :refer :all]
[clojure.string :as string]
[cuic.core :as c]
[cuic.test :refer [deftest* browser-test-fixture]]
[test-common :refer [todos-url]])
(:import (javax.imageio ImageIO)
(java.io ByteArrayInputStream)... | |
3cf295bd393d738e08a5eecb544578d29cab3054f2a2a81c40c09a2e79dcbf24 | haskell-opengl/OpenGLRaw | ClearTexture.hs | # LANGUAGE PatternSynonyms #
--------------------------------------------------------------------------------
-- |
-- Module : Graphics.GL.ARB.ClearTexture
Copyright : ( c ) 2019
-- License : BSD3
--
Maintainer : < >
-- Stability : stable
-- Portability : portable
--
-------------------... | null | https://raw.githubusercontent.com/haskell-opengl/OpenGLRaw/57e50c9d28dfa62d6a87ae9b561af28f64ce32a0/src/Graphics/GL/ARB/ClearTexture.hs | haskell | ------------------------------------------------------------------------------
|
Module : Graphics.GL.ARB.ClearTexture
License : BSD3
Stability : stable
Portability : portable
------------------------------------------------------------------------------
* Extension Support
* Enums
* Functions | # LANGUAGE PatternSynonyms #
Copyright : ( c ) 2019
Maintainer : < >
module Graphics.GL.ARB.ClearTexture (
glGetARBClearTexture,
gl_ARB_clear_texture,
pattern GL_CLEAR_TEXTURE,
glClearTexImage,
glClearTexSubImage
) where
import Graphics.GL.ExtensionPredicates
import Graphics.GL.Tokens
impo... |
1a8232f55e15d6d5b62e867b0e2231d4f9354527e1dca03bbdee47408c0622c4 | clojure-interop/aws-api | project.clj | (defproject clojure-interop/com.amazonaws.services.simplesystemsmanagement "1.0.0"
:description "Clojure to Java Interop Bindings for com.amazonaws.services.simplesystemsmanagement"
:url "-interop/aws-api"
:license {:name "Eclipse Public License"
:url "-v10.html"}
:dependencies [[org.clojure/clojure... | null | https://raw.githubusercontent.com/clojure-interop/aws-api/59249b43d3bfaff0a79f5f4f8b7bc22518a3bf14/com.amazonaws.services.simplesystemsmanagement/project.clj | clojure | (defproject clojure-interop/com.amazonaws.services.simplesystemsmanagement "1.0.0"
:description "Clojure to Java Interop Bindings for com.amazonaws.services.simplesystemsmanagement"
:url "-interop/aws-api"
:license {:name "Eclipse Public License"
:url "-v10.html"}
:dependencies [[org.clojure/clojure... | |
759f1dce1e457caaa745f20ae43ce484d73e858d947f8524983e4a76b1df2a76 | rabbitmq/rabbitmq-erlang-client | amqp_gen_consumer.erl | This Source Code Form is subject to the terms of the Mozilla Public
License , v. 2.0 . If a copy of the MPL was not distributed with this
file , You can obtain one at /.
%%
Copyright ( c ) 2011 - 2020 VMware , Inc. or its affiliates . All rights reserved .
%%
%% @doc A behaviour module for implementing consu... | null | https://raw.githubusercontent.com/rabbitmq/rabbitmq-erlang-client/2022e01c515d93ed1883e9e9e987be2e58fe15c9/src/amqp_gen_consumer.erl | erlang |
@doc A behaviour module for implementing consumers for
amqp_channel. To specify a consumer implementation for a channel,
use amqp_connection:open_channel/{2,3}.
<br/>
All callbacks are called within the gen_consumer process. <br/>
<br/>
See comments in amqp_gen_consumer.erl source file for documentation
on th... | This Source Code Form is subject to the terms of the Mozilla Public
License , v. 2.0 . If a copy of the MPL was not distributed with this
file , You can obtain one at /.
Copyright ( c ) 2011 - 2020 VMware , Inc. or its affiliates . All rights reserved .
-module(amqp_gen_consumer).
-include("amqp_client.hrl"... |
42a853d4dc4709ed7cd881c29f41c478e7c705b4223c59a265340f553310c35a | spurious/snd-mirror | libutf8proc.scm | ;;; utf8proc.scm
;;;
;;; tie the utf8proc library into the *libutf8proc* environment
(require cload.scm)
(provide 'libutf8proc.scm)
;; if loading from a different directory, pass that info to C
(let ((directory (let ((current-file (port-filename)))
(and (memv (current-file 0) '(#\/ #\~))
(substring current-fi... | null | https://raw.githubusercontent.com/spurious/snd-mirror/4ab7cb7609c46135e42d732ba2ac4c34c58ca049/libutf8proc.scm | scheme | utf8proc.scm
tie the utf8proc library into the *libutf8proc* environment
if loading from a different directory, pass that info to C
these return newly allocated memory -- should probably free it here
|
(require cload.scm)
(provide 'libutf8proc.scm)
(let ((directory (let ((current-file (port-filename)))
(and (memv (current-file 0) '(#\/ #\~))
(substring current-file 0 (- (length current-file) 9))))))
(when (and directory (not (member directory *load-path*)))
(set! *load-path* (cons directory *load-path... |
58b51335d6959aa44b8dc8fc9487a62ebdb3521982fc9120ae7bea2b687ec3d4 | jayunit100/RudolF | project.clj | (defproject BioClojure "0.0.2-SNAPSHOT"
:description "An application for visualizing NMR data on structures and plots"
:dependencies [[org.clojure/clojure "1.2.1"]
[org.clojure/clojure-contrib "1.2.0"]
[commons-lang "2.3"]
[ring/ring-jetty-adapter "0.3.9"]
... | null | https://raw.githubusercontent.com/jayunit100/RudolF/8936bafbb30c65c78b820062dec550ceeea4b3a4/bioclojure/project.clj | clojure | (defproject BioClojure "0.0.2-SNAPSHOT"
:description "An application for visualizing NMR data on structures and plots"
:dependencies [[org.clojure/clojure "1.2.1"]
[org.clojure/clojure-contrib "1.2.0"]
[commons-lang "2.3"]
[ring/ring-jetty-adapter "0.3.9"]
... | |
93cc76a933cd9df86af0e9fa69b045035bc97ff31037f6363fc774051ea5c7ec | dizengrong/erlang_game | mod_minheap.erl | %%%-------------------------------------------------------------------
@author < >
( C ) 2011 ,
%%% @doc
%%%
%%% @end
Created : 15 Jul 2011 by < >
%%%-------------------------------------------------------------------
-module(mod_minheap).
-export([
new_heap/3,
delete_heap/1,
is_f... | null | https://raw.githubusercontent.com/dizengrong/erlang_game/4598f97daa9ca5eecff292ac401dd8f903eea867/gerl_robot/src/from_server/mod_minheap.erl | erlang | -------------------------------------------------------------------
@doc
@end
-------------------------------------------------------------------
@doc 删除最小堆
删除堆中的某一元素然后维护堆
判断堆是否为空
================LOCAL FUCTION=======================
新的值比父节点小的时候往上跟新
新的值比父亲节点大的时候往下跟新 | @author < >
( C ) 2011 ,
Created : 15 Jul 2011 by < >
-module(mod_minheap).
-export([
new_heap/3,
delete_heap/1,
is_full/1,
is_empty/1,
key_find/2,
get_top_element/1
]).
-export([
insert/3,
update/3,
pop/1,
de... |
d4c2b3daa38413c3aeee80a24eb8082a4f4ade0800176ebf45df7375908ce638 | ds-wizard/engine-backend | Detail_Bundle_GET.hs | module Registry.Api.Handler.DocumentTemplate.Detail_Bundle_GET where
import Control.Monad.Reader (asks)
import qualified Data.UUID as U
import Servant
import Registry.Api.Handler.Common
import Registry.Model.Context.AppContext
import Registry.Model.Context.BaseContext
import Registry.Service.DocumentTemplate.Bundle.D... | null | https://raw.githubusercontent.com/ds-wizard/engine-backend/d392b751192a646064305d3534c57becaa229f28/engine-registry/src/Registry/Api/Handler/DocumentTemplate/Detail_Bundle_GET.hs | haskell | module Registry.Api.Handler.DocumentTemplate.Detail_Bundle_GET where
import Control.Monad.Reader (asks)
import qualified Data.UUID as U
import Servant
import Registry.Api.Handler.Common
import Registry.Model.Context.AppContext
import Registry.Model.Context.BaseContext
import Registry.Service.DocumentTemplate.Bundle.D... | |
8f7d44b906859fb896ffd084221506eb2181083ccd4708b5603a608d60509c9f | kappelmann/engaging-large-scale-functional-programming | Logger.hs | module Competition.Tournament.Logger
( logTournamentStart,
logTournamentResults,
logGameStart,
logGameEnd,
)
where
import Competition.Logger (logStderr, logStdout)
import Competition.Types (Encounter(..), Game (..), Submission (..))
import Data.List (intercalate)
logTournamentStart :: [Encounter] -> [... | null | https://raw.githubusercontent.com/kappelmann/engaging-large-scale-functional-programming/80e8a732c38691ff4e602e0cf77ff2eefb486284/resources/game_tournament_framework/backend/tournament-runner/src/Competition/Tournament/Logger.hs | haskell | module Competition.Tournament.Logger
( logTournamentStart,
logTournamentResults,
logGameStart,
logGameEnd,
)
where
import Competition.Logger (logStderr, logStdout)
import Competition.Types (Encounter(..), Game (..), Submission (..))
import Data.List (intercalate)
logTournamentStart :: [Encounter] -> [... | |
31d8e246e715682e5f488a658d377d68141898638d17c224e0ef8f74e0bae7e5 | clojurecup2014/parade-route | run_tests_i.clj | (assembly-load-from "clojure.tools.namespace.dll")
(assembly-load-from "clojure.data.generators.dll")
(assembly-load-from "clojure.test.generative.dll")
( System / setProperty " clojure.test.generative.msec " " 60000 " )
(require '[clojure.test.generative.runner :as runner])
(runner/-main-no-exit "clojure/test_clojure"... | null | https://raw.githubusercontent.com/clojurecup2014/parade-route/adb2e1ea202228e3da07902849dee08f0bb8d81c/Assets/Clojure/Internal/Plugins/clojure/run_tests_i.clj | clojure | clojure.test-clojure.reflect -- TODO: need to rewrite reflect tests | (assembly-load-from "clojure.tools.namespace.dll")
(assembly-load-from "clojure.data.generators.dll")
(assembly-load-from "clojure.test.generative.dll")
( System / setProperty " clojure.test.generative.msec " " 60000 " )
(require '[clojure.test.generative.runner :as runner])
(runner/-main-no-exit "clojure/test_clojure"... |
d76935980435914d87a8d55680c236d577245e09f8db619a92812f4a9d2c0fab | trevorbernard/phaser | manual.clj | Copyright 2013 - 2014 UserEvents Inc.
;;
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/trevorbernard/phaser/7b97c0df9d65d669a85b439d50e29a85b753f481/src/phaser/manual.clj | clojure |
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
-2.0
Unless required by applicable law or agreed to in writing, software
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing per... | Copyright 2013 - 2014 UserEvents Inc.
distributed under the License is distributed on an " AS IS " BASIS ,
(ns phaser.manual
(:import
[java.util.concurrent TimeUnit Executor]
[com.lmax.disruptor RingBuffer WorkHandler DataProvider EventFactory EventHandler
Sequence SequenceBarrier WaitStrategy BatchEve... |
18f7c38e0190455b01f7a4a5f9abcccde32442fad0ac332b0846c86a8660481d | deps-app/versions | redis.clj | (ns jarkeeper.redis
(:require [com.stuartsierra.component :as component]
[taoensso.carmine :as car :refer [wcar]]))
(defmacro wcar* [redis & body] `(car/wcar (:redis ~redis) ~@body))
(defrecord Redis [uri]
component/Lifecycle
(start [component]
(if (:redis component)
component
(assoc... | null | https://raw.githubusercontent.com/deps-app/versions/5e58ac456cb3ec90c5d87dbfdde8f9414f8b1f3b/src/jarkeeper/redis.clj | clojure | (ns jarkeeper.redis
(:require [com.stuartsierra.component :as component]
[taoensso.carmine :as car :refer [wcar]]))
(defmacro wcar* [redis & body] `(car/wcar (:redis ~redis) ~@body))
(defrecord Redis [uri]
component/Lifecycle
(start [component]
(if (:redis component)
component
(assoc... | |
fc765ba14b3e3bb8cd677f0a18289e9b1d43a74cde943451ebfb80ef8696dcd0 | facebook/flow | workerCancel.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/52e59c7a9dea8556e7caf0be2b2c5c2e310b5b65/src/heap/workerCancel.ml | ocaml | Check if the workers are stopped and exit if they are |
* 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... |
3622f42e88f23357dae678af1b942c3e379d4dc80ab347e4fc51874054c7b5ed | atzeus/FRPNow | PrimEv.hs | module Control.FRPNow.Private.PrimEv(Round, Clock, PrimEv, newClock , callbackp, spawn, spawnOS, curRound, newRound ,observeAt ) where
import Control.Applicative
import System.IO.Unsafe
import Data.IORef
import Data.Unique
import Control.Concurrent
import Debug.Trace
data Clock = Clock {
identClock :: U... | null | https://raw.githubusercontent.com/atzeus/FRPNow/58073b88dfd725eab6851a75b4c9f01f9d3f97d2/Control/FRPNow/Private/PrimEv.hs | haskell | when given a IO action that schedules a round, create a new clock | module Control.FRPNow.Private.PrimEv(Round, Clock, PrimEv, newClock , callbackp, spawn, spawnOS, curRound, newRound ,observeAt ) where
import Control.Applicative
import System.IO.Unsafe
import Data.IORef
import Data.Unique
import Control.Concurrent
import Debug.Trace
data Clock = Clock {
identClock :: U... |
ff59e8e4edbbcbbae34071089965dba2a338bd060892592249be4ad66a52c8b0 | mishadoff/project-euler | problem005.clj | (ns project-euler.problem005
(:use [clojure.contrib.math :only (lcm)]))
Elapsed time : 0.210153 msecs
(defn euler-005 []
(reduce lcm (range 1 21))) | null | https://raw.githubusercontent.com/mishadoff/project-euler/45642adf29626d3752227c5a342886b33c70b337/src/project_euler/problem005.clj | clojure | (ns project-euler.problem005
(:use [clojure.contrib.math :only (lcm)]))
Elapsed time : 0.210153 msecs
(defn euler-005 []
(reduce lcm (range 1 21))) | |
b8818d22362799e6be3e3ea7d03f689c5a05e5497d9e71dd1db365d97502728d | 7theta/re-frame-via | views.cljs | ;; Copyright (c) 7theta. All rights reserved.
;; The use and distribution terms for this software are covered by the
;; Eclipse Public License 1.0 (-v10.html)
;; which can be found in the LICENSE file at the root of this
;; distribution.
;;
;; By using this software in any fashion, you are agreeing to be bo... | null | https://raw.githubusercontent.com/7theta/re-frame-via/ae530337eff4098991e937d6e06aa413d8ad7b45/example/src/cljs/example/views.cljs | clojure | Copyright (c) 7theta. All rights reserved.
The use and distribution terms for this software are covered by the
Eclipse Public License 1.0 (-v10.html)
which can be found in the LICENSE file at the root of this
distribution.
By using this software in any fashion, you are agreeing to be bound by
the ... |
(ns example.views
(:require [re-frame.core :refer [subscribe dispatch]]))
(defn main-panel []
[:div {:style {:margin "40px"}}
(if @(subscribe [:authenticated?])
[:button {:on-click #(dispatch [:logout])} "Logout"]
[:button {:on-click #(dispatch [:login])} "Login"])])
|
9de2fa20c0e3d3f226985aa4f830231f40fb7e40877a149909622dd182e4d6a0 | argp/bap | disasm_i386.ml | * Native lifter of x86 instructions to the BAP IL
open Int64
open Ast
open BatPervasives
open Big_int_Z
open Big_int_convenience
open Type
open BatListFull
Purposefully placed below BatPervasives
open Ast_convenience
module VH=Var.VarHash
module D = Debug.Make(struct let name = "Disasm_i386" and default=`NoDebug ... | null | https://raw.githubusercontent.com/argp/bap/2f60a35e822200a1ec50eea3a947a322b45da363/ocaml/disasm_i386.ml | ocaml | next ins address, offset
* Information about the type of pcmp instruction.
dst, src, condition
dest type, dest, (src copy length, src type, src, src src offset, src dest offset)*
addr is RA
left or right, type, src/dest op, shift op, use carry flag
size, src, dest
dest size, element size, low/high element... | * Native lifter of x86 instructions to the BAP IL
open Int64
open Ast
open BatPervasives
open Big_int_Z
open Big_int_convenience
open Type
open BatListFull
Purposefully placed below BatPervasives
open Ast_convenience
module VH=Var.VarHash
module D = Debug.Make(struct let name = "Disasm_i386" and default=`NoDebug ... |
f3f3f9cfbe7120e6af8f975f5f4124feb601bd896c02f8c729f5b52eb5a275af | ibotty/iban | IBAN.hs | module Finance.IBAN
( IBAN (),
IBANError (..),
iban,
prettyIBAN,
parseIBAN,
parseBBANByCountry,
)
where
import Finance.IBAN.Data
import Finance.IBAN.Internal
| null | https://raw.githubusercontent.com/ibotty/iban/6f37fd52b2b5e1eb9880b1c8def0c4c777cd1be5/src/Finance/IBAN.hs | haskell | module Finance.IBAN
( IBAN (),
IBANError (..),
iban,
prettyIBAN,
parseIBAN,
parseBBANByCountry,
)
where
import Finance.IBAN.Data
import Finance.IBAN.Internal
| |
d3874a7566cb24245c8e56284c881c08c9902e6597b78d825c31ba6cd644debf | ChildsplayOSU/bogl | Main.hs | module Main where
import System.Environment
import API.Run
import API.JSONData
import Runtime.Values
import Data.Array
-- | Entry point to run the command line interface (interpreter/repl)
main :: IO ()
main = do
putStrLn "=============================="
putStrLn "BoGL (The Board Game Language)"
putStrLn "Creat... | null | https://raw.githubusercontent.com/ChildsplayOSU/bogl/8c649689bf26543be1a7ec72787b9c013ecb754f/app/Main.hs | haskell | | Entry point to run the command line interface (interpreter/repl)
attempt to load up this bogl file
no args, run standalone repl only
| Load a BoGL file for the repl
evaluate this file
valid case, run REPL
types followed by value means we're good to go
run the full repl
| Run the repl by itself (no file loade... | module Main where
import System.Environment
import API.Run
import API.JSONData
import Runtime.Values
import Data.Array
main :: IO ()
main = do
putStrLn "=============================="
putStrLn "BoGL (The Board Game Language)"
putStrLn "Created at the School of EECS"
putStrLn "Oregon State University"
putSt... |
4bd74bdad8342fe4924bb4f65fbb30a95c2c5ad99760ca027fe569d168c24e10 | samoht/camloo | camloo.scm | * Copyright ( C ) 1994 - 2010 INRIA
;*
;* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation ; version 2 of the License .
;*
;* This program is distributed in the hope that it will be useful,
;* but W... | null | https://raw.githubusercontent.com/samoht/camloo/29a578a152fa23a3125a2a5b23e325b6d45d3abd/src/camloo/Llib/camloo.scm | scheme | *
* This program is free software; you can redistribute it and/or modify
version 2 of the License .
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public L... | * Copyright ( C ) 1994 - 2010 INRIA
* it under the terms of the GNU General Public License as published by
(module camloo
(main main)
(library camloo-runtime)
(import init
lib_module_list
module
generate
Llambda
optimize-ref
Ldefine
__caml_main))
(define *output* (current-output... |
d02fde71fb52c7be032914bbdc5c4eb98a252da04fa27f9fb948cd08d68ca104 | mhkoji/Senn | hachee.lisp | ;; convert/list-candidates depending on hachee kkc impl lm
(defpackage :senn.im.kkc.hachee
(:use :cl)
(:export :kkc
:build-hachee-impl-lm-kkc))
(in-package :senn.im.kkc.hachee)
(defun build-hachee-impl-lm-kkc ()
(let ((corpus-pathnames
(hachee.data.corpus:word-pron-utf8-pathnames)))
(log:... | null | https://raw.githubusercontent.com/mhkoji/Senn/7bb1305bb0d3128bcd278b85c9c745f817872a6a/senn/src/im/kkc/hachee.lisp | lisp | convert/list-candidates depending on hachee kkc impl lm
| (defpackage :senn.im.kkc.hachee
(:use :cl)
(:export :kkc
:build-hachee-impl-lm-kkc))
(in-package :senn.im.kkc.hachee)
(defun build-hachee-impl-lm-kkc ()
(let ((corpus-pathnames
(hachee.data.corpus:word-pron-utf8-pathnames)))
(log:debug "Loading: ~A" corpus-pathnames)
(hachee.kkc.impl.... |
a39cfb36456a800c5af9ea76d2706f929f7114d12ac865ebc808f17ac6775b0c | zen-lang/zen-lsp | build.clj | (ns build
(:require [clojure.tools.build.api :as b]))
(def lib 'my/lib1)
( def version ( format " 1.2.%s " ( b / git - count - revs nil ) ) )
(def class-dir "target/classes")
(def basis (b/create-basis {:project "deps.edn"}))
( def uber - file ( format " target/%s-%s - standalone.jar " ( name lib ) version ) )
;... | null | https://raw.githubusercontent.com/zen-lang/zen-lsp/1e2df99875cf00aa17609465c0627d2c617773ca/server/build.clj | clojure | (def jar-file (format "target/%s-%s.jar" (name lib) version)) | (ns build
(:require [clojure.tools.build.api :as b]))
(def lib 'my/lib1)
( def version ( format " 1.2.%s " ( b / git - count - revs nil ) ) )
(def class-dir "target/classes")
(def basis (b/create-basis {:project "deps.edn"}))
( def uber - file ( format " target/%s-%s - standalone.jar " ( name lib ) version ) )
... |
7c825fece35119eb5a98900a25c28ed814919a1d9f67ed70476f20eb04151922 | oden-lang/oden | Backend.hs | module Oden.Backend where
import Oden.Core.Monomorphed
data CodegenError = UnexpectedError String
deriving (Show, Eq, Ord)
data CompiledFile = CompiledFile FilePath String
deriving (Show, Eq, Ord)
class Backend b where
codegen :: b -> MonomorphedPackage -> Either CodegenError [... | null | https://raw.githubusercontent.com/oden-lang/oden/10c99b59c8b77c4db51ade9a4d8f9573db7f4d14/src/Oden/Backend.hs | haskell | module Oden.Backend where
import Oden.Core.Monomorphed
data CodegenError = UnexpectedError String
deriving (Show, Eq, Ord)
data CompiledFile = CompiledFile FilePath String
deriving (Show, Eq, Ord)
class Backend b where
codegen :: b -> MonomorphedPackage -> Either CodegenError [... | |
cba29e349f68f63babdc1989b699dae67868f954240acf7059e368f27917b1d8 | vehicle-lang/vehicle | Variable.hs | module Vehicle.Compile.Queries.Variable where
import Data.Sequence (Seq)
import Data.Sequence qualified as Seq
import Data.Text (Text)
import Data.Text qualified as Text (pack)
import Prettyprinter (brackets)
import Vehicle.Compile.Prelude
------------------------------------------------------------------------------... | null | https://raw.githubusercontent.com/vehicle-lang/vehicle/fd82119b2baae5f31cea159866378c6a1ba42bfc/vehicle/src/Vehicle/Compile/Queries/Variable.hs | haskell | ------------------------------------------------------------------------------
Variable class
------------------------------------------------------------------------------
User variables
| Variables entered by the user
------------------------------------------------------------------------------
Network variables... | module Vehicle.Compile.Queries.Variable where
import Data.Sequence (Seq)
import Data.Sequence qualified as Seq
import Data.Text (Text)
import Data.Text qualified as Text (pack)
import Prettyprinter (brackets)
import Vehicle.Compile.Prelude
class Pretty variable => IsVariable variable
newtype UserVariable = UserVar... |
a6a3647ca9289bbba11fdbba13a13b5c84e5d5302d7c14cf1cc6701f307ea11d | chenyukang/eopl | 10.scm | (load-relative "../libs/init.scm")
(load-relative "./base/classes/test.scm")
(load-relative "./base/classes/store.scm")
(load-relative "./base/classes/data-structures.scm")
(load-relative "./base/classes/environments.scm")
(load-relative "./base/classes/lang.scm")
(load-relative "./base/classes/interp.scm")
(load-relat... | null | https://raw.githubusercontent.com/chenyukang/eopl/0406ff23b993bfe020294fa70d2597b1ce4f9b78/ch9/10.scm | scheme | grammatical specification ;;;;;;;;;;;;;;;;
new productions for oop
method formals
this is special-cased to prevent it from mutation
sllgen boilerplate ;;;;;;;;;;;;;;;;
new cases for CLASSES language
new stuff
%will call c1 func | (load-relative "../libs/init.scm")
(load-relative "./base/classes/test.scm")
(load-relative "./base/classes/store.scm")
(load-relative "./base/classes/data-structures.scm")
(load-relative "./base/classes/environments.scm")
(load-relative "./base/classes/lang.scm")
(load-relative "./base/classes/interp.scm")
(load-relat... |
4c95b4622de31a08c30f95a4b292e844a6cc89595060e49bd99ee8da93ddae58 | gregr/ina | minimal.scm | ;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; Parsing expressions ;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;
(define (parse-quote env e) (ast:quote (syntax-provenance e) (syntax->datum e)))
(define (parse-quote-syntax env e) (ast:quote (syntax-provenance e) e))
(define (parse-if env e.c e.t e.f) ($if (pars... | null | https://raw.githubusercontent.com/gregr/ina/49422737654dcb6e2dabdb1c3d732d13385166a2/nscheme/include/minimal.scm | scheme |
Parsing expressions ;;;
Parsing definitions ;;;
Pre-base language syntax environment ;;;
|
(define (parse-quote env e) (ast:quote (syntax-provenance e) (syntax->datum e)))
(define (parse-quote-syntax env e) (ast:quote (syntax-provenance e) e))
(define (parse-if env e.c e.t e.f) ($if (parse-expression env e.c)
(parse-expre... |
65ca770c883b6b042aee9109b96c46c4df4bd1ef467a6724859c3f11b3f24df6 | fluree/ledger | signatures_test.clj | (ns fluree.db.ledger.docs.identity.signatures-test
(:require [clojure.test :refer :all]
[fluree.db.test-helpers :as test]
[fluree.db.ledger.docs.getting-started.basic-schema :as basic]
[fluree.db.api :as fdb]
[org.httpkit.client :as http]
[clojure.core.async... | null | https://raw.githubusercontent.com/fluree/ledger/31f3e11a0648501b0a8cc6148177e54c67420042/test/fluree/db/ledger/docs/identity/signatures_test.clj | clojure | Use fdb-api-open = false, everything that goes through the endpoints needs to be signed | (ns fluree.db.ledger.docs.identity.signatures-test
(:require [clojure.test :refer :all]
[fluree.db.test-helpers :as test]
[fluree.db.ledger.docs.getting-started.basic-schema :as basic]
[fluree.db.api :as fdb]
[org.httpkit.client :as http]
[clojure.core.async... |
affd42bc0a2b3703bac09c37c6fd47da144349120d310d001355a05f2db6c3d9 | erlangonrails/devdb | erlydtl_runtime.erl | -module(erlydtl_runtime).
-compile(export_all).
find_value(Key, L) when is_list(L) ->
% io:format("Lookup ~p in ~p~n", [Key, L]),
case lists:keyfind(Key, 1, L) of
false ->
case lists:keyfind(atom_to_list(Key), 1, L) of
false -> lists:keyfind(list_to_binary(atom_to_list(Key)... | null | https://raw.githubusercontent.com/erlangonrails/devdb/0e7eaa6bd810ec3892bfc3d933439560620d0941/dev/erlydtl/src/erlydtl/erlydtl_runtime.erl | erlang | io:format("Lookup ~p in ~p~n", [Key, L]),
throw({undefined_variable, Key}); | -module(erlydtl_runtime).
-compile(export_all).
find_value(Key, L) when is_list(L) ->
case lists:keyfind(Key, 1, L) of
false ->
case lists:keyfind(atom_to_list(Key), 1, L) of
false -> lists:keyfind(list_to_binary(atom_to_list(Key)), 1, L);
Val -> Val
... |
ad1a88149b664271f4c4fe63b9938b68e754aabd1cf533c03e5595d5ab89484e | ragkousism/Guix-on-Hurd | asdf.scm | ;;; GNU Guix --- Functional package management for GNU
Copyright © 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 version 3 of the Lice... | null | https://raw.githubusercontent.com/ragkousism/Guix-on-Hurd/e951bb2c0c4961dc6ac2bda8f331b9c4cee0da95/guix/build-system/asdf.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 © 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 (guix build-system asdf)
#:use-module (guix store)
#:use-module (guix utils)
#:use-module (gu... |
151f9c77dcf9bde87abace1803ba2279f7aa20c55627cbe135261905ab91ff9d | symbiont-io/detsys-testkit | Http.hs | {-# LANGUAGE OverloadedStrings #-}
# LANGUAGE DeriveGeneric #
# LANGUAGE StandaloneDeriving #
module StuntDouble.Transport.Http where
import qualified Data.HashMap.Strict as HashMap
import Data.Text (Text)
import Data.Heap (Heap)
import GHC.Generics (Generic)
import Data.Aeson
import Data.String
import Data.Aeson.Int... | null | https://raw.githubusercontent.com/symbiont-io/detsys-testkit/29a3a0140730420e4c5cc8db23df6fdb03f9302c/src/runtime-prototype/src/StuntDouble/Transport/Http.hs | haskell | # LANGUAGE OverloadedStrings #
----------------------------------------------------------------------
XXX: when/how does this grow?
XXX: Instead of sending right away here, we could batch instead and only
to asynchronously take care of possible errors though). | # LANGUAGE DeriveGeneric #
# LANGUAGE StandaloneDeriving #
module StuntDouble.Transport.Http where
import qualified Data.HashMap.Strict as HashMap
import Data.Text (Text)
import Data.Heap (Heap)
import GHC.Generics (Generic)
import Data.Aeson
import Data.String
import Data.Aeson.Internal
import Control.Concurrent.Asy... |
7ece98406ceca92b33b4d22fcf394b649c11745ea606245798b027401083c1d2 | brianhempel/maniposynth | snoc.ml | let rec snoc list elem =
match list with
| hd :: tail ->
let rest_snoced = snoc tail elem [@@pos 58, 23] in
hd :: rest_snoced
| [] -> [ elem ]
[@@pos 844, 305]
let () = assert (snoc [ 0; 0 ] 1 = [ 0; 0; 1 ]) [@@pos 1294, 315]
| null | https://raw.githubusercontent.com/brianhempel/maniposynth/8cb8e0c84db2ffb51feae2fccb10dbff40c4e0e0/expert_eval_manual/snoc.ml | ocaml | let rec snoc list elem =
match list with
| hd :: tail ->
let rest_snoced = snoc tail elem [@@pos 58, 23] in
hd :: rest_snoced
| [] -> [ elem ]
[@@pos 844, 305]
let () = assert (snoc [ 0; 0 ] 1 = [ 0; 0; 1 ]) [@@pos 1294, 315]
| |
a3ce68e8ade0a2a41b00436baf126b613b194674f01ca505207fc9ddda7dc4d2 | den1k/vimsical | transit.clj | (ns vimsical.common.util.transit
(:require
[clojure.core.async :as a]
[cognitect.transit :as transit]
[clojure.core.async.impl.protocols :as ap])
(:import
(clojure.lang PersistentTreeMap)
(com.cognitect.transit ReadHandler WriteHandler)
(java.io ByteArrayOutputStream)
(java.nio.channels Readabl... | null | https://raw.githubusercontent.com/den1k/vimsical/1e4a1f1297849b1121baf24bdb7a0c6ba3558954/src/common/vimsical/common/util/transit.clj | clojure |
* HTTP
** Content Types
** Requests
** Responses
* Reader
* Writer
The piped os is passed to the transit writer, it will pass the written
data without copying it to the piped is
The rule of thumb here is to avoid i/o in the go-loop, if all goes
according to plan we'll get full backpressure start... | (ns vimsical.common.util.transit
(:require
[clojure.core.async :as a]
[cognitect.transit :as transit]
[clojure.core.async.impl.protocols :as ap])
(:import
(clojure.lang PersistentTreeMap)
(com.cognitect.transit ReadHandler WriteHandler)
(java.io ByteArrayOutputStream)
(java.nio.channels Readabl... |
7b836383c543020d2d370ced8f3d4333d03bf9102bccf46a9c556ab550b01dcd | JacquesCarette/Drasil | Format.hs | -- | Possible formats for printer output.
module Language.Drasil.Format where
| Document types include Software Requirements Specification and Website .
Choosing SRS will generate both TeX and HTML files , while Website generates only as HTML .
-- This also determines what folders the generated files will be place... | null | https://raw.githubusercontent.com/JacquesCarette/Drasil/98c6e2e81bc1479010ce71b22960ab214a891159/code/drasil-printers/lib/Language/Drasil/Format.hs | haskell | | Possible formats for printer output.
This also determines what folders the generated files will be placed into.
| Possible formats for printer output.
| Shows the different types of documents. | module Language.Drasil.Format where
| Document types include Software Requirements Specification and Website .
Choosing SRS will generate both TeX and HTML files , while Website generates only as HTML .
data DocType = SRS | Website | Jupyter
data Format = TeX | Plain | HTML | JSON
instance Show DocType where
s... |
42da71797d5911263d33a23599f3a71f88340a4ae30da93113ba26fffa6359ad | gadfly361/re-pressed | subs.cljs | (ns re-pressed.subs
(:require [re-frame.core :as rf]))
(rf/reg-sub
::name
(fn [db]
(:name db)))
(rf/reg-sub
::active-panel
(fn [db _]
(:active-panel db)))
(rf/reg-sub
::keydown-keys
(fn [db _]
(get-in db [:re-pressed.core/keydown :keys])))
(rf/reg-sub
::cards
(fn [db]
(get db :cards)))
(rf/... | null | https://raw.githubusercontent.com/gadfly361/re-pressed/a719171f8ff03b2c1d18aa6697323b7c83e952b9/src/demo/re_pressed/subs.cljs | clojure | (ns re-pressed.subs
(:require [re-frame.core :as rf]))
(rf/reg-sub
::name
(fn [db]
(:name db)))
(rf/reg-sub
::active-panel
(fn [db _]
(:active-panel db)))
(rf/reg-sub
::keydown-keys
(fn [db _]
(get-in db [:re-pressed.core/keydown :keys])))
(rf/reg-sub
::cards
(fn [db]
(get db :cards)))
(rf/... | |
76bb9828329d8bdf6b77a142ecf35defa82f5c963fa092cb558747a2a7445848 | pveber/bistro | html_logger.mli | open Bistro_engine
val create : string -> Logger.t
| null | https://raw.githubusercontent.com/pveber/bistro/da0ebc969c8c5ca091905366875cbf8366622280/lib/utils/html_logger.mli | ocaml | open Bistro_engine
val create : string -> Logger.t
| |
6f5c70da335b83b86bfd08e3b624eb8da765018cbf2c88da7947ecdbf8d859fe | sonowz/advent-of-code-haskell | Day04.hs | module Y2019.Day04 where
import Relude
import Relude.Extra.Bifunctor
import Relude.Extra.CallStack
import Relude.Extra.Foldable1
import Relude.Extra.Map
import Relude.Extra.Newtype
import Relude.Extra.Tuple
import Lib.IO
import Lib.Types
-----------------------
-- Type declarations --
-----------------------
newtype... | null | https://raw.githubusercontent.com/sonowz/advent-of-code-haskell/6cec825c5172bbec687aab510e43832e6f2c0372/src/Y2019/Day04.hs | haskell | ---------------------
Type declarations --
---------------------
----------
Part 1 --
----------
----------
----------
------------------
------------------ | module Y2019.Day04 where
import Relude
import Relude.Extra.Bifunctor
import Relude.Extra.CallStack
import Relude.Extra.Foldable1
import Relude.Extra.Map
import Relude.Extra.Newtype
import Relude.Extra.Tuple
import Lib.IO
import Lib.Types
newtype PasswordRange = PwRange (Int, Int) deriving (Show)
newtype Password = P... |
d7215d8ef06e84b6fa67dd7cdebd35f5dc4d92aa571177ead5e41ec259e31eae | pjotrp/guix | pypi.scm | ;;; GNU Guix --- Functional package management for GNU
Copyright © 2014 < >
Copyright © 2015 < >
Copyright © 2015 < >
;;;
;;; This file is part of GNU Guix.
;;;
GNU is free software ; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by
the Fre... | null | https://raw.githubusercontent.com/pjotrp/guix/96250294012c2f1520b67f12ea80bfd6b98075a2/guix/import/pypi.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 © 2014 < >
Copyright © 2015 < >
Copyright © 2015 < >
under the terms of the GNU General Public License as published by
You should have received a copy of the GNU General Public License
along with GNU . If not , see < / > .
(define-module (guix import pypi)
#:use-module (ice-9 binary... |
3981b7998bdc513307926dc216875ede18e2b3ccf9923620c5c72b5b739eec9e | mattmundell/nightshade | envanal.lisp | ;;; The environment analysis phase for the compiler. This phase annotates
;;; IR1 with a hierarchy of environment structures, determining the
;;; environment that each Lambda allocates its variables and finding what
;;; values are closed over by each environment.
(in-package "C")
#[ Environment Analysis
Determi... | null | https://raw.githubusercontent.com/mattmundell/nightshade/d8abd7bd3424b95b70bed599e0cfe033e15299e0/src/compiler/envanal.lisp | lisp | The environment analysis phase for the compiler. This phase annotates
IR1 with a hierarchy of environment structures, determining the
environment that each Lambda allocates its variables and finding what
values are closed over by each environment.
FIX what's an upward funarg?
Do environment analysis on the code... |
(in-package "C")
#[ Environment Analysis
Determine which distinct environments need to be allocated, and what
context needed to be closed over by each environment. Detect non-local
exits and set closure variables. Also emit cleanup code as funny
function calls. This is the last pure ICR pass.
Pha... |
09e9ccfb11c2c913db2f55c8793a10081620f4807041d4215a7aff0c662e5589 | cuter-testing/cuter | cuter_monitor_tests.erl | -*- erlang - indent - level : 2 -*-
%%------------------------------------------------------------------------------
-module(cuter_monitor_tests).
-include_lib("eunit/include/eunit.hrl").
-include("include/eunit_config.hrl").
This should be provided by EUnit
-define(ISERVER, cuter_iserver).
-type descr() :: non... | null | https://raw.githubusercontent.com/cuter-testing/cuter/62a300d5cadf62ca9af5bc62ff0a0cb2d717dfcd/test/utest/src/cuter_monitor_tests.erl | erlang | ------------------------------------------------------------------------------ | -*- erlang - indent - level : 2 -*-
-module(cuter_monitor_tests).
-include_lib("eunit/include/eunit.hrl").
-include("include/eunit_config.hrl").
This should be provided by EUnit
-define(ISERVER, cuter_iserver).
-type descr() :: nonempty_string().
Ensure start / stop runs properly -- 19 below is the line numb... |
3b426a30b2a94dad9a603fc0b4d3efaeeadfc566dc3aee439dde6ca615bcc45d | apache/couchdb-rebar | rebar_require_vsn_tests.erl | -*- erlang - indent - level : 4;indent - tabs - mode : nil -*-
%% ex: ts=4 sw=4 et
-module(rebar_require_vsn_tests).
-include_lib("eunit/include/eunit.hrl").
version_tuple_test_() ->
[%% typical cases
?_assert(check("R14A", "eunit") =:= {14, 0, 0}),
?_assert(check("R14B", "eunit") =:= {14, 0, 0}),
... | null | https://raw.githubusercontent.com/apache/couchdb-rebar/8578221c20d0caa3deb724e5622a924045ffa8bf/test/rebar_require_vsn_tests.erl | erlang | ex: ts=4 sw=4 et
typical cases
error cases | -*- erlang - indent - level : 4;indent - tabs - mode : nil -*-
-module(rebar_require_vsn_tests).
-include_lib("eunit/include/eunit.hrl").
version_tuple_test_() ->
?_assert(check("R14A", "eunit") =:= {14, 0, 0}),
?_assert(check("R14B", "eunit") =:= {14, 0, 0}),
?_assert(check("R14B01", "eunit") =:= {1... |
0d0fe8db484bb5b5295b5a1035d5dcfc7460d02ce7dd4d4a281ceab5f770a926 | erlang/otp | ct_surefire_SUITE.erl | %%
%% %CopyrightBegin%
%%
Copyright Ericsson AB 2012 - 2022 . All Rights Reserved .
%%
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
%% you may not use this file except in compliance with the License.
%% You may obtain a copy of the License at
%%
%% -2.0
%%
%% Unless required by applicab... | null | https://raw.githubusercontent.com/erlang/otp/eccc556e79f315d1f87c10fb46f2c4af50a63f20/lib/common_test/test/ct_surefire_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 2012 - 2022 . 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(ct_surefire_SUITE).
-compile(export_all).
-include_lib("common_test/include/ct.hrl").
-include_lib("common... |
3b9bf51b7add3aef9220f0841a9147ff3d8a18d42cf83e5311d6ffb99e3246be | uwplse/PUMPKIN-PATCH | proofdiff.ml | (* Difference between old and new proofs *)
open Constr
open Environ
open Evd
open Proofcat
open Assumptions
open Expansion
open Evaluation
open Proofcatterms
open Reducers
open Declarations
open Utilities
open Merging
open Indutils
open Convertibility
open Stateutils
(* --- Types --- *)
type 'a proof_diff = 'a * 'a... | null | https://raw.githubusercontent.com/uwplse/PUMPKIN-PATCH/73fd77ba49388fdc72702a252a8fa8f071a8e1ea/plugin/src/compilation/proofdiff.ml | ocaml | Difference between old and new proofs
--- Types ---
Get the assumptions from a proof_diff
Get the old proof from a proof_diff
Get the new proof from a proof_diff
Change the assumptions of a proof_diff
Change the old proof of a proof_diff
Change the new proof of a proof_diff
--- Kinds of proof diffs ---... |
open Constr
open Environ
open Evd
open Proofcat
open Assumptions
open Expansion
open Evaluation
open Proofcatterms
open Reducers
open Declarations
open Utilities
open Merging
open Indutils
open Convertibility
open Stateutils
type 'a proof_diff = 'a * 'a * equal_assumptions
Construct a proof_diff
let difference a1... |
8f89cd200667e4f24e9c52c46d755e5f296ff127b13acdaa3c59b877453ef12e | malcolmreynolds/GSLL | blas-swap.lisp | Regression test BLAS - SWAP for GSLL , automatically generated
(in-package :gsl)
(LISP-UNIT:DEFINE-TEST BLAS-SWAP
(LISP-UNIT::ASSERT-NUMERICAL-EQUAL
(LIST (LIST #(-8.93 34.12 -6.15) #(-34.5 8.24 3.29)))
(MULTIPLE-VALUE-LIST
... | null | https://raw.githubusercontent.com/malcolmreynolds/GSLL/2f722f12f1d08e1b9550a46e2a22adba8e1e52c4/tests/blas-swap.lisp | lisp | Regression test BLAS - SWAP for GSLL , automatically generated
(in-package :gsl)
(LISP-UNIT:DEFINE-TEST BLAS-SWAP
(LISP-UNIT::ASSERT-NUMERICAL-EQUAL
(LIST (LIST #(-8.93 34.12 -6.15) #(-34.5 8.24 3.29)))
(MULTIPLE-VALUE-LIST
... | |
5322dee65825b1776511c1307073fb1acae02a659140f27315375679bc37173a | soegaard/remacs | colors.rkt | #lang racket/base
(provide (all-defined-out))
;;;
;;; COLORS
;;;
(require racket/class racket/draw)
(require (only-in srfi/1 circular-list))
(define (color? x)
(is-a? x color%))
(define (hex->color x)
(define blue (remainder x 256))
(define green (remainder (quotient x 256) 256))
(define... | null | https://raw.githubusercontent.com/soegaard/remacs/8681b3acfe93335e2bc2133c6f144af9e0a1289e/colors.rkt | racket |
COLORS
SOLARIZED
See more here:
Dark Mode:
base1 = optional emphasized contents
base01 = comments
base03 = background
These are for light mode
brblack background (darkest)
black background
brgreen content tone (darkest)
bryellow content tone
These are for dark mode
brblue ... | #lang racket/base
(provide (all-defined-out))
(require racket/class racket/draw)
(require (only-in srfi/1 circular-list))
(define (color? x)
(is-a? x color%))
(define (hex->color x)
(define blue (remainder x 256))
(define green (remainder (quotient x 256) 256))
(define red (remainder (... |
f3351a76e147b6bf018a7f61a9093df1cf03a937c1c4bb6a5c34efa0260b134f | mokus0/junkbox | BananaTimer.hs | {-# LANGUAGE RecordWildCards, RankNTypes #-}
module FRP.BananaTimer where
import Data.Time
import Reactive.Banana
data ClockControls t = ClockControls
{ initialTime :: Double
, unitsPerSecond :: Discrete t Double
, referenceClock :: Maybe (Clock t)
}
defaultClockControls = ClockControls
... | null | https://raw.githubusercontent.com/mokus0/junkbox/151014bbef9db2b9205209df66c418d6d58b0d9e/Haskell/FRP/BananaTimer.hs | haskell | # LANGUAGE RecordWildCards, RankNTypes #
^ the ratio of slave's clock rate to master's clock rate
^ the master clock's time at which the multiplier last changed
^ the slave clock's time at which the multiplier last changed
snapshot of state at last multiplier change event | module FRP.BananaTimer where
import Data.Time
import Reactive.Banana
data ClockControls t = ClockControls
{ initialTime :: Double
, unitsPerSecond :: Discrete t Double
, referenceClock :: Maybe (Clock t)
}
defaultClockControls = ClockControls
{ initialTime = 0
, unitsPerSeco... |
402904594d16d229d518632cfff9dd30915fa167201c718bb216acf643d7114c | input-output-hk/project-icarus-importer | Softfork.hs | # LANGUAGE TypeOperators #
-- | Softfork resolution logic.
module Pos.Update.Poll.Logic.Softfork
( recordBlockIssuance
, processGenesisBlock
) where
import Universum
import Control.Monad.Except (MonadError, throwError)
import qualified Data.HashSet as HS
import qualified Dat... | null | https://raw.githubusercontent.com/input-output-hk/project-icarus-importer/36342f277bcb7f1902e677a02d1ce93e4cf224f0/update/Pos/Update/Poll/Logic/Softfork.hs | haskell | | Softfork resolution logic.
| Record the fact that main block with given version and leader has
been issued by for the given slot.
inevitably encounter this issuer.
| Process creation of genesis block for given epoch.
resolution rule check.
resolution rule for them.
We also do sanity check in assert mode just ... | # LANGUAGE TypeOperators #
module Pos.Update.Poll.Logic.Softfork
( recordBlockIssuance
, processGenesisBlock
) where
import Universum
import Control.Monad.Except (MonadError, throwError)
import qualified Data.HashSet as HS
import qualified Data.List.NonEmpty as NE
import ... |
b8a1fc5c7d354e22555e30addf5d44acfadddb3c92672f065d2af4cf9fa6e64d | clojure/core.typed | untyped.clj | (ns clojure.core.typed.test.gradual.untyped)
(def a 1)
(def b nil)
| null | https://raw.githubusercontent.com/clojure/core.typed/f5b7d00bbb29d09000d7fef7cca5b40416c9fa91/typed/checker.jvm/test/clojure/core/typed/test/gradual/untyped.clj | clojure | (ns clojure.core.typed.test.gradual.untyped)
(def a 1)
(def b nil)
| |
639f282e75f4c4bb1a43d71ff44bd7a3b03f9451fa39b33dc96d11b410258e9a | chshersh/dr-cabal | Model.hs | |
Module : DrCabal . Model
Copyright : ( c ) 2022
SPDX - License - Identifier : MPL-2.0
Maintainer : < >
Stability : Experimental
Portability : Portable
Data types to model the domain of the @cabal@ output .
Module ... | null | https://raw.githubusercontent.com/chshersh/dr-cabal/29ea82fcafe332a0595069ef0901b0b49d8d6385/src/DrCabal/Model.hs | haskell | parse status string to the 'Status' type
check if this line is a library: '-' separates library name and its version | |
Module : DrCabal . Model
Copyright : ( c ) 2022
SPDX - License - Identifier : MPL-2.0
Maintainer : < >
Stability : Experimental
Portability : Portable
Data types to model the domain of the @cabal@ output .
Module ... |
f3e2f41da91ea43bf2e91def8cdf6b31a7ba8c724a27fa8cd34b88a1c52c806d | TOTBWF/teenytt | Refiner.hs | -- | The core of the elaboration algorithm.
module TeenyTT.Elaborator.Refiner
( typ
, chk
, syn
) where
import Data.Foldable
import Data.Functor
import TeenyTT.Base.Ident
import TeenyTT.Base.Location
import TeenyTT.Core.Domain qualified as D
import TeenyTT.Elaborator.ConcreteSyntax qualified as CS
import Te... | null | https://raw.githubusercontent.com/TOTBWF/teenytt/b1363fe78183bb13ea447056a10ef1eac72dbff1/src/TeenyTT/Elaborator/Refiner.hs | haskell | | The core of the elaboration algorithm. | module TeenyTT.Elaborator.Refiner
( typ
, chk
, syn
) where
import Data.Foldable
import Data.Functor
import TeenyTT.Base.Ident
import TeenyTT.Base.Location
import TeenyTT.Core.Domain qualified as D
import TeenyTT.Elaborator.ConcreteSyntax qualified as CS
import TeenyTT.Elaborator.Monad
import TeenyTT.Elabor... |
3cc4fe50ef9feb16087806b5f9843d9cab0fbb6853c77cec077e2855d43010ef | input-output-hk/plutus-apps | AddressDatumIndexEvent.hs | # LANGUAGE DataKinds #
{-# LANGUAGE GADTs #-}
# LANGUAGE LambdaCase #
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE TupleSections #
module Spec.Marconi.ChainIndex.Indexers.AddressDatum.AddressDatumIndexEvent
( tests
) where
import Cardano.Api qualified as C
import Cardano.Api... | null | https://raw.githubusercontent.com/input-output-hk/plutus-apps/006f4ae4461094d3e9405a445b0c9cf48727fa81/marconi-chain-index/test/Spec/Marconi/ChainIndex/Indexers/AddressDatum/AddressDatumIndexEvent.hs | haskell | # LANGUAGE GADTs #
# LANGUAGE OverloadedStrings #
TODO Very slow test case. There seems to be a performance issue with creating transactions
| TxOutDatumInScriptWitness C.ScriptData
We do 'addresses ++ addresses' to generate duplicate addresses so that we can test that we
correctly index different datum... | # LANGUAGE DataKinds #
# LANGUAGE LambdaCase #
# LANGUAGE TupleSections #
module Spec.Marconi.ChainIndex.Indexers.AddressDatum.AddressDatumIndexEvent
( tests
) where
import Cardano.Api qualified as C
import Cardano.Api.Shelley qualified as C
import Control.Monad (forM)
import Data.List q... |
15c7631f8a367f1a196246ae26b73731bbc6c3b3366de9783f9f96308ac663fe | owickstrom/komposition | VideoSpeedControl.hs | {-# LANGUAGE OverloadedLabels #-}
# LANGUAGE OverloadedLists #
{-# LANGUAGE OverloadedStrings #-}
-- |
module Komposition.UserInterface.GtkInterface.VideoSpeedControl where
import Komposition.Prelude
import Control.Lens
import GI.Gtk.Declarative
import Komposition.UserInt... | null | https://raw.githubusercontent.com/owickstrom/komposition/64893d50941b90f44d77fea0dc6d30c061464cf3/src/Komposition/UserInterface/GtkInterface/VideoSpeedControl.hs | haskell | # LANGUAGE OverloadedLabels #
# LANGUAGE OverloadedStrings #
| | # LANGUAGE OverloadedLists #
module Komposition.UserInterface.GtkInterface.VideoSpeedControl where
import Komposition.Prelude
import Control.Lens
import GI.Gtk.Declarative
import Komposition.UserInterface.GtkInterface.NumberInput
import Komposition.VideoSpeed
vi... |
3904d5ebe904135d5a0dbcdf12a1b48faf6b8c77825793f7b0315997556351cf | hexlet-codebattle/battle_asserts | equality_count.clj | (ns battle-asserts.issues.equality-count
(:require [clojure.test.check.generators :as gen]))
(def level :elementary)
(def tags ["math"])
(def description
{:en "Create a function that takes array of three integers and returns the amount of integers which are of equal value. Note: Function must return 0, 2 or 3."
... | null | https://raw.githubusercontent.com/hexlet-codebattle/battle_asserts/1dadf10a3daca628b89972b8de2ca497ca971739/src/battle_asserts/issues/equality_count.clj | clojure | (ns battle-asserts.issues.equality-count
(:require [clojure.test.check.generators :as gen]))
(def level :elementary)
(def tags ["math"])
(def description
{:en "Create a function that takes array of three integers and returns the amount of integers which are of equal value. Note: Function must return 0, 2 or 3."
... | |
345f6f83926eafc5df74f2438c907f5f9967fb567c0065d163dee6eed5176796 | emqx/emqx | emqx_gateway_ctx_SUITE.erl | %%--------------------------------------------------------------------
Copyright ( c ) 2022 - 2023 EMQ Technologies Co. , Ltd. All Rights Reserved .
%%
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
%% you may not use this file except in compliance with the License.
%% You may obtain a copy o... | null | https://raw.githubusercontent.com/emqx/emqx/dbc10c2eed3df314586c7b9ac6292083204f1f68/apps/emqx_gateway/test/emqx_gateway_ctx_SUITE.erl | erlang | --------------------------------------------------------------------
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
-2.0
Unless required by applicable law or agreed to in writing, software
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express ... | Copyright ( c ) 2022 - 2023 EMQ Technologies Co. , Ltd. All Rights Reserved .
Licensed under the Apache License , Version 2.0 ( the " License " ) ;
distributed under the License is distributed on an " AS IS " BASIS ,
-module(emqx_gateway_ctx_SUITE).
-include_lib("eunit/include/eunit.hrl").
-compile(export_all)... |
6a8fbac8474e7fd9cc4a9f24e565d0b9ff536785facffe992cb74c33ace59e66 | spurious/sagittarius-scheme-mirror | parameters.scm | -*- mode : scheme ; coding : utf-8 ; -*-
;;;
;;; sagittarius/parameters.scm - parameter library
;;;
Copyright ( c ) 2010 - 2016 < >
;;;
;;; Redistribution and use in source and binary forms, with or without
;;; modification, are permitted provided that the following conditions
;;; are met:
;;; ... | null | https://raw.githubusercontent.com/spurious/sagittarius-scheme-mirror/53f104188934109227c01b1e9a9af5312f9ce997/lib/sagittarius/parameters.scm | scheme | coding : utf-8 ; -*-
sagittarius/parameters.scm - parameter library
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, thi... | Copyright ( c ) 2010 - 2016 < >
" AS IS " AND ANY EXPRESS OR IMPLIED WARRANTIES , INCLUDING , BUT NOT
SPECIAL , EXEMPLARY , OR CONSEQUENTIAL DAMAGES ( INCLUDING , BUT NOT LIMITED
LIABILITY , WHETHER IN CONTRACT , STRICT LIABILITY , OR TORT ( INCLUDING
(library (sagittarius parameters)
(expor... |
4485bbad0a885d5073c27306266d1a806720b6c988a3e0af16497dc7f3ae335c | Camilotk/ocaml4noobs | extension.ml | module List = struct
include List
let rec optmap f = function
| [] -> []
| hd :: tl ->
match f hd with
| None -> optmap f tl
| Some x -> x :: optmap f tl
end;;
module type A = sig
val nome : string
val altura : float
end
module type B = sig
include A
val idade : int
end | null | https://raw.githubusercontent.com/Camilotk/ocaml4noobs/e0bcabb64b7d7749205bbce8a3d0ef75e16e66b3/4_organizacao/extension.ml | ocaml | module List = struct
include List
let rec optmap f = function
| [] -> []
| hd :: tl ->
match f hd with
| None -> optmap f tl
| Some x -> x :: optmap f tl
end;;
module type A = sig
val nome : string
val altura : float
end
module type B = sig
include A
val idade : int
end | |
ee640ffcc55bc8ad567b08a5962b5425bf7af0dfe4b14e132b63236eba7622db | dtgoitia/civil-autolisp | StreetLighting.lsp | (defun c:Clean_Street_lighting_Drawing ()
(initget "Yes No")
(if (= "Yes" (getkword "\n--- WARNING ---\nThis command will remove layers, and join lines and change their colors.\nAre you sure you want to continue? [Yes/No] <No>:"))
(progn
(setq luxLayerList (DT:GetLuxLayers))
(foreach layerName luxLa... | null | https://raw.githubusercontent.com/dtgoitia/civil-autolisp/72d68139d372c84014d160f8e4918f062356349f/Dump%20folder/StreetLighting.lsp | lisp | Join lux level lines
Change entity color form index to true
END foreach
Clean unnecessary layers
END progn
END if
Return layers lux level layers
END and
END if
Join lux levels
END if
END if
Join all the lines, arcs, polylines and lwpolylines passed
ss [pickset] - Selection set with all the entities to join
END p... | (defun c:Clean_Street_lighting_Drawing ()
(initget "Yes No")
(if (= "Yes" (getkword "\n--- WARNING ---\nThis command will remove layers, and join lines and change their colors.\nAre you sure you want to continue? [Yes/No] <No>:"))
(progn
(setq luxLayerList (DT:GetLuxLayers))
(foreach layerName luxLa... |
dc4b30dabbc3b931944076a2b2e379cdda1c42443a1f3317244624c56b67c605 | spechub/Hets | Examples.hs | module PGIP.Server.Examples where
dol :: String
dol = "%% a simple parthood ontology in OWL\n\
\logic OWL\n\
\ontology Parthood_OWL =\n\
\ ObjectProperty: isPartOf\n\
\ ObjectProperty: isProperPartOf\n\
\ Characteristics: Asymmetric\n\
\ SubPropertyOf: isPartOf\n\
\end\n\
... | null | https://raw.githubusercontent.com/spechub/Hets/af7b628a75aab0d510b8ae7f067a5c9bc48d0f9e/PGIP/Server/Examples.hs | haskell | module PGIP.Server.Examples where
dol :: String
dol = "%% a simple parthood ontology in OWL\n\
\logic OWL\n\
\ontology Parthood_OWL =\n\
\ ObjectProperty: isPartOf\n\
\ ObjectProperty: isProperPartOf\n\
\ Characteristics: Asymmetric\n\
\ SubPropertyOf: isPartOf\n\
\end\n\
... | |
4d7c48e30da89ff1f90c874c93849fc80758942a5dac2939b2592eb7ca94396d | ajhc/ajhc | Lexer.hs | -- #hide
-----------------------------------------------------------------------------
-- |
Module : Language . .
Copyright : ( c ) The GHC Team , 1997 - 2000
-- License : BSD-style (see the file libraries/base/LICENSE)
--
-- Maintainer :
-- Stability : experimental
-- Portability : porta... | null | https://raw.githubusercontent.com/ajhc/ajhc/8ef784a6a3b5998cfcd95d0142d627da9576f264/src/FrontEnd/Lexer.hs | haskell | #hide
---------------------------------------------------------------------------
|
License : BSD-style (see the file libraries/base/LICENSE)
Maintainer :
Stability : experimental
Portability : portable
---------------------------------------------------------------------------
ToDo: Use a lexical... | Module : Language . .
Copyright : ( c ) The GHC Team , 1997 - 2000
for Haskell .
ToDo : Introduce different tokens for decimal , octal and hexadecimal ( ? )
ToDo : FloatTok should have three parts ( integer part , fraction , exponent ) ( ? )
module FrontEnd.Lexer (Token(..), lexer) where
im... |
7e32d49336c842dc62ba6af45a09154bc36e557775497f5f15baea4194fd70b5 | kmmelcher/plp-sad | AlunoController.hs | O módulo AlunoController fornece todas as funcionalidades necessárias de interação para lidar com o
Aluno . tanto como mediador de informações entre um controller e o Aluno , como próprio canal de
troca de informações entre o e o sistema .
module Controller.AlunoController where
import Model.Aluno as A
... | null | https://raw.githubusercontent.com/kmmelcher/plp-sad/438d022b20413b5c4b180196cd9bea6f6b8d9b57/haskell/src/Controller/AlunoController.hs | haskell | O módulo AlunoController fornece todas as funcionalidades necessárias de interação para lidar com o
Aluno . tanto como mediador de informações entre um controller e o Aluno , como próprio canal de
troca de informações entre o e o sistema .
module Controller.AlunoController where
import Model.Aluno as A
... | |
96069e4f4908a2b01d9222ebf5473999354f87face26b329bb87d36b9ee4aa5d | fission-codes/fission | Root.hs | module Fission.Test.Web.Server.Root (spec) where
import Servant
import Fission.Internal.Mock
import qualified Fission.Web.API.Types as API
import Fission.Test.Web.Server.Prelude
spec :: Spec
spec =
describe "GET /" do
with rootServer do
it "is always successful" d... | null | https://raw.githubusercontent.com/fission-codes/fission/629f20c2d34201ae3211e398066b1a72dceb127e/fission-web-server/test/Fission/Test/Web/Server/Root.hs | haskell | i.e. this type enforces that it produces no effects | module Fission.Test.Web.Server.Root (spec) where
import Servant
import Fission.Internal.Mock
import qualified Fission.Web.API.Types as API
import Fission.Test.Web.Server.Prelude
spec :: Spec
spec =
describe "GET /" do
with rootServer do
it "is always successful" d... |
761f0b4444b7f80edcf6de78a453f01237f1e2e9b54b2cdba17794e33b304596 | fulcrologic/fulcro-rad | ids_spec.cljc | (ns com.fulcrologic.rad.ids-spec
(:require
[com.fulcrologic.rad.ids :as ids]
[fulcro-spec.core :refer [assertions specification behavior component =>]]))
(defn less-than [x y & more]
(if (< (compare x y) 0)
(if (next more)
(recur y (first more) (next more))
(< (compare y (first more)) 0))
... | null | https://raw.githubusercontent.com/fulcrologic/fulcro-rad/d2a40fdd7ca6ee0ec5fdb3897d5764bb6c5f7800/src/test/com/fulcrologic/rad/ids_spec.cljc | clojure | (ns com.fulcrologic.rad.ids-spec
(:require
[com.fulcrologic.rad.ids :as ids]
[fulcro-spec.core :refer [assertions specification behavior component =>]]))
(defn less-than [x y & more]
(if (< (compare x y) 0)
(if (next more)
(recur y (first more) (next more))
(< (compare y (first more)) 0))
... | |
57ed048bc76f82feff7cc404f4a4538bd58622de6924dfed925d40b111114d49 | msakai/toysolver | BCD.hs | # OPTIONS_GHC -Wall -fno - warn - unused - do - bind #
-----------------------------------------------------------------------------
-- |
Module : ToySolver .
Copyright : ( c ) 2014
-- License : BSD-style
--
-- Maintainer :
-- Stability : provisional
-- Portability : portable
--
-- Refer... | null | https://raw.githubusercontent.com/msakai/toysolver/6233d130d3dcea32fa34c26feebd151f546dea85/src/ToySolver/SAT/PBO/BCD.hs | haskell | ---------------------------------------------------------------------------
|
License : BSD-style
Maintainer :
Stability : provisional
Portability : portable
Reference:
Core-Guided binary search algorithms for maximum satisfiability,
<>
Improvements to Core-Guided binary search for MaxSAT... | # OPTIONS_GHC -Wall -fno - warn - unused - do - bind #
Module : ToySolver .
Copyright : ( c ) 2014
* , , ,
Twenty - Fifth AAAI Conference on Artificial Intelligence , 2011 .
* A. Morgado , , and ,
in Theory and Applications of Satisfiability Testing ( SAT 2012 ) ,
pp . ... |
0d43f1c029e9bf172563b1c2cd208733f4f3e4d54de1c2784cc9652e2b1dcf1d | OlafChitil/hat | LowLevel.hs | {-# LANGUAGE EmptyDataDecls #-}
module LowLevel
( openHatFile -- :: CString -> CString -> IO ()
, closeHatFile -- :: IO ()
: : IO FileNode
: : IO FileNode
: : IO CString
, hatVersionNumber -- :: String
, FileNode(..)
, nil -- :: FileNode
, unevaluated -- :: FileNo... | null | https://raw.githubusercontent.com/OlafChitil/hat/8840a480c076f9f01e58ce24b346850169498be2/tools/LowLevel.hs | haskell | # LANGUAGE EmptyDataDecls #
:: CString -> CString -> IO ()
:: IO ()
:: String
:: FileNode
:: FileNode
:: FileNode
:: FileNode
:: FileNode
:: FileNode
:: FileNode -> SimpleNodeType
:: FileNode -> FileNode
:: FileNode -> Bool -> FileNode
:: FileNode -> FileNode
:: FileNode -> String
:: FileNode -> String
... |
module LowLevel
: : IO FileNode
: : IO FileNode
: : IO CString
, FileNode(..)
, NodeType(..)
: : FileNode - > NodeType
, SimpleNodeType(..)
: : IO [ ( FileNode , NodeType ) ]
) where
import Foreign.Ptr (Ptr)
import Foreign.C.String (CString, peekCString)
import System.IO.Unsafe (unsaf... |
a7a62589ee8e82aabfbb6f806ebc75a3cf34fd0683b9d1854cc3e1753dede66f | openvstorage/alba | fragment_size_helper_test.ml |
Copyright ( C ) iNuron -
This file is part of Open vStorage . For license information , see < LICENSE.txt >
Copyright (C) iNuron -
This file is part of Open vStorage. For license information, see <LICENSE.txt>
*)
open! Prelude
open Fragment_size_helper
let test_determine_chunk_size () =
let v = [
... | null | https://raw.githubusercontent.com/openvstorage/alba/459bd459335138d6b282d332fcff53a1b4300c29/ocaml/src/fragment_size_helper_test.ml | ocaml |
Copyright ( C ) iNuron -
This file is part of Open vStorage . For license information , see < LICENSE.txt >
Copyright (C) iNuron -
This file is part of Open vStorage. For license information, see <LICENSE.txt>
*)
open! Prelude
open Fragment_size_helper
let test_determine_chunk_size () =
let v = [
... | |
c62a7a8219e7f1611c6f08309b542c9dcd9ef14adb4d672344aeb8d10cce7d9d | penpot/penpot | v1_10.cljs | This Source Code Form is subject to the terms of the Mozilla Public
License , v. 2.0 . If a copy of the MPL was not distributed with this
file , You can obtain one at /.
;;
;; Copyright (c) KALEIDOS INC
(ns app.main.ui.releases.v1-10
(:require
[app.main.ui.releases.common :as c]
[rumext.v2 :as mf]))
(de... | null | https://raw.githubusercontent.com/penpot/penpot/50ee0ad3fd4627b000841fa2eb4ee13ae9d93a9a/frontend/src/app/main/ui/releases/v1_10.cljs | clojure |
Copyright (c) KALEIDOS INC | This Source Code Form is subject to the terms of the Mozilla Public
License , v. 2.0 . If a copy of the MPL was not distributed with this
file , You can obtain one at /.
(ns app.main.ui.releases.v1-10
(:require
[app.main.ui.releases.common :as c]
[rumext.v2 :as mf]))
(defmethod c/render-release-notes "1... |
76f9e6d9a8ee50c3c7587430d4c3e7e38066754339541f50e9fe9ab71bf96de7 | michiakig/LispInSmallPieces | chap10j.scm | $ I d : chap10j.scm , v 4.0 1995/07/10 06:50:44 queinnec Exp $
;;;(((((((((((((((((((((((((((((((( L i S P ))))))))))))))))))))))))))))))))
;;; This file is part of the files that accompany the book:
LISP Implantation Semantique Programmation ( InterEditions , France )
By Christian Queinnec < >
;;; Newest v... | null | https://raw.githubusercontent.com/michiakig/LispInSmallPieces/0a2762d539a5f4c7488fffe95722790ac475c2ea/src/chap10j.scm | scheme | (((((((((((((((((((((((((((((((( L i S P ))))))))))))))))))))))))))))))))
This file is part of the files that accompany the book:
Newest version may be retrieved from:
Check the README file before using this file.
(((((((((((((((((((((((((((((((( L i S P ))))))))))))))))))))))))))))))))
Simple-minded initialization... | $ I d : chap10j.scm , v 4.0 1995/07/10 06:50:44 queinnec Exp $
LISP Implantation Semantique Programmation ( InterEditions , France )
By Christian Queinnec < >
( IP 128.93.2.54 ) ftp.inria.fr : INRIA / Projects / icsla / Books / LiSP*.tar.gz
(define-class Global-Variable Variable (initialized?))
(def... |
16ee8ff2e8f33b8d17c3cae55c115da1b260a32c2f8bbf7ffdb4088b622a089b | oakes/Nightlight | boot.clj | (ns nightlight.boot
{:boot/export-tasks true}
(:require [nightlight.core :refer [start]]
[boot.core :as core]
[clojure.java.io :as io]
[clojure.string :as str]))
(core/deftask nightlight
[p port PORT int "The port that Nightlight runs on"
_ host HOST str "The hostname that ... | null | https://raw.githubusercontent.com/oakes/Nightlight/51ed9bcd7286c2833bb48daf9cb0624e4e7b0e14/src/nightlight/boot.clj | clojure | (ns nightlight.boot
{:boot/export-tasks true}
(:require [nightlight.core :refer [start]]
[boot.core :as core]
[clojure.java.io :as io]
[clojure.string :as str]))
(core/deftask nightlight
[p port PORT int "The port that Nightlight runs on"
_ host HOST str "The hostname that ... | |
eb6d89bab67b768c9a9bb3e1ce45f5e3f5315681374755bab6bc39ed4c4f28b6 | LeventErkok/sbvPlugin | T25.hs | {-# OPTIONS_GHC -fplugin=Data.SBV.Plugin #-}
module T25 where
import Data.SBV.Plugin
{-# ANN f theorem #-}
f :: Bool
f = True
| null | https://raw.githubusercontent.com/LeventErkok/sbvPlugin/b6a6e94cd237a4f64f985783931bd7656e7a6a69/tests/T25.hs | haskell | # OPTIONS_GHC -fplugin=Data.SBV.Plugin #
# ANN f theorem # |
module T25 where
import Data.SBV.Plugin
f :: Bool
f = True
|
3df5327a7557f52bc4f587390116b8a617e9ab498af556b7a2b0237cec27a0ae | DKurilo/hackerrank | cata.hs | |
Here is examples from these lectures :
Also a great article is here :
-algebras
I just wrote down examples from lectures as accurate as I could .
As I feel it , playing with this code allow to understand lectures better and to find why and where you need this .
This code available he... | null | https://raw.githubusercontent.com/DKurilo/hackerrank/37063170567b397b25a2b7123bc9c1299d34814a/nothackerrank/cata.hs | haskell | Example 1. Fibonacci | |
Here is examples from these lectures :
Also a great article is here :
-algebras
I just wrote down examples from lectures as accurate as I could .
As I feel it , playing with this code allow to understand lectures better and to find why and where you need this .
This code available he... |
fb72cfdbe762b9b1f090bc741c34bc2fa2fa0385c2ac643a5ac0da494e2fac0d | rd--/hsc3 | mostChange.help.hs | -- mostChange
let n = lfNoise0Id 'α' kr 1
x = mouseX kr 200 300 Linear 0.1
f = mostChange (n * 400 + 900) x
in sinOsc ar f 0 * 0.1
| null | https://raw.githubusercontent.com/rd--/hsc3/60cb422f0e2049f00b7e15076b2667b85ad8f638/Help/Ugen/mostChange.help.hs | haskell | mostChange | let n = lfNoise0Id 'α' kr 1
x = mouseX kr 200 300 Linear 0.1
f = mostChange (n * 400 + 900) x
in sinOsc ar f 0 * 0.1
|
b26c2abaf492b152ce084dd9d784527ee8073f84511a9a87d5b0fdd0a6a630ad | runtimeverification/haskell-backend | Transition.hs | module Test.Kore.Rewrite.Transition (
test_ifte,
test_record,
) where
import Kore.Rewrite.Transition
import Prelude.Kore
import Test.Tasty
import Test.Tasty.HUnit.Ext
test_ifte :: [TestTree]
test_ifte =
[ testGroup
"\"else\" branch"
[ testCase "returns value" $ do
let thenBranc... | null | https://raw.githubusercontent.com/runtimeverification/haskell-backend/b06757e252ee01fdd5ab8f07de2910711997d845/kore/test/Test/Kore/Rewrite/Transition.hs | haskell | Allows running some Transition action before the recorded action. | module Test.Kore.Rewrite.Transition (
test_ifte,
test_record,
) where
import Kore.Rewrite.Transition
import Prelude.Kore
import Test.Tasty
import Test.Tasty.HUnit.Ext
test_ifte :: [TestTree]
test_ifte =
[ testGroup
"\"else\" branch"
[ testCase "returns value" $ do
let thenBranc... |
884a4042a5eeb51c0bd86aa87116bd079cb3735254e3fb95d7c9d1d826d33feb | outergod/cl-heredoc | package.lisp | ;;;; cl-heredoc - package.lisp
Copyright ( C ) 2009 , 2010 < >
;;;; This file is part of cl-heredoc.
;;;; cl-heredoc 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... | null | https://raw.githubusercontent.com/outergod/cl-heredoc/a8c8a3557bb6b4854adff86f10182c22e6676ac8/src/package.lisp | lisp | cl-heredoc - package.lisp
This file is part of cl-heredoc.
cl-heredoc is free software; you can redistribute it and/or modify
either version 3 of the License , or
(at your option) any later version.
cl-heredoc is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied ... | Copyright ( C ) 2009 , 2010 < >
it under the terms of the GNU General Public License as published by
You should have received a copy of the GNU General Public License
(in-package :cl-user)
(defpackage :cl-heredoc
(:use :cl)
(:export :read-heredoc :read-until-match))
|
24c4cb591d8ffadc44824600b3c19882c1836805110d0b15e93109bb2334f53c | fdopen/uwt | uwt_io.mli | This file is part of uwt , released under the MIT license . See LICENSE.md for
details , or visit .
details, or visit . *)
(** Buffered byte channels *)
* A { b channel } is a high - level object for performing input / output
( IO ) . It allows to read / write from / to the outside world in an
... | null | https://raw.githubusercontent.com/fdopen/uwt/44276aa6755b92eddc9ad58662a968afad243e8b/src/uwt_io.mli | ocaml | * Buffered byte channels
* Exception raised when a channel is closed. The parameter is a
description of the channel.
* {2 Types}
* Type of buffered byte channels
* Input mode
* Output mode
* Channel mode
* [input] input mode representation
* [output] output mode representation
* Type of input channels
*... | This file is part of uwt , released under the MIT license . See LICENSE.md for
details , or visit .
details, or visit . *)
* A { b channel } is a high - level object for performing input / output
( IO ) . It allows to read / write from / to the outside world in an
efficient way , by minimising ... |
19a0e222956d98ca20ee0f3e1b1501e37ab8790b2b1ee48c50da86a6cff8a27b | erlangonrails/devdb | simple_phase.erl | This file is provided to you under the Apache License ,
%% Version 2.0 (the "License"); you may not use this file
except in compliance with the License . You may obtain
%% a copy of the License at
%% -2.0
%% Unless required by applicable law or agreed to in writing,
software distributed under the License is... | null | https://raw.githubusercontent.com/erlangonrails/devdb/0e7eaa6bd810ec3892bfc3d933439560620d0941/dev/riak-0.11.0/apps/luke/tests/simple_phase.erl | erlang | Version 2.0 (the "License"); you may not use this file
a copy of the License at
-2.0
Unless required by applicable law or agreed to in writing,
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License. | This file is provided to you under the Apache License ,
except in compliance with the License . You may obtain
software distributed under the License is distributed on an
" AS IS " BASIS , WITHOUT WARRANTIES OR CONDITIONS OF ANY
-module(simple_phase).
-behaviour(luke_phase).
-export([init/1, handle_input... |
f4c19afcb2f4002ea181d8b8d01b67f44757ffdc71c5208037a950bead338d45 | aniketpant/fraskell | fizzbuzz.hs | {-
The usual FizzBuzz code
-}
module Main where
main = do
mapM_ putStrLn $ map fizzbuzz [1..100]
fizzbuzz :: Int -> String
fizzbuzz x
| x `mod` 15 == 0 = "FizzBuzz"
| x `mod` 3 == 0 = "Fizz"
| x `mod` 5 == 0 = "Buzz"
| otherwise = show x | null | https://raw.githubusercontent.com/aniketpant/fraskell/e1c0f9a11bada28907980f08eff86106d67bf4f5/fizzbuzz.hs | haskell |
The usual FizzBuzz code
|
module Main where
main = do
mapM_ putStrLn $ map fizzbuzz [1..100]
fizzbuzz :: Int -> String
fizzbuzz x
| x `mod` 15 == 0 = "FizzBuzz"
| x `mod` 3 == 0 = "Fizz"
| x `mod` 5 == 0 = "Buzz"
| otherwise = show x |
ff76daa96d0104a32bcabbfe3f6e0b2086f06cc043aa83ded809f20cb395aa33 | tweag/ormolu | multi-way-if.hs | {-# LANGUAGE MultiWayIf #-}
foo x = if | x == 5 -> 5
bar x y = if
| x > y -> x
| x < y
-> y
| otherwise -> x
baz =
if | p -> f
| otherwise -> g
x
| null | https://raw.githubusercontent.com/tweag/ormolu/34bdf62429768f24b70d0f8ba7730fc4d8ae73ba/data/examples/declaration/value/function/multi-way-if.hs | haskell | # LANGUAGE MultiWayIf # |
foo x = if | x == 5 -> 5
bar x y = if
| x > y -> x
| x < y
-> y
| otherwise -> x
baz =
if | p -> f
| otherwise -> g
x
|
fe6b2f8d6ff579cec09e8ec7b71372d657515069802bd7f0b0a710ab587920d0 | nixz/cl-vr | make-geometry.lisp | ;;;; -*- Mode: Lisp; indent-tabs-mode: nil -*-
;;;; ==========================================================================
make-geometry.lisp --- The code in this file makes vertex and index
;;;; buffers with the geometry that is specified into global buffers
;;;;
Copyright ( c ) 2013 , < >
;;;; All rights... | null | https://raw.githubusercontent.com/nixz/cl-vr/145aa3505a09e996101972faaed6250fa1164d07/make-geometry.lisp | lisp | -*- Mode: Lisp; indent-tabs-mode: nil -*-
==========================================================================
buffers with the geometry that is specified into global buffers
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that... | make-geometry.lisp --- The code in this file makes vertex and index
Copyright ( c ) 2013 , < >
" 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
THEORY OF LIABILITY ,... |
69f55def57504cf0acb354ebec1d47d273cf33ff54715d5189d4bd92f0568e1f | np/mbox-tools | mbox-grep.hs | {-# LANGUAGE TemplateHaskell, TypeOperators #-}
--------------------------------------------------------------------
-- |
-- Executable : mbox-grep
Copyright : ( c ) 2008 , 2009 , 2010 , 2011
-- License : BSD3
--
Maintainer : < >
-- Stability : provisional
-- Portability:
--
---------------------------------... | null | https://raw.githubusercontent.com/np/mbox-tools/494848aa730e445d3227b6c57d3351aa8401cf4c/mbox-grep.hs | haskell | # LANGUAGE TemplateHaskell, TypeOperators #
------------------------------------------------------------------
|
Executable : mbox-grep
License : BSD3
Stability : provisional
Portability:
------------------------------------------------------------------
emailContent email | Copyright : ( c ) 2008 , 2009 , 2010 , 2011
Maintainer : < >
import Codec.Mbox (Mbox(..), MboxMessage(..), Direction(..), parseMboxFiles, opposite)
import Email (Email(..),ShowFormat(..),fmtOpt,defaultShowFormat,
readEmail,putEmails,showFormatsDoc,stringOfField)
import System.Environment (getArg... |
faef07326abb5f89466ff5ea68017976e9b5f9f7edfb6e200d9a4969e2361686 | brendanhay/gogol | Product.hs | # LANGUAGE DataKinds #
# LANGUAGE DeriveGeneric #
# LANGUAGE DerivingStrategies #
# LANGUAGE DuplicateRecordFields #
# LANGUAGE FlexibleInstances #
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE LambdaCase #
{-# LANGUAGE OverloadedStrings #-}
# LANGUAGE PatternSynonyms #
# LANGUAGE RecordWildCards #
{-# LANGUAGE St... | null | https://raw.githubusercontent.com/brendanhay/gogol/8cbceeaaba36a3c08712b2e272606161500fbe91/lib/services/gogol-doubleclick-bids/gen/Gogol/DoubleClickBids/Internal/Product.hs | haskell | # LANGUAGE OverloadedStrings #
# LANGUAGE StrictData #
|
Stability : auto-generated
* ChannelGrouping
* DisjunctiveMatchStatement
* EventFilter
* ListQueriesResponse
* Options
* Parameters
* PathFilter
* PathQueryOptions
* PathQueryOptionsFilter
* Query
* QueryMetadata
* QuerySchedule
* Report
* Repor... | # LANGUAGE DataKinds #
# LANGUAGE DeriveGeneric #
# LANGUAGE DerivingStrategies #
# LANGUAGE DuplicateRecordFields #
# LANGUAGE FlexibleInstances #
# LANGUAGE GeneralizedNewtypeDeriving #
# LANGUAGE LambdaCase #
# LANGUAGE PatternSynonyms #
# LANGUAGE RecordWildCards #
# LANGUAGE TypeFamilies #
# LANGUAGE TypeOperators... |
91d09fa0c7998c319dda0cdb5cd7211a1ebb96599d8124b0628c64ac962152d5 | ralsei/sawzall | info.rkt | #lang info
(define collection 'multi)
(define deps '("sawzall-lib"
"sawzall-doc"))
(define implies '("sawzall-lib"
"sawzall-doc"))
(define pkg-desc "A grammar for data wrangling")
(define version "1.0")
| null | https://raw.githubusercontent.com/ralsei/sawzall/c50c78fb48769fe90727cf4f5cff2d39f5c2cd22/sawzall/info.rkt | racket | #lang info
(define collection 'multi)
(define deps '("sawzall-lib"
"sawzall-doc"))
(define implies '("sawzall-lib"
"sawzall-doc"))
(define pkg-desc "A grammar for data wrangling")
(define version "1.0")
| |
7cab979aa0306ab0c73069386a7d8200db012a1117148b8ff1724d653de03a7c | weyrick/roadsend-php | cfa.scm | ;; ***** BEGIN LICENSE BLOCK *****
;; Roadsend PHP Compiler
Copyright ( C ) 2007 - 2008 Roadsend , Inc.
;;
;; 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 ,... | null | https://raw.githubusercontent.com/weyrick/roadsend-php/d6301a897b1a02d7a85bdb915bea91d0991eb158/compiler/cfa.scm | scheme | ***** BEGIN LICENSE BLOCK *****
Roadsend PHP Compiler
This program is free software; you can redistribute it and/or
either version 2
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOS... | Copyright ( C ) 2007 - 2008 Roadsend , Inc.
modify it under the terms of the GNU General Public License
of the License , or ( at your option ) any later version .
You should have received a copy of the GNU General Public License
Foundation , Inc. , 51 Franklin Street , Fifth Floor , Boston , MA 02110 - 1301... |
4472fd6bb5458c4b67328cf3a71ba59781e494f5a7c8be81d0ed9ff57a2c9470 | gsakkas/rite | 3255.ml |
let pipe fs = let f a x = a x in let base = 0 in List.fold_left f base fs;;
fix
let pipe fs = let f a x a x = x in let base x = x in List.fold_left f base fs ; ;
let pipe fs = let f a x a x = x in let base x = x in List.fold_left f base fs;;
*)
changed spans
( 2,27)-(2,30 )
fun a - > fun x - > x
L... | null | https://raw.githubusercontent.com/gsakkas/rite/958a0ad2460e15734447bc07bd181f5d35956d3b/data/sp14/3255.ml | ocaml |
let pipe fs = let f a x = a x in let base = 0 in List.fold_left f base fs;;
fix
let pipe fs = let f a x a x = x in let base x = x in List.fold_left f base fs ; ;
let pipe fs = let f a x a x = x in let base x = x in List.fold_left f base fs;;
*)
changed spans
( 2,27)-(2,30 )
fun a - > fun x - > x
L... | |
977d68ebfcde49e4f422939bea77567b55319d88ab2caf5b22b83147e2e40c10 | finnishtransportagency/harja | aikataulu_test.clj | (ns harja.palvelin.raportointi.aikataulu-test
(:require [clojure.test :refer :all]
[harja.palvelin.komponentit.tietokanta :as tietokanta]
[harja.palvelin.palvelut.toimenpidekoodit :refer :all]
[harja.palvelin.palvelut.urakat :refer :all]
[harja.testi :refer :all]
... | null | https://raw.githubusercontent.com/finnishtransportagency/harja/d2c3efc456f459e72943c97c369d5391b57f5536/test/clj/harja/palvelin/raportointi/aikataulu_test.clj | clojure | (ns harja.palvelin.raportointi.aikataulu-test
(:require [clojure.test :refer :all]
[harja.palvelin.komponentit.tietokanta :as tietokanta]
[harja.palvelin.palvelut.toimenpidekoodit :refer :all]
[harja.palvelin.palvelut.urakat :refer :all]
[harja.testi :refer :all]
... | |
d3b96c993ed3f97785d8254be36b7b08696a2ea8ca0151014c633b6f1af276e5 | DaMSL/K3 | FusionHarness.hs | # LANGUAGE LambdaCase #
# LANGUAGE ViewPatterns #
import Language.K3.Core.Annotation (K3, tag, (@~))
import Language.K3.Core.Declaration (Declaration(..))
import Language.K3.Core.Expression
import Language.K3.Analysis.HMTypes.Inference
import Language.K3.Analysis.Properties
import Language.K3.Analysis.Effects.InsertE... | null | https://raw.githubusercontent.com/DaMSL/K3/51749157844e76ae79dba619116fc5ad9d685643/examples/analysis/FusionHarness.hs | haskell | doFusionInference :: K3 Declaration -> Either String (K3 Declaration)
doFusionInference p = do
inferFusableProgramApplies pWithProp
--pWithFuse <- inferFusableProgramApplies pWithProp
fuseProgramTransformers pWithFuse
. stripAllProperties | # LANGUAGE LambdaCase #
# LANGUAGE ViewPatterns #
import Language.K3.Core.Annotation (K3, tag, (@~))
import Language.K3.Core.Declaration (Declaration(..))
import Language.K3.Core.Expression
import Language.K3.Analysis.HMTypes.Inference
import Language.K3.Analysis.Properties
import Language.K3.Analysis.Effects.InsertE... |
99fb63e0ccc1d3f9d260930c23add92e7182723dd58b0a3c49bbc7c0924f5d23 | TGOlson/blockchain | Crypto.hs | module Data.Blockchain.Crypto
( module Data.Blockchain.Crypto.ECDSA
, module Data.Blockchain.Crypto.Hash
, module Data.Blockchain.Crypto.HashTree
) where
import Data.Blockchain.Crypto.ECDSA
import Data.Blockchain.Crypto.Hash
import Data.Blockchain.Crypto.HashTree
| null | https://raw.githubusercontent.com/TGOlson/blockchain/da53ad888589b5a2f3fd2c53c33a399fefb48ab1/lib/Data/Blockchain/Crypto.hs | haskell | module Data.Blockchain.Crypto
( module Data.Blockchain.Crypto.ECDSA
, module Data.Blockchain.Crypto.Hash
, module Data.Blockchain.Crypto.HashTree
) where
import Data.Blockchain.Crypto.ECDSA
import Data.Blockchain.Crypto.Hash
import Data.Blockchain.Crypto.HashTree
| |
1efef7399d25084e9f251a29be1004dba818cf0d8524d36689b20fb7af7549d8 | ocaml-flambda/ocaml-jst | lift_code.ml | (**************************************************************************)
(* *)
(* OCaml *)
(* *)
... | null | https://raw.githubusercontent.com/ocaml-flambda/ocaml-jst/7e5a626e4b4e12f1e9106564e1baba4d0ef6309a/middle_end/flambda/lift_code.ml | ocaml | ************************************************************************
OCaml
... | , OCamlPro
and ,
Copyright 2014 - -2016 Jane Street Group LLC
the GNU Lesser General Public License version 2.1 , with the
[@@@ocaml.warning "+a-4-9-30-40-41-42-66"]
open! Int_replace_polymor... |
68649e1101fd4a27c24034903d6395631aeada989692a35115dfdde054407e8f | well-typed/large-records | R000.hs | #if PROFILE_CORESIZE
{-# OPTIONS_GHC -ddump-to-file -ddump-ds-preopt -ddump-ds -ddump-simpl #-}
#endif
#if PROFILE_TIMING
{-# OPTIONS_GHC -ddump-to-file -ddump-timings #-}
#endif
module Experiment.HListBaseline.Sized.R000 where
| null | https://raw.githubusercontent.com/well-typed/large-records/551f265845fbe56346988a6b484dca40ef380609/large-records-benchmarks/bench/typelet/Experiment/HListBaseline/Sized/R000.hs | haskell | # OPTIONS_GHC -ddump-to-file -ddump-ds-preopt -ddump-ds -ddump-simpl #
# OPTIONS_GHC -ddump-to-file -ddump-timings # | #if PROFILE_CORESIZE
#endif
#if PROFILE_TIMING
#endif
module Experiment.HListBaseline.Sized.R000 where
|
20d1761e005d35214e28e847b9f221037440b55ed7f4fb9142d7b1272349732f | synduce/Synduce | search_v4.ml | * @synduce -s 2 -NB
(* Trees *)
type 'a tree =
| Empty
| Node of 'a * 'a tree * 'a tree
(* Lists *)
type 'a list =
| Nil
| Cons of 'a * 'a list
(* Representation function from tree to list *)
let rec repr = function
| Empty -> Nil
| Node (a, l, r) -> Cons (a, dec (repr l) r)
and dec li = function
| Em... | null | https://raw.githubusercontent.com/synduce/Synduce/42d970faa863365f10531b19945cbb5cfb70f134/benchmarks/incomplete/list_to_tree/search_v4.ml | ocaml | Trees
Lists
Representation function from tree to list | * @synduce -s 2 -NB
type 'a tree =
| Empty
| Node of 'a * 'a tree * 'a tree
type 'a list =
| Nil
| Cons of 'a * 'a list
let rec repr = function
| Empty -> Nil
| Node (a, l, r) -> Cons (a, dec (repr l) r)
and dec li = function
| Empty -> li
| Node (a, ll, lr) -> Cons (a, dec (dec li ll) lr)
;;
let t... |
52bb1284efd57b0e175144778538f5030dcd2347fd4cef8f545328b8b5401e69 | soenkehahn/getopt-generics | ModifiersSpec.hs | # LANGUAGE DeriveGeneric #
module ModifiersSpec where
import Data.Char
import Data.List
import Test.Hspec
import Util
import WithCli.Pure
import WithCli.Pure.RecordSpec
spec :: Spec
spec = do
describe "AddShortOption" $ do
it "allows modifiers for sh... | null | https://raw.githubusercontent.com/soenkehahn/getopt-generics/dd7223d98524d9f2e406f6691965f0dc66423b6f/test/ModifiersSpec.hs | haskell | # LANGUAGE DeriveGeneric #
module ModifiersSpec where
import Data.Char
import Data.List
import Test.Hspec
import Util
import WithCli.Pure
import WithCli.Pure.RecordSpec
spec :: Spec
spec = do
describe "AddShortOption" $ do
it "allows modifiers for sh... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.