Skip to content

Commit ab28a9b

Browse files
authored
Merge branch 'nodejs:main' into main
2 parents 5f32f2f + 77e8d44 commit ab28a9b

71 files changed

Lines changed: 1783 additions & 400 deletions

File tree

Some content is hidden

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

.configurations/configuration.dsc.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ properties:
55
- resource: Microsoft.WinGet.DSC/WinGetPackage
66
id: pythonPackage
77
directives:
8-
description: Install Python 3.12
8+
description: Install Python 3.14
99
module: Microsoft.WinGet.DSC
1010
allowPrerelease: true
1111
settings:
12-
id: Python.Python.3.12
12+
id: Python.Python.3.14
1313
source: winget
1414
- resource: Microsoft.WinGet.DSC/WinGetPackage
1515
id: vsPackage
@@ -51,4 +51,4 @@ properties:
5151
settings:
5252
id: Nasm.Nasm
5353
source: winget
54-
configurationVersion: 0.1.0
54+
configurationVersion: 0.1.1

.configurations/configuration.vsEnterprise.dsc.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ properties:
55
- resource: Microsoft.WinGet.DSC/WinGetPackage
66
id: pythonPackage
77
directives:
8-
description: Install Python 3.12
8+
description: Install Python 3.14
99
module: Microsoft.WinGet.DSC
1010
allowPrerelease: true
1111
settings:
12-
id: Python.Python.3.12
12+
id: Python.Python.3.14
1313
source: winget
1414
- resource: Microsoft.WinGet.DSC/WinGetPackage
1515
id: vsPackage
@@ -51,4 +51,4 @@ properties:
5151
settings:
5252
id: Nasm.Nasm
5353
source: winget
54-
configurationVersion: 0.1.0
54+
configurationVersion: 0.1.1

.configurations/configuration.vsProfessional.dsc.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ properties:
55
- resource: Microsoft.WinGet.DSC/WinGetPackage
66
id: pythonPackage
77
directives:
8-
description: Install Python 3.12
8+
description: Install Python 3.14
99
module: Microsoft.WinGet.DSC
1010
allowPrerelease: true
1111
settings:
12-
id: Python.Python.3.12
12+
id: Python.Python.3.14
1313
source: winget
1414
- resource: Microsoft.WinGet.DSC/WinGetPackage
1515
id: vsPackage
@@ -51,4 +51,4 @@ properties:
5151
settings:
5252
id: Nasm.Nasm
5353
source: winget
54-
configurationVersion: 0.1.0
54+
configurationVersion: 0.1.1

.github/workflows/lint-release-proposal.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ jobs:
2626
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
2727
with:
2828
persist-credentials: false
29+
fetch-depth: 2
2930
- name: Lint release commit title format
3031
run: |
3132
EXPECTED_TITLE='^[[:digit:]]{4}-[[:digit:]]{2}-[[:digit:]]{2}, Version [[:digit:]]+\.[[:digit:]]+\.[[:digit:]]+ (\(Current|'.+' \(LTS)\)$'
@@ -51,6 +52,29 @@ jobs:
5152
- name: Verify it's release-ready
5253
run: |
5354
SKIP_XZ=1 make release-only
55+
- name: Lint release commit content
56+
run: |
57+
MAJOR="$(awk '/^#define NODE_MAJOR_VERSION / { print $3 }' src/node_version.h)"
58+
59+
echo "Checking for expected files in the release commit:"
60+
missing_expected=
61+
for expected in CHANGELOG.md src/node_version.h doc/changelogs/; do
62+
if git diff --exit-code --quiet --diff-filter=M HEAD^ -- "$expected"; then
63+
echo "Missing expected file in diff: $expected"
64+
missing_expected=1
65+
fi
66+
done
67+
[ -z "$missing_expected" ] || exit 1
68+
69+
echo "Checking for unexpected files in the release commit:"
70+
set -ex
71+
[ -z "$(git diff-tree --no-commit-id --name-only -r HEAD --\
72+
. \
73+
':(exclude)CHANGELOG.md' \
74+
':(exclude)src/node_version.h' \
75+
':(exclude)test/parallel/test-process-release.js' \
76+
':(exclude)doc/api/' \
77+
":(exclude)doc/changelogs/CHANGELOG_V$MAJOR.md")" ]
5478
- name: Validate CHANGELOG
5579
id: releaser-info
5680
run: |

BUILDING.md

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -735,8 +735,8 @@ Refs:
735735

736736
##### Option 1: Manual install
737737

