Skip to main content

parse_object_literal_complete

Function parse_object_literal_complete 

Source
pub fn parse_object_literal_complete(
    s: &str,
) -> Option<Result<HashMap<String, Value>, SqlError>>
Expand description

Parse a { key: value, ... } object literal that must be the WHOLE input.

The strict form of parse_object_literal, for callers whose input is the literal and nothing else. Trailing text is an error naming what was left over, so a clause the caller wrote can never be discarded in silence. A trailing ; is accepted — it terminates the statement, it is not content.