From c756801b0141e5d8f5f43e38d9962117e034e565 Mon Sep 17 00:00:00 2001 From: Alan Donovan Date: Wed, 26 Sep 2018 09:05:57 -0400 Subject: [PATCH] go/analysis/internal/checker: fix go1.10 build ...by removing references to trace API for now. Change-Id: Ide6bbbfd98e15a3773b4a10232bcbf2dc2153341 Reviewed-on: https://go-review.googlesource.com/137615 Reviewed-by: Alan Donovan --- go/analysis/internal/checker/checker.go | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/go/analysis/internal/checker/checker.go b/go/analysis/internal/checker/checker.go index 290ad5a3..d4388c53 100644 --- a/go/analysis/internal/checker/checker.go +++ b/go/analysis/internal/checker/checker.go @@ -6,7 +6,6 @@ package checker import ( "bytes" - "context" "encoding/gob" "encoding/json" "flag" @@ -442,9 +441,13 @@ func (act *action) execOnce() { // Analyze dependencies. execAll(act.deps) - ctx, task := trace.NewTask(context.Background(), "exec") - defer task.End() - trace.Log(ctx, "pass", act.String()) + // TODO(adonovan): uncomment this during profiling. + // It won't build pre-go1.11 but conditional compilation + // using build tags isn't warranted. + // + // ctx, task := trace.NewTask(context.Background(), "exec") + // trace.Log(ctx, "pass", act.String()) + // defer task.End() // Record time spent in this node but not its dependencies. // In parallel mode, due to GC/scheduler contention, the