codeberg.org/gruf/go-errors/v2@v2.3.1/build_notrace.go (about)

     1  //go:build !errtrace
     2  // +build !errtrace
     3  
     4  package errors
     5  
     6  import "runtime"
     7  
     8  // IncludesStacktrace is a compile-time flag used to indicate
     9  // whether to include stacktraces on error wrap / creation.
    10  const IncludesStacktrace = false
    11  
    12  type trace struct{}
    13  
    14  // set will set the actual trace value
    15  // only when correct build flag is set.
    16  func (trace) set([]runtime.Frame) {}
    17  
    18  // value returns the actual trace value
    19  // only when correct build flag is set.
    20  func (trace) value() Callers { return nil }