THRIFT-4448: Golang: do something with context.Context. Remove Go1.6 compatibility.
Client: go
This closes #1459
diff --git a/test/go/src/common/printing_handler.go b/test/go/src/common/printing_handler.go
index c0a2862..2b22d0c 100644
--- a/test/go/src/common/printing_handler.go
+++ b/test/go/src/common/printing_handler.go
@@ -1,5 +1,3 @@
-// +build !go1.7
-
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -22,13 +20,12 @@
package common
import (
+ "context"
+ "encoding/hex"
"errors"
"fmt"
- "encoding/hex"
. "gen/thrifttest"
"time"
-
- "golang.org/x/net/context"
)
var PrintingHandler = &printingHandler{}
@@ -280,11 +277,11 @@
func (p *printingHandler) TestInsanity(ctx context.Context, argument *Insanity) (r map[UserId]map[Numberz]*Insanity, err error) {
fmt.Printf("testInsanity()\n")
r = make(map[UserId]map[Numberz]*Insanity)
- r[1] = map[Numberz]*Insanity {
+ r[1] = map[Numberz]*Insanity{
2: argument,
3: argument,
}
- r[2] = map[Numberz]*Insanity {
+ r[2] = map[Numberz]*Insanity{
6: NewInsanity(),
}
return