implements: drop --annotate option

Currently, annotating the functions (are they documented, deprecated,
etc) in the function listing is not very costly and there are very
few situations where that extra information would be unwanted. Just
annotate the listing every time when running the tool.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
This commit is contained in:
John Mulligan 2020-05-08 10:27:42 -04:00 committed by John Mulligan
parent b450208827
commit 3ad6ad0473
1 changed files with 4 additions and 4 deletions

View File

@ -13,7 +13,7 @@ package main
// ./implements ./cephfs ./rados ./rbd // ./implements ./cephfs ./rados ./rbd
// //
// # generate a comprehensive report on rbd in json // # generate a comprehensive report on rbd in json
// ./implements --list --annotate --json rbd // ./implements --list --json rbd
import ( import (
"flag" "flag"
@ -27,7 +27,6 @@ import (
var ( var (
verbose bool verbose bool
list bool list bool
annotate bool
reportJSON bool reportJSON bool
// verbose logger // verbose logger
@ -41,7 +40,6 @@ func abort(msg string) {
func init() { func init() {
flag.BoolVar(&verbose, "verbose", false, "be more verbose (for debugging)") flag.BoolVar(&verbose, "verbose", false, "be more verbose (for debugging)")
flag.BoolVar(&list, "list", false, "list functions") flag.BoolVar(&list, "list", false, "list functions")
flag.BoolVar(&annotate, "annotate", false, "annotate functions")
flag.BoolVar(&reportJSON, "json", false, "use JSON output format") flag.BoolVar(&reportJSON, "json", false, "use JSON output format")
} }
@ -56,9 +54,11 @@ func main() {
} }
var r implements.Reporter var r implements.Reporter
// always annotate for now, leave the option of disabling it someday if it
// gets costly
o := implements.ReportOptions{ o := implements.ReportOptions{
List: list, List: list,
Annotate: annotate, Annotate: true,
} }
switch { switch {
case reportJSON: case reportJSON: