github / github/codeql

Java: JavadocText does not exist for empty block comment / javadoc lines

Abierto
#3,827 0 comentarios 0 reacciones 0 asignados Ver en GitHub
Java question
Lenguaje dominante
CodeQL
Estrellas
10.1k
Forks
2.1k
Merge medio
2 d 15 h
PR fusionados (30 d)
141

Descripción

**Description of the issue**
`JavadocText` represents a single line of a block or javadoc comment, see #3696.
However, it appears `JavadocText` does not exist for empty lines (unless they are single line comments).
Example query:
```ql
import java

from JavadocText text
where
text.getText().regexpMatch("[ \t]*")
// Make sure this is not a single line comment
and exists (text.getParent+().(Javadoc).getCommentedElement())
select text
```

It would be quite useful to detect empty lines, e.g. to find out if javadoc is missing HTML tags such as `
` or `

` to create proper line breaks. If that is the case the output will contain everything within the same line.

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.