mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 03:27:44 +00:00
JSSpecCompiler+LibXML: Store location for tokens
This commit is contained in:
parent
d219c91ca9
commit
dee4978d67
7 changed files with 78 additions and 50 deletions
|
@ -31,13 +31,13 @@ inline constexpr StringView attribute_id = "id"sv;
|
|||
|
||||
inline constexpr StringView class_secnum = "secnum"sv;
|
||||
|
||||
ParseErrorOr<void> tokenize_string(XML::Node const* node, StringView view, Vector<Token>& tokens);
|
||||
ParseErrorOr<void> tokenize_string(SpecificationParsingContext& ctx, XML::Node const* node, StringView view, Vector<Token>& tokens);
|
||||
|
||||
struct TokenizeTreeResult {
|
||||
Vector<Token> tokens;
|
||||
XML::Node const* substeps = nullptr;
|
||||
};
|
||||
|
||||
ParseErrorOr<TokenizeTreeResult> tokenize_tree(XML::Node const* node, bool allow_substeps = false);
|
||||
ParseErrorOr<TokenizeTreeResult> tokenize_tree(SpecificationParsingContext& ctx, XML::Node const* node, bool allow_substeps = false);
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue