cuelang.org/go@v0.10.1/internal/golangorgx/gopls/telemetry/telemetry_go118.go (about)

     1  // Copyright 2023 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  //go:build !go1.19
     6  // +build !go1.19
     7  
     8  package telemetry
     9  
    10  // This file defines dummy implementations of telemetry operations to
    11  // permit building with go1.18. Until we drop support for go1.18,
    12  // gopls may not refer to the telemetry module directly, but must go
    13  // through this file.
    14  
    15  func CounterOpen() {}
    16  
    17  func StartCrashMonitor() {}
    18  
    19  func CrashMonitorSupported() bool { return false }
    20  
    21  func NewStackCounter(string, int) dummyCounter { return dummyCounter{} }
    22  
    23  type dummyCounter struct{}
    24  
    25  func (dummyCounter) Inc() {}
    26  
    27  func Mode() string {
    28  	return "local"
    29  }
    30  
    31  func SetMode(mode string) error {
    32  	return nil
    33  }
    34  
    35  func Upload() {
    36  }
    37  
    38  func RecordClientInfo(string) {}
    39  
    40  func RecordViewGoVersion(x int) {
    41  }
    42  
    43  func AddForwardedCounters(names []string, values []int64) {
    44  }