You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2019/03/23 10:19:55 UTC

[GitHub] [incubator-netbeans] matthiasblaesing commented on a change in pull request #1173: maven project compile args not passed to editor javac

matthiasblaesing commented on a change in pull request #1173: maven project compile args not passed to editor javac
URL: https://github.com/apache/incubator-netbeans/pull/1173#discussion_r268389485
 
 

 ##########
 File path: java/maven/src/org/netbeans/modules/maven/queries/PomCompilerOptionsQueryImpl.java
 ##########
 @@ -105,8 +105,11 @@ public Result getOptions(@NonNull final FileObject file) {
             String[] compilerArgs = PluginPropertyUtils.getPluginPropertyList(proj, Constants.GROUP_APACHE_PLUGINS, Constants.PLUGIN_COMPILER, "compilerArgs", "arg", null); // NOI18N
             if (compilerArgs != null) {
                 for (String compilerArg : compilerArgs) {
-                    if(compilerArg != null && ARG_PARAMETERS.equals(compilerArg.trim())) {
-                        return Arrays.asList(ARG_PARAMETERS);
+                    if (compilerArg != null)  {
+                        if (ARG_PARAMETERS.equals(compilerArg.trim())) {
+                            return Arrays.asList(ARG_PARAMETERS);//reqd?
 
 Review comment:
   In the original code there are only two cases:
   - if a compiler argument `-parameters` was provided, it will be returned
   - else an empty list is returned
   
   This makes sense reading the commit message of the addition:
   http://hg.netbeans.org/main-golden/log/tip/maven/src/org/netbeans/modules/maven/queries/PomCompilerOptionsQueryImpl.java 
   It is basicly a guard to limit the change to that single parameter.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists