On Fri, 24 Jan 2025, David Malcolm wrote: > The attached patch adds a postprocessing step to "bin" that > turns e.g. > <h1 id="ID">TEXT</h1> > to: > <h1 id="ID"><a href="#ID">TEXT</a></h1>
It looks like this is causing an issue for (at least) one of our pages. http://gcc.gnu.org/projects/cxx-status.html no longer validates with Error: Start tag a seen but an element of the same type was already open. From line 644, column 32; to line 644, column 48 ...d="cxx2a"><a href="#cxx20"><a id=... Error: Duplicate ID cxx2a. From line 644, column 49; to line 644, column 62 ...="#cxx20"><a id="cxx2a">C++20... See https://validator.w3.org /nu/?doc=http://gcc.gnu.org/projects/cxx-status.html The HTML in question in projects/cxx-status.html is <h2 id="cxx20"><a id="cxx2a">C++20 Support in GCC</a></h2> which the script transforms to <h2 id="cxx20"><a id="cxx2a"><a href="#cxx20"><a id="cxx2a">C++20 Support in GCC</a></a></h2>↩ The original, valid HTML comes from the following two commits, so copying Jonathan: commit a5a3dc2f85786b038bc66b0e1929fdc67095397b Author: Gerald Pfeifer <ger...@pfeifer.com> Date: Thu May 11 22:24:02 2023 +0200 projects/cxx-status: Fix markup Commit a09e584729 introduced an <a id="..."> without corresponding </a>. commit a09e584729c3136719d8870ad0c26870de8a552f Author: Jonathan Wakely <jwak...@redhat.com> Date: Wed Mar 22 10:36:37 2023 +0000 Clarify experimental status of C++17 prior to GCC 9 Also link to library docs for C++20 and add a cxx2a anchor which is used by some old links. One way to address this would be removing the cxx2a anchor again, though per se it is legitimate and valid HTML. The duplication of <a id="cxx2a"> does look like an issue with the Python script, though, which might cause other issues down the road? Gerald