Skip to content

Commit da167ea

Browse files
ellishgtmsri
authored andcommitted
[NFC][Glob] Escape backslash to fix doxygen rendering (llvm#109055)
The docs for Glob wasn't rendered correctly, I believe because the `\` was not properly escaped. I haven't built these docs locally, so I'll follow up to see if this is fixed after it lands. https://llvm.org/doxygen/classllvm_1_1GlobPattern.html
1 parent 08b1d20 commit da167ea

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

llvm/include/llvm/Support/GlobPattern.h

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@ namespace llvm {
3434
/// expansions are not supported. If \p MaxSubPatterns is empty then
3535
/// brace expansions are not supported and characters \p "{,}" are treated as
3636
/// literals.
37-
/// * \p "\" escapes the next character so it is treated as a literal.
38-
///
37+
/// * \p "\\" (a single backslash) escapes the next character so it is treated
38+
/// as a literal.
3939
///
4040
/// Some known edge cases are:
4141
/// * \p "]" is allowed as the first character in a character class, i.e.,
@@ -45,9 +45,8 @@ namespace llvm {
4545
/// * \p "}" and \p "," that are not inside a brace expansion are taken as
4646
/// literals, e.g., \p ",}" is valid but \p "{" is not.
4747
///
48-
///
49-
/// For example, \p "*[/\\]foo.{c,cpp}" will match (unix or windows) paths to
50-
/// all files named \p "foo.c" or \p "foo.cpp".
48+
/// For example, \p "*[/\\\\]foo.{c,cpp}" (with two backslashes) will match
49+
/// (unix or windows) paths to all files named \p "foo.c" or \p "foo.cpp".
5150
class GlobPattern {
5251
public:
5352
/// \param Pat the pattern to match against

0 commit comments

Comments
 (0)