Skip to content

Instantly share code, notes, and snippets.

View ryukzak's full-sized avatar

Aleksandr Penskoi ryukzak

View GitHub Profile
{ "keys": ["alt+j"], "command": "do_after_mark", "args": {"command": "copy"}, "context": [{ "key": "setting.with_marker" }] },
{ "keys": ["alt+h"], "command": "move", "args": {"by": "characters", "forward": false, "extend": true}, "context": [{ "key": "setting.with_marker" }] }
import sublime, sublime_plugin
class ClearMarkCommand(sublime_plugin.TextCommand):
def run(self, edit):
self.view.run_command("clear_bookmarks", {"name": "mark"})
self.view.settings().set('with_marker', False)
class DoAfterMarkCommand(sublime_plugin.TextCommand):
def run(self, edit, command, args = {}):
self.view.run_command("clear_mark")
#include <stdio.h>
#include <stdlib.h>
#include <stdbool.h>
#include <unistd.h>
struct List {
struct List *next;
int value;
};
class Foo(val bar:Bar) {
def this() = this(new Bar)
}
module Main where
import qualified Data.ByteString as B
import Cmd
import System.Environment
import Data.Array
newState = State { pmem = B.empty
, dmem = array (0, 255) $ take 256 $ zip [0,1..] [0,0..]
, pc = 0x00
module Cmd where
import Data.Word
import qualified Data.ByteString as B
import Data.Array
import Data.Bits
import Debug.Trace
import Data.List
data State = State { pmem :: B.ByteString
@ryukzak
ryukzak / gist:340102
Created March 22, 2010 14:07
Erlang план лекции
Erlang
=============== Заглавие ==========
О чём будет данная лекция.
- описание области, о которой пойдёт речь.
- описание стилистики изложения (сравнение с традиционными
методами).
#define led_conduction 0xFF
#define dip_state 0
#define init_led_state 1
#define led_state 2
#define rev_led_state 3
char din, dip, state;
while (dip = read_dip()){
switch (state){
case dip_state: