Skip to content

Cloned Parser does not reuse TagSet from original #2422

Closed

Description

@OlivierJaquemet

When using new Parser(original), parser.clone() or parser.newInstance(), if the original parser had custom TagSet, it is not preserved in the copy.

        Parser parser = Parser.htmlParser();
        parser.tagSet().add(new Tag("foo"));
        
        Parser clone = parser.clone();
        clone.tagSet().get("foo", Parser.NamespaceHtml)) --> is NULL

(incoming pull request with unittest)

Activity

  1. added a commit that references this issue on Oct 24, 2025
    d0cdcbc
  2. added 2 commits that reference this issue on Nov 13, 2025
    bcbac42
    26fc5e5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions