Claude Warren created CLI-331:
---------------------------------

             Summary: Deprecated option usage is not detected if non string 
keys are used for resolution.
                 Key: CLI-331
                 URL: https://issues.apache.org/jira/browse/CLI-331
             Project: Commons CLI
          Issue Type: Bug
          Components: CLI-1.x
    Affects Versions: 1.7.0
            Reporter: Claude Warren


CommandLine.handleDeprecated() is not called if the option key is not a string.

 

For example getOptionValue() has both String and Option parameter types. 
 * getOptionValue(String) calls handleDeprecated()
 * getOptionValue(Option) does not call handleDeprecated().

In most cases the String parameter resolves the Option and calls the Option 
parameter method of the same name. 

The fix is to move the handleDeprecated() into the Option processing path.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to