Skip to content

Commit

Permalink
doc: fix copy-paste artifacts in the buffer.md
Browse files Browse the repository at this point in the history
PR-URL: #9795
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Roman Reiss <me@silverwind.io>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
  • Loading branch information
vsemozhetbyt authored and MylesBorins committed Mar 7, 2017
1 parent 9354ee5 commit 13fa9af
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions doc/api/buffer.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -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()
Expand Down

0 comments on commit 13fa9af

Please sign in to comment.