mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-04-28 15:28:55 +00:00
LibWeb: Add HTMLToken(Type) constructor and use it
This commit is contained in:
parent
f2e3c770f9
commit
25cba4387b
Notes:
sideshowbarker
2024-07-18 08:52:43 +09:00
Author: https://github.com/MaxWipfli
Commit: 25cba4387b
Pull-request: https://github.com/SerenityOS/serenity/pull/8784
Reviewed-by: https://github.com/Hendiadyoin1
Reviewed-by: https://github.com/alimpfard
2 changed files with 10 additions and 6 deletions
|
@ -2665,8 +2665,7 @@ bool HTMLTokenizer::consume_next_if_match(StringView const& string, CaseSensitiv
|
|||
|
||||
void HTMLTokenizer::create_new_token(HTMLToken::Type type)
|
||||
{
|
||||
m_current_token = {};
|
||||
m_current_token.m_type = type;
|
||||
m_current_token = { type };
|
||||
size_t offset = 0;
|
||||
switch (type) {
|
||||
case HTMLToken::Type::StartTag:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue