Under heavy development. This site describes the intended 1.0 language. Current features and performance vary. Development status
Sn50SnThe SnAPI programming language
Development · Evolving reference

SecureRandomError

Owns the secure filling failure and exact initialized byte prefix. Discard partially filled security inputs. Failure does not imply no mutation. The record owns no buffer; immutable copies support concurrent observation.

Sn is under heavy development. This reference includes the intended 1.0 design; features may be incomplete in the current compiler. Read the status →

Module std.random

import std.random;

Public declaration contracts and authored examples. A page can document several related symbols. Implementation bodies are excluded.

SecureRandomError

pub struct SecureRandomError

Owns the secure filling failure and exact initialized byte prefix. Discard partially filled security inputs. Failure does not imply no mutation. The record owns no buffer; immutable copies support concurrent observation.

SecureRandomError.Reason

pub Reason: SecureRandomErrorReason;

Entropy or worker-admission failure.

SecureRandomError.Transferred

pub Transferred: usize;

Initialized prefix bytes; at most the requested output length.

Documentation snapshot: October 24, 2026 About versions ↗
Searching Development · language & standard library