Giant blob of minor changes
[dotfiles/.git] / .config / coc / extensions / coc-go-data / tools / pkg / mod / golang.org / x / tools@v0.0.0-20201105173854-bc9fc8d8c4bc / refactor / eg / testdata / B1.go
diff --git a/.config/coc/extensions/coc-go-data/tools/pkg/mod/golang.org/x/tools@v0.0.0-20201105173854-bc9fc8d8c4bc/refactor/eg/testdata/B1.go b/.config/coc/extensions/coc-go-data/tools/pkg/mod/golang.org/x/tools@v0.0.0-20201105173854-bc9fc8d8c4bc/refactor/eg/testdata/B1.go
new file mode 100644 (file)
index 0000000..8b52546
--- /dev/null
@@ -0,0 +1,17 @@
+// +build ignore
+
+package B1
+
+import "time"
+
+var startup = time.Now()
+
+func example() time.Duration {
+       before := time.Now()
+       time.Sleep(1)
+       return time.Now().Sub(before)
+}
+
+func msSinceStartup() int64 {
+       return int64(time.Now().Sub(startup) / time.Millisecond)
+}