PHP TypeLang Help

@psalm-pure

The @psalm-pure tag declares a function or method as pure, meaning it is free of side effects: calling it repeatedly with the same arguments always produces the same result, without observably mutating any state.

"@psalm-pure" [ <Description> ]

Parsing a @psalm-pure tag produces a PureTag instance. Being a pure marker, it adds nothing beyond the $name and optional $description every Tag already carries.

final class PureTag extends FlagTag {}

The same PureTag is produced by @phpstan-pure and @phan-pure, which restate the same concept for their respective tools.

Defined by Psalm.

08 July 2026