Skip to content

Instantly share code, notes, and snippets.

***@***-***:~/src/github.com/syncthing/syncthing$ go run build.go
go get -v code.google.com/p/go.tools/cmd/cover
code.google.com/p/go.tools (download)
code.google.com/p/go.tools/cover
code.google.com/p/go.tools/cmd/cover
go install code.google.com/p/go.tools/cmd/cover: open /usr/local/go/pkg/tool/linux_amd64/cover: permission denied
exit status 1
exit status 1
@pyfisch
pyfisch / e1.geojson
Created October 7, 2014 18:49
European long-distance path E1
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
fn main() {
let testvector = vec![1, 2, 3];
let a: int = testvector[-1];
println!("{}", a);
}
/* The output:
task '<main>' panicked at 'index out of bounds: the len is 3 but the index is 18446744073709551615', /xxxx/src/main.rs:1
*/
@pyfisch
pyfisch / gist:91196db6df376c9638a7
Last active August 29, 2015 14:14
language.rs
#[plugin] #[no_link]
extern crate phf_macros;
extern crate phf;
use std::fmt;
use std::str::FromStr;
use std::ascii::AsciiExt;
#[derive(Clone, Debug, PartialOrd, PartialEq)]
pub enum Language {
@pyfisch
pyfisch / gist:4c10dd5ab79a6e715af2
Created January 25, 2015 16:07
What does this error message mean?
Compiling language-tags v0.0.1 (file:///home/michael/Dokumente/git/rust-language-tags)
src/language.rs:26:5: 26:17 error: expected a literal
src/language.rs:26 Language::Ar => "ar",
^~~~~~~~~~~~
src/lib.rs:1:1: 462:1 note: in expansion of phf_map!
src/language.rs:25:62: 31:3 note: expansion site
src/language.rs:27:5: 27:17 error: expected a literal
src/language.rs:27 Language::De => "de",
^~~~~~~~~~~~
src/lib.rs:1:1: 462:1 note: in expansion of phf_map!
//! HTTP status codes.
use std::fmt;
use std::mem::transmute;
use std::num::{FromPrimitive, ToPrimitive};
use std::cmp::Ordering;
pub use self::StatusCode::*;
pub use self::StatusClass::*;
# -*- coding: utf-8 -*-
"""
inyoka.utils.sessions
~~~~~~~~~~~~~~~~~~~~~
Session related utility functions.
:copyright: (c) 2007-2015 by the Inyoka Team, see AUTHORS for more details.
:license: BSD, see LICENSE for more details.
title wikidata author country language published pages isbn13 isbn10 oclc lccn
Semtecs Q13131267 Q13128620 Q25 Q9309 978-0-86381-528-7
Carnifal (nofel) Q20589393 Q18535656 Q25 Q9309 978-0-86243-675-9
How Green Was My Valley Q3398593 Q561435 Q145 Q1860 299207
Rhys Lewis Q7321804 Q3395446 Q25 Q9309
100 o Arwyr Cymru Q3394804 Q25 Q1860 978-1-903529-15-7
Brethyn Cartref Q18535480 Q7668277 Q25 Q9309
Chwalfa Q5118441 Q7793653 Q25 Q9309 978-0-86383-878-1 0-86383-878-2
Blodeugerdd o Farddoniaeth Gymraeg yr Ugeinfed Ganrif Q13126089 Q25 Q1860
Wild Wales Q8000838 Q2137717 Q1860
title wikidata author country language published pages isbn13 isbn10 oclc lccn
Semtecs Q13131267 Q13128620 Q25 Q9309 374 978-0-86381-528-7
Carnifal (nofel) Q20589393 Q18535656 Q25 Q9309 2004-08-26 240 978-0-86243-675-9
How Green Was My Valley Q3398593 Q561435 Q145 Q1860 1939 299207
Rhys Lewis Q7321804 Q3395446 Q25 Q9309 1885
100 o Arwyr Cymru Q3394804 Q25 Q1860 2005-04-08 418 978-1-903529-15-7
Brethyn Cartref Q18535480 Q7668277 Q25 Q9309 1913
Blodeugerdd o Farddoniaeth Gymraeg yr Ugeinfed Ganrif Q13126089 Q25 Q1860 1987 736
Wild Wales Q8000838 Q2137717 Q1860 1862
Yma o Hyd (nofel) Q13132543 Q3402032 Q25 Q9309 1985-01-01 978-0-86243-106-8
test aead::seal_in_place::aes_128_gcm::tls12_1350 ... bench: 1,325 ns/iter (+/- 34) = 1018 MB/s
test aead::seal_in_place::aes_128_gcm::tls12_16 ... bench: 219 ns/iter (+/- 75) = 73 MB/s
test aead::seal_in_place::aes_128_gcm::tls12_8192 ... bench: 7,239 ns/iter (+/- 683) = 1131 MB/s
test aead::seal_in_place::aes_128_gcm::tls12_finished ... bench: 181 ns/iter (+/- 3) = 66 MB/s
test aead::seal_in_place::aes_128_gcm::tls13_1350 ... bench: 1,283 ns/iter (+/- 50) = 1052 MB/s
test aead::seal_in_place::aes_128_gcm::tls13_8192 ... bench: 7,307 ns/iter (+/- 752) = 1121 MB/s
test aead::seal_in_place::aes_128_gcm::tls13_finished ... bench: 162 ns/iter (+/- 15) = 197 MB/s
test aead::seal_in_place::aes_256_gcm::tls12_1350 ... bench: 1,592 ns/iter (+/- 192) = 847 MB/s
test aead::seal_in_place::aes_256_gcm::tls12_16 ... bench: 207 ns/iter (+/-