Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing .lastIndexOf method #114

Closed
feross opened this issue Apr 28, 2016 · 5 comments
Closed

Add missing .lastIndexOf method #114

feross opened this issue Apr 28, 2016 · 5 comments

Comments

@feross
Copy link
Owner

feross commented Apr 28, 2016

Node.js documentation for .lastIndexOf: https://nodejs.org/api/buffer.html#buffer_buf_lastindexof_value_byteoffset_encoding

Identical to Buffer#indexOf(), but searches the Buffer from back to front instead of front to back. Returns the starting index position of value in Buffer or -1 if the Buffer does not contain value. The value can be a String, Buffer or Number. Strings are by default interpreted as UTF8. If byteOffset is provided, will return the last match that begins at or before byteOffset.

@dcposch's PR: nodejs/node#4846

@feross
Copy link
Owner Author

feross commented Apr 29, 2016

@dcposch -- any interest in sending a PR to implement this? ;)

@dcposch
Copy link
Collaborator

dcposch commented May 1, 2016

lol k

@feross feross changed the title Add buf.lastIndexOf Add missing .lastIndexOf method Aug 8, 2016
@feross
Copy link
Owner Author

feross commented Aug 8, 2016

Yo @dcposch, no pressure, but this issue is still open if you want it 😉

@dcposch
Copy link
Collaborator

dcposch commented Aug 8, 2016

sure, on it

@feross
Copy link
Owner Author

feross commented Aug 8, 2016

Awesome! Fixed by #127

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

No branches or pull requests

2 participants