Skip to content

Instantly share code, notes, and snippets.

@14427
14427 / hkt.rs
Last active February 7, 2024 10:18
Higher-kinded type trait
use std::rc::Rc;
trait HKT<U> {
type C; // Current type
type T; // Type with C swapped with U
}
macro_rules! derive_hkt {
($t:ident) => {
impl<T, U> HKT<U> for $t<T> {
@cpswsg
cpswsg / Favicon MetaTags
Created June 23, 2013 03:33
Meta Tags for Favicon
<!-- Favicon -->
<meta name="msapplication-TileImage" content="images/favicons/tile.png"> <!-- Windows 8 -->
<meta name="msapplication-TileColor" content="#00CCFF"/> <!-- Windows 8 color -->
<!--[if IE]><link rel="shortcut icon" href="images/favicons/favicon.ico"><![endif]-->
<link rel="icon" type="image/png" href="images/favicons/favicon.png">
<link rel="apple-touch-icon-precomposed" sizes="144x144" href="images/favicons/apple-touch-icon-precomposed-144x144.png"><!-- iPad Retina-->
<link rel="apple-touch-icon-precomposed" sizes="114x114" href="images/favicons/apple-touch-icon-precomposed-114x114.png"><!--iPhone Retina -->
<link rel="apple-touch-icon-precomposed" sizes="72x72" href="images/favicons/apple-touch-icon-precomposed-72x72.png"><!-- iPad 1 e 2 -->
<link rel="apple-touch-icon-precomposed" href="images/favicons/apple-touch-icon-precomposed-57x57.png"><!-- iPhone, iPod e Android 2.2+ -->