pm_parser_new

Function pm_parser_new 

Source
pub unsafe extern "C" fn pm_parser_new(
    arena: *mut pm_arena_t,
    source: *const u8,
    size: usize,
    options: *const pm_options_t,
) -> *mut pm_parser_t
Expand description

Allocate and initialize a parser with the given start and end pointers.

@param arena The arena to use for all AST-lifetime allocations. It is caller- owned and must outlive the parser. @param source The source to parse. @param size The size of the source. @param options The optional options to use when parsing. These options must live for the whole lifetime of this parser. @returns The initialized parser. It is the responsibility of the caller to free the parser with pm_parser_free().