Hubbub
Functions
in_table_body.c File Reference
#include <assert.h>
#include <string.h>
#include "treebuilder/modes.h"
#include "treebuilder/internal.h"
#include "treebuilder/treebuilder.h"
#include "utils/utils.h"

Go to the source code of this file.

Functions

static void table_clear_stack (hubbub_treebuilder *treebuilder)
 Clear the stack back to a table body context. More...
 
static hubbub_error table_sub_start_or_table_end (hubbub_treebuilder *treebuilder)
 Handle the case common to some start tag and the table end tag cases. More...
 
hubbub_error handle_in_table_body (hubbub_treebuilder *treebuilder, const hubbub_token *token)
 Handle tokens in "in table body" insertion mode. More...
 

Function Documentation

hubbub_error handle_in_table_body ( hubbub_treebuilder treebuilder,
const hubbub_token token 
)
static void table_clear_stack ( hubbub_treebuilder treebuilder)
static

Clear the stack back to a table body context.

Parameters
treebuilderThe treebuilder instance

Definition at line 22 of file in_table_body.c.

References hubbub_tree_handler::ctx, current_node(), element_stack_pop(), HTML, TBODY, TFOOT, THEAD, hubbub_treebuilder::tree_handler, type, and hubbub_tree_handler::unref_node.

Referenced by handle_in_table_body(), and table_sub_start_or_table_end().

static hubbub_error table_sub_start_or_table_end ( hubbub_treebuilder treebuilder)
static

Handle the case common to some start tag and the table end tag cases.

Parameters
treebuilderThe treebuilder instance
Returns
Whether to reprocess the current token
Todo:
parse error

Definition at line 51 of file in_table_body.c.

References hubbub_treebuilder::context, hubbub_tree_handler::ctx, element_in_scope(), element_stack_pop(), HUBBUB_OK, HUBBUB_REPROCESS, IN_TABLE, hubbub_treebuilder_context::mode, table_clear_stack(), TBODY, TFOOT, THEAD, hubbub_treebuilder::tree_handler, and hubbub_tree_handler::unref_node.

Referenced by handle_in_table_body().