Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Conversation

xphil
Copy link

@xphil xphil commented Apr 16, 2018

Description: What this PR does
Added ability to terminate ArrayEach() from within its callback, by setting error to some value.
Previous implementation didn't make much sense, since error was always nil.

Benchmark before change:
Benchmark is currently broken, but this fix should not change benchmark times in any way. Might fix benchmark later.

Benchmark after change:

For running benchmarks use:

go test -test.benchmem -bench JsonParser ./benchmark/ -benchtime 5s -v
# OR
make bench (runs inside docker)

xphil added 2 commits April 16, 2018 03:45
Added ability to terminate ArrayEach() from within its callback, by setting
error to some value.
Previous implementation didn't make much sense, since error was always nil.
@jlhawn
Copy link

jlhawn commented Nov 13, 2018

@xphil I just noticed this PR, after I opened #156

What do you think of that patch? It's a similar goal as this one except it has the callback return an error. I also fixed the benchmarks to get them to run again.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.