mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 07:14:30 +02:00
8219475: javap man page needs to be updated
Reviewed-by: mchung
This commit is contained in:
parent
b75d37538d
commit
9d7777e585
2 changed files with 22 additions and 8 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2007, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
|
@ -326,6 +326,20 @@ public class JavapTask implements DisassemblerTool.DisassemblerTask, Messages {
|
|||
void process(JavapTask task, String opt, String arg) throws BadArgs {
|
||||
task.options.moduleName = arg;
|
||||
}
|
||||
},
|
||||
|
||||
// this option is processed by the launcher, and cannot be used when invoked via
|
||||
// an API like ToolProvider. It exists here to be documented in the command-line help.
|
||||
new Option(false, "-J") {
|
||||
@Override
|
||||
boolean matches(String opt) {
|
||||
return opt.startsWith("-J");
|
||||
}
|
||||
|
||||
@Override
|
||||
void process(JavapTask task, String opt, String arg) throws BadArgs {
|
||||
throw task.new BadArgs("err.only.for.launcher");
|
||||
}
|
||||
}
|
||||
|
||||
};
|
||||
|
@ -936,7 +950,7 @@ public class JavapTask implements DisassemblerTool.DisassemblerTask, Messages {
|
|||
printLines(getMessage("main.usage", progname));
|
||||
for (Option o: recognizedOptions) {
|
||||
String name = o.aliases[0].replaceAll("^-+", "").replaceAll("-+", "_"); // there must always be at least one name
|
||||
if (name.startsWith("X") || name.equals("fullversion") || name.equals("h") || name.equals("verify"))
|
||||
if (name.startsWith("X") || name.equals("fullversion"))
|
||||
continue;
|
||||
printLines(getMessage("main.opt." + name));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue