This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#lang racket | |
(void (let ((a 0)) | |
(vector-immutable | |
a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a a |
This file has been truncated, but you can view the full file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#lang racket | |
(define (_P! n) (void)) | |
(define (_S n) (void)) | |
(define (_N v) (void)) | |
(define (_G n) (void)) | |
(define (_S! n x) (void)) | |
(define (_A . args) (void)) | |
(define (_F v) (void)) | |
(define (_CATCH h f) (void)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import System.Environment (getArgs) | |
import System.IO (hPutStrLn, stderr) | |
import System.Exit (exitFailure) | |
import Data.List (find, isPrefixOf, isSuffixOf, nub, intersperse) | |
import Data.Maybe (fromJust, mapMaybe) | |
import System.Directory (listDirectory, doesDirectoryExist) | |
import Data.Traversable (for) | |
import System.FilePath ((</>), takeDirectory, pathSeparator, dropExtension) | |
import Data.Monoid (Endo(..)) | |
import Data.Foldable (fold) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- same as sum below | |
liftSum :: Functor f => Either (f a) (f b) -> f (Either a b) | |
liftSum = either (Left <$>) (Right <$>) | |
-- same as comult below | |
unliftProd :: Functor f => f (a, b) -> (f a, f b) | |
unliftProd x = (fst <$> x, snd <$> x) | |
-- same as cosum below | |
unliftSum :: Comonad f => f (Either a b) -> Either (f a) (f b) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Trans.RWS ( | |
module X, | |
RWS, | |
runRWS, | |
evalRWS, | |
execRWS, | |
mapRWS, | |
RWST, | |
runRWST, | |
evalRWST, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE Rank2Types | |
, RebindableSyntax | |
, ImplicitParams | |
, NoMonomorphismRestriction #-} | |
import Data.Maybe | |
import Data.Function | |
import Data.String | |
import Prelude (undefined, error, String, (++)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module LayoutParser ( | |
LayoutParser, | |
indented, | |
linefold, | |
line, | |
saveIndent, | |
align, | |
runLayoutParser | |
) where |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <assert.h> | |
#include <setjmp.h> | |
#include <signal.h> | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <stdbool.h> | |
#include <string.h> | |
#include <unistd.h> | |
#include <time.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'forwardable' | |
module Packages | |
class Package | |
module Mixin | |
extend Forwardable | |
def_delegators :@__PACKAGE__, :import, :bind | |
attr_reader :__PACKAGE__ | |
def method_added(name) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Daybreak | |
class BackgroundCompaction | |
def initialize(file) | |
@db = Daybreak::DB.new(file) | |
@thread = Thread.new(&method(:run)) | |
end | |
def stop | |
@stop = true | |
@thread.join |