Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 66ea32d

Browse filesBrowse files
committed
tools: enable no-extra-parens in ESLint
Enable `no-extra-parens`. This rule restricts the use of parentheses to only where they are necessary. It is set to be restricted to report only function expressions. PR-URL: #5512 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: James M Snell <jasnell@gmail.com>
1 parent 9091ccd commit 66ea32d
Copy full SHA for 66ea32d

File tree

Expand file treeCollapse file tree

2 files changed

+2
-1
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

2 files changed

+2
-1
lines changed
Open diff view settings
Collapse file

‎.eslintrc‎

Copy file name to clipboardExpand all lines: .eslintrc
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ rules:
1414
no-empty-character-class: 2
1515
no-ex-assign: 2
1616
no-extra-boolean-cast : 2
17+
no-extra-parens: [2, "functions"]
1718
no-extra-semi: 2
1819
no-func-assign: 2
1920
no-invalid-regexp: 2
Collapse file

‎test/parallel/test-util-inspect.js‎

Copy file name to clipboardExpand all lines: test/parallel/test-util-inspect.js
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -640,7 +640,7 @@ checkAlignment(new Map(big_array.map(function(y) { return [y, null]; })));
640640
}
641641

642642
{
643-
const x = new (function() {});
643+
const x = new function() {};
644644
assert.equal(util.inspect(x), '{}');
645645
}
646646

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.