738-
* The current [version of Python][Python versions] from the
739-
[Microsoft Store](https://apps.microsoft.com/store/search?publisher=Python+Software+Foundation)
738+
* The current [version of Python][Python downloads] by following the instructions in
739+
[Using Python on Windows][].
740740
* The "Desktop development with C++" workload from
741741
[Visual Studio 2022 (17.13 or newer)](https://visualstudio.microsoft.com/downloads/)
742742
or the "C++ build tools" workload from the
@@ -780,25 +780,17 @@ easily. These files will install the following
780780
[WinGet](https://learn.microsoft.com/en-us/windows/package-manager/winget/) packages:
781781

782782
* Git for Windows with the `git` and Unix tools added to the `PATH`
783-
* `Python 3.12`
783+
* `Python 3.14`
784784
* `Visual Studio 2022` (Community, Enterprise or Professional)
785785
* `Visual Studio 2022 Build Tools` with Visual C++ workload, Clang and ClangToolset
786786
* `NetWide Assembler`
787787

788-
To install Node.js prerequisites from Powershell Terminal:
788+
To install Node.js prerequisites from PowerShell Terminal:
789789

790790
```powershell
791791
winget configure .\.configurations\configuration.dsc.yaml
792792
```
793793

794-
Alternatively, you can use [Dev Home](https://learn.microsoft.com/en-us/windows/dev-home/)
795-
to install the prerequisites:
796-
797-
* Switch to `Machine Configuration` tab
798-
* Click on `Configuration File`
799-
* Choose the corresponding WinGet configuration file
800-
* Click on `Set up as admin`
801-
802794
##### Option 3: Automated install with Boxstarter
803795

804796
A [Boxstarter](https://boxstarter.org/) script can be used for easy setup of
@@ -1146,4 +1138,6 @@ by opening a pull request against the registry available at
11461138

11471139
[AIX toolbox]: https://www.ibm.com/support/pages/aix-toolbox-open-source-software-overview
11481140
[Developer Mode]: https://learn.microsoft.com/en-us/windows/advanced-settings/developer-mode
1141+
[Python downloads]: https://www.python.org/downloads/
11491142
[Python versions]: https://devguide.python.org/versions/
1143+
[Using Python on Windows]: https://docs.python.org/3/using/windows.html
Lines changed: 34 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,47 @@
1-
--- trap-handler.h 2022-08-11 09:01:23.384000000 +0800
2-
+++ fixed-trap-handler.h 2022-08-11 09:09:15.352000000 +0800
3-
@@ -17,23 +17,7 @@
4-
namespace internal {
5-
namespace trap_handler {
6-
1+
--- trap-handler.h
2+
+++ fixed-trap-handler.h
3+
@@ -18,43 +18,1 @@
74
-// X64 on Linux, Windows, MacOS, FreeBSD.
85
-#if V8_HOST_ARCH_X64 && V8_TARGET_ARCH_X64 && \
96
- ((V8_OS_LINUX && !V8_OS_ANDROID) || V8_OS_WIN || V8_OS_DARWIN || \
107
- V8_OS_FREEBSD)
118
-#define V8_TRAP_HANDLER_SUPPORTED true
12-
-// Arm64 (non-simulator) on Mac.
13-
-#elif V8_TARGET_ARCH_ARM64 && V8_HOST_ARCH_ARM64 && V8_OS_DARWIN
9+
-// Arm64 native on Linux, Windows, MacOS.
10+
-#elif V8_TARGET_ARCH_ARM64 && V8_HOST_ARCH_ARM64 && \
11+
- ((V8_OS_LINUX && !V8_OS_ANDROID) || V8_OS_WIN || V8_OS_DARWIN)
1412
-#define V8_TRAP_HANDLER_SUPPORTED true
13+
-// For Linux and Mac, enable the simulator when it's been requested.
14+
-#if USE_SIMULATOR && ((V8_OS_LINUX && !V8_OS_ANDROID) || V8_OS_DARWIN)
15+
-#define V8_TRAP_HANDLER_VIA_SIMULATOR
16+
-#endif
1517
-// Arm64 simulator on x64 on Linux, Mac, or Windows.
18+
-//
19+
-// The simulator case uses some inline assembly code, which cannot be
20+
-// compiled with MSVC, so don't enable the trap handler in that case.
21+
-// (MSVC #defines _MSC_VER, but so does Clang when targeting Windows, hence
22+
-// the check for __clang__.)
1623
-#elif V8_TARGET_ARCH_ARM64 && V8_HOST_ARCH_X64 && \
17-
- (V8_OS_LINUX || V8_OS_DARWIN)
24+
- (V8_OS_LINUX || V8_OS_DARWIN || V8_OS_WIN) && \
25+
- (!defined(_MSC_VER) || defined(__clang__))
26+
-#define V8_TRAP_HANDLER_VIA_SIMULATOR
27+
-#define V8_TRAP_HANDLER_SUPPORTED true
28+
-// Loong64 (non-simulator) on Linux.
29+
-#elif V8_TARGET_ARCH_LOONG64 && V8_HOST_ARCH_LOONG64 && V8_OS_LINUX
30+
-#define V8_TRAP_HANDLER_SUPPORTED true
31+
-// Loong64 simulator on x64 on Linux
32+
-#elif V8_TARGET_ARCH_LOONG64 && V8_HOST_ARCH_X64 && V8_OS_LINUX
33+
-#define V8_TRAP_HANDLER_VIA_SIMULATOR
34+
-#define V8_TRAP_HANDLER_SUPPORTED true
35+
-// RISCV64 (non-simulator) on Linux.
36+
-#elif V8_TARGET_ARCH_RISCV64 && V8_HOST_ARCH_RISCV64 && V8_OS_LINUX && \
37+
- !V8_OS_ANDROID
38+
-#define V8_TRAP_HANDLER_SUPPORTED true
39+
-// RISCV64 simulator on x64 on Linux
40+
-#elif V8_TARGET_ARCH_RISCV64 && V8_HOST_ARCH_X64 && V8_OS_LINUX
1841
-#define V8_TRAP_HANDLER_VIA_SIMULATOR
1942
-#define V8_TRAP_HANDLER_SUPPORTED true
2043
-// Everything else is unsupported.
2144
-#else
22-
#define V8_TRAP_HANDLER_SUPPORTED false
45+
-#define V8_TRAP_HANDLER_SUPPORTED false
2346
-#endif
24-
25-
// Setup for shared library export.
26-
#if defined(BUILDING_V8_SHARED) && defined(V8_OS_WIN)
47+
+#define V8_TRAP_HANDLER_SUPPORTED false

configure.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -970,6 +970,12 @@
970970
default=None,
971971
help='build without SQLite (disables SQLite and Web Storage API)')
972972

973+
parser.add_argument('--experimental-quic',
974+
action='store_true',
975+
dest='experimental_quic',
976+
default=None,
977+
help='build with experimental QUIC support')
978+
973979
parser.add_argument('--ninja',
974980
action='store_true',
975981
dest='use_ninja',
@@ -2030,6 +2036,10 @@ def without_sqlite_error(option):
20302036

20312037
configure_library('sqlite', o, pkgname='sqlite3')
20322038

2039+
def configure_quic(o):
2040+
o['variables']['node_use_quic'] = b(options.experimental_quic and
2041+
not options.without_ssl)
2042+
20332043
def configure_static(o):
20342044
if options.fully_static or options.partly_static:
20352045
if flavor == 'mac':
@@ -2482,6 +2492,7 @@ def make_bin_override():
24822492
configure_library('zstd', output, pkgname='libzstd')
24832493
configure_v8(output, configurations)
24842494
configure_openssl(output)
2495+
configure_quic(output)
24852496
configure_intl(output)
24862497
configure_static(output)
24872498
configure_inspector(output)

deps/v8/include/v8-version.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#define V8_MAJOR_VERSION 14
1212
#define V8_MINOR_VERSION 3
1313
#define V8_BUILD_NUMBER 127
14-
#define V8_PATCH_LEVEL 17
14+
#define V8_PATCH_LEVEL 18
1515

1616
// Use 1 for candidates and 0 otherwise.
1717
// (Boolean macro values are not supported by all preprocessors.)

deps/v8/src/codegen/arm64/assembler-arm64.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4968,7 +4968,7 @@ void Assembler::CheckVeneerPool(bool force_emit, bool require_jump,
49684968
return;
49694969
}
49704970

4971-
CHECK_LT(pc_offset(), unresolved_branches_first_limit());
4971+
DCHECK(pc_offset() < unresolved_branches_first_limit());
49724972

49734973
// Some short sequence of instruction mustn't be broken up by veneer pool
49744974
// emission, such sequences are protected by calls to BlockVeneerPoolFor and

doc/api/buffer.md

Lines changed: 42 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ changes:
243243
-->
244244

245245
`Buffer` instances are also JavaScript {Uint8Array} and {TypedArray}
246-
instances. All {TypedArray} methods are available on `Buffer`s. There are,
246+
instances. All {TypedArray} methods and properties are available on `Buffer`s. There are,
247247
however, subtle incompatibilities between the `Buffer` API and the
248248
{TypedArray} API.
249249

@@ -415,6 +415,21 @@ function:
415415
* [`Buffer.from(arrayBuffer[, byteOffset[, length]])`][`Buffer.from(arrayBuf)`]
416416
* [`Buffer.from(string[, encoding])`][`Buffer.from(string)`]
417417

418+
### Buffer methods are callable with `Uint8Array` instances
419+
420+
All methods on the Buffer prototype are callable with a `Uint8Array` instance.
421+
422+
```js
423+
const { toString, write } = Buffer.prototype;
424+
425+
const uint8array = new Uint8Array(5);
426+
427+
write.call(uint8array, 'hello', 0, 5, 'utf8'); // 5
428+
// <Uint8Array 68 65 6c 6c 6f>
429+
430+
toString.call(uint8array, 'utf8'); // 'hello'
431+
```
432+
418433
## Buffers and iteration
419434

420435
`Buffer` instances can be iterated over using `for..of` syntax:
@@ -2058,6 +2073,10 @@ console.log(buf.fill('zz', 'hex'));
20582073

20592074
<!-- YAML
20602075
added: v5.3.0
2076+
changes:
2077+
- version: REPLACEME
2078+
pr-url: https://github.com/nodejs/node/pull/56578
2079+
description: supports Uint8Array as `this` value.
20612080
-->
20622081

20632082
* `value` {string|Buffer|Uint8Array|integer} What to search for.
@@ -2945,10 +2964,14 @@ console.log(buf.readInt32LE(1));
29452964
<!-- YAML
29462965
added: v0.11.15
29472966
changes:
2967+
- version: REPLACEME
2968+
pr-url: https://github.com/nodejs/node/pull/56578
2969+
description: supports Uint8Array as `this` value.
29482970
- version: v10.0.0
29492971
pr-url: https://github.com/nodejs/node/pull/18395
29502972
description: Removed `noAssert` and no implicit coercion of the offset
29512973
and `byteLength` to `uint32` anymore.
2974+
29522975
-->
29532976

29542977
* `offset` {integer} Number of bytes to skip before starting to read. Must
@@ -2992,10 +3015,14 @@ console.log(buf.readIntBE(1, 0).toString(16));
29923015
<!-- YAML
29933016
added: v0.11.15
29943017
changes:
3018+
- version: REPLACEME
3019+
pr-url: https://github.com/nodejs/node/pull/56578
3020+
description: supports Uint8Array as `this` value.
29953021
- version: v10.0.0
29963022
pr-url: https://github.com/nodejs/node/pull/18395
29973023
description: Removed `noAssert` and no implicit coercion of the offset
29983024
and `byteLength` to `uint32` anymore.
3025+
29993026
-->
30003027

30013028
* `offset` {integer} Number of bytes to skip before starting to read. Must
@@ -3269,6 +3296,9 @@ console.log(buf.readUInt32LE(1).toString(16));
32693296
<!-- YAML
32703297
added: v0.11.15
32713298
changes:
3299+
- version: REPLACEME
3300+
pr-url: https://github.com/nodejs/node/pull/56578
3301+
description: supports Uint8Array as `this` value.
32723302
- version:
32733303
- v14.9.0
32743304
- v12.19.0
@@ -3319,6 +3349,9 @@ console.log(buf.readUIntBE(1, 6).toString(16));
33193349
<!-- YAML
33203350
added: v0.11.15
33213351
changes:
3352+
- version: REPLACEME
3353+
pr-url: https://github.com/nodejs/node/pull/56578
3354+
description: supports Uint8Array as `this` value.
33223355
- version:
33233356
- v14.9.0
33243357
- v12.19.0
@@ -3771,6 +3804,10 @@ console.log(copy);
37713804

37723805
<!-- YAML
37733806
added: v0.1.90
3807+
changes:
3808+
- version: REPLACEME
3809+
pr-url: https://github.com/nodejs/node/pull/56578
3810+
description: supports Uint8Array as `this` value.
37743811
-->
37753812

37763813
* `encoding` {string} The character encoding to use. **Default:** `'utf8'`.
@@ -3909,6 +3946,10 @@ for (const value of buf) {
39093946

39103947
<!-- YAML
39113948
added: v0.1.90
3949+
changes:
3950+
- version: REPLACEME
3951+
pr-url: https://github.com/nodejs/node/pull/56578
3952+
description: supports Uint8Array as `this` value.
39123953
-->
39133954

39143955
* `string` {string} String to write to `buf`.

0 commit comments

Comments
 (0)