Inspectopedia
 
2024.3

Text block can be replaced with regular string literal

Info
New
Last modified: 03 December 2024

Reports text blocks that can be replaced with regular string literals. This may help to downgrade for backward compatibility with earlier Java versions.

Example:

After the quick fix is applied:

This inspection depends on the Java feature 'Text block literals', which is available since Java 15.

New in 2019.3