Skip to content

Instantly share code, notes, and snippets.

View garsue's full-sized avatar

garsue garsue

View GitHub Profile
@garsue
garsue / main.go
Created September 6, 2017 10:00
Add BOM
package main
import (
"bufio"
"bytes"
"errors"
"io"
"log"
"os"
)
@garsue
garsue / go-sql-driver.md
Last active November 30, 2018 02:46
2018年時点の database/sql/driver 雑感

0日目。

法人インフォをぶっこ抜きたくて https://github.com/garsue/sparql/ というの書いてる。

GoのSPARQLのクライアントライブラリは https://github.com/knakk/sparql があるけど、 レスポンスまるっとメモリにロードするのがちょっと嫌で、なによりよくあるRDBと同じノリで使えたらいい感じかなと思って、SQL driverとしてクライアントライブラリを書いてみた。

database/sql/driverはちょいちょい進化していて、 実装すべきinterfaceとそうでもないやつが別れてきてる。