The goal of this article is to explain the Rust Pin
higher order type by exploring how Rust
handles self-referential structs. Rust works best when data is modelled without cycles and there
is no way to express self-referential structs directly, so creating and manipulating these kinds of
struct can be a bit tricky.
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
Supported URLs : | |
/me | |
/user/id | |
/historyShip/id | |
/historyHero/id | |
/group/id | |
/curShip | |
/curHero |
I hereby claim:
- I am demurgos on github.
- I am demurgos (https://keybase.io/demurgos) on keybase.
- I have a public key ASCbE4ATLqXn-zKVANUHjJoqzUbDVJbyWxdCMeC26V-LlAo
To claim this, I am signing this object:
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] | |
name = "pgrepro" | |
version = "0.1.0" | |
authors = ["Charles Samborski <demurgos@demurgos.net>"] | |
edition = "2018" | |
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | |
[dependencies] | |
futures-util = "0.3.13" |
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
use std::sync::Arc; | |
use crate::core::{Get, UuidGenerator}; | |
use crate::clock::Clock; | |
use crate::user::SimpleUserService; | |
#[derive(Clone)] | |
pub struct Api(()); | |
pub trait ApiLike: Clone + Sized {} |
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
use std::sync::Arc; | |
use crate::core::{Provider, UuidGenerator}; | |
use crate::clock::Clock; | |
use crate::user::SimpleUserService; | |
#[derive(Clone)] | |
pub struct Api(()); | |
pub trait ApiLike: Clone + Sized {} |
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
// ==UserScript== | |
// @name HammerfestHeader | |
// @namespace hammerfest.fr | |
// @description Choix de la banniere Hammerfest | |
// @version 2 | |
// @include http://www.hammerfest.fr/* | |
// @match http://www.hammerfest.fr/* | |
// ==/UserScript== | |
//Cacher les sites amis pendant une partie |
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
interface LinearRgb { | |
r: number; | |
g: number; | |
b: number; | |
} | |
interface Srgb { | |
r: number; | |
g: number; |
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
--A--------------------------- | |
[a---------------) | |
+ | |
--B--------------------------- | |
[b-----) | |
+ | |
--C--------------------------- | |
[c--------------) |
This document describes the merge algorithm.
The merge algorithm takes a list of process coverages (or smaller items) and outputs a single object combining the information in the inputs. The goal is to simulate the result V8 would have returned if the coverages were executed sequentially inside the same process instead of their own processes (so the counts are summed).
NewerOlder