Skip to content
This repository was archived by the owner on Oct 15, 2020. It is now read-only.

Commit f480a95

Browse files
committed
meta: merge node/master into node-chakracore/master
Merge 3dfce5c as of 2018-03-08 This commit was automatically generated. For any problems, please contact jackhorton Reviewed-By: Jack Horton <jahorto@microsoft.com>
2 parents bbcf831 + 3dfce5c commit f480a95

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

50 files changed

+384
-208
lines changed

.eslintrc.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -58,12 +58,12 @@ module.exports = {
5858
'dot-location': ['error', 'property'],
5959
'dot-notation': 'error',
6060
'eol-last': 'error',
61-
eqeqeq: ['error', 'smart'],
61+
'eqeqeq': ['error', 'smart'],
6262
'for-direction': 'error',
6363
'func-call-spacing': 'error',
6464
'func-name-matching': 'error',
6565
'func-style': ['error', 'declaration', { allowArrowFunctions: true }],
66-
indent: ['error', 2, {
66+
'indent': ['error', 2, {
6767
ArrayExpression: 'first',
6868
CallExpression: { arguments: 'first' },
6969
FunctionDeclaration: { parameters: 'first' },
@@ -209,9 +209,10 @@ module.exports = {
209209
'one-var-declaration-per-line': 'error',
210210
'operator-linebreak': ['error', 'after'],
211211
'prefer-const': ['error', { ignoreReadBeforeAssign: true }],
212-
quotes: ['error', 'single', { avoidEscape: true }],
212+
'quotes': ['error', 'single', { avoidEscape: true }],
213+
'quote-props': ['error', 'consistent'],
213214
'rest-spread-spacing': 'error',
214-
semi: 'error',
215+
'semi': 'error',
215216
'semi-spacing': 'error',
216217
'space-before-blocks': ['error', 'always'],
217218
'space-before-function-paren': ['error', {
@@ -222,7 +223,7 @@ module.exports = {
222223
'space-in-parens': ['error', 'never'],
223224
'space-infix-ops': 'error',
224225
'space-unary-ops': 'error',
225-
strict: ['error', 'global'],
226+
'strict': ['error', 'global'],
226227
'symbol-description': 'error',
227228
'template-curly-spacing': 'error',
228229
'unicode-bom': 'error',

CHANGELOG.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,9 @@ release.
3131
</tr>
3232
<tr>
3333
<td valign="top">
34-
<b><a href="doc/changelogs/CHANGELOG_V9.md#9.7.0">9.7.0</a></b><br/>
34+
<b><a href="doc/changelogs/CHANGELOG_V9.md#9.8.0">9.8.0</a></b><br/>
35+
<a href="doc/changelogs/CHANGELOG_V9.md#9.7.1">9.7.1</a><br/>
36+
<a href="doc/changelogs/CHANGELOG_V9.md#9.7.0">9.7.0</a><br/>
3537
<a href="doc/changelogs/CHANGELOG_V9.md#9.6.1">9.6.1</a><br/>
3638
<a href="doc/changelogs/CHANGELOG_V9.md#9.6.0">9.6.0</a><br/>
3739
<a href="doc/changelogs/CHANGELOG_V9.md#9.5.0">9.5.0</a><br/>

benchmark/querystring/querystring-stringify.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ function main({ type, n }) {
1717
encodemany: {
1818
'\u0080\u0083\u0089': 'bar',
1919
'\u008C\u008E\u0099': 'quux',
20-
xyzzy: '\u00A5q\u00A3r'
20+
'xyzzy': '\u00A5q\u00A3r'
2121
},
2222
encodelast: {
2323
foo: 'bar',

doc/api/cli.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ tracing is enabled using `--trace-events-enabled`.
237237

238238
### `--trace-event-file-pattern`
239239
<!-- YAML
240-
added: REPLACEME
240+
added: v9.8.0
241241
-->
242242

243243
Template string specifying the filepath for the trace event data, it

doc/api/deprecations.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -915,7 +915,6 @@ Type: Runtime
915915
916916
This was never a documented feature.
917917
918-
919918
<a id="DEP0101"></a>
920919
### DEP0101: --with-lttng
921920
@@ -940,6 +939,17 @@ Type: Documentation-only (supports [`--pending-deprecation`][])
940939
Using `process.binding()` in general should be avoided. The type checking
941940
methods in particular can be replaced by using [`util.types`][].
942941
942+
<a id="DEP0104"></a>
943+
### DEP0104: process.env string coercion
944+
945+
Type: Documentation-only (supports [`--pending-deprecation`][])
946+
947+
Currently when assigning a property to [`process.env`][], the assigned value is
948+
implicitly converted to a string if it is not a string. This behavior is
949+
deprecated if the assigned value is not a string, boolean, or number. In the
950+
future, such assignment may result in a thrown error. Please convert the
951+
property to a string before assigning it to `process.env`.
952+
943953
[`--pending-deprecation`]: cli.html#cli_pending_deprecation
944954
[`Buffer.allocUnsafeSlow(size)`]: buffer.html#buffer_class_method_buffer_allocunsafeslow_size
945955
[`Buffer.from(array)`]: buffer.html#buffer_class_method_buffer_from_array
@@ -976,6 +986,7 @@ methods in particular can be replaced by using [`util.types`][].
976986
[`fs.stat()`]: fs.html#fs_fs_stat_path_callback
977987
[`os.networkInterfaces`]: os.html#os_os_networkinterfaces
978988
[`os.tmpdir()`]: os.html#os_os_tmpdir
989+
[`process.env`]: process.html#process_process_env
979990
[`punycode`]: punycode.html
980991
[`require.extensions`]: modules.html#modules_require_extensions
981992
[`setInterval()`]: timers.html#timers_setinterval_callback_delay_args

doc/api/inspector.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,8 +136,34 @@ with an error. [`session.connect()`] will need to be called to be able to send
136136
messages again. Reconnected session will lose all inspector state, such as
137137
enabled agents or configured breakpoints.
138138

139+
## Example usage
140+
141+
### CPU Profiler
142+
143+
Apart from the debugger, various V8 Profilers are available through the DevTools
144+
protocol. Here's a simple example showing how to use the [CPU profiler][]:
145+
146+
```js
147+
const inspector = require('inspector');
148+
149+
const session = new inspector.Session();
150+
session.connect();
151+
152+
session.post('Profiler.enable', () => {
153+
session.post('Profiler.start', () => {
154+
// invoke business logic under measurement here...
155+
156+
// some time later...
157+
session.post('Profiler.stop', ({ profile }) => {
158+
// write profile to disk, upload, etc.
159+
});
160+
});
161+
});
162+
```
163+
139164

140165
[`session.connect()`]: #inspector_session_connect
141166
[`Debugger.paused`]: https://chromedevtools.github.io/devtools-protocol/v8/Debugger/#event-paused
142167
[`EventEmitter`]: events.html#events_class_eventemitter
143168
[Chrome DevTools Protocol Viewer]: https://chromedevtools.github.io/devtools-protocol/v8/
169+
[CPU Profiler]: https://chromedevtools.github.io/devtools-protocol/v8/Profiler

doc/api/process.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -836,6 +836,10 @@ emitMyWarning();
836836
## process.env
837837
<!-- YAML
838838
added: v0.1.27
839+
changes:
840+
- version: REPLACEME
841+
pr-url: https://github.com/nodejs/node/pull/18990
842+
description: Implicit conversion of variable value to string is deprecated.
839843
-->
840844

841845
* {Object}
@@ -877,7 +881,8 @@ console.log(process.env.foo);
877881
```
878882

879883
Assigning a property on `process.env` will implicitly convert the value
880-
to a string.
884+
to a string. **This behavior is deprecated.** Future versions of Node.js may
885+
throw an error when the value is not a string, number, or boolean.
881886

882887
Example:
883888

doc/api/repl.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ global or scoped variable, the input `fs` will be evaluated on-demand as
144144
#### Assignment of the `_` (underscore) variable
145145
<!-- YAML
146146
changes:
147-
- version: REPLACEME
147+
- version: v9.8.0
148148
pr-url: https://github.com/nodejs/node/pull/18919
149149
description: Added `_error` support.
150150
-->

0 commit comments

Comments
 (0)