Skip to content

Instantly share code, notes, and snippets.

👊
omae wa mou shindeiru

Austin Seipp thoughtpolice

👊
omae wa mou shindeiru
Block or report user

Report or block thoughtpolice

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:134873
~/ghc/ghc-osx64-unreg $ make bootstrapping-files
make -r --no-print-directory -f ghc.mk bootstrapping-files
find: libraries/ghc-prim/dist-install/build: No such file or directory
find: libraries/ghc-prim/dist-install/build: No such file or directory
find: libraries/integer-gmp/dist-install/build: No such file or directory
find: libraries/integer-gmp/dist-install/build: No such file or directory
find: libraries/integer/dist-install/build: No such file or directory
find: libraries/integer/dist-install/build: No such file or directory
find: libraries/base/dist-install/build: No such file or directory
find: libraries/base/dist-install/build: No such file or directory
View gist:134887
mkdir utils/ghc-cabal/dist
mkdir utils/ghc-cabal/dist/build
mkdir utils/ghc-cabal/dist/build/tmp
"/Users/austinseipp/bin/ghc" -H32m -O -H32m --make utils/ghc-cabal/ghc-cabal.hs -o utils/ghc-cabal/dist/build/tmp/ghc-cabal \
-Wall \
-DCABAL_VERSION=1,7,2 \
-odir bootstrapping \
-hidir bootstrapping \
-ilibraries/Cabal \
-ilibraries/filepath \
View gist:138728
~/src/C-ObjC-Blocks $ cat t.c
#include <stdio.h>
#include "blocks_runtime.h"
int main() {
int x[5] = { 0, 1, 2, 3, 4 };
for(int i=0; i<5; i++) {
void (^f)(int) = ^(int y) { printf("v: %d\n", i+y); };
View gist:141038
~/code/AwesomePrelude/src $ cat test.hs
import AwesomePrelude
import HaskellPrelude
import JsPrelude
import qualified Prelude as P
test :: P.Bool
test = not false && false || true
test2 :: Js JsBool
View gist:241730
import Prelude hiding (and)
import Criterion.Main(defaultMain, bench, B(..))
import Data.Word
import LLVM.Core
import LLVM.Util.Optimize
import LLVM.ExecutionEngine
import Test.QuickCheck
View asio_blkreader.cc
#include <iostream>
#include <assert.h>
#include <sys/vfs.h>
#include <boost/asio.hpp>
#include <boost/asio/posix/random_access_descriptor.hpp>
#include <boost/iostreams/device/file_descriptor.hpp>
#include <boost/system/error_code.hpp>
#include <boost/bind.hpp>
@thoughtpolice
thoughtpolice / DerivativesViaDualNumbers.hs
Created Dec 10, 2010
Computing derivatives of functions using dual numbers
View DerivativesViaDualNumbers.hs
{-# LANGUAGE ViewPatterns #-}
module DerivativesViaDualNumbers where
{--
Dual numbers are an extension of the real numbers, like Complex
numbers, only with the identity that d^2 = 0. They are represented
similarly to complex numbers as well, i.e. a+b*d where 'a' and 'b' are
real numbers.
@thoughtpolice
thoughtpolice / gist:750279
Created Dec 21, 2010
Lightweight dependent types + a proof of a 'mirror' function
View gist:750279
{-# LANGUAGE TypeFamilies, RankNTypes, FlexibleContexts, ScopedTypeVariables #-}
{-
based heavily on Ryan Ingram's lightweight type-level dependent programming
in haskell, posted to haskell-cafe:
http://www.haskell.org/pipermail/haskell-cafe/2009-June/062690.html
I would suggest reading it before continuing further
-}
View gist:834331
/**//*/};)/**/main(/*//**/tang ,gnat/**//*/,ABBA~,0-0(avnz;)0-0,tang,raeN
,ABBA(niam&&)))2-]--tang-[kri - =raeN(&&0<)/*clerk*/,noon,raeN){(!tang&&
noon!=-1&&(gnat&2)&&((raeN&&( getchar(noon+0)))||(1-raeN&&(trgpune(noon
)))))||tang&&znva(/*//**/tang ,tang,tang/**|**//*/((||)))0(enupgrt=raeN
(&&tang!(||)))0(rahcteg=raeN( &&1==tang((&&1-^)gnat=raeN(;;;)tang,gnat
,ABBA,0(avnz;)gnat:46+]552&)191+gnat([kri?0>]652%)191+gnat([kri=gnat
(&&)1-^gnat(&&)1& ABBA(!;)raeN,tang,gnat,ABBA(avnz&&0>ABBA{)raeN
,/**/);}znva(/*//**/tang,gnat,ABBA/**//*/(niam;}1-,78-,611-,321
-,321-,001-,64-,43-,801-,001-,301-,321-,511-,53-,54,44,34,24
@thoughtpolice
thoughtpolice / refl.hs
Created Mar 15, 2011
strange segfault with ghc7/windows
View refl.hs
import Data.Reflection
test1 :: Int
test1 =
let x = 2
in reify x reflect
main = print test1
You can’t perform that action at this time.