JsonRemedy.Layer3.ContextManager (json_remedy v0.1.3)
View SourceContext management functions for Layer 3 syntax normalization.
Handles parsing state, expectation tracking, and context transitions during character-by-character processing.
Summary
Functions
Determine what to expect after closing a delimiter.
Determine what to expect next based on current state.
Get position information for error reporting.
Check if a position in the input is inside a string literal. Used to avoid applying repairs to string content.
Functions
@spec determine_expecting_after_close(list()) :: :comma_or_end | :value
Determine what to expect after closing a delimiter.
Determine what to expect next based on current state.
@spec get_position_info(String.t(), non_neg_integer()) :: %{ line: pos_integer(), column: pos_integer(), context: String.t() }
Get position information for error reporting.
@spec inside_string?(String.t(), non_neg_integer()) :: boolean()
Check if a position in the input is inside a string literal. Used to avoid applying repairs to string content.