-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added junks, not to lose something still probably useful
- Loading branch information
Jun FURUSE
committed
May 27, 2016
1 parent
afdedf6
commit c727e8d
Showing
3 changed files
with
41 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
let (>>=) a b x = a x + b x | ||
let id x = x | ||
let (&) = (@@) | ||
let f x = (|>) x & id >>= id |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
let nan = | ||
float_of_bits 0x7F_F0_00_00_00_00_00_01L |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# OCaml とは全く関係ない emacs テクメモ | ||
|
||
## Kill Ring | ||
|
||
`kill` した文字列一覧 | ||
|
||
* `(popup-menu 'yank-menu)` | ||
* `anything-show-kill-ring` (requires `anything`) | ||
|
||
## `list-buffers` つまり `C-x C-b` の挙動が変った死ね | ||
|
||
予期したバッファレイアウトにならなくなったので死ぬ。そこで | ||
|
||
``` | ||
(global-change-key (kbd "<backtab>") 'shell-round-visit-buffer) | ||
(defun good-old-list-buffers () | ||
(interactive) | ||
(if (not (string-equal (buffer-name (current-buffer)) "*Buffer List*")) | ||
(save-selected-window (buffer-menu-other-window)))) | ||
(global-change-key (kbd "C-x C-b") 'good-old-list-buffers) | ||
``` | ||
|
||
## Interesting functions | ||
|
||
### `(bounds-of-thing-at-point THING)` | ||
|
||
``` | ||
(defun hogehogera () | ||
(interactive) | ||
(let* ( (bds (bounds-of-thing-at-point 'filename)) | ||
(p1 (car bds)) | ||
(p2 (cdr bds)) ) | ||
(message "%d %d" p1 p2))) | ||
``` |