Skip to content

Commit 948d69f

Browse files
committed
[FormatVariadic] Mark index as required in docstring
After looking at the formatv docstring, I thought the index was optional (as it is in other languages). This changes the header docs to show `index` instead of `[index]`, to indicate that it is required. Differential Revision: https://reviews.llvm.org/D118833
1 parent 18fa0b1 commit 948d69f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/include/llvm/Support/FormatVariadic.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ template <typename Tuple> class formatv_object : public formatv_object_base {
172172
// Formats textual output. `Fmt` is a string consisting of one or more
173173
// replacement sequences with the following grammar:
174174
//
175-
// rep_field ::= "{" [index] ["," layout] [":" format] "}"
175+
// rep_field ::= "{" index ["," layout] [":" format] "}"
176176
// index ::= <non-negative integer>
177177
// layout ::= [[[char]loc]width]
178178
// format ::= <any string not containing "{" or "}">

0 commit comments

Comments
 (0)