Skip to main content

Module error

Module error 

Source
Expand description

Comprehensive error types for dx-serializer

This module provides a unified error handling system with detailed location information for debugging and user-friendly error messages.

Structs§

SourceLocation
Source location information for parse errors

Enums§

DxError
Comprehensive error type for all DX serializer operations

Constants§

DX_MAGIC
Magic bytes for DX binary format
DX_VERSION
Current binary format version
MAX_INPUT_SIZE
Maximum input size (100 MB) - prevents memory exhaustion attacks
MAX_RECURSION_DEPTH
Maximum recursion depth for nested structures - prevents stack overflow
MAX_SNIPPET_LENGTH
Maximum length for error snippets (characters of context around error)
MAX_TABLE_ROWS
Maximum table row count - prevents memory exhaustion

Functions§

extract_snippet
Extract a snippet of input around the error location

Type Aliases§

Result
Serializer result type using DxError as the shared error.