Browse Source

LibWeb: Make HTMLTokens non-copyable

Max Wipfli 4 years ago
parent
commit
8a4c44db8c
1 changed files with 4 additions and 0 deletions
  1. 4 0
      Userland/Libraries/LibWeb/HTML/Parser/HTMLToken.h

+ 4 - 0
Userland/Libraries/LibWeb/HTML/Parser/HTMLToken.h

@@ -19,6 +19,7 @@ namespace Web::HTML {
 class HTMLTokenizer;
 class HTMLTokenizer;
 
 
 class HTMLToken {
 class HTMLToken {
+    AK_MAKE_NONCOPYABLE(HTMLToken);
 
 
 public:
 public:
     enum class Type {
     enum class Type {
@@ -79,6 +80,9 @@ public:
     {
     {
     }
     }
 
 
+    HTMLToken(HTMLToken&& other) = default;
+    HTMLToken& operator=(HTMLToken&& other) = default;
+
     bool is_doctype() const { return m_type == Type::DOCTYPE; }
     bool is_doctype() const { return m_type == Type::DOCTYPE; }
     bool is_start_tag() const { return m_type == Type::StartTag; }
     bool is_start_tag() const { return m_type == Type::StartTag; }
     bool is_end_tag() const { return m_type == Type::EndTag; }
     bool is_end_tag() const { return m_type == Type::EndTag; }