summaryrefslogtreecommitdiffstats
path: root/llvm/docs/CommandLine.rst
Commit message (Collapse)AuthorAgeFilesLines
* [CommandLine] Add callbacks to OptionsDon Hinton2019-12-061-0/+25
| | | | | | | | | | | | | | | | | | | | | | Summary: Add a new cl::callback attribute to Option. This attribute specifies a callback function that is called when an option is seen, and can be used to set other options, as in option A implies option B. If the option is a `cl::list`, and `cl::CommaSeparated` is also specified, the callback will fire once for each value. This could be used to validate combinations or selectively set other options. Reviewers: beanz, thomasfinch, MaskRay, thopre, serge-sans-paille Reviewed By: beanz Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D70620
* [docs] Remove dangling parenthesis from documentationTim Northover2019-11-191-1/+1
| | | | Patch by leiteg.
* [NFC] fix trivial typos in documentsHiroshi Inoue2019-06-251-1/+1
| | | | llvm-svn: 364278
* [docs] Put DefaultOption bullet in alphabetical order.Don Hinton2019-04-261-8/+8
| | | | llvm-svn: 359309
* [CommandLineParser] Add DefaultOption flagDon Hinton2019-04-151-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: Add DefaultOption flag to CommandLineParser which provides a default option or alias, but allows users to override it for some other purpose as needed. Also, add `-h` as a default alias to `-help`, which can be seamlessly overridden by applications like llvm-objdump and llvm-readobj which use `-h` as an alias for other options. (relanding after revert, r358414) Added DefaultOptions.clear() to reset(). Reviewers: alexfh, klimek Reviewed By: klimek Subscribers: kristina, MaskRay, mehdi_amini, inglorion, dexonsmith, hiraditya, llvm-commits, jhenderson, arphaman, cfe-commits Tags: #clang, #llvm Differential Revision: https://reviews.llvm.org/D59746 llvm-svn: 358428
* Revert r358337: "[CommandLineParser] Add DefaultOption flag"Ilya Biryukov2019-04-151-10/+0
| | | | | | | The change causes test failures under asan. Reverting to unbreak our integrate. llvm-svn: 358414
* [CommandLineParser] Add DefaultOption flagDon Hinton2019-04-131-0/+10
| | | | | | | | | | | | | | | | | | | | | | Summary: Add DefaultOption flag to CommandLineParser which provides a default option or alias, but allows users to override it for some other purpose as needed. Also, add `-h` as a default alias to `-help`, which can be seamlessly overridden by applications like llvm-objdump and llvm-readobj which use `-h` as an alias for other options. Reviewers: alexfh, klimek Reviewed By: klimek Subscribers: MaskRay, mehdi_amini, inglorion, dexonsmith, hiraditya, llvm-commits, jhenderson, arphaman, cfe-commits Tags: #clang, #llvm Differential Revision: https://reviews.llvm.org/D59746 llvm-svn: 358337
* [CommandLine] Allow grouping options which can have values.Igor Kudrin2019-03-011-20/+29
| | | | | | | | | | | | | | | | This patch allows all forms of values for options to be used at the end of a group. With the fix, it is possible to follow the way GNU binutils tools handle grouping options better. For example, the -j option can be used with objdump in any of the following ways: $ objdump -d -j .text a.o $ objdump -d -j.text a.o $ objdump -dj .text a.o $ objdump -dj.text a.o Differential Revision: https://reviews.llvm.org/D58711 llvm-svn: 355185
* [CommandLine] Do not crash if an option has both ValueRequired and Grouping.Igor Kudrin2019-03-011-1/+2
| | | | | | | | | | | | If an option, which requires a value, has a `cl::Grouping` formatting modifier, it works well as far as it is used at the end of a group, or as a separate argument. However, if the option appears accidentally in the middle of a group, the program just crashes. This patch prints an error message instead. Differential Revision: https://reviews.llvm.org/D58499 llvm-svn: 355184
* Rename DEBUG macro to LLVM_DEBUG.Nicola Zaghen2018-05-141-3/+3
| | | | | | | | | | | | | | | | The DEBUG() macro is very generic so it might clash with other projects. The renaming was done as follows: - git grep -l 'DEBUG' | xargs sed -i 's/\bDEBUG\s\?(/LLVM_DEBUG(/g' - git diff -U0 master | ../clang/tools/clang-format/clang-format-diff.py -i -p1 -style LLVM - Manual change to APInt - Manually chage DOCS as regex doesn't match it. In the transition period the DEBUG() macro is still present and aliased to the LLVM_DEBUG() one. Differential Revision: https://reviews.llvm.org/D43624 llvm-svn: 332240
* NFC - Typo fixes lib/VMCore -> lib/IRGabor Buella2018-04-301-1/+1
| | | | llvm-svn: 331166
* Remove references to response file argument in CommandLine.rstDave Lee2017-09-201-8/+4
| | | | | | | | | | | | | | | | | Summary: The documentation refers to a boolean that controls whether response files are handled, but this is incorrect. Since r165535, response files are always enabled. Reviewers: compnerd, rafael Reviewed By: compnerd Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D38095 llvm-svn: 313830
* Update CommandLine.rst getRegisteredOptions exampleBrian Gesiak2016-11-071-2/+1
| | | | | | | | | | Summary: Update the docs to match the changes in http://reviews.llvm.org/D7132 Reviewers: beanz, llvm-commits, modocache Differential Revision: https://reviews.llvm.org/D26296 llvm-svn: 286094
* Update documentation after r283671 ("Turn cl::values() (for enum) from a ↵Mehdi Amini2016-10-101-7/+5
| | | | | | vararg function to using C++ variadic template") llvm-svn: 283782
* Turn cl::values() (for enum) from a vararg function to using C++ variadic ↵Mehdi Amini2016-10-081-10/+5
| | | | | | | | | | | | | | | template The core of the change is supposed to be NFC, however it also fixes what I believe was an undefined behavior when calling: va_start(ValueArgs, Desc); with Desc being a StringRef. Differential Revision: https://reviews.llvm.org/D25342 llvm-svn: 283671
* Add missing underlines for a docs section. NFCJonathan Roelofs2015-07-241-0/+1
| | | | llvm-svn: 243075
* Update the example of using a command-line option custom parser toPaul Robinson2014-10-131-5/+5
| | | | | | | | match the current implementation. Patch by Douglas Yung! llvm-svn: 219631
* Correct word hyphenationsAlp Toker2013-12-051-1/+1
| | | | | | | This patch tries to avoid unrelated changes other than fixing a few hyphen-related ambiguities and contractions in nearby lines. llvm-svn: 196471
* CommandLine.rst: remove tiny bit of bad mark-upHans Wennborg2013-07-101-1/+1
| | | | llvm-svn: 186042
* Better output for long help strings for command-line options.Alexander Kornienko2013-05-101-1/+2
| | | | | | | | | | | | | | | | | | | | | Summary: This patch allows using \n inside long help strings for command-line options, so that all lines are equally indented. This is not a perfect solution, as we don't (and probably don't want to) know about terminal width, but it allows to format long help strings somehow readable without manually padding them with spaces. A motivating example is -help output from clang-format (source code in tools/clang-format/ClangFormat.cpp, see cl options offset, length, style, and dump-config). Reviewers: atrick, alexfh Reviewed By: alexfh CC: llvm-commits, rafael Differential Revision: http://llvm-reviews.chandlerc.com/D779 llvm-svn: 181608
* Add two points to release notes about recent command line library changes.Andrew Trick2013-05-071-0/+2
| | | | | | Patch by Dan Liew! llvm-svn: 181335
* Implemented public interface for modifying registered (not positional or ↵Andrew Trick2013-05-061-0/+51
| | | | | | | | sink options) command line options at runtime. Patch by Dan Liew! llvm-svn: 181254
* Support command line option categories.Andrew Trick2013-05-061-0/+75
| | | | | | Patch by Dan Liew! llvm-svn: 181253
* Added table of contents declaration in CommandLine Library documentation.Tobias Grosser2013-05-021-0/+3
| | | | | Contributed-by: Dan Liew <daniel.liew@imperial.ac.uk> llvm-svn: 180919
* docs: Fix long standing linking antipattern.Sean Silva2013-01-111-2/+0
| | | | | | | | | Before we learned about :doc:, we used :ref: and put a dummy link at the top of each page. Don't do that anymore. This fixes PR14891 as a special case. llvm-svn: 172162
* remove the rest of the "written by" lines in the documentation. It isChris Lattner2013-01-101-3/+1
| | | | | | | against the developer policy to include this sort of thing as SVN blame already captures this in a far more fine-grained way. llvm-svn: 172109
* Sphinxify the CommandLine document.Bill Wendling2012-08-081-0/+1615
llvm-svn: 161479
OpenPOWER on IntegriCloud