Skip to content

Instantly share code, notes, and snippets.

🎯
Focusing

Ted Yin Determinant

🎯
Focusing
Block or report user

Report or block Determinant

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@jnrbsn
jnrbsn / better-gist-styles.css
Created Sep 14, 2010
Better styles for embedding GitHub Gists
View better-gist-styles.css
/* Better styles for embedding GitHub Gists */
.gist{font-size:13px;line-height:18px;margin-bottom:20px;width:100%}
.gist pre{font-family:Menlo,Monaco,'Bitstream Vera Sans Mono','Courier New',monospace !important}
.gist-meta{font-family:Helvetica,Arial,sans-serif;font-size:13px !important}
.gist-meta a{color:#26a !important;text-decoration:none}
.gist-meta a:hover{color:#0e4071 !important}
@jjgod
jjgod / 0001-Fix-CID-keyed-fonts-glyph-lookup.patch
Last active Mar 3, 2019
Patch to dvipdfm-x for CID-keyed font support
View 0001-Fix-CID-keyed-fonts-glyph-lookup.patch
From 759df18a9c8ec05c6830687682c57d9e4c6a55d3 Mon Sep 17 00:00:00 2001
From: Jiang Jiang <gzjjgod@gmail.com>
Date: Sat, 26 Jul 2014 21:33:19 +0200
Subject: [PATCH 1/3] Fix CID-keyed fonts glyph lookup
Keep cff_charsets parsed from CID font around if exists. Use the
cff_charsets to do GID -> CID lookup.
---
texk/dvipdfm-x/cff.c | 14 ++++++++------
texk/dvipdfm-x/cff.h | 1 +
@dvliman
dvliman / gist:267b66ac3a321172fd35
Created Jan 4, 2015
linux-kernel-booting-process
View gist:267b66ac3a321172fd35

GNU/Linux kernel internals

Linux kernel booting process. Part 1.

If you read my previous blog posts, you can note that sometime ago I have started to get involved low-level programming. I wrote some posts about x86_64 assembly programming for Linux. In the same time I started to dive into GNU/Linux kernel source code. It is very interesting for me to understand how low-level things works, how programs runs on my computer, how they located in memory, how kernel manages processes and memory, how network stack works on low-level and many many other things. I decided to write yet another series of posts about GNU/Linux kernel for x86_64.

Note, that I'm not professional kernel hacker and I don't write code for kernel at work, just a hobby. I just like low-level stuff and it is interesting to me how these

@ynsta
ynsta / sampler.py
Last active Apr 25, 2019
Statistic profiling on stm32f4 with openocd by dwt_pcsr sampling
View sampler.py
#!/usr/bin/python2
# run openocd (0.9.0) with :
# $ openocd -f stlink-v2-1.cfg -f stm32f4x.cfg &> /dev/null"
# then run
# $ python2 sampler.py path_to_myelf_with_symbols
import sys
import time
import telnetlib
@eddieh
eddieh / libevent-v-libuv.md
Last active May 13, 2019
libevent vs libuv
View libevent-v-libuv.md

libevent vs libuv

Comparing libevent and libuv. My upfront biased: I want to like libevent. However, I want to objectively compare the two and make an informed decision.

What versions are we comparing?

  • libevent 2.0.22 (Stable) [2014-01-05]
  • libuv 1.8.0 (Stable) [2015-12-15]
@MaiaVictor
MaiaVictor / promise_monad.md
Last active Sep 7, 2019
async/await is just the do-notation of the Promise monad
View promise_monad.md

async/await is just the do-notation of the Promise monad

CertSimple just wrote a blog post arguing ES2017's async/await was the best thing to happen with JavaScript. I wholeheartedly agree.

In short, one of the (few?) good things about JavaScript used to be how well it handled asynchronous requests. This was mostly thanks to its Scheme-inherited implementation of functions and closures. That, though, was also one of its worst faults, because it led to the "callback hell", an seemingly unavoidable pattern that made highly asynchronous JS code almost unreadable. Many solutions attempted to solve that, but most failed. Promises almost did it, but failed too. Finally, async/await is here and, combined with Promises, it solves the problem for good. On this post, I'll explain why that is the case and trace a link between promises, async/await, the do-notation and monads.

First, let's illustrate the 3 styles by implementing

You can’t perform that action at this time.