_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
e47654f2d461469ab3906a1cf9e33eae0390d7be19a3e9184e147a58156e0d3d
jyh/metaprl
mfir_token.ml
doc <:doc< @module[Mfir_token] The @tt[Mfir_token] module defines tokens, a syntactic mechanism for representing strings and operations on strings. @docoff ------------------------------------------------------------------------ @begin[license] This file is part of MetaPRL, a modular, higher ord...
null
https://raw.githubusercontent.com/jyh/metaprl/51ba0bbbf409ecb7f96f5abbeb91902fdec47a19/theories/fir/mfir_token.ml
ocaml
************************************************************************* * Declarations. ************************************************************************* ************************************************************************* * Rewrites. ******************************************************************...
doc <:doc< @module[Mfir_token] The @tt[Mfir_token] module defines tokens, a syntactic mechanism for representing strings and operations on strings. @docoff ------------------------------------------------------------------------ @begin[license] This file is part of MetaPRL, a modular, higher ord...
39f9c2aca7797ed77b7c22a3b15942ec7377a527e4807a547a0da1578692336c
janestreet/memtrace_viewer_with_deps
vdom_keyboard.ml
module Grouped_help_text = Grouped_help_text module Help_text = Help_text module Keyboard_event_handler = Keyboard_event_handler module Keystroke = Keystroke module Variable_keyboard_event_handler = Variable_keyboard_event_handler module Keyboard_event = Keyboard_event let with_keyboard_handler node keyboard_handler =...
null
https://raw.githubusercontent.com/janestreet/memtrace_viewer_with_deps/5a9e1f927f5f8333e2d71c8d3ca03a45587422c4/vendor/incr_dom_keyboard/src/vdom_keyboard.ml
ocaml
module Grouped_help_text = Grouped_help_text module Help_text = Help_text module Keyboard_event_handler = Keyboard_event_handler module Keystroke = Keystroke module Variable_keyboard_event_handler = Variable_keyboard_event_handler module Keyboard_event = Keyboard_event let with_keyboard_handler node keyboard_handler =...
438f12255583a7e8a29b6cce0fe06aef3ec6aff6ef9d9e0202bca3bc49791049
haskellari/postgresql-libpq
Marshal.hs
# LANGUAGE CPP # module Database.PostgreSQL.LibPQ.Marshal where import Foreign (Ptr, Storable, allocaArray, nullPtr, pokeArray) unsafeWithArray :: Storable a => Int -> [a] -> (Ptr a -> IO b) -> IO b unsafeWithArray len vals f = #if 0 if len /= length vals then error "unsafeWithArray: len mismatch" else #endif all...
null
https://raw.githubusercontent.com/haskellari/postgresql-libpq/733ce3a84f073d5ff1ecda1f34b7e945a5c3cbfd/src/Database/PostgreSQL/LibPQ/Marshal.hs
haskell
In 'Nothing' case uses 0 and 'nullPtr'.
# LANGUAGE CPP # module Database.PostgreSQL.LibPQ.Marshal where import Foreign (Ptr, Storable, allocaArray, nullPtr, pokeArray) unsafeWithArray :: Storable a => Int -> [a] -> (Ptr a -> IO b) -> IO b unsafeWithArray len vals f = #if 0 if len /= length vals then error "unsafeWithArray: len mismatch" else #endif all...
68b5c20a90294f0328a9aa7f94bc405dfe1ce43aa0ac1407fe3d9aad32d58af1
RichiH/git-annex
FileMatcher.hs
git - annex file matcher types - - Copyright 2013 - 2016 < > - - Licensed under the GNU GPL version 3 or higher . - - Copyright 2013-2016 Joey Hess <> - - Licensed under the GNU GPL version 3 or higher. -} module Types.FileMatcher where import Types.UUID (UUID) import Types.Key (Key) import U...
null
https://raw.githubusercontent.com/RichiH/git-annex/bbcad2b0af8cd9264d0cb86e6ca126ae626171f3/Types/FileMatcher.hs
haskell
^ current path to the file, for operations that examine it If the OptInfo is not available, accessing it may result in eg an exception being thrown. This is a matcher that can have tokens added to it while it's being built, and once complete is compiled to an unchangable matcher.
git - annex file matcher types - - Copyright 2013 - 2016 < > - - Licensed under the GNU GPL version 3 or higher . - - Copyright 2013-2016 Joey Hess <> - - Licensed under the GNU GPL version 3 or higher. -} module Types.FileMatcher where import Types.UUID (UUID) import Types.Key (Key) import U...
a597e3aed368bba740c94b8af9cbc8b4925b0bf91e9dc07024aba97204350561
guardians-of-life/haskell-editor-setup
Debian.hs
module OS.Linux.Debian where import OS.Common import qualified Data.Text as T import Data.Text.IO ( putStrLn ) import Data.Maybe ( isNothing ) import NeatInterpolation import Prelude ( IO ...
null
https://raw.githubusercontent.com/guardians-of-life/haskell-editor-setup/241adbc85dbfa3eeebbdcb1064bde415c84f1cc0/src/OS/Linux/Debian.hs
haskell
module OS.Linux.Debian where import OS.Common import qualified Data.Text as T import Data.Text.IO ( putStrLn ) import Data.Maybe ( isNothing ) import NeatInterpolation import Prelude ( IO ...
ecf4639956c7d54065382faf2095f1f8c51977493eb5174b8942b86638d3828d
steffan-westcott/clj-otel
middleware.clj
(ns example.common-utils.middleware (:require [steffan-westcott.clj-otel.api.trace.http :as trace-http] [steffan-westcott.clj-otel.api.trace.span :as span])) (defn wrap-exception-event "Ring middleware for adding an exception event to the server span." [handler] (fn ([request] (try ...
null
https://raw.githubusercontent.com/steffan-westcott/clj-otel/ed5c20a468fb2b8b3f4674382f57e031609f20a6/examples/common-utils/middleware/src/example/common_utils/middleware.clj
clojure
(ns example.common-utils.middleware (:require [steffan-westcott.clj-otel.api.trace.http :as trace-http] [steffan-westcott.clj-otel.api.trace.span :as span])) (defn wrap-exception-event "Ring middleware for adding an exception event to the server span." [handler] (fn ([request] (try ...
1310d95c3ffd3b1f9efb3823940ec9190c3f65aa282b18ab778029b70ab83795
clash-lang/clash-compiler
Interpolate.hs
| Copyright : ( C ) 2019 , QBayLogic B.V. License : BSD2 ( see the file LICENSE ) Maintainer : QBayLogic B.V. < > Copyright : (C) 2019, QBayLogic B.V. License : BSD2 (see the file LICENSE) Maintainer : QBayLogic B.V. <> -} # LANGUAGE QuasiQuotes # module Clash.Tests.Util.Interpolate where ...
null
https://raw.githubusercontent.com/clash-lang/clash-compiler/8e461a910f2f37c900705a0847a9b533bce4d2ea/clash-lib/tests/Clash/Tests/Util/Interpolate.hs
haskell
test that we can escape closing '}'
| Copyright : ( C ) 2019 , QBayLogic B.V. License : BSD2 ( see the file LICENSE ) Maintainer : QBayLogic B.V. < > Copyright : (C) 2019, QBayLogic B.V. License : BSD2 (see the file LICENSE) Maintainer : QBayLogic B.V. <> -} # LANGUAGE QuasiQuotes # module Clash.Tests.Util.Interpolate where ...
b1bea2384267a355796aadc16cdb1e06f50702d957855187f9d282029889edc5
gregtatcam/imaplet-lwt
gitl_storage.ml
* Copyright ( c ) 2013 - 2016 < > * * Permission to use , copy , modify , and distribute this software for any * purpose with or without fee is hereby granted , provided that the above * copyright notice and this permission notice appear in all copies . * * THE SOFTWARE IS PROVIDED " AS IS " AND...
null
https://raw.githubusercontent.com/gregtatcam/imaplet-lwt/d7b51253e79cffa97e98ab899ed833cd7cb44bb6/lib/commands/gitl_storage.ml
ocaml
user,mailbox,keys check if mailbox exists status select mailbox examine mailbox create mailbox delete mailbox subscribe mailbox unsubscribe mailbox need to eliminate messages, .index, and .meta append message(s) to selected mailbox should do binary search, the list is ordered delete a message ...
* Copyright ( c ) 2013 - 2016 < > * * Permission to use , copy , modify , and distribute this software for any * purpose with or without fee is hereby granted , provided that the above * copyright notice and this permission notice appear in all copies . * * THE SOFTWARE IS PROVIDED " AS IS " AND...
c7a970949c45d6191a65cbcaeccb0ce1b604fe422d61ccc62f74e7b74a2c2acd
mokus0/junkbox
ShredCppHeaders.hs
module ShredCppHeaders where import System.Environment import System.Process import Text.ParserCombinators.Parsec import Data.List main = do (hdr:args) <- getArgs processed <- readProcess "cpp" (["-xc++"] ++ args) ("#include " ++ show hdr) case parse header "<cpp output>" processed of ...
null
https://raw.githubusercontent.com/mokus0/junkbox/151014bbef9db2b9205209df66c418d6d58b0d9e/Haskell/Odd%20little%20utilities/ShredCppHeaders.hs
haskell
blankStuff = many1 blankThing blankThing = space <|> newline decl = namespace <|> otherDecl namespace = do string "namespace" blankStuff identifier conservative... add cases as needed
module ShredCppHeaders where import System.Environment import System.Process import Text.ParserCombinators.Parsec import Data.List main = do (hdr:args) <- getArgs processed <- readProcess "cpp" (["-xc++"] ++ args) ("#include " ++ show hdr) case parse header "<cpp output>" processed of ...
edfa13b3740aedcfb121ece4d91a7b4a5883fc8918a6ff518bc04a85420ecd82
mukul-rathi/bolt
bad_function_defn.ml
open Core open Print_typed_ast let%expect_test "Function args in wrong order" = print_typed_ast " class Foo { capability linear Bar; var int f : Bar; } function int f (int z, Foo y) { z } void main(){ let y = new Foo(); f(y, 4) // Error - args in wrong order ...
null
https://raw.githubusercontent.com/mukul-rathi/bolt/1faf19d698852fdb6af2ee005a5f036ee1c76503/tests/frontend/expect/typing/bad_function_defn.ml
ocaml
open Core open Print_typed_ast let%expect_test "Function args in wrong order" = print_typed_ast " class Foo { capability linear Bar; var int f : Bar; } function int f (int z, Foo y) { z } void main(){ let y = new Foo(); f(y, 4) // Error - args in wrong order ...
9226c9343959afcee417e8f84a9b829e25ae63f0b499dc4e84dc88d05ef4bc38
esl/MongooseIM
service_admin_extra.erl
%%%------------------------------------------------------------------- %%% File : service_admin_extra.erl Author : > , < > %%% Purpose : Contributed administrative functions and commands Created : 10 Aug 2008 by > %%% %%% ejabberd , Copyright ( C ) 2002 - 2008 ProcessOne %%% %%% This program is f...
null
https://raw.githubusercontent.com/esl/MongooseIM/a465408fcc98a171cbfbcad242dedbdb5abb022d/src/admin_extra/service_admin_extra.erl
erlang
------------------------------------------------------------------- File : service_admin_extra.erl Purpose : Contributed administrative functions and commands This program is free software; you can redistribute it and/or License, or (at your option) any later version. This program is distributed in the hope...
Author : > , < > Created : 10 Aug 2008 by > ejabberd , Copyright ( C ) 2002 - 2008 ProcessOne modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the You should have received a copy of the GNU General Public License F...
340b96f5f4445d7d904aa419a020de8f69edc593d2fc59bf9fe6cdd1a93f504e
weblocks-framework/weblocks
suggest.lisp
(in-package :weblocks) (export '(render-suggest)) (declaim (special *max-raw-input-length*)) ;early (defun render-suggest (input-name resultset &key default-value (input-id (gensym)) (choices-id (gensym)) (format-fn #'format...
null
https://raw.githubusercontent.com/weblocks-framework/weblocks/fe96152458c8eb54d74751b3201db42dafe1708b/src/utils/suggest.lisp
lisp
early
(in-package :weblocks) (export '(render-suggest)) (defun render-suggest (input-name resultset &key default-value (input-id (gensym)) (choices-id (gensym)) (format-fn #'format-suggest-list) (max-length ...
f1574e7808f6753c196ff1df5369e75b9e1555625c9f0ade6d286d677625feeb
singpolyma/cheogram
UniquePrefix.hs
module UniquePrefix where import Data.List import qualified Data.Set as S import qualified Data.Text as T import qualified Data.CaseInsensitive as CI uniquePrefix txts = helper [] $ map (S.fromList . map CI.mk . tail . T.inits) txts helper done (prefixes:otherPrefixes) = (foldl' S.difference prefixes (done ++ other...
null
https://raw.githubusercontent.com/singpolyma/cheogram/d46daa6fdef9d53cb0d44a8be62c4b613fac82e6/UniquePrefix.hs
haskell
ALT:
module UniquePrefix where import Data.List import qualified Data.Set as S import qualified Data.Text as T import qualified Data.CaseInsensitive as CI uniquePrefix txts = helper [] $ map (S.fromList . map CI.mk . tail . T.inits) txts helper done (prefixes:otherPrefixes) = (foldl' S.difference prefixes (done ++ other...
f2e75a2a49a8e66e9ad2860cffa1c3983caacef9d7b97005e1cbba523ea57baa
zero-one-group/geni
column.clj
(ns zero-one.geni.core.column (:refer-clojure :exclude [* + - / < <= = > >= ...
null
https://raw.githubusercontent.com/zero-one-group/geni/4dbabf8315d85cc1526e04bca7e4cb7b75c21ac1/src/clojure/zero_one/geni/core/column.clj
clojure
Column Methods Sorting Functions Java Expressions Support Functions Shortcut Functions Aliases
(ns zero-one.geni.core.column (:refer-clojure :exclude [* + - / < <= = > >= ...
04f46092c20a2067ae0710a251ca711f8156399f88d4b4e4094b2605c67ec2a8
input-output-hk/cardano-rt-view
OwnInfo.hs
# LANGUAGE CPP # # LANGUAGE LambdaCase # # LANGUAGE RecordWildCards # module Cardano.RTView.GUI.Markup.OwnInfo ( mkOwnInfo ) where import Control.Monad (forM, void) import Data.List (find, intersperse) import qualified Data.Text as T import Data.Version (showVersion) import ...
null
https://raw.githubusercontent.com/input-output-hk/cardano-rt-view/0ff669a5acc8d81a35aa5a924cbb79978d0999a8/src/Cardano/RTView/GUI/Markup/OwnInfo.hs
haskell
# LANGUAGE CPP # # LANGUAGE LambdaCase # # LANGUAGE RecordWildCards # module Cardano.RTView.GUI.Markup.OwnInfo ( mkOwnInfo ) where import Control.Monad (forM, void) import Data.List (find, intersperse) import qualified Data.Text as T import Data.Version (showVersion) import ...
fb483f6d6bf70458f521e40b1e1aa1362568cb0d1659dc28e52406c810046a0d
ryanpbrewster/haskell
trailing_string.hs
-- trailing_string.hs - You are given two strings ' A ' and ' B ' . Print out a 1 if string ' B ' occurs at the end of string ' A ' . Else a zero . - Input sample : - - The first argument is a file , containing two strings , comma delimited , one per line . Ignore all empty lines in the input file.e.g . ...
null
https://raw.githubusercontent.com/ryanpbrewster/haskell/6edd0afe234008a48b4871032dedfd143ca6e412/CodeEval/trailing_string.hs
haskell
trailing_string.hs
- You are given two strings ' A ' and ' B ' . Print out a 1 if string ' B ' occurs at the end of string ' A ' . Else a zero . - Input sample : - - The first argument is a file , containing two strings , comma delimited , one per line . Ignore all empty lines in the input file.e.g . - - Hello World , W...
5ce1fee76b46488a73c189c1747b4d5f3adc58f255e0325674ae6b75edb91c2f
avsm/ocaml-orm-sqlite
nested_tuple.ml
TYPE_CONV_PATH "Nested_tuple" type x = { foo: (int32 * int64 * string * (string * bool option)); bar: string * char; } with orm open OUnit open Test_utils let x = {foo=(5l, 10L, "tt", ("xx", Some true)) ; bar=("hello",'w') } let name = "nested_tuple.db" let test_init () = ignore(open_db x_init name); ignor...
null
https://raw.githubusercontent.com/avsm/ocaml-orm-sqlite/0c41dee6e254abd75706edcb785f657bfe55d08b/lib_test/nested_tuple.ml
ocaml
TYPE_CONV_PATH "Nested_tuple" type x = { foo: (int32 * int64 * string * (string * bool option)); bar: string * char; } with orm open OUnit open Test_utils let x = {foo=(5l, 10L, "tt", ("xx", Some true)) ; bar=("hello",'w') } let name = "nested_tuple.db" let test_init () = ignore(open_db x_init name); ignor...
9784b37f56aadf37f9997316d73d9afe5755e145a1cd210606791d0ae6e3e3cf
cdsmith/explainable-predicates
Util.hs
# LANGUAGE CPP # # LANGUAGE DeriveFunctor # # LANGUAGE FlexibleContexts # | Internal utilities used for HMock implementation . module Test.Predicates.Internal.Util where import Data.Generics (Data, everywhere, mkT) import GHC.Stack (CallStack, getCallStack, prettySrcLoc) import Language.Haskell.TH.Syntax (NameFlavo...
null
https://raw.githubusercontent.com/cdsmith/explainable-predicates/926298136528b73e551e6c9403910a38d5056425/src/Test/Predicates/Internal/Util.hs
haskell
| A value together with its source location. | Annotates a value with its source location from the call stack. | Formats a 'Located' 'String' to include its source location. remaining list. that it will pretty-print more cleanly.
# LANGUAGE CPP # # LANGUAGE DeriveFunctor # # LANGUAGE FlexibleContexts # | Internal utilities used for HMock implementation . module Test.Predicates.Internal.Util where import Data.Generics (Data, everywhere, mkT) import GHC.Stack (CallStack, getCallStack, prettySrcLoc) import Language.Haskell.TH.Syntax (NameFlavo...
14be29b70345caca7691e8efe0696a2765d1ebed66c6db1d65cc31452eea33ab
titola/incudine
base.lisp
Copyright ( c ) 2013 - 2021 ;;; ;;; This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation ; either version 2 of the License , or ;;; (at your option) any later version. ;;; ;;; This program is distri...
null
https://raw.githubusercontent.com/titola/incudine/57f5b259148b91a90245cef32e280721d7c27bac/src/analysis/base.lisp
lisp
This program is free software; you can redistribute it and/or modify either version 2 of the License , or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR...
Copyright ( c ) 2013 - 2021 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 Foundation , Inc. , 51 Franklin St , Fifth Floor , Boston , MA 02110 - 1301 USA (in-package :incudine.analysis) Inspired by the UAna object...
e8f429f87d1c254ecbabd9d0f6d661663d839c486530d66ee3df47aacbd32d68
hemmi/coq2scala
typeclasses_errors.mli
(************************************************************************) v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2012 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *...
null
https://raw.githubusercontent.com/hemmi/coq2scala/d10f441c18146933a99bf2088116bd213ac3648d/coq-8.4pl2-old/pretyping/typeclasses_errors.mli
ocaml
********************************************************************** // * This file is distributed under the terms of the * GNU Lesser General Public License Version 2.1 ********************************************************************** * Class name, method * found, expec...
v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2012 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * open Names open Decl_kinds op...
1125a1eb17259e6ccb3d6a48db95f8a4302537dfbdb5d43badeb1571466240b4
Javran/advent-of-code
Day3.hs
module Javran.AdventOfCode.Y2018.Day3 ( ) where import qualified Data.IntSet as IS import qualified Data.Map.Strict as M import Javran.AdventOfCode.Prelude import Text.ParserCombinators.ReadP hiding (count, get, many) data Day3 deriving (Generic) type Claim = (Int, ((Int, Int), (Int, Int))) claimP :: ReadP Claim ...
null
https://raw.githubusercontent.com/Javran/advent-of-code/676ef13c2f9d341cf7de0f383335a1cf577bd73d/src/Javran/AdventOfCode/Y2018/Day3.hs
haskell
module Javran.AdventOfCode.Y2018.Day3 ( ) where import qualified Data.IntSet as IS import qualified Data.Map.Strict as M import Javran.AdventOfCode.Prelude import Text.ParserCombinators.ReadP hiding (count, get, many) data Day3 deriving (Generic) type Claim = (Int, ((Int, Int), (Int, Int))) claimP :: ReadP Claim ...
5163d92703db4ea9ff476a8c1a60d7ee3198552dc4c1aaab6bac3c39909cca85
lopec/LoPEC
io_module.erl
%%%------------------------------------------------------------------- @author < > @author ( C ) 2009 , , %%% @doc %%% Deals with the temporary storage in the cluster. Gets a binary %%% stream of data to write or returns the binary stream of data. %%% %%% @end Created : 1 Dec 2009 by < > %%%------...
null
https://raw.githubusercontent.com/lopec/LoPEC/29a3989c48a60e5990615dea17bad9d24d770f7b/trunk/lib/common/src/io_module.erl
erlang
------------------------------------------------------------------- @doc Deals with the temporary storage in the cluster. Gets a binary stream of data to write or returns the binary stream of data. @end ------------------------------------------------------------------- API gen_server callbacks =================...
@author < > @author ( C ) 2009 , , Created : 1 Dec 2009 by < > -module(io_module). -behaviour(gen_server). -export([start_link/2, stop/0, put/3, get/2]). -export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). start_link(ModuleName::atom ( ) , A...
451f5bb2c761a7582fab1ef395067594c005b652fe3c3ea704e48a0798411a4d
typelead/etlas
AbiHash.hs
{-# LANGUAGE DeriveDataTypeable #-} # LANGUAGE DeriveGeneric # # LANGUAGE GeneralizedNewtypeDeriving # module Distribution.Types.AbiHash ( AbiHash, unAbiHash, mkAbiHash ) where import Prelude () import Distribution.Compat.Prelude import Distribution.Utils.ShortText import qualified Distribution.Compat.ReadP as P...
null
https://raw.githubusercontent.com/typelead/etlas/bbd7c558169e1fda086e759e1a6f8c8ca2807583/etlas-cabal/Distribution/Types/AbiHash.hs
haskell
# LANGUAGE DeriveDataTypeable # | ABI Hashes Use 'mkAbiHash' and 'unAbiHash' to convert from/to a 'String'. This type is opaque since @Cabal-2.0@ @since 2.0 'mkAbiHash' is the inverse to 'unAbiHash' Note: No validations are performed to ensure that the resulting @since 2.0 | Convert 'AbiHash' to 'String'...
# LANGUAGE DeriveGeneric # # LANGUAGE GeneralizedNewtypeDeriving # module Distribution.Types.AbiHash ( AbiHash, unAbiHash, mkAbiHash ) where import Prelude () import Distribution.Compat.Prelude import Distribution.Utils.ShortText import qualified Distribution.Compat.ReadP as Parse import qualified Text.PrettyPri...
9bef116aa127f70c8ba001a30c0831d4466cd2f4ba13dd0092fa5f546a8eb5cb
proof-ninja/ocaml-blake3
blake3.mli
val hash: int -> bytes -> bytes val hash_multicore: int -> bytes -> bytes
null
https://raw.githubusercontent.com/proof-ninja/ocaml-blake3/b83e491d2b71712c237264ec118b318e14176069/src/blake3.mli
ocaml
val hash: int -> bytes -> bytes val hash_multicore: int -> bytes -> bytes
2fb286bbfaa31660840106e9b9accecb05d53a3f1e25711330407beae7078641
mfoemmel/erlang-otp
wxBufferedDC.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 2008 - 2009 . All Rights Reserved . %% The contents of this file are subject to the Erlang Public License , Version 1.1 , ( the " License " ) ; you may not use this file except in %% compliance with the License. You should have received a copy of the %% Erlang Pub...
null
https://raw.githubusercontent.com/mfoemmel/erlang-otp/9c6fdd21e4e6573ca6f567053ff3ac454d742bc2/lib/wx/src/gen/wxBufferedDC.erl
erlang
%CopyrightBegin% compliance with the License. You should have received a copy of the Erlang Public License along with this software. If not, it can be retrieved online at /. basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limita...
Copyright Ericsson AB 2008 - 2009 . All Rights Reserved . The contents of this file are subject to the Erlang Public License , Version 1.1 , ( the " License " ) ; you may not use this file except in Software distributed under the License is distributed on an " AS IS " -module(wxBufferedDC). -include("wxe.hrl"...
d0b77eef4afd72fc34c8958e4141d5d35c13268b56e87f77832d2981a2008758
janestreet/core_bench
quota.ml
open Core type t = | Span of Time_float.Span.t | Num_calls of int [@@deriving sexp] let int_of_string_with_scientific_notation string = try Int.of_string string with | _ -> let float = Float.of_string string in let int = Float.to_int float in if Float.equal float (Float.of_int int) then int ...
null
https://raw.githubusercontent.com/janestreet/core_bench/6ef00935febc215cec376af9349078828498a748/internals/quota.ml
ocaml
open Core type t = | Span of Time_float.Span.t | Num_calls of int [@@deriving sexp] let int_of_string_with_scientific_notation string = try Int.of_string string with | _ -> let float = Float.of_string string in let int = Float.to_int float in if Float.equal float (Float.of_int int) then int ...
7729e048e7e892ffa45da1ed8c7f75104d82d1ff46e7735d14b2af5de68e91ea
actondev/s7-reaper
gui2.scm
(ns rootlet :require ((aod.c.imgui :as ig) (aod.imgui.macros :as igm))) (print "hi from gui2.scm") (define (draw) ;; (print "here drawing!!") ;; huh.. if I call begin it crashes (ig/begin "gui 2") (ig/text "hi there") (ig/end))
null
https://raw.githubusercontent.com/actondev/s7-reaper/4e407e72c3e08b5a984b351fd2c355f0bb560e8e/src/scheme/gui2.scm
scheme
(print "here drawing!!") huh.. if I call begin it crashes
(ns rootlet :require ((aod.c.imgui :as ig) (aod.imgui.macros :as igm))) (print "hi from gui2.scm") (define (draw) (ig/begin "gui 2") (ig/text "hi there") (ig/end))
cb197a3adb7a73cf34fc25b5cc1c81f67e9a5324f1252475af6ba3ee2a205605
ocaml-sf/learn-ocaml-corpus
choose_right.ml
let return (x : 'a) : 'a m = let compute s f = s x f in { compute } let (>>=) (m1 : 'a m) (f2 : 'a -> 'b m) : 'b m = let compute s f = m1.compute (fun x f' -> (f2 x).compute s f') f in { compute } let fail : 'a m = let compute s f = f() in { compute } let choose (m1 : 'a m) (m2 : 'a m) : 'a m = m2 (* w...
null
https://raw.githubusercontent.com/ocaml-sf/learn-ocaml-corpus/7dcf4d72b49863a3e37e41b3c3097aa4c6101a69/exercises/fpottier/nondet_monad_cont/wrong/choose_right.ml
ocaml
wrong The functions [reflect] and [msplit] witness an isomorphism between the type ['a m] and the type [unit -> ('a * 'a m) option].
let return (x : 'a) : 'a m = let compute s f = s x f in { compute } let (>>=) (m1 : 'a m) (f2 : 'a -> 'b m) : 'b m = let compute s f = m1.compute (fun x f' -> (f2 x).compute s f') f in { compute } let fail : 'a m = let compute s f = f() in { compute } let choose (m1 : 'a m) (m2 : 'a m) : 'a m = let sols...
561c2d72679cbd8b52895885aebbd3c04239f2bdcbc0d2a4e28ca0f970842548
jimcrayne/jhc
tc136.hs
{-# OPTIONS -fglasgow-exts #-} -- !!! scoped type variables this test failed in pre - release GHC 5.02 module ShouldCompile where f :: forall x. x -> x -> x f (x::x) (y::x) = x Two points : ( a ) we are using x as a term variable and as a type variable -- (b) the type variable appears twice, but that is O...
null
https://raw.githubusercontent.com/jimcrayne/jhc/1ff035af3d697f9175f8761c8d08edbffde03b4e/regress/tests/1_typecheck/2_pass/ghc/tc136.hs
haskell
# OPTIONS -fglasgow-exts # !!! scoped type variables (b) the type variable appears twice, but that is OK
this test failed in pre - release GHC 5.02 module ShouldCompile where f :: forall x. x -> x -> x f (x::x) (y::x) = x Two points : ( a ) we are using x as a term variable and as a type variable
cdad654188eb7d4c21f6ce06cbe2e51ff513c0c0f7591dfacd2e1149805e419c
clojure/test.check
runner.cljs
(ns clojure.test.check.test.runner (:require [cljs.test :as test :refer-macros [run-tests]] [clojure.test.check.generators :as gen] [clojure.test.check.test] [clojure.test.check.random-test] [clojure.test.check.rose-tree-test] [clojure.test.check.clojure-tes...
null
https://raw.githubusercontent.com/clojure/test.check/c05034f911fa140913958b79aa51017d3f2f4426/src/target/cljs/browser/clojure/test/check/test/runner.cljs
clojure
(ns clojure.test.check.test.runner (:require [cljs.test :as test :refer-macros [run-tests]] [clojure.test.check.generators :as gen] [clojure.test.check.test] [clojure.test.check.random-test] [clojure.test.check.rose-tree-test] [clojure.test.check.clojure-tes...
d59f7b3f1de3f15fa52d8bd14c8150b4a487a11093b4b6b4ec0ce66ddb091786
bnomis/om-next-datascript-localisation-demo
logging.cljc
(ns om-next-datascript-localisation-demo.logging) ;; change this def to true/false to turn logging on/off ;; when off, all logging is removed from code (def logging-is-on true) (defmacro log [& args] `(when logging-is-on (js/console.log (apply str (interpose " " (list ~@args)))))) (defmacro log-env [env] `(w...
null
https://raw.githubusercontent.com/bnomis/om-next-datascript-localisation-demo/be9a77e0a040896533f79f86cdbd115c19ab3c9f/src/om_next_datascript_localisation_demo/logging.cljc
clojure
change this def to true/false to turn logging on/off when off, all logging is removed from code throwing an exception is a handy way to get a stack trace (try (throw (js/Error. "read")) (catch js/Error e (log (.-stack e)))) throwing an exception is a handy way to get a stack trace (try (throw (js/Error. "mutate")) ...
(ns om-next-datascript-localisation-demo.logging) (def logging-is-on true) (defmacro log [& args] `(when logging-is-on (js/console.log (apply str (interpose " " (list ~@args)))))) (defmacro log-env [env] `(when logging-is-on (log "- env contains:" (keys ~env)) (doseq [k# [:path :pathopt :ref :ast :co...
d815e2fc1dae4e192fe19e2f71182f01334e8cb3d56833acc0be6bf7664bac68
footprintanalytics/footprint-web
setup.clj
(ns metabase.api.setup (:require [clojure.tools.logging :as log] [compojure.core :refer [GET POST]] [java-time :as t] [metabase.analytics.snowplow :as snowplow] [metabase.api.common :as api] [metabase.api.common.validation :as validation] [metaba...
null
https://raw.githubusercontent.com/footprintanalytics/footprint-web/d3090d943dd9fcea493c236f79e7ef8a36ae17fc/src/metabase/api/setup.clj
clojure
redefined by them then we create a session right away because we want our new user logged in to continue the setup process return user ID, session ID, and the Session object itself set a couple preferences default to `true` if allow_tracking isn't specified. The setting will set itself correctly whether a boolean ...
(ns metabase.api.setup (:require [clojure.tools.logging :as log] [compojure.core :refer [GET POST]] [java-time :as t] [metabase.analytics.snowplow :as snowplow] [metabase.api.common :as api] [metabase.api.common.validation :as validation] [metaba...
c0cd1625a04e9c38dddda35dc976f469f931c83ef9ad4317ccd11e70d52d81da
ocsigen/js_of_ocaml
empty_cma.ml
Js_of_ocaml tests * / * Copyright ( C ) 2019 * * This program is free software ; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation ; either version 2 of the License , or * ( at your option ) any later vers...
null
https://raw.githubusercontent.com/ocsigen/js_of_ocaml/76035911e9b9145937e698feb5bea8f823fb3f12/compiler/tests-compiler/empty_cma.ml
ocaml
Js_of_ocaml tests * / * Copyright ( C ) 2019 * * This program is free software ; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation ; either version 2 of the License , or * ( at your option ) any later vers...
d23fadd250c1206abb7deb02d396224a3cd7545980cefce64f89d76553ac6380
yesodweb/shakespeare
BuilderQQ.hs
{-# LANGUAGE TemplateHaskellQuotes #-} module Text.Shakespeare.BuilderQQ (builderQQ) where import Prelude import Language.Haskell.TH.Quote (QuasiQuoter(..)) import Language.Haskell.TH.Syntax (Exp(..)) import Text.Shakespeare import Text.Shakespeare.Text (ToText(..)) builderQQ :: QuasiQuoter builderQQ = shakespeare ...
null
https://raw.githubusercontent.com/yesodweb/shakespeare/edf4f194a1b89d4654f719ae221aded675899b0d/test/Text/Shakespeare/BuilderQQ.hs
haskell
# LANGUAGE TemplateHaskellQuotes #
module Text.Shakespeare.BuilderQQ (builderQQ) where import Prelude import Language.Haskell.TH.Quote (QuasiQuoter(..)) import Language.Haskell.TH.Syntax (Exp(..)) import Text.Shakespeare import Text.Shakespeare.Text (ToText(..)) builderQQ :: QuasiQuoter builderQQ = shakespeare $ defaultShakespeareSettings ...
d0347ee6954b34aa002f875c651ec44e16551c0a3044b7179e34c4fea4494430
sharplispers/montezuma
segment-term-vector.lisp
(in-package #:montezuma) (defclass segment-term-vector () ((field :initarg :field :reader field) (terms :initarg :terms :reader terms) (term-frequencies :initarg :term-frequencies :reader term-frequencies) (positions :initarg :positions :reader positions) (offsets :initarg :offsets :reader offsets))) (d...
null
https://raw.githubusercontent.com/sharplispers/montezuma/ee2129eece7065760de4ebbaeffaadcb27644738/src/index/segment-term-vector.lisp
lisp
(in-package #:montezuma) (defclass segment-term-vector () ((field :initarg :field :reader field) (terms :initarg :terms :reader terms) (term-frequencies :initarg :term-frequencies :reader term-frequencies) (positions :initarg :positions :reader positions) (offsets :initarg :offsets :reader offsets))) (d...
0d82cc6bea6649adb9f41a6e10833304c9c037f6bebd605bea7c7ccf85164740
samoht/camloo
liblist.scm
;; !!! generated file, don't edit !!! ;; ================================== ;; TODO 25/06/10: auto-generate this file (module lib_module_list (export *lib-module-list*)) (define *lib-module-list* '("bool" "bigloo" "ref" "sys" "obj" "iparsing" "unix" "handle" "bio" "bint" "bstring" "bmisc" "sys" "bfloat" "tag" "intext...
null
https://raw.githubusercontent.com/samoht/camloo/29a578a152fa23a3125a2a5b23e325b6d45d3abd/src/camloo/Llib/liblist.scm
scheme
!!! generated file, don't edit !!! ================================== TODO 25/06/10: auto-generate this file
(module lib_module_list (export *lib-module-list*)) (define *lib-module-list* '("bool" "bigloo" "ref" "sys" "obj" "iparsing" "unix" "handle" "bio" "bint" "bstring" "bmisc" "sys" "bfloat" "tag" "intext" "eq" "exc" "list" "int" "fstring" "fchar" "string" "char" "fvect" "vect" "filename" "float" "pair" "random" "baltree...
fd4e4411243e52dad5ced27def2b8e46cb20e634f7420d68b0fdfbfa1c036101
r0man/google-maps-clj
location.clj
(ns google.maps.location) (defrecord Location [latitude longitude altitude]) (defn make-location [latitude longitude & [altitude]] (Location. latitude longitude altitude)) (defn location? "Returns true if arg is a location, otherwise false." [arg] (and (:latitude arg) (:longitude arg))) (defn format-location ...
null
https://raw.githubusercontent.com/r0man/google-maps-clj/75467cd366fad1250ac78f07e4796c254d09f36a/src/google/maps/location.clj
clojure
(ns google.maps.location) (defrecord Location [latitude longitude altitude]) (defn make-location [latitude longitude & [altitude]] (Location. latitude longitude altitude)) (defn location? "Returns true if arg is a location, otherwise false." [arg] (and (:latitude arg) (:longitude arg))) (defn format-location ...
82d13d9a8221397c0ef31fcddf4600f52a82f683a7a5ba9baa6447c3da6beaf5
clojure/core.typed
instant.clj
(ns clojure.core.typed.test.instant (:require [clojure.core.typed :as t] [clojure.test :refer :all] [clojure.core.typed.test.test-utils :refer :all])) (deftest read-instant-date-test (is-tc-e (read-instant-date "2014-04-23T10:13Z") java.util.Date :requires...
null
https://raw.githubusercontent.com/clojure/core.typed/f5b7d00bbb29d09000d7fef7cca5b40416c9fa91/typed/checker.jvm/test/clojure/core/typed/test/instant.clj
clojure
(ns clojure.core.typed.test.instant (:require [clojure.core.typed :as t] [clojure.test :refer :all] [clojure.core.typed.test.test-utils :refer :all])) (deftest read-instant-date-test (is-tc-e (read-instant-date "2014-04-23T10:13Z") java.util.Date :requires...
a6fe57819fe49b9ea321474d4efc381840ffa03e02cd6b37eec90728b04bd3f3
ocheron/cryptostore
Parse.hs
-- | Module : Crypto . Store . -- License : BSD-style Maintainer : < > -- Stability : experimental -- Portability : unknown -- Parser combinators for ASN.1 stream . Similar to " Data . " but -- with the following additions: -- * stream is annotated , i.e. parser input is @('ASN1 ' , e)@ in...
null
https://raw.githubusercontent.com/ocheron/cryptostore/a9c5ad06bdc4197663ba933b0a62c3c33cf92a17/src/Crypto/Store/ASN1/Parse.hs
haskell
| License : BSD-style Stability : experimental Portability : unknown with the following additions: and hold the exact binary content that has been parsed. As consequence, no @getObject@ function is provided. Function 'withAnnotations' runs a parser and returns all annotations consumed in a monoi...
Module : Crypto . Store . Maintainer : < > Parser combinators for ASN.1 stream . Similar to " Data . " but * stream is annotated , i.e. parser input is @('ASN1 ' , e)@ instead of @'ASN1'@. Main motivation is to allow to parse a sequence of ' ASN1Repr ' * The parser implements ' Alternati...
d51f3038bfa6bda2d2d49189cce1749185c9f22bbb696856be24ed2da486b63c
threatgrid/ctia
routes.clj
(ns ctia.bundle.routes (:refer-clojure :exclude [identity]) (:require [clojure.string :as str] [ctia.lib.compojure.api.core :refer [GET POST context routes]] [ctia.bundle.core :refer [bundle-max-size bundle-size import-bundle ...
null
https://raw.githubusercontent.com/threatgrid/ctia/8e306e63428d620d101ff9ce6e2eaf6ebf97b41b/src/ctia/bundle/routes.clj
clojure
(ns ctia.bundle.routes (:refer-clojure :exclude [identity]) (:require [clojure.string :as str] [ctia.lib.compojure.api.core :refer [GET POST context routes]] [ctia.bundle.core :refer [bundle-max-size bundle-size import-bundle ...
81fa4fc2fb6aa6e93500e7a2ff1ed88795183c0b1b2726ee91772825d8069aca
sheepduke/chameleon
chameleon.lisp
(defpackage chameleon-tests (:use #:cl) (:local-nicknames (#:config #:chameleon-tests.config)) (:import-from #:fiveam #:signals #:is #:test #:def-suite*)) (in-package chameleon-tests) (def-suite* chameleon) (test defconfig (config:with-profile :...
null
https://raw.githubusercontent.com/sheepduke/chameleon/f4519edf6993d654aa3e8178a1710537a49d6619/tests/chameleon.lisp
lisp
Setup Test Tear down
(defpackage chameleon-tests (:use #:cl) (:local-nicknames (#:config #:chameleon-tests.config)) (:import-from #:fiveam #:signals #:is #:test #:def-suite*)) (in-package chameleon-tests) (def-suite* chameleon) (test defconfig (config:with-profile :...
895d24603ae2181a321ef5ec9b11139d642087fc305f2ed0aa7aaae50540ce7d
bmeurer/ocamljit2
options.ml
(***********************************************************************) (* ocamlbuild *) (* *) , , projet Gallium , INRIA Rocquencourt (* ...
null
https://raw.githubusercontent.com/bmeurer/ocamljit2/ef06db5c688c1160acc1de1f63c29473bcd0055c/ocamlbuild/options.ml
ocaml
********************************************************************* ocamlbuild ...
, , projet Gallium , INRIA Rocquencourt Copyright 2007 Institut National de Recherche en Informatique et en Automatique . All rights reserved . This file is distributed under the terms of the Q Public License version 1.0 . Original author : let version = "ocamlbuild "^(S...
31fc292c7bcd7636f95179849d71542e6bbbf8abba4a55683276f8d0a26398b0
valerauko/kitsune-alpha
attachment.clj
(ns kitsune.spec.mastodon.attachment (:require [clojure.spec.alpha :as s] [kitsune.spec.common :as common])) (s/def ::shortcode string?) (s/def ::static-url ::common/url) (s/def ::emoji (s/keys :req-un [::shortcode ::common/url ::static-url])) (s/def ::type #{"image" "video" "gifv" "unknown"}) (s/def ...
null
https://raw.githubusercontent.com/valerauko/kitsune-alpha/34ca08e4013541aeaf1a5a5786f3189ff17c1a58/src/kitsune/spec/mastodon/attachment.clj
clojure
TODO: this gonna need some investigation
(ns kitsune.spec.mastodon.attachment (:require [clojure.spec.alpha :as s] [kitsune.spec.common :as common])) (s/def ::shortcode string?) (s/def ::static-url ::common/url) (s/def ::emoji (s/keys :req-un [::shortcode ::common/url ::static-url])) (s/def ::type #{"image" "video" "gifv" "unknown"}) (s/def ...
919b00eaa2621c069476025270afe26132c8f84985e12746b99b985270433419
synduce/Synduce
Tuples.mli
val type_name_of_types : RType.t list -> string val constr_name_of_types : RType.t list -> string val is_constr_name : string -> bool val type_name_of_constr : string -> string option val proj_name_of_types : RType.t list -> int -> string val types_of_tuple_name : string -> RType.t list option val type_name_of_proj_nam...
null
https://raw.githubusercontent.com/synduce/Synduce/d453b04cfb507395908a270b1906f5ac34298d29/src/lang/Tuples.mli
ocaml
val type_name_of_types : RType.t list -> string val constr_name_of_types : RType.t list -> string val is_constr_name : string -> bool val type_name_of_constr : string -> string option val proj_name_of_types : RType.t list -> int -> string val types_of_tuple_name : string -> RType.t list option val type_name_of_proj_nam...
a5f99e5d3a95ed0f7f1bda610d324cfddb9df55ad14c979c6957c3a7180e45c2
tsoding/multik
swirl.ml
module Swirl : Animation.T = struct let fps = 60 let resolution = (1920, 1080) let center (p: Picture.t): Picture.t = let w, h = resolution in let half_w, half_h = (float_of_int w *. 0.5, float_of_int h *. 0.5) in p |> Picture.translate (half_w, half_h) let background : Picture.t =...
null
https://raw.githubusercontent.com/tsoding/multik/15384bd44c607f1b76c625ef97c01ad50a155cdc/samples/swirl.ml
ocaml
Picture.Circle 10.0
module Swirl : Animation.T = struct let fps = 60 let resolution = (1920, 1080) let center (p: Picture.t): Picture.t = let w, h = resolution in let half_w, half_h = (float_of_int w *. 0.5, float_of_int h *. 0.5) in p |> Picture.translate (half_w, half_h) let background : Picture.t =...
65f425a0b61e318567f76414f755ef0caddef47ae42dcee38a99a60f6731ac94
LeventErkok/sbvPlugin
T05.hs
{-# OPTIONS_GHC -fplugin=Data.SBV.Plugin #-} module T05 where import Data.SBV.Plugin # ANN f theorem { options = [ IgnoreFailure , CVC4 ] } # f :: Integer -> Integer -> Bool f x y = x + y >= x - y
null
https://raw.githubusercontent.com/LeventErkok/sbvPlugin/b6a6e94cd237a4f64f985783931bd7656e7a6a69/tests/T05.hs
haskell
# OPTIONS_GHC -fplugin=Data.SBV.Plugin #
module T05 where import Data.SBV.Plugin # ANN f theorem { options = [ IgnoreFailure , CVC4 ] } # f :: Integer -> Integer -> Bool f x y = x + y >= x - y
1e919580c83a421388baad03ee77b1982962fba0ede64d5602f0693f003b338e
wilbowma/cur
issue-71.rkt
#lang cur (require cur/stdlib/sugar rackunit/turnstile+) Paulin - Mohring equality . A good test of proper parameter / index handling (data pm= : 2 (Π (A : (Type 0)) (Π (a : A) (Π (b : A) (Type 0)))) (pm-refl : (Π (A : (Type 0)) (Π (a : A) (pm= A a a))))) (define pm-sym (λ [A : (Type 0)] (λ [x ...
null
https://raw.githubusercontent.com/wilbowma/cur/e039c98941b3d272c6e462387df22846e10b0128/cur-test/cur/tests/issue-71.rkt
racket
pm= symmetric
#lang cur (require cur/stdlib/sugar rackunit/turnstile+) Paulin - Mohring equality . A good test of proper parameter / index handling (data pm= : 2 (Π (A : (Type 0)) (Π (a : A) (Π (b : A) (Type 0)))) (pm-refl : (Π (A : (Type 0)) (Π (a : A) (pm= A a a))))) (define pm-sym (λ [A : (Type 0)] (λ [x ...
c16c079302395564215878692e64f865c6ae285bd1f3278fcf031a6c7a6e52bc
fterrier/pylos
handlers.clj
(ns system.handlers (:require [com.stuartsierra.component :as component] [server.handlers.websockets :refer [websockets-handler]] [server.handlers.telegram :refer [telegram-handler]] [server.handlers.handler :refer [start-handler stop-ha...
null
https://raw.githubusercontent.com/fterrier/pylos/f9283cf58a32000ed271e768ab6151ac081ed37d/src/clj/system/handlers.clj
clojure
(ns system.handlers (:require [com.stuartsierra.component :as component] [server.handlers.websockets :refer [websockets-handler]] [server.handlers.telegram :refer [telegram-handler]] [server.handlers.handler :refer [start-handler stop-ha...
7100a1f5d9a0a89af7cd38eb6c0dae490f0438d11e9275987fdcb16f48d8de52
SamirTalwar/advent-of-code
AOC_03_1.hs
import qualified Data.Char as Char import qualified Data.Set as Set data Direction = North | East | South | West deriving (Eq, Show) type Coordinates = (Int, Int) main = do directions <- parseInput <$> trim <$> getContents let visitedLocations = Set.fromList $ scanl (flip apply) (0, 0) directions print $ Set...
null
https://raw.githubusercontent.com/SamirTalwar/advent-of-code/66bd9e31f078c9b81ece0264fb869e48964afa63/2015/AOC_03_1.hs
haskell
import qualified Data.Char as Char import qualified Data.Set as Set data Direction = North | East | South | West deriving (Eq, Show) type Coordinates = (Int, Int) main = do directions <- parseInput <$> trim <$> getContents let visitedLocations = Set.fromList $ scanl (flip apply) (0, 0) directions print $ Set...
25d50048623c5c53f6436d61465d153122ffa99c4582f5e974b6f50e41132caa
dimitri/ql-to-deb
main.lisp
;;; Update our debian packages with the latest known Quicklisp releases . ;;; (in-package #:ql-to-deb) (defparameter *commands* '(("status" "Compare versions (debian sid, local, Quicklisp)" status) ("check" "List packages that need building" check) ("update" "Build either packages or al...
null
https://raw.githubusercontent.com/dimitri/ql-to-deb/f89e91804ebbb1912001c1b1d45c157cf162608f/src/main.lisp
lisp
any error here is a panic Usage strings for commands print out the usage, whatever happens here
Update our debian packages with the latest known Quicklisp releases . (in-package #:ql-to-deb) (defparameter *commands* '(("status" "Compare versions (debian sid, local, Quicklisp)" status) ("check" "List packages that need building" check) ("update" "Build either packages or all that n...
1366d8222948b5d54e7c532d6d0759e26f036387c4c791b05acb6cb339f51888
ghc/testsuite
T4809_IdentityT.hs
# LANGUAGE MultiParamTypeClasses , TypeSynonymInstances , FlexibleInstances , TypeFamilies , GeneralizedNewtypeDeriving # # OPTIONS_GHC -fno - warn - orphans # module T4809_IdentityT ( evalIdentityT , IdentityT(..) , XML(..) ) where import Control.Monad (MonadPlus) import Control.Monad.Trans ...
null
https://raw.githubusercontent.com/ghc/testsuite/998a816ae89c4fd573f4abd7c6abb346cf7ee9af/tests/typecheck/should_run/T4809_IdentityT.hs
haskell
* IdentityT Monad Transformer * HSX.XMLGenerator for IdentityT
# LANGUAGE MultiParamTypeClasses , TypeSynonymInstances , FlexibleInstances , TypeFamilies , GeneralizedNewtypeDeriving # # OPTIONS_GHC -fno - warn - orphans # module T4809_IdentityT ( evalIdentityT , IdentityT(..) , XML(..) ) where import Control.Monad (MonadPlus) import Control.Monad.Trans ...
ea79b1226ada51dfb03dfdac2a24e809a2ae9f05ad3385c8b5f86fc3b11d9021
pariyatti/kosa
time.clj
(ns kuti.support.time (:refer-clojure :exclude [time]) (:require [tick.alpha.api :as t] [chime.core :as chime] [clojure.string :as s] [kuti.support.strings :refer [slice]]) (:import [java.time LocalDate ZonedDateTime ZoneId] [java.time.chrono Era IsoEra IsoChronology...
null
https://raw.githubusercontent.com/pariyatti/kosa/33b8aa3d1882839d5b38425f05233a4b354dac37/src/kuti/support/time.clj
clojure
but we cover them anyway to be explicit about our intention: dates and publishing: NOTE: I'm not actually sure this is a great idea. -sd
(ns kuti.support.time (:refer-clojure :exclude [time]) (:require [tick.alpha.api :as t] [chime.core :as chime] [clojure.string :as s] [kuti.support.strings :refer [slice]]) (:import [java.time LocalDate ZonedDateTime ZoneId] [java.time.chrono Era IsoEra IsoChronology...
0b5d5c39451676333a54f14743ef39696362e4d9644d2cd333d23678bd6b9fb5
anmonteiro/ocaml-quic
parse.ml
---------------------------------------------------------------------------- * Copyright ( c ) 2020 * * All rights reserved . * * Redistribution and use in source and binary forms , with or without * modification , are permitted provided that the following conditions are met : * * 1...
null
https://raw.githubusercontent.com/anmonteiro/ocaml-quic/6bcd5e4cb2da0a7b8a5274321f08771143373666/lib/parse.ml
ocaml
From RFC9000§19.3.1: * Thus, given a largest packet number for the range, the smallest value * is determined by the formula: * * smallest = largest - ack_range From RFC9000§19.1: * [...] a PADDING frame consists of the single byte that identifies * the frame as a PA...
---------------------------------------------------------------------------- * Copyright ( c ) 2020 * * All rights reserved . * * Redistribution and use in source and binary forms , with or without * modification , are permitted provided that the following conditions are met : * * 1...
9debe2e7f3cb295634933d775861dfe263adfe3e161e39aa1caf4cc70987618f
igarnier/prbnmcn-dagger
sprinkler.ml
open Dagger let () = if Helpers.produce_artifacts then Cgraph.Internal.set_debug true let rng_state = RNG.make [| 0x1337; 0x533D |] (* ------------------------------------------------------------------------- *) (* Using incremental inference *) module Traced_incremental = struct open Lmh_incremental_inference ...
null
https://raw.githubusercontent.com/igarnier/prbnmcn-dagger/360e196be3e28cbcc67691a1fd68f1cd93743e35/test/sprinkler.ml
ocaml
------------------------------------------------------------------------- Using incremental inference ------------------------------------------------------------------------- Using non-incremental inference
open Dagger let () = if Helpers.produce_artifacts then Cgraph.Internal.set_debug true let rng_state = RNG.make [| 0x1337; 0x533D |] module Traced_incremental = struct open Lmh_incremental_inference let bern = Stats_dist.bernoulli let model : bool t = let open Infix in let*! rain = sample (bern ~bias...
10fa28322805ba75bcbf32d0e6354b347992bdd458311952d718092507bd8ab6
nuprl/gradual-typing-performance
timeline.rkt
#lang racket/base (require pict ppict racket/list) (provide timeline-pict) (define *timeline-pict (inset (cc-superimpose (apply hc-append 30 (build-list 11 (λ (n) (vc-append 5 (blank 1 12) (...
null
https://raw.githubusercontent.com/nuprl/gradual-typing-performance/35442b3221299a9cadba6810573007736b0d65d4/paper/popl-2016/talk/timeline.rkt
racket
#lang racket/base (require pict ppict racket/list) (provide timeline-pict) (define *timeline-pict (inset (cc-superimpose (apply hc-append 30 (build-list 11 (λ (n) (vc-append 5 (blank 1 12) (...
01b9084924949232f889fe99b20a2d27e382a2198302f2a776c458dcd9ab36bc
jimpil/enclog
training.clj
(ns enclog.training (:import (org.encog.ml CalculateScore) (org.encog.neural.networks.training.simple TrainAdaline) (org.encog.neural.networks.training.propagation.back Backpropagation) (org.encog.neural.networks.training.propagation.manhattan ManhattanPropagation) (org...
null
https://raw.githubusercontent.com/jimpil/enclog/3281c0959090e1911ae5ea99feb886e0e8a645c8/src/enclog/training.clj
clojure
--------------------------------------*SOURCE*-------------------------------------------------------------------------------- ------------------------------------------------------------------------------------------------------------------------------ initialised empty initialised with train data initialised empty m...
(ns enclog.training (:import (org.encog.ml CalculateScore) (org.encog.neural.networks.training.simple TrainAdaline) (org.encog.neural.networks.training.propagation.back Backpropagation) (org.encog.neural.networks.training.propagation.manhattan ManhattanPropagation) (org...
90ff8cf0496a3783371f21e44ab921590664b6e4df6242ba31c673f7022ef90a
open-company/open-company-web
foc_menu.cljs
(ns oc.web.actions.foc-menu (:require [oc.web.dispatcher :as dis])) (defn toggle-foc-show-menu ([] (toggle-foc-show-menu nil)) ([v] (dis/dispatch! [:foc-show-menu v]))) (defn toggle-foc-menu-open ([] (toggle-foc-menu-open nil)) ([v] (dis/dispatch! [:foc-menu-open v]))) (defn toggle-foc-activity-move ...
null
https://raw.githubusercontent.com/open-company/open-company-web/700f751b8284d287432ba73007b104f26669be91/src/main/oc/web/actions/foc_menu.cljs
clojure
(ns oc.web.actions.foc-menu (:require [oc.web.dispatcher :as dis])) (defn toggle-foc-show-menu ([] (toggle-foc-show-menu nil)) ([v] (dis/dispatch! [:foc-show-menu v]))) (defn toggle-foc-menu-open ([] (toggle-foc-menu-open nil)) ([v] (dis/dispatch! [:foc-menu-open v]))) (defn toggle-foc-activity-move ...
6c4d5091ec0fa2c71f3a4b21c1d9977996472f8f1721d2fc2bc701a9347126e0
DavidAlphaFox/ailib
ai_pooled_task.erl
-module(ai_pooled_task). -export([checkin/1]). -export([async/1, async/2, async/3, async/4]). -export([await/1, await/2, safe_await/2, safe_await/3]). async(Fun) when erlang:is_function(Fun) -> Me = erlang:self(), Pid = ai_pool:checkout(?MODULE,true,infinity), Ref = erlang:...
null
https://raw.githubusercontent.com/DavidAlphaFox/ailib/1f5bd561d9ecd977d4c169c8edde99cbc727873d/src/pool/ai_pooled_task.erl
erlang
-module(ai_pooled_task). -export([checkin/1]). -export([async/1, async/2, async/3, async/4]). -export([await/1, await/2, safe_await/2, safe_await/3]). async(Fun) when erlang:is_function(Fun) -> Me = erlang:self(), Pid = ai_pool:checkout(?MODULE,true,infinity), Ref = erlang:...
1e4d762bba77e60772b7fab79ede7ac5cedb8f45ecbe0bafd8e5bca8791e6d38
daypack-dev/daypack-lib
time_profile_store.ml
open Test_utils module Qc = struct let read_from_dir_is_inverse_of_write_to_dir = QCheck.Test.make ~count:1000 ~name:"read_from_dir_is_inverse_of_write_to_dir" time_profile_store (fun store -> let dir = Core.Filename.temp_dir "daypack" "time_profile_store" in ( match Da...
null
https://raw.githubusercontent.com/daypack-dev/daypack-lib/63fa5d85007eca73aa6c51874a839636dd0403d3/tests/time_profile_store.ml
ocaml
open Test_utils module Qc = struct let read_from_dir_is_inverse_of_write_to_dir = QCheck.Test.make ~count:1000 ~name:"read_from_dir_is_inverse_of_write_to_dir" time_profile_store (fun store -> let dir = Core.Filename.temp_dir "daypack" "time_profile_store" in ( match Da...
2eb31988ce1d52e9bed68408dc214832c2ce2dc9d49c53b96bdd868a0eca7666
facebookarchive/pfff
find_source.mli
(* will manage optional skip list at root *) val files_of_root: lang:string -> Common.dirname -> Common.filename list will manage optional skip list at root of vcs val files_of_dir_or_files: lang:string -> verbose:bool -> Common.path list -> Common.filename list val finder: string -> (Common.path list ...
null
https://raw.githubusercontent.com/facebookarchive/pfff/ec21095ab7d445559576513a63314e794378c367/find_source.mli
ocaml
will manage optional skip list at root
val files_of_root: lang:string -> Common.dirname -> Common.filename list will manage optional skip list at root of vcs val files_of_dir_or_files: lang:string -> verbose:bool -> Common.path list -> Common.filename list val finder: string -> (Common.path list -> Common.filename list)
f822b21ef6758c488653793d2db25b8bc95e78e76288bb6ff56d042a86f5c1d4
avsm/platform
tyxml_svg.mli
TyXML * * Copyright ( C ) 2011 , * * This program is free software ; you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation , with linking exception ; * either version 2.1 of the License , or ( at you...
null
https://raw.githubusercontent.com/avsm/platform/b254e3c6b60f3c0c09dfdcde92eb1abdc267fa1c/duniverse/tyxml.4.3.0/implem/tyxml_svg.mli
ocaml
* {2 Printers}
TyXML * * Copyright ( C ) 2011 , * * This program is free software ; you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation , with linking exception ; * either version 2.1 of the License , or ( at you...
737da5e12700783273e1fd7273fa063fa74d339f09e507054a2c952c8868d309
isovector/suavemente
Core.hs
# LANGUAGE DataKinds # {-# LANGUAGE QuasiQuotes #-} # LANGUAGE TypeApplications # {-# LANGUAGE TypeOperators #-} module Web.Suavemente.Core where import Control.Applicative (liftA2) import Control.Concurrent.STM.TVar (TVar, writeTVar) import Control.Monad.Except (throwErr...
null
https://raw.githubusercontent.com/isovector/suavemente/b74315d57c42192353d6c5b67a13c3cf64d6afa3/src/Web/Suavemente/Core.hs
haskell
# LANGUAGE QuasiQuotes # # LANGUAGE TypeOperators # ---------------------------------------------------------------------------- | Get a 'String' representation of a markup-able type. Useful for constructing elements via quasiquotation. -------------------------------------------------------------------------...
# LANGUAGE DataKinds # # LANGUAGE TypeApplications # module Web.Suavemente.Core where import Control.Applicative (liftA2) import Control.Concurrent.STM.TVar (TVar, writeTVar) import Control.Monad.Except (throwError) import Control.Monad.IO.Class (liftIO) import ...
41d14baad699c4d407b7635f9b113beff8fa1620c6066da13268c0bbeb3d29ae
WhatsApp/erlt
enum_mod05.erl
-file("dev_enum/src/enum_mod05.erlt", 1). -module(enum_mod05). -eqwalizer_unchecked([]). -export([expr/0, pattern/3, guard/3]). -spec expr() -> {enum_mod04:foo(), enum_mod04:bar(), enum_mod04:baz()}. expr() -> {{'$#enum_mod04:foo.x'}, {'$#enum_mod04:bar.x', 1, 2}, {'...
null
https://raw.githubusercontent.com/WhatsApp/erlt/616a4adc628ca8754112e659701e57f1cd7fecd1/tests/dev_enum/ir-spec/enum_mod05.erl
erlang
-file("dev_enum/src/enum_mod05.erlt", 1). -module(enum_mod05). -eqwalizer_unchecked([]). -export([expr/0, pattern/3, guard/3]). -spec expr() -> {enum_mod04:foo(), enum_mod04:bar(), enum_mod04:baz()}. expr() -> {{'$#enum_mod04:foo.x'}, {'$#enum_mod04:bar.x', 1, 2}, {'...
10b3cf08bb892d7235f69837fce401eb2417088415991115d36f695a707b9245
roman/Haskell-etc
SpecTest.hs
# LANGUAGE CPP # # LANGUAGE NoImplicitPrelude # # LANGUAGE OverloadedLists # {-# LANGUAGE OverloadedStrings #-} # LANGUAGE ScopedTypeVariables # module System.Etc.SpecTest (tests) where import RIO import qualified RIO.HashMap as HashMap import qualified RIO.Vector as Vector impor...
null
https://raw.githubusercontent.com/roman/Haskell-etc/5c88575fa5d742aece4669c460e0ae72e039b45e/etc/test/System/Etc/SpecTest.hs
haskell
# LANGUAGE OverloadedStrings # NOTE: For some reason, pattern matching doesn't work on lts-6, using if/else instead error is a typo on key command (instead of command_s_)
# LANGUAGE CPP # # LANGUAGE NoImplicitPrelude # # LANGUAGE OverloadedLists # # LANGUAGE ScopedTypeVariables # module System.Etc.SpecTest (tests) where import RIO import qualified RIO.HashMap as HashMap import qualified RIO.Vector as Vector import Test.Tasty (TestTree, testGro...
c73b439118e16a34f26dc9a4048c46b6b2b2030dccc41d312cf3fdf3bf83d363
LaurentMazare/tensorflow-ocaml
mnist_conv.ml
open Base open Float.O_dot open Tensorflow_core open Tensorflow module O = Ops let image_dim = Mnist_helper.image_dim let label_count = Mnist_helper.label_count let scalar_tensor f = let array = Tensor.create1 Bigarray.float32 1 in Tensor.set array [| 0 |] f; array let batch_size = 512 let epochs = 5000 let (...
null
https://raw.githubusercontent.com/LaurentMazare/tensorflow-ocaml/52c5f1dec1a8b7dc9bc6ef06abbc07da6cd90d39/examples/mnist/mnist_conv.ml
ocaml
open Base open Float.O_dot open Tensorflow_core open Tensorflow module O = Ops let image_dim = Mnist_helper.image_dim let label_count = Mnist_helper.label_count let scalar_tensor f = let array = Tensor.create1 Bigarray.float32 1 in Tensor.set array [| 0 |] f; array let batch_size = 512 let epochs = 5000 let (...
6a3c67bf7306ca43c1d503970f5a35d82e899cecee9b0482650b13060124e58a
danielmiladinov/joy-of-clojure
clojure-is-a-lisp-1.clj
Lisp-1 ;; --------------------------------------------------------------------------------------------------------------------- Clojure is what 's known as a , which in simple terms means it uses the same name resolution for function and value bindings . In a Lisp-2 programming language like Common Lisp , these ...
null
https://raw.githubusercontent.com/danielmiladinov/joy-of-clojure/cad7d1851e153beb12a2cd536eb467be12cb7a73/src/joy-of-clojure/chapter4/clojure-is-a-lisp-1.clj
clojure
--------------------------------------------------------------------------------------------------------------------- depending on the context of the symbol, be it in a function-call position or a function-argument position. There are same name-resolution scheme is used for functions and their arguments, there's a r...
Lisp-1 Clojure is what 's known as a , which in simple terms means it uses the same name resolution for function and value bindings . In a Lisp-2 programming language like Common Lisp , these name resolutions are performed differently many arguments for and against both and , but one downside of bears consi...
ef6e51ab88b0380ca41a8cb19684bb27e1f91cf8c66b6f9d244f17fca6292903
audreyt/openafp
BMM.hs
module OpenAFP.Records.AFP.BMM where import OpenAFP.Types import OpenAFP.Internals data BMM = BMM { bmm_Type :: !N3 ,bmm_ :: !N3 ,bmm :: !NStr } deriving (Show, Typeable)
null
https://raw.githubusercontent.com/audreyt/openafp/178e0dd427479ac7b8b461e05c263e52dd614b73/src/OpenAFP/Records/AFP/BMM.hs
haskell
module OpenAFP.Records.AFP.BMM where import OpenAFP.Types import OpenAFP.Internals data BMM = BMM { bmm_Type :: !N3 ,bmm_ :: !N3 ,bmm :: !NStr } deriving (Show, Typeable)
cc926e4db2a0d5b83131c66aa230ffffad705074ca244f354b4bd28f37a5c703
andersfugmann/amqp-client
queue_declare_test.ml
open Amqp open Thread let uniq s = Printf.sprintf "%s_%d_%s" (Filename.basename Sys.argv.(0)) (Unix.getpid ()) s let handler var { Message.message = (_, body); _ } = Ivar.fill var body; return () let declare ~channel name = let queue_name = uniq name in Queue.declare channel ~auto_delete:true queue_name >>= fu...
null
https://raw.githubusercontent.com/andersfugmann/amqp-client/2932a69510af550e9e156ed479f4fca7daee31cc/async/test/queue_declare_test.ml
ocaml
open Amqp open Thread let uniq s = Printf.sprintf "%s_%d_%s" (Filename.basename Sys.argv.(0)) (Unix.getpid ()) s let handler var { Message.message = (_, body); _ } = Ivar.fill var body; return () let declare ~channel name = let queue_name = uniq name in Queue.declare channel ~auto_delete:true queue_name >>= fu...
de84cbe03ae543fca4e95120ebfcc0808492d0be23b3dfde4786c35915d1f952
softlab-ntua/bencherl
class_FaultyDeterministicThirstyCustomer.erl
Copyright ( C ) 2008 - 2014 EDF R&D % % This file is part of the Sim-Diasca training material. % % It has been placed in the public domain. % Author : ( ) % Class modeling a deterministic thristy customer. -module(class_FaultyDeterministicThirstyCustomer). % Determines what are the mother classes of this cla...
null
https://raw.githubusercontent.com/softlab-ntua/bencherl/317bdbf348def0b2f9ed32cb6621e21083b7e0ca/app/sim-diasca/sim-diasca/doc/training/exercises/ex_sim_diasca_model_troubleshooting/class_FaultyDeterministicThirstyCustomer.erl
erlang
This file is part of the Sim-Diasca training material. It has been placed in the public domain. Class modeling a deterministic thristy customer. Determines what are the mother classes of this class (if any): parameters taken by the constructor ('construct'). Member method declarations. Must be included before...
Copyright ( C ) 2008 - 2014 EDF R&D Author : ( ) -module(class_FaultyDeterministicThirstyCustomer). -define( wooper_superclasses, [ class_Actor ] ). -define( wooper_construct_parameters, ActorSettings, CustomerName, KnownMachine, RepletionDuration, InitialBudget ). Declaring all variations of WOOPER ...
1a485a3b22400674ac612d544e9d57c7b55706feafeb4419446bf3f4a2028b50
GrammaTech/sel
fodder-database.lisp
;;; fodder-database.lisp --- Generic interface to database of software fodder (defpackage :software-evolution-library/components/fodder-database (:nicknames :sel/components/fodder-database :sel/cp/fodder-database) (:use :gt/full :software-evolution-library/components/searchable) (:export :fodder-database ...
null
https://raw.githubusercontent.com/GrammaTech/sel/a59174c02a454e8d588614e221cf281260cf12f8/components/fodder-database.lisp
lisp
fodder-database.lisp --- Generic interface to database of software fodder
(defpackage :software-evolution-library/components/fodder-database (:nicknames :sel/components/fodder-database :sel/cp/fodder-database) (:use :gt/full :software-evolution-library/components/searchable) (:export :fodder-database :database-emptyp :find-type :find-macro)) (in...
f53f5fae2927916e020fd083dad8fc906fcb87b216251bb2256afa7d9d58c2c8
crategus/cl-cffi-gtk
rtest-gobject-utils.lisp
(def-suite gobject-utils :in gobject-suite) (in-suite gobject-utils) ;; Load Gdk to have examples for flags and enum definitions. (asdf:load-system :cl-cffi-gtk-gdk) (test get-enum-items (is (equal '("GDK_DRAG_PROTO_NONE" "GDK_DRAG_PROTO_MOTIF" "GDK_DRAG_PROTO_XDND" "GDK_DRAG_PROTO_ROOTWIN" ...
null
https://raw.githubusercontent.com/crategus/cl-cffi-gtk/22156e3e2356f71a67231d9868abcab3582356f3/test/rtest-gobject-utils.lisp
lisp
Load Gdk to have examples for flags and enum definitions.
(def-suite gobject-utils :in gobject-suite) (in-suite gobject-utils) (asdf:load-system :cl-cffi-gtk-gdk) (test get-enum-items (is (equal '("GDK_DRAG_PROTO_NONE" "GDK_DRAG_PROTO_MOTIF" "GDK_DRAG_PROTO_XDND" "GDK_DRAG_PROTO_ROOTWIN" "GDK_DRAG_PROTO_WIN32_DROPFILES" "GDK_DRAG_PROTO_OLE2" ...
94bead7a70e59be2f60bddc05f34c51aa36f41e8976e8b516004181cd4a66a6e
patricoferris/ocaml-df
ffi_stubgen.ml
(* General structure taken from -yaml/blob/master/ffi/stubgen/ffi_stubgen.ml *) let prefix = "statvfs_stub" let prologue = "#include <sys/types.h>\n#include <sys/statvfs.h>\n" let () = let generate_ml, generate_c = (ref false, ref false) in let () = Arg.( parse [ ("-ml", Set generate_m...
null
https://raw.githubusercontent.com/patricoferris/ocaml-df/617654587d66f394096277eb952947847cf3649f/ffi/stubgen/ffi_stubgen.ml
ocaml
General structure taken from -yaml/blob/master/ffi/stubgen/ffi_stubgen.ml
let prefix = "statvfs_stub" let prologue = "#include <sys/types.h>\n#include <sys/statvfs.h>\n" let () = let generate_ml, generate_c = (ref false, ref false) in let () = Arg.( parse [ ("-ml", Set generate_ml, "Generate ML"); ("-c", Set generate_c, "Generate C"); ]) ...
30b0bd517a299a08ddd92704d10fbf37b434f0c0d37759e9a90d957b6c78565b
vlstill/hsExprTest
safety.IO.nok.hs
import System.IO.Unsafe ( unsafePerformIO ) import System.Exit ( exitSuccess ) foo = unsafePerformIO $ exitSuccess
null
https://raw.githubusercontent.com/vlstill/hsExprTest/391fc823c1684ec248ac8f76412fefeffb791865/examples/safety.IO.nok.hs
haskell
import System.IO.Unsafe ( unsafePerformIO ) import System.Exit ( exitSuccess ) foo = unsafePerformIO $ exitSuccess
507712e73990fa7241a9c2363eb38677da760273ae12a543d5a9409735b30fff
plandes/cisql
spec.clj
(ns ^{:doc "This package manages DB specs. It also class loads and optionally downloads the JDBC drivers." :author "Paul Landes"} zensols.cisql.spec (:import [java.sql DriverManager] [java.util Properties]) (:require [clojure.java.io :as io] [clojure.tools.logging :as log] ...
null
https://raw.githubusercontent.com/plandes/cisql/8001864f1596d191386a3787b49e8a640705fee2/src/clojure/zensols/cisql/spec.clj
clojure
(ns ^{:doc "This package manages DB specs. It also class loads and optionally downloads the JDBC drivers." :author "Paul Landes"} zensols.cisql.spec (:import [java.sql DriverManager] [java.util Properties]) (:require [clojure.java.io :as io] [clojure.tools.logging :as log] ...
3c064a75b3c528f862d5f8d325efaa6ff1848ce34e0782033b169dbfa32f21d2
scarvalhojr/haskellbook
section27.9.hs
import Debug.Trace (trace) inc = (+1) twice = inc . inc howManyTimes = inc (trace "I got eval'd" (1 + 1)) + twice (trace "I got eval'd" (1 + 1)) howManyTimes' = let onePlusOne = trace "I got eval'd" (1 + 1) in inc onePlusOne + twice onePlusOne
null
https://raw.githubusercontent.com/scarvalhojr/haskellbook/6016a5a78da3fc4a29f5ea68b239563895c448d5/chapter27/section27.9.hs
haskell
import Debug.Trace (trace) inc = (+1) twice = inc . inc howManyTimes = inc (trace "I got eval'd" (1 + 1)) + twice (trace "I got eval'd" (1 + 1)) howManyTimes' = let onePlusOne = trace "I got eval'd" (1 + 1) in inc onePlusOne + twice onePlusOne
fbc06f74701f636a41997f1084b0170aeb71df32f4cdf2d43d4d062f09fea28c
penpot/penpot
templates.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.onboarding.templates (:require [app.config :as cf] [app.main.data.dashboard :as dd] ...
null
https://raw.githubusercontent.com/penpot/penpot/746f4926322643f7b98b38379db7ef55db4e4de5/frontend/src/app/main/ui/onboarding/templates.cljs
clojure
Copyright (c) KALEIDOS INC NOTE: the project usually comes empty, it only comes fulfilled when a user creates a new team just after signup.
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.onboarding.templates (:require [app.config :as cf] [app.main.data.dashboard :as dd] [app.main.data.modal :as modal] ...
1298b997ea9c683764fa837f66e55778ba2cd16a08af36aaa1f27ccfeafb7a31
jjtolton/libapl-clj
api.clj
(ns ^{:doc "A (more) stable API for working in APL memory space. Coercion from JVM->APL provided. This is the suggested API for library development."} libapl-clj.api (:require [libapl-clj.impl.api :as api :reload true] [libapl-clj.impl.ops :as ops :reload true] [libapl-clj.impl.helpers :as h...
null
https://raw.githubusercontent.com/jjtolton/libapl-clj/01e2bf7e0d20abd9f8f36c2d9fc829dd4082d455/src/libapl_clj/api.clj
clojure
could use some macros here todo -- this will crash on complex numbers. : can't figure out why atp->ref! crashes on scalars todo -- would be good to get rid of this reflection need to fix reflection 1 + 1 ⍳10 1 2 3 + 1 2 3 1 2 3 + 10 10 + 1 2 3
(ns ^{:doc "A (more) stable API for working in APL memory space. Coercion from JVM->APL provided. This is the suggested API for library development."} libapl-clj.api (:require [libapl-clj.impl.api :as api :reload true] [libapl-clj.impl.ops :as ops :reload true] [libapl-clj.impl.helpers :as h...
7562370b2ad9d54e3e5786f5590ab20de3b12d017cf55fe0f191e897e3c9bda9
jafingerhut/clojure-benchmarks
pmap-alternates.clj
(ns pmapalternates (:use [clojure.string :only (join)]) (:import java.util.concurrent.ExecutorService java.util.concurrent.Executors) (:gen-class)) (set! *warn-on-reflection* true) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; This is a copy of part of Medusa package , ...
null
https://raw.githubusercontent.com/jafingerhut/clojure-benchmarks/474a8a4823727dd371f1baa9809517f9e0b508d4/misc/pmap-alternates.clj
clojure
thread pool with a fixed size. No more than that many threads will ever run at once, but Medusa tries to keep that many threads going at all times, as long as there are things to do that have been submitted. git clone -utils.git git clone This is the end of the subset of Medusa code. modified-pmap does w...
(ns pmapalternates (:use [clojure.string :only (join)]) (:import java.util.concurrent.ExecutorService java.util.concurrent.Executors) (:gen-class)) (set! *warn-on-reflection* true) This is a copy of part of Medusa package , which allows you to submit a bunch of Clojure expressions to run to a...
8e88ca029d1be0eacc8f15b6971baa9d211a38136e88d0b6f36dbdaf19c8060b
fourmolu/fourmolu
overlapping-four-out.hs
deriving instance {-# OVERLAPPABLE #-} Ord Foo deriving instance {-# OVERLAPPING #-} Num Foo deriving instance {-# OVERLAPS #-} Read Foo deriving instance # INCOHERENT # Show Foo
null
https://raw.githubusercontent.com/fourmolu/fourmolu/1f8903a92c8d5001dc1ec8ecfd4a04a3b61c3283/data/examples/declaration/deriving/overlapping-four-out.hs
haskell
# OVERLAPPABLE # # OVERLAPPING # # OVERLAPS #
deriving instance Ord Foo deriving instance Num Foo deriving instance Read Foo deriving instance # INCOHERENT # Show Foo
e4d02c70037fec2a66afb5a4ddc92655df8de79f28ca2d2c26f227a33ecc9dad
diku-dk/futhark
UsageTable.hs
{-# LANGUAGE Strict #-} -- | A usage-table is sort of a bottom-up symbol table, describing how -- (and if) a variable is used. module Futhark.Analysis.UsageTable ( UsageTable, without, lookup, used, expand, isConsumed, isInResult, isUsedDirectly, isSize, usages, usage, con...
null
https://raw.githubusercontent.com/diku-dk/futhark/174e8d862def6f52d5c9a36fa3aa6e746049776e/src/Futhark/Analysis/UsageTable.hs
haskell
# LANGUAGE Strict # | A usage-table is sort of a bottom-up symbol table, describing how (and if) a variable is used. | A usage table. | Remove these entries from the usage table. | Look up a variable in the usage table. | Is the variable present in the usage table? That is, has it been used? | Expand the usage ...
module Futhark.Analysis.UsageTable ( UsageTable, without, lookup, used, expand, isConsumed, isInResult, isUsedDirectly, isSize, usages, usage, consumedUsage, inResultUsage, sizeUsage, sizeUsages, withoutU, Usages, consumedU, presentU, usageI...
617178cb3c72509192a2b6e106890fd7694926ff4f8357d476adaa6d263e3db8
open-telemetry/opentelemetry-erlang
otel_metric_exporter_pid.erl
%%%------------------------------------------------------------------------ Copyright 2022 , OpenTelemetry Authors 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 %% %% Unl...
null
https://raw.githubusercontent.com/open-telemetry/opentelemetry-erlang/7b3cb407245681ca26434cfde10ec58611f2e498/apps/opentelemetry_experimental/src/otel_metric_exporter_pid.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 o...
Copyright 2022 , OpenTelemetry Authors Licensed under the Apache License , Version 2.0 ( the " License " ) ; distributed under the License is distributed on an " AS IS " BASIS , -module(otel_metric_exporter_pid). -export([init/1, export/4, force_flush/0, shutdown/1]). -include_lib("o...
f707bce106870c0c19dcaa8fec652b45dc4c16604a0705fb9aa5daa8df67aaf4
HugoPeters1024/hs-sleuth
Cvt.hs
# LANGUAGE RecordWildCards # module HsComprehension.Cvt where import HsComprehension.Ast import Data.Text (Text) import qualified Data.Text as T import Data.Char import Numeric (showOct, showHex) import Data.Hashable as Hash import qualified GhcDump.Ast as GHCD import HsComprehension.Hash (hashExprModAlpha) data ...
null
https://raw.githubusercontent.com/HugoPeters1024/hs-sleuth/e710f31436ac2828302bc60a57080eb34d528db2/plugin/lib/HsComprehension/Cvt.hs
haskell
to reduce the dump size, the details of the unfoldings care currently removed
# LANGUAGE RecordWildCards # module HsComprehension.Cvt where import HsComprehension.Ast import Data.Text (Text) import qualified Data.Text as T import Data.Char import Numeric (showOct, showHex) import Data.Hashable as Hash import qualified GhcDump.Ast as GHCD import HsComprehension.Hash (hashExprModAlpha) data ...
b2291ded8dc08476aa463d695bd1e5ba00b8ba1044153d01b2926edeff883d0e
rubenbarroso/EOPL
r5rs.scm
defining eopl fcns in R5RS scheme (define eopl:printf (lambda (format . args) (let ((len (string-length format))) (let loop ((i 0) (args args)) (let ((output (lambda (fn) (fn (car args)) (loop (+ i 2) (cdr args)))) (outputc ...
null
https://raw.githubusercontent.com/rubenbarroso/EOPL/f9b3c03c2fcbaddf64694ee3243d54be95bfe31d/src/interps/r5rs.scm
scheme
print the message
defining eopl fcns in R5RS scheme (define eopl:printf (lambda (format . args) (let ((len (string-length format))) (let loop ((i 0) (args args)) (let ((output (lambda (fn) (fn (car args)) (loop (+ i 2) (cdr args)))) (outputc ...
d3651759bd95a71cec870e0625a91f9bb4255daf77739b3dd006b693987984db
OpenBookStore/openbookstore
test-contacts.lisp
(in-package :bookshops-test) (subtest "Create a contact" ;; Our fixtures work. (with-empty-db (is (object-id (create-contact "contact test")) 1 "create a contact"))) (subtest "Lend books, see loans" (with-empty-db (with-fixtures (ok (lend (first *books*) (first *contacts*)) ...
null
https://raw.githubusercontent.com/OpenBookStore/openbookstore/13f16e5460ba7149c9f3108b7f3519e4614e4580/tests/test-contacts.lisp
lisp
Our fixtures work. error: (ok (loans) "Loans")
(in-package :bookshops-test) (subtest "Create a contact" (with-empty-db (is (object-id (create-contact "contact test")) 1 "create a contact"))) (subtest "Lend books, see loans" (with-empty-db (with-fixtures (ok (lend (first *books*) (first *contacts*)) "Lend") ))) (f...
460e186ca8f1e2af430884b1a19c22636889983ccf5f33e5661f9d0d96051e57
quil-lang/magicl
abstract-tensor.lisp
abstract-tensor.lisp ;;;; Author : ;;;; Collaborators : (in-package #:magicl) (defstruct (abstract-tensor (:constructor nil) (:copier nil)) "Abstract tensor class. Superclass for implementing the abstract-tensor protocol") ;;; abstract-tensor protocol ;;; These methods do not have...
null
https://raw.githubusercontent.com/quil-lang/magicl/a10a6c8ce7c7910029d247bbc170c09d3a1e79fd/src/high-level/abstract-tensor.lisp
lisp
abstract-tensor protocol These methods do not have generic definitions and must be implemented by subclasses abstract-tensor generic methods These methods have default generic implementations but can be optimized by subclasses arguments Recall that, e.g., TENSOR + NUMBER is commutative, but N.B. This implement...
abstract-tensor.lisp Author : Collaborators : (in-package #:magicl) (defstruct (abstract-tensor (:constructor nil) (:copier nil)) "Abstract tensor class. Superclass for implementing the abstract-tensor protocol") (defgeneric shape (tensor) (:documentation "The shape (dimensions...
954e9daba11260f570b708fe18febdfe2ccfdb0dac4d8a82cccc428823f6a8e3
mtgred/netrunner
payment.clj
(ns game.core.payment (:require [clojure.string :as string] [game.core.board :refer [all-active-installed]] [game.core.card :refer [ice?]] [game.core.eid :refer [make-eid]] [game.core.flags :refer [card-flag?]] [game.core.toasts :refer [toast]] [jinteki.utils :refer [capitalize]])) (defmu...
null
https://raw.githubusercontent.com/mtgred/netrunner/30f5e446b7b72488496ec44d553365ccfa4c429d/src/clj/game/core/payment.clj
clojure
Using the multi-method value here in case a cost-type Remove nil stealth costs Don't group :x-credits the function `pay` is defined in resolve-ability because they're all intermingled fuck the restriction against circular dependencies, for real cost labels and messages
(ns game.core.payment (:require [clojure.string :as string] [game.core.board :refer [all-active-installed]] [game.core.card :refer [ice?]] [game.core.eid :refer [make-eid]] [game.core.flags :refer [card-flag?]] [game.core.toasts :refer [toast]] [jinteki.utils :refer [capitalize]])) (defmu...
230403dff31df966631779c9065c2809b36511b8168642e73ca2cc5fdcea1e84
hoplon/hoplon
boot_hoplon.clj
Copyright ( c ) and . All rights reserved . ;; The use and distribution terms for this software are covered by the Eclipse Public License 1.0 ( -1.0.php ) ;; which can be found in the file epl-v10.html at the root of this distribution. ;; By using this software in any fashion, you are agreeing to be bound by ;;...
null
https://raw.githubusercontent.com/hoplon/hoplon/2f886d10d942e72e4565dfbb997487e90c8d5e3a/src/hoplon/boot_hoplon.clj
clojure
The use and distribution terms for this software are covered by the which can be found in the file epl-v10.html at the root of this distribution. By using this software in any fashion, you are agreeing to be bound by the terms of this license. You must not remove this notice, or any other, from this software. ...
Copyright ( c ) and . All rights reserved . Eclipse Public License 1.0 ( -1.0.php ) (ns hoplon.boot-hoplon {:boot/export-tasks true} (:require [boot.core :as boot] [boot.pod :as pod] [boot.util :as util] [boot.file :as file] [cloj...
674ee80c29e9ee6c7318c03732d88e127cbfda9adfc826900871fd3cfd9f6dd9
SanderSpies/ocaml-gist
query_protocol.ml
{ { { COPYING * ( This file is part of Merlin , an helper for ocaml editors Copyright ( C ) 2013 - 2015 < frederic.bour(_)lakaban.net > refis.thomas(_)gmail.com > < simon.castellan(_)iuwt.fr > Permission is hereby granted , free...
null
https://raw.githubusercontent.com/SanderSpies/ocaml-gist/7dc229aebdf51310e8c7dae12df0cb55b5de5a32/ocaml_webworker/merlin_lite/src/frontend/query_protocol.ml
ocaml
{ { { COPYING * ( This file is part of Merlin , an helper for ocaml editors Copyright ( C ) 2013 - 2015 < frederic.bour(_)lakaban.net > refis.thomas(_)gmail.com > < simon.castellan(_)iuwt.fr > Permission is hereby granted , free...
0d88d50c240734c9613c66a527d347287154e918b8a17b418d7a97e78bbd13f7
janestreet/lwt-async
lwt_list.ml
Lightweight thread library for * Module Lwt_list * Copyright ( C ) 2010 * * This program is free software ; you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as * published by the Free Software Foundation , with linking exceptions ; * eithe...
null
https://raw.githubusercontent.com/janestreet/lwt-async/c738e6202c1c7409e079e513c7bdf469f7f9984c/src/core/lwt_list.ml
ocaml
Lightweight thread library for * Module Lwt_list * Copyright ( C ) 2010 * * This program is free software ; you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as * published by the Free Software Foundation , with linking exceptions ; * eithe...
0e9f204499425c1b30962adadbbda447fd9e969f1f66affdd5b3cdc7b4a254a1
eudoxia0/asdf-linguist
tools.lisp
(in-package :asdf-linguist) YUI CSS compressor (define-component css-minify :input-type "css" :output-type "min.css" :compile-function (lambda (input-pathname output-pathname) (inferior-shell:run `("yui-compressor" ,input-pathname "-o" ,output-pathname) ...
null
https://raw.githubusercontent.com/eudoxia0/asdf-linguist/f15de19287a5c2ca0e453b105be0c6f143339441/src/www/tools.lisp
lisp
(in-package :asdf-linguist) YUI CSS compressor (define-component css-minify :input-type "css" :output-type "min.css" :compile-function (lambda (input-pathname output-pathname) (inferior-shell:run `("yui-compressor" ,input-pathname "-o" ,output-pathname) ...
e68ce1bac69ab5f4549634bd48deeb060037764cc60a07d0927837c810af6f0a
sky-big/RabbitMQ
rabbit_federation_mgmt.erl
The contents of this file are subject to the Mozilla Public License Version 1.1 ( the " License " ) ; you may not use this file except in %% compliance with the License. You may obtain a copy of the License %% at / %% Software distributed under the License is distributed on an " AS IS " %% basis, WITHOUT WA...
null
https://raw.githubusercontent.com/sky-big/RabbitMQ/d7a773e11f93fcde4497c764c9fa185aad049ce2/plugins-src/rabbitmq-federation-management/src/rabbit_federation_mgmt.erl
erlang
compliance with the License. You may obtain a copy of the License at / basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. -------------------------------------------------------------------- --------...
The contents of this file are subject to the Mozilla Public License Version 1.1 ( the " License " ) ; you may not use this file except in Software distributed under the License is distributed on an " AS IS " The Original Code is RabbitMQ . The Initial Developer of the Original Code is GoPivotal , Inc. ...
d4cfbdb3591f33da3adf7e6d6514858d99aaf4e287a8cbdee07e40cc21a30594
facebookarchive/pfff
highlight_hs.mli
val visit_program : tag_hook: (Parse_info.info -> Highlight_code.category -> unit) -> Highlight_code.highlighter_preferences -> Ast_hs.program * Parser_hs.token list -> unit
null
https://raw.githubusercontent.com/facebookarchive/pfff/ec21095ab7d445559576513a63314e794378c367/lang_haskell/analyze/highlight_hs.mli
ocaml
val visit_program : tag_hook: (Parse_info.info -> Highlight_code.category -> unit) -> Highlight_code.highlighter_preferences -> Ast_hs.program * Parser_hs.token list -> unit
092a96d160910ff36a3b7365f63bd55c5f2d7dc8f7e4439da94f6a7fd8632fc9
camllight/camllight
symtable.ml
#open "misc";; #open "const";; #open "predef";; #open "printf";; (* symtable.ml : to assign numbers to global variables and so on *) let object_name = ref "";; (* Hashtables for numbering objects *) type 'a numtable = { mutable num_cnt: int; (* The current number *) mutable num_tbl: ('a, int...
null
https://raw.githubusercontent.com/camllight/camllight/0cc537de0846393322058dbb26449427bfc76786/sources/src/linker/symtable.ml
ocaml
symtable.ml : to assign numbers to global variables and so on Hashtables for numbering objects The current number The table Global variables The exception tags The C primitives Initialization To write and read linker tables to a file
#open "misc";; #open "const";; #open "predef";; #open "printf";; let object_name = ref "";; type 'a numtable = ;; let new_numtable size = { num_cnt = 0; num_tbl = hashtbl__new size } ;; let find_in_numtable nt = hashtbl__find nt.num_tbl and enter_in_numtable nt key = let c = nt.num_cnt in nt.num_cnt <-...
d1473b78b9abc39737c4bf778202b92843d4bbc5029df2b148c22429131403f9
avsm/mirage-ci
docker_ops.mli
--------------------------------------------------------------------------- Copyright ( c ) 2017 . All rights reserved . Distributed under the ISC license , see terms at the end of the file . % % NAME%% % % --------------------------------------------------------------------------- Copyright (c) 2...
null
https://raw.githubusercontent.com/avsm/mirage-ci/a11ecf203976299fa19337fd9e1794d6ca3fa436/src/docker_ops.mli
ocaml
--------------------------------------------------------------------------- Copyright ( c ) 2017 . All rights reserved . Distributed under the ISC license , see terms at the end of the file . % % NAME%% % % --------------------------------------------------------------------------- Copyright (c) 2...
16ac295a07571e00aa49ae08513121107b83505f3b933f74c0b288b2b1ccb09b
EFanZh/EOPL-Exercises
exercise-7.17.rkt
#lang eopl ;; Exercise 7.17 [★★] In our representation, extend-subst may do a lot of work if σ is large. Implement an alternate ;; representation in which extend-subst is implemented as ;; ;; (define extend-subst ;; (lambda (subst tvar ty) ;; (cons (cons tvar ty) subst))) ;; ;; and the extra work is ...
null
https://raw.githubusercontent.com/EFanZh/EOPL-Exercises/11667f1e84a1a3e300c2182630b56db3e3d9246a/solutions/exercise-7.17.rkt
racket
Exercise 7.17 [★★] In our representation, extend-subst may do a lot of work if σ is large. Implement an alternate representation in which extend-subst is implemented as (define extend-subst (lambda (subst tvar ty) (cons (cons tvar ty) subst))) and the extra work is shifted to apply-subst-to-ty...
#lang eopl (define the-lexical-spec '([whitespace (whitespace) skip] [comment ("%" (arbno (not #\newline))) skip] [identifier (letter (arbno (or letter digit "_" "-" "?"))) symbol] [number (digit (arbno digit)) number] [number ("-" digit (arbno digit)) number])) (define the-grammar '([program (e...
704a9c9a63f4f5665527a8822d85994bbe520b47eed141116450d8957fd6cb38
serokell/haskell-crypto
Box.hs
SPDX - FileCopyrightText : 2020 -- SPDX - License - Identifier : MPL-2.0 -- | Public-key authenticated encryption. -- -- It is best to import this module qualified: -- -- @ -- import qualified NaCl.Box as Box -- -- encrypted = Box.'create' pk sk nonce message -- decrypted = Box.'open' pk sk nonce encrypted -- @ -...
null
https://raw.githubusercontent.com/serokell/haskell-crypto/e57b04d103b428b03c83565060a36da442663a5a/NaCl/lib/NaCl/Box.hs
haskell
| Public-key authenticated encryption. It is best to import this module qualified: @ import qualified NaCl.Box as Box encrypted = Box.'create' pk sk nonce message decrypted = Box.'open' pk sk nonce encrypted @ This is @crypto_box_*@ from NaCl. | Encrypt a message. @ encrypted = Box.create pk sk nonce m...
SPDX - FileCopyrightText : 2020 SPDX - License - Identifier : MPL-2.0 module NaCl.Box ( PublicKey , toPublicKey , SecretKey , toSecretKey , keypair , Nonce , toNonce , create , open ) where import Data.ByteArray (ByteArray, ByteArrayAccess) import System.IO.Unsafe (unsafePerformIO) import ...
e8ce9a41bf05802d9a40a3687b2b0e9aab676c96447d03bdeec3d4370ec535bf
cmsc430/www
compile-expr.rkt
#lang racket (provide (all-defined-out)) (require "stdlib.rkt" "ast.rkt" "types.rkt" "lambdas.rkt" "fv.rkt" "utils.rkt" "compile-ops.rkt" "compile-datum.rkt" "a86/ast.rkt" "registers.rkt") ;; Expr CEnv GEnv Bool -> Asm (define (compile-e ...
null
https://raw.githubusercontent.com/cmsc430/www/473cdf0f5d5734f760eee93bb2871313f15529fd/langs/outlaw/compile-expr.rkt
racket
Expr CEnv GEnv Bool -> Asm Id CEnv GEnv -> Asm The return address is placed above the arguments, so callee pops arguments and return address is next frame fetch the code label FIXME: should have tail recursive version too return value Lambda -> Id Copy the values of given free variables into the heap at given...
#lang racket (provide (all-defined-out)) (require "stdlib.rkt" "ast.rkt" "types.rkt" "lambdas.rkt" "fv.rkt" "utils.rkt" "compile-ops.rkt" "compile-datum.rkt" "a86/ast.rkt" "registers.rkt") (define (compile-e e c g t?) (match e [(Quo...
5e0224fdffe0467aa998866f3e449e1f51fcdd1e007fd38bbcb1589641399f2c
flodihn/NextGen
char.erl
-module(char). -include("char.hrl"). -include_lib("stdlib/include/qlc.hrl"). -export([ init/0, init_tables/0, stop/0, retreive_char/1, save_char/1 ]). init_tables() -> mnesia:create_schema([node()]), mnesia:start(), mnesia:create_table(char, [{attributes, record_info(fields, char...
null
https://raw.githubusercontent.com/flodihn/NextGen/3da1c3ee0d8f658383bdf5fccbdd49ace3cdb323/CharacterServer/src/char.erl
erlang
delete(Q) -> F = fun() -> mnesia:delete(Q) end, F = fun() -> qlc:e(Q) end,
-module(char). -include("char.hrl"). -include_lib("stdlib/include/qlc.hrl"). -export([ init/0, init_tables/0, stop/0, retreive_char/1, save_char/1 ]). init_tables() -> mnesia:create_schema([node()]), mnesia:start(), mnesia:create_table(char, [{attributes, record_info(fields, char...
20347762d02ba7184c5be192026a6decbb4f0f5b185fab85c1403a6dca464889
mtolly/onyxite-customs
StackTrace.hs
# LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # # LANGUAGE MultiParamTypeClasses # {-# LANGUAGE RankNTypes #-} # LANGUAGE TypeFamilies # {-# LANGUAGE UndecidableInstanc...
null
https://raw.githubusercontent.com/mtolly/onyxite-customs/63a0b278bbe973480d12a12518efe939dd882028/haskell/packages/onyx-lib/src/Onyx/StackTrace.hs
haskell
# LANGUAGE RankNTypes # # LANGUAGE UndecidableInstances # | This can represent an error (required input was not found) or a warning (given input was not completely recognized). and this doesn't seem to always catch it correctly, at least in Wine to a StackTraceT fatal with layers
# LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies # # LANGUAGE GeneralizedNewtypeDeriving # # LANGUAGE LambdaCase # # LANGUAGE MultiParamTypeClasses # # LANGUAGE TypeFamilies # module Onyx.StackTrace ( Message(..), Messages(..) , MessageLevel(..), Send...
0fe378f6b7ec764f05907900ee7302d31972248d12abf4eb8c0bc23f494a3a3d
haskell/haskell-language-server
GHC.hs
# LANGUAGE CPP # # LANGUAGE FlexibleContexts # {-# LANGUAGE GADTs #-} {-# LANGUAGE LambdaCase #-} {-# LANGUAGE PatternSynonyms #-} {-# LANGUAGE RankNTypes #-} # LANGUAGE RecordWildCards # # LANGUAGE TupleSections # # LANGUAGE TypeApplications # # OPTIONS_GHC -Wno - missing - ...
null
https://raw.githubusercontent.com/haskell/haskell-language-server/686fa1aa0ed686fb890d93247cd52ee1a77ed188/plugins/hls-gadt-plugin/src/Ide/Plugin/GHC.hs
haskell
# LANGUAGE GADTs # # LANGUAGE LambdaCase # # LANGUAGE PatternSynonyms # # LANGUAGE RankNTypes # | Check if a given range is in the range of located item ^Type variable names ^Data type context Parameters in the data constructor | Construct GADT result type Without type variable With type ...
# LANGUAGE CPP # # LANGUAGE FlexibleContexts # # LANGUAGE RecordWildCards # # LANGUAGE TupleSections # # LANGUAGE TypeApplications # # OPTIONS_GHC -Wno - missing - signatures # # OPTIONS_GHC -Wno - overlapping - patterns # module Ide.Plugin.GHC where import Data.Functor ...