-
-
Notifications
You must be signed in to change notification settings - Fork 33.8k
Closed
Labels
duplicateIssues and PRs that are duplicates of other issues or PRs.Issues and PRs that are duplicates of other issues or PRs.
Description
Version
v10.24.1
Platform
Linux LAPTOP 5.11.0-27-generic #29~20.04.1-Ubuntu SMP Wed Aug 11 15:58:17 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
Subsystem
No response
What steps will reproduce the bug?
$ cat file.js
a = 0;
console.log("strict mode not enabled");
$ node --use-strict file.js
strict mode not enabled
How often does it reproduce? Is there a required condition?
Reproduces for latest node releases for versions 10, 12, 14, 16
node/10.24.1
node/12.22.6
node/14.17.6
node/16.8.0
Works fine for node v8.17.0
What is the expected behavior?
ReferenceError: a is not defined should be thrown
What do you see instead?
The file is not run in strict mode.
Additional information
No response
Metadata
Metadata
Assignees
Labels
duplicateIssues and PRs that are duplicates of other issues or PRs.Issues and PRs that are duplicates of other issues or PRs.