1XOLINT(1)                 BSD General Commands Manual                XOLINT(1)
2

NAME

4     xolint — detect errors in programs using xo_emit(3)
5

SYNOPSIS

7     xolint [-c] [-C <flags>] [-d] [-D] [-I] [-p] [-V] [-X] [files...]
8

DESCRIPTION

10     xolint is a tool for reporting common mistakes in format strings in
11     source code that invokes xo_emit(3).  It allows these errors to be diag‐
12     nosed at build time, rather than waiting until runtime.
13
14     xolint takes one or more C files as arguments, and reports error, warn‐
15     ing, or informational messages as needed.
16
17     -c         Invoke 'cpp' against the input file
18
19     -C <flags>
20                Flags that are passed to 'cpp'
21
22     -d         Enable debug output
23
24     -D         Generate documentation for all xolint messages
25
26     -I         Generate a table of xo_info_t structures.
27
28     -p         Print the offending lines after the error message is displayed
29
30     -V         Do not report errors, but instead print a complete list of all
31                field names, sorted alphabetically.  The output can help spot
32                inconsistencies and spelling errors.
33
34     -X         Extract samples from xolint, suitable for internal testing.
35
36     The output message contains the source filename and line number, the
37     class of the message, the message, and, if -p is given, the line that
38     contains the error:
39
40               % xolint -t xolint.c
41               xolint.c: 16: error: anchor format should be "%d"
42               16         xo_emit("{[:/%s}");
43

SEE ALSO

45     libxo(3), xo_emit(3)
46

HISTORY

48     The libxo library first appeared in FreeBSD 11.0.
49

AUTHORS

51     libxo was written by Phil Shafer <phil@freebsd.org>.
52
53

ADDITIONAL DOCUMENTATION

55     FreeBSD uses libxo version 1.6.0.  Complete documentation can be found on
56     github:
57
58           https://juniper.github.io/libxo/1.6.0/html/index.html
59
60     libxo lives on github as:
61
62           https://github.com/Juniper/libxo
63
64     The latest release of libxo is available at:
65
66           https://github.com/Juniper/libxo/releases
67

HISTORY

69     The libxo library was added in FreeBSD 11.0.
70

AUTHOR

72     Phil Shafer
73
74BSD                            December 4, 2014                            BSD
Impressum