Skip to content

Instantly share code, notes, and snippets.

@xosnrdev
xosnrdev / lib.rs
Last active December 22, 2025 10:14
Simple RFC IETF 5322, 3414 email-password validation
use std::fmt;
#[derive(Debug)]
pub enum ValidationError {
InvalidEmail,
InvalidPassword,
}
impl fmt::Display for ValidationError {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {