common: add pkgdoc.go for package godoc.

This commit is contained in:
Joubin Muhammad Houshyar 2016-06-10 06:34:48 -04:00
parent 78afc228ee
commit de243b05f3
2 changed files with 19 additions and 2 deletions

View file

@ -14,7 +14,6 @@
// You should have received a copy of the GNU Lesser General Public License
// along with the go-ethereum library. If not, see <http://www.gnu.org/licenses/>.
// Package common contains various helper functions.
package common
import (
@ -106,7 +105,7 @@ func Hex2Bytes(str string) []byte {
return h
}
func Hex2BytesFixed(str string, flen int) []byte {
func HexToBytesFixed(str string, flen int) []byte {
h, _ := hex.DecodeString(str)
if len(h) == flen {
return h

18
common/pkgdoc.go Normal file
View file

@ -0,0 +1,18 @@
// Copyright 2014 The go-ethereum Authors
// This file is part of the go-ethereum library.
//
// The go-ethereum library is free software: you can redistribute it and/or modify
// it under the terms of the GNU Lesser General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// The go-ethereum library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with the go-ethereum library. If not, see <http://www.gnu.org/licenses/>.
// Package common contains various helper functions.
package common