Add canAdvance to cursor and tests
Summary: Determine if the cursor can advance N bytes. This is useful if applications want to check before reading so an exception isn't thrown. It tries to walk the minimal amount of links needed in the chain. I had a task that could have used this, though caching totalLength and macro magic ended up being the implementation chosen. I think this just adds to the cursor API. Reviewed By: djwatson Differential Revision: D2728498 fb-gh-sync-id: 8657653b82a48828cccab143653dc169ef715702
Showing
Please register or sign in to comment