Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DelimitedOptionHandler.printDefaultValue() throws NPE (when there are no defaults) #166

Open
atnak opened this issue Dec 13, 2018 · 0 comments

Comments

@atnak
Copy link

atnak commented Dec 13, 2018

This causes CmdLineParser.printUsage() to throw NPE, and appears to be a regression of "default values in usage".

It affects classes subclassing DelimitedOptionHandler such as MultiPathOptionHandler and MultiFileOptionHandler.

Minimal code to reproduce

public class Foo {

	@Argument(usage = "Foo", handler = MultiPathOptionHandler.class)
	List<Path> paths;

	public static void main(String[] args) {
		new CmdLineParser(new Foo()).printUsage(System.out);
	}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant