Skip to content

Commit

Permalink
*: fix build tag by run gofix (#34260)
Browse files Browse the repository at this point in the history
ref #31716
  • Loading branch information
hawkingrei authored Apr 27, 2022
1 parent a0f55d3 commit 6da6e5a
Show file tree
Hide file tree
Showing 60 changed files with 12 additions and 60 deletions.
1 change: 0 additions & 1 deletion br/pkg/lightning/backend/local/local_freebsd.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build freebsd
// +build freebsd

package local

Expand Down
1 change: 0 additions & 1 deletion br/pkg/lightning/backend/local/local_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !windows
// +build !windows

package local

Expand Down
1 change: 0 additions & 1 deletion br/pkg/lightning/backend/local/local_unix_generic.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !freebsd && !windows
// +build !freebsd,!windows

package local

Expand Down
1 change: 0 additions & 1 deletion br/pkg/lightning/backend/local/local_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build windows
// +build windows

package local

Expand Down
1 change: 0 additions & 1 deletion br/pkg/lightning/common/storage_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !windows
// +build !windows

// TODO: Deduplicate this implementation with DM!

Expand Down
1 change: 0 additions & 1 deletion br/pkg/lightning/common/storage_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build windows
// +build windows

// TODO: Deduplicate this implementation with DM!

Expand Down
1 change: 0 additions & 1 deletion br/pkg/lightning/manual/manual_nocgo.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
// the LICENSE file.

//go:build !cgo
// +build !cgo

package manual

Expand Down
1 change: 0 additions & 1 deletion br/pkg/lightning/sigusr1_other.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !linux && !darwin && !freebsd && !unix
// +build !linux,!darwin,!freebsd,!unix

package lightning

Expand Down
1 change: 0 additions & 1 deletion br/pkg/lightning/sigusr1_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build linux || darwin || freebsd || unix
// +build linux darwin freebsd unix

package lightning

Expand Down
1 change: 0 additions & 1 deletion br/pkg/lightning/web/res.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build dev
// +build dev

package web

Expand Down
1 change: 0 additions & 1 deletion br/pkg/lightning/web/res_vfsdata.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion br/pkg/restore/merge_fuzz_test.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
// Copyright 2022 PingCAP, Inc. Licensed under Apache-2.0.
//go:build go1.18
// +build go1.18

package restore_test

Expand Down
1 change: 0 additions & 1 deletion br/pkg/storage/local_unix.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// Copyright 2020 PingCAP, Inc. Licensed under Apache-2.0.

//go:build !windows
// +build !windows

package storage

Expand Down
1 change: 0 additions & 1 deletion br/pkg/storage/local_windows.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// Copyright 2020 PingCAP, Inc. Licensed under Apache-2.0.

//go:build windows
// +build windows

package storage

Expand Down
1 change: 0 additions & 1 deletion br/pkg/utils/dyn_pprof_other.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
//go:build !linux && !darwin && !freebsd && !unix
// +build !linux,!darwin,!freebsd,!unix

// Copyright 2020 PingCAP, Inc. Licensed under Apache-2.0.

Expand Down
1 change: 0 additions & 1 deletion br/pkg/utils/dyn_pprof_unix.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
//go:build linux || darwin || freebsd || unix
// +build linux darwin freebsd unix

// Copyright 2020 PingCAP, Inc. Licensed under Apache-2.0.

Expand Down
2 changes: 1 addition & 1 deletion cmd/ddltest/column_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
package ddltest

import (
goctx "context"
"fmt"
"reflect"
"sync"
Expand All @@ -29,7 +30,6 @@ import (
"github.com/pingcap/tidb/types"
"github.com/stretchr/testify/require"
"go.uber.org/zap"
goctx "golang.org/x/net/context"
)

// After add column finished, check the records in the table.
Expand Down
2 changes: 1 addition & 1 deletion cmd/ddltest/ddl_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
package ddltest

import (
goctx "context"
"database/sql"
"database/sql/driver"
"flag"
Expand Down Expand Up @@ -49,7 +50,6 @@ import (
"github.com/pingcap/tidb/types"
"github.com/stretchr/testify/require"
"go.uber.org/zap"
goctx "golang.org/x/net/context"
)

var (
Expand Down
2 changes: 1 addition & 1 deletion cmd/ddltest/index_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
package ddltest

import (
goctx "context"
"fmt"
"math"
"sync"
Expand All @@ -25,7 +26,6 @@ import (
"github.com/pingcap/tidb/store/gcworker"
"github.com/pingcap/tidb/table"
"github.com/stretchr/testify/require"
goctx "golang.org/x/net/context"
)

func getIndex(t table.Table, name string) table.Index {
Expand Down
1 change: 0 additions & 1 deletion ddl/restart_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build !race
// +build !race

package ddl

Expand Down
2 changes: 1 addition & 1 deletion expression/typeinfer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
package expression_test

import (
"context"
"fmt"
"math"
"testing"
Expand All @@ -30,7 +31,6 @@ import (
"github.com/pingcap/tidb/types"
"github.com/pingcap/tidb/util/printer"
"github.com/stretchr/testify/require"
"golang.org/x/net/context"
)

func TestInferType(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion owner/manager_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ package owner_test

import (
"context"
goctx "context"
"fmt"
"runtime"
"testing"
Expand All @@ -32,7 +33,6 @@ import (
clientv3 "go.etcd.io/etcd/client/v3"
"go.etcd.io/etcd/client/v3/concurrency"
"go.etcd.io/etcd/tests/v3/integration"
goctx "golang.org/x/net/context"
)

const testLease = 5 * time.Millisecond
Expand Down
1 change: 0 additions & 1 deletion server/tidb_serial_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build !race
// +build !race

package server

Expand Down
1 change: 0 additions & 1 deletion server/tidb_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build !race
// +build !race

package server

Expand Down
2 changes: 1 addition & 1 deletion store/mockstore/unistore/client/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@
package client

import (
"context"
"time"

"github.com/tikv/client-go/v2/tikvrpc"
"golang.org/x/net/context"
)

// Client is a client that sends RPC.
Expand Down
2 changes: 1 addition & 1 deletion store/mockstore/unistore/cophandler/analyze.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ package cophandler

import (
"bytes"
"context"
"math"
"math/rand"
"sort"
Expand All @@ -40,7 +41,6 @@ import (
"github.com/pingcap/tidb/util/rowcodec"
"github.com/pingcap/tipb/go-tipb"
"github.com/twmb/murmur3"
"golang.org/x/net/context"
)

// handleCopAnalyzeRequest handles coprocessor analyze request.
Expand Down
2 changes: 1 addition & 1 deletion store/mockstore/unistore/pd.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@
package unistore

import (
"context"
"errors"
"math"
"sync"

"github.com/pingcap/kvproto/pkg/pdpb"
us "github.com/pingcap/tidb/store/mockstore/unistore/tikv"
pd "github.com/tikv/pd/client"
"golang.org/x/net/context"
)

var _ pd.Client = new(pdClient)
Expand Down
2 changes: 1 addition & 1 deletion store/mockstore/unistore/rpc.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
package unistore

import (
"context"
"io"
"math"
"os"
Expand All @@ -35,7 +36,6 @@ import (
us "github.com/pingcap/tidb/store/mockstore/unistore/tikv"
"github.com/pingcap/tidb/util/codec"
"github.com/tikv/client-go/v2/tikvrpc"
"golang.org/x/net/context"
"google.golang.org/grpc/metadata"
)

Expand Down
2 changes: 1 addition & 1 deletion store/mockstore/unistore/tikv/mock_region.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ package tikv

import (
"bytes"
"context"
"sort"
"sync"
"sync/atomic"
Expand All @@ -37,7 +38,6 @@ import (
"github.com/pingcap/tidb/tablecodec"
"github.com/pingcap/tidb/util/codec"
pdclient "github.com/tikv/pd/client"
"golang.org/x/net/context"
)

// MPPTaskHandlerMap is a map of *cophandler.MPPTaskHandler.
Expand Down
2 changes: 1 addition & 1 deletion store/mockstore/unistore/tikv/region.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ package tikv

import (
"bytes"
"context"
"encoding/binary"
"strconv"
"sync"
Expand All @@ -36,7 +37,6 @@ import (
"github.com/pingcap/tidb/store/mockstore/unistore/tikv/mvcc"
"github.com/pingcap/tidb/util/codec"
"go.uber.org/zap"
"golang.org/x/net/context"
)

// InternalKey
Expand Down
1 change: 0 additions & 1 deletion testkit/asynctestkit.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !codes
// +build !codes

package testkit

Expand Down
1 change: 0 additions & 1 deletion testkit/dbtestkit.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !codes
// +build !codes

package testkit

Expand Down
1 change: 0 additions & 1 deletion testkit/mockstore.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !codes
// +build !codes

package testkit

Expand Down
1 change: 0 additions & 1 deletion testkit/result.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !codes
// +build !codes

package testkit

Expand Down
1 change: 0 additions & 1 deletion testkit/testkit.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !codes
// +build !codes

package testkit

Expand Down
1 change: 0 additions & 1 deletion testkit/testmain/bench.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !codes
// +build !codes

package testmain

Expand Down
1 change: 0 additions & 1 deletion testkit/testmain/wrapper.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !codes
// +build !codes

package testmain

Expand Down
1 change: 0 additions & 1 deletion testkit/testutil/handle.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !codes
// +build !codes

package testutil

Expand Down
1 change: 0 additions & 1 deletion testkit/testutil/require.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

//go:build !codes
// +build !codes

package testutil

Expand Down
Loading

0 comments on commit 6da6e5a

Please sign in to comment.