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
56k: "https://123.campfirenow.com/images/56k.gif" | |
bell: ":bell:" | |
bezos: ":laughing::thought_balloon:" | |
bueller: "anyone?" | |
butts: ":open_hands: :smoking:" | |
clowntown: "https://123.campfirenow.com/images/clowntown.gif" | |
cottoneyejoe: ":notes::hear_no_evil::notes:" | |
crickets: "hears crickets chirping" | |
dadgummit: "dad gummit!! :fishing_pole_and_fish:" | |
dangerzone: "https://123.campfirenow.com/images/dangerzone.png" |
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
diff --git a/gc.c b/gc.c | |
--- a/gc.c | |
+++ b/gc.c | |
@@ -77,6 +77,41 @@ void *alloca (); | |
#ifndef GC_MALLOC_LIMIT | |
#define GC_MALLOC_LIMIT 8000000 | |
#endif | |
+#define HEAP_MIN_SLOTS 10000 | |
+#define FREE_MIN 4096 | |
+ |
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
package com.banksimple.util | |
private[util] final class Effectful[T](val origin: T) { | |
/** | |
* A special case of doto, andAlso is useful for | |
* quick logging or output tasks. Similar in use | |
* to doto, but only takes one function. | |
* */ | |
def andAlso(x: T => Unit): T = { x(origin) ; origin } |
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
;; Packaged version of singly-linked list based FIFO queue described | |
;; by Paul Graham in Ansi Common Lisp. Functions names changed not to | |
;; conflict with the lock free queue in sb-concurrency. | |
;; Taken from | |
;; http://cs.northwestern.edu/academics/courses/325/programs/graham.lisp | |
(defpackage :pg-queue (:use :cl)) | |
(in-package :pg-queue) |
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
" Vim color file | |
" Converted from Textmate theme Twilight using Coloration v0.2.5 (http://github.com/sickill/coloration) | |
set background=dark | |
highlight clear | |
if exists("syntax_on") | |
syntax reset | |
endif |
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 java.lang.reflect.Method | |
class Sendable(a: AnyRef) { | |
val methods = a.getClass.getDeclaredMethods | |
def wrapByte(b: Byte) = new java.lang.Byte(b) | |
def wrapShort(s: Short) = new java.lang.Short(s) | |
def wrapInt(i: Int) = new java.lang.Integer(i) | |
def wrapLong(l: Long) = new java.lang.Long(l) | |
def wrapFloat(f: Float) = new java.lang.Float(f) |
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
# | |
# This core extension customizes XML and JSON serialization in Mongoid::Document | |
# objects: | |
# * Serializes BSON::ObjectIDs as strings in XML | |
# * Removes leading underscores from attributes (such as _id, _type) | |
# * Allows documents to customize serialization even further by declaring a | |
# `serialize_attributes!` method, e.g.: | |
# def serialize_attributes!(attribute_hash) | |
# attribute_hash.delete(:unnecessary_key) | |
# attribute_hash[:password] = '' |
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 <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> | |
#include <hiredis/libevent.h> | |
void getCallback(redisContext *c, redisReply *reply, const void *privdata) { | |
printf("argv[%s]: %s\n", (const char*)privdata, reply->reply); | |
/* Disconnect after receiving the reply to GET */ | |
redisDisconnect(c); |
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
class Proc | |
def <<(other) | |
case other | |
when Proc | |
Proc.new do |*args| | |
call(other.call(*args)) | |
end | |
else | |
call(other) | |
end |
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
# sh function to murder all running processes matching a pattern | |
# thanks 3n: http://twitter.com/3n/status/19113206105 | |
murder () { | |
ps | grep $1 | grep -v grep | awk '{print $1}' | xargs kill -9 | |
} |