Todos Nuevo

user:thomas gists creados por el usuario

title:mygist gists con el título indicado

description:sync gists with given description

filename:myfile.txt gists que contienen archivos con el nombre indicado

extension:yml gists que contienen archivos con la extensión indicada

language:go gists que contienen archivos con el lenguaje indicado

topic:homelab gists with given topic

all:systemctl search all fields

Iniciar sesión

Todos Nuevo Iniciar sesión

All gists matching topic big5

Recientemente creado
Menos reciente creado
Recientemente actualizado
Menos reciente actualizado

jetsung / gbkbig5.go

0 gustos
0 bifurcaciones
1 archivos
Última actividad 1 month ago
Golang GBK Big5 from/to UTF-8 转换 转自:https://gist.github.com/zhang0098/c691e1da5bbdc7f41ca5
big5 gbk go
1 import (
2 "bytes"
3 "io/ioutil"
4 "golang.org/x/text/encoding/traditionalchinese"
5 "golang.org/x/text/encoding/simplifiedchinese"
6 "golang.org/x/text/transform"
7 )
8 //convert GBK to UTF-8
9 func Decodegbk(s []byte) ([]byte, error) {
10 I := bytes.NewReader(s)
Siguiente Anterior

Desarrollado por Opengist ⋅ Load: 49ms⋅

Español
Čeština Deutsch English Español Français Magyar Italiano 日本語 Polski Português Русский Türkçe Українська 中文 繁體中文
⋅ 爱开发 ⋅ 爱开发社区