sdk/golang/Standard Library/GoRuntimeDebug
Standard Library

GoRuntimeDebug

Go stdlib package — runtime/debug. Auto-indexed from CDN. Method-level security roles have not been annotated; rule writers should inspect the source before use.

Other Methods

.BuildInfo.String()Neutral
#
Signature
BuildInfo.String() string

BuildInfo.String function.

.FreeOSMemory()Neutral
#
Signature
FreeOSMemory()

FreeOSMemory forces a garbage collection followed by an

.ParseBuildInfo()Neutral
#
Signature
ParseBuildInfo(data string) (*BuildInfo, error)

ParseBuildInfo function.

.PrintStack()Neutral
#
Signature
PrintStack()

PrintStack prints to standard error the stack trace returned by runtime.Stack.

.ReadBuildInfo()Neutral
#
Signature
ReadBuildInfo() (*BuildInfo, bool)

ReadBuildInfo returns the build information embedded

.ReadGCStats()Neutral
#
Signature
ReadGCStats(stats *GCStats)

ReadGCStats reads statistics about garbage collection into stats.

.SetGCPercent()Neutral
#
Signature
SetGCPercent(percent int) int

SetGCPercent sets the garbage collection target percentage:

.SetMaxStack()Neutral
#
Signature
SetMaxStack(bytes int) int

SetMaxStack sets the maximum amount of memory that

.SetMaxThreads()Neutral
#
Signature
SetMaxThreads(threads int) int

SetMaxThreads sets the maximum number of operating system

.SetMemoryLimit()Neutral
#
Signature
SetMemoryLimit(limit int64) int64

SetMemoryLimit provides the runtime with a soft memory limit.

Fully-Qualified Names

FQNField
runtime/debugfqns[0]

Wrong FQN → 0 findings. Verify with: change fqns to garbage → must produce 0 results.

Import

go.mod
// standard library — no go.mod entry required
rule.py
from codepathfinder.go_rule import ...  # runtime/debug