From 8af811f90e4014faa7dc2247a0a6788d18cc1b0e Mon Sep 17 00:00:00 2001 From: Vse Mozhet Byt Date: Sat, 26 Nov 2016 23:08:40 +0200 Subject: [PATCH] doc: fix copy-paste artifacts in the buffer.md PR-URL: https://github.com/nodejs/node/pull/9795 Reviewed-By: Sam Roberts Reviewed-By: Roman Reiss Reviewed-By: Anna Henningsen --- doc/api/buffer.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/api/buffer.md b/doc/api/buffer.md index 9af658f5c310fe..d1a3e056b3225a 100644 --- a/doc/api/buffer.md +++ b/doc/api/buffer.md @@ -1511,10 +1511,10 @@ Examples: ```js const buf = Buffer.from([0x12, 0x34, 0x56, 0x78, 0x90, 0xab]); -// Prints: 1234567890ab +// Prints: -546f87a9cbee console.log(buf.readIntLE(0, 6).toString(16)); -// Prints: -546f87a9cbee +// Prints: 1234567890ab console.log(buf.readIntBE(0, 6).toString(16)); // Throws an exception: RangeError: Index out of range @@ -1739,7 +1739,7 @@ console.log(buf1); const buf2 = Buffer.from([0x1, 0x2, 0x3]); // Throws an exception: RangeError: Buffer size must be a multiple of 16-bits -buf2.swap32(); +buf2.swap16(); ``` ### buf.swap32()