#[derive(NotSensitive)]
{
// Attributes available to this derive:
#[not_sensitive]
}
Expand description
Derives a no-op redactable::RedactableContainer implementation, along with
slog::Value / SlogRedacted and TracingRedacted.
This is useful for types that are known to be non-sensitive but still need to
satisfy RedactableContainer / Redactable bounds. Because the type has no
sensitive data, logging integration works without wrappers.
§Generated Impls
RedactableContainer: no-op passthrough (the type has no sensitive data)slog::ValueandSlogRedacted(behindcfg(feature = "slog")): emits theDebugrepresentation as a string. Requires the type to implementDebug(use#[derive(Debug)]).TracingRedacted(behindcfg(feature = "tracing")): marker trait
§Debug
NotSensitive does not generate a Debug impl. Unlike Sensitive (which generates
Debug to redact sensitive fields), NotSensitive types have nothing to redact — standard
#[derive(Debug)] is the right tool. Add it alongside NotSensitive:
ⓘ
#[derive(Clone, Debug, NotSensitive)]
struct PublicData { ... }Unions are rejected at compile time.