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
#!/usr/bin/perl -w | |
use strict; | |
use Dpkg::Control; | |
my @args; | |
my $target = "ubuntu"; | |
my $changes; | |
my $dryrun = 0; |
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 T(type): | |
def mro(cls): | |
global C | |
C = cls | |
return [] | |
try: | |
T("T", (), {}) | |
except TypeError: | |
pass |
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
mwhudson@aeglos:~$ cat mro.py | |
class T(type): | |
def mro(self): | |
return [] | |
class X(object,metaclass=T): | |
pass | |
class Y(object): | |
pass |
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
#!/bin/sh | |
DATE="$(TZ=UTC date +"%Y%m%d" -d "@$(git log -1 --pretty=format:%ct)")" | |
HASH="$(git log -n 1 "--format=format:%h")" | |
VERSION="0.0~git${DATE}.0.${HASH}" | |
PKG="$1" | |
ORIG="${PKG}_${VERSION}.orig.tar.gz" |
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 main | |
import ( | |
"debug/elf" | |
"encoding/binary" | |
"fmt" | |
"io" | |
"log" | |
"os" | |
) |
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
? golang.org/x/text [no test files] | |
ok golang.org/x/text/cases 0.380s | |
? golang.org/x/text/cmd/gotext [no test files] | |
--- FAIL: TestProcessWeights (0.00s) | |
collate_test.go:222: 4: Weights 1 was 2684357122; want 2684354560 | |
collate_test.go:222: 5: Weights 1 was 2684354570; want 2684354560 | |
collate_test.go:222: 11: Weights 1 was 2684357122; want 2684354560 | |
collate_test.go:222: 12: Weights 1 was 2684354570; want 2684354560 | |
collate_test.go:222: 18: Weights 1 was 2684357122; want 2684354560 | |
collate_test.go:222: 19: Weights 1 was 2684354570; want 2684354560 |
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
#!/usr/bin/perl | |
package main; | |
use strict; | |
use warnings; | |
use Cwd qw(:DEFAULT abs_path); | |
use Dpkg::Control; | |
use Dpkg::Control::Info; |
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
ok archive/tar 0.030s | |
ok archive/zip 60.159s | |
ok bufio 0.125s | |
ok bytes 9.558s | |
ok compress/bzip2 0.116s | |
ok compress/flate 38.625s | |
ok compress/gzip 0.130s | |
ok compress/lzw 0.128s | |
ok compress/zlib 2.255s | |
ok container/heap 0.087s |
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
#!/bin/sh | |
buildlog=$(go build -o /tmp/blah -x -work $2 2>&1) | |
eval $(echo "$buildlog" | grep WORK=) | |
linkcmd=$(echo "$buildlog" | grep -F "$(go tool -n link)") | |
for i in `seq $1`; do | |
eval /usr/bin/time -f '"BenchmarkLink$3 1 %e secs %M MaxRSS"' $linkcmd | |
done | |
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 main | |
import ( | |
"encoding/json" | |
"fmt" | |
yaml "gopkg.in/yaml.v2" | |
) | |
type bar struct { |