Skip to content
This repository was archived by the owner on Jul 30, 2024. It is now read-only.

Buffer instance does not have kMaxLength actually #169

Merged
merged 1 commit into from
Feb 22, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -141,15 +141,6 @@ class Buffer private[this] () extends Uint8Array( /* dummy to trick constructor
*/
def keys(): js.Iterator[Int] = js.native

/**
* The largest size allowed for a single Buffer instance.
* On 32-bit architectures, this value is (2^30)-1 (~1GB). On 64-bit architectures, this value is (2^31)-1 (~2GB).
* Note that this is a property on the buffer module returned by require('buffer'), not on the Buffer global or
* a Buffer instance.
* @return the largest size allowed
*/
def kMaxLength: Int = js.native

/**
* Identical to buf.indexOf(), except buf is searched from back to front instead of front to back.
* @param value What to search for
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,6 @@ package object buffer {
*
* On 32-bit architectures, this value is `(2^30)-1` (~1GB).
* On 64-bit architectures, this value is `(2^31)-1` (~2GB).
*
* This value is also available as [[Buffer.kMaxLength]].
*/
val MAX_LENGTH: Int = js.native

Expand Down