On Fri, 21 Feb 2025 15:13:08 GMT, Nizar Benalla <nbena...@openjdk.org> wrote:

>> Some javadoc snippets can match multiple links to the same content, leading 
>> to different results in different javadoc runs.
>> This patch proposes emitting an error when such cases are encountered.
>> 
>> There is a very trivial, unrelated change in `TestGlobalHtml.java` because I 
>> noticed some whitespace wasn't right.
>
> Nizar Benalla has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   fix test bug

src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/taglets/SnippetTaglet.java
 line 152:

> 150:                                         linkTarget,
> 151:                                         l.target(),
> 152:                                         
> content.asCharSequence().toString().trim());

Would have beein interesting to use the error message that takes additional 
`start`, `pos` and `end` parameters to point to the location of the conflicting 
link inside the snippet. Worth a try if you're inclined, but not required.
Thanks for renaming the var!

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/23328#discussion_r1965665713

Reply via email to