---
name: "function::warn"
section: "3stap"
platform: "linux"
package: "systemtap-doc"
version: "5.1-5"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/function::warn"
---

# function::warn(3stap)

Send a line to the warning stream

## NAME

function::warn - Send a line to the warning stream

## SYNOPSIS

```
    warn(msg:string)
```

## ARGUMENTS

*msg*

The formatted message string

## DESCRIPTION

This function sends a warning message immediately to staprun. It is also sent over the bulk transport (relayfs) if it is being used. If the last characater is not a newline, the one is added.

## SEE ALSO0

[*tapset::logging*(3stap)](/tapset::logging/3stap.md)
