_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
e1c1e961a2a2b4881bd71e2679005c26068fea08d966e54154a2e537d72dcf5e
huangjs/cl
zlog.lisp
;;; Compiled by f2cl version: ( " f2cl1.l , v 1.215 2009/04/07 22:05:21 rtoy Exp $ " " f2cl2.l , v 1.37 2008/02/22 22:19:33 rtoy Exp $ " " f2cl3.l , v 1.6 2008/02/22 22:19:33 rtoy Exp $ " " f2cl4.l , v 1.7 2008/02/22 22:19:34 rtoy Exp $ " " f2cl5.l , v 1.200 2009/01/19 02:38:17 rtoy Exp $ " " f2cl6.l ,...
null
https://raw.githubusercontent.com/huangjs/cl/96158b3f82f82a6b7d53ef04b3b29c5c8de2dbf7/lib/maxima/src/numerical/slatec/zlog.lisp
lisp
Compiled by f2cl version: Options: ((:prune-labels nil) (:auto-save t) (:relaxed-array-decls t) (:coerce-assigns :as-needed) (:array-type ':simple-array) (:array-slicing nil) (:declare-common nil) (:float-format double-float))
( " f2cl1.l , v 1.215 2009/04/07 22:05:21 rtoy Exp $ " " f2cl2.l , v 1.37 2008/02/22 22:19:33 rtoy Exp $ " " f2cl3.l , v 1.6 2008/02/22 22:19:33 rtoy Exp $ " " f2cl4.l , v 1.7 2008/02/22 22:19:34 rtoy Exp $ " " f2cl5.l , v 1.200 2009/01/19 02:38:17 rtoy Exp $ " " f2cl6.l , v 1.48 2008/08/24 00:56:27 rt...
59b92678cafa569831d406d7ba9efdcdf98c2c1f75291a9040ca0aed37772a0f
namin/biohacker
condef.lisp
;;; -*- Mode: Lisp; Syntax: Common-lisp; -*- ;;;; Sample constraints for TCON interpreter. Last edited 1/29/93 , by KDF Copyright ( c ) 1988 - 1993 , , Northwestern University , and , the Xerox Corporation . ;;; All rights reserved. ;;; See the file legal.txt for a paragraph stating scope of permission ;...
null
https://raw.githubusercontent.com/namin/biohacker/6b5da4c51c9caa6b5e1a68b046af171708d1af64/BPS/tcon/condef.lisp
lisp
-*- Mode: Lisp; Syntax: Common-lisp; -*- Sample constraints for TCON interpreter. All rights reserved. See the file legal.txt for a paragraph stating scope of permission and disclaimer of warranty. The above copyright notice and that paragraph must be included in any separate copy of this file. Use multiplier co...
Last edited 1/29/93 , by KDF Copyright ( c ) 1988 - 1993 , , Northwestern University , and , the Xerox Corporation . (in-package :COMMON-LISP-USER) (constraint adder ((a1 cell) (a2 cell) (sum cell)) (formulae (sum (a1 a2) (+ a1 a2)) (a1 (sum a2) (- sum a2)) (a2 (sum a1) (- sum a1))...
20e579d86e48733f198a00ac3f43f17aa68929bb0e18396e0b0abee3f3154486
ohua-dev/ohua-core
Passes.hs
-- | -- Module : $Header$ -- Description : Passes over algorithm language terms to ensure certain invariants Copyright : ( c ) 2017 . All Rights Reserved . -- License : EPL-1.0 Maintainer : , -- Stability : experimental -- Portability : portable -- -- This module implements a set of passes over ...
null
https://raw.githubusercontent.com/ohua-dev/ohua-core/978fa3369922f86cc3fc474d5f2c554cc87fd60a/core/src/Ohua/ALang/Passes.hs
haskell
| Module : $Header$ Description : Passes over algorithm language terms to ensure certain invariants License : EPL-1.0 Stability : experimental Portability : portable This module implements a set of passes over ALang which perform various tasks. The most important function is `normalize`, which tran...
Copyright : ( c ) 2017 . All Rights Reserved . Maintainer : , This source code is licensed under the terms described in the associated LICENSE.TXT file # LANGUAGE CPP # # LANGUAGE ScopedTypeVariables # module Ohua.ALang.Passes where import Ohua.Prelude import Control.Comonad (extract) import Control.M...
ad49569e7d17aff8b3dc6a5f34bfa6e3b1baa1f9178187c084e48655913920f7
tezos/tezos-mirror
interpreter_model.ml
(*****************************************************************************) (* *) (* Open Source License *) Copyright ( c ) 2021 Nomadic Labs , < > (* ...
null
https://raw.githubusercontent.com/tezos/tezos-mirror/cdc7a4382ef6dfcd6c73f86d9a29b829b33d18d4/src/proto_016_PtMumbai/lib_benchmarks_proto/interpreter_model.ml
ocaml
*************************************************************************** Open Source License Permission is h...
Copyright ( c ) 2021 Nomadic Labs , < > to deal in the Software without restriction , including without limitation and/or sell copies of the Software , and to permit persons to whom the THE SOFTWARE IS PROVIDED " AS IS " , WITHOUT WARRANTY OF ANY KIND , EXPRESS OR LIABILITY , WHETHER IN A...
17f10ad93035498416c55172171fc4eb9312487cab454301b34502acb29d5d8a
Bogdanp/racket-component
system.rkt
#lang racket/base (require (for-syntax racket/base racket/syntax syntax/parse) racket/contract/base racket/match "component.rkt" "dependency.rkt") (provide (for-syntax component) define-system (contract-out [make-system (-> system-sp...
null
https://raw.githubusercontent.com/Bogdanp/racket-component/1d0b73fd482e8ae9388336a1357e5afdb4b6c612/component-lib/component/private/system.rkt
racket
backwards-compat
#lang racket/base (require (for-syntax racket/base racket/syntax syntax/parse) racket/contract/base racket/match "component.rkt" "dependency.rkt") (provide (for-syntax component) define-system (contract-out [make-system (-> system-sp...
ba65b71a4f205d2c70556db965cf455ef2e9f224bf1388dcd67290c1bc882f2d
philnguyen/soft-contract
member.rkt
#lang racket (require soft-contract/fake-contract) (define (member x l) (if (empty? l) empty (if (equal? x (car l)) l (member x (cdr l))))) (provide/contract [member (any/c (listof any/c) . -> . (listof any/c))])
null
https://raw.githubusercontent.com/philnguyen/soft-contract/5e07dc2d622ee80b961f4e8aebd04ce950720239/soft-contract/test/programs/safe/softy/member.rkt
racket
#lang racket (require soft-contract/fake-contract) (define (member x l) (if (empty? l) empty (if (equal? x (car l)) l (member x (cdr l))))) (provide/contract [member (any/c (listof any/c) . -> . (listof any/c))])
c4717164382b923622adc7b504500715b8e5b5fa5407f30a7dcbe5025194f720
nibbula/yew
who-cmds.lisp
;;; who-cmds.lisp - Commands for who . ;;; (in-package :who) (defun who-user-name-list () (append (los-util:user-name-list) (list "am" "i"))) (eval-when (:compile-toplevel :load-toplevel :execute) (defclass lish-user::arg-who-user (lish-user::arg-user) () (:default-initargs :choice-func #'who-user...
null
https://raw.githubusercontent.com/nibbula/yew/a62473dae637fb33a92aa75f260bf77b34cdbcfd/los/who-cmds.lisp
lisp
@@@ There should be an option where it tries to figure out durations for sessions and booted times, like the "last" command. @@@ I can't be bothered to do this correctly now. End
who-cmds.lisp - Commands for who . (in-package :who) (defun who-user-name-list () (append (los-util:user-name-list) (list "am" "i"))) (eval-when (:compile-toplevel :load-toplevel :execute) (defclass lish-user::arg-who-user (lish-user::arg-user) () (:default-initargs :choice-func #'who-user-name-li...
8a2e0532b6076a995e4b630ca58407ddec7141773f9a7f564073dd6ac26d889d
samrushing/irken-compiler
hpack.scm
;; -*- Mode: Irken -*- ;; RFC 7541 ;; XXX need to support SETTINGS_MAX_HEADER_LIST_SIZE ;; in order to defend against an 'hpack bomb'. (define (H a b) (:tuple a b)) (define *static-table* #((H "" "") (H ":authority" "") (H ":method" "GET") (H ":method" "POST") (H ":path" "/") (H ":path" ...
null
https://raw.githubusercontent.com/samrushing/irken-compiler/690da48852d55497f873738df54f14e8e135d006/doom/http/hpack.scm
scheme
-*- Mode: Irken -*- RFC 7541 XXX need to support SETTINGS_MAX_HEADER_LIST_SIZE in order to defend against an 'hpack bomb'. a map from header-pair to index in the static table. XXX investigate: this is supposed to be a 'canonical' huffman encoding, which is supposed to have a very compact representation, w...
(define (H a b) (:tuple a b)) (define *static-table* #((H "" "") (H ":authority" "") (H ":method" "GET") (H ":method" "POST") (H ":path" "/") (H ":path" "/index.html") (H ":scheme" "http") (H ":scheme" "https") (H ":status" "200") (H ":status" "204") (H ":status" "206") ...
72a330632d0e051a32ffa53473d340b12a5747f6215bc4a4f6444e1769739c05
GaloisInc/cryptol
RunLexer.hs
-- | -- Module : Main Copyright : ( c ) 2013 - 2016 Galois , Inc. -- License : BSD3 -- Maintainer : -- Stability : provisional -- Portability : portable import Cryptol.Parser.Lexer import Cryptol.Parser.PP main :: IO () main = interact (unlines . map (show . pp) . fst . primLexer)
null
https://raw.githubusercontent.com/GaloisInc/cryptol/8cca24568ad499f06032c2e4eaa7dfd4c542efb6/tests/parser/RunLexer.hs
haskell
| Module : Main License : BSD3 Maintainer : Stability : provisional Portability : portable
Copyright : ( c ) 2013 - 2016 Galois , Inc. import Cryptol.Parser.Lexer import Cryptol.Parser.PP main :: IO () main = interact (unlines . map (show . pp) . fst . primLexer)
59b2a367766a825ea2a520557aa9d7dd2a4e61888fdb3758723fef89b1f63db5
birthevdb/Latent-Effect-and-Handlers
Reader.hs
{-# LANGUAGE RankNTypes #-} # LANGUAGE TypeOperators # {-# LANGUAGE GADTs #-} # LANGUAGE KindSignatures # # LANGUAGE FlexibleContexts # module Effects.Reader where import General data Reading r :: * -> (* -> *) -> * where Local :: (r -> r) -> Reading r a (OneSub a) Ask :: Reading r r NoSub hR...
null
https://raw.githubusercontent.com/birthevdb/Latent-Effect-and-Handlers/398167aa3a18572afa1ecc9ecdd6b37c97495f90/Effects/Reader.hs
haskell
# LANGUAGE RankNTypes # # LANGUAGE GADTs #
# LANGUAGE TypeOperators # # LANGUAGE KindSignatures # # LANGUAGE FlexibleContexts # module Effects.Reader where import General data Reading r :: * -> (* -> *) -> * where Local :: (r -> r) -> Reading r a (OneSub a) Ask :: Reading r r NoSub hRead :: Functor l => r -> Tree (Readi...
7badb05fc455c00e6710f8182684b288bad957667aa3e0d054be140cd8afcd08
fortytools/holumbus
Grammar.hs
-- ---------------------------------------------------------------------------- | Module : Holumbus . Query . Language . Grammar Copyright : Copyright ( C ) 2007 , 2008 License : MIT Maintainer : ( ) Stability : experimental Portability : portable Version : 0.2 ...
null
https://raw.githubusercontent.com/fortytools/holumbus/4b2f7b832feab2715a4d48be0b07dca018eaa8e8/searchengine/source/Holumbus/Query/Language/Grammar.hs
haskell
---------------------------------------------------------------------------- ---------------------------------------------------------------------------- * Query data types * Optimizing | The query language. ^ Single case-insensitive word. ^ Single case-insensitive phrase. ^ Single case-sensitive word. ^ Singl...
| Module : Holumbus . Query . Language . Grammar Copyright : Copyright ( C ) 2007 , 2008 License : MIT Maintainer : ( ) Stability : experimental Portability : portable Version : 0.2 The Holumbus query language definition . The specific syntax of any qu...
50d2716cca7b9ffca5e0e8ce0817e4a01ae0eaf01a34a42f7b0bc1723e5a9e90
ocsigen/js_of_ocaml
test.ml
(* TEST *) let is_nan2 (x, y) = Float.is_nan x && Float.is_nan y type test = True of (unit -> bool) | False of (unit -> bool) | Equal of ((unit -> float) * float) | Pair of ((unit -> float * float) * (float * float)) let cases = [ ( 1, True (fun () -> Float.is_finite 1.)); ( 2, True...
null
https://raw.githubusercontent.com/ocsigen/js_of_ocaml/31c8a3d9d4e34f3fd573dd5056e733233ca4f4f6/compiler/tests-ocaml/lib-float/test.ml
ocaml
TEST tie resolve differently tie resolve differently
let is_nan2 (x, y) = Float.is_nan x && Float.is_nan y type test = True of (unit -> bool) | False of (unit -> bool) | Equal of ((unit -> float) * float) | Pair of ((unit -> float * float) * (float * float)) let cases = [ ( 1, True (fun () -> Float.is_finite 1.)); ( 2, True (fun () ->...
8969054f4c79e32e63b14e8d3795fab85c87a93a5eceef37da9db9392fe69439
vmchale/kempe
IR.hs
module Kempe.IR ( writeModule , runTempM , TempM , prettyIR , WriteSt (..) , size ) where import Data.Foldable (toList, traverse_) import Data.List.NonEmpty (NonEmpty (..)) import qu...
null
https://raw.githubusercontent.com/vmchale/kempe/aac73a386390747c0a54819d63c7438b54cdb168/src/Kempe/IR.hs
haskell
strict b/c it's faster according to benchmarks TODO: type sizes in state optimize tail-recursion, if possible This is a little slow ^ Can it be optimized here? FIXME: just use expressions from memory accesses | This throws exceptions on nonsensical input. ^ Can we do TCO? what to do on failure? move data poin...
module Kempe.IR ( writeModule , runTempM , TempM , prettyIR , WriteSt (..) , size ) where import Data.Foldable (toList, traverse_) import Data.List.NonEmpty (NonEmpty (..)) import qu...
4534e63017c29d75af46b78710f1ffb5f8ad3e08a5f5346a084d697f4044d77b
hbr/fmlib
result.mli
(** Result: Handling results of operations which can fail *) (** {1 Overview} *) (** Operations returning a result type can be used to have some {i functional exception handling}. Let's say that you have some operatios returning a result object. {[ let op1 ... : (int, error) result = ...
null
https://raw.githubusercontent.com/hbr/fmlib/92ac0e65db09375fad79029072e0c45e80d2586f/src/std/result.mli
ocaml
* Result: Handling results of operations which can fail * {1 Overview} * Operations returning a result type can be used to have some {i functional exception handling}. Let's say that you have some operatios returning a result object. {[ let op1 ... : (int, error) result = ... l...
| Error e -> ]} A simple example: {[ type 'a r = ('a, string) result let add (a: int r) (b: int r): int r = let* x = a in let* y = b in Ok (x + y) let divide (a: int r) (b: int r): int r = let* x = a in let* y...
018bc55bf3856707c4e6838a773423cd9b3954bd3f59458ad664e427a3371664
cubicle-model-checker/cubicle
symbols.mli
(**************************************************************************) (* *) Cubicle (* *) ...
null
https://raw.githubusercontent.com/cubicle-model-checker/cubicle/00f09bb2d4bb496549775e770d7ada08bc1e4866/smt/symbols.mli
ocaml
************************************************************************ ...
Cubicle Copyright ( C ) 2011 - 2014 and Universite Paris - Sud 11 This file is distributed under the terms ...
76f12d591d167e0c8232b5caa3dd1f503fb18c43e252383c5cfec8c49bbab106
mariachris/Concuerror
depend_4.erl
-module(depend_4). -export([depend_4/0]). -export([scenarios/0]). scenarios() -> [{?MODULE, inf, dpor}]. depend_4() -> ets:new(table, [public, named_table]), ets:insert(table, {x, 0}), ets:insert(table, {y, 0}), ets:insert(table, {z, 0}), spawn(fun() -> ets:insert(table, {z, 1}) end), spawn(f...
null
https://raw.githubusercontent.com/mariachris/Concuerror/87e63f10ac615bf2eeac5b0916ef54d11a933e0b/testsuite/suites/dpor/src/depend_4.erl
erlang
-module(depend_4). -export([depend_4/0]). -export([scenarios/0]). scenarios() -> [{?MODULE, inf, dpor}]. depend_4() -> ets:new(table, [public, named_table]), ets:insert(table, {x, 0}), ets:insert(table, {y, 0}), ets:insert(table, {z, 0}), spawn(fun() -> ets:insert(table, {z, 1}) end), spawn(f...
5b985cc388a746bcaa6645784bad261d7162f4fc0e8989e1c3e0f1c61a89273f
expipiplus1/vulkan
Write.hs
module Render.Element.Write where import Data.Char ( isLower ) import Data.List ( lookup ) import Data.List.Extra ( groupOn , nubOrd , n...
null
https://raw.githubusercontent.com/expipiplus1/vulkan/70d8cca16893f8de76c0eb89e79e73f5a455db76/generate-new/src/Render/Element/Write.hs
haskell
-------------------------------------------------------------- Rendering -------------------------------------------------------------- Boot module handling TODO: do this segmentation properly, nubbing here is nasty Write the files ^ out directory ^ Is a boot file | If we are importing constructors of a type...
module Render.Element.Write where import Data.Char ( isLower ) import Data.List ( lookup ) import Data.List.Extra ( groupOn , nubOrd , n...
a2204c6ab7d9e31d259bbf370b6a439472511207f82809c29d93b216fa6e79c1
kiranlak/austin-sbst
baseObjValue.ml
module Log = LogManager type branchCovObjVal = { appLevel : int; branchDist : float; } type objectiveValue = Simple of float | BranchCoverage of branchCovObjVal let mkBranchCovObjVal (a:int) (bd:float) = BranchCoverage({appLevel=a;branchDist=bd}) let compareObjVal (o1:objectiveValue) (o2:objectiveValue) = mat...
null
https://raw.githubusercontent.com/kiranlak/austin-sbst/9c8aac72692dca952302e0e4fdb9ff381bba58ae/AustinOcaml/searchMethods/objectives/baseObjValue.ml
ocaml
module Log = LogManager type branchCovObjVal = { appLevel : int; branchDist : float; } type objectiveValue = Simple of float | BranchCoverage of branchCovObjVal let mkBranchCovObjVal (a:int) (bd:float) = BranchCoverage({appLevel=a;branchDist=bd}) let compareObjVal (o1:objectiveValue) (o2:objectiveValue) = mat...
6477f509c2823cf90057c18a2ade4ec4e7d3b26902f24feae86e0001327aa9d6
yuriy-chumak/ol
joystick.scm
(define-library (lib joystick) (version 1.0) (license MIT/LGPL3) (description "joystick support library") (import (otus lisp) (otus ffi)) (export axis-count buttons-count read-event) (cond-expand (Windows (begin #false )) (Android (begin #false )) ...
null
https://raw.githubusercontent.com/yuriy-chumak/ol/37bbcbf67b058e54f646d81d368c73c214ea92b2/libraries/lib/joystick.scm
scheme
/usr/include/linux/joystick.h JSIOCGBUTTONS
(define-library (lib joystick) (version 1.0) (license MIT/LGPL3) (description "joystick support library") (import (otus lisp) (otus ffi)) (export axis-count buttons-count read-event) (cond-expand (Windows (begin #false )) (Android (begin #false )) ...
230d3b044e70d94ee0f2eeead07d5e23766a0137ea57a73c08e6d3046e56a237
cabol/west
west_util.erl
%% ------------------------------------------------------------------- %% Copyright ( c ) 2013 , Inc. All Rights Reserved . %% 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 ...
null
https://raw.githubusercontent.com/cabol/west/c3c31dff9ad727ce9b82dde6eb690f7b11cd4d24/src/west_util.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 permissio...
Copyright ( c ) 2013 , Inc. All Rights Reserved . 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 @author < > ( C...
c995b6ad9b030d2664b59b404595dc968f2abfefa200b6575405429faae183c5
webyrd/mediKanren
read.rkt
#lang racket/base (provide read-all read-all/stream read-all-from-file ) (require racket/stream ) (define (read-all in) (define datum (read in)) (if (eof-object? datum) '() (cons datum (read-all in)))) (define (read-all/stream in) (define datum (read in)) (if (eof-object? datum) '() (stream-cons ...
null
https://raw.githubusercontent.com/webyrd/mediKanren/a2b80ea94f66bcdd4305b9369ad4184c2afe9829/attic/code/read.rkt
racket
#lang racket/base (provide read-all read-all/stream read-all-from-file ) (require racket/stream ) (define (read-all in) (define datum (read in)) (if (eof-object? datum) '() (cons datum (read-all in)))) (define (read-all/stream in) (define datum (read in)) (if (eof-object? datum) '() (stream-cons ...
83b2309a4d26e34beed0f5743fc3a310ba044ec7534b3f96fce519799dc1f4ec
brendanhay/terrafomo
Provider.hs
-- This module is auto-generated. # LANGUAGE NoImplicitPrelude # # LANGUAGE RecordWildCards # # LANGUAGE StrictData # # OPTIONS_GHC -fno - warn - unused - imports # -- | Module : . MySQL.Provider Copyright : ( c ) 2017 - 2018 License : Mozilla Public License , v. 2.0 . Maintainer ...
null
https://raw.githubusercontent.com/brendanhay/terrafomo/387a0e9341fb9cd5543ef8332dea126f50f1070e/provider/terrafomo-mysql/gen/Terrafomo/MySQL/Provider.hs
haskell
This module is auto-generated. | Stability : auto-generated * MySQL Specific Aliases * MySQL Configuration - (Required) ^ @password@ - (Optional) ^ @username@ - (Required) | Specify a new MySQL provider configuration. See the < terraform documentation> for more information. ^ The minimal/required argume...
# LANGUAGE NoImplicitPrelude # # LANGUAGE RecordWildCards # # LANGUAGE StrictData # # OPTIONS_GHC -fno - warn - unused - imports # Module : . MySQL.Provider Copyright : ( c ) 2017 - 2018 License : Mozilla Public License , v. 2.0 . Maintainer : < brendan.g.hay+ > Portability ...
bc3f7bc5cfce6c79acd3b3982984a6efa082b5d67b1e63fc033839d73ac5e429
thephoeron/cl-isaac
isaac-64.lisp
-*- Mode : LISP ; Syntax : COMMON - LISP ; Package : CL - ISAAC ; Base : 10 -*- file : isaac-64.lisp Copyright ( c ) 2008 , Copyright ( c ) 2014 - 2022 , " the Phoeron " BSD license : you can do anything you want with it ( but no warranty ) . (in-package #:cl-isaac) TODO : proof these against ISAAC-6...
null
https://raw.githubusercontent.com/thephoeron/cl-isaac/9cd88f39733be753facbf361cb0e08b9e42ff8d5/isaac-64.lisp
lisp
Syntax : COMMON - LISP ; Package : CL - ISAAC ; Base : 10 -*- file : isaac-64.lisp golden ratio scramble it Pass #1 Pass #2
Copyright ( c ) 2008 , Copyright ( c ) 2014 - 2022 , " the Phoeron " BSD license : you can do anything you want with it ( but no warranty ) . (in-package #:cl-isaac) TODO : proof these against ISAAC-64 implementation from (defstruct isaac64-ctx (randcnt 0 :type (unsigned-byte 64)) (randrsl (make-...
e2c5b24b55b7a7d629b9f809318b72de16c10c0b9176be47015ee39ee5c9fb83
ocamllabs/ocaml-modular-implicits
t041-makeblock.ml
type t = { mutable a : int; mutable b : int; mutable c : int; mutable d : int; };; { a = 0; b = 0; c = 0; d = 0 };; * 0 CONST0 1 PUSHCONST0 2 PUSHCONST0 3 PUSHCONST0 4 MAKEBLOCK 4 , 0 7 ATOM0 8 SETGLOBAL T041 - makeblock 10 STOP * ...
null
https://raw.githubusercontent.com/ocamllabs/ocaml-modular-implicits/92e45da5c8a4c2db8b2cd5be28a5bec2ac2181f1/testsuite/tests/tool-ocaml/t041-makeblock.ml
ocaml
type t = { mutable a : int; mutable b : int; mutable c : int; mutable d : int; };; { a = 0; b = 0; c = 0; d = 0 };; * 0 CONST0 1 PUSHCONST0 2 PUSHCONST0 3 PUSHCONST0 4 MAKEBLOCK 4 , 0 7 ATOM0 8 SETGLOBAL T041 - makeblock 10 STOP * ...
862fdf7d3294ffe37fd554f6f340abca1018bfd81e8136cd979c1e03dcc37d80
mirage/mirage
mirage_impl_kv.ml
open Functoria open Astring module Key = Mirage_key type ro = RO let ro = Type.v RO let crunch dirname = let is_valid = function | '0' .. '9' | 'a' .. 'z' | 'A' .. 'Z' -> true | _ -> false in let modname = String.filter is_valid dirname in let name = "Static_" ^ String.Ascii.lowercase modname in le...
null
https://raw.githubusercontent.com/mirage/mirage/68bc2f914daf6b1936c98638ad3648388cd03ebc/lib/mirage/impl/mirage_impl_kv.ml
ocaml
open Functoria open Astring module Key = Mirage_key type ro = RO let ro = Type.v RO let crunch dirname = let is_valid = function | '0' .. '9' | 'a' .. 'z' | 'A' .. 'Z' -> true | _ -> false in let modname = String.filter is_valid dirname in let name = "Static_" ^ String.Ascii.lowercase modname in le...
ba6d2acb1467d26dd93ea54edceec4e520aea10427c61788a8ba71a3d9d6a66c
spurious/sagittarius-scheme-mirror
cgen.scm
;; -*- Scheme -*- CGen , originally from Gauche ;; This library just exports all variables from ( sagittarius cgen cise ) and ( sagittarius cgen unit ) . These 2 libraries do not depend on Sagittarius ;; headers. So it can be used for normal C generator (I guess). #!core (library (sagittarius cgen) (export :a...
null
https://raw.githubusercontent.com/spurious/sagittarius-scheme-mirror/53f104188934109227c01b1e9a9af5312f9ce997/sitelib/sagittarius/cgen.scm
scheme
-*- Scheme -*- headers. So it can be used for normal C generator (I guess).
CGen , originally from Gauche This library just exports all variables from ( sagittarius cgen cise ) and ( sagittarius cgen unit ) . These 2 libraries do not depend on Sagittarius #!core (library (sagittarius cgen) (export :all) (import (sagittarius cgen cise) (sagittarius cgen unit)))
45b2ade75ec8a6723b0d7d2d2c16561503ec6b0f37046372463b4d8e64ae5e48
oxidizing/sihl-starter
service.ml
(* Kernel services *) module Random = Sihl.Utils.Random.Service.Make () module Log = Sihl.Log.Service.Make () module Config = Sihl.Config.Service.Make (Log) module Db = Sihl.Data.Db.Service.Make (Config) (Log) module MigrationRepo = Sihl.Data.Migration.Service.Repo.MakeMariaDb (Db) module Cmd = Sihl.Cmd.Service.Make...
null
https://raw.githubusercontent.com/oxidizing/sihl-starter/d9867089892f34afcb1519c4c8fb4328c062f5a7/service.ml
ocaml
Kernel services Configuration providers Repositories Services
module Random = Sihl.Utils.Random.Service.Make () module Log = Sihl.Log.Service.Make () module Config = Sihl.Config.Service.Make (Log) module Db = Sihl.Data.Db.Service.Make (Config) (Log) module MigrationRepo = Sihl.Data.Migration.Service.Repo.MakeMariaDb (Db) module Cmd = Sihl.Cmd.Service.Make () module Migration ...
a9158c176da3c690a41c928b282abcedc045aaa2b2c98d947adbba8369def9d2
ahungry/ahungry-fleece
af.lib.ansi-colors.lisp
- A utility library . Copyright ( C ) 2016 < > ;; ;; This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or ;; (at your option) any later version. ;;...
null
https://raw.githubusercontent.com/ahungry/ahungry-fleece/1cef1d3a3aa9cffe9f06b7632006565bbc986814/src/libs/af.lib.ansi-colors.lisp
lisp
This program is free software: you can redistribute it and/or modify (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 PURPOSE. See the GNU Affero General...
- A utility library . Copyright ( C ) 2016 < > it under the terms of the GNU Affero General Public License as published by the Free Software Foundation , either version 3 of the License , or You should have received a copy of the GNU Affero General Public License (in-package #:cl-user) (defpackage af....
adf1bd9a9ded13eedbe16ba9dad785adc98b49b6eb46ab566b4fd8a3d67c2d7f
huiyaozheng/Mirage-zmq
config.ml
open Mirage let main = foreign ~packages:[package "mirage-zmq"] "Unikernel.Main" (stackv4 @-> job) let stack = generic_stackv4 default_network let () = register "sub_unikernel" [ main $ stack ]
null
https://raw.githubusercontent.com/huiyaozheng/Mirage-zmq/af288a3378a7c357bd5646a3abf4fd5ae777369b/test/SUB/unikernel/config.ml
ocaml
open Mirage let main = foreign ~packages:[package "mirage-zmq"] "Unikernel.Main" (stackv4 @-> job) let stack = generic_stackv4 default_network let () = register "sub_unikernel" [ main $ stack ]
f83241ddcac1d66a3da129a4272c5f460459c3cca21a528d14ea61c01774a686
cldm/cldm
config.lisp
(in-package :cldm) (defparameter *libraries-directory* (pathname "~/.cldm/cache/libraries/")) (defparameter *local-libraries-directory* (merge-pathnames (pathname "lib/") (osicat:current-directory))) (defparameter *verbose-mode* nil "When true, verbose messages are displayed on the standard output") (defpa...
null
https://raw.githubusercontent.com/cldm/cldm/899f1a92d52245ef0fc84d073ac35c4b0d2e9609/src/config.lisp
lisp
Configuration files If successful, add it to the repositories list
(in-package :cldm) (defparameter *libraries-directory* (pathname "~/.cldm/cache/libraries/")) (defparameter *local-libraries-directory* (merge-pathnames (pathname "lib/") (osicat:current-directory))) (defparameter *verbose-mode* nil "When true, verbose messages are displayed on the standard output") (defpa...
6ed456b5278473d2326409da62e709a5a7b14e38cb24cb21f1fb87d54d0936d8
mfoemmel/erlang-otp
wxListCtrl.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 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 Public Lic...
null
https://raw.githubusercontent.com/mfoemmel/erlang-otp/9c6fdd21e4e6573ca6f567053ff3ac454d742bc2/lib/wx/api_gen/wx_extra/wxListCtrl.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 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 " <<EXPORT:SortItems sortItems/2 SortItems:EXPORT>> ...
880ca667638d526f33d52b178c3fa9d4c004c61d1fe0792f6bb8001002162381
reenberg/wobot
Flask.dump.hs
v0 :: Float v0 = let { v = 0.0 :: Float } in v v1 :: (Float, Float) -> (Float, Float) v1 = let { v = (\(x, prev) -> let { cur = 0.5 * x + 0.5 * prev } in (,) cur cur) :: ((Float, Float) -> (Float, Float)) } in v v2 :: Integer v2 = let { v = 0 :: Integer } in v f0 :: ((), Integer) -> (Flo...
null
https://raw.githubusercontent.com/reenberg/wobot/ce7f112096ba1abd43b8d29da7e8944c2a004125/flask/examples/ewma/Flask.dump.hs
haskell
v0 :: Float v0 = let { v = 0.0 :: Float } in v v1 :: (Float, Float) -> (Float, Float) v1 = let { v = (\(x, prev) -> let { cur = 0.5 * x + 0.5 * prev } in (,) cur cur) :: ((Float, Float) -> (Float, Float)) } in v v2 :: Integer v2 = let { v = 0 :: Integer } in v f0 :: ((), Integer) -> (Flo...
27123656f882fe546bec9ac251b0c3cdb3f1232b716371b5472f9cfd40577a43
henryw374/time-literals
data_readers_cljs.cljc
(ns time-literals.data-readers-cljs (:refer-clojure :exclude [time]) #?(:cljs (:require [java.time :refer [Period LocalDate LocalDateTime ZonedDateTime OffsetTime ...
null
https://raw.githubusercontent.com/henryw374/time-literals/dcc01d0e814139013ba1fbe800d2f099042da404/src/time_literals/data_readers_cljs.cljc
clojure
(ns time-literals.data-readers-cljs (:refer-clojure :exclude [time]) #?(:cljs (:require [java.time :refer [Period LocalDate LocalDateTime ZonedDateTime OffsetTime ...
c583ea9240e108fe90363999e2df23edb8ea469d23b9e34e78e01610378e5659
dysinger/restack
config.ml
open Mirage let main = foreign ~packages:[ package "reason"; package "duration"; ] "Unikernel.Hello" (time @-> job) let () = register "hello" [main $ default_time]
null
https://raw.githubusercontent.com/dysinger/restack/ef8ac0ae0542f1d81d7bd3032c6077149d403d68/000-hello-world/config.ml
ocaml
open Mirage let main = foreign ~packages:[ package "reason"; package "duration"; ] "Unikernel.Hello" (time @-> job) let () = register "hello" [main $ default_time]
edba15617ad48a00a6cfc53da1cccecf6e835e74635add97a5b0cebb7a958d3a
holdenlee/depgraph
ParseUtilities.hs
{-# OPTIONS -XMultiParamTypeClasses -XFunctionalDependencies -XFlexibleInstances -XRank2Types -XGADTs -XPolyKinds #-} module ParseUtilities ( ProgramInfo (current, deps, fields, currentFile), emptyPI, insertDep, insertSF, insertSF2, lookupSF, insertField, ProgramParser, ioFile, ioFiles, fieldsParser,...
null
https://raw.githubusercontent.com/holdenlee/depgraph/30081e9b8acb1083970dec47f7c753bcd47eb534/ParseUtilities.hs
haskell
# OPTIONS -XMultiParamTypeClasses -XFunctionalDependencies -XFlexibleInstances -XRank2Types -XGADTs -XPolyKinds # , names:: Map.Map String String display names , labels:: Map.Map String String} deriving Show insertName:: String -> ProgramInfo -> ProgramInfo parses eol automatically? does this pres...
module ParseUtilities ( ProgramInfo (current, deps, fields, currentFile), emptyPI, insertDep, insertSF, insertSF2, lookupSF, insertField, ProgramParser, ioFile, ioFiles, fieldsParser, readFields, chain, chainPI, getFile) where import System.Environment import System.Directory import System.IO import Contro...
0ea8a085381246a192fbe824b236d23975ad1cfddab710bdf516a28e50497d5f
apache/couchdb-chttpd
chttpd_handlers_tests.erl
Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not % use this file except in compliance with the License. You may obtain a copy of % the License at % % -2.0 % % Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an " A...
null
https://raw.githubusercontent.com/apache/couchdb-chttpd/74002101513c03df74a4c25f3c892f5d003fa5da/test/chttpd_handlers_tests.erl
erlang
use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations...
Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not distributed under the License is distributed on an " AS IS " BASIS , WITHOUT -module(chttpd_handlers_tests). -include_lib("couch/include/couch_eunit.hrl"). -include_lib("couch/include/couch_db.hrl"). setup() -> Addr = config:g...
4a7800d39b2fb549ade66b0872fd2295c1305ba73d1bb76f36cdb4bca3b919a7
locusmath/locus
object.clj
(ns locus.algebra.groupoid.core.object (:require [locus.set.logic.core.set :refer :all] [locus.set.logic.limit.product :refer :all] [locus.set.logic.sequence.object :refer :all] [locus.con.core.setpart :refer :all] [locus.set.mapping.general.core.object :refer :all] ...
null
https://raw.githubusercontent.com/locusmath/locus/b232579217be4e39458410893827a84d744168e4/src/clojure/locus/algebra/groupoid/core/object.clj
clojure
A category C has isomorphisms for every object. A groupoid is a category C for which each morphism is an isomorphism, meaning that if f: A -> B is a morphism there always exists conversion routines for groups and setoids to convert them to groupoids. The position of groupoids within the type hierarchy Underlying r...
(ns locus.algebra.groupoid.core.object (:require [locus.set.logic.core.set :refer :all] [locus.set.logic.limit.product :refer :all] [locus.set.logic.sequence.object :refer :all] [locus.con.core.setpart :refer :all] [locus.set.mapping.general.core.object :refer :all] ...
3190174853f0f08324052c3270da20d02214954a7eb5022d6a906ded4494a7df
dbuenzli/mu
scales.ml
(* This code is in the public domain *) open Mu open Mu.Syntax type scale = Pitch.rel list let major = [2; 2; 1; 2; 2; 2] let hexatonic_blues = [3; 2; 1; 1; 3] let make_scale : Pitch.t -> scale -> Pitch.t list = fun p scale -> let next acc rel = Pitch.transp rel (List.hd acc) :: acc in List.rev (List.fold_left ...
null
https://raw.githubusercontent.com/dbuenzli/mu/f6028ba4515bd49eb076b7394dee39e8f35e13fa/test/scales.ml
ocaml
This code is in the public domain
open Mu open Mu.Syntax type scale = Pitch.rel list let major = [2; 2; 1; 2; 2; 2] let hexatonic_blues = [3; 2; 1; 1; 3] let make_scale : Pitch.t -> scale -> Pitch.t list = fun p scale -> let next acc rel = Pitch.transp rel (List.hd acc) :: acc in List.rev (List.fold_left next [p] scale) let play_scale p scale ...
9e43439e7a243c4e1642c7836debb439dd6eca3c9f25e0323370475b655b0bb1
mgsloan/instance-templates
Test.hs
# LANGUAGE TemplateHaskell , , ScopedTypeVariables , FlexibleInstances , FlexibleContexts # TemplateHaskell , ConstraintKinds , ScopedTypeVariables , FlexibleInstances , FlexibleContexts #-} module Test where import Classes import Prelude ( Int, (>>), (.) ) import qualified Prelude as ...
null
https://raw.githubusercontent.com/mgsloan/instance-templates/734f3fe838f194b613a270c2e1eb9502b73840a6/tests/numeric/Test.hs
haskell
This is just for prettier -ddump-splices
# LANGUAGE TemplateHaskell , , ScopedTypeVariables , FlexibleInstances , FlexibleContexts # TemplateHaskell , ConstraintKinds , ScopedTypeVariables , FlexibleInstances , FlexibleContexts #-} module Test where import Classes import Prelude ( Int, (>>), (.) ) import qualified Prelude as ...
3e07963f6e9b0ce9dba083be2d3b15fc52533d7bdb0f4e45734610f68bc6d56e
project-oak/hafnium-verification
cVar_decl.mli
* Copyright ( c ) Facebook , Inc. and its 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) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the ...
null
https://raw.githubusercontent.com/project-oak/hafnium-verification/6071eff162148e4d25a0fedaea003addac242ace/experiments/ownership-inference/infer/infer/src/clang/cVar_decl.mli
ocaml
* Process variable declarations by saving them as local or global variables.
* Copyright ( c ) Facebook , Inc. and its 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) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the ...
19b51e5ecd54659f33509ced63450d7c986807808bfc0272a02341faf901979c
vindarel/replic
config.lisp
(defpackage replic.config (:use :cl) (:import-from :replic.utils :truthy :falsy) (:export :apply-config :read-config :has-option-p :option)) (in-package :replic.config) (defvar *cfg-file* ".replic.conf" "Default name of the config file.") (defv...
null
https://raw.githubusercontent.com/vindarel/replic/23962f901c3c6f983893f0445e40195610e3df1f/src/config.lisp
lisp
Setting here and not in defparameter: ensure this is the user's value, not where the binary was built on. xxx verbose (format t "reading config ~a~&" it) read-files reads a list. :PACKAGE -> "package" section name. Apply replic's default config: - search for them without earmuffs in the config file, - get the...
(defpackage replic.config (:use :cl) (:import-from :replic.utils :truthy :falsy) (:export :apply-config :read-config :has-option-p :option)) (in-package :replic.config) (defvar *cfg-file* ".replic.conf" "Default name of the config file.") (defv...
3b2c027b930dff21e31ec85e744a8af52df77fb6467156e6a3d0e05502a33756
braintripping/lark
registry.cljs
(ns lark.commands.registry (:require [goog.object :as gobj] [clojure.string :as string] [clojure.set :as set] [goog.events :as events] ["@braintripping/keypress.js" :refer [keypress]])) (gobj/set (gobj/get js/window "goog" "events") "listen" events/listen) (defonce Key...
null
https://raw.githubusercontent.com/braintripping/lark/95038a823068681c39453c46a309a3514cf48800/tools/src/lark/commands/registry.cljs
clojure
we don't care what order modifiers are pressed
(ns lark.commands.registry (:require [goog.object :as gobj] [clojure.string :as string] [clojure.set :as set] [goog.events :as events] ["@braintripping/keypress.js" :refer [keypress]])) (gobj/set (gobj/get js/window "goog" "events") "listen" events/listen) (defonce Key...
627d6c806577095e2aff364a12d89aabb7bebfc853a7cb1eb91d12af10586d44
keigoi/ocaml-mpst
chan.ml
module Q = Queue module M = Monitor type 'a t = ('a Q.t ref) M.t let create () : 'a t = M.create (ref (Q.create ())) let send (t : 'a t) (v:'a) : unit = M.lock t (fun q -> Q.add v !q; M.signal t) let receive (t:'a t) : 'a = M.wait t (fun q -> if Q.is_empty !q then M.WaitMore else M.Return...
null
https://raw.githubusercontent.com/keigoi/ocaml-mpst/daae64bc9fe1d10213b9e73e22a10ccc5a0426cd/lib/bare/chan.ml
ocaml
module Q = Queue module M = Monitor type 'a t = ('a Q.t ref) M.t let create () : 'a t = M.create (ref (Q.create ())) let send (t : 'a t) (v:'a) : unit = M.lock t (fun q -> Q.add v !q; M.signal t) let receive (t:'a t) : 'a = M.wait t (fun q -> if Q.is_empty !q then M.WaitMore else M.Return...
741b88a51e151843d50ca450b79d016e9095ed337470ff60b1d5fab29e53106b
abakst/Brisk
Env.hs
module Brisk.Model.Env (empty, lookup, insert, addsEnv, unionEnvs, toList, Env(..)) where import Prelude hiding (lookup, insert) import qualified Data.Map.Strict as M type Env k v = M.Map k v empty :: Ord k => M.Map k v empty = M.empty lookup :: Ord k => M.Map k v -> k -> Maybe v lookup e k = M.looku...
null
https://raw.githubusercontent.com/abakst/Brisk/3e4ce790a742d3e3b786dba45d36f715ea0e61ef/src/Brisk/Model/Env.hs
haskell
module Brisk.Model.Env (empty, lookup, insert, addsEnv, unionEnvs, toList, Env(..)) where import Prelude hiding (lookup, insert) import qualified Data.Map.Strict as M type Env k v = M.Map k v empty :: Ord k => M.Map k v empty = M.empty lookup :: Ord k => M.Map k v -> k -> Maybe v lookup e k = M.looku...
b1ff8a2a69483b1888525de19182e234ed9547a6c6dfe82cddb74dcfaef50a1b
hanshuebner/bknr-datastore
encoding-test.lisp
(in-package :bknr.datastore) (5am:def-suite :bknr.datastore) (5am:in-suite :bknr.datastore) (defun files-identical-content-p (path-a path-b) "Are files of PATH-A and PATH-B byte per byte identical?" (with-open-file (in-a path-a :element-type '(unsigned-byte 8)) (with-open-file (in-b path-b :element-type '(uns...
null
https://raw.githubusercontent.com/hanshuebner/bknr-datastore/c98d44f47cc88d19ff91ca3eefbd9719a8ace022/src/data/encoding-test.lisp
lisp
from cl-store :) ratios complex numbers - currently not supported (test-encoding complex.2 #C(0.0 1.0)) (test-encoding complex.3 #C(32 -23455)) (test-encoding complex.5 #C(-111 -1123)) (test-encoding complex.6 #C(-11.2 -34.5)) single-float double-float characters strings #\? is the substitution char above ...
(in-package :bknr.datastore) (5am:def-suite :bknr.datastore) (5am:in-suite :bknr.datastore) (defun files-identical-content-p (path-a path-b) "Are files of PATH-A and PATH-B byte per byte identical?" (with-open-file (in-a path-a :element-type '(unsigned-byte 8)) (with-open-file (in-b path-b :element-type '(uns...
b65ce0392d4a368c874bc57fac395301edcc4bd39bb96c3fa03d62c3d748c538
alanb2718/wallingford
compiled-quadrilateral.rkt
#lang s-exp rosette ; hand compiled code for quadrilateral.rkt (require "../applications/geothings.rkt") (require "../reactive/reactive.rkt") (require "../reactive/abstract-reactive-thing.rkt") (require "compiled-reactive-thing.rkt") (require "../rhea/rhea.rkt") ; this is a symlink in the wallingford/ directory to th...
null
https://raw.githubusercontent.com/alanb2718/wallingford/9dd436c29f737d210c5b87dc1b86b2924c0c5970/compiled-reactive/compiled-quadrilateral.rkt
racket
hand compiled code for quadrilateral.rkt this is a symlink in the wallingford/ directory to the actual rhea directory join the corners of the quadrilateral add stays with explicit priorities to disambiguate behavior list of all the corners and midpoints for dragging the image for this is a list of the current val...
#lang s-exp rosette (require "../applications/geothings.rkt") (require "../reactive/reactive.rkt") (require "../reactive/abstract-reactive-thing.rkt") (require "compiled-reactive-thing.rkt") functions to make symbolic objects using Cassowary variables (define (make-cassowary-point x y) (point (new cassowary-variab...
083648204f3f39cadf0908a800fd0d011913448e9c52e372df8f0df84c32f764
apache/couchdb-ddoc-cache
ddoc_cache_sup.erl
Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not % use this file except in compliance with the License. You may obtain a copy of % the License at % % -2.0 % % Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an " A...
null
https://raw.githubusercontent.com/apache/couchdb-ddoc-cache/c762e90a33ce3cda19ef142dd1120f1087ecd876/src/ddoc_cache_sup.erl
erlang
use this file except in compliance with the License. You may obtain a copy of the License at -2.0 Unless required by applicable law or agreed to in writing, software WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations...
Licensed under the Apache License , Version 2.0 ( the " License " ) ; you may not distributed under the License is distributed on an " AS IS " BASIS , WITHOUT -module(ddoc_cache_sup). -behaviour(supervisor). -export([ start_link/0, init/1 ]). start_link() -> supervisor:start_link({local, ?MODULE}, ...
22f8d3665ba91ae9af3af629a5af122095088b88d1e2b101e26e4311f1fdbd26
DaveWM/lobster-writer
views.cljs
(ns lobster-writer.views (:require [re-frame.core :as re-frame] [lobster-writer.subs :as subs] [lobster-writer.events :as events] [lobster-writer.components.editable-list :refer [editable-list]] [lobster-writer.utils :as utils] [lobster-writer.constants :as constants] [lobster-writer.compo...
null
https://raw.githubusercontent.com/DaveWM/lobster-writer/de40ee73d612abd1cdb4281e61a604f73afb215d/src/cljs/lobster_writer/views.cljs
clojure
home
(ns lobster-writer.views (:require [re-frame.core :as re-frame] [lobster-writer.subs :as subs] [lobster-writer.events :as events] [lobster-writer.components.editable-list :refer [editable-list]] [lobster-writer.utils :as utils] [lobster-writer.constants :as constants] [lobster-writer.compo...
72c7fc5690f84389872610dd3e5fb5cf68712e18a1592050f3c86eb5e4333d3c
racketscript/racketscript
let-tail-nontail.rkt
#lang racket (define (extract-current-continuation-marks key) (continuation-mark-set->list (current-continuation-marks) key)) (define (main) (define result-a #f) (define result-b #f) (with-continuation-mark 'key 'mark-main (let ([x (add1 0)]) (with-continuation-mark 'key 'mark-let (set...
null
https://raw.githubusercontent.com/racketscript/racketscript/f94006d11338a674ae10f6bd83fc53e6806d07d8/tests/wcm/let-tail-nontail.rkt
racket
#lang racket (define (extract-current-continuation-marks key) (continuation-mark-set->list (current-continuation-marks) key)) (define (main) (define result-a #f) (define result-b #f) (with-continuation-mark 'key 'mark-main (let ([x (add1 0)]) (with-continuation-mark 'key 'mark-let (set...
0336b4eee36698595a2617dda72be14a28d6c244b1563861556496c80a6b38f9
cjohansen/dumdom
dom_test.clj
(ns dumdom.dom-test (:require [clojure.test :refer [deftest testing is]] [dumdom.dom :as sut])) (defn remove-fns [x] (cond-> x (:data x) (update :data dissoc :on :hook))) (defn render [comp] (-> (comp [] 0) remove-fns (update :children #(map remove-fns %)))) (deftest element-test ...
null
https://raw.githubusercontent.com/cjohansen/dumdom/7ad911c2c487253df9caf75d49c2c274d91d0bf7/test/dumdom/dom_test.clj
clojure
(ns dumdom.dom-test (:require [clojure.test :refer [deftest testing is]] [dumdom.dom :as sut])) (defn remove-fns [x] (cond-> x (:data x) (update :data dissoc :on :hook))) (defn render [comp] (-> (comp [] 0) remove-fns (update :children #(map remove-fns %)))) (deftest element-test ...
07ff19a421c9b3f292e858d08125ceeca8d556724462b656a54c2fca4c707297
jherrlin/guitar-theory-training
fretboard_matrix.cljc
(ns v4.se.jherrlin.music-theory.models.fretboard-matrix "Representation of a fretboard as a matrix. Example: [[{:x 0, :tone #{:e}, :y 0} {:x 1, :tone #{:f}, :y 0} {:x 2, :tone #{:gb :f#}, :y 0}] [{:x 0, :tone #{:b}, :y 1} {:x 1, :tone #{:c}, :y 1} {:x 2, :tone #{:db :c#}, :y 1}] [{:x 0, :to...
null
https://raw.githubusercontent.com/jherrlin/guitar-theory-training/fd2866d4bdf314d54f68e39c31f2f3d81da699e2/src/v4/se/jherrlin/music_theory/models/fretboard_matrix.cljc
clojure
(ns v4.se.jherrlin.music-theory.models.fretboard-matrix "Representation of a fretboard as a matrix. Example: [[{:x 0, :tone #{:e}, :y 0} {:x 1, :tone #{:f}, :y 0} {:x 2, :tone #{:gb :f#}, :y 0}] [{:x 0, :tone #{:b}, :y 1} {:x 1, :tone #{:c}, :y 1} {:x 2, :tone #{:db :c#}, :y 1}] [{:x 0, :to...
ba0d4ff417664ccd09b0e6195f438e7f79bf626cf98954c4f8d8954493f4b301
LaurentMazare/tensorflow-ocaml
var.mli
val create : int list -> type_:'a Node.Type.t -> init:'a Node.t -> 'a Node.t val float : int list -> init:[ `float ] Node.t -> [ `float ] Node.t val double : int list -> init:[ `double ] Node.t -> [ `double ] Node.t val f_or_d : int list -> float -> type_:([< `float | `double ] as 'a) Node.Type.t -> 'a Node.t...
null
https://raw.githubusercontent.com/LaurentMazare/tensorflow-ocaml/52c5f1dec1a8b7dc9bc6ef06abbc07da6cd90d39/src/graph/var.mli
ocaml
* [get_all_vars nodes] returns all the variables that can be used when evaluating a node in [nodes]. Each variable is only returned once.
val create : int list -> type_:'a Node.Type.t -> init:'a Node.t -> 'a Node.t val float : int list -> init:[ `float ] Node.t -> [ `float ] Node.t val double : int list -> init:[ `double ] Node.t -> [ `double ] Node.t val f_or_d : int list -> float -> type_:([< `float | `double ] as 'a) Node.Type.t -> 'a Node.t...
1720a4ce3224507e82e62cbb9ea881ef5519451132ffd1c0de99abd83a9063be
originrose/cortex
math_test.clj
(ns cortex.datasets.math-test (:require [clojure.test :refer :all] [clojure.core.matrix :as m] [mikera.vectorz.matrix-api] [cortex.util :as util])) (m/set-current-implementation :vectorz) (deftest normalize-test (let [num-rows 10 num-cols 20 test-mat (m/array (...
null
https://raw.githubusercontent.com/originrose/cortex/94b1430538e6187f3dfd1697c36ff2c62b475901/test/clj/cortex/datasets/math_test.clj
clojure
(ns cortex.datasets.math-test (:require [clojure.test :refer :all] [clojure.core.matrix :as m] [mikera.vectorz.matrix-api] [cortex.util :as util])) (m/set-current-implementation :vectorz) (deftest normalize-test (let [num-rows 10 num-cols 20 test-mat (m/array (...
158e34318d39592c636dfe7e3b48b9c3814e661396c7de0d7c6471d4b4eb4330
uxbox/uxbox-backend
icons.clj
This Source Code Form is subject to the terms of the Mozilla Public License , v. 2.0 . If a copy of the MPL was not distributed with this file , You can obtain one at /. ;; Copyright ( c ) 2016 < > (ns uxbox.services.icons "Icons library related services." (:require [clojure.spec :as s] [sur...
null
https://raw.githubusercontent.com/uxbox/uxbox-backend/036c42db8424be3ac34c38be80577ee279141681/src/uxbox/services/icons.clj
clojure
--- Helpers & Specs --- Create Collection --- Update Collection --- Copy Icon --- List Collections --- Delete Collection --- Create Icon (Upload) --- Update Icon --- Delete Icon --- List Icons
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 ) 2016 < > (ns uxbox.services.icons "Icons library related services." (:require [clojure.spec :as s] [surica...
f4ffeb10ec4f9f8c0b954496efdaf994e0d6b7877496918ad16c1f8585afb68a
kraison/langutils
tagger-oldctx.lisp
-*- Mode : Lisp ; Syntax : ANSI - Common - Lisp ; Base : 10 ; Package : utils -*- ;;;; ************************************************************************* ;;;; FILE IDENTIFICATION ;;;; ;;;; Name: tagger-ctxold ;;;; Purpose: Non-macro version of context rule parser/generator ;;;; Programmer : ...
null
https://raw.githubusercontent.com/kraison/langutils/2c75cf08c9dbaf22ed7209c485b7157e5ab5143a/langutils/src/tagger-oldctx.lisp
lisp
Syntax : ANSI - Common - Lisp ; Base : 10 ; Package : utils -*- ************************************************************************* FILE IDENTIFICATION Name: tagger-ctxold Purpose: Non-macro version of context rule parser/generator
Programmer : Date Started : October 2004 (in-package :langutils) (defun make-contextual-rule-old ( contextual-rule ) (declare (optimize speed (safety 0)) (type list contextual-rule) (inline svref)) (let ((old (mkkeysym (first contextual-rule))) (new (mkkeysym (second contextual-rule))) (nam...
dc964f50c7f386616143a4686e97dbfd9917dd1c32831ee2268f1247879671e9
labra/Haws
testShacl.hs
module TestShacl where import Shacl import Test.Framework import Test.Framework.Providers.HUnit import Test.HUnit hiding (Node) import Data.Set (Set) import qualified Data.Set as Set import RDF import RDFUtils import Namespaces import Sets import Typing test_combineTyping1 = combineTypings typing1 typing2 @?= typing...
null
https://raw.githubusercontent.com/labra/Haws/2417adc37522994e2bbb8e9e397481a1f6f4f038/papers/testShacl.hs
haskell
module TestShacl where import Shacl import Test.Framework import Test.Framework.Providers.HUnit import Test.HUnit hiding (Node) import Data.Set (Set) import qualified Data.Set as Set import RDF import RDFUtils import Namespaces import Sets import Typing test_combineTyping1 = combineTypings typing1 typing2 @?= typing...
52930b2fbdba03834759040f9e328239b0e44b48d3ecbce238fff1e8fbaef4cc
hyperfiddle/electric
react.clj
(ns dustin.react (:require reagent.dom [reagent.core :as r])) ; 1 translate to reagent (defn UserGreeting [props] [:h1 "Welcome back!"]) (defn GuestGreeting [props] [:h1 "Please sign up."]) (defn Wrapper [& children] ...) (defn PromptBrandLogo [isLoggedIn] ...) (defn Greeting [{:keys [isLoggedIn]}] ...
null
https://raw.githubusercontent.com/hyperfiddle/electric/1c6c3891cbf13123fef8d33e6555d300f0dac134/scratch/dustin/y2021/via/react.clj
clojure
1 translate to reagent - - runtime eval = interpreter interpreter Abstract Syntax Tree vs Tree evaluation rules will be provided later to faciliate evaluation of the abstractions
(ns dustin.react (:require reagent.dom [reagent.core :as r])) (defn UserGreeting [props] [:h1 "Welcome back!"]) (defn GuestGreeting [props] [:h1 "Please sign up."]) (defn Wrapper [& children] ...) (defn PromptBrandLogo [isLoggedIn] ...) (defn Greeting [{:keys [isLoggedIn]}] [Wrapper [:div [Promp...
a815b5e0c8590c7013fc426ad3db5d195ef361f9c3b4d942483934d4512c105b
vascokk/rivus_cep
rivus_cep_query_worker_tests.erl
-module(rivus_cep_query_worker_tests). -compile([debug_info, export_all]). -compile([{parse_transform, lager_transform}]). -include_lib("eunit/include/eunit.hrl"). -include("rivus_cep.hrl"). query_worker_test_() -> {setup, fun () -> folsom:start(), lager:start(), application:start(gproc), ...
null
https://raw.githubusercontent.com/vascokk/rivus_cep/e9fe6ed79201d852065f7fb2a24a880414031d27/test/rivus_cep_query_worker_tests.erl
erlang
?debugMsg(io_lib:format("Values: ~p~n",[Values])), send some events ?debugMsg(io_lib:format("Values: ~p~n",[Values])), ?assertEqual([{gr1,b,80},{gr3,b,80}], Values),
-module(rivus_cep_query_worker_tests). -compile([debug_info, export_all]). -compile([{parse_transform, lager_transform}]). -include_lib("eunit/include/eunit.hrl"). -include("rivus_cep.hrl"). query_worker_test_() -> {setup, fun () -> folsom:start(), lager:start(), application:start(gproc), ...
bd38b689e1d124ec0561b0786272a0cc3f361340238794d8b1079feaa9e46c26
scicloj/metamorph.ml
learning_curve_test.clj
(ns scicloj.metamorph.learning-curve-test (:require [clojure.test :as t] [tech.v3.dataset] [scicloj.metamorph.core :as mm] [tech.v3.dataset.metamorph :as mds] [tablecloth.api :as tc] [tablecloth.pipeline :as tc-mm] [scicloj.metamorph.ml] ...
null
https://raw.githubusercontent.com/scicloj/metamorph.ml/14a5430dc90ee4757c1c21fd4f916a4fad68ae9e/test/scicloj/metamorph/learning_curve_test.clj
clojure
(ns scicloj.metamorph.learning-curve-test (:require [clojure.test :as t] [tech.v3.dataset] [scicloj.metamorph.core :as mm] [tech.v3.dataset.metamorph :as mds] [tablecloth.api :as tc] [tablecloth.pipeline :as tc-mm] [scicloj.metamorph.ml] ...
6f19882fcf9528dc2e6fe92af520bd5626aaea614ae79d4b6d0222f2e47dd188
theodormoroianu/SecondYearCourses
HaskellChurch_20210415162211.hs
{-# LANGUAGE RankNTypes #-} module HaskellChurch where A boolean is any way to choose between two alternatives newtype CBool = CBool {cIf :: forall t. t -> t -> t} An instance to show as regular Booleans instance Show CBool where show b = show $ cIf b True False The boolean constant true always chooses the ...
null
https://raw.githubusercontent.com/theodormoroianu/SecondYearCourses/5e359e6a7cf588a527d27209bf53b4ce6b8d5e83/FLP/Laboratoare/Lab%209/.history/HaskellChurch_20210415162211.hs
haskell
# LANGUAGE RankNTypes # The boolean negation switches the alternatives The boolean conjunction can be built as a conditional The boolean disjunction can be built as a conditional a pair is a way to compute something based on the values contained within the pair. a function to be applied on the values, it will apply i...
module HaskellChurch where A boolean is any way to choose between two alternatives newtype CBool = CBool {cIf :: forall t. t -> t -> t} An instance to show as regular Booleans instance Show CBool where show b = show $ cIf b True False The boolean constant true always chooses the first alternative cTrue :: C...
215f3473cd6111e425b9a39c1331d5bda13957f0974e36f952006f73aa1d34a4
colah/Haskell-Re-Syntaxed
brainstorm.hs
Type Synonyms , type families , GADTs , Kind Sigs ... -- ... Can be a lot nicer. -- Summary: -- * synonyms are syntacticly like functions, -- except upper case names -- * type families are like functions, just as -- synonyms but with cases. * GADTs are block like . -- synonym Foo :: Type -> T...
null
https://raw.githubusercontent.com/colah/Haskell-Re-Syntaxed/d78645b685ef6e1108a54e9e70b4f5b4f3c8dc70/brainstorm.hs
haskell
... Can be a lot nicer. Summary: * synonyms are syntacticly like functions, except upper case names * type families are like functions, just as synonyms but with cases. synonym type family instead of this monstrosity: constraints can be guards :) They're *kind of* like Type -> Bool With cons...
Type Synonyms , type families , GADTs , Kind Sigs ... * GADTs are block like . Foo :: Type -> Type Foo a = (a, a -> a, Int) GADT List :: Type -> Type List = data Null :: List a Cons :: a -> List a -> List a Bar :: Type -> Type Bar Int = String Bar String = Int type family Bar a :: * type instance B...
ba9db05a758205c5fa25c3389908d4bface311fedfc0d6687bb100c488be5537
dalaing/little-languages
Infer.hs
| Copyright : ( c ) , 2016 License : : Stability : experimental Portability : non - portable Copyright : (c) Dave Laing, 2016 License : BSD3 Maintainer : Stability : experimental Portability : non-portable -} # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies #...
null
https://raw.githubusercontent.com/dalaing/little-languages/9f089f646a5344b8f7178700455a36a755d29b1f/code/old/modular/common-lang/src/Component/Term/Infer.hs
haskell
# LANGUAGE TemplateHaskell # # LANGUAGE RankNTypes # | ^ ^ | | ^ | ^ ^ | ^ ^
| Copyright : ( c ) , 2016 License : : Stability : experimental Portability : non - portable Copyright : (c) Dave Laing, 2016 License : BSD3 Maintainer : Stability : experimental Portability : non-portable -} # LANGUAGE FlexibleInstances # # LANGUAGE FunctionalDependencies #...
9bdb509a26ec6a05a3dd610e98b4430019c460516fd796b75924429f6c7eab0e
FranklinChen/hugs98-plus-Sep2006
Strict.hs
-- | Produces XHTML 1.0 Strict. module Text.XHtml.Strict ( -- * Data types Html, HtmlAttr, -- * Classes HTML(..), ADDATTRS(..), -- * Primitives and basic combinators (<<), concatHtml, (+++), noHtml, isNoHtml, tag, itag, emptyAttr, intAttr, strAttr, primHtml, -- * Rend...
null
https://raw.githubusercontent.com/FranklinChen/hugs98-plus-Sep2006/54ab69bd6313adbbed1d790b46aca2a0305ea67e/packages/xhtml/Text/XHtml/Strict.hs
haskell
| Produces XHTML 1.0 Strict. * Data types * Classes * Primitives and basic combinators * Rendering | Output the HTML without adding newlines or spaces within the markup. This should be the most time and space efficient way to render HTML, though the ouput is quite unreadable. | Outputs indented HTML. Becau...
module Text.XHtml.Strict ( Html, HtmlAttr, HTML(..), ADDATTRS(..), (<<), concatHtml, (+++), noHtml, isNoHtml, tag, itag, emptyAttr, intAttr, strAttr, primHtml, showHtml, renderHtml, prettyHtml, showHtmlFragment, renderHtmlFragment, prettyHtmlFragment, module Text.XHtml.St...
123c11d177919506375f3f55de1e478cde33c3b5d338609c47feee60f4045e8b
janestreet/universe
prim.mli
(** Specification of primitive types *) open Shexp_sexp.Std module Args : sig module Spec : sig module Arg : sig type 'a t = | A of ('a -> Sexp.t) | L of string * ('a -> Sexp.t) (** L for Labeled *) | O of string * ('a -> Sexp.t) * 'a (** O for Optional *) e...
null
https://raw.githubusercontent.com/janestreet/universe/b6cb56fdae83f5d55f9c809f1c2a2b50ea213126/shexp/process-lib/src/prim.mli
ocaml
* Specification of primitive types * L for Labeled * O for Optional The type is exposed to solve generalization problems * Returns [None] if the result is [Unit] or [Env]
open Shexp_sexp.Std module Args : sig module Spec : sig module Arg : sig type 'a t = | A of ('a -> Sexp.t) | L of string * ('a -> Sexp.t) | O of string * ('a -> Sexp.t) * 'a end type 'a t = | [] : 'a t | ( :: ) : 'a Arg.t * 'b t -> ('a -> 'b) t end typ...
ab7ee1656a0c408f2cc6ff58fd33e3a95a75cbee030b11cbce03c81874488e23
phoe-trash/gateway
unknown-command.lisp
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;; GATEWAY " phoe " Herda 2016 (in-package #:gateway) #| Error UNKNOWN-COMMAND Should be signaled when the system attempts to execute a command that is not present on the system. This error is usually not signaled from within ...
null
https://raw.githubusercontent.com/phoe-trash/gateway/a8d579ccbafcaee8678caf59d365ec2eab0b1a7e/_old/errors/unknown-command.lisp
lisp
GATEWAY Error UNKNOWN-COMMAND Should be signaled when the system attempts to execute a command that is not present on the system. This error is usually not signaled from within the command context, but from the operation context and should be signaled by invoking the function HANDLE-GATEWAY-ERROR on a condition in...
" phoe " Herda 2016 (in-package #:gateway) (define-gateway-error unknown-command ((command :reader unknown-command-command :initarg :command :initform (error "Must provide command."))) (owner connection condition) (((command (unknown-command-command condition))) ("...
dd12be59f5cbe01f7a4ba39576fa103e5b74430dcd5510fd57c2dd7138d01974
mzp/coq-ide-for-ios
constrintern.ml
(************************************************************************) v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2010 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *...
null
https://raw.githubusercontent.com/mzp/coq-ide-for-ios/4cdb389bbecd7cdd114666a8450ecf5b5f0391d3/coqlib/interp/constrintern.ml
ocaml
********************************************************************** // * This file is distributed under the terms of the * GNU Lesser General Public License Version 2.1 ********************************************************************** $Id: constrintern.ml 13620 2010-11-...
v * The Coq Proof Assistant / The Coq Development Team < O _ _ _ , , * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999 - 2010 \VV/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * open Pp open Util open Flags...
6e073c42404a26469ca1df21a5d5f97a274eec1c4b27ca4f631c038070dfab49
shayne-fletcher/zen
main.ml
let _ = Printf.printf "Hello world!\n"
null
https://raw.githubusercontent.com/shayne-fletcher/zen/10a1d0b9bf261bb133918dd62fb1593c3d4d21cb/ocaml/ocamlyacc/calculator/main.ml
ocaml
let _ = Printf.printf "Hello world!\n"
8669cb721fb86b8f312c5f7c988777b204dd520c9af86892aabee7cc8f3daec0
manuel-serrano/hop
callcc_resume_push.scm
;*=====================================================================*/ * Author : * / * Copyright : 2007 - 11 , see LICENSE file * / ;* ------------------------------------------------------------- */ * This file is part of Scheme2Js . ...
null
https://raw.githubusercontent.com/manuel-serrano/hop/481cb10478286796addd2ec9ee29c95db27aa390/scheme2js/callcc_resume_push.scm
scheme
*=====================================================================*/ * ------------------------------------------------------------- */ * */ * but WITHOUT ANY WARRANTY; without even the implied warranty of */ * MERCHANTABILITY or FITNE...
* Author : * / * Copyright : 2007 - 11 , see LICENSE file * / * This file is part of Scheme2Js . * / * Scheme2Js is distributed in the hope that it will be useful , * / (module callcc-resume-push (imp...
ccb8784013964a2b319b09c6968ac7abd31484994cce04a2c84ba934be31a1ca
ocaml/ocaml
location.ml
(**************************************************************************) (* *) (* OCaml *) (* *) ...
null
https://raw.githubusercontent.com/ocaml/ocaml/d71ea3d089ae3c338b8b6e2fb7beb08908076c7a/parsing/location.ml
ocaml
************************************************************************ OCaml ...
, projet Cristal , INRIA Rocquencourt Copyright 1996 Institut National de Recherche en Informatique et the GNU Lesser General Public License version 2.1 , with the open Lexing type t = Warnings.loc = { loc_start: position; loc_end: position; loc_ghost: bool } let i...
d6530b329e5bf272a7b613675c29006c68a4039dc9ef03edf809a3fd26aec04b
hasktorch/hasktorch
AlexNet.hs
# LANGUAGE DeriveGeneric # # LANGUAGE MultiParamTypeClasses # # LANGUAGE RecordWildCards # module AlexNet where import GHC.Generics import Torch.Functional import qualified Torch.Functional.Internal as I import Torch.NN import Torch.Tensor data AlexNetBBSpec = AlexNetBBSpec { conv1 :: Conv2dSpec, conv2 :: Conv...
null
https://raw.githubusercontent.com/hasktorch/hasktorch/8fa4d2a6cdb7f144484f7d24d8d4924fb0faecd2/examples/alexNet/AlexNet.hs
haskell
# LANGUAGE DeriveGeneric # # LANGUAGE MultiParamTypeClasses # # LANGUAGE RecordWildCards # module AlexNet where import GHC.Generics import Torch.Functional import qualified Torch.Functional.Internal as I import Torch.NN import Torch.Tensor data AlexNetBBSpec = AlexNetBBSpec { conv1 :: Conv2dSpec, conv2 :: Conv...
4c12495cced95e112e46c9363f86ab064c74fa499831a9e4468f14573a268f4d
tolysz/prepare-ghcjs
PathsModule.hs
----------------------------------------------------------------------------- -- | -- Module : Distribution.Simple.Build.Macros Copyright : 2003 - 2005 , 2006 , 2007 - 2008 -- -- Maintainer : -- Portability : portable -- -- Generating the Paths_pkgname module. --...
null
https://raw.githubusercontent.com/tolysz/prepare-ghcjs/8499e14e27854a366e98f89fab0af355056cf055/spec-lts/cabal/Cabal/Distribution/Simple/Build/PathsModule.hs
haskell
--------------------------------------------------------------------------- | Module : Distribution.Simple.Build.Macros Maintainer : Portability : portable Generating the Paths_pkgname module. enables them to find their version number and find any installed data files at runtime. This code should pr...
Copyright : 2003 - 2005 , 2006 , 2007 - 2008 This is a module that Cabal generates for the benefit of packages . It module Distribution.Simple.Build.PathsModule ( generate, pkgPathEnvVar ) where import Distribution.System import Distribution.Simple.Compiler import...
54e50c8543bd01005604565dcd6ad22d084fa7090afd704b70df98f3b28ae2aa
mflatt/not-a-box
schemify.rkt
#lang racket/base (require "wrap.rkt" "match.rkt" "known.rkt" "import.rkt" "struct-type-info.rkt" "simple.rkt" "find-definition.rkt" "mutated.rkt" "mutated-state.rkt" "left-to-right.rkt") (provide schemify-linklet schemify-body ...
null
https://raw.githubusercontent.com/mflatt/not-a-box/b6c1af4fb0eb877610a3a20b5265a8c8d2dd28e9/schemify/schemify.rkt
racket
Convert a linklet to a Scheme `lambda`, dealing with several issues: - imports and exports are represented by `variable` objects that are passed to the function; to avoid obscuring the program to the optimizer, though, refer to the definitions of exported variables instead of going through the `var...
#lang racket/base (require "wrap.rkt" "match.rkt" "known.rkt" "import.rkt" "struct-type-info.rkt" "simple.rkt" "find-definition.rkt" "mutated.rkt" "mutated-state.rkt" "left-to-right.rkt") (provide schemify-linklet schemify-body ...
3e281f40c6498c55bb93e4bc462e91b0ee40df05c4ee9aa33fb8fb40ad524a37
deadtrickster/rebar3_elvis_plugin
elvis_config.erl
-module(elvis_config). -export([ default/0, load_file/1, load/1, validate/1, normalize/1, Geters dirs/1, ignore/1, filter/1, files/1, rules/1, %% Files resolve_files/1, resolve_files/2, apply...
null
https://raw.githubusercontent.com/deadtrickster/rebar3_elvis_plugin/0b7dd1a3808dbe2e2e916ecf3afd1ff24e723021/src/elvis_config.erl
erlang
Files Public NOTE: Provided for backwards compatibility. @doc Takes a configuration and a list of files, filtering some of them according to the 'filter' key, or if not specified uses '*.erl'. @end resolve_files/2 with a config() type is used in elvis project @doc Takes a configuration and finds al...
-module(elvis_config). -export([ default/0, load_file/1, load/1, validate/1, normalize/1, Geters dirs/1, ignore/1, filter/1, files/1, rules/1, resolve_files/1, resolve_files/2, apply_to_files/2 ...
8b01029f02aa6c5408316b1146804e2f6ab236f325307b91df70cd338b40f51e
MercuryTechnologies/moat
SumOfProductSpec.hs
module SumOfProductSpec where import Common import Data.Text (Text) import Moat import Test.Hspec import Test.Hspec.Golden import Prelude hiding (Enum) data Enum = DataCons0 {enumField0 :: Int, enumField1 :: Int} | DataCons1 {enumField2 :: Text, enumField3 :: Text} mobileGenWith ( defaultOptions { dataAn...
null
https://raw.githubusercontent.com/MercuryTechnologies/moat/0217e7abe6bb045e5ea4c33d5dae9d636d3e6159/test/SumOfProductSpec.hs
haskell
module SumOfProductSpec where import Common import Data.Text (Text) import Moat import Test.Hspec import Test.Hspec.Golden import Prelude hiding (Enum) data Enum = DataCons0 {enumField0 :: Int, enumField1 :: Int} | DataCons1 {enumField2 :: Text, enumField3 :: Text} mobileGenWith ( defaultOptions { dataAn...
c67e6c4126a58acc448ac8f556155b72c9ac6c0dc48fda1870de4f75f10536d6
roosta/tincture
spec_test.cljs
(ns tincture.spec-test (:require [cljs.test :refer-macros [deftest testing is]] [tincture.spec :as sp] [clojure.spec.alpha :as s])) (s/def ::test-boolean boolean?) (s/def ::test-pos-int pos-int?) (deftest check-spec (testing "Checking a spec, and check return value" (is (sp/check-spec ...
null
https://raw.githubusercontent.com/roosta/tincture/587e68248dae09616942dc23bbd97cb9a1a4caa2/test/tincture/spec_test.cljs
clojure
(ns tincture.spec-test (:require [cljs.test :refer-macros [deftest testing is]] [tincture.spec :as sp] [clojure.spec.alpha :as s])) (s/def ::test-boolean boolean?) (s/def ::test-pos-int pos-int?) (deftest check-spec (testing "Checking a spec, and check return value" (is (sp/check-spec ...
80fe97a1c65581eb0decf8a12c1890711e44a83f746c40c450601632ce2986ba
parapluu/Concuerror
concuerror_deps.erl
%%%---------------------------------------------------------------------- Copyright ( c ) 2013 , < > , < > and < > . %%% All rights reserved. %%% This file is distributed under the Simplified BSD License . %%% Details can be found in the LICENSE file. %%%------------...
null
https://raw.githubusercontent.com/parapluu/Concuerror/152a5ccee0b6e97d8c3329c2167166435329d261/resources/old_source/concuerror_deps.erl
erlang
---------------------------------------------------------------------- All rights reserved. Details can be found in the LICENSE file. ---------------------------------------------------------------------- ---------------------------------------------------------------------- =========================================...
Copyright ( c ) 2013 , < > , < > and < > . This file is distributed under the Simplified BSD License . Authors : < > Description : Dependency relation for Erlang -module(concuerror_deps). -export([may_have_dependencies/1, dependent/2, ...
d249ba128ba46e4a119b2a01d54d889fc42e16db12fbc2ec2aaa0a11b8317d13
sunshineclt/Racket-Helper
4-SICP2.36.rkt
#lang racket (define (accumulate op init seq) (if (null? seq) init (op (car seq) (accumulate op init (cdr seq))))) (define (accumulate-n op init seqs) (if (null? seqs) '() (cons (accumulate op init (map (lambda (s) (if(null? s)'()(car s))) seqs)) (if(null? (cdar seqs)) ...
null
https://raw.githubusercontent.com/sunshineclt/Racket-Helper/bf85f38dd8d084db68265bb98d8c38bada6494ec/%E5%BE%90%E7%8E%89%E9%BA%9F/%E4%BD%9C%E4%B8%9A3/4-SICP2.36.rkt
racket
#lang racket (define (accumulate op init seq) (if (null? seq) init (op (car seq) (accumulate op init (cdr seq))))) (define (accumulate-n op init seqs) (if (null? seqs) '() (cons (accumulate op init (map (lambda (s) (if(null? s)'()(car s))) seqs)) (if(null? (cdar seqs)) ...
a60734a039b1d0671ae5f1bf3ea240fb96805757376bf7157df69f2714ffe598
faber-lang/faber
ParseSpec.hs
module ParseSpec (spec) where import Operators import Parse import Test.Hspec -- helpers parse :: String -> Expr parse s = case parseCode "" code of Left (ParseError err) -> error err Right t -> destruct t where code = "name main = " ++ s destruct [Name (NameDef _ [] body [])] = body pars...
null
https://raw.githubusercontent.com/faber-lang/faber/d022f52b22f209f1f10609949495b689e886c75f/test/ParseSpec.hs
haskell
helpers tests
module ParseSpec (spec) where import Operators import Parse import Test.Hspec parse :: String -> Expr parse s = case parseCode "" code of Left (ParseError err) -> error err Right t -> destruct t where code = "name main = " ++ s destruct [Name (NameDef _ [] body [])] = body parseTy :: Stri...
7b0abad1b9fd0e8b293ee55957138a2da5b1960fae234cfdd966843a4febe5ef
babashka/process
quickdoc.clj
(ns quickdoc (:require [pod.borkdude.clj-kondo :as clj-kondo])) (defn quickdoc [{:keys [branch outfile github/repo] :or {branch "main" outfile "API.md"}}] (let [var-defs (-> (clj-kondo/run! {:lint ["src"] :config {:...
null
https://raw.githubusercontent.com/babashka/process/c99fbe294b9da5185ece64b5fee8283f6d2a3827/script/quickdoc.clj
clojure
(.println System/err (:defined-by var)) (.println System/err (keys var))
(ns quickdoc (:require [pod.borkdude.clj-kondo :as clj-kondo])) (defn quickdoc [{:keys [branch outfile github/repo] :or {branch "main" outfile "API.md"}}] (let [var-defs (-> (clj-kondo/run! {:lint ["src"] :config {:...
d1a5dc3f0595e918667c93156419b5ac0200cbe4288f22002d1a8e8c942fea5c
dsheets/codoc
codocExtraction.ml
* Copyright ( c ) 2015 < > * * Permission to use , copy , modify , and distribute this software for any * purpose with or without fee is hereby granted , provided that the above * copyright notice and this permission notice appear in all copies . * * THE SOFTWARE IS PROVIDED " AS IS " AND THE AU...
null
https://raw.githubusercontent.com/dsheets/codoc/382077cf3e7e20e478bd97cc0b348e0b2ec926db/lib/codocExtraction.ml
ocaml
cmt or packed
* Copyright ( c ) 2015 < > * * Permission to use , copy , modify , and distribute this software for any * purpose with or without fee is hereby granted , provided that the above * copyright notice and this permission notice appear in all copies . * * THE SOFTWARE IS PROVIDED " AS IS " AND THE AU...
c96526efdce583c4b902dee2d7cafac57adf95baacfa54714c0f76b701faaf24
JunSuzukiJapan/cl-reex
handmade-observable.lisp
(in-package :cl-user) (defpackage cl-reex.macro.handmade-observable (:use :cl) (:import-from :cl-reex.observable :subscribe :observable :observable-object :is-active :observable-state :state :active :error :completed :disposed :...
null
https://raw.githubusercontent.com/JunSuzukiJapan/cl-reex/94928c7949c235b41902138d9e4a5654b92d67eb/src/macro/handmade-observable.lisp
lisp
on-next on-error on-completed
(in-package :cl-user) (defpackage cl-reex.macro.handmade-observable (:use :cl) (:import-from :cl-reex.observable :subscribe :observable :observable-object :is-active :observable-state :state :active :error :completed :disposed :...
add280d4857653a78305e8a1588bc23735d9bf89ae9d2bb23e6f2692d6a9ec07
yrashk/erlang
ets.erl
%% %% %CopyrightBegin% %% Copyright Ericsson AB 1996 - 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/yrashk/erlang/e1282325ed75e52a98d58f5bd9fb0fa27896173f/lib/stdlib/src/ets.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 1996 - 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(ets). Interface to the Term stor...
3aecc9cb569a3668b60771164174311dd9cf4f7e25126d5dab62e8958c179681
binaryage/clearcut
messages.cljs
(ns clearcut.messages "A subsystem for printing runtime warnings and errors." (:require-macros [clearcut.messages :refer [gen-clearcut-message-prefix]])) ; -- helpers ---------------------------------------------------------------------------------------------------------------- (defn ^:dynamic post-process-messa...
null
https://raw.githubusercontent.com/binaryage/clearcut/7f44705cd8743f8679199cb78a215487eb411ed4/src/lib/clearcut/messages.cljs
clojure
-- helpers ---------------------------------------------------------------------------------------------------------------- -- runtime error/warning messages ----------------------------------------------------------------------------------------- (post-process-message (str "Unexpected soft selector (\"?\" does not...
(ns clearcut.messages "A subsystem for printing runtime warnings and errors." (:require-macros [clearcut.messages :refer [gen-clearcut-message-prefix]])) (defn ^:dynamic post-process-message [msg] (str (gen-clearcut-message-prefix) ", " msg)) (defmulti runtime-message (fn [type & _] type)) ( defmethod runtim...
1bc546cc99b9f74129f5852a5e5fc2b39f9f6d782997a876699bde312615f06c
robert-strandh/CLIMatis
graphics-packages.lisp
(defpackage #:clim3-graphics (:use #:common-lisp) (:export ))
null
https://raw.githubusercontent.com/robert-strandh/CLIMatis/4949ddcc46d3f81596f956d12f64035e04589b29/Graphics/graphics-packages.lisp
lisp
(defpackage #:clim3-graphics (:use #:common-lisp) (:export ))
5aceb21a53df2419f94a15753f34ba67543557f474fdf29e0fe1d146e83dbd4f
Holworth/SICP_Solutions
square-list-iter.rkt
#lang sicp (define (square-list items) (define (iter things ans) (if (null? things) ans (iter (cdr things) (append ans (list (* (car things) (car things))))) )) (iter items nil) ) (square-list (list 1 2 3 4 5))
null
https://raw.githubusercontent.com/Holworth/SICP_Solutions/c5c893545e6cd21d835a000dd226923c55475588/solutions/chap2/code/square-list-iter.rkt
racket
#lang sicp (define (square-list items) (define (iter things ans) (if (null? things) ans (iter (cdr things) (append ans (list (* (car things) (car things))))) )) (iter items nil) ) (square-list (list 1 2 3 4 5))
3c2d788f53330abf22ae730811f2a7e545b55c4e21fb06001173d71d1339730b
tolysz/prepare-ghcjs
Common.hs
# LANGUAGE CPP # {-# LANGUAGE PackageImports #-} # OPTIONS_GHC -fno - warn - unused - imports # module Typed.Common (load) where import Prelude () import Prelude.Compat import Data.ByteString.Lazy as L import System.Exit import System.IO #ifndef HAS_BOTH_AESON_AND_BENCHMARKS import Data.Aeson hiding (Result) #else...
null
https://raw.githubusercontent.com/tolysz/prepare-ghcjs/8499e14e27854a366e98f89fab0af355056cf055/spec-lts8/aeson/benchmarks/Typed/Common.hs
haskell
# LANGUAGE PackageImports #
# LANGUAGE CPP # # OPTIONS_GHC -fno - warn - unused - imports # module Typed.Common (load) where import Prelude () import Prelude.Compat import Data.ByteString.Lazy as L import System.Exit import System.IO #ifndef HAS_BOTH_AESON_AND_BENCHMARKS import Data.Aeson hiding (Result) #else import "aeson" Data.Aeson hidin...
6d46d1a1d354e4355c5dc9cbe601bc372459c32b491ffa6cb1444ed47a255f49
VisionsGlobalEmpowerment/webchange
state.cljs
(ns webchange.admin.pages.class-profile.state (:require [re-frame.core :as re-frame] [re-frame.std-interceptors :as i] [webchange.admin.routes :as routes] [webchange.state.warehouse :as warehouse])) (def path-to-db :page/class-profile) (re-frame/reg-sub path-to-db (fn [db] (get db path-to-db...
null
https://raw.githubusercontent.com/VisionsGlobalEmpowerment/webchange/2b14cfa0b116034312a382763e6aebd67e2f25a7/src/cljs/webchange/admin/pages/class_profile/state.cljs
clojure
Side Bar Content Class Form Class data school courses
(ns webchange.admin.pages.class-profile.state (:require [re-frame.core :as re-frame] [re-frame.std-interceptors :as i] [webchange.admin.routes :as routes] [webchange.state.warehouse :as warehouse])) (def path-to-db :page/class-profile) (re-frame/reg-sub path-to-db (fn [db] (get db path-to-db...
289b17826b8181f0b8453104b55a87dfc288e0df8a3c33623298351805ae0a80
thlack/surfs
button.clj
(ns ^:no-doc thlack.surfs.elements.spec.button (:require [clojure.spec.alpha :as s] [thlack.surfs.composition.spec :as comp.spec] [thlack.surfs.strings.spec :as strings.spec :refer [deftext]])) (s/def ::type #{:button}) (deftext ::text ::comp.spec/plain-text 75) (s/def ::action_id ::strings...
null
https://raw.githubusercontent.com/thlack/surfs/e03d137d6d43c4b73a45a71984cf084d2904c4b0/src/thlack/surfs/elements/spec/button.clj
clojure
(ns ^:no-doc thlack.surfs.elements.spec.button (:require [clojure.spec.alpha :as s] [thlack.surfs.composition.spec :as comp.spec] [thlack.surfs.strings.spec :as strings.spec :refer [deftext]])) (s/def ::type #{:button}) (deftext ::text ::comp.spec/plain-text 75) (s/def ::action_id ::strings...
0f834ed9db9d0b1a9c4de8aa41f4edb1b3a09bb6d7240196e7776ae78a93c465
jstrutz/hashids.clj
util.clj
(ns hashids.util (:require [clojure.edn :as edn])) (defmacro xor ([] nil) ([a] a) ([a b] `(let [a# ~a b# ~b] (if a# (if b# false a#) (if b# b# false))))) (defn expt [b e] (java.lang.Math/pow b e)) (defn long->hexstr [n] (format "%x" n)) (defn hexstr->long [s] (try...
null
https://raw.githubusercontent.com/jstrutz/hashids.clj/3811184c290319e9c7515ccee7a53713d9f700ab/src/hashids/util.clj
clojure
(ns hashids.util (:require [clojure.edn :as edn])) (defmacro xor ([] nil) ([a] a) ([a b] `(let [a# ~a b# ~b] (if a# (if b# false a#) (if b# b# false))))) (defn expt [b e] (java.lang.Math/pow b e)) (defn long->hexstr [n] (format "%x" n)) (defn hexstr->long [s] (try...
fad4dff6da8d93b76041edf2dc4f85401a18d690af8571e4ee562b225a5abccc
pitag-ha/ppx_fprint
test.expected.ml
let saludo = Printf.sprintf "Hi there." let first_name = "O" let last_name = "Caml" let introduction = Printf.sprintf "My name is %s." first_name let formal_intro = Printf.sprintf "My name is %s%s." first_name last_name
null
https://raw.githubusercontent.com/pitag-ha/ppx_fprint/98506a3c8b3e3af04ab31a31fa5a4c1148c5a022/test/rewriter/test.expected.ml
ocaml
let saludo = Printf.sprintf "Hi there." let first_name = "O" let last_name = "Caml" let introduction = Printf.sprintf "My name is %s." first_name let formal_intro = Printf.sprintf "My name is %s%s." first_name last_name
64bf23147dd252af4e867b302f33ebfffe5f9faf76e27bb9706ab74ccee7e052
input-output-hk/plutus-apps
Constraints.hs
-- | Constraints for transactions module Ledger.Tx.Constraints( -- $constraints TC.TxConstraints(..) , TC.TxConstraint(..) , TC.ScriptInputConstraint(..) , TC.ScriptOutputConstraint(..) -- * Defining constraints , TC.mustPayToTheScriptWithDatumHash , TC.mustPayToTheScriptWithDatumInTx ...
null
https://raw.githubusercontent.com/input-output-hk/plutus-apps/006f4ae4461094d3e9405a445b0c9cf48727fa81/plutus-tx-constraints/src/Ledger/Tx/Constraints.hs
haskell
| Constraints for transactions $constraints * Defining constraints * Must-pay constraints for specific types of addresses * Defining off-chain only constraints * Queries on constraints * Off-chain transaction generation ** Lookups * Deprecated $constraints the 'Ledger.Tx.Constraints.TxConstraints.mustPayToTh...
module Ledger.Tx.Constraints( TC.TxConstraints(..) , TC.TxConstraint(..) , TC.ScriptInputConstraint(..) , TC.ScriptOutputConstraint(..) , TC.mustPayToTheScriptWithDatumHash , TC.mustPayToTheScriptWithDatumInTx , TC.mustPayToTheScriptWithInlineDatum , TC.mustPayToTheScriptWithReferenceScr...
3a72b3a583560a82fba325009602c0fffb7b826080c1e90aa3d8a037ab42246a
haskell/cabal
Progress.hs
module Distribution.Solver.Types.Progress ( Progress(..) , foldProgress ) where import Prelude () import Distribution.Solver.Compat.Prelude hiding (fail) -- | A type to represent the unfolding of an expensive long running -- calculation that may fail. We may get intermediate steps before the final -- resu...
null
https://raw.githubusercontent.com/haskell/cabal/6896c6aa0e4804913aaba0bbbe00649e18f17bb8/cabal-install-solver/src/Distribution/Solver/Types/Progress.hs
haskell
| A type to represent the unfolding of an expensive long running calculation that may fail. We may get intermediate steps before the final result which may be used to indicate progress and\/or logging messages. The derived functor instance caused a space leak in the solver. > foldProgress (flip const) Left Righ...
module Distribution.Solver.Types.Progress ( Progress(..) , foldProgress ) where import Prelude () import Distribution.Solver.Compat.Prelude hiding (fail) data Progress step fail done = Step step (Progress step fail done) | Fail fail | Done done ...
8ff7b7d1c421d482a8612b751e78d7201ccee2ae46a7109a7057e0b371100fdd
nodew/haskell-realworld-example
Article.hs
# LANGUAGE DerivingStrategies # # LANGUAGE GeneralizedNewtypeDeriving # module Conduit.Core.Article where import RIO import Rel8 import Data.Aeson import Data.Time import qualified Data.Text as T import Servant import Crypto.Random ( MonadRandom(getRandomBytes) ) import Crypto.Hash ( hashWith, SHA256(SHA256) ) import...
null
https://raw.githubusercontent.com/nodew/haskell-realworld-example/3401dcf9ee9cd04ed3417b37d05348c204f0607b/src/Conduit/Core/Article.hs
haskell
# LANGUAGE DerivingStrategies # # LANGUAGE GeneralizedNewtypeDeriving # module Conduit.Core.Article where import RIO import Rel8 import Data.Aeson import Data.Time import qualified Data.Text as T import Servant import Crypto.Random ( MonadRandom(getRandomBytes) ) import Crypto.Hash ( hashWith, SHA256(SHA256) ) import...
629afe0d08397502d83623550488c85766871dfd7b6f1f030c30091430a9a5b8
freizl/dive-into-haskell
fizzbuzz.hs
# LANGUAGE MonadComprehensions # module Main where import Data.Monoid import Data.Maybe test :: Int -> String -> Int -> Maybe String test x str n = listToMaybe [ str | n `mod` x == 0 ] fizz :: Int -> Maybe String fizz = test 3 "fizz" buzz :: Int -> Maybe String buzz = test 5 "buzz" fz :: Int -> String fz n = fro...
null
https://raw.githubusercontent.com/freizl/dive-into-haskell/b18a6bfe212db6c3a5d707b4a640170b8bcf9330/problems/fizzbuzz.hs
haskell
# LANGUAGE MonadComprehensions # module Main where import Data.Monoid import Data.Maybe test :: Int -> String -> Int -> Maybe String test x str n = listToMaybe [ str | n `mod` x == 0 ] fizz :: Int -> Maybe String fizz = test 3 "fizz" buzz :: Int -> Maybe String buzz = test 5 "buzz" fz :: Int -> String fz n = fro...
9a4f1eca57eadd8defa8cd7d7068fb0df96566484b7608e5f304fd3a066d5465
jlongster/schemeray
schemeray.scm
;;; Scheme Raytracer v0.1 ;;; ;;; Performs sphere/plane/triangle intersection tests, loads .obj files as a list of triangles , applies ;;; illumination and reflections. ;;; ;;; The math here hasn't been optimized at all, and there's ;;; a good deal that could be done. However, I simply wanted to build a prototype...
null
https://raw.githubusercontent.com/jlongster/schemeray/0ea0f1596cbafa05e541131fd64d482c79dd4173/ports/chicken/schemeray.scm
scheme
Scheme Raytracer v0.1 Performs sphere/plane/triangle intersection tests, loads illumination and reflections. The math here hasn't been optimized at all, and there's a good deal that could be done. However, I simply wanted next version. This outputs to a file 'image.ppm' which is of the format ppm's to other...
.obj files as a list of triangles , applies to build a prototype . Optimization will come in the Portable Pixmap . provides nice tools to convert ( For Chicken ) (require-extension syntax-case) (declare (standard-bindings) (extended-bindings) (block) (mostly-flonum) ...
b6b727d0e46fbe3a0d7611381245f20b9f0df54be73f292ff6dad2ed285794a0
seckcoder/iu_c311
grammar.rkt
#lang eopl (provide (all-defined-out)) (define scanner-spec-a '((white-sp (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 grammar-al...
null
https://raw.githubusercontent.com/seckcoder/iu_c311/a1215983b6ab08df32058ef1e089cb294419e567/racket/continuation-modular/grammar.rkt
racket
#lang eopl (provide (all-defined-out)) (define scanner-spec-a '((white-sp (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 grammar-al...
ee8952bfc1467789c78460f08a3a29a0dff7ae8aa6a7755a4808e81170f7305d
Perry961002/SICP
exe2.56-exponentiation.scm
(load "Chap2\\example\\exa2.3.2-Symbolic-guidance.scm") ;指数式就是第一个元素是**的biao (define (exponentiation? x) (and (pair? x) (eq? (car x) '**))) 底数就是指数式的第二个元素 (define (base e) (cadr e)) 指数是指数式的第三个元素 (define (exponent e) (caddr e)) ;构造指数式 (define (make-exponentiation b e) (cond ((=number? e 0) 1) ...
null
https://raw.githubusercontent.com/Perry961002/SICP/89d539e600a73bec42d350592f0ac626e041bf16/Chap2/exercise/exe2.56-exponentiation.scm
scheme
指数式就是第一个元素是**的biao 构造指数式
(load "Chap2\\example\\exa2.3.2-Symbolic-guidance.scm") (define (exponentiation? x) (and (pair? x) (eq? (car x) '**))) 底数就是指数式的第二个元素 (define (base e) (cadr e)) 指数是指数式的第三个元素 (define (exponent e) (caddr e)) (define (make-exponentiation b e) (cond ((=number? e 0) 1) ((=number? e 1) b) ...
cc5f2dbc7f51d184cb5284e248e3b6ef1b4f72dbf68e73beea56c8836d85dd9b
ocaml-gospel/ortac
translation.mli
module W = Warnings open Gospel val with_checks : driver:Drv.t -> term_printer:(Tterm.term -> string) -> Tterm.term list -> Translated.value -> Translated.value val with_pres : driver:Drv.t -> term_printer:(Tterm.term -> string) -> Tterm.term list -> Translated.value -> Translated.value val with_...
null
https://raw.githubusercontent.com/ocaml-gospel/ortac/dacc564ffaf8cfeb6f012bacefa5319d042ba29f/src/core/translation.mli
ocaml
module W = Warnings open Gospel val with_checks : driver:Drv.t -> term_printer:(Tterm.term -> string) -> Tterm.term list -> Translated.value -> Translated.value val with_pres : driver:Drv.t -> term_printer:(Tterm.term -> string) -> Tterm.term list -> Translated.value -> Translated.value val with_...
edee82ce7fd716c91d656b36108cecfc632bee821a8c346e6df5218c0c19789f
shenxs/about-scheme
17.4.rkt
;abstractions from templates 从模板抽象 以前一直从一般函数->抽象函数 ;这一章直接从函数模板得到抽象函数 ? 尽管这个话题还在研究中 , 我们现在只是了解一下基本的idea #lang racket (define (fun_for_l l) (cond [(empty? l) ...] [else (... (first l) ... (fun_for_l (rest l)))])) ;;这是一般的列表处理函数模板,确实这种形式出现了很多次 ; ; ; ;抽象之后就是以下的函数 (define (reduce l base combine) (cond [(emp...
null
https://raw.githubusercontent.com/shenxs/about-scheme/d458776a62cb0bbcbfbb2a044ed18b849f26fd0f/HTDP/17.4.rkt
racket
abstractions from templates 这一章直接从函数模板得到抽象函数 这是一般的列表处理函数模板,确实这种形式出现了很多次 抽象之后就是以下的函数 [list of sum] -> number [list of number ]->number (reduce 运算对象(列表) 幺元 运算符)
从模板抽象 以前一直从一般函数->抽象函数 ? 尽管这个话题还在研究中 , 我们现在只是了解一下基本的idea #lang racket (define (fun_for_l l) (cond [(empty? l) ...] [else (... (first l) ... (fun_for_l (rest l)))])) (define (reduce l base combine) (cond [(empty? l) base] [else (combine (first l) (reduce (rest l base combine)))])) 之后就可以用一行定义出sum , p...
286b6910ab6ccb622a3cfc37a03f174b9ea6b1610f9210547698a6e3a73885af
kit-ty-kate/labrys
buildSystem.ml
Copyright ( c ) 2013 - 2017 The Labrys developers . (* See the LICENSE file at the top-level directory. *) exception Failure type import_data = { library : bool ; hash_import : string } type impl_infos = { version : string ; hash : string ; hash_bc : string ; imports : (string * import_data) list }...
null
https://raw.githubusercontent.com/kit-ty-kate/labrys/54e13e765583d76c6054fabe06dd4f18d68dc17d/src/buildSystem.ml
ocaml
See the LICENSE file at the top-level directory.
Copyright ( c ) 2013 - 2017 The Labrys developers . exception Failure type import_data = { library : bool ; hash_import : string } type impl_infos = { version : string ; hash : string ; hash_bc : string ; imports : (string * import_data) list } let map_msgpack_maps = let aux = function | (`F...