github.com/shogo82148/std@v1.22.1-0.20240327122250-4e474527810c/runtime/debuglog.go (about) 1 // Copyright 2019 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 // This file provides an internal debug logging facility. The debug 6 // log is a lightweight, in-memory, per-M ring buffer. By default, the 7 // runtime prints the debug log on panic. 8 // 9 // To print something to the debug log, call dlog to obtain a dlogger 10 // and use the methods on that to add values. The values will be 11 // space-separated in the output (much like println). 12 // 13 // This facility can be enabled by passing -tags debuglog when 14 // building. Without this tag, dlog calls compile to nothing. 15 16 package runtime