Skip to content

Commit 5c47ea0

Browse files
committed
Swift: Missing QLDoc / typos / missing private.
1 parent 0660f98 commit 5c47ea0

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

swift/ql/lib/codeql/swift/regex/Regex.qll

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,14 +84,20 @@ private class NSRegularExpressionRegexCreation extends RegexCreation {
8484
}
8585
}
8686

87-
newtype TRegexParseMode =
87+
private newtype TRegexParseMode =
8888
MkIgnoreCase() or // case insensitive
8989
MkVerbose() or // ignores whitespace and `#` comments within patterns
9090
MkDotAll() or // dot matches all characters, including line terminators
9191
MkMultiLine() or // `^` and `$` also match beginning and end of lines
9292
MkUnicode() // Unicode UAX 29 word boundary mode
9393

94+
/**
95+
* A regular expression parse mode flag.
96+
*/
9497
class RegexParseMode extends TRegexParseMode {
98+
/**
99+
* Gets the name of this parse mode flag.
100+
*/
95101
string getName() {
96102
this = MkIgnoreCase() and result = "IGNORECASE"
97103
or
@@ -120,7 +126,7 @@ class RegexAdditionalFlowStep extends Unit {
120126
/**
121127
* Holds if a regular expression parse mode is either set (`isSet` = true)
122128
* or unset (`isSet` = false) at `node`. Parse modes propagate through
123-
* array construction and regex constuction.
129+
* array construction and regex construction.
124130
*/
125131
abstract predicate setsParseMode(DataFlow::Node node, RegexParseMode mode, boolean isSet);
126132
}

0 commit comments

Comments
 (0)