It's only redundant if you expect people to memorize your style guide. If the style guide is instead enforced by a lint rule, then having the /> be required means that no one has to memorize the list of self-closing tags.
The writer of the HTML will be told off if they try to use /> on a tag that won't actually self-close, and they will also be told off if they neglect /> on a tag that self-closes.
Once written, the reader knows that a tag that ends in /> closes itself, and if it ends in > then there's definitely a closing tag somewhere.
But it doesn't even "work for particular names" because the `/>` part isn't what closes the element.
By the time the parser has seen the sequence `<br` it already knows which element this is, because it can only be the BR element, and has already finalized the DOM node for it because that's the rule for the BR tag. The moment it sees the opening angled bracket and tag, that node is created in an already closed state.
So those extra two `/>` do, in the most literal sense possible, nothing at all. They're allowed to be there for historical reason but they literally do nothing: they're treated as bytes to be ignored and the DOM parser skips over them while it looks for the next active token in order to continue building the DOM.
The parser treats `B<` and `p` as attributes of `br`, and determines that the `<br` tag ends with the `>` at the end of line 1.
If I end the `<br` with either `/>` or `>`, it parses correctly. Which means that `/>` and `>` are both considered valid endings for the `<br` tag, but you have to have one or the other and it will keep looking until it finds one.
Right, I think the person you’re replying to is partially correct in that the parser gets to “<br “ and recognizes that “this is be a br tag”, but it doesn’t close because tags can have any arbitrary attributes, and the W3C says br may also contain any of the global attributes. So, the parser indeed doesn’t just stop because it knows what tag it is and then doesn’t allow any attributes, it has to keep going until it reaches a valid closing “>”.
And then, when you've done that, you can just remove the "/>" bit, since it's a redundant rule.