This file contains hidden or 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
<svg viewBox="0 0 50 50"> | |
<defs> | |
<mask id="mask"> | |
<circle | |
r="24" | |
cy="25" | |
cx="25" | |
fill="white" | |
/> |
This file contains hidden or 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
Checking rand v0.6.5 | |
Checking failure v0.1.5 | |
Checking target-lexicon v0.3.0 | |
error[E0277]: the trait bound `rand_hc::Hc128Rng: rand_core::SeedableRng` is not satisfied | |
--> /Users/rfm/.cargo/registry/src/github.com-1ecc6299db9ec823/rand-0.6.5/src/rngs/std.rs:55:6 | |
| | |
55 | impl SeedableRng for StdRng { | |
| ^^^^^^^^^^^ the trait `rand_core::SeedableRng` is not implemented for `rand_hc::Hc128Rng` | |
error[E0277]: the trait bound `rand_isaac::IsaacRng: rand_core::SeedableRng` is not satisfied |
This file contains hidden or 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
export function Thing { | |
constructor(one, two) { | |
this.one = one; | |
this.two = two; | |
} | |
} | |
let t1 = new Thing(1, 2); | |
let t2 = new Thing('one', 'two'); | |
let t3 = addThings(t1, t2); // {one: '1 & one', two: '2 & two'} |
This file contains hidden or 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
libiconv is keg-only, which means it was not symlinked into /usr/local, | |
because macOS already provides this software and installing another version in | |
parallel can cause all kinds of trouble. | |
If you need to have libiconv first in your PATH run: | |
echo 'export PATH="/usr/local/opt/libiconv/bin:$PATH"' >> ~/.bash_profile | |
For compilers to find libiconv you may need to set: | |
export LDFLAGS="-L/usr/local/opt/libiconv/lib" | |
export CPPFLAGS="-I/usr/local/opt/libiconv/include" |
This file contains hidden or 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
Marcus:crates.io rfm$ cargo clean && cargo test | |
Compiling version_check v0.1.4 | |
Compiling winapi-build v0.1.1 | |
Compiling libc v0.2.42 | |
Compiling nodrop v0.1.12 | |
Compiling num-traits v0.1.40 | |
Compiling unicode-xid v0.1.0 | |
Compiling siphasher v0.2.2 | |
Compiling scopeguard v0.3.3 | |
Compiling lazy_static v1.0.0 |
This file contains hidden or 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
#[macro_use] | |
extern crate nom; | |
type Duration = Vec<(f32, DurationUnit)>; | |
pub fn parse(s: &str) -> Result<Duration, String> { | |
match parse_duration(s) { | |
Ok(pair) => { | |
Ok(pair.1) | |
}, | |
Err(e) => Err(format!("Error parsing duration {:?}", e)), | |
} |
This file contains hidden or 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
INFO 2018-09-25T19:54:22Z: analytics: Starting up | |
INFO 2018-09-25T19:54:22Z: warp::server: warp drive engaged: listening on 127.0.0.1:5555 | |
INFO 2018-09-25T19:54:33Z: warp::filters::log: "POST /analytics/landing HTTP/1.1" 400 720.83 |
This file contains hidden or 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] | |
name = "getpid" | |
version = "0.1.0" | |
[dependencies] | |
walkdir = "1" | |
docopt = "2" |
This file contains hidden or 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
enum Expression { | |
Binary(BinaryExpression), | |
Unary(Box<UnaryExpression>), | |
} | |
struct BinaryExpression { | |
left: Box<Expression>, | |
operator: Operator, | |
right: Box:<Expression>, | |
} |
This file contains hidden or 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
let wasm; | |
fetch('/rust_program_name.wasm') | |
.then(res => res.arrayBuffer()) | |
.then(buf => { | |
return WebAssembly.Instantiate(buf, importObject) | |
.then(mod => { | |
wasm = mod.instance.exports; | |
start(); | |
}); | |
}); |