Author: | draftcode |
---|---|
Date: | 2011-11-11T13:18:07+09:00 |
ID: | 289a0136-0c1c-11e1-a06b-040ccee352e6 |
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
.data | |
hello: | |
.string "Hello world!\n" | |
.text | |
.globl _start | |
_start: | |
movl $4, %eax # write(1, hello, strlen(hello)) | |
movl $1, %ebx | |
movl $hello, %ecx |
An introduction to curl
using GitHub's API.
Makes a basic GET request to the specifed URI
curl https://api.github.com/users/caspyin
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
;SMBDIS.ASM - A COMPREHENSIVE SUPER MARIO BROS. DISASSEMBLY | |
;by doppelganger ([email protected]) | |
;This file is provided for your own use as-is. It will require the character rom data | |
;and an iNES file header to get it to work. | |
;There are so many people I have to thank for this, that taking all the credit for | |
;myself would be an unforgivable act of arrogance. Without their help this would | |
;probably not be possible. So I thank all the peeps in the nesdev scene whose insight into | |
;the 6502 and the NES helped me learn how it works (you guys know who you are, there's no |
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
protected String substringByShiftJISBytesCount(String source, int bytesCount) | |
throws UnsupportedEncodingException { | |
if (source == null) return source; | |
byte[] bytes = source.getBytes("MS932"); | |
if (bytes.length < bytesCount) return source; | |
String result = new String(bytes, 0, bytesCount, "MS932"); | |
String last = result.substring(result.length() -1); | |
String lazt = new String(last.getBytes("MS932"), "MS932"); | |
if (!last.equals(lazt)) { | |
result = result.substring(0, result.length()-1); |
MessagePackが文字列とバイナリをわけないのは問題?
Objective Cの実装使ってるとある問題にぶちあたった.なので,文字列をちゃんとバイナリ(Raw)と分けるべき,という提案
(*) 俺は熟読したわけではないので,中身が気になる人はちゃんと本スレを読みましょう
Vim Advent Calendar 2012の102日目(2013-03-12)の記事です。
-
W,E,BでのWORD移動を文節単位にする jasegment.vimを作りました。
OlderNewer