mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 01:37:35 +00:00
LibXML: Record source location for nodes
This commit is contained in:
parent
3556c27d2d
commit
6368e6ca12
3 changed files with 72 additions and 20 deletions
|
@ -19,6 +19,12 @@ struct Attribute {
|
|||
DeprecatedString value;
|
||||
};
|
||||
|
||||
struct Offset {
|
||||
size_t offset { 0 };
|
||||
size_t line { 0 };
|
||||
size_t column { 0 };
|
||||
};
|
||||
|
||||
struct Node {
|
||||
struct Text {
|
||||
StringBuilder builder;
|
||||
|
@ -34,6 +40,7 @@ struct Node {
|
|||
|
||||
bool operator==(Node const&) const;
|
||||
|
||||
Offset offset;
|
||||
Variant<Text, Comment, Element> content;
|
||||
Node* parent { nullptr };
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue