cleanup serial package

This commit is contained in:
Darien Raymond
2018-11-13 22:46:01 +01:00
parent eeb588ffa0
commit c5ccbe6b63
4 changed files with 16 additions and 6 deletions
+1 -6
View File
@@ -25,6 +25,7 @@ func ToString(v interface{}) string {
}
}
// Concat concatenates all input into a single string.
func Concat(v ...interface{}) string {
builder := strings.Builder{}
for _, value := range v {
@@ -32,9 +33,3 @@ func Concat(v ...interface{}) string {
}
return builder.String()
}
func WriteString(s string) func([]byte) (int, error) {
return func(b []byte) (int, error) {
return copy(b, []byte(s)), nil
}
}