dukescript commented on pull request #106:
URL: 
https://github.com/apache/maven-javadoc-plugin/pull/106#issuecomment-953522559


   and finally use it as:
   ```diff
   diff --git a/pom.xml b/pom.xml
   new file mode 100644
   index 0000000..6b533c4
   --- /dev/null
   +++ b/pom.xml
   @@ -0,0 +1,51 @@
   +<?xml version="1.0" encoding="UTF-8"?>
   +<project xmlns="http://maven.apache.org/POM/4.0.0"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/xsd/maven-4.0.0.xsd";>
   +    <modelVersion>4.0.0</modelVersion>
   +    <groupId>frgaaldoc.demo</groupId>
   +    <artifactId>frgaaldoc</artifactId>
   +    <version>1.0-SNAPSHOT</version>
   +    <packaging>jar</packaging>
   +    <properties>
   +        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
   +        <maven.compiler.source>16</maven.compiler.source>
   +        <maven.compiler.target>8</maven.compiler.target>
   +    </properties>
   +    <build>
   +        <plugins>
   +            <plugin>
   +                <groupId>org.apache.maven.plugins</groupId>
   +                <artifactId>maven-compiler-plugin</artifactId>
   +                <version>3.8.1</version>
   +                <dependencies>
   +                    <dependency>
   +                        <groupId>org.frgaal</groupId>
   +                        <artifactId>compiler-maven-plugin</artifactId>
   +                        <version>16.0.1</version>
   +                    </dependency>
   +                </dependencies>
   +                <configuration>
   +                    <compilerId>frgaal</compilerId>
   +                    <source>16</source>
   +                    <target>1.8</target>
   +                    <compilerArgs>
   +                        <arg>-Xlint:deprecation</arg>
   +                    </compilerArgs>
   +                </configuration>
   +            </plugin>
   +            <plugin>
   +                <groupId>org.apache.maven.plugins</groupId>
   +                <artifactId>maven-javadoc-plugin</artifactId>
   +                <version>3.1.1</version>
   +                <dependencies>
   +                    <dependency>
   +                        <groupId>org.frgaal</groupId>
   +                        <artifactId>javadoc-maven-plugin</artifactId>
   +                        <version>16.0.1</version>
   +                    </dependency>
   +                </dependencies>
   +                <configuration>
   +                </configuration>
   +            </plugin>
   +        </plugins>
   +    </build>
   +</project>
   \ No newline at end of file
   diff --git a/src/main/java/frgaaldoc/demo/frgaaldoc/Main.java 
b/src/main/java/frgaaldoc/demo/frgaaldoc/Main.java
   new file mode 100644
   index 0000000..0090185
   --- /dev/null
   +++ b/src/main/java/frgaaldoc/demo/frgaaldoc/Main.java
   @@ -0,0 +1,12 @@
   +package frgaaldoc.demo.frgaaldoc;
   +
   +/** A class using text blocks */
   +public class Main {
   +    public static void main(String[] args) {
   +        var x = """
   +        Hello World!    
   +        """;
   +                   
   +        System.err.println(x);
   +    }
   +}
   ```
   
   without the change in this PR the ` mvn javadoc:javadoc` fails with:
   ```
   Failed to execute goal 
org.apache.maven.plugins:maven-javadoc-plugin:3.1.1:javadoc (default-cli) on 
project frgaaldoc: An error has occurred in Javadoc report generation: 
   Exit code: 1 - src/main/java/frgaaldoc/demo/frgaaldoc/Main.java:6: error: 
unclosed string literal
           var x = """
                     ^
   main/java/frgaaldoc/demo/frgaaldoc/Main.java:7: error: ';' expected
           Hello World!    
                      ^
   src/main/java/frgaaldoc/demo/frgaaldoc/Main.java:8: error: unclosed string 
literal
           """;
             ^
   ```
   with the change proposed by this PR the Javadoc can be generated without 
issues. Can you consider introduction of 
`org.apache.maven.plugins.javadoc.JavadocImplementation` or similar concept? It 
would help these alternative Java compilers a lot!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to