Skip to content
This repository has been archived by the owner on Apr 22, 2023. It is now read-only.

Add Buffer::fill() method to do a memset #477

Closed
wants to merge 3 commits into from

Conversation

kkaefer
Copy link

@kkaefer kkaefer commented Nov 30, 2010

@kkaefer
Copy link
Author

kkaefer commented Nov 30, 2010

still missing tests

@kkaefer
Copy link
Author

kkaefer commented Nov 30, 2010

Yeah, throw an exception in that case? Currently it just ignores the upper bits. E.g. a charcode of 256 would be 0 and 257 = 1.

@kkaefer
Copy link
Author

kkaefer commented Nov 30, 2010

I mostly added the start/end for API consistency, but if there's a consensus, I can also remove it.

@elarkin
Copy link

elarkin commented Dec 3, 2010

This conflicts with an existing buffer set method: See https://github.com/ry/node/blob/master/lib/buffer.js#L191

@kkaefer
Copy link
Author

kkaefer commented Dec 4, 2010

Thanks elarkin, I changed it to "fill" now as xk suggested in #472

@ry ry closed this in 5e1b7ca May 6, 2011
@ry
Copy link

ry commented May 6, 2011

thanks. sorry it took so long

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants