Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for d flag #261

Merged
merged 1 commit into from
Jun 24, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/rules/no-non-standard-flag.ts
Expand Up @@ -2,7 +2,7 @@ import type { RegExpVisitor } from "regexpp/visitor"
import type { RegExpContext } from "../utils"
import { createRule, defineRegexpVisitor } from "../utils"

const STANDARD_FLAGS = "gimsuy"
const STANDARD_FLAGS = "dgimsuy"

export default createRule("no-non-standard-flag", {
meta: {
Expand Down
1 change: 1 addition & 0 deletions lib/rules/no-super-linear-backtracking.ts
Expand Up @@ -42,6 +42,7 @@ function getParsedLiteral(context: RegExpContext): ParsedLiteral {
end: NaN,
dotAll: flags.dotAll ?? false,
global: flags.global ?? false,
hasIndices: flags.hasIndices ?? false,
ignoreCase: flags.ignoreCase ?? false,
multiline: flags.multiline ?? false,
sticky: flags.sticky ?? false,
Expand Down
1 change: 1 addition & 0 deletions lib/rules/no-super-linear-move.ts
Expand Up @@ -44,6 +44,7 @@ function getParsedLiteral(
end: NaN,
dotAll: flags.dotAll ?? false,
global: flags.global ?? false,
hasIndices: flags.hasIndices ?? false,
ignoreCase: flags.ignoreCase ?? false,
multiline: flags.multiline ?? false,
sticky: !ignoreSticky && (flags.sticky ?? false),
Expand Down
6 changes: 3 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -90,7 +90,7 @@
"jsdoctypeparser": "^9.0.0",
"refa": "^0.8.0",
"regexp-ast-analysis": "^0.2.2",
"regexpp": "^3.1.0",
"regexpp": "^3.2.0",
"scslre": "^0.1.5"
}
}
97 changes: 0 additions & 97 deletions tests/lib/rules-with-d-flag.ts

This file was deleted